pub struct PromoteAgentAccountRequest {
pub account_id: String,
pub handle: String,
pub credential_id: String,
pub challenge_id: String,
pub client_data_json: Vec<u8>,
pub attestation_object: Vec<u8>,
pub agent_node_id: String,
pub promote_consent_signature: Vec<u8>,
pub client_operation_id: String,
pub authorization_hash: String,
pub expires_at_millis: i64,
}Expand description
Promote-consent half of the agent-account claim ceremony (api#123).
One call finishes WebAuthn registration, binds credentialId, claims the
handle, and flips rooting_tier agent_rooted → self_rooted. The ratified
promote-consent binds (account_id, handle, credential_id) plus, when
present, the two trailing counted fields authorization_hash and
expires_at_millis — that is the anti-replay binding, signed after
WebAuthn create() has produced the id. The counted-statement encoding
of those two fields is defined on the fields themselves.
Fields§
§account_id: StringPlaceholder account being claimed.
handle: StringHandle chosen at claim time. Replaces the pet name.
credential_id: StringWebAuthn credentialId of the just-created passkey.
challenge_id: StringChallenge minted by the adoption BeginWebAuthnRegistration.
client_data_json: Vec<u8>Raw WebAuthn create() attestation bytes (verbatim; the lib base64url-decodes them off the wire).
attestation_object: Vec<u8>§agent_node_id: StringIroh node id of the authorizing agent.
promote_consent_signature: Vec<u8>Agent-derived-credential signature over
(account_id, handle, credential_id) plus, when present, the two
trailing counted fields authorization_hash and expires_at_millis.
The counted-statement encoding of those two fields is defined on the
fields themselves.
client_operation_id: StringIdempotency key scoped to the authorizing agent and this RPC.
Hex SHA-256 of the claim secret (claim-state id / authorizationHash).
In the counted Ed25519 statement this field is the UTF-8 bytes of
the lowercase hex SHA-256 of the claim secret (64 hex chars).
Do not send uppercase or raw 32-byte digest.
Empty on non-adoption and on old clients.
Empty hash + 0 is old-client v1; when either this or
expires_at_millis is set, both must travel together with the existing
promote triple (account_id, handle, credential_id).
expires_at_millis: i64Consent expiry as Unix millis. On the wire this stays proto int64.
Inside the counted Ed25519 statement it is
exactly 8 big-endian two’s-complement bytes of that i64 (i64::to_be_bytes).
Not decimal text, not protobuf varint.
Zero on non-adoption and on old clients.
Empty hash + 0 is old-client v1; when either this or
authorization_hash is set, both must travel together with the
existing promote triple.
Trait Implementations§
Source§impl Clone for PromoteAgentAccountRequest
impl Clone for PromoteAgentAccountRequest
Source§fn clone(&self) -> PromoteAgentAccountRequest
fn clone(&self) -> PromoteAgentAccountRequest
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for PromoteAgentAccountRequest
impl Debug for PromoteAgentAccountRequest
Source§impl Default for PromoteAgentAccountRequest
impl Default for PromoteAgentAccountRequest
impl Eq for PromoteAgentAccountRequest
Source§impl Hash for PromoteAgentAccountRequest
impl Hash for PromoteAgentAccountRequest
Source§impl Message for PromoteAgentAccountRequest
impl Message for PromoteAgentAccountRequest
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self. Read moreSource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self.