This is the EN-only doc by design — every page under
docs/api-reference/* and this claim guide stay English to match the convention every major API platform (Stripe, GitHub, AWS, GCP) ships. Localized translations of the conceptual + tutorial docs are in flight as part of T7; the API-shaped surfaces are not in scope.Self-register vs. claim — one question decides
Are you the agent, or are you adopting a pre-existing one?
- You are the agent → use
POST /v1/agents. This creates a new agent owned by you in one authenticated call — no separate claim step. - You are adopting a gateway-provisioned agent → use
POST /v1/agents/{id}/claim(this guide). The agent already exists; you prove you hold its key and assign it to your org.
How hash_proof proves key ownership
hash_proof is the full 64-character lowercase hex output of:
providerApiKey is the agent’s Anthropic / OpenAI / Gemini key — the key the agent uses in the x-api-key / Authorization: Bearer / x-goog-api-key header on gateway calls. The API compares this against the stored proof and never sees the raw key.
Compute it locally before calling claim:
Step 1 — Agent routes its first gateway call
No extra setup required. When the agent makes a normal request through the gateway with its provider key (and optionallyx-mnemom-agent: <name>), the gateway:
- Hashes the provider key (+ name) to compute
agent_hash. - Finds no existing agent with that hash, so creates one.
- Parks it in the Mnemom Sandbox holding org with
claim_state: unclaimed. - Returns the assigned
mnm-*agent ID in thex-mnemom-agentresponse header.
mnm-* ID — you’ll need it to claim.
Between steps: integrity during the unclaimed phase
This is expected behavior, not a bug. Gateway-provisioned agents receive only a legacy alignment-card row at auto-provisioning time. No canonical alignment card is composed for them. Canonical cards are the prerequisite for the full integrity pipeline, so several downstream behaviors do not apply until after claim: No durable checkpoints.GET /v1/agents/{id}/checkpoints returns an empty list for unclaimed agents. This is expected and correct — checkpoints require a canonical alignment card. An empty checkpoint list is not a gap to investigate; it is the normal state for this provisioning tier.
Verdict headers are fail-open, not analytical. The gateway still returns X-Mnemom-Verdict and X-AIP-Verdict headers on every request, but their values (clear / pass) come from the fail-open path — there is no canonical card to analyze against. These headers are not evidence that integrity analysis ran. Don’t confuse this with the unverified verdict value: unverified means a canonical card exists and analysis was attempted but failed (analyzer timeout/error); it never applies to unclaimed agents, since no analysis is attempted for them at all.
AP-Traces are best-effort. The observer writes AP-Traces when Cloudflare metadata survives to the observer layer, but this is not guaranteed for unclaimed agents.
Enforcement mode is observe. There is no owner to authorize a more active mode; nothing is blocked or nudged.
How to get full integrity coverage. Claim the agent (Step 2 below). Once a canonical alignment card is composed — which happens as part of completing claim/onboarding — durable checkpoints begin, verdict headers reflect real analysis, and AP-Traces are guaranteed. The full integrity pipeline starts from claim.
Step 2 — Owner claims the agent
Authenticated as the owner — a Bearer JWT (frommnemom login), an mnm_* API key (X-Mnemom-Api-Key), or a session cookie — call the claim endpoint. Standard auth is all it takes; there is no special claim-only scheme. You prove you hold the agent’s provider key by sending hash_proof; the principal you authenticate as becomes the agent’s owner.
Choosing the org
- Pass
org_idto place the agent in a specific org. You must be a member (owner,admin, ormember). An org you don’t belong to →403 agent_org_not_member; the errordetailscarryrequested_org_idandclaimable_orgs. - Omit
org_idand the agent lands in your personal org — the smallest-blast-radius default. To place the agent in a shared or company org, name it explicitly.
GET /v1/orgs (or mnemom org list) to find the right org_id.
Logging in does not select an org.
mnemom login authenticates you; the
OAuth session carries no org context. Org placement is decided per command.Response
org_id, so you know exactly where the agent landed.
Idempotency and re-homing
Think of claim as a declarative assertion: “this agent is mine, and it lives in the org I name.” Repeating that assertion as the rightful owner is always safe:- Re-claim with the same (or no)
org_id→ no-op success;claimed_atis preserved. - Re-claim with a new
org_id→ the agent is moved to that org. Claim is also how you move an agent between your orgs.
409 on claim. An agent already owned by a different principal returns 403 agent_cross_tenant — hash_proof lets you claim an unowned agent; it never lets you take over one that already has an owner.
Two ways to move an agent between orgs
move takes { "dest_org_id": "org-…" } plus an Idempotency-Key header, and returns { moved, agent_id, from_org_id, to_org_id } (moving to the current org is an idempotent no-op, moved: false). Every move is recorded as an agent.org_moved governance audit row.
What changes after the claim
Once the agent is claimed:- Ownership is set.
claimed_byis your user/org; every subsequent policy and billing decision flows through your account. - The agent is in your org. It appears in
GET /v1/agentsresults for that org. - If
alignment_card.publish: true, the agent becomes discoverable in the Trust Directory at/directory. - The integrity pipeline starts from this point. A canonical alignment card is composed for the agent; durable checkpoints begin accumulating, verdict headers reflect real analysis, and AP-Traces are guaranteed. See Between steps: integrity during the unclaimed phase for what was and was not recorded before claim.
DELETE /v1/agents/{id}) is an owner-side operation.
Common failure modes
Related
- Agent Identity — the full registration model,
agent_hashformula, and self-register vs. claim comparison. - Authentication — the owner-side auth methods (passkey, AAL2, SSO, API keys) that gate the claim endpoint.
POST /v1/agents/{id}/claim— endpoint reference with full request/response schema.POST /v1/agents— self-register path (creates and owns in one authenticated call).