did:t3n DID the organization controls, with an agent card that T3N hosts privately for the organization to manage — never public unless the organization chooses. Every step uses the t3n CLI that ships with the @terminal3/t3n-sdk package — no code required, for the whole lifecycle: create, read, and update (updating needs CLI 4.25.0 or newer; older installs have an SDK fallback).
Onboarding, not permissions. This page gives an agent an identity and a card. It does not grant the agent access to anything — no user data, no contract functions. That’s a separate step the data owner performs afterwards: see Agent Auth.Two onboarding paths. This is the one where an organization owns the agent, with a card kept private by default. If instead an agent registers itself — public and discoverable — see Register a Public Agent.
- Download the SDK
- Get an org admin’s key
- Create your organization
- Scaffold the agent card
- Provision the agent
- Read the card back
All commands that talk to the network accept
--env sandbox|testnet|production (or the T3N_ENV environment variable); sandbox and testnet are the same test network. testnet is the default — the examples below pass it explicitly anyway, so a copied command never depends on your shell.1
Download the SDK
The CLI is part of the TypeScript SDK. You can run it with zero install, or install it globally:The rest of this guide uses the global
t3n form; substitute npx @terminal3/t3n-sdk if you skipped the install.2
Get an org admin's key
The organization admin’s key is a standard Ethereum-style secp256k1 private key (32 bytes,
0x-prefixed hex). The easiest way to get one is the claim page — it issues a key together with metered test credits, and provisioning is a write operation that consumes credits.Put the key in your shell’s environment; every signing command reads it from there (or from --api-key):3
Create your organization
Skip this if your organization already exists — just use its DID. Otherwise create one; the authenticated caller becomes its initial admin:Drop
--json for human-readable output (organisation created: did:t3n:0a1b2c...) if you’d rather copy the DID by hand.4
Scaffold the agent card
The agent card is a JSON document, following the ERC-8004 registration format, that describes the agent and lists its service endpoints — including its A2A agent card. Scaffold one with:Run interactively, it walks you through name, description, image, and which services to include (A2A / MCP / DID). In scripts it falls back to flags:
--name, --description, --image, --did, --x402, and --force. Replace the placeholders with your agent’s real endpoints and keep the whole card under 16 KiB.This step is optional — skip it to let T3N host a minimal default card for the agent instead (shown in the next step).
5
Provision the agent
Mint the agent and host its card, all in one transaction. You don’t need a URL for the card — T3N serves it at One transaction mints the agent’s DID and its wallet, and hosts the card privately under the organization. Nothing is published — the agent is not publicly discoverable, by design.
/api/agent-card/<did>:Drop Pass
--card to host a default card. t3n agent create --org "$ORG_DID" --name "Booking Bot" (nothing else) hosts a minimal default card, named after the agent, with its DID as the service entry:--no-card to mint the agent with no card at all — add one later with card-set, which needs the writer grant covered in the last step. And pass --uri <url> only if the agent also has its own external endpoint you want recorded in its DID document (an agent-uri service entry is added for it).6
Read the card back
The card lives in your organization’s private scope. Read it back as an org admin — no publishing required:Only the organization’s admins — or a principal you grant a delegation credential to — can read it. It is not exposed at the public
/api/agent-card/<did> endpoint.That’s the whole lifecycle for a private org agent — create, read, update — all authenticated, none of it public. If card-get returns your card, you’re done; updating it takes the one extra grant below.Granting and revoking write access.
writers-add and writers-remove adjust the list and leave the other writers alone — the usual choice. writers-set replaces the whole list, so anyone you omit loses access; writers-clear removes everyone, leaving the scope unwritable until you grant again. All four require an org admin.add and remove read the current list and write back the result, so two admins editing the same scope at the same moment can overwrite each other. That’s fine interactively; scripts that might race should use writers-set with the full intended list.Reads are metered too. If
card-get returns InsufficientCredit, the account is simply out of credits — top up and retry; nothing is wrong with the card. Metering settles after the fact, so the writes in earlier steps can succeed and then leave the balance short for this read.Under the Hood: where does the private card live?
Under the Hood: where does the private card live?
The card is ordinary org-data:
create/card-set store it in your organization’s agent-cards scope on the built-in tee:org-data/contracts TEE contract, at a deterministic entry id derived from (orgDid, agentDid). Reads (card-get) go through org-data’s normal authorization — an org admin, or a holder of a delegation credential scoped to that read. It is never copied to the world-readable card map unless you explicitly publish it.What’s next
- The agent now has an identity and a card. Next, let it actually do something — granting permission to act on users’ data and contracts → Agent Auth and Delegate Access
- How DIDs work on T3N → Decentralized Identifiers
- Provisioning and card writes consume credits → Tokens