Guided flow · ECZ-ID API Passport™
API guided flow
Carry an API through the Accountability Chain: its identity and operator, the caller and its context, authority and Intent, current state, a decision before consequence, the result, and the Receipt and re-verify.
- API identity
- Operator
- Caller and context
- Authority
- Intent
- Current state
- Decision
- Action and result
- Receipt and re-verify
Steps at a glance · what is live today
- 01Identify the APILive · public
- 02Connect the accountable operatorLive · public
- 03Resolve the caller and its contextLive · public
- 04Establish authorityLive · signed in
- 05Carry IntentLive · signed in
- 06Read current stateLive · public
- 07Decide before consequenceRelease-gated
- 08Act, and record the resultYour system
- 09Receipt and re-verifyNo public retrieval
Live in production and publicly readable, with no account and no key.
GoalGive the API a free ECZ-ID Passport and declare it where its ecosystem already looks.
Why it mattersOne logical API is one Passport. Versions, environments, regional aliases and gateways are bindings; a second distinct API is a second Passport.
Prerequisites
- An API you operate.
- One identifier: its base URL, its OpenAPI URL or its repository.
Example
openapi: 3.1.0
info:
title: Example Payments API
version: "2.3.0"
x-ecz-id:
operator_ecz_id: ECZ-GB-EXAMPL
api_passport_id: ECZ-GB-EXAMPL::API_PASSPORT-AB12CD
api_origin: https://api.example.com
spec_hash: sha256:<hash-of-canonical-spec>
resolver_url: https://resolver.ecocitizenz.org/p/ECZ-GB-EXAMPL::API_PASSPORT-AB12CDCheck
npx -y @ecocitizenz/ecz-id-mcp-verifier check --target https://api.ecocitizenz.com --target-type api_urlExpected output
{
"target_type": "api_url",
"policy_mode": "OPEN",
"result_state": "NO_PUBLIC_RESOLVER_PROOF_FOUND",
"reason_codes": ["NO_PUBLIC_RESOLVER_PROOF_FOUND", "RESOLVER_READ_ONLY",
"LOCAL_POLICY_DECIDES"],
"primary_action": "CHOOSE_OPERATOR_PATH",
"exit_code": 0
}ECZ-ID’s own public API has not been issued an API Passport. Declare yours in OpenAPI info as one x-ecz-id object, with the fields in the OpenAPI x-ecz-id reference at /bindings/openapi-x-ecz-id/.
What this proves
- That the machine has a persistent, publicly resolvable identity under an accountable organisation, once issued and declared.
What this does not prove
- That the machine is safe, secure, correct or verified. A free Passport never claims that.
- Control of any native identity. A declaration is a pointer; only a proven binding proves.
Live in production and publicly readable, with no account and no key.
GoalResolve the Business Passport of the organisation that answers for the API.
Why it mattersEvery child Passport resolves to one accountable organisation. A relying party who reaches the API can always find who stands behind it, without asking.
Prerequisites
- The API's ECZ-ID, or the parent ECZ-ID it names.
Example
curl -s https://api.ecocitizenz.com/api/p/ECZ-GB-RBS1NW.jsonExpected output
{
"ecz_id": "ECZ-GB-RBS1NW",
"resolver_v2": {
"record_type": "ECZ_ID_PARENT",
"state": {
"lifecycle_state": "ACTIVE",
"parent_tier": "VERIFIED",
"reliance_level": "PARENT_IDENTITY_ONLY"
},
"reliance": {
"can_rely_on": ["record_existence", "active_parent_state",
"current_parent_tier", "public_resolver_visibility"],
"reverify_before_reliance": true
}
}
}This is the operator record behind this site. Read parent_tier_context.tier_meaning on a child record: a parent tier is never inherited by a machine.
What this proves
- An accountable organisation exists and is publicly resolvable.
- Its current lifecycle state and parent tier, at the moment you read them.
What this does not prove
- That the organisation authorised any particular action by the API.
- That the machine itself is verified, safe or compliant.
Live in production and publicly readable, with no account and no key.
GoalBefore serving a consequential request, resolve the calling agent or service by its ECZ-ID.
Why it mattersReciprocal trust runs both ways. The caller checked your API; your API checks the caller. Its record says who operates it and what state it is in now.
Prerequisites
- The caller’s ECZ-ID, carried by your own authentication or request metadata.
Example
// Runs today: your own policy over live Resolver state.
async function mayProceed(eczId) {
const res = await fetch('https://api.ecocitizenz.com/api/p/' + eczId + '.json');
if (res.status === 404) return { ok: false, why: 'NO_PUBLIC_ECZ_ID_FOUND' };
if (!res.ok) return { ok: false, why: 'RESOLVER_UNREADABLE', retry: true };
const v2 = (await res.json()).resolver_v2;
const failClosed = v2.machine_policy.fail_closed_states;
const ok = v2.state.lifecycle_state === 'ACTIVE'
&& !failClosed.includes(v2.state.lifecycle_state)
&& !failClosed.includes(v2.binding.state);
return { ok, why: v2.state.reliance_level };
}What this proves
- The caller’s accountable operator and current published state.
What this does not prove
- That the caller is authorised for this request. That is authority and Intent, next.
Live in production and operated by the account holder, signed in, through the TrustOps Dashboard.
GoalState what the calling agent is authorised to do, within what bounds and for how long, and make every consequential action name that Intent.
Why it mattersAn Intent can name the counterparty it may act against, how fresh that counterparty’s proof must be, and what happens if its state changes.
Prerequisites
- An authorised ECZ-ID Intent in force (state
ACTIVE). - A single choke point in your code where consequential actions pass.
Example
{
"schema": "ecz.intent.v1",
"actor": { "kind": "ECZ_PASSPORT", "ecz_id": "ECZ-GB-EXAMPL::AGENT_PASSPORT-AB12CD", "family": "AGENT" },
"objective_summary": "Refund damaged orders through the payments API",
"constraints": {
"actions": { "permitted": ["refund:create"], "excluded": [] },
"resources": { "permitted": ["orders/*"], "excluded": [] },
"financial": { "currency": "GBP", "max_per_action": 250, "max_total": 2500 },
"counterparty": {
"counterparty_ecz_id": "ECZ-GB-EXAMPL",
"required_dci_state": "BOUND",
"max_proof_age_seconds": 300,
"on_change": "RE_RESOLVE"
}
},
"window": { "not_before": "2026-10-12T00:00:00Z", "expires_at": "2026-10-19T00:00:00Z" },
"state": "ACTIVE"
}In your system
// Your audit log: one entry per consequential action, written before it runs.
// ECZ-ID defines the Intent reference; the rest belongs to your system.
log.info('consequential_action', {
actor_ecz_id: 'ECZ-GB-EXAMPL::AGENT_PASSPORT-AB12CD',
intent_ref: { intent_id: 'INT-0000000000EXAMPLE0', version: 3 },
request_id: crypto.randomUUID(),
action: 'refund:create',
resource: 'orders/88213',
amount: 120,
currency: 'GBP',
});Request identifiers, nonces and correlation IDs belong to the request, not the Intent. ECZ-ID defines no header for carrying an Intent reference over arbitrary protocols, and this site does not invent one.
What this proves
- What was authorised, as a versioned record with its bounds and window.
What this does not prove
- That any action stayed inside those bounds. Holding an Intent identifier authorises nothing by itself.
- That a sandbox Intent covers production. It never does.
Live in production and publicly readable, with no account and no key.
GoalRead both parties’ state live at the moment of the request, not from a cache.
Why it mattersA counterparty that was active this morning can be suspended this afternoon. Records are served no-store, and fail-closed states are listed by the record itself.
Prerequisites
- Both ECZ-IDs.
Example
curl -s https://api.ecocitizenz.com/api/p/ECZ-GB-RBS1NW.jsonExpected output
"machine_policy": {
"recommended_machine_action": "ALLOW_PARENT_IDENTITY_VISIBILITY_ONLY",
"high_risk_action": "FAIL_CLOSED_UNLESS_LIVE_BINDING_AND_EVIDENCE_AVAILABLE",
"fail_closed_states": ["REVOKED", "SUSPENDED", "DEGRADED", "MISMATCH",
"PROOF_UNAVAILABLE", "PUBLIC_PROJECTION_UNAVAILABLE", "ACTIVE_ABUSE_FLAGGED", "UNKNOWN"]
}What this proves
- The published state now, and which states the publisher expects you to fail closed on.
What this does not prove
- State a minute from now.
ReferenceCurrent stateResolver output
Documented ahead of release.
GoalDecide whether the request's proposed action may proceed before it changes anything.
Why it mattersAn HTTP gateway in front of the API is where a request can be held or blocked. IntentControl is designed to evaluate a proposed action against identity, authority, delegation, Intent, policy, current state and constraints. It is documented ahead of release, so today you decide with your own policy over live state.
Prerequisites
- A choke point in your code in front of the action.
- The counterparty or target ECZ-ID.
Example
// Runs today: your own policy over live Resolver state.
async function mayProceed(eczId) {
const res = await fetch('https://api.ecocitizenz.com/api/p/' + eczId + '.json');
if (res.status === 404) return { ok: false, why: 'NO_PUBLIC_ECZ_ID_FOUND' };
if (!res.ok) return { ok: false, why: 'RESOLVER_UNREADABLE', retry: true };
const v2 = (await res.json()).resolver_v2;
const failClosed = v2.machine_policy.fail_closed_states;
const ok = v2.state.lifecycle_state === 'ACTIVE'
&& !failClosed.includes(v2.state.lifecycle_state)
&& !failClosed.includes(v2.binding.state);
return { ok, why: v2.state.reliance_level };
}What this proves
- Your own decision, made on the current published state of the counterparty.
What this does not prove
- An Intent-bounded decision. That is IntentControl: its interface is release-gated and not callable, and commercially it is coming soon in TrustOps and not yet on sale.
- Enforcement. A decision only constrains actions routed through an enforcement point you run.
This happens in the integrator’s own system.
GoalServe the request, or refuse it, and record what you did.
Why it mattersThe action and its result happen in your API. A decision says what was determined; only your system knows what actually happened.
Prerequisites
- Your audit log entry from the Intent step.
What this proves
- What your system did, as your system recorded it.
What this does not prove
- That an allowed request succeeded. An allow is not a result.
ReferenceConsequence boundary
ECZ-ID Core records it, but public, unauthenticated retrieval and verification are not enabled.
GoalKeep a record of what the API did, and know what ECZ-ID publishes about it.
Why it mattersReceipts record decisions, mediation and lifecycle events in Core. A Receipt proves what the recording system recorded; it does not prove every real-world assertion behind it.
Prerequisites
- Your own audit log entry from the Intent step.
Example
curl -s https://api.ecocitizenz.com/api/p/ECZ-GB-RBS1NW.jsonExpected output
"evidence": {
"public_receipts_count": 0,
"public_receipt_state": "NO_PUBLIC_RECEIPT",
"public_receipt_retrievable": false,
"receipt_retrieval_state": "NONE_PUBLISHED",
"recorded_receipts_count": 1,
"reason_codes": ["RECEIPTS_RECORDED_NOT_PUBLICLY_RETRIEVABLE"]
}Recorded is not published. Decide on evidence.public_receipt_state and evidence.public_receipt_retrievable, the fields the record lists for machines.
What this proves
- Whether Core has recorded receipts for the subject, and whether any are publicly retrievable.
What this does not prove
- What any receipt says. Public retrieval and public verification are not enabled.
- That an action happened or succeeded. An allow is not a result, and a decision receipt is not an action receipt.
Where next
This page is explanation, not authority. Current state is only ever the live Resolver record. Commands were run read-only on 2026-10-10; illustrative examples are labelled.
