/** * Identity Registry module for ERC-8004 * Handles agent registration and identity management */ import { ethers } from 'ethers'; import { MetadataEntry, AgentRegistrationFile } from './types'; export declare class IdentityRegistry { private contract; private provider; private signer?; constructor(address: string, provider: ethers.Provider, signer?: ethers.Signer); /** * Register a new agent with no URI (URI can be set later) * Spec: function register() returns (uint256 agentId) */ register(): Promise; /** * Register a new agent with a token URI * Spec: function register(string tokenURI) returns (uint256 agentId) * @param tokenURI - URI pointing to agent registration file (MAY use ipfs://, https://, etc.) */ registerWithURI(tokenURI: string): Promise; /** * Register a new agent with URI and optional on-chain metadata * Spec: function register(string tokenURI, MetadataEntry[] calldata metadata) returns (uint256 agentId) * @param tokenURI - URI pointing to agent registration file * @param metadata - OPTIONAL on-chain metadata entries */ registerWithMetadata(tokenURI: string, metadata?: MetadataEntry[]): Promise; /** * Get the token URI for an agent * Spec: Standard ERC-721 tokenURI function * @param agentId - The agent's ID * @returns URI string (MAY be ipfs://, https://, etc.) */ getTokenURI(agentId: bigint): Promise; /** * Set the token URI for an agent * Note: This is an implementation-specific extension (not in base spec). * Assumes implementation exposes setTokenURI with owner/operator checks. * @param agentId - The agent's ID * @param uri - New URI string */ setTokenURI(agentId: bigint, uri: string): Promise; /** * Get the owner of an agent * Spec: Standard ERC-721 ownerOf function * @param agentId - The agent's ID */ getOwner(agentId: bigint): Promise; /** * Get on-chain metadata for an agent * Spec: function getMetadata(uint256 agentId, string key) returns (bytes) * @param agentId - The agent's ID * @param key - Metadata key */ getMetadata(agentId: bigint, key: string): Promise; /** * Set on-chain metadata for an agent * Spec: function setMetadata(uint256 agentId, string key, bytes value) * @param agentId - The agent's ID * @param key - Metadata key * @param value - Metadata value */ setMetadata(agentId: bigint, key: string, value: string): Promise; /** * Fetch and parse the agent registration file from the token URI * This is a convenience function that fetches the URI and parses it * Note: Does not validate - spec says ERC-8004 cannot cryptographically guarantee * that advertised capabilities are functional * @param agentId - The agent's ID */ getRegistrationFile(agentId: bigint): Promise; } //# sourceMappingURL=IdentityRegistry.d.ts.map