import type { TunnelRegistration } from './tunnel-types.js'; export type BrokerRegisterInput = { brokerUrl: string; registrationSecret: string; gatewayVersion: string; platform: string; recoveryToken?: string; preferredSubdomain?: string; }; export declare class TunnelBrokerError extends Error { readonly status: number; constructor(status: number, message: string); } export declare class TunnelRegistrationKeyRejectedError extends TunnelBrokerError { readonly code = "TUNNEL_REGISTRATION_KEY_REJECTED"; constructor(); } export declare class TunnelRecoveryProofRejectedError extends TunnelBrokerError { readonly code = "TUNNEL_RECOVERY_PROOF_REJECTED"; constructor(); } export declare class TunnelBrokerClient { private readonly baseUrl; constructor(baseUrl: string); private apiUrl; register(input: BrokerRegisterInput): Promise; /** Explicit takeover requires a separately signed recovery audience. */ recover(input: BrokerRegisterInput): Promise; private requestRegistration; heartbeat(tunnelId: string, tunnelToken: string): Promise; deregister(tunnelId: string, tunnelToken: string): Promise; } export declare function resolveBrokerApiBase(brokerUrl: string): string;