export interface User { id: string; email: string; name?: string; profilePicture?: string; onboarded?: boolean; createdAt?: string; updatedAt?: string; } export interface DataTier { name?: string; type?: string; description?: string; descriptions?: string; reward?: string; } export type TrainingScreenMode = 'mock' | 'fast' | 'real' | 'none'; export interface TrainingIntent { requestedScopes: string[]; requiresInference: boolean; requiresMbti: boolean; hasInferenceInput: boolean; priority: 'high' | 'normal'; source: 'sdk'; } export interface AuthorizedData { basic: boolean; personality?: boolean; preferences?: boolean; rawMemories?: boolean; fastTraits?: boolean; wrappedTraits?: boolean; } export interface TrainingStatus { ready: boolean; statusUrl?: string; pollIntervalMs?: number; neverTrained?: boolean; lastPayload?: any; regenerationInFlight?: boolean; traitsComplete?: boolean; } export interface OnairosResult { token: string; apiUrl: string; approved: string[]; userData: { email?: string; username?: string; connectedAccounts: string[]; skipped?: boolean; [key: string]: any; }; apiResponse?: any; platformData?: Record; authorizedData?: AuthorizedData; training?: TrainingStatus; } export interface OnairosButtonProps { /** Return link after authentication (used for web-based flows) */ returnLink?: string; /** @deprecated Internal legacy auth prefill. */ prefillUrl?: string; /** Application name to display in dialogs */ AppName: string; /** Button type - 'normal' or 'pill' */ buttonType?: 'normal' | 'pill'; /** Data requests for user consent */ requestData?: any; /** Button width in pixels */ buttonWidth?: number; /** Button height in pixels */ buttonHeight?: number; /** Whether to show stroke/border around button */ hasStroke?: boolean; /** Whether the button is enabled */ enabled?: boolean; /** Button form/shape style */ buttonForm?: 'default' | 'login' | 'signup' | 'connect'; /** Callback when user rejects or cancels */ onRejection?: (reason?: string) => void; /** Callback when authentication completes successfully */ onComplete?: (result: OnairosResult) => void; /** @deprecated Use onComplete(result) instead. */ onResolved?: (apiUrl: string, accessToken: string, data: any) => void; /** Function to check before starting authentication */ preCheck?: () => Promise; /** Button background color */ color?: string; /** @deprecated Internal legacy button effect. */ swerv?: boolean; /** Enable debug mode */ debug?: boolean; /** @deprecated Use priorityPlatform. Kept as a compatibility alias. */ preferredPlatform?: string | string[]; /** Platform to prioritize in the connector/auth flow. */ priorityPlatform?: string | null; /** @deprecated Internal/test-only flow control. Do not use in normal integrations. */ testMode?: boolean; /** Enable dark mode */ darkMode?: boolean; /** @deprecated Internal legacy auto mode; use autoFetch/inferenceData instead. */ auto?: boolean; /** Automatically fetch approved data before onComplete. Defaults to true. */ autoFetch?: boolean; /** If true, effective trainingScreenMode defaults to "none" and training/data loading runs in background. */ backgroundLoadData?: boolean; /** Controls the SDK training/loading UI style. Defaults to "fast", or "none" when backgroundLoadData=true. */ trainingScreenMode?: TrainingScreenMode; /** Inference input payload used for preferences/inference endpoints */ inferenceData?: any; /** App icon to display */ appIcon?: any; /** @deprecated Internal test-only flow control. */ newUser?: boolean; /** @deprecated Internal test-only flow control. */ existingUser?: boolean; /** @deprecated Internal test-only flow control. */ fastTraining?: boolean; fastTraits?: boolean; /** Close the SDK modal after consent. Defaults to true. */ closeOnConsent?: boolean; /** Optional reasoning shown on the insufficient-data training warning. */ insufficientDataReasoning?: string | null; /** Ask backend inference to return MBTI preference output when preferences is approved. */ preferencesMbti?: boolean; primaryAuthOnly?: boolean; useNewWelcomeFlow?: boolean; /** Filter which platforms the SDK may show. */ allowedPlatforms?: string[]; /** Platforms to badge as recommended. */ recommendedPlatforms?: string[]; /** Developer API key for button-level initialization. */ apiKey?: string; /** Internal test-only bypass for API key initialization. */ skipApiKeyInitialization?: boolean; /** Developer app display/routing name. */ webpageName?: string; /** @deprecated Internal backend app id override; normal apps should use AppName/webpageName. */ appId?: string | null; /** Optional signup attribution metadata forwarded to SDK auth endpoints. */ signupAttribution?: Record | string | null; /** Optional custom explainer copy shown before onboarding starts. */ dataUsageDescription?: string; } export interface OnairosProps { /** Return link after authentication (used for web-based flows) */ returnLink?: string; /** @deprecated Internal legacy auth prefill. */ prefillUrl?: string; /** Application name to display in dialogs */ AppName: string; /** Button type - 'normal' or 'pill' */ buttonType?: 'normal' | 'pill'; /** Data requests for user consent */ requestData?: any; /** Button width in pixels */ buttonWidth?: number; /** Button height in pixels */ buttonHeight?: number; /** Whether to show stroke/border around button */ hasStroke?: boolean; /** Whether the button is enabled */ enabled?: boolean; /** Button form/shape style */ buttonForm?: 'default' | 'connect'; /** Callback when user rejects or cancels */ onRejection?: (error?: string) => void; /** Callback when authentication completes successfully. */ onComplete?: (result: OnairosResult) => void; /** @deprecated Use onComplete(result) instead. */ onResolved?: (apiUrl: string, token: string, userData: any) => void; /** Function to check before starting authentication */ preCheck?: () => Promise; /** Button background color */ color?: string; /** Enable debug mode */ debug?: boolean; /** Enable dark mode */ darkMode?: boolean; /** @deprecated Use priorityPlatform. Kept as a compatibility alias. */ preferredPlatform?: string | string[]; /** Platform to prioritize in the connector/auth flow. */ priorityPlatform?: string | null; /** @deprecated Internal/test-only flow control. Do not use in normal integrations. */ testMode?: boolean; /** Automatically fetch approved data before onComplete. Defaults to true. */ autoFetch?: boolean; /** If true, effective trainingScreenMode defaults to "none" and training/data loading runs in background. */ backgroundLoadData?: boolean; /** Controls the SDK training/loading UI style. Defaults to "fast", or "none" when backgroundLoadData=true. */ trainingScreenMode?: TrainingScreenMode; inferenceData?: any; /** API Key Configuration (REQUIRED) */ apiKey: string; /** Environment setting for API calls */ environment?: 'production' | 'staging' | 'development'; /** Enable logging for debugging */ enableLogging?: boolean; /** Request timeout in milliseconds */ timeout?: number; /** Number of retry attempts for failed requests */ retryAttempts?: number; /** If true, uses a reduced chunk cap for faster trait generation. */ fastTraits?: boolean; closeOnConsent?: boolean; /** Optional reasoning shown on the insufficient-data training warning. */ insufficientDataReasoning?: string | null; preferencesMbti?: boolean; primaryAuthOnly?: boolean; useNewWelcomeFlow?: boolean; allowedPlatforms?: string[]; recommendedPlatforms?: string[]; webpageName?: string; /** Optional signup attribution metadata forwarded to SDK auth endpoints. */ signupAttribution?: Record | string | null; /** Optional custom explainer copy shown before onboarding starts. */ dataUsageDescription?: string; } export interface UniversalOnboardingProps { visible: boolean; onClose: () => void; AppName: string; appIcon?: any; requestData?: any; returnLink?: string; onComplete?: (apiUrl: string, token: string, userData: any) => void | Promise; /** @deprecated Use priorityPlatform. Kept as a compatibility alias. */ preferredPlatform?: string | string[]; debug?: boolean; /** @deprecated Internal/test-only flow control. Do not use in normal integrations. */ testMode?: boolean; embedd?: boolean; /** @deprecated Internal test-only flow control. */ newUser?: boolean; /** @deprecated Internal test-only flow control. */ existingUser?: boolean; /** @deprecated Internal test-only flow control. */ fastTraining?: boolean; fastTraits?: boolean; /** Inference data for auto mode */ inferenceData?: any; /** @deprecated Internal legacy auto mode; use autoFetch/inferenceData instead. */ auto?: boolean; /** Automatically fetch approved data before onComplete. Defaults to true. */ autoFetch?: boolean; /** If true, effective trainingScreenMode defaults to "none" and training/data loading runs in background. */ backgroundLoadData?: boolean; /** Controls the SDK training/loading UI style. Defaults to "fast", or "none" when backgroundLoadData=true. */ trainingScreenMode?: TrainingScreenMode; /** @deprecated Internal legacy partner identifier. */ partner?: string; closeOnConsent?: boolean; /** Optional reasoning shown on the insufficient-data training warning. */ insufficientDataReasoning?: string | null; preferencesMbti?: boolean; priorityPlatform?: string | null; primaryAuthOnly?: boolean; useNewWelcomeFlow?: boolean; allowedPlatforms?: string[]; recommendedPlatforms?: string[]; /** @deprecated Internal backend app id override; normal apps should use AppName/webpageName. */ appId?: string | null; webpageName?: string; /** Optional signup attribution metadata forwarded to SDK auth endpoints. */ signupAttribution?: Record | string | null; /** Optional custom explainer copy shown before onboarding starts. */ dataUsageDescription?: string; } export interface PlatformListProps { connections: { [key: string]: boolean; }; onToggle: (platform: string, connect: boolean) => Promise; isLoading: boolean; canProceed: boolean; onProceed: () => void; } export interface PinInputProps { onSubmit: (pin: string) => void; minLength?: number; requireSpecialChar?: boolean; requireNumber?: boolean; initialPin?: string; } export interface TrainingModalProps { visible: boolean; progress: number; eta: string; onCancel: () => void; onComplete?: () => void; modelKey?: string; username?: string; /** @deprecated Internal test-only simulation flag. */ test?: boolean; } export interface OAuthWebViewProps { url: string; platform: string; onComplete: () => void; onClose: () => void; } export interface CredentialsResult { isValid: boolean; credentials?: { username?: string; userPin?: string; accessToken?: string; pinterest?: { token: string; username: string; }; }; } export interface OverlayProps { visible: boolean; onClose: () => void; credentials: any; onDeleteCredentials: () => void; } export interface ConnectionStatus { [key: string]: boolean; } export interface PlatformConfig { name: string; icon: string; color: string; description?: string; } export interface ApiResponse { success: boolean; data?: T; error?: string; } export interface PlatformAuthConfig { hasNativeSDK: boolean; nativeSDKPackage?: string; authEndpoint: string; color: string; clientId?: string; iosClientId?: string; redirectUri?: string; scope?: string; responseType?: string; } export interface PinRequirements { minLength: number; requireSpecialChar: boolean; requireNumber: boolean; } export interface OnairosConfig { apiKey: string; environment?: 'production' | 'staging' | 'development'; enableLogging?: boolean; timeout?: number; retryAttempts?: number; } export interface TestModeOptions { /** @deprecated Internal test-only flow control. */ skipEmailVerification?: boolean; /** @deprecated Internal test-only flow control. */ mockApiResponses?: boolean; /** @deprecated Internal test-only flow control. */ simulateTraining?: boolean; /** @deprecated Internal test-only flow control. */ enableDebugLogs?: boolean; } export interface WelcomeScreenProps { visible: boolean; onClose: () => void; onComplete?: (token: string, email?: string) => void; } export interface OnairosCredentials { username?: string; userPin?: string; accessToken?: string; pinterest?: { token: string; username: string; }; youtube?: { token: string; username: string; }; linkedin?: { token: string; username: string; }; reddit?: { token: string; username: string; }; gmail?: { token: string; username: string; }; } //# sourceMappingURL=index.d.ts.map