Public declaration syntax from forge-ts/packages/forge-identity/src/agent-identity.ts Original source SHA-256: 0af434de2b7e560b26c8f6935a719a855a35a5058e3eb9ac7cb6cf2e66e847b0 Function bodies and constant values are omitted. This is not the complete implementation. Source line 25 export interface OasDocument { /** The DID identifier. */ readonly id: string; /** The DID document context. */ readonly context: readonly string[]; /** Verification methods. */ readonly verificationMethod: readonly VerificationMethod[]; /** Authentication references. */ readonly authentication: readonly string[]; /** Optional lineage section for derived identities. */ readonly lineage?: LineageSection; /** Optional document proof. */ readonly proof?: DocumentProof; } Source line 43 export interface VerificationMethod { /** The method identifier. */ readonly id: string; /** The method type. */ readonly type: string; /** The controller DID. */ readonly controller: string; /** The public key in multibase encoding. */ readonly publicKeyMultibase: string; } Source line 57 export interface LineageSection { /** The generation (derivation depth) of this entity. */ readonly generation: number; /** The DID of the human root in the lineage chain. */ readonly humanRootDid: string; /** The DID of the immediate parent. */ readonly parentDid: string; /** The derivation path used. */ readonly derivationPath: string; /** The lineage proof. */ readonly proof: LineageProof; } Source line 73 export interface LineageProof { /** The proof type (e.g., 'AgentLineageProof2025'). */ readonly type: string; /** The ISO 8601 creation timestamp. */ readonly created: string; /** The verification method used to create the proof. */ readonly verificationMethod: string; /** The proof value (base64url-encoded signature). */ readonly proofValue: string; } Source line 87 export interface DocumentProof { /** The proof type. */ readonly type: string; /** The ISO 8601 creation timestamp. */ readonly created: string; /** The verification method used to create the proof. */ readonly verificationMethod: string; /** The proof value (base64url-encoded signature). */ readonly proofValue: string; } Source line 107 export interface CryptoBridge { /** Generates a new Ed25519 keypair. Returns [privateKey, publicKey]. */ generateKeypair(): [Uint8Array, Uint8Array]; /** Signs a message with the given private key. Returns a 64-byte signature. */ sign(privateKey: Uint8Array, message: Uint8Array): Uint8Array; /** Verifies a signature. Returns true if valid. */ verify(publicKey: Uint8Array, message: Uint8Array, signature: Uint8Array): boolean; /** Derives a child key via HKDF-SHA256. Returns [childPrivateKey, childPublicKey]. */ deriveChild(parentPrivateKey: Uint8Array, path: string): [Uint8Array, Uint8Array]; } Source line 140 export class ForgeAgentIdentity { constructor( did: string, kind: string, privateKey: Uint8Array, publicKey: Uint8Array, document: OasDocument, lineageDepth: number, bridge: CryptoBridge ); did(): string; kind(): string; document(): OasDocument; lineageDepth(): number; sign(message: Uint8Array): Uint8Array; verify(message: Uint8Array, signature: Uint8Array): void; verifyingKeyBytes(): Uint8Array; toString(): string; _privateKeyBytes(): Uint8Array; _cryptoBridge(): CryptoBridge; }