> For the complete documentation index, see [llms.txt](https://vectis.liesware.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://vectis.liesware.com/public-keys.md).

# Public Keys

## Return public keys for a kid

> Returns public keys for active keys only. Disabled, retired, compromised, and destroyed keys are rejected to avoid enabling new use.

```json
{"openapi":"3.1.0","info":{"title":"Vectis HTTP API","version":"v1"},"tags":[{"name":"Public Keys"}],"servers":[{"url":"http://127.0.0.1:3000","description":"Local default server over HTTP"},{"url":"https://127.0.0.1:3000","description":"Local HTTPS server when VECTIS_MODE=prod"}],"paths":{"/pub/{kid}":{"get":{"tags":["Public Keys"],"summary":"Return public keys for a kid","description":"Returns public keys for active keys only. Disabled, retired, compromised, and destroyed keys are rejected to avoid enabling new use.","parameters":[{"$ref":"#/components/parameters/Kid"}],"responses":{"200":{"description":"Public keys only","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicKeysOutput"}}}},"default":{"$ref":"#/components/responses/Error"}}}}},"components":{"parameters":{"Kid":{"name":"kid","in":"path","required":true,"schema":{"$ref":"#/components/schemas/Kid"}}},"schemas":{"Kid":{"type":"string","pattern":"^[0-9a-fA-F]{64}$"},"PublicKeysOutput":{"type":"object","required":["info","keys"],"properties":{"info":{"$ref":"#/components/schemas/TextField"},"keys":{"type":"object","required":["eddsa","xecdh","ml-dsa","ml-kem"],"properties":{"eddsa":{"$ref":"#/components/schemas/PublicDerKey"},"xecdh":{"$ref":"#/components/schemas/PublicRawKey"},"ml-dsa":{"$ref":"#/components/schemas/PublicDerKey"},"ml-kem":{"$ref":"#/components/schemas/PublicDerKey"}}}}},"TextField":{"type":"string","minLength":1,"pattern":"^[^\\x00-\\x1F\\x7F-\\x9F]+$"},"PublicDerKey":{"type":"object","required":["alg","public_key_der_hex"],"properties":{"alg":{"$ref":"#/components/schemas/TextField"},"public_key_der_hex":{"$ref":"#/components/schemas/HexString"}}},"HexString":{"type":"string","pattern":"^[0-9a-fA-F]+$"},"PublicRawKey":{"type":"object","required":["alg","public_key_hex"],"properties":{"alg":{"$ref":"#/components/schemas/TextField"},"public_key_hex":{"$ref":"#/components/schemas/HexString"}}},"ErrorResponse":{"type":"object","required":["error"],"properties":{"error":{"$ref":"#/components/schemas/TextField"}}}},"responses":{"Error":{"description":"Public error response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}}
```
