Declare payload key
Self-service possession-auth declaration. Authentication is by the advisor’s registered Ed25519 signing key: the body must carry a detached signature over the v2 declaration preimage (ocss-payload-key-declaration-v2), not the bare JWK bytes. The preimage is these five fields newline-joined, in order: the literal scheme string ocss-payload-key-declaration-v2; the advisor’s UUID; the advisor’s registered signing key_id; issued_at rendered as RFC3339 UTC truncated to the second; and the raw payload_public_key_jwk bytes (last, no trailing newline). Domain-separating the scheme, binding the advisor UUID + signing key_id, and time-bounding issued_at (±5 minutes of the server clock) together rule out a captured v1-style signature, a declaration replayed later, and a declaration replayed against a different advisor. No bearer token scheme applies to this operation — authorization is established by possession of the registered private key. Clearing a declared key is not self-service — use the admin revoke flow.
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
Advisor agent ID.
Body
Serialized EC P-256 public JWK (≤4 KiB). The kid must form a valid did#kid distinct from the advisor's signing key_id.
Detached Ed25519 signature over the v2 preimage — NOT the bare JWK bytes. Build it as five newline-joined fields: the scheme string ocss-payload-key-declaration-v2, the advisor UUID, the advisor's registered signing key_id, issued_at (RFC3339 UTC, truncated to the second), and the raw payload_public_key_jwk bytes — then sign with the advisor's registered private key.
RFC3339 timestamp of this declaration — also one of the signed preimage fields (freshness-bound to ±5 minutes of the server clock; stale or future-dated declarations are rejected).