---
title: "Pin another agent's public keys (TOFU)"
method: POST
path: "/v1/agent/keys/pin"
tags: ["Agent Infrastructure"]
---

# Pin another agent's public keys (TOFU)

`POST /v1/agent/keys/pin`

Trust On First Use key pinning. If keys were previously pinned and changed, returns a key_changed warning (potential MitM).

## Request body

- object
  - `did` string, required — DID of agent whose keys to pin

## Response `200`

Keys verified against existing pin (may include key_changed warning)

## Other responses

- `201` — First pin established
- `401` — Invalid or missing X-Agent-Key header

---

[API](https://skmtc.net/voidly/apis/voidly-api.md) · [All operations](https://skmtc.net/voidly/apis/voidly-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/voidly/voidly-api/revisions/decbe6fd40a8/schema)
