@firebase/auth 0.21.1 → 0.21.2-20230131204242
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/CHANGELOG.md +13 -0
- package/dist/auth-public.d.ts +8 -4
- package/dist/auth.d.ts +8 -4
- package/dist/browser-cjs/index-888931f8.js +9642 -0
- package/dist/browser-cjs/index-888931f8.js.map +1 -0
- package/dist/browser-cjs/index.cordova.d.ts +32 -0
- package/dist/browser-cjs/index.d.ts +36 -0
- package/dist/browser-cjs/index.doc.d.ts +24 -0
- package/dist/browser-cjs/index.js +93 -0
- package/dist/browser-cjs/index.js.map +1 -0
- package/dist/browser-cjs/index.node.d.ts +17 -0
- package/dist/browser-cjs/index.rn.d.ts +32 -0
- package/dist/browser-cjs/index.shared.d.ts +19 -0
- package/dist/browser-cjs/index.webworker.d.ts +21 -0
- package/dist/browser-cjs/internal/index.d.ts +42 -0
- package/dist/browser-cjs/internal.js +667 -0
- package/dist/browser-cjs/internal.js.map +1 -0
- package/dist/browser-cjs/scripts/run_node_tests.d.ts +17 -0
- package/dist/browser-cjs/src/api/account_management/account.d.ts +59 -0
- package/dist/browser-cjs/src/api/account_management/account.test.d.ts +17 -0
- package/dist/browser-cjs/src/api/account_management/email_and_password.d.ts +47 -0
- package/dist/browser-cjs/src/api/account_management/email_and_password.test.d.ts +17 -0
- package/dist/browser-cjs/src/api/account_management/mfa.d.ts +69 -0
- package/dist/browser-cjs/src/api/account_management/mfa.test.d.ts +17 -0
- package/dist/browser-cjs/src/api/account_management/profile.d.ts +29 -0
- package/dist/browser-cjs/src/api/account_management/profile.test.d.ts +17 -0
- package/dist/browser-cjs/src/api/authentication/create_auth_uri.d.ts +26 -0
- package/dist/browser-cjs/src/api/authentication/create_auth_uri.test.d.ts +17 -0
- package/dist/browser-cjs/src/api/authentication/custom_token.d.ts +26 -0
- package/dist/browser-cjs/src/api/authentication/custom_token.test.d.ts +17 -0
- package/dist/browser-cjs/src/api/authentication/email_and_password.d.ts +76 -0
- package/dist/browser-cjs/src/api/authentication/email_and_password.test.d.ts +17 -0
- package/dist/browser-cjs/src/api/authentication/email_link.d.ts +32 -0
- package/dist/browser-cjs/src/api/authentication/email_link.test.d.ts +17 -0
- package/dist/browser-cjs/src/api/authentication/idp.d.ts +40 -0
- package/dist/browser-cjs/src/api/authentication/idp.test.d.ts +17 -0
- package/dist/browser-cjs/src/api/authentication/mfa.d.ts +58 -0
- package/dist/browser-cjs/src/api/authentication/mfa.test.d.ts +17 -0
- package/dist/browser-cjs/src/api/authentication/recaptcha.d.ts +18 -0
- package/dist/browser-cjs/src/api/authentication/recaptcha.test.d.ts +17 -0
- package/dist/browser-cjs/src/api/authentication/sign_up.d.ts +29 -0
- package/dist/browser-cjs/src/api/authentication/sign_up.test.d.ts +17 -0
- package/dist/browser-cjs/src/api/authentication/sms.d.ts +50 -0
- package/dist/browser-cjs/src/api/authentication/sms.test.d.ts +17 -0
- package/dist/browser-cjs/src/api/authentication/token.d.ts +26 -0
- package/dist/browser-cjs/src/api/authentication/token.test.d.ts +17 -0
- package/dist/browser-cjs/src/api/errors.d.ts +118 -0
- package/dist/browser-cjs/src/api/index.d.ts +69 -0
- package/dist/browser-cjs/src/api/index.test.d.ts +17 -0
- package/dist/browser-cjs/src/api/project_config/get_project_config.d.ts +25 -0
- package/dist/browser-cjs/src/api/project_config/get_project_config.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/action_code_url.d.ts +73 -0
- package/dist/browser-cjs/src/core/action_code_url.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/auth/auth_event_manager.d.ts +34 -0
- package/dist/browser-cjs/src/core/auth/auth_event_manager.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/auth/auth_impl.d.ts +110 -0
- package/dist/browser-cjs/src/core/auth/auth_impl.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/auth/emulator.d.ts +42 -0
- package/dist/browser-cjs/src/core/auth/emulator.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/auth/firebase_internal.d.ts +35 -0
- package/dist/browser-cjs/src/core/auth/firebase_internal.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/auth/initialize.d.ts +46 -0
- package/dist/browser-cjs/src/core/auth/initialize.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/auth/middleware.d.ts +25 -0
- package/dist/browser-cjs/src/core/auth/middleware.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/auth/register.d.ts +23 -0
- package/dist/browser-cjs/src/core/credentials/auth_credential.d.ts +75 -0
- package/dist/browser-cjs/src/core/credentials/email.d.ts +60 -0
- package/dist/browser-cjs/src/core/credentials/email.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/credentials/index.d.ts +23 -0
- package/dist/browser-cjs/src/core/credentials/oauth.d.ts +81 -0
- package/dist/browser-cjs/src/core/credentials/oauth.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/credentials/phone.d.ts +52 -0
- package/dist/browser-cjs/src/core/credentials/phone.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/credentials/saml.d.ts +52 -0
- package/dist/browser-cjs/src/core/credentials/saml.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/errors.d.ts +305 -0
- package/dist/browser-cjs/src/core/errors.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/index.d.ts +158 -0
- package/dist/browser-cjs/src/core/persistence/in_memory.d.ts +35 -0
- package/dist/browser-cjs/src/core/persistence/in_memory.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/persistence/index.d.ts +41 -0
- package/dist/browser-cjs/src/core/persistence/persistence_user_manager.d.ts +45 -0
- package/dist/browser-cjs/src/core/persistence/persistence_user_manager.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/providers/email.d.ts +83 -0
- package/dist/browser-cjs/src/core/providers/email.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/providers/facebook.d.ts +93 -0
- package/dist/browser-cjs/src/core/providers/facebook.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/providers/federated.d.ts +64 -0
- package/dist/browser-cjs/src/core/providers/federated.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/providers/github.d.ts +89 -0
- package/dist/browser-cjs/src/core/providers/github.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/providers/google.d.ts +96 -0
- package/dist/browser-cjs/src/core/providers/google.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/providers/oauth.d.ts +151 -0
- package/dist/browser-cjs/src/core/providers/oauth.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/providers/saml.d.ts +62 -0
- package/dist/browser-cjs/src/core/providers/saml.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/providers/twitter.d.ts +103 -0
- package/dist/browser-cjs/src/core/providers/twitter.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/strategies/abstract_popup_redirect_operation.d.ts +44 -0
- package/dist/browser-cjs/src/core/strategies/abstract_popup_redirect_operation.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/strategies/action_code_settings.d.ts +19 -0
- package/dist/browser-cjs/src/core/strategies/action_code_settings.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/strategies/anonymous.d.ts +29 -0
- package/dist/browser-cjs/src/core/strategies/anonymous.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/strategies/credential.d.ts +58 -0
- package/dist/browser-cjs/src/core/strategies/credential.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/strategies/custom_token.d.ts +34 -0
- package/dist/browser-cjs/src/core/strategies/custom_token.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/strategies/email.d.ts +98 -0
- package/dist/browser-cjs/src/core/strategies/email.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/strategies/email_and_password.d.ts +126 -0
- package/dist/browser-cjs/src/core/strategies/email_and_password.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/strategies/email_link.d.ts +103 -0
- package/dist/browser-cjs/src/core/strategies/email_link.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/strategies/idp.d.ts +32 -0
- package/dist/browser-cjs/src/core/strategies/idp.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/strategies/redirect.d.ts +36 -0
- package/dist/browser-cjs/src/core/strategies/redirect.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/user/account_info.d.ts +60 -0
- package/dist/browser-cjs/src/core/user/account_info.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/user/additional_user_info.d.ts +31 -0
- package/dist/browser-cjs/src/core/user/additional_user_info.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/user/id_token_result.d.ts +48 -0
- package/dist/browser-cjs/src/core/user/id_token_result.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/user/invalidation.d.ts +18 -0
- package/dist/browser-cjs/src/core/user/invalidation.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/user/link_unlink.d.ts +30 -0
- package/dist/browser-cjs/src/core/user/link_unlink.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/user/proactive_refresh.d.ts +34 -0
- package/dist/browser-cjs/src/core/user/proactive_refresh.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/user/reauthenticate.d.ts +20 -0
- package/dist/browser-cjs/src/core/user/reauthenticate.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/user/reload.d.ts +27 -0
- package/dist/browser-cjs/src/core/user/reload.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/user/token_manager.d.ts +49 -0
- package/dist/browser-cjs/src/core/user/token_manager.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/user/user_credential_impl.d.ts +37 -0
- package/dist/browser-cjs/src/core/user/user_credential_impl.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/user/user_impl.d.ts +68 -0
- package/dist/browser-cjs/src/core/user/user_impl.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/user/user_metadata.d.ts +27 -0
- package/dist/browser-cjs/src/core/util/assert.d.ts +93 -0
- package/dist/browser-cjs/src/core/util/assert.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/util/browser.d.ts +50 -0
- package/dist/browser-cjs/src/core/util/browser.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/util/delay.d.ts +31 -0
- package/dist/browser-cjs/src/core/util/delay.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/util/emulator.d.ts +18 -0
- package/dist/browser-cjs/src/core/util/emulator.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/util/event_id.d.ts +17 -0
- package/dist/browser-cjs/src/core/util/event_id.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/util/fetch_provider.d.ts +25 -0
- package/dist/browser-cjs/src/core/util/handler.d.ts +20 -0
- package/dist/browser-cjs/src/core/util/instantiator.d.ts +28 -0
- package/dist/browser-cjs/src/core/util/instantiator.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/util/location.d.ts +19 -0
- package/dist/browser-cjs/src/core/util/log.d.ts +22 -0
- package/dist/browser-cjs/src/core/util/navigator.d.ts +21 -0
- package/dist/browser-cjs/src/core/util/providers.d.ts +23 -0
- package/dist/browser-cjs/src/core/util/resolver.d.ts +25 -0
- package/dist/browser-cjs/src/core/util/time.d.ts +17 -0
- package/dist/browser-cjs/src/core/util/validate_origin.d.ts +18 -0
- package/dist/browser-cjs/src/core/util/validate_origin.test.d.ts +17 -0
- package/dist/browser-cjs/src/core/util/version.d.ts +30 -0
- package/dist/browser-cjs/src/core/util/version.test.d.ts +17 -0
- package/dist/browser-cjs/src/index.d.ts +18 -0
- package/dist/browser-cjs/src/mfa/index.d.ts +18 -0
- package/dist/browser-cjs/src/mfa/mfa_assertion.d.ts +27 -0
- package/dist/browser-cjs/src/mfa/mfa_error.d.ts +35 -0
- package/dist/browser-cjs/src/mfa/mfa_info.d.ts +32 -0
- package/dist/browser-cjs/src/mfa/mfa_info.test.d.ts +17 -0
- package/dist/browser-cjs/src/mfa/mfa_resolver.d.ts +41 -0
- package/dist/browser-cjs/src/mfa/mfa_resolver.test.d.ts +17 -0
- package/dist/browser-cjs/src/mfa/mfa_session.d.ts +39 -0
- package/dist/browser-cjs/src/mfa/mfa_session.test.d.ts +17 -0
- package/dist/browser-cjs/src/mfa/mfa_user.d.ts +38 -0
- package/dist/browser-cjs/src/mfa/mfa_user.test.d.ts +17 -0
- package/dist/browser-cjs/src/model/application_verifier.d.ts +23 -0
- package/dist/browser-cjs/src/model/auth.d.ts +75 -0
- package/dist/browser-cjs/src/model/enum_maps.d.ts +97 -0
- package/dist/browser-cjs/src/model/enums.d.ts +74 -0
- package/dist/browser-cjs/src/model/id_token.d.ts +87 -0
- package/dist/browser-cjs/src/model/popup_redirect.d.ts +94 -0
- package/dist/browser-cjs/src/model/public_types.d.ts +1162 -0
- package/dist/browser-cjs/src/model/user.d.ts +83 -0
- package/dist/browser-cjs/src/platform_browser/auth.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_browser/auth_window.d.ts +37 -0
- package/dist/browser-cjs/src/platform_browser/iframe/gapi.d.ts +19 -0
- package/dist/browser-cjs/src/platform_browser/iframe/gapi.iframes.d.ts +47 -0
- package/dist/browser-cjs/src/platform_browser/iframe/gapi.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_browser/iframe/iframe.d.ts +18 -0
- package/dist/browser-cjs/src/platform_browser/iframe/iframe.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_browser/index.d.ts +27 -0
- package/dist/browser-cjs/src/platform_browser/load_js.d.ts +18 -0
- package/dist/browser-cjs/src/platform_browser/load_js.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_browser/messagechannel/index.d.ts +87 -0
- package/dist/browser-cjs/src/platform_browser/messagechannel/promise.d.ts +33 -0
- package/dist/browser-cjs/src/platform_browser/messagechannel/promise.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_browser/messagechannel/receiver.d.ts +63 -0
- package/dist/browser-cjs/src/platform_browser/messagechannel/receiver.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_browser/messagechannel/sender.d.ts +46 -0
- package/dist/browser-cjs/src/platform_browser/messagechannel/sender.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_browser/mfa/assertions/phone.d.ts +56 -0
- package/dist/browser-cjs/src/platform_browser/mfa/assertions/phone.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_browser/persistence/browser.d.ts +27 -0
- package/dist/browser-cjs/src/platform_browser/persistence/browser.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_browser/persistence/indexed_db.d.ts +33 -0
- package/dist/browser-cjs/src/platform_browser/persistence/indexed_db.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_browser/persistence/local_storage.d.ts +25 -0
- package/dist/browser-cjs/src/platform_browser/persistence/local_storage.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_browser/persistence/session_storage.d.ts +24 -0
- package/dist/browser-cjs/src/platform_browser/persistence/session_storage.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_browser/popup_redirect.d.ts +24 -0
- package/dist/browser-cjs/src/platform_browser/popup_redirect.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_browser/providers/phone.d.ts +149 -0
- package/dist/browser-cjs/src/platform_browser/providers/phone.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_browser/recaptcha/recaptcha.d.ts +23 -0
- package/dist/browser-cjs/src/platform_browser/recaptcha/recaptcha_loader.d.ts +49 -0
- package/dist/browser-cjs/src/platform_browser/recaptcha/recaptcha_loader.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_browser/recaptcha/recaptcha_mock.d.ts +51 -0
- package/dist/browser-cjs/src/platform_browser/recaptcha/recaptcha_mock.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_browser/recaptcha/recaptcha_verifier.d.ts +90 -0
- package/dist/browser-cjs/src/platform_browser/recaptcha/recaptcha_verifier.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_browser/strategies/phone.d.ts +98 -0
- package/dist/browser-cjs/src/platform_browser/strategies/phone.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_browser/strategies/popup.d.ts +103 -0
- package/dist/browser-cjs/src/platform_browser/strategies/popup.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_browser/strategies/redirect.d.ts +165 -0
- package/dist/browser-cjs/src/platform_browser/strategies/redirect.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_browser/util/popup.d.ts +24 -0
- package/dist/browser-cjs/src/platform_browser/util/popup.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_browser/util/worker.d.ts +20 -0
- package/dist/browser-cjs/src/platform_cordova/plugins.d.ts +42 -0
- package/dist/browser-cjs/src/platform_cordova/popup_redirect/events.d.ts +39 -0
- package/dist/browser-cjs/src/platform_cordova/popup_redirect/events.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_cordova/popup_redirect/popup_redirect.d.ts +24 -0
- package/dist/browser-cjs/src/platform_cordova/popup_redirect/popup_redirect.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_cordova/popup_redirect/utils.d.ts +47 -0
- package/dist/browser-cjs/src/platform_cordova/popup_redirect/utils.test.d.ts +17 -0
- package/dist/browser-cjs/src/platform_cordova/strategies/redirect.d.ts +20 -0
- package/dist/browser-cjs/src/platform_node/index.d.ts +49 -0
- package/dist/browser-cjs/src/platform_react_native/persistence/react_native.d.ts +25 -0
- package/dist/browser-cjs/src/platform_react_native/persistence/react_native.test.d.ts +17 -0
- package/dist/browser-cjs/test/helpers/api/helper.d.ts +20 -0
- package/dist/browser-cjs/test/helpers/delay.d.ts +20 -0
- package/dist/browser-cjs/test/helpers/erroring_unavailable_persistence.d.ts +36 -0
- package/dist/browser-cjs/test/helpers/fake_service_worker.d.ts +22 -0
- package/dist/browser-cjs/test/helpers/id_token_response.d.ts +18 -0
- package/dist/browser-cjs/test/helpers/iframe_event.d.ts +19 -0
- package/dist/browser-cjs/test/helpers/integration/emulator_rest_helpers.d.ts +35 -0
- package/dist/browser-cjs/test/helpers/integration/helpers.d.ts +20 -0
- package/dist/browser-cjs/test/helpers/integration/settings.d.ts +23 -0
- package/dist/browser-cjs/test/helpers/jwt.d.ts +17 -0
- package/dist/browser-cjs/test/helpers/mock_auth.d.ts +42 -0
- package/dist/browser-cjs/test/helpers/mock_auth_credential.d.ts +31 -0
- package/dist/browser-cjs/test/helpers/mock_fetch.d.ts +30 -0
- package/dist/browser-cjs/test/helpers/mock_fetch.test.d.ts +17 -0
- package/dist/browser-cjs/test/helpers/mock_popup_redirect_resolver.d.ts +24 -0
- package/dist/browser-cjs/test/helpers/redirect_persistence.d.ts +24 -0
- package/dist/browser-cjs/test/helpers/timeout_stub.d.ts +34 -0
- package/dist/browser-cjs/test/integration/flows/anonymous.test.d.ts +17 -0
- package/dist/browser-cjs/test/integration/flows/custom.local.test.d.ts +17 -0
- package/dist/browser-cjs/test/integration/flows/email.test.d.ts +17 -0
- package/dist/browser-cjs/test/integration/flows/idp.local.test.d.ts +17 -0
- package/dist/browser-cjs/test/integration/flows/middleware_test_generator.d.ts +18 -0
- package/dist/browser-cjs/test/integration/flows/oob.local.test.d.ts +17 -0
- package/dist/browser-cjs/test/integration/flows/phone.test.d.ts +17 -0
- package/dist/browser-cjs/test/integration/webdriver/anonymous.test.d.ts +17 -0
- package/dist/browser-cjs/test/integration/webdriver/compat/firebaseui.test.d.ts +17 -0
- package/dist/browser-cjs/test/integration/webdriver/persistence.test.d.ts +17 -0
- package/dist/browser-cjs/test/integration/webdriver/popup.test.d.ts +17 -0
- package/dist/browser-cjs/test/integration/webdriver/redirect.test.d.ts +17 -0
- package/dist/browser-cjs/test/integration/webdriver/util/auth_driver.d.ts +46 -0
- package/dist/browser-cjs/test/integration/webdriver/util/functions.d.ts +81 -0
- package/dist/browser-cjs/test/integration/webdriver/util/idp_page.d.ts +31 -0
- package/dist/browser-cjs/test/integration/webdriver/util/js_load_condition.d.ts +25 -0
- package/dist/browser-cjs/test/integration/webdriver/util/test_runner.d.ts +19 -0
- package/dist/browser-cjs/test/integration/webdriver/util/test_server.d.ts +27 -0
- package/dist/browser-cjs/test/integration/webdriver/util/ui_page.d.ts +33 -0
- package/dist/cordova/index.js +2 -2
- package/dist/cordova/internal.js +2 -2
- package/dist/cordova/{popup_redirect-f2a91123.js → popup_redirect-e3f41047.js} +16 -15
- package/dist/cordova/popup_redirect-e3f41047.js.map +1 -0
- package/dist/cordova/src/core/strategies/credential.d.ts +2 -1
- package/dist/cordova/src/platform_browser/strategies/redirect.d.ts +6 -3
- package/dist/esm2017/{index-e5b3cc81.js → index-ad92feb8.js} +22 -20
- package/dist/esm2017/index-ad92feb8.js.map +1 -0
- package/dist/esm2017/index.js +1 -1
- package/dist/esm2017/internal.js +2 -2
- package/dist/esm2017/src/core/strategies/credential.d.ts +2 -1
- package/dist/esm2017/src/platform_browser/strategies/redirect.d.ts +6 -3
- package/dist/esm5/{index-624a9c08.js → index-b011a244.js} +16 -15
- package/dist/esm5/index-b011a244.js.map +1 -0
- package/dist/esm5/index.js +1 -1
- package/dist/esm5/internal.js +2 -2
- package/dist/esm5/src/core/strategies/credential.d.ts +2 -1
- package/dist/esm5/src/platform_browser/strategies/redirect.d.ts +6 -3
- package/dist/index.webworker.esm5.js +9 -11
- package/dist/index.webworker.esm5.js.map +1 -1
- package/dist/node/{index-69e083b1.js → index-07d4f473.js} +10 -12
- package/dist/node/{index-69e083b1.js.map → index-07d4f473.js.map} +1 -1
- package/dist/node/index.js +1 -1
- package/dist/node/internal.js +1 -1
- package/dist/node/internal.js.map +1 -1
- package/dist/node/src/core/strategies/credential.d.ts +2 -1
- package/dist/node/src/platform_browser/strategies/redirect.d.ts +6 -3
- package/dist/node-esm/{index-67ff6dfa.js → index-0d69afd8.js} +16 -17
- package/dist/node-esm/{index-67ff6dfa.js.map → index-0d69afd8.js.map} +1 -1
- package/dist/node-esm/index.js +1 -1
- package/dist/node-esm/internal.js +2 -2
- package/dist/node-esm/internal.js.map +1 -1
- package/dist/node-esm/src/core/strategies/credential.d.ts +2 -1
- package/dist/node-esm/src/platform_browser/strategies/redirect.d.ts +6 -3
- package/dist/rn/index.js +1 -1
- package/dist/rn/internal.js +7 -4
- package/dist/rn/internal.js.map +1 -1
- package/dist/rn/{phone-ec5655af.js → phone-92601072.js} +10 -12
- package/dist/rn/phone-92601072.js.map +1 -0
- package/dist/rn/src/core/strategies/credential.d.ts +2 -1
- package/dist/rn/src/platform_browser/strategies/redirect.d.ts +6 -3
- package/dist/src/core/strategies/credential.d.ts +2 -1
- package/dist/src/platform_browser/strategies/redirect.d.ts +6 -3
- package/package.json +15 -7
- package/dist/cordova/popup_redirect-f2a91123.js.map +0 -1
- package/dist/esm2017/index-e5b3cc81.js.map +0 -1
- package/dist/esm5/index-624a9c08.js.map +0 -1
- package/dist/rn/phone-ec5655af.js.map +0 -1
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import { IdToken, IdTokenResponse } from '../../model/id_token';
|
|
18
|
+
import { Auth } from '../../model/public_types';
|
|
19
|
+
export interface SignInWithIdpRequest {
|
|
20
|
+
requestUri: string;
|
|
21
|
+
postBody?: string;
|
|
22
|
+
sessionId?: string;
|
|
23
|
+
tenantId?: string;
|
|
24
|
+
returnSecureToken: boolean;
|
|
25
|
+
returnIdpCredential?: boolean;
|
|
26
|
+
idToken?: IdToken;
|
|
27
|
+
autoCreate?: boolean;
|
|
28
|
+
pendingToken?: string;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* @internal
|
|
32
|
+
*/
|
|
33
|
+
export interface SignInWithIdpResponse extends IdTokenResponse {
|
|
34
|
+
oauthAccessToken?: string;
|
|
35
|
+
oauthTokenSecret?: string;
|
|
36
|
+
nonce?: string;
|
|
37
|
+
oauthIdToken?: string;
|
|
38
|
+
pendingToken?: string;
|
|
39
|
+
}
|
|
40
|
+
export declare function signInWithIdp(auth: Auth, request: SignInWithIdpRequest): Promise<SignInWithIdpResponse>;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
export {};
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import { Auth } from '../../model/public_types';
|
|
18
|
+
import { IdTokenResponse } from '../../model/id_token';
|
|
19
|
+
import { MfaEnrollment } from '../account_management/mfa';
|
|
20
|
+
import { SignInWithIdpResponse } from './idp';
|
|
21
|
+
import { SignInWithPhoneNumberRequest, SignInWithPhoneNumberResponse } from './sms';
|
|
22
|
+
export interface FinalizeMfaResponse {
|
|
23
|
+
idToken: string;
|
|
24
|
+
refreshToken: string;
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* @internal
|
|
28
|
+
*/
|
|
29
|
+
export interface IdTokenMfaResponse extends IdTokenResponse {
|
|
30
|
+
mfaPendingCredential?: string;
|
|
31
|
+
mfaInfo?: MfaEnrollment[];
|
|
32
|
+
}
|
|
33
|
+
export interface StartPhoneMfaSignInRequest {
|
|
34
|
+
mfaPendingCredential: string;
|
|
35
|
+
mfaEnrollmentId: string;
|
|
36
|
+
phoneSignInInfo: {
|
|
37
|
+
recaptchaToken: string;
|
|
38
|
+
};
|
|
39
|
+
tenantId?: string;
|
|
40
|
+
}
|
|
41
|
+
export interface StartPhoneMfaSignInResponse {
|
|
42
|
+
phoneResponseInfo: {
|
|
43
|
+
sessionInfo: string;
|
|
44
|
+
};
|
|
45
|
+
}
|
|
46
|
+
export declare function startSignInPhoneMfa(auth: Auth, request: StartPhoneMfaSignInRequest): Promise<StartPhoneMfaSignInResponse>;
|
|
47
|
+
export interface FinalizePhoneMfaSignInRequest {
|
|
48
|
+
mfaPendingCredential: string;
|
|
49
|
+
phoneVerificationInfo: SignInWithPhoneNumberRequest;
|
|
50
|
+
tenantId?: string;
|
|
51
|
+
}
|
|
52
|
+
export interface FinalizePhoneMfaSignInResponse extends FinalizeMfaResponse {
|
|
53
|
+
}
|
|
54
|
+
export declare function finalizeSignInPhoneMfa(auth: Auth, request: FinalizePhoneMfaSignInRequest): Promise<FinalizePhoneMfaSignInResponse>;
|
|
55
|
+
/**
|
|
56
|
+
* @internal
|
|
57
|
+
*/
|
|
58
|
+
export declare type PhoneOrOauthTokenResponse = SignInWithPhoneNumberResponse | SignInWithIdpResponse | IdTokenResponse;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
export {};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import { Auth } from '../../model/public_types';
|
|
18
|
+
export declare function getRecaptchaParams(auth: Auth): Promise<string>;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
export {};
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import { IdTokenResponse } from '../../model/id_token';
|
|
18
|
+
import { Auth } from '../../model/public_types';
|
|
19
|
+
export interface SignUpRequest {
|
|
20
|
+
returnSecureToken?: boolean;
|
|
21
|
+
email?: string;
|
|
22
|
+
password?: string;
|
|
23
|
+
tenantId?: string;
|
|
24
|
+
}
|
|
25
|
+
export interface SignUpResponse extends IdTokenResponse {
|
|
26
|
+
displayName?: string;
|
|
27
|
+
email?: string;
|
|
28
|
+
}
|
|
29
|
+
export declare function signUp(auth: Auth, request: SignUpRequest): Promise<SignUpResponse>;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
export {};
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import { IdTokenResponse } from '../../model/id_token';
|
|
18
|
+
import { Auth } from '../../model/public_types';
|
|
19
|
+
export interface SendPhoneVerificationCodeRequest {
|
|
20
|
+
phoneNumber: string;
|
|
21
|
+
recaptchaToken: string;
|
|
22
|
+
tenantId?: string;
|
|
23
|
+
}
|
|
24
|
+
export interface SendPhoneVerificationCodeResponse {
|
|
25
|
+
sessionInfo: string;
|
|
26
|
+
}
|
|
27
|
+
export declare function sendPhoneVerificationCode(auth: Auth, request: SendPhoneVerificationCodeRequest): Promise<SendPhoneVerificationCodeResponse>;
|
|
28
|
+
/**
|
|
29
|
+
* @internal
|
|
30
|
+
*/
|
|
31
|
+
export interface SignInWithPhoneNumberRequest {
|
|
32
|
+
temporaryProof?: string;
|
|
33
|
+
phoneNumber?: string;
|
|
34
|
+
sessionInfo?: string;
|
|
35
|
+
code?: string;
|
|
36
|
+
tenantId?: string;
|
|
37
|
+
}
|
|
38
|
+
export interface LinkWithPhoneNumberRequest extends SignInWithPhoneNumberRequest {
|
|
39
|
+
idToken: string;
|
|
40
|
+
}
|
|
41
|
+
/**
|
|
42
|
+
* @internal
|
|
43
|
+
*/
|
|
44
|
+
export interface SignInWithPhoneNumberResponse extends IdTokenResponse {
|
|
45
|
+
temporaryProof?: string;
|
|
46
|
+
phoneNumber?: string;
|
|
47
|
+
}
|
|
48
|
+
export declare function signInWithPhoneNumber(auth: Auth, request: SignInWithPhoneNumberRequest): Promise<SignInWithPhoneNumberResponse>;
|
|
49
|
+
export declare function linkWithPhoneNumber(auth: Auth, request: LinkWithPhoneNumberRequest): Promise<SignInWithPhoneNumberResponse>;
|
|
50
|
+
export declare function verifyPhoneNumberForExisting(auth: Auth, request: SignInWithPhoneNumberRequest): Promise<SignInWithPhoneNumberResponse>;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
export {};
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import { Auth } from '../../model/public_types';
|
|
18
|
+
export declare const enum Endpoint {
|
|
19
|
+
TOKEN = "/v1/token"
|
|
20
|
+
}
|
|
21
|
+
export interface RequestStsTokenResponse {
|
|
22
|
+
accessToken: string;
|
|
23
|
+
expiresIn: string;
|
|
24
|
+
refreshToken: string;
|
|
25
|
+
}
|
|
26
|
+
export declare function requestStsToken(auth: Auth, refreshToken: string): Promise<RequestStsTokenResponse>;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
export {};
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import { AuthErrorCode } from '../core/errors';
|
|
18
|
+
/**
|
|
19
|
+
* Errors that can be returned by the backend
|
|
20
|
+
*/
|
|
21
|
+
export declare const enum ServerError {
|
|
22
|
+
ADMIN_ONLY_OPERATION = "ADMIN_ONLY_OPERATION",
|
|
23
|
+
BLOCKING_FUNCTION_ERROR_RESPONSE = "BLOCKING_FUNCTION_ERROR_RESPONSE",
|
|
24
|
+
CAPTCHA_CHECK_FAILED = "CAPTCHA_CHECK_FAILED",
|
|
25
|
+
CORS_UNSUPPORTED = "CORS_UNSUPPORTED",
|
|
26
|
+
CREDENTIAL_MISMATCH = "CREDENTIAL_MISMATCH",
|
|
27
|
+
CREDENTIAL_TOO_OLD_LOGIN_AGAIN = "CREDENTIAL_TOO_OLD_LOGIN_AGAIN",
|
|
28
|
+
DYNAMIC_LINK_NOT_ACTIVATED = "DYNAMIC_LINK_NOT_ACTIVATED",
|
|
29
|
+
EMAIL_CHANGE_NEEDS_VERIFICATION = "EMAIL_CHANGE_NEEDS_VERIFICATION",
|
|
30
|
+
EMAIL_EXISTS = "EMAIL_EXISTS",
|
|
31
|
+
EMAIL_NOT_FOUND = "EMAIL_NOT_FOUND",
|
|
32
|
+
EXPIRED_OOB_CODE = "EXPIRED_OOB_CODE",
|
|
33
|
+
FEDERATED_USER_ID_ALREADY_LINKED = "FEDERATED_USER_ID_ALREADY_LINKED",
|
|
34
|
+
INVALID_APP_CREDENTIAL = "INVALID_APP_CREDENTIAL",
|
|
35
|
+
INVALID_APP_ID = "INVALID_APP_ID",
|
|
36
|
+
INVALID_CERT_HASH = "INVALID_CERT_HASH",
|
|
37
|
+
INVALID_CODE = "INVALID_CODE",
|
|
38
|
+
INVALID_CONTINUE_URI = "INVALID_CONTINUE_URI",
|
|
39
|
+
INVALID_CUSTOM_TOKEN = "INVALID_CUSTOM_TOKEN",
|
|
40
|
+
INVALID_DYNAMIC_LINK_DOMAIN = "INVALID_DYNAMIC_LINK_DOMAIN",
|
|
41
|
+
INVALID_EMAIL = "INVALID_EMAIL",
|
|
42
|
+
INVALID_ID_TOKEN = "INVALID_ID_TOKEN",
|
|
43
|
+
INVALID_IDP_RESPONSE = "INVALID_IDP_RESPONSE",
|
|
44
|
+
INVALID_IDENTIFIER = "INVALID_IDENTIFIER",
|
|
45
|
+
INVALID_MESSAGE_PAYLOAD = "INVALID_MESSAGE_PAYLOAD",
|
|
46
|
+
INVALID_MFA_PENDING_CREDENTIAL = "INVALID_MFA_PENDING_CREDENTIAL",
|
|
47
|
+
INVALID_OAUTH_CLIENT_ID = "INVALID_OAUTH_CLIENT_ID",
|
|
48
|
+
INVALID_OOB_CODE = "INVALID_OOB_CODE",
|
|
49
|
+
INVALID_PASSWORD = "INVALID_PASSWORD",
|
|
50
|
+
INVALID_PENDING_TOKEN = "INVALID_PENDING_TOKEN",
|
|
51
|
+
INVALID_PHONE_NUMBER = "INVALID_PHONE_NUMBER",
|
|
52
|
+
INVALID_PROVIDER_ID = "INVALID_PROVIDER_ID",
|
|
53
|
+
INVALID_RECIPIENT_EMAIL = "INVALID_RECIPIENT_EMAIL",
|
|
54
|
+
INVALID_SENDER = "INVALID_SENDER",
|
|
55
|
+
INVALID_SESSION_INFO = "INVALID_SESSION_INFO",
|
|
56
|
+
INVALID_TEMPORARY_PROOF = "INVALID_TEMPORARY_PROOF",
|
|
57
|
+
INVALID_TENANT_ID = "INVALID_TENANT_ID",
|
|
58
|
+
MFA_ENROLLMENT_NOT_FOUND = "MFA_ENROLLMENT_NOT_FOUND",
|
|
59
|
+
MISSING_ANDROID_PACKAGE_NAME = "MISSING_ANDROID_PACKAGE_NAME",
|
|
60
|
+
MISSING_APP_CREDENTIAL = "MISSING_APP_CREDENTIAL",
|
|
61
|
+
MISSING_CODE = "MISSING_CODE",
|
|
62
|
+
MISSING_CONTINUE_URI = "MISSING_CONTINUE_URI",
|
|
63
|
+
MISSING_CUSTOM_TOKEN = "MISSING_CUSTOM_TOKEN",
|
|
64
|
+
MISSING_IOS_BUNDLE_ID = "MISSING_IOS_BUNDLE_ID",
|
|
65
|
+
MISSING_MFA_ENROLLMENT_ID = "MISSING_MFA_ENROLLMENT_ID",
|
|
66
|
+
MISSING_MFA_PENDING_CREDENTIAL = "MISSING_MFA_PENDING_CREDENTIAL",
|
|
67
|
+
MISSING_OOB_CODE = "MISSING_OOB_CODE",
|
|
68
|
+
MISSING_OR_INVALID_NONCE = "MISSING_OR_INVALID_NONCE",
|
|
69
|
+
MISSING_PASSWORD = "MISSING_PASSWORD",
|
|
70
|
+
MISSING_REQ_TYPE = "MISSING_REQ_TYPE",
|
|
71
|
+
MISSING_PHONE_NUMBER = "MISSING_PHONE_NUMBER",
|
|
72
|
+
MISSING_SESSION_INFO = "MISSING_SESSION_INFO",
|
|
73
|
+
OPERATION_NOT_ALLOWED = "OPERATION_NOT_ALLOWED",
|
|
74
|
+
PASSWORD_LOGIN_DISABLED = "PASSWORD_LOGIN_DISABLED",
|
|
75
|
+
QUOTA_EXCEEDED = "QUOTA_EXCEEDED",
|
|
76
|
+
RESET_PASSWORD_EXCEED_LIMIT = "RESET_PASSWORD_EXCEED_LIMIT",
|
|
77
|
+
REJECTED_CREDENTIAL = "REJECTED_CREDENTIAL",
|
|
78
|
+
SECOND_FACTOR_EXISTS = "SECOND_FACTOR_EXISTS",
|
|
79
|
+
SECOND_FACTOR_LIMIT_EXCEEDED = "SECOND_FACTOR_LIMIT_EXCEEDED",
|
|
80
|
+
SESSION_EXPIRED = "SESSION_EXPIRED",
|
|
81
|
+
TENANT_ID_MISMATCH = "TENANT_ID_MISMATCH",
|
|
82
|
+
TOKEN_EXPIRED = "TOKEN_EXPIRED",
|
|
83
|
+
TOO_MANY_ATTEMPTS_TRY_LATER = "TOO_MANY_ATTEMPTS_TRY_LATER",
|
|
84
|
+
UNSUPPORTED_FIRST_FACTOR = "UNSUPPORTED_FIRST_FACTOR",
|
|
85
|
+
UNSUPPORTED_TENANT_OPERATION = "UNSUPPORTED_TENANT_OPERATION",
|
|
86
|
+
UNAUTHORIZED_DOMAIN = "UNAUTHORIZED_DOMAIN",
|
|
87
|
+
UNVERIFIED_EMAIL = "UNVERIFIED_EMAIL",
|
|
88
|
+
USER_CANCELLED = "USER_CANCELLED",
|
|
89
|
+
USER_DISABLED = "USER_DISABLED",
|
|
90
|
+
USER_NOT_FOUND = "USER_NOT_FOUND",
|
|
91
|
+
WEAK_PASSWORD = "WEAK_PASSWORD"
|
|
92
|
+
}
|
|
93
|
+
/**
|
|
94
|
+
* API Response in the event of an error
|
|
95
|
+
*/
|
|
96
|
+
export interface JsonError {
|
|
97
|
+
error: {
|
|
98
|
+
code: number;
|
|
99
|
+
message: string;
|
|
100
|
+
errors?: [
|
|
101
|
+
{
|
|
102
|
+
message: ServerError;
|
|
103
|
+
domain: string;
|
|
104
|
+
reason: string;
|
|
105
|
+
}
|
|
106
|
+
];
|
|
107
|
+
};
|
|
108
|
+
}
|
|
109
|
+
/**
|
|
110
|
+
* Type definition for a map from server errors to developer visible errors
|
|
111
|
+
*/
|
|
112
|
+
export declare type ServerErrorMap<ApiError extends string> = {
|
|
113
|
+
readonly [K in ApiError]: AuthErrorCode;
|
|
114
|
+
};
|
|
115
|
+
/**
|
|
116
|
+
* Map from errors returned by the server to errors to developer visible errors
|
|
117
|
+
*/
|
|
118
|
+
export declare const SERVER_ERROR_MAP: Partial<ServerErrorMap<ServerError>>;
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import { FirebaseError } from '@firebase/util';
|
|
18
|
+
import { AuthErrorCode } from '../core/errors';
|
|
19
|
+
import { Delay } from '../core/util/delay';
|
|
20
|
+
import { Auth } from '../model/public_types';
|
|
21
|
+
import { IdTokenResponse } from '../model/id_token';
|
|
22
|
+
import { ServerError, ServerErrorMap } from './errors';
|
|
23
|
+
export declare const enum HttpMethod {
|
|
24
|
+
POST = "POST",
|
|
25
|
+
GET = "GET"
|
|
26
|
+
}
|
|
27
|
+
export declare const enum HttpHeader {
|
|
28
|
+
CONTENT_TYPE = "Content-Type",
|
|
29
|
+
X_FIREBASE_LOCALE = "X-Firebase-Locale",
|
|
30
|
+
X_CLIENT_VERSION = "X-Client-Version",
|
|
31
|
+
X_FIREBASE_GMPID = "X-Firebase-gmpid",
|
|
32
|
+
X_FIREBASE_CLIENT = "X-Firebase-Client"
|
|
33
|
+
}
|
|
34
|
+
export declare const enum Endpoint {
|
|
35
|
+
CREATE_AUTH_URI = "/v1/accounts:createAuthUri",
|
|
36
|
+
DELETE_ACCOUNT = "/v1/accounts:delete",
|
|
37
|
+
RESET_PASSWORD = "/v1/accounts:resetPassword",
|
|
38
|
+
SIGN_UP = "/v1/accounts:signUp",
|
|
39
|
+
SIGN_IN_WITH_CUSTOM_TOKEN = "/v1/accounts:signInWithCustomToken",
|
|
40
|
+
SIGN_IN_WITH_EMAIL_LINK = "/v1/accounts:signInWithEmailLink",
|
|
41
|
+
SIGN_IN_WITH_IDP = "/v1/accounts:signInWithIdp",
|
|
42
|
+
SIGN_IN_WITH_PASSWORD = "/v1/accounts:signInWithPassword",
|
|
43
|
+
SIGN_IN_WITH_PHONE_NUMBER = "/v1/accounts:signInWithPhoneNumber",
|
|
44
|
+
SEND_VERIFICATION_CODE = "/v1/accounts:sendVerificationCode",
|
|
45
|
+
SEND_OOB_CODE = "/v1/accounts:sendOobCode",
|
|
46
|
+
SET_ACCOUNT_INFO = "/v1/accounts:update",
|
|
47
|
+
GET_ACCOUNT_INFO = "/v1/accounts:lookup",
|
|
48
|
+
GET_RECAPTCHA_PARAM = "/v1/recaptchaParams",
|
|
49
|
+
START_MFA_ENROLLMENT = "/v2/accounts/mfaEnrollment:start",
|
|
50
|
+
FINALIZE_MFA_ENROLLMENT = "/v2/accounts/mfaEnrollment:finalize",
|
|
51
|
+
START_MFA_SIGN_IN = "/v2/accounts/mfaSignIn:start",
|
|
52
|
+
FINALIZE_MFA_SIGN_IN = "/v2/accounts/mfaSignIn:finalize",
|
|
53
|
+
WITHDRAW_MFA = "/v2/accounts/mfaEnrollment:withdraw",
|
|
54
|
+
GET_PROJECT_CONFIG = "/v1/projects"
|
|
55
|
+
}
|
|
56
|
+
export declare const DEFAULT_API_TIMEOUT_MS: Delay;
|
|
57
|
+
export declare function _addTidIfNecessary<T extends {
|
|
58
|
+
tenantId?: string;
|
|
59
|
+
}>(auth: Auth, request: T): T;
|
|
60
|
+
export declare function _performApiRequest<T, V>(auth: Auth, method: HttpMethod, path: Endpoint, request?: T, customErrorMap?: Partial<ServerErrorMap<ServerError>>): Promise<V>;
|
|
61
|
+
export declare function _performFetchWithErrorHandling<V>(auth: Auth, customErrorMap: Partial<ServerErrorMap<ServerError>>, fetchFn: () => Promise<Response>): Promise<V>;
|
|
62
|
+
export declare function _performSignInRequest<T, V extends IdTokenResponse>(auth: Auth, method: HttpMethod, path: Endpoint, request?: T, customErrorMap?: Partial<ServerErrorMap<ServerError>>): Promise<V>;
|
|
63
|
+
export declare function _getFinalTarget(auth: Auth, host: string, path: string, query: string): string;
|
|
64
|
+
interface PotentialResponse extends IdTokenResponse {
|
|
65
|
+
email?: string;
|
|
66
|
+
phoneNumber?: string;
|
|
67
|
+
}
|
|
68
|
+
export declare function _makeTaggedError(auth: Auth, code: AuthErrorCode, response: PotentialResponse): FirebaseError;
|
|
69
|
+
export {};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
export {};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
import { Auth } from '../../model/public_types';
|
|
18
|
+
export interface GetProjectConfigRequest {
|
|
19
|
+
androidPackageName?: string;
|
|
20
|
+
iosBundleId?: string;
|
|
21
|
+
}
|
|
22
|
+
export interface GetProjectConfigResponse {
|
|
23
|
+
authorizedDomains: string[];
|
|
24
|
+
}
|
|
25
|
+
export declare function _getProjectConfig(auth: Auth, request?: GetProjectConfigRequest): Promise<GetProjectConfigResponse>;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
export {};
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright 2020 Google LLC
|
|
4
|
+
*
|
|
5
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
* you may not use this file except in compliance with the License.
|
|
7
|
+
* You may obtain a copy of the License at
|
|
8
|
+
*
|
|
9
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
*
|
|
11
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
* See the License for the specific language governing permissions and
|
|
15
|
+
* limitations under the License.
|
|
16
|
+
*/
|
|
17
|
+
/**
|
|
18
|
+
* A utility class to parse email action URLs such as password reset, email verification,
|
|
19
|
+
* email link sign in, etc.
|
|
20
|
+
*
|
|
21
|
+
* @public
|
|
22
|
+
*/
|
|
23
|
+
export declare class ActionCodeURL {
|
|
24
|
+
/**
|
|
25
|
+
* The API key of the email action link.
|
|
26
|
+
*/
|
|
27
|
+
readonly apiKey: string;
|
|
28
|
+
/**
|
|
29
|
+
* The action code of the email action link.
|
|
30
|
+
*/
|
|
31
|
+
readonly code: string;
|
|
32
|
+
/**
|
|
33
|
+
* The continue URL of the email action link. Null if not provided.
|
|
34
|
+
*/
|
|
35
|
+
readonly continueUrl: string | null;
|
|
36
|
+
/**
|
|
37
|
+
* The language code of the email action link. Null if not provided.
|
|
38
|
+
*/
|
|
39
|
+
readonly languageCode: string | null;
|
|
40
|
+
/**
|
|
41
|
+
* The action performed by the email action link. It returns from one of the types from
|
|
42
|
+
* {@link ActionCodeInfo}
|
|
43
|
+
*/
|
|
44
|
+
readonly operation: string;
|
|
45
|
+
/**
|
|
46
|
+
* The tenant ID of the email action link. Null if the email action is from the parent project.
|
|
47
|
+
*/
|
|
48
|
+
readonly tenantId: string | null;
|
|
49
|
+
/**
|
|
50
|
+
* @param actionLink - The link from which to extract the URL.
|
|
51
|
+
* @returns The {@link ActionCodeURL} object, or null if the link is invalid.
|
|
52
|
+
*
|
|
53
|
+
* @internal
|
|
54
|
+
*/
|
|
55
|
+
constructor(actionLink: string);
|
|
56
|
+
/**
|
|
57
|
+
* Parses the email action link string and returns an {@link ActionCodeURL} if the link is valid,
|
|
58
|
+
* otherwise returns null.
|
|
59
|
+
*
|
|
60
|
+
* @param link - The email action link string.
|
|
61
|
+
* @returns The {@link ActionCodeURL} object, or null if the link is invalid.
|
|
62
|
+
*
|
|
63
|
+
* @public
|
|
64
|
+
*/
|
|
65
|
+
static parseLink(link: string): ActionCodeURL | null;
|
|
66
|
+
}
|
|
67
|
+
/**
|
|
68
|
+
* Parses the email action link string and returns an {@link ActionCodeURL} if
|
|
69
|
+
* the link is valid, otherwise returns null.
|
|
70
|
+
*
|
|
71
|
+
* @public
|
|
72
|
+
*/
|
|
73
|
+
export declare function parseActionCodeURL(link: string): ActionCodeURL | null;
|