export interface RegisterAgentOptions { /** Relay base URL, e.g. https://homespun.example.com. Trailing slash is trimmed. */ url: string; /** Optional agent display name; the relay defaults it if omitted. */ name?: string; /** * Shared registration secret. Sent as `Authorization: Bearer `. * Only needed when the relay runs REGISTRATION_MODE=secret; ignored by * relays in open mode and rejected (404) by relays in closed mode. */ secret?: string; /** Optional fetch override (defaults to global fetch). */ fetch?: typeof fetch; /** * Optional client version string. Sent as `x-homespun-cli-version` so the * relay's version-skew check can flag a too-old CLI even on the * un-authenticated register endpoint. See `HomespunClient`'s `cliVersion` * option for the parent contract. */ cliVersion?: string; } export interface RegisterAgentResult { agent_id: string; api_key: string; key_prefix: string; } /** * Provision a fresh agent + API key from the relay. Mirrors HomespunClient.call's * never-throw-raw style: network/parse failures and non-2xx responses are * surfaced as HomespunApiError. */ export declare function registerAgent(opts: RegisterAgentOptions): Promise;