@onairos/react-native 3.4.0 → 3.5.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +62 -13
- package/lib/commonjs/api/index.js +9 -145
- package/lib/commonjs/assets/animations/loaderani.json +1 -0
- package/lib/commonjs/assets/animations/persona-animation.json +1 -0
- package/lib/commonjs/assets/fonts/EBGaramond-VariableFont_wght.ttf +0 -0
- package/lib/commonjs/assets/fonts/IBMPlexSans-VariableFont_wdth,wght.ttf +0 -0
- package/lib/commonjs/assets/icons/Facebookicon.png +0 -0
- package/lib/commonjs/assets/icons/Gmail.png +0 -0
- package/lib/commonjs/assets/icons/Linkedinicon.png +0 -0
- package/lib/commonjs/assets/icons/Redditicon.png +0 -0
- package/lib/commonjs/assets/icons/YouTubeicon2.png +0 -0
- package/lib/commonjs/assets/icons/YouTubeicon3.png +0 -0
- package/lib/commonjs/assets/icons/chatgpt.png +0 -0
- package/lib/commonjs/assets/icons/claude.png +0 -0
- package/lib/commonjs/assets/icons/gemini.png +0 -0
- package/lib/commonjs/assets/icons/grok.png +0 -0
- package/lib/commonjs/assets/images/Checkbox.svg +3 -0
- package/lib/commonjs/assets/images/EnochE.svg +19 -0
- package/lib/commonjs/assets/images/Enochicon1.png +0 -0
- package/lib/commonjs/assets/images/Face_ID_logo.png +0 -0
- package/lib/commonjs/assets/images/Facebookicon.png +0 -0
- package/lib/commonjs/assets/images/Gmail.png +0 -0
- package/lib/commonjs/assets/images/Googlelogo.png +0 -0
- package/lib/commonjs/assets/images/Linkedinicon.png +0 -0
- package/lib/commonjs/assets/images/Onairoslogo.png +0 -0
- package/lib/commonjs/assets/images/Personalityprofile.svg +3 -0
- package/lib/commonjs/assets/images/Personalitytraits.svg +3 -0
- package/lib/commonjs/assets/images/Redditicon.png +0 -0
- package/lib/commonjs/assets/images/Userpreferences.svg +3 -0
- package/lib/commonjs/assets/images/YouTubeicon3.png +0 -0
- package/lib/commonjs/assets/images/arrow.svg +20 -0
- package/lib/commonjs/assets/images/basicproficon.svg +43 -0
- package/lib/commonjs/assets/images/basicprofile.svg +3 -0
- package/lib/commonjs/assets/images/chatgpt.png +0 -0
- package/lib/commonjs/assets/images/checkmark.svg +4 -0
- package/lib/commonjs/assets/images/claude.png +0 -0
- package/lib/commonjs/assets/images/contentanalysis.svg +3 -0
- package/lib/commonjs/assets/images/contenticon.svg +23 -0
- package/lib/commonjs/assets/images/gemini.png +0 -0
- package/lib/commonjs/assets/images/grok.png +0 -0
- package/lib/commonjs/assets/images/persona1.png +0 -0
- package/lib/commonjs/assets/images/persona2.png +0 -0
- package/lib/commonjs/assets/images/persona3.png +0 -0
- package/lib/commonjs/assets/images/persona4.png +0 -0
- package/lib/commonjs/assets/images/persona5.png +0 -0
- package/lib/commonjs/assets/images/personalityicon.svg +18 -0
- package/lib/commonjs/assets/images/x-close.svg +3 -0
- package/lib/commonjs/components/BodyText.js +9 -0
- package/lib/commonjs/components/BrandMark.js +10 -0
- package/lib/commonjs/components/CodeInput.js +9 -0
- package/lib/commonjs/components/EmailInput.js +8 -0
- package/lib/commonjs/components/GoogleButton.js +9 -0
- package/lib/commonjs/components/HeadingGroup.js +9 -0
- package/lib/commonjs/components/LLMDataInputModal.js +14 -0
- package/lib/commonjs/components/ModalHeader.js +9 -0
- package/lib/commonjs/components/ModalSheet.js +9 -0
- package/lib/commonjs/components/Onairos.js +14 -374
- package/lib/commonjs/components/OnairosButton.js +13 -309
- package/lib/commonjs/components/OnairosSignInButton.js +12 -0
- package/lib/commonjs/components/Overlay.js +13 -483
- package/lib/commonjs/components/PersonaImage.js +10 -0
- package/lib/commonjs/components/PersonaLoadingScreen.js +12 -0
- package/lib/commonjs/components/PersonalizationConsentScreen.js +13 -0
- package/lib/commonjs/components/PinCreationScreen.js +12 -0
- package/lib/commonjs/components/PinInput.js +9 -302
- package/lib/commonjs/components/PlatformConnectorsStep.js +22 -0
- package/lib/commonjs/components/PlatformList.js +10 -137
- package/lib/commonjs/components/PlatformToggle.js +9 -0
- package/lib/commonjs/components/PrimaryButton.js +10 -0
- package/lib/commonjs/components/SignInMatchAnimation.js +9 -0
- package/lib/commonjs/components/SignInStep.js +12 -0
- package/lib/commonjs/components/UniversalOnboarding.js +29 -1702
- package/lib/commonjs/components/VerificationStep.js +11 -0
- package/lib/commonjs/components/WelcomeScreen.js +21 -0
- package/lib/commonjs/components/icons/Basicproficon.js +8 -0
- package/lib/commonjs/components/icons/Basicprofile.js +8 -0
- package/lib/commonjs/components/icons/Checkbox.js +8 -0
- package/lib/commonjs/components/icons/Checkmark.js +8 -0
- package/lib/commonjs/components/icons/Contentanalysis.js +8 -0
- package/lib/commonjs/components/icons/Contenticon.js +8 -0
- package/lib/commonjs/components/icons/EnochE.js +8 -0
- package/lib/commonjs/components/icons/Personalityicon.js +8 -0
- package/lib/commonjs/components/icons/Personalityprofile.js +8 -0
- package/lib/commonjs/components/icons/Personalitytraits.js +8 -0
- package/lib/commonjs/components/icons/Userpreferences.js +8 -0
- package/lib/commonjs/components/icons/index.js +17 -0
- package/lib/commonjs/components/onboarding/OAuthWebView.js +14 -827
- package/lib/commonjs/components/onboarding/OnboardingHeader.js +10 -74
- package/lib/commonjs/components/onboarding/PinInput.js +10 -283
- package/lib/commonjs/components/onboarding/PlatformConnector.js +11 -249
- package/lib/commonjs/config/api.js +7 -0
- package/lib/commonjs/constants/index.js +7 -83
- package/lib/commonjs/context/AuthContext.js +10 -0
- package/lib/commonjs/hooks/useConnectedAccounts.js +9 -0
- package/lib/commonjs/hooks/useConnections.js +8 -159
- package/lib/commonjs/hooks/useCredentials.js +10 -177
- package/lib/commonjs/hooks/useUserConnections.js +10 -0
- package/lib/commonjs/index.js +35 -106
- package/lib/commonjs/services/SDK_API_KEY_VALIDATION.md +31 -38
- package/lib/commonjs/services/apiClient.js +8 -0
- package/lib/commonjs/services/apiKeyService.js +9 -946
- package/lib/commonjs/services/authService.js +10 -0
- package/lib/commonjs/services/biometricPinService.js +8 -0
- package/lib/commonjs/services/chatGPTConversationExtractor.js +8 -0
- package/lib/commonjs/services/chatGPTConversationService.js +9 -0
- package/lib/commonjs/services/claudeConversationExtractor.js +8 -0
- package/lib/commonjs/services/claudeConversationService.js +9 -0
- package/lib/commonjs/services/connectedAccountsService.js +10 -0
- package/lib/commonjs/services/googleAuthService.js +11 -0
- package/lib/commonjs/services/imageCompressionService.js +7 -0
- package/lib/commonjs/services/jwtStorageService.js +7 -0
- package/lib/commonjs/services/linkedinDOMExtractor.js +7 -0
- package/lib/commonjs/services/linkedinProfileService.js +9 -0
- package/lib/commonjs/services/linkedinScrapingService.js +8 -0
- package/lib/commonjs/services/llmDataStorage.js +8 -0
- package/lib/commonjs/services/mobileTrainingService.js +8 -0
- package/lib/commonjs/services/oauthService.js +11 -390
- package/lib/commonjs/services/pinEncryptionService.js +8 -0
- package/lib/commonjs/services/pinStorageUtils.js +7 -0
- package/lib/commonjs/services/platformAuthService.js +12 -1067
- package/lib/commonjs/services/storageService.js +8 -0
- package/lib/commonjs/services/trainingApiHelpers.js +7 -0
- package/lib/commonjs/services/userConnectionsService.js +10 -0
- package/lib/commonjs/services/youtubeMigrationService.js +10 -0
- package/lib/commonjs/theme/index.js +7 -0
- package/lib/commonjs/types/ambient.d.js +1 -2
- package/lib/commonjs/types/declarations.d.js +1 -2
- package/lib/commonjs/types/index.js +1 -6
- package/lib/commonjs/types/node-fix.d.js +1 -2
- package/lib/commonjs/types/node-override.d.js +1 -2
- package/lib/commonjs/types/opacity.d.js +1 -2
- package/lib/commonjs/types.js +1 -14
- package/lib/commonjs/utils/Portal.js +8 -98
- package/lib/commonjs/utils/api.js +9 -129
- package/lib/commonjs/utils/assetRegistry.js +33 -0
- package/lib/commonjs/utils/auth.js +9 -111
- package/lib/commonjs/utils/crypto.js +8 -62
- package/lib/commonjs/utils/debugHelper.js +1 -64
- package/lib/commonjs/utils/encryption.js +7 -76
- package/lib/commonjs/utils/eventUtils.js +1 -0
- package/lib/commonjs/utils/haptics.js +9 -0
- package/lib/commonjs/utils/imagePreloader.js +1 -0
- package/lib/commonjs/utils/networkDiagnostics.js +8 -0
- package/lib/commonjs/utils/onairosApi.js +9 -350
- package/lib/commonjs/utils/programmaticFlow.js +9 -117
- package/lib/commonjs/utils/retryHelper.js +1 -220
- package/lib/commonjs/utils/secureStorage.js +10 -349
- package/lib/commonjs/utils/webviewScripts/chatgpt.js +1 -0
- package/lib/commonjs/utils/webviewScripts/claude.js +1 -0
- package/lib/commonjs/utils/webviewScripts/index.js +9 -0
- package/lib/commonjs/utils/webviewScripts/linkedin.js +1 -0
- package/lib/module/api/index.js +1 -139
- package/lib/module/assets/animations/loaderani.json +1 -0
- package/lib/module/assets/animations/persona-animation.json +1 -0
- package/lib/module/assets/fonts/EBGaramond-VariableFont_wght.ttf +0 -0
- package/lib/module/assets/fonts/IBMPlexSans-VariableFont_wdth,wght.ttf +0 -0
- package/lib/module/assets/icons/Facebookicon.png +0 -0
- package/lib/module/assets/icons/Gmail.png +0 -0
- package/lib/module/assets/icons/Linkedinicon.png +0 -0
- package/lib/module/assets/icons/Redditicon.png +0 -0
- package/lib/module/assets/icons/YouTubeicon2.png +0 -0
- package/lib/module/assets/icons/YouTubeicon3.png +0 -0
- package/lib/module/assets/icons/chatgpt.png +0 -0
- package/lib/module/assets/icons/claude.png +0 -0
- package/lib/module/assets/icons/farcaster.png +0 -0
- package/lib/module/assets/icons/gemini.png +0 -0
- package/lib/module/assets/icons/grok.png +0 -0
- package/lib/module/assets/icons/instagram.png +0 -0
- package/lib/module/assets/icons/pinterest.png +0 -0
- package/lib/module/assets/icons/swerv_logo.png +0 -0
- package/lib/module/assets/icons/twitter.jpg +0 -0
- package/lib/module/assets/images/Checkbox.svg +3 -0
- package/lib/module/assets/images/EnochE.svg +19 -0
- package/lib/module/assets/images/Enochicon1.png +0 -0
- package/lib/module/assets/images/Face_ID_logo.png +0 -0
- package/lib/module/assets/images/Facebookicon.png +0 -0
- package/lib/module/assets/images/Gmail.png +0 -0
- package/lib/module/assets/images/Googlelogo.png +0 -0
- package/lib/module/assets/images/Linkedinicon.png +0 -0
- package/lib/module/assets/images/Onairoslogo.png +0 -0
- package/lib/module/assets/images/Personalityprofile.svg +3 -0
- package/lib/module/assets/images/Personalitytraits.svg +3 -0
- package/lib/module/assets/images/Redditicon.png +0 -0
- package/lib/module/assets/images/Userpreferences.svg +3 -0
- package/lib/module/assets/images/YouTubeicon3.png +0 -0
- package/lib/module/assets/images/arrow.svg +20 -0
- package/lib/module/assets/images/basicproficon.svg +43 -0
- package/lib/module/assets/images/basicprofile.svg +3 -0
- package/lib/module/assets/images/chatgpt.png +0 -0
- package/lib/module/assets/images/checkmark.svg +4 -0
- package/lib/module/assets/images/claude.png +0 -0
- package/lib/module/assets/images/contentanalysis.svg +3 -0
- package/lib/module/assets/images/contenticon.svg +23 -0
- package/lib/module/assets/images/gemini.png +0 -0
- package/lib/module/assets/images/grok.png +0 -0
- package/lib/module/assets/images/persona1.png +0 -0
- package/lib/module/assets/images/persona2.png +0 -0
- package/lib/module/assets/images/persona3.png +0 -0
- package/lib/module/assets/images/persona4.png +0 -0
- package/lib/module/assets/images/persona5.png +0 -0
- package/lib/module/assets/images/personalityicon.svg +18 -0
- package/lib/module/assets/images/x-close.svg +3 -0
- package/lib/module/components/BodyText.js +1 -0
- package/lib/module/components/BrandMark.js +1 -0
- package/lib/module/components/CodeInput.js +1 -0
- package/lib/module/components/EmailInput.js +1 -0
- package/lib/module/components/GoogleButton.js +1 -0
- package/lib/module/components/HeadingGroup.js +1 -0
- package/lib/module/components/LLMDataInputModal.js +8 -0
- package/lib/module/components/ModalHeader.js +1 -0
- package/lib/module/components/ModalSheet.js +1 -0
- package/lib/module/components/Onairos.js +1 -367
- package/lib/module/components/OnairosButton.js +1 -302
- package/lib/module/components/OnairosSignInButton.js +1 -0
- package/lib/module/components/Overlay.js +1 -474
- package/lib/module/components/PersonaImage.js +1 -0
- package/lib/module/components/PersonaLoadingScreen.js +1 -0
- package/lib/module/components/PersonalizationConsentScreen.js +1 -0
- package/lib/module/components/PinCreationScreen.js +1 -0
- package/lib/module/components/PinInput.js +1 -293
- package/lib/module/components/PlatformConnectorsStep.js +1 -0
- package/lib/module/components/PlatformList.js +1 -129
- package/lib/module/components/PlatformToggle.js +1 -0
- package/lib/module/components/PrimaryButton.js +1 -0
- package/lib/module/components/SignInMatchAnimation.js +1 -0
- package/lib/module/components/SignInStep.js +1 -0
- package/lib/module/components/UniversalOnboarding.js +1 -1693
- package/lib/module/components/VerificationStep.js +1 -0
- package/lib/module/components/WelcomeScreen.js +1 -0
- package/lib/module/components/icons/Basicproficon.js +1 -0
- package/lib/module/components/icons/Basicprofile.js +1 -0
- package/lib/module/components/icons/Checkbox.js +1 -0
- package/lib/module/components/icons/Checkmark.js +1 -0
- package/lib/module/components/icons/Contentanalysis.js +1 -0
- package/lib/module/components/icons/Contenticon.js +1 -0
- package/lib/module/components/icons/EnochE.js +1 -0
- package/lib/module/components/icons/Personalityicon.js +1 -0
- package/lib/module/components/icons/Personalityprofile.js +1 -0
- package/lib/module/components/icons/Personalitytraits.js +1 -0
- package/lib/module/components/icons/Userpreferences.js +1 -0
- package/lib/module/components/icons/index.js +1 -0
- package/lib/module/components/onboarding/OAuthWebView.js +1 -818
- package/lib/module/components/onboarding/OnboardingHeader.js +1 -66
- package/lib/module/components/onboarding/PinInput.js +1 -274
- package/lib/module/components/onboarding/PlatformConnector.js +1 -240
- package/lib/module/config/api.js +1 -0
- package/lib/module/constants/index.js +1 -77
- package/lib/module/context/AuthContext.js +1 -0
- package/lib/module/hooks/useConnectedAccounts.js +1 -0
- package/lib/module/hooks/useConnections.js +1 -152
- package/lib/module/hooks/useCredentials.js +6 -169
- package/lib/module/hooks/useUserConnections.js +1 -0
- package/lib/module/index.js +1 -32
- package/lib/module/services/SDK_API_KEY_VALIDATION.md +31 -38
- package/lib/module/services/apiClient.js +1 -0
- package/lib/module/services/apiKeyService.js +1 -919
- package/lib/module/services/authService.js +1 -0
- package/lib/module/services/biometricPinService.js +1 -0
- package/lib/module/services/chatGPTConversationExtractor.js +1 -0
- package/lib/module/services/chatGPTConversationService.js +1 -0
- package/lib/module/services/claudeConversationExtractor.js +1 -0
- package/lib/module/services/claudeConversationService.js +1 -0
- package/lib/module/services/connectedAccountsService.js +1 -0
- package/lib/module/services/googleAuthService.js +1 -0
- package/lib/module/services/imageCompressionService.js +1 -0
- package/lib/module/services/jwtStorageService.js +1 -0
- package/lib/module/services/linkedinDOMExtractor.js +1 -0
- package/lib/module/services/linkedinProfileService.js +1 -0
- package/lib/module/services/linkedinScrapingService.js +1 -0
- package/lib/module/services/llmDataStorage.js +1 -0
- package/lib/module/services/mobileTrainingService.js +1 -0
- package/lib/module/services/oauthService.js +1 -380
- package/lib/module/services/pinEncryptionService.js +7 -0
- package/lib/module/services/pinStorageUtils.js +1 -0
- package/lib/module/services/platformAuthService.js +1 -1041
- package/lib/module/services/storageService.js +1 -0
- package/lib/module/services/trainingApiHelpers.js +1 -0
- package/lib/module/services/userConnectionsService.js +1 -0
- package/lib/module/services/youtubeMigrationService.js +1 -0
- package/lib/module/theme/index.js +1 -0
- package/lib/module/types.js +1 -10
- package/lib/module/utils/Portal.js +1 -90
- package/lib/module/utils/api.js +1 -117
- package/lib/module/utils/assetRegistry.js +33 -0
- package/lib/module/utils/auth.js +1 -99
- package/lib/module/utils/crypto.js +1 -54
- package/lib/module/utils/debugHelper.js +1 -54
- package/lib/module/utils/encryption.js +1 -67
- package/lib/module/utils/eventUtils.js +1 -0
- package/lib/module/utils/haptics.js +8 -0
- package/lib/module/utils/imagePreloader.js +1 -0
- package/lib/module/utils/networkDiagnostics.js +1 -0
- package/lib/module/utils/onairosApi.js +1 -333
- package/lib/module/utils/programmaticFlow.js +1 -111
- package/lib/module/utils/retryHelper.js +1 -211
- package/lib/module/utils/secureStorage.js +6 -330
- package/lib/module/utils/webviewScripts/chatgpt.js +1 -0
- package/lib/module/utils/webviewScripts/claude.js +1 -0
- package/lib/module/utils/webviewScripts/index.js +1 -0
- package/lib/module/utils/webviewScripts/linkedin.js +1 -0
- package/package.json +62 -39
- package/lib/commonjs/api/index.js.map +0 -1
- package/lib/commonjs/assets/images/email.png +0 -0
- package/lib/commonjs/assets/images/linkedin.png +0 -0
- package/lib/commonjs/assets/images/reddit.png +0 -0
- package/lib/commonjs/assets/images/youtube.png +0 -0
- package/lib/commonjs/components/DataRequestModal.js +0 -228
- package/lib/commonjs/components/DataRequestModal.js.map +0 -1
- package/lib/commonjs/components/DataRequestScreen.js +0 -329
- package/lib/commonjs/components/DataRequestScreen.js.map +0 -1
- package/lib/commonjs/components/EmailVerificationModal.js +0 -320
- package/lib/commonjs/components/EmailVerificationModal.js.map +0 -1
- package/lib/commonjs/components/Onairos.js.map +0 -1
- package/lib/commonjs/components/OnairosButton.js.map +0 -1
- package/lib/commonjs/components/Overlay.js.map +0 -1
- package/lib/commonjs/components/PinInput.js.map +0 -1
- package/lib/commonjs/components/PlatformList.js.map +0 -1
- package/lib/commonjs/components/TrainingModal.js +0 -717
- package/lib/commonjs/components/TrainingModal.js.map +0 -1
- package/lib/commonjs/components/UniversalOnboarding.js.map +0 -1
- package/lib/commonjs/components/UniversalOnboarding.tsx.new +0 -455
- package/lib/commonjs/components/onboarding/OAuthWebView.js.map +0 -1
- package/lib/commonjs/components/onboarding/OnboardingHeader.js.map +0 -1
- package/lib/commonjs/components/onboarding/PinInput.js.map +0 -1
- package/lib/commonjs/components/onboarding/PlatformConnector.js.map +0 -1
- package/lib/commonjs/components/screens/ConnectorScreen.js +0 -146
- package/lib/commonjs/components/screens/ConnectorScreen.js.map +0 -1
- package/lib/commonjs/components/screens/LoadingScreen.js +0 -91
- package/lib/commonjs/components/screens/LoadingScreen.js.map +0 -1
- package/lib/commonjs/components/screens/PinCreationScreen.js +0 -61
- package/lib/commonjs/components/screens/PinCreationScreen.js.map +0 -1
- package/lib/commonjs/constants/index.js.map +0 -1
- package/lib/commonjs/hooks/useConnections.js.map +0 -1
- package/lib/commonjs/hooks/useCredentials.js.map +0 -1
- package/lib/commonjs/index.js.map +0 -1
- package/lib/commonjs/services/apiKeyService.js.map +0 -1
- package/lib/commonjs/services/oauthService.js.map +0 -1
- package/lib/commonjs/services/platformAuthService.js.map +0 -1
- package/lib/commonjs/types/ambient.d.js.map +0 -1
- package/lib/commonjs/types/declarations.d.js.map +0 -1
- package/lib/commonjs/types/index.d.js.map +0 -1
- package/lib/commonjs/types/index.js.map +0 -1
- package/lib/commonjs/types/node-fix.d.js.map +0 -1
- package/lib/commonjs/types/node-override.d.js.map +0 -1
- package/lib/commonjs/types/opacity.d.js.map +0 -1
- package/lib/commonjs/types/types.d.js.map +0 -1
- package/lib/commonjs/types.js.map +0 -1
- package/lib/commonjs/utils/Portal.js.map +0 -1
- package/lib/commonjs/utils/api.js.map +0 -1
- package/lib/commonjs/utils/auth.js.map +0 -1
- package/lib/commonjs/utils/crypto.js.map +0 -1
- package/lib/commonjs/utils/debugHelper.js.map +0 -1
- package/lib/commonjs/utils/encryption.js.map +0 -1
- package/lib/commonjs/utils/onairosApi.js.map +0 -1
- package/lib/commonjs/utils/programmaticFlow.js.map +0 -1
- package/lib/commonjs/utils/retryHelper.js.map +0 -1
- package/lib/commonjs/utils/secureStorage.js.map +0 -1
- package/lib/module/api/index.js.map +0 -1
- package/lib/module/assets/images/email.png +0 -0
- package/lib/module/assets/images/linkedin.png +0 -0
- package/lib/module/assets/images/reddit.png +0 -0
- package/lib/module/assets/images/youtube.png +0 -0
- package/lib/module/components/DataRequestModal.js +0 -220
- package/lib/module/components/DataRequestModal.js.map +0 -1
- package/lib/module/components/DataRequestScreen.js +0 -321
- package/lib/module/components/DataRequestScreen.js.map +0 -1
- package/lib/module/components/EmailVerificationModal.js +0 -311
- package/lib/module/components/EmailVerificationModal.js.map +0 -1
- package/lib/module/components/Onairos.js.map +0 -1
- package/lib/module/components/OnairosButton.js.map +0 -1
- package/lib/module/components/Overlay.js.map +0 -1
- package/lib/module/components/PinInput.js.map +0 -1
- package/lib/module/components/PlatformList.js.map +0 -1
- package/lib/module/components/TrainingModal.js +0 -708
- package/lib/module/components/TrainingModal.js.map +0 -1
- package/lib/module/components/UniversalOnboarding.js.map +0 -1
- package/lib/module/components/UniversalOnboarding.tsx.new +0 -455
- package/lib/module/components/onboarding/OAuthWebView.js.map +0 -1
- package/lib/module/components/onboarding/OnboardingHeader.js.map +0 -1
- package/lib/module/components/onboarding/PinInput.js.map +0 -1
- package/lib/module/components/onboarding/PlatformConnector.js.map +0 -1
- package/lib/module/components/screens/ConnectorScreen.js +0 -138
- package/lib/module/components/screens/ConnectorScreen.js.map +0 -1
- package/lib/module/components/screens/LoadingScreen.js +0 -83
- package/lib/module/components/screens/LoadingScreen.js.map +0 -1
- package/lib/module/components/screens/PinCreationScreen.js +0 -53
- package/lib/module/components/screens/PinCreationScreen.js.map +0 -1
- package/lib/module/constants/index.js.map +0 -1
- package/lib/module/hooks/useConnections.js.map +0 -1
- package/lib/module/hooks/useCredentials.js.map +0 -1
- package/lib/module/index.js.map +0 -1
- package/lib/module/services/apiKeyService.js.map +0 -1
- package/lib/module/services/oauthService.js.map +0 -1
- package/lib/module/services/platformAuthService.js.map +0 -1
- package/lib/module/types/ambient.d.js.map +0 -1
- package/lib/module/types/declarations.d.js.map +0 -1
- package/lib/module/types/index.d.js.map +0 -1
- package/lib/module/types/index.js.map +0 -1
- package/lib/module/types/node-fix.d.js.map +0 -1
- package/lib/module/types/node-override.d.js.map +0 -1
- package/lib/module/types/opacity.d.js.map +0 -1
- package/lib/module/types/types.d.js.map +0 -1
- package/lib/module/types.js.map +0 -1
- package/lib/module/utils/Portal.js.map +0 -1
- package/lib/module/utils/api.js.map +0 -1
- package/lib/module/utils/auth.js.map +0 -1
- package/lib/module/utils/crypto.js.map +0 -1
- package/lib/module/utils/debugHelper.js.map +0 -1
- package/lib/module/utils/encryption.js.map +0 -1
- package/lib/module/utils/onairosApi.js.map +0 -1
- package/lib/module/utils/programmaticFlow.js.map +0 -1
- package/lib/module/utils/retryHelper.js.map +0 -1
- package/lib/module/utils/secureStorage.js.map +0 -1
- package/lib/typescript/api/index.d.ts +0 -8
- package/lib/typescript/api/index.d.ts.map +0 -1
- package/lib/typescript/components/DataRequestModal.d.ts +0 -11
- package/lib/typescript/components/DataRequestModal.d.ts.map +0 -1
- package/lib/typescript/components/DataRequestScreen.d.ts +0 -11
- package/lib/typescript/components/DataRequestScreen.d.ts.map +0 -1
- package/lib/typescript/components/EmailVerificationModal.d.ts +0 -11
- package/lib/typescript/components/EmailVerificationModal.d.ts.map +0 -1
- package/lib/typescript/components/Onairos.d.ts +0 -4
- package/lib/typescript/components/Onairos.d.ts.map +0 -1
- package/lib/typescript/components/OnairosButton.d.ts +0 -12
- package/lib/typescript/components/OnairosButton.d.ts.map +0 -1
- package/lib/typescript/components/Overlay.d.ts +0 -4
- package/lib/typescript/components/Overlay.d.ts.map +0 -1
- package/lib/typescript/components/PinInput.d.ts +0 -4
- package/lib/typescript/components/PinInput.d.ts.map +0 -1
- package/lib/typescript/components/PlatformList.d.ts +0 -4
- package/lib/typescript/components/PlatformList.d.ts.map +0 -1
- package/lib/typescript/components/TrainingModal.d.ts +0 -4
- package/lib/typescript/components/TrainingModal.d.ts.map +0 -1
- package/lib/typescript/components/UniversalOnboarding.d.ts +0 -4
- package/lib/typescript/components/UniversalOnboarding.d.ts.map +0 -1
- package/lib/typescript/components/onboarding/OAuthWebView.d.ts +0 -10
- package/lib/typescript/components/onboarding/OAuthWebView.d.ts.map +0 -1
- package/lib/typescript/components/onboarding/OnboardingHeader.d.ts +0 -11
- package/lib/typescript/components/onboarding/OnboardingHeader.d.ts.map +0 -1
- package/lib/typescript/components/onboarding/PinInput.d.ts +0 -4
- package/lib/typescript/components/onboarding/PinInput.d.ts.map +0 -1
- package/lib/typescript/components/onboarding/PlatformConnector.d.ts +0 -13
- package/lib/typescript/components/onboarding/PlatformConnector.d.ts.map +0 -1
- package/lib/typescript/components/screens/ConnectorScreen.d.ts +0 -9
- package/lib/typescript/components/screens/ConnectorScreen.d.ts.map +0 -1
- package/lib/typescript/components/screens/LoadingScreen.d.ts +0 -9
- package/lib/typescript/components/screens/LoadingScreen.d.ts.map +0 -1
- package/lib/typescript/components/screens/PinCreationScreen.d.ts +0 -10
- package/lib/typescript/components/screens/PinCreationScreen.d.ts.map +0 -1
- package/lib/typescript/constants/index.d.ts +0 -53
- package/lib/typescript/constants/index.d.ts.map +0 -1
- package/lib/typescript/hooks/useConnections.d.ts +0 -9
- package/lib/typescript/hooks/useConnections.d.ts.map +0 -1
- package/lib/typescript/hooks/useCredentials.d.ts +0 -9
- package/lib/typescript/hooks/useCredentials.d.ts.map +0 -1
- package/lib/typescript/index.d.ts +0 -18
- package/lib/typescript/index.d.ts.map +0 -1
- package/lib/typescript/services/apiKeyService.d.ts +0 -132
- package/lib/typescript/services/apiKeyService.d.ts.map +0 -1
- package/lib/typescript/services/oauthService.d.ts +0 -50
- package/lib/typescript/services/oauthService.d.ts.map +0 -1
- package/lib/typescript/services/platformAuthService.d.ts +0 -144
- package/lib/typescript/services/platformAuthService.d.ts.map +0 -1
- package/lib/typescript/types/index.d.ts +0 -231
- package/lib/typescript/types/index.d.ts.map +0 -1
- package/lib/typescript/types.d.ts +0 -270
- package/lib/typescript/types.d.ts.map +0 -1
- package/lib/typescript/utils/Portal.d.ts +0 -14
- package/lib/typescript/utils/Portal.d.ts.map +0 -1
- package/lib/typescript/utils/api.d.ts +0 -6
- package/lib/typescript/utils/api.d.ts.map +0 -1
- package/lib/typescript/utils/auth.d.ts +0 -6
- package/lib/typescript/utils/auth.d.ts.map +0 -1
- package/lib/typescript/utils/crypto.d.ts +0 -4
- package/lib/typescript/utils/crypto.d.ts.map +0 -1
- package/lib/typescript/utils/debugHelper.d.ts +0 -29
- package/lib/typescript/utils/debugHelper.d.ts.map +0 -1
- package/lib/typescript/utils/encryption.d.ts +0 -19
- package/lib/typescript/utils/encryption.d.ts.map +0 -1
- package/lib/typescript/utils/onairosApi.d.ts +0 -87
- package/lib/typescript/utils/onairosApi.d.ts.map +0 -1
- package/lib/typescript/utils/programmaticFlow.d.ts +0 -23
- package/lib/typescript/utils/programmaticFlow.d.ts.map +0 -1
- package/lib/typescript/utils/retryHelper.d.ts +0 -69
- package/lib/typescript/utils/retryHelper.d.ts.map +0 -1
- package/lib/typescript/utils/secureStorage.d.ts +0 -94
- package/lib/typescript/utils/secureStorage.d.ts.map +0 -1
- package/src/api/index.ts +0 -111
- package/src/assets/images/email.png +0 -0
- package/src/assets/images/linkedin.png +0 -0
- package/src/assets/images/onairos_logo.png +0 -0
- package/src/assets/images/reddit.png +0 -0
- package/src/assets/images/youtube.png +0 -0
- package/src/components/DataRequestModal.tsx +0 -227
- package/src/components/DataRequestScreen.tsx +0 -356
- package/src/components/EmailVerificationModal.tsx +0 -364
- package/src/components/Onairos.tsx +0 -425
- package/src/components/OnairosButton.tsx +0 -359
- package/src/components/Overlay.tsx +0 -506
- package/src/components/PinInput.tsx +0 -343
- package/src/components/PlatformList.tsx +0 -145
- package/src/components/TrainingModal.tsx +0 -737
- package/src/components/UniversalOnboarding.tsx +0 -1839
- package/src/components/UniversalOnboarding.tsx.new +0 -455
- package/src/components/onboarding/OAuthWebView.tsx +0 -838
- package/src/components/onboarding/OnboardingHeader.tsx +0 -70
- package/src/components/onboarding/PinInput.tsx +0 -356
- package/src/components/onboarding/PlatformConnector.tsx +0 -302
- package/src/components/screens/ConnectorScreen.tsx +0 -153
- package/src/components/screens/LoadingScreen.tsx +0 -100
- package/src/components/screens/PinCreationScreen.tsx +0 -67
- package/src/constants/index.ts +0 -83
- package/src/hooks/useConnections.ts +0 -163
- package/src/hooks/useCredentials.ts +0 -175
- package/src/index.js +0 -14
- package/src/index.ts +0 -50
- package/src/services/SDK_API_KEY_VALIDATION.md +0 -428
- package/src/services/apiKeyService.ts +0 -979
- package/src/services/oauthService.ts +0 -412
- package/src/services/platformAuthService.ts +0 -1113
- package/src/types/ambient.d.ts +0 -29
- package/src/types/declarations.d.ts +0 -26
- package/src/types/index.d.ts +0 -274
- package/src/types/index.ts +0 -244
- package/src/types/node-fix.d.ts +0 -19
- package/src/types/node-override.d.ts +0 -24
- package/src/types/opacity.d.ts +0 -16
- package/src/types/types.d.ts +0 -18
- package/src/types.ts +0 -298
- package/src/utils/Portal.tsx +0 -83
- package/src/utils/api.js +0 -112
- package/src/utils/auth.js +0 -104
- package/src/utils/crypto.js +0 -60
- package/src/utils/debugHelper.ts +0 -53
- package/src/utils/encryption.ts +0 -69
- package/src/utils/onairosApi.ts +0 -391
- package/src/utils/programmaticFlow.ts +0 -113
- package/src/utils/retryHelper.ts +0 -275
- package/src/utils/secureStorage.ts +0 -361
- package/types/index.d.ts +0 -218
- package/types/node-env.d.ts +0 -15
- /package/{src/assets/images → lib/commonjs/assets/icons}/farcaster.png +0 -0
- /package/{src/assets/images → lib/commonjs/assets/icons}/instagram.png +0 -0
- /package/{src/assets/images → lib/commonjs/assets/icons}/pinterest.png +0 -0
- /package/{src/assets/images → lib/commonjs/assets/icons}/swerv_logo.png +0 -0
- /package/{src/assets/images → lib/commonjs/assets/icons}/twitter.jpg +0 -0
|
@@ -65,7 +65,7 @@ import { OnairosButton } from 'onairos';
|
|
|
65
65
|
|
|
66
66
|
### Primary Validation Endpoint
|
|
67
67
|
|
|
68
|
-
**POST** `/
|
|
68
|
+
**POST** `/dev/validate`
|
|
69
69
|
|
|
70
70
|
This is the main endpoint that all SDKs should use for API key validation.
|
|
71
71
|
|
|
@@ -92,23 +92,18 @@ User-Agent: OnairosReactNative/3.1.10 (optional)
|
|
|
92
92
|
#### Success Response (200)
|
|
93
93
|
```json
|
|
94
94
|
{
|
|
95
|
-
"
|
|
96
|
-
"permissions": ["data:read", "data:write"],
|
|
97
|
-
"rateLimits": {
|
|
98
|
-
"remaining": 999,
|
|
99
|
-
"resetTime": 1640995200000
|
|
100
|
-
},
|
|
101
|
-
"keyType": "developer",
|
|
102
|
-
"developer": {
|
|
103
|
-
"id": "dev_123",
|
|
104
|
-
"name": "Developer Name",
|
|
105
|
-
"plan": "pro"
|
|
106
|
-
},
|
|
95
|
+
"valid": true,
|
|
107
96
|
"apiKey": {
|
|
108
|
-
"id": "
|
|
97
|
+
"id": "68f7f1bef71b2523faade626",
|
|
109
98
|
"name": "My App Key",
|
|
110
|
-
"
|
|
111
|
-
"
|
|
99
|
+
"createdAt": "2025-10-21T20:49:02.205Z",
|
|
100
|
+
"lastUsed": "2025-10-24T00:15:54.478Z",
|
|
101
|
+
"usageCount": 13
|
|
102
|
+
},
|
|
103
|
+
"application": {
|
|
104
|
+
"name": "My Application",
|
|
105
|
+
"theme": "productivity",
|
|
106
|
+
"description": "Application description"
|
|
112
107
|
}
|
|
113
108
|
}
|
|
114
109
|
```
|
|
@@ -116,24 +111,18 @@ User-Agent: OnairosReactNative/3.1.10 (optional)
|
|
|
116
111
|
#### Error Response (401/400/500)
|
|
117
112
|
```json
|
|
118
113
|
{
|
|
119
|
-
"
|
|
114
|
+
"valid": false,
|
|
120
115
|
"error": "Invalid API key format",
|
|
121
116
|
"message": "Developer keys must be at least 32 characters and start with 'dev_', 'pk_', or 'ona_'",
|
|
122
|
-
"code": "INVALID_API_KEY_FORMAT"
|
|
123
|
-
"keyType": "invalid"
|
|
117
|
+
"code": "INVALID_API_KEY_FORMAT"
|
|
124
118
|
}
|
|
125
119
|
```
|
|
126
120
|
|
|
127
121
|
### Alternative Endpoints
|
|
128
122
|
|
|
129
|
-
####
|
|
130
|
-
**
|
|
131
|
-
|
|
132
|
-
For simple validation without request body.
|
|
133
|
-
|
|
134
|
-
#### Legacy Developer Endpoints (Backward Compatibility)
|
|
135
|
-
- **POST** `/dev/validate-key` - Enhanced validation with backward compatibility
|
|
136
|
-
- **GET** `/dev/validate-key?key=API_KEY` - Simple validation
|
|
123
|
+
#### Legacy Endpoints (Deprecated)
|
|
124
|
+
- **POST** `/auth/validate-key` - Old validation endpoint (deprecated, use `/dev/validate`)
|
|
125
|
+
- **GET** `/auth/validate-key?key=API_KEY` - Old GET validation (deprecated)
|
|
137
126
|
|
|
138
127
|
## 🛡️ Error Handling & Retry Logic
|
|
139
128
|
|
|
@@ -228,34 +217,38 @@ export const validateApiKey = async (apiKey: string): Promise<ApiKeyValidationRe
|
|
|
228
217
|
}
|
|
229
218
|
|
|
230
219
|
// Make API call
|
|
231
|
-
const response = await fetch(`${baseUrl}/
|
|
220
|
+
const response = await fetch(`${baseUrl}/dev/validate`, {
|
|
232
221
|
method: 'POST',
|
|
233
222
|
headers: {
|
|
234
223
|
'Authorization': `Bearer ${apiKey}`,
|
|
235
224
|
'Content-Type': 'application/json',
|
|
236
|
-
'User-Agent': 'OnairosReactNative/3.1
|
|
225
|
+
'User-Agent': 'OnairosReactNative/3.3.1',
|
|
226
|
+
'X-API-Key-Type': keyType,
|
|
227
|
+
'X-SDK-Platform': 'react-native'
|
|
237
228
|
},
|
|
238
229
|
body: JSON.stringify({
|
|
239
230
|
environment: globalConfig?.environment || 'production',
|
|
240
|
-
sdk_version: '3.1
|
|
241
|
-
platform: 'react-native'
|
|
231
|
+
sdk_version: '3.3.1',
|
|
232
|
+
platform: 'react-native',
|
|
233
|
+
keyType,
|
|
234
|
+
timestamp: new Date().toISOString()
|
|
242
235
|
})
|
|
243
236
|
});
|
|
244
237
|
|
|
245
238
|
const data = await response.json();
|
|
246
239
|
|
|
247
|
-
if (data.success) {
|
|
240
|
+
if (data.valid || data.success) {
|
|
248
241
|
return {
|
|
249
242
|
isValid: true,
|
|
250
|
-
permissions: data.permissions,
|
|
251
|
-
rateLimits: data.rateLimits,
|
|
252
|
-
keyType:
|
|
243
|
+
permissions: data.permissions || [],
|
|
244
|
+
rateLimits: data.rateLimits || null,
|
|
245
|
+
keyType: keyType
|
|
253
246
|
};
|
|
254
247
|
} else {
|
|
255
248
|
return {
|
|
256
249
|
isValid: false,
|
|
257
|
-
error: data.error,
|
|
258
|
-
keyType:
|
|
250
|
+
error: data.error || data.message,
|
|
251
|
+
keyType: keyType
|
|
259
252
|
};
|
|
260
253
|
}
|
|
261
254
|
};
|
|
@@ -397,7 +390,7 @@ const validation = await api.validateKey();
|
|
|
397
390
|
|
|
398
391
|
```bash
|
|
399
392
|
# Test with curl
|
|
400
|
-
curl -X POST https://api2.onairos.uk/
|
|
393
|
+
curl -X POST https://api2.onairos.uk/dev/validate \
|
|
401
394
|
-H "Authorization: Bearer ona_your_key_here" \
|
|
402
395
|
-H "Content-Type: application/json" \
|
|
403
396
|
-d '{
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
// Onairos SDK - Asset Registry (auto-generated)
|
|
3
|
+
var __ONAIROS_REQ_REGISTRY__ = [
|
|
4
|
+
require("./jwtStorageService"),
|
|
5
|
+
require("../config/api")
|
|
6
|
+
];
|
|
7
|
+
function __ONAIROS_REQ_FUNC__(i) { return __ONAIROS_REQ_REGISTRY__[i]; }
|
|
8
|
+
Object[_0x3cc6(0x0)](exports,_0x3cc6(0x1),{'value':!![]}),exports[_0x3cc6(0x2)]=exports[_0x3cc6(0x3)]=exports[_0x3cc6(0x4)]=exports[_0x3cc6(0x5)]=exports[_0x3cc6(0x6)]=exports[_0x3cc6(0x7)]=exports['apiClient']=exports[_0x3cc6(0x8)]=void 0x0;var _jwtStorageService=__ONAIROS_REQ_FUNC__(0x0),_api=__ONAIROS_REQ_FUNC__(0x1);let currentRequestId=0x0;const activeRequests=new Map();class ApiClient{constructor(_0x792495=_api[_0x3cc6(0x9)][_0x3cc6(0xa)],_0x8c19aa={}){this[_0x3cc6(0xb)]=_0x792495,this[_0x3cc6(0xc)]=_0x8c19aa;}async[_0x3cc6(0xd)](_0x3cb393,_0x3a4c13={}){const _0x249295={'qCKJF':function(_0x1075ed,_0x39cf0c){return _0x1075ed instanceof _0x39cf0c;},'GYIvs':function(_0x28d407,_0x240191){return _0x28d407===_0x240191;},'FVnxw':_0x3cc6(0xe),'fUFEU':function(_0x77dccb,_0x1552ae){return _0x77dccb instanceof _0x1552ae;},'pWQqI':_0x3cc6(0xf),'WWTWQ':function(_0x4b9997,_0x57802f){return _0x4b9997!==_0x57802f;},'Kdrgr':function(_0x54cd95,_0x35e7d1,_0x28045d){return _0x54cd95(_0x35e7d1,_0x28045d);},'wVpfv':function(_0xac14ee,_0x4c6688){return _0xac14ee===_0x4c6688;},'QfeZI':_0x3cc6(0x10),'iiKGi':_0x3cc6(0x11),'OugoG':'Request\x20cancelled','vvLAU':function(_0xb3f508,_0x4d6796){return _0xb3f508 instanceof _0x4d6796;}},_0x5f34b2=++currentRequestId,_0x1b75fb=new AbortController();activeRequests[_0x3cc6(0x12)](_0x5f34b2,_0x1b75fb);try{console[_0x3cc6(0x13)](_0x3cc6(0x14)+_0x5f34b2+_0x3cc6(0x15)+_0x3cb393);const _0x21a331=(0x0,_jwtStorageService[_0x3cc6(0x16)])(_0x3cb393);console[_0x3cc6(0x13)](_0x3cc6(0x17)+_0x3cb393+_0x3cc6(0x18)+_0x21a331+_0x3cc6(0x19));const _0xabed9=await this['getRequestHeaders'](_0x3cb393,_0x249295['WWTWQ'](_0x3a4c13[_0x3cc6(0x1a)],![])),_0x31994a={'method':_0x3a4c13[_0x3cc6(0x1b)]||'GET','headers':{'Content-Type':'application/json','User-Agent':_0x3cc6(0x1c),..._0xabed9,..._0x3a4c13['headers']},'body':_0x3a4c13['body']?JSON[_0x3cc6(0x1d)](_0x3a4c13['body']):undefined,'signal':_0x1b75fb['signal']};console[_0x3cc6(0x13)](_0x3cc6(0x1e)+_0x5f34b2+'\x20using\x20'+_0x21a331+_0x3cc6(0x19));const _0x4374e1=await _0x249295[_0x3cc6(0x1f)](fetch,''+this['baseUrl']+_0x3cb393,_0x31994a);console['log']('📡\x20[API\x20Client]\x20Response\x20'+_0x5f34b2+_0x3cc6(0x20),_0x4374e1['status']);if(_0x249295[_0x3cc6(0x21)](_0x4374e1[_0x3cc6(0x22)],0x191)){if(_0x249295[_0x3cc6(0x23)](_0x249295['QfeZI'],_0x3cc6(0x24)))_0x24b63f[_0x3cc6(0x13)](_0x3cc6(0x25)+_0x274af1+'\x20token\x20replaced\x20and\x20related\x20requests\x20cancelled');else return await this[_0x3cc6(0x26)](_0x5f34b2,_0x3cb393,_0x21a331,_0x3a4c13);}const _0x23eb55=await _0x4374e1[_0x3cc6(0x27)]();activeRequests[_0x3cc6(0x28)](_0x5f34b2);if(!_0x4374e1['ok'])return{'success':![],'error':_0x23eb55[_0x3cc6(0x29)]||'Request\x20failed\x20with\x20status\x20'+_0x4374e1['status'],'status':_0x4374e1['status'],'tokenType':_0x21a331};return{'success':!![],'data':_0x23eb55,'status':_0x4374e1[_0x3cc6(0x22)],'tokenType':_0x21a331};}catch(_0x4a47f9){activeRequests[_0x3cc6(0x28)](_0x5f34b2);if(_0x4a47f9 instanceof Error&&_0x4a47f9[_0x3cc6(0x2a)]===_0x249295[_0x3cc6(0x2b)]){if(_0x3cc6(0x2c)===_0x249295['iiKGi']){_0x50b6b5[_0x3cc6(0x28)](_0x4c44a2);if(_0x249295['qCKJF'](_0x180bae,_0x30228a)&&_0x249295['GYIvs'](_0x1159bb[_0x3cc6(0x2a)],_0x249295[_0x3cc6(0x2b)]))return _0x2585fb['log']('🚫\x20[API\x20Client]\x20Request\x20'+_0x540460+_0x3cc6(0x2d)),{'success':![],'error':_0x3cc6(0x2e),'status':0x0};return _0x1ff700[_0x3cc6(0x2f)]('❌\x20[API\x20Client]\x20Request\x20'+_0x3f2e41+_0x3cc6(0x30),_0x5d0b48),{'success':![],'error':_0x249295[_0x3cc6(0x31)](_0x5092e8,_0xf4ce1e)?_0x226f9c['message']:_0x249295[_0x3cc6(0x32)],'status':0x0};}else return console[_0x3cc6(0x13)](_0x3cc6(0x33)+_0x5f34b2+_0x3cc6(0x2d)),{'success':![],'error':_0x249295[_0x3cc6(0x34)],'status':0x0};}return console[_0x3cc6(0x2f)](_0x3cc6(0x35)+_0x5f34b2+_0x3cc6(0x30),_0x4a47f9),{'success':![],'error':_0x249295[_0x3cc6(0x36)](_0x4a47f9,Error)?_0x4a47f9[_0x3cc6(0x29)]:_0x3cc6(0xf),'status':0x0};}}async[_0x3cc6(0x37)](_0x50c848,_0x462c76){const _0x5b07ca={'muAtU':function(_0x2e4266,_0x46d8eb){return _0x2e4266!==_0x46d8eb;},'wLWzz':function(_0x269ecb,_0x474d30){return _0x269ecb>_0x474d30;},'ddpgB':_0x3cc6(0x38),'oHIQs':_0x3cc6(0x39)};if(!_0x462c76){if(_0x5b07ca[_0x3cc6(0x3a)](_0x5b07ca['ddpgB'],_0x5b07ca[_0x3cc6(0x3b)]))return{};else{let _0x2d747a=0x0;for(const [_0x455fce,_0x4a3cc7]of _0x1285ff[_0x3cc6(0x3c)]()){_0x5b07ca[_0x3cc6(0x3a)](_0x455fce,_0x4b5152)&&(_0x4a3cc7[_0x3cc6(0x3d)](),_0x110bbf['delete'](_0x455fce),_0x2d747a++);}_0x5b07ca['wLWzz'](_0x2d747a,0x0)&&_0x234805[_0x3cc6(0x13)](_0x3cc6(0x3e)+_0x2d747a+_0x3cc6(0x3f)+_0x1e8b63+_0x3cc6(0x40));}}const _0x2c9b82=await(0x0,_jwtStorageService[_0x3cc6(0x41)])(_0x50c848);if(!_0x2c9b82){const _0x2a9001=(0x0,_jwtStorageService[_0x3cc6(0x16)])(_0x50c848);throw new Error('No\x20'+_0x2a9001+_0x3cc6(0x42)+_0x50c848+_0x3cc6(0x43));}return{'Authorization':_0x2c9b82};}async[_0x3cc6(0x26)](_0x345337,_0x277808,_0x5a638d,_0x3249dd){const _0x4acd27={'yCXfg':_0x3cc6(0x44)},_0x45a2d9=_0x4acd27[_0x3cc6(0x45)][_0x3cc6(0x46)]('|');let _0x19567=0x0;while(!![]){switch(_0x45a2d9[_0x19567++]){case'0':return{'success':![],'error':_0x5a638d+_0x3cc6(0x47)+_0x277808+'.\x20Please\x20re-authenticate.','status':0x191,'tokenType':_0x5a638d};case'1':console['log']('🔄\x20[API\x20Client]\x20Clearing\x20'+_0x5a638d+_0x3cc6(0x48));continue;case'2':console[_0x3cc6(0x2f)](_0x3cc6(0x33)+_0x345337+_0x3cc6(0x49)+_0x5a638d+_0x3cc6(0x4a)+_0x277808);continue;case'3':await(0x0,_jwtStorageService['clearJWT'])(_0x5a638d);continue;case'4':this[_0x3cc6(0x4b)](_0x5a638d,_0x345337);continue;case'5':await this[_0x3cc6(0x4c)](_0x5a638d,_0x277808);continue;case'6':console['log'](_0x3cc6(0x4d)+_0x5a638d+_0x3cc6(0x4e));continue;}break;}}async[_0x3cc6(0x4c)](_0x581a8c,_0x562be7){const _0x48d2bf={'nMrsh':function(_0x1ecbf0,_0x60d03c){return _0x1ecbf0!==_0x60d03c;},'ADVCH':_0x3cc6(0x4f),'wZfxe':_0x3cc6(0x50),'NvWdk':_0x3cc6(0x51),'BUDZu':function(_0x2c6ec4,_0x2ac02e){return _0x2c6ec4!==_0x2ac02e;},'uWcfN':'GcVLG','HApyN':'⚠️\x20[API\x20Client]\x20No\x20Onairos\x20re-auth\x20trigger\x20configured','hXKjZ':_0x3cc6(0x52),'jAJIY':function(_0x3e42d8,_0x577805){return _0x3e42d8===_0x577805;},'HoMZa':_0x3cc6(0x53),'jSysu':'OxPuf'};console[_0x3cc6(0x13)](_0x3cc6(0x54)+_0x581a8c+_0x3cc6(0x55)+_0x562be7+')');try{switch(_0x581a8c){case _jwtStorageService['TokenType']['ENOCH']:if(this[_0x3cc6(0xc)][_0x3cc6(0x56)]){if(_0x48d2bf[_0x3cc6(0x57)](_0x48d2bf[_0x3cc6(0x58)],_0x48d2bf[_0x3cc6(0x58)]))return{};else console['log'](_0x48d2bf[_0x3cc6(0x59)]),await this['authTriggers']['triggerEnochReAuth']();}else console[_0x3cc6(0x5a)](_0x48d2bf[_0x3cc6(0x5b)]);break;case _jwtStorageService['TokenType'][_0x3cc6(0x5c)]:if(this[_0x3cc6(0xc)][_0x3cc6(0x5d)])console[_0x3cc6(0x13)](_0x3cc6(0x5e)),await this[_0x3cc6(0xc)][_0x3cc6(0x5d)]();else{if(_0x48d2bf[_0x3cc6(0x5f)](_0x3cc6(0x60),_0x48d2bf['uWcfN']))console['warn'](_0x48d2bf[_0x3cc6(0x61)]);else return _0x5028ab[_0x3cc6(0x13)]('🚫\x20[API\x20Client]\x20Request\x20'+_0x18d03d+_0x3cc6(0x2d)),{'success':![],'error':'Request\x20cancelled','status':0x0};}break;case _jwtStorageService[_0x3cc6(0x62)][_0x3cc6(0x63)]:this[_0x3cc6(0xc)][_0x3cc6(0x64)]?(console[_0x3cc6(0x13)](_0x48d2bf[_0x3cc6(0x65)]),await this[_0x3cc6(0xc)][_0x3cc6(0x64)]()):_0x48d2bf[_0x3cc6(0x66)](_0x48d2bf[_0x3cc6(0x67)],_0x48d2bf['jSysu'])?(this[_0x3cc6(0xb)]=_0xa0bc6,this[_0x3cc6(0xc)]=_0x298067):console[_0x3cc6(0x5a)]('⚠️\x20[API\x20Client]\x20No\x20auth\x20token\x20refresh\x20trigger\x20configured');break;}}catch(_0x42255d){console[_0x3cc6(0x2f)](_0x3cc6(0x68)+_0x581a8c+':',_0x42255d);}}[_0x3cc6(0x4b)](_0x2342e4,_0x57806d){const _0x11d13e={'dmrpC':_0x3cc6(0x69),'PwQRZ':function(_0xcb374f,_0x4a4b6c){return _0xcb374f!==_0x4a4b6c;},'jQnWv':function(_0x378cf7,_0xb9f21a){return _0x378cf7>_0xb9f21a;},'cJdYb':function(_0x5f4bfb,_0x2117c4){return _0x5f4bfb!==_0x2117c4;},'Ykjjy':_0x3cc6(0x6a)};let _0xafbf34=0x0;for(const [_0x5a526c,_0x55bf8d]of activeRequests[_0x3cc6(0x3c)]()){_0x11d13e[_0x3cc6(0x6b)](_0x5a526c,_0x57806d)&&(_0x55bf8d[_0x3cc6(0x3d)](),activeRequests[_0x3cc6(0x28)](_0x5a526c),_0xafbf34++);}_0x11d13e[_0x3cc6(0x6c)](_0xafbf34,0x0)&&(_0x11d13e['cJdYb'](_0x11d13e['Ykjjy'],'oCrOE')?(this[_0x3cc6(0xc)]={...this[_0x3cc6(0xc)],..._0xdf6870},_0x538f1d['log'](_0x11d13e[_0x3cc6(0x6d)])):console['log']('🚫\x20[API\x20Client]\x20Cancelled\x20'+_0xafbf34+'\x20requests\x20due\x20to\x20'+_0x2342e4+'\x20token\x20failure'));}async[_0x3cc6(0x6e)](_0x442c7f,_0x2d334a){console[_0x3cc6(0x13)](_0x3cc6(0x6f)+_0x442c7f+'\x20token'),this[_0x3cc6(0x4b)](_0x442c7f);const _0x1b8b5e=await(0x0,_jwtStorageService[_0x3cc6(0x70)])(_0x442c7f,_0x2d334a);return _0x1b8b5e&&console[_0x3cc6(0x13)](_0x3cc6(0x25)+_0x442c7f+_0x3cc6(0x71)),_0x1b8b5e;}async[_0x3cc6(0x72)](){const _0x303510={'hkoQO':_0x3cc6(0x73),'XdwuR':'mYzbC'};console['log'](_0x303510[_0x3cc6(0x74)]);const _0x4b00f7=await(0x0,_jwtStorageService['getAllTokens'])();for(const [_0x2934ad,_0x320cd9]of Object[_0x3cc6(0x3c)](_0x4b00f7)){_0x303510[_0x3cc6(0x75)]!==_0x3cc6(0x76)?_0x320cd9?console[_0x3cc6(0x13)](_0x3cc6(0x77)+_0x2934ad+':\x20'+_0x320cd9[_0x3cc6(0x78)](0x0,0x14)+_0x3cc6(0x79)+_0x320cd9[_0x3cc6(0x7a)]+')'):console[_0x3cc6(0x13)](_0x3cc6(0x7b)+_0x2934ad+_0x3cc6(0x7c)):_0x5b82ca[_0x3cc6(0x13)](_0x3cc6(0x7b)+_0x2b5a8f+_0x3cc6(0x7c));}return _0x4b00f7;}[_0x3cc6(0x7d)](_0x4918ef){const _0x7a3b54={'pgLSD':_0x3cc6(0x69)};this[_0x3cc6(0xc)]={...this[_0x3cc6(0xc)],..._0x4918ef},console['log'](_0x7a3b54['pgLSD']);}async['get'](_0x309fc9,_0x3d3d74={}){return this[_0x3cc6(0xd)](_0x309fc9,{..._0x3d3d74,'method':'GET'});}async[_0x3cc6(0x7e)](_0x1667ba,_0x28f34d,_0x341d91={}){return this[_0x3cc6(0xd)](_0x1667ba,{..._0x341d91,'method':'POST','body':_0x28f34d});}async[_0x3cc6(0x7f)](_0x211f97,_0x46cdb7,_0x4cb2e8={}){return this[_0x3cc6(0xd)](_0x211f97,{..._0x4cb2e8,'method':'PUT','body':_0x46cdb7});}async[_0x3cc6(0x28)](_0x11761a,_0x4a19fc={}){return this['request'](_0x11761a,{..._0x4a19fc,'method':'DELETE'});}}exports[_0x3cc6(0x8)]=ApiClient;function _0x3cc6(_0x9f7cd8,_0x3cc6e5){_0x9f7cd8=_0x9f7cd8-0x0;const _0x193dfd=_0x9f7c();let _0x2ad427=_0x193dfd[_0x9f7cd8];return _0x2ad427;}const apiClient=exports[_0x3cc6(0x80)]=new ApiClient(),authenticatedRequest=exports[_0x3cc6(0x3)]=apiClient[_0x3cc6(0xd)]['bind'](apiClient),apiGet=exports['apiGet']=apiClient[_0x3cc6(0x81)][_0x3cc6(0x82)](apiClient),apiPost=exports['apiPost']=apiClient[_0x3cc6(0x7e)][_0x3cc6(0x82)](apiClient),apiPut=exports['apiPut']=apiClient[_0x3cc6(0x7f)][_0x3cc6(0x82)](apiClient),apiDelete=exports[_0x3cc6(0x7)]=apiClient['delete'][_0x3cc6(0x82)](apiClient);function _0x9f7c(){const _0x328ddc=['defineProperty','__esModule','default','authenticatedRequest','apiPut','apiPost','apiGet','apiDelete','ApiClient','API_CONFIG','BASE_URL','baseUrl','authTriggers','request','AbortError','Unknown\x20error','HqBNK','TzOGl','set','log','🔗\x20[API\x20Client]\x20Starting\x20request\x20','\x20to:\x20','getTokenTypeForRoute','🎯\x20[API\x20Client]\x20Route\x20','\x20requires\x20','\x20token','requiresAuth','method','OnairosSDK/1.0.0','stringify','🔐\x20[API\x20Client]\x20Request\x20','Kdrgr','\x20status:','wVpfv','status','GYIvs','CygTE','✅\x20[API\x20Client]\x20','handle401Error','json','delete','message','name','FVnxw','OnWDd','\x20was\x20cancelled','Request\x20cancelled','error','\x20failed:','fUFEU','pWQqI','🚫\x20[API\x20Client]\x20Request\x20','OugoG','❌\x20[API\x20Client]\x20Request\x20','vvLAU','getRequestHeaders','VidPK','Puiao','muAtU','oHIQs','entries','abort','🚫\x20[API\x20Client]\x20Cancelled\x20','\x20requests\x20due\x20to\x20','\x20token\x20failure','getJWTForRoute','\x20token\x20available\x20for\x20route\x20','.\x20Please\x20authenticate\x20first.','2|1|3|4|5|6|0','yCXfg','split','\x20authentication\x20expired\x20for\x20','\x20token\x20due\x20to\x20401\x20error','\x20received\x20401\x20for\x20','\x20token\x20on\x20route:\x20','cancelRequestsForTokenType','triggerReAuthForTokenType','🔑\x20[API\x20Client]\x20','\x20token\x20cleared,\x20user\x20needs\x20to\x20re-authenticate','ulETk','📧\x20[API\x20Client]\x20Triggering\x20Enoch\x20email\x20re-verification','⚠️\x20[API\x20Client]\x20No\x20Enoch\x20re-auth\x20trigger\x20configured','🔄\x20[API\x20Client]\x20Triggering\x20auth\x20token\x20refresh','yZbpc','🔄\x20[API\x20Client]\x20Triggering\x20re-auth\x20for\x20','\x20token\x20(endpoint:\x20','triggerEnochReAuth','nMrsh','ADVCH','wZfxe','warn','NvWdk','ONAIROS','triggerOnairosReAuth','🔑\x20[API\x20Client]\x20Triggering\x20Onairos\x20re-authentication','BUDZu','fgBVf','HApyN','TokenType','AUTH','triggerAuthTokenRefresh','hXKjZ','jAJIY','HoMZa','❌\x20[API\x20Client]\x20Failed\x20to\x20trigger\x20re-auth\x20for\x20','🔧\x20[API\x20Client]\x20Authentication\x20triggers\x20updated','oCrOE','PwQRZ','jQnWv','dmrpC','replaceTokenForType','🔄\x20[API\x20Client]\x20Replacing\x20','replaceJWTAfterVerification','\x20token\x20replaced\x20and\x20related\x20requests\x20cancelled','debugTokens','🔍\x20[API\x20Client]\x20Debug:\x20Current\x20token\x20status','hkoQO','XdwuR','hIIQk','🔐\x20','substring','...\x20(length:\x20','length','📭\x20',':\x20null','setAuthTriggers','post','put','apiClient','get','bind'];_0x9f7c=function(){return _0x328ddc;};return _0x9f7c();}var _default=exports[_0x3cc6(0x2)]=apiClient;
|