/**
 * Device Identity Service
 *
 * Manages a persistent device identity stored in ~/.crewly/device.json.
 * Used by the relay auto-discovery system to uniquely identify this
 * Crewly installation across sessions and restarts.
 *
 * @module services/cloud/device-identity.service
 */
/**
 * Persistent device identity stored in ~/.crewly/device.json.
 */
export interface DeviceIdentity {
    /** Unique device identifier (UUID v4) */
    deviceId: string;
    /** Human-readable device name (defaults to OS hostname) */
    deviceName: string;
    /** ISO timestamp when the identity was first created */
    createdAt: string;
    /** ISO timestamp of last activity */
    lastSeenAt: string;
}
/**
 * Singleton service that manages device identity for relay auto-discovery.
 *
 * On first run, generates a UUID and captures the OS hostname, persisting
 * both to ~/.crewly/device.json. Subsequent calls read from disk.
 *
 * @example
 * ```typescript
 * const identity = DeviceIdentityService.getInstance();
 * const id = await identity.getOrCreateIdentity();
 * console.log(id.deviceId, id.deviceName);
 * ```
 */
export declare class DeviceIdentityService {
    private static instance;
    private readonly logger;
    private readonly crewlyHome;
    private readonly deviceFilePath;
    private cachedIdentity;
    /**
     * Creates a DeviceIdentityService instance.
     *
     * @param crewlyHome - Override ~/.crewly path (for testing)
     */
    constructor(crewlyHome?: string);
    /**
     * Get the singleton instance.
     *
     * @returns DeviceIdentityService instance
     */
    static getInstance(): DeviceIdentityService;
    /**
     * Reset the singleton (for testing).
     */
    static resetInstance(): void;
    /**
     * Get or create the device identity.
     * Reads from ~/.crewly/device.json if it exists, otherwise creates
     * a new identity with a fresh UUID and the OS hostname.
     *
     * @returns The device identity
     */
    getOrCreateIdentity(): Promise<DeviceIdentity>;
    /**
     * Update the lastSeenAt timestamp on the persisted identity.
     */
    updateLastSeen(): Promise<void>;
    /**
     * Get the device ID string.
     *
     * @returns The device UUID
     */
    getDeviceId(): Promise<string>;
    /**
     * Get the device name string.
     *
     * @returns The device hostname
     */
    getDeviceName(): Promise<string>;
    /**
     * Write identity to disk, ensuring the directory exists.
     *
     * @param identity - The identity to persist
     */
    private persistIdentity;
}
//# sourceMappingURL=device-identity.service.d.ts.map