rendered from docs/registration-records.md 89fab6d4c77d

Reading the account tree

A didbot server writes two public records for every account it creates. An app reads them to learn what an account is, which person operates it, and which account created it. This page is for that app. Who operates an account covers how the records are written and what each one proves.

bot.did.registration

The server writes one into the account’s own repository, at record key self. The schema is lexicons/bot/did/registration.json.

Field Required Holds
did yes The account’s DID, so a copy taken out of the repository still says which account it describes.
operator yes The DID of the person at the top of the tree. Their repository is on a server this one cannot write to.
kind yes A label for the account, from the lexicon’s knownValues. The server gives it no meaning, and a reader should accept a value it does not know.
lineage no The DIDs of the accounts between the operator and this one: first the account the operator created, last this account’s parent. Absent when the operator created this account. At most 16 entries.
createdAt yes When the server created the account.

The server writes the record while it creates the account, before the repository is announced, and never changes it. The server refuses any write to bot.did.registration from the account itself, so an account cannot change what it says it is. The server’s own account, did:web:<server hostname>, has one too: kind: "service" and no lineage.

bot.did.operator

One record per account the author operates. The record key is that account’s did:web hostname, such as agent.pds.example.

Field Required Holds
subject yes The DID of the account the author operates.
creates no What the subject may create beneath it. The server reads this only from the person’s own repository.
createdAt yes When the author wrote the record.

Two parties write these:

Building the tree

Each registration places its account in one tree:

For a person who runs a laptop host that starts agent sessions, each with subagents:

Account kind lineage Parent
did:web:host.pds.example host absent did:plc:human
did:web:agent.pds.example agent [host] host
did:web:subagent.pds.example agent [host, agent] agent

Any kind can have children. Draw the tree from lineage and use kind only for the label.

To walk down instead, list bot.did.operator records. The person’s repository lists the accounts they created and the server. Each hosted account’s repository lists the accounts it created.

Every record inside a didbot server’s repositories is that server’s word: it holds the signing keys and could write any of them. On any other server, an account can write its own bot.did.registration, and the record is the account’s word. The person’s own bot.did.operator records are theirs. To confirm the person operates an account, read their record for the first lineage entry, or for the account when there is no lineage, and their record for the server. What a stranger can check walks through it.

Examples

The server is pds.example, run by did:plc:human.

The server’s own account:

// at://did:web:pds.example/bot.did.registration/self
{
  "$type": "bot.did.registration",
  "did": "did:web:pds.example",
  "operator": "did:plc:human",
  "kind": "service",
  "createdAt": "2026-10-10T23:20:44Z"
}

A host the person created:

// at://did:web:host.pds.example/bot.did.registration/self
{
  "$type": "bot.did.registration",
  "did": "did:web:host.pds.example",
  "operator": "did:plc:human",
  "kind": "host",
  "createdAt": "2026-10-10T23:21:01Z"
}

An agent session the host created, and its subagent:

// at://did:web:agent.pds.example/bot.did.registration/self
{
  "$type": "bot.did.registration",
  "did": "did:web:agent.pds.example",
  "operator": "did:plc:human",
  "lineage": ["did:web:host.pds.example"],
  "kind": "agent",
  "createdAt": "2026-10-21T12:12:32Z"
}
// at://did:web:subagent.pds.example/bot.did.registration/self
{
  "$type": "bot.did.registration",
  "did": "did:web:subagent.pds.example",
  "operator": "did:plc:human",
  "lineage": ["did:web:host.pds.example", "did:web:agent.pds.example"],
  "kind": "agent",
  "createdAt": "2026-10-21T12:14:05Z"
}

A pipeline the person created for a CI workflow:

// at://did:web:pipeline.pds.example/bot.did.registration/self
{
  "$type": "bot.did.registration",
  "did": "did:web:pipeline.pds.example",
  "operator": "did:plc:human",
  "kind": "pipeline",
  "createdAt": "2026-10-12T09:40:17Z"
}

The person’s record for the host, in their own repository, and the record the server wrote in the host’s repository for the agent:

// at://did:plc:human/bot.did.operator/host.pds.example
{
  "$type": "bot.did.operator",
  "subject": "did:web:host.pds.example",
  "creates": [
    { "scope": "subject", "kinds": ["agent"] },
    { "scope": "descendants", "kinds": ["agent"] }
  ],
  "createdAt": "2026-10-10T23:20:58Z"
}
// at://did:web:host.pds.example/bot.did.operator/agent.pds.example
{
  "$type": "bot.did.operator",
  "subject": "did:web:agent.pds.example",
  "createdAt": "2026-10-21T12:12:32Z"
}

Reading them over XRPC

Both records are public and need no credential. Find the account’s server in its DID document: the #atproto_pds service. A did:web document is at https://<hostname>/.well-known/did.json.

curl -s 'https://pds.example/xrpc/com.atproto.repo.listRecords?repo=did:web:agent.pds.example&collection=bot.did.registration'
{
  "records": [
    {
      "uri": "at://did:web:agent.pds.example/bot.did.registration/self",
      "cid": "bafyrei…",
      "value": {
        "$type": "bot.did.registration",
        "did": "did:web:agent.pds.example",
        "operator": "did:plc:human",
        "lineage": ["did:web:host.pds.example"],
        "kind": "agent",
        "createdAt": "2026-10-21T12:12:32Z"
      }
    }
  ]
}

An account has at most one, so com.atproto.repo.getRecord with rkey=self reads the same record. An empty records list means the account has no registration.

The accounts the host created, from the same server:

curl -s 'https://pds.example/xrpc/com.atproto.repo.listRecords?repo=did:web:host.pds.example&collection=bot.did.operator'

The person’s records come from the server their own DID document names, with repo=did:plc:human.

A firehose reader sees each registration as a create in the account’s first commits on com.atproto.sync.subscribeRepos.