OpenAgentID documentation
Source referencesRust module referenceopenagent-auth-protocol

openagent-auth-protocol · types

Declared module signatures, types, configuration, and source documentation.

Source: openagent-sdk/crates/openagent-auth-protocol/src/types.rs. SHA-256: 399d81227f0317d5513cd77a42d84da7b8f6f4772057de68a851138b880dd485.

This source reference follows declared modules and preserves feature attributes. It includes public declarations and implementation methods in those modules. Private-module exports and trait resolution still require the compiler; not every declaration is a crate-root import. Function bodies and constant values are omitted. Source comments describe their implementation context and are not a production deployment claim.

types::ConformanceLevel

Conformance levels for entity classification (Bioagentic).

#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, Serialize, Deserialize)]
pub enum ConformanceLevel {
    /// L0: Passive signals only (UA, TLS fingerprint).
    #[serde(rename = "L0")]
    L0,
    /// L1: Behavioral analysis (18-dim feature extraction).
    #[serde(rename = "L1")]
    L1,
    /// L2: Full cryptographic proof (Ed25519 / FIDO2).
    #[serde(rename = "L2")]
    L2,
}

Source line: 11.

types::ConformanceLevel::level

Returns the numeric ordering (L0=0, L1=1, L2=2).

pub fn level(&self) -> u8;

Source line: 25.

types::ConformanceLevel::satisfies

Returns true if self satisfies the required level.

pub fn satisfies(&self, required: &Self) -> bool;

Source line: 34.

types::DidDocument

Minimal DID document fragment for the handshake.

#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct DidDocument {
/// Canonical DID (e.g. `did:oas:l1fe:agent:my-bot`).

pub id: String,
/// Multibase-encoded Ed25519 verification key.

pub verification_key: String,
/// Entity kind (`agent`, `tool`, `service`, etc.).

pub kind: String,
/// Optional parent DID for lineage.

#[serde(skip_serializing_if = "Option::is_none")]
pub parent: Option<String>
}

Source line: 51.

types::LineageProof

Cryptographic lineage proof linking an agent to its human root.

#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct LineageProof {
/// Chain of DID-to-DID attestations from the agent back to HMR.

pub chain: Vec<LineageLink>
}

Source line: 65.

A single link in the lineage chain.

#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct LineageLink {
/// DID of the parent (delegator).

pub from: String,
/// DID of the child (delegatee).

pub to: String,
/// Ed25519 signature by `from` over the delegation assertion.

pub signature: String,
/// ISO-8601 timestamp of the delegation.

pub issued_at: String
}

Source line: 72.

types::DiscoveryDocument

Server discovery response at GET /.well-known/openagent.

#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct DiscoveryDocument {
/// Auth endpoint path (default: `/.well-known/openagent/auth`).

pub auth_endpoint: String,
/// Supported protocol versions.

pub supported_versions: Vec<u32>,
/// Server's DID.

pub server_did: String,
/// Minimum conformance level required.

pub required_conformance_level: ConformanceLevel
}

Source line: 85.

On this page