/** * @octomil/browser — Device context for silent registration * * Tracks installation identity, registration state, and auth tokens * for the device registration flow. Uses crypto.randomUUID() for * installation IDs (NOT browser fingerprinting) and persists to * localStorage where available. */ export type RegistrationState = "pending" | "registered" | "failed"; export type TokenState = { type: "none"; } | { type: "valid"; accessToken: string; expiresAt: Date; } | { type: "expired"; }; export declare class DeviceContext { readonly installationId: string; readonly orgId: string | null; readonly appId: string | null; private _registrationState; private _tokenState; private _serverDeviceId; constructor(opts: { installationId: string; orgId?: string | null; appId?: string | null; }); get registrationState(): RegistrationState; get tokenState(): TokenState; get serverDeviceId(): string | null; get isRegistered(): boolean; authHeaders(): Record | null; telemetryResource(): Record; /** @internal */ _updateRegistered(serverDeviceId: string, accessToken: string, expiresAt: Date): void; /** @internal */ _updateToken(accessToken: string, expiresAt: Date): void; /** @internal */ _markFailed(): void; /** @internal */ _markTokenExpired(): void; private static readonly STORAGE_KEY; static getOrCreateInstallationId(): string; } //# sourceMappingURL=device-context.d.ts.map