/**
 * Device Announcer — mDNS + Cloud registration for physical device discovery
 *
 * Announces the UI Bridge service on the local network via mDNS (when
 * react-native-zeroconf is available) and optionally registers with the
 * cloud relay backend.
 */
export interface AnnouncerConfig {
    /** Stable device identifier */
    deviceId: string;
    /** App bundle/package ID */
    appId: string;
    /** UI Bridge server port (default 8087) */
    port?: number;
    /** Cloud relay WebSocket URL for registration */
    cloudRelayUrl?: string;
    /** Auth token for cloud relay */
    cloudToken?: string;
    /** UI Bridge SDK version */
    version?: string;
}
export interface DeviceAnnouncerState {
    mdnsActive: boolean;
    cloudConnected: boolean;
}
/** Minimal interface for the react-native-zeroconf Zeroconf instance */
interface ZeroconfService {
    publishService(type: string, protocol: string, domain: string, name: string, port: number, txtRecord: Record<string, string>): void;
    unpublishService(name: string): void;
}
/**
 * Announces the UI Bridge server on the local network (mDNS) and optionally
 * registers with the qontinui.io cloud relay for remote discovery.
 */
export declare class DeviceAnnouncer {
    private config;
    private state;
    private cloudWs;
    private reconnectTimer;
    private reconnectDelay;
    private stopped;
    /** Zeroconf instance, set when mDNS is successfully started */
    private zeroconf;
    /** Rotated pairing token for mDNS TXT records */
    private pairingToken;
    constructor(config: AnnouncerConfig);
    /**
     * Start mDNS advertisement.
     *
     * The consumer must pass the `Zeroconf` constructor (from `react-native-zeroconf`)
     * explicitly; otherwise this is a no-op.
     *
     * Rationale: Metro's `require()` throws an uncatchable module-load error if the
     * bundle doesn't include the named package. That error escapes async try/catch
     * boundaries and crashes the app. We avoid it by never calling `require()`
     * ourselves — the consumer imports the package when they know it's installed.
     *
     * @param ZeroconfCtor - constructor from `import Zeroconf from 'react-native-zeroconf'`
     */
    startMdnsAdvertise(ZeroconfCtor?: new () => ZeroconfService): Promise<void>;
    /**
     * Connect to the cloud relay WebSocket and send a device_register message.
     *
     * Reconnects automatically with exponential backoff (2 s → 60 s) if the
     * connection drops.
     */
    connectCloudRelay(): Promise<void>;
    /** Stop all advertising and registration. */
    stop(): Promise<void>;
    /** Return a copy of the current announcer state. */
    getState(): DeviceAnnouncerState;
    private scheduleReconnect;
}
export {};
//# sourceMappingURL=DeviceAnnouncer.d.ts.map