@zanii/residency
v0.2.0
Published
Prove where an agent's data physically stayed - bind a region attestation to each data touch, confirm the attested region is inside a declared jurisdiction, and emit a receipt the moment it crosses a border. Answers 'prove it never left the UAE / the EU.'
Readme
@zanii/residency
Did my data leave the country? Bind a region attestation to each data touch, confirm it's inside a declared jurisdiction, and emit a receipt when it crosses a border. Answers the 2026 sovereignty fear: "prove it never left the UAE / the EU."
npm install @zanii/residency @zanii/coreimport { buildResidencyClaim, verifyResidency, detectCrossings, JURISDICTION_PRESETS } from '@zanii/residency';
const claim = buildResidencyClaim({ jurisdiction: 'UAE',
regionAttestation: { region: 'me-central-1', source: 'aws:instance-identity', evidence }, ts: now });
await zanii.record(claim);
// verify: your injected geo verifier authenticates the region, then it must be in the allow-set
const r = await verifyResidency(claim.payload, { allowedRegions: JURISDICTION_PRESETS.UAE, verifyRegion });
r.ok; r.crossed; // crossed = the region left the declared jurisdiction — a border crossing
detectCrossings(sequence, JURISDICTION_PRESETS.UAE); // exit/return points across a historyPython: from zanii.residency import build_residency_claim, verify_residency, detect_crossings, ...
Injected geo verification & declared jurisdictions
We can't derive where a server ran — the region signal comes from the cloud provider or a
TEE's attested geolocation, authenticated by your verifyRegion (the @zanii/attest
discipline). And jurisdiction is declared, not assumed: you pass an explicit
allowedRegions set — your compliance team owns it. Presets (UAE, GCC, EU) are
convenience only.
The limit, stated up front
Only as strong as the region attestation source. A claim proves "a signal your verifier trusts said this ran in region R, and R is in your declared jurisdiction." Bind a signal you verify.
