> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.adid.dev/llms.txt.
> For full documentation content, see https://docs.adid.dev/llms-full.txt.

# DIDComm Service Endpoints

For a DID to be reachable by DIDComm peers, its DID Document **must** include a `DIDCommMessaging` service entry. IDA auto-populates this for every `did:adi` it provisions:

```json
{
  "@context": ["https://www.w3.org/ns/did/v1", "https://didcomm.org/messaging/contexts/v2"],
  "id": "did:adi:def…",
  "verificationMethod": [/* … */],
  "authentication": ["did:adi:def…#key-1"],
  "keyAgreement":  ["did:adi:def…#key-x25519-1"],
  "service": [
    {
      "id": "did:adi:def…#didcomm-1",
      "type": "DIDCommMessaging",
      "serviceEndpoint": {
        "uri": "https://adid.dev/api/v1/didcomm/receive",
        "accept": ["didcomm/v2"],
        "routingKeys": []
      }
    }
  ]
}
```

To override the default endpoint (e.g., point at your own mediator), update the DID Document via `PUT /api/v1/dids/{did}` and replace the `service` array. See §9.3 [DID endpoints](#api-dids).

> **Important:** the `keyAgreement` verification method is **distinct** from the `authentication` key. Authentication uses Ed25519; key agreement uses X25519 (derived from the same seed via the standard birational map). The platform manages this for you, but if you publish a custom DID Document, ensure both keys are present — DIDComm v2 cannot decrypt without an X25519 key-agreement key.