@firebase/auth 0.18.3 → 0.19.0-canary.0b3ca78eb

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.
Files changed (365) hide show
  1. package/CHANGELOG.md +16 -0
  2. package/dist/auth-public.d.ts +28 -19
  3. package/dist/auth.d.ts +29 -20
  4. package/dist/cordova/index.js +2 -2
  5. package/dist/cordova/index.rn.d.ts +3 -0
  6. package/dist/cordova/internal.js +7 -3
  7. package/dist/cordova/internal.js.map +1 -1
  8. package/dist/cordova/{popup_redirect-f608cd47.js → popup_redirect-680c56fc.js} +54 -33
  9. package/dist/cordova/popup_redirect-680c56fc.js.map +1 -0
  10. package/dist/cordova/src/core/errors.d.ts +2 -2
  11. package/dist/cordova/src/core/strategies/abstract_popup_redirect_operation.d.ts +1 -1
  12. package/dist/cordova/src/mfa/mfa_error.d.ts +4 -5
  13. package/dist/cordova/src/model/public_types.d.ts +25 -19
  14. package/dist/cordova/src/platform_browser/persistence/browser.d.ts +4 -3
  15. package/dist/cordova/src/platform_browser/persistence/browser.test.d.ts +17 -0
  16. package/dist/cordova/src/platform_browser/strategies/phone.d.ts +3 -0
  17. package/dist/cordova/test/helpers/erroring_unavailable_persistence.d.ts +36 -0
  18. package/dist/esm2017/{index-f41a0691.js → index-100be16e.js} +43 -25
  19. package/dist/esm2017/index-100be16e.js.map +1 -0
  20. package/dist/esm2017/index.js +1 -1
  21. package/dist/esm2017/index.rn.d.ts +3 -0
  22. package/dist/esm2017/internal.js +2 -2
  23. package/dist/esm2017/src/core/errors.d.ts +2 -2
  24. package/dist/esm2017/src/core/strategies/abstract_popup_redirect_operation.d.ts +1 -1
  25. package/dist/esm2017/src/mfa/mfa_error.d.ts +4 -5
  26. package/dist/esm2017/src/model/public_types.d.ts +25 -19
  27. package/dist/esm2017/src/platform_browser/persistence/browser.d.ts +4 -3
  28. package/dist/esm2017/src/platform_browser/persistence/browser.test.d.ts +17 -0
  29. package/dist/esm2017/src/platform_browser/strategies/phone.d.ts +3 -0
  30. package/dist/esm2017/test/helpers/erroring_unavailable_persistence.d.ts +36 -0
  31. package/dist/esm5/{index-fd8b7af5.js → index-4c58d8b7.js} +59 -34
  32. package/dist/esm5/index-4c58d8b7.js.map +1 -0
  33. package/dist/esm5/index.js +1 -1
  34. package/dist/esm5/index.rn.d.ts +3 -0
  35. package/dist/esm5/internal.js +2 -2
  36. package/dist/esm5/src/core/errors.d.ts +2 -2
  37. package/dist/esm5/src/core/strategies/abstract_popup_redirect_operation.d.ts +1 -1
  38. package/dist/esm5/src/mfa/mfa_error.d.ts +4 -5
  39. package/dist/esm5/src/model/public_types.d.ts +25 -19
  40. package/dist/esm5/src/platform_browser/persistence/browser.d.ts +4 -3
  41. package/dist/esm5/src/platform_browser/persistence/browser.test.d.ts +17 -0
  42. package/dist/esm5/src/platform_browser/strategies/phone.d.ts +3 -0
  43. package/dist/esm5/test/helpers/erroring_unavailable_persistence.d.ts +36 -0
  44. package/dist/index.rn.d.ts +3 -0
  45. package/dist/index.webworker.esm5.js +25 -23
  46. package/dist/index.webworker.esm5.js.map +1 -1
  47. package/dist/node/{index-358613ec.js → index-8505a33c.js} +26 -24
  48. package/dist/node/index-8505a33c.js.map +1 -0
  49. package/dist/node/index.js +1 -1
  50. package/dist/node/index.rn.d.ts +3 -0
  51. package/dist/node/internal.js +29 -10
  52. package/dist/node/internal.js.map +1 -1
  53. package/dist/node/src/core/errors.d.ts +2 -2
  54. package/dist/node/src/core/strategies/abstract_popup_redirect_operation.d.ts +1 -1
  55. package/dist/node/src/mfa/mfa_error.d.ts +4 -5
  56. package/dist/node/src/model/public_types.d.ts +25 -19
  57. package/dist/node/src/platform_browser/persistence/browser.d.ts +4 -3
  58. package/dist/node/src/platform_browser/persistence/browser.test.d.ts +17 -0
  59. package/dist/node/src/platform_browser/strategies/phone.d.ts +3 -0
  60. package/dist/node/test/helpers/erroring_unavailable_persistence.d.ts +36 -0
  61. package/dist/node-esm/index-4b759c81.js +6031 -0
  62. package/dist/node-esm/index-4b759c81.js.map +1 -0
  63. package/dist/node-esm/index.cordova.d.ts +32 -0
  64. package/dist/node-esm/index.d.ts +36 -0
  65. package/dist/node-esm/index.doc.d.ts +24 -0
  66. package/dist/node-esm/index.js +8 -0
  67. package/dist/node-esm/index.js.map +1 -0
  68. package/dist/node-esm/index.node.d.ts +17 -0
  69. package/dist/node-esm/index.rn.d.ts +30 -0
  70. package/dist/node-esm/index.shared.d.ts +19 -0
  71. package/dist/node-esm/index.webworker.d.ts +21 -0
  72. package/dist/node-esm/internal/index.d.ts +41 -0
  73. package/dist/node-esm/internal.js +1455 -0
  74. package/dist/node-esm/internal.js.map +1 -0
  75. package/dist/node-esm/package.json +1 -0
  76. package/dist/node-esm/scripts/run_node_tests.d.ts +17 -0
  77. package/dist/node-esm/src/api/account_management/account.d.ts +59 -0
  78. package/dist/node-esm/src/api/account_management/account.test.d.ts +17 -0
  79. package/dist/node-esm/src/api/account_management/email_and_password.d.ts +47 -0
  80. package/dist/node-esm/src/api/account_management/email_and_password.test.d.ts +17 -0
  81. package/dist/node-esm/src/api/account_management/mfa.d.ts +69 -0
  82. package/dist/node-esm/src/api/account_management/mfa.test.d.ts +17 -0
  83. package/dist/node-esm/src/api/account_management/profile.d.ts +29 -0
  84. package/dist/node-esm/src/api/account_management/profile.test.d.ts +17 -0
  85. package/dist/node-esm/src/api/authentication/create_auth_uri.d.ts +26 -0
  86. package/dist/node-esm/src/api/authentication/create_auth_uri.test.d.ts +17 -0
  87. package/dist/node-esm/src/api/authentication/custom_token.d.ts +26 -0
  88. package/dist/node-esm/src/api/authentication/custom_token.test.d.ts +17 -0
  89. package/dist/node-esm/src/api/authentication/email_and_password.d.ts +76 -0
  90. package/dist/node-esm/src/api/authentication/email_and_password.test.d.ts +17 -0
  91. package/dist/node-esm/src/api/authentication/email_link.d.ts +32 -0
  92. package/dist/node-esm/src/api/authentication/email_link.test.d.ts +17 -0
  93. package/dist/node-esm/src/api/authentication/idp.d.ts +40 -0
  94. package/dist/node-esm/src/api/authentication/idp.test.d.ts +17 -0
  95. package/dist/node-esm/src/api/authentication/mfa.d.ts +58 -0
  96. package/dist/node-esm/src/api/authentication/mfa.test.d.ts +17 -0
  97. package/dist/node-esm/src/api/authentication/recaptcha.d.ts +18 -0
  98. package/dist/node-esm/src/api/authentication/recaptcha.test.d.ts +17 -0
  99. package/dist/node-esm/src/api/authentication/sign_up.d.ts +29 -0
  100. package/dist/node-esm/src/api/authentication/sign_up.test.d.ts +17 -0
  101. package/dist/node-esm/src/api/authentication/sms.d.ts +50 -0
  102. package/dist/node-esm/src/api/authentication/sms.test.d.ts +17 -0
  103. package/dist/node-esm/src/api/authentication/token.d.ts +26 -0
  104. package/dist/node-esm/src/api/authentication/token.test.d.ts +17 -0
  105. package/dist/node-esm/src/api/errors.d.ts +118 -0
  106. package/dist/node-esm/src/api/index.d.ts +67 -0
  107. package/dist/node-esm/src/api/index.test.d.ts +17 -0
  108. package/dist/node-esm/src/api/project_config/get_project_config.d.ts +25 -0
  109. package/dist/node-esm/src/api/project_config/get_project_config.test.d.ts +17 -0
  110. package/dist/node-esm/src/core/action_code_url.d.ts +73 -0
  111. package/dist/node-esm/src/core/action_code_url.test.d.ts +17 -0
  112. package/dist/node-esm/src/core/auth/auth_event_manager.d.ts +34 -0
  113. package/dist/node-esm/src/core/auth/auth_event_manager.test.d.ts +17 -0
  114. package/dist/node-esm/src/core/auth/auth_impl.d.ts +106 -0
  115. package/dist/node-esm/src/core/auth/auth_impl.test.d.ts +17 -0
  116. package/dist/node-esm/src/core/auth/emulator.d.ts +42 -0
  117. package/dist/node-esm/src/core/auth/emulator.test.d.ts +17 -0
  118. package/dist/node-esm/src/core/auth/firebase_internal.d.ts +35 -0
  119. package/dist/node-esm/src/core/auth/firebase_internal.test.d.ts +17 -0
  120. package/dist/node-esm/src/core/auth/initialize.d.ts +46 -0
  121. package/dist/node-esm/src/core/auth/initialize.test.d.ts +17 -0
  122. package/dist/node-esm/src/core/auth/register.d.ts +23 -0
  123. package/dist/node-esm/src/core/credentials/auth_credential.d.ts +75 -0
  124. package/dist/node-esm/src/core/credentials/email.d.ts +60 -0
  125. package/dist/node-esm/src/core/credentials/email.test.d.ts +17 -0
  126. package/dist/node-esm/src/core/credentials/index.d.ts +23 -0
  127. package/dist/node-esm/src/core/credentials/oauth.d.ts +81 -0
  128. package/dist/node-esm/src/core/credentials/oauth.test.d.ts +17 -0
  129. package/dist/node-esm/src/core/credentials/phone.d.ts +52 -0
  130. package/dist/node-esm/src/core/credentials/phone.test.d.ts +17 -0
  131. package/dist/node-esm/src/core/credentials/saml.d.ts +52 -0
  132. package/dist/node-esm/src/core/credentials/saml.test.d.ts +17 -0
  133. package/dist/node-esm/src/core/errors.d.ts +299 -0
  134. package/dist/node-esm/src/core/errors.test.d.ts +17 -0
  135. package/dist/node-esm/src/core/index.d.ts +141 -0
  136. package/dist/node-esm/src/core/persistence/in_memory.d.ts +35 -0
  137. package/dist/node-esm/src/core/persistence/in_memory.test.d.ts +17 -0
  138. package/dist/node-esm/src/core/persistence/index.d.ts +41 -0
  139. package/dist/node-esm/src/core/persistence/persistence_user_manager.d.ts +45 -0
  140. package/dist/node-esm/src/core/persistence/persistence_user_manager.test.d.ts +17 -0
  141. package/dist/node-esm/src/core/providers/email.d.ts +83 -0
  142. package/dist/node-esm/src/core/providers/email.test.d.ts +17 -0
  143. package/dist/node-esm/src/core/providers/facebook.d.ts +93 -0
  144. package/dist/node-esm/src/core/providers/facebook.test.d.ts +17 -0
  145. package/dist/node-esm/src/core/providers/federated.d.ts +64 -0
  146. package/dist/node-esm/src/core/providers/federated.test.d.ts +17 -0
  147. package/dist/node-esm/src/core/providers/github.d.ts +89 -0
  148. package/dist/node-esm/src/core/providers/github.test.d.ts +17 -0
  149. package/dist/node-esm/src/core/providers/google.d.ts +96 -0
  150. package/dist/node-esm/src/core/providers/google.test.d.ts +17 -0
  151. package/dist/node-esm/src/core/providers/oauth.d.ts +151 -0
  152. package/dist/node-esm/src/core/providers/oauth.test.d.ts +17 -0
  153. package/dist/node-esm/src/core/providers/saml.d.ts +62 -0
  154. package/dist/node-esm/src/core/providers/saml.test.d.ts +17 -0
  155. package/dist/node-esm/src/core/providers/twitter.d.ts +103 -0
  156. package/dist/node-esm/src/core/providers/twitter.test.d.ts +17 -0
  157. package/dist/node-esm/src/core/strategies/abstract_popup_redirect_operation.d.ts +44 -0
  158. package/dist/node-esm/src/core/strategies/abstract_popup_redirect_operation.test.d.ts +17 -0
  159. package/dist/node-esm/src/core/strategies/action_code_settings.d.ts +19 -0
  160. package/dist/node-esm/src/core/strategies/action_code_settings.test.d.ts +17 -0
  161. package/dist/node-esm/src/core/strategies/anonymous.d.ts +29 -0
  162. package/dist/node-esm/src/core/strategies/anonymous.test.d.ts +17 -0
  163. package/dist/node-esm/src/core/strategies/credential.d.ts +57 -0
  164. package/dist/node-esm/src/core/strategies/credential.test.d.ts +17 -0
  165. package/dist/node-esm/src/core/strategies/custom_token.d.ts +34 -0
  166. package/dist/node-esm/src/core/strategies/custom_token.test.d.ts +17 -0
  167. package/dist/node-esm/src/core/strategies/email.d.ts +98 -0
  168. package/dist/node-esm/src/core/strategies/email.test.d.ts +17 -0
  169. package/dist/node-esm/src/core/strategies/email_and_password.d.ts +126 -0
  170. package/dist/node-esm/src/core/strategies/email_and_password.test.d.ts +17 -0
  171. package/dist/node-esm/src/core/strategies/email_link.d.ts +103 -0
  172. package/dist/node-esm/src/core/strategies/email_link.test.d.ts +17 -0
  173. package/dist/node-esm/src/core/strategies/idp.d.ts +32 -0
  174. package/dist/node-esm/src/core/strategies/idp.test.d.ts +17 -0
  175. package/dist/node-esm/src/core/strategies/redirect.d.ts +35 -0
  176. package/dist/node-esm/src/core/strategies/redirect.test.d.ts +17 -0
  177. package/dist/node-esm/src/core/user/account_info.d.ts +60 -0
  178. package/dist/node-esm/src/core/user/account_info.test.d.ts +17 -0
  179. package/dist/node-esm/src/core/user/additional_user_info.d.ts +31 -0
  180. package/dist/node-esm/src/core/user/additional_user_info.test.d.ts +17 -0
  181. package/dist/node-esm/src/core/user/id_token_result.d.ts +48 -0
  182. package/dist/node-esm/src/core/user/id_token_result.test.d.ts +17 -0
  183. package/dist/node-esm/src/core/user/invalidation.d.ts +18 -0
  184. package/dist/node-esm/src/core/user/invalidation.test.d.ts +17 -0
  185. package/dist/node-esm/src/core/user/link_unlink.d.ts +30 -0
  186. package/dist/node-esm/src/core/user/link_unlink.test.d.ts +17 -0
  187. package/dist/node-esm/src/core/user/proactive_refresh.d.ts +34 -0
  188. package/dist/node-esm/src/core/user/proactive_refresh.test.d.ts +17 -0
  189. package/dist/node-esm/src/core/user/reauthenticate.d.ts +20 -0
  190. package/dist/node-esm/src/core/user/reauthenticate.test.d.ts +17 -0
  191. package/dist/node-esm/src/core/user/reload.d.ts +27 -0
  192. package/dist/node-esm/src/core/user/reload.test.d.ts +17 -0
  193. package/dist/node-esm/src/core/user/token_manager.d.ts +49 -0
  194. package/dist/node-esm/src/core/user/token_manager.test.d.ts +17 -0
  195. package/dist/node-esm/src/core/user/user_credential_impl.d.ts +37 -0
  196. package/dist/node-esm/src/core/user/user_credential_impl.test.d.ts +17 -0
  197. package/dist/node-esm/src/core/user/user_impl.d.ts +68 -0
  198. package/dist/node-esm/src/core/user/user_impl.test.d.ts +17 -0
  199. package/dist/node-esm/src/core/user/user_metadata.d.ts +27 -0
  200. package/dist/node-esm/src/core/util/assert.d.ts +93 -0
  201. package/dist/node-esm/src/core/util/assert.test.d.ts +17 -0
  202. package/dist/node-esm/src/core/util/browser.d.ts +50 -0
  203. package/dist/node-esm/src/core/util/browser.test.d.ts +17 -0
  204. package/dist/node-esm/src/core/util/delay.d.ts +31 -0
  205. package/dist/node-esm/src/core/util/delay.test.d.ts +17 -0
  206. package/dist/node-esm/src/core/util/emulator.d.ts +18 -0
  207. package/dist/node-esm/src/core/util/emulator.test.d.ts +17 -0
  208. package/dist/node-esm/src/core/util/event_id.d.ts +17 -0
  209. package/dist/node-esm/src/core/util/event_id.test.d.ts +17 -0
  210. package/dist/node-esm/src/core/util/fetch_provider.d.ts +25 -0
  211. package/dist/node-esm/src/core/util/handler.d.ts +20 -0
  212. package/dist/node-esm/src/core/util/instantiator.d.ts +28 -0
  213. package/dist/node-esm/src/core/util/instantiator.test.d.ts +17 -0
  214. package/dist/node-esm/src/core/util/location.d.ts +19 -0
  215. package/dist/node-esm/src/core/util/log.d.ts +22 -0
  216. package/dist/node-esm/src/core/util/navigator.d.ts +21 -0
  217. package/dist/node-esm/src/core/util/providers.d.ts +23 -0
  218. package/dist/node-esm/src/core/util/resolver.d.ts +25 -0
  219. package/dist/node-esm/src/core/util/time.d.ts +17 -0
  220. package/dist/node-esm/src/core/util/validate_origin.d.ts +18 -0
  221. package/dist/node-esm/src/core/util/validate_origin.test.d.ts +17 -0
  222. package/dist/node-esm/src/core/util/version.d.ts +30 -0
  223. package/dist/node-esm/src/core/util/version.test.d.ts +17 -0
  224. package/dist/node-esm/src/index.d.ts +18 -0
  225. package/dist/node-esm/src/mfa/index.d.ts +18 -0
  226. package/dist/node-esm/src/mfa/mfa_assertion.d.ts +27 -0
  227. package/dist/node-esm/src/mfa/mfa_error.d.ts +35 -0
  228. package/dist/node-esm/src/mfa/mfa_info.d.ts +32 -0
  229. package/dist/node-esm/src/mfa/mfa_info.test.d.ts +17 -0
  230. package/dist/node-esm/src/mfa/mfa_resolver.d.ts +41 -0
  231. package/dist/node-esm/src/mfa/mfa_resolver.test.d.ts +17 -0
  232. package/dist/node-esm/src/mfa/mfa_session.d.ts +37 -0
  233. package/dist/node-esm/src/mfa/mfa_session.test.d.ts +17 -0
  234. package/dist/node-esm/src/mfa/mfa_user.d.ts +38 -0
  235. package/dist/node-esm/src/mfa/mfa_user.test.d.ts +17 -0
  236. package/dist/node-esm/src/model/application_verifier.d.ts +23 -0
  237. package/dist/node-esm/src/model/auth.d.ts +75 -0
  238. package/dist/node-esm/src/model/enum_maps.d.ts +97 -0
  239. package/dist/node-esm/src/model/enums.d.ts +74 -0
  240. package/dist/node-esm/src/model/id_token.d.ts +84 -0
  241. package/dist/node-esm/src/model/popup_redirect.d.ts +92 -0
  242. package/dist/node-esm/src/model/public_types.d.ts +1139 -0
  243. package/dist/node-esm/src/model/user.d.ts +79 -0
  244. package/dist/node-esm/src/platform_browser/auth.test.d.ts +17 -0
  245. package/dist/node-esm/src/platform_browser/auth_window.d.ts +37 -0
  246. package/dist/node-esm/src/platform_browser/iframe/gapi.d.ts +19 -0
  247. package/dist/node-esm/src/platform_browser/iframe/gapi.iframes.d.ts +47 -0
  248. package/dist/node-esm/src/platform_browser/iframe/gapi.test.d.ts +17 -0
  249. package/dist/node-esm/src/platform_browser/iframe/iframe.d.ts +18 -0
  250. package/dist/node-esm/src/platform_browser/iframe/iframe.test.d.ts +17 -0
  251. package/dist/node-esm/src/platform_browser/index.d.ts +27 -0
  252. package/dist/node-esm/src/platform_browser/load_js.d.ts +18 -0
  253. package/dist/node-esm/src/platform_browser/load_js.test.d.ts +17 -0
  254. package/dist/node-esm/src/platform_browser/messagechannel/index.d.ts +87 -0
  255. package/dist/node-esm/src/platform_browser/messagechannel/promise.d.ts +33 -0
  256. package/dist/node-esm/src/platform_browser/messagechannel/promise.test.d.ts +17 -0
  257. package/dist/node-esm/src/platform_browser/messagechannel/receiver.d.ts +63 -0
  258. package/dist/node-esm/src/platform_browser/messagechannel/receiver.test.d.ts +17 -0
  259. package/dist/node-esm/src/platform_browser/messagechannel/sender.d.ts +46 -0
  260. package/dist/node-esm/src/platform_browser/messagechannel/sender.test.d.ts +17 -0
  261. package/dist/node-esm/src/platform_browser/mfa/assertions/phone.d.ts +56 -0
  262. package/dist/node-esm/src/platform_browser/mfa/assertions/phone.test.d.ts +17 -0
  263. package/dist/node-esm/src/platform_browser/persistence/browser.d.ts +27 -0
  264. package/dist/node-esm/src/platform_browser/persistence/browser.test.d.ts +17 -0
  265. package/dist/node-esm/src/platform_browser/persistence/indexed_db.d.ts +33 -0
  266. package/dist/node-esm/src/platform_browser/persistence/indexed_db.test.d.ts +17 -0
  267. package/dist/node-esm/src/platform_browser/persistence/local_storage.d.ts +25 -0
  268. package/dist/node-esm/src/platform_browser/persistence/local_storage.test.d.ts +17 -0
  269. package/dist/node-esm/src/platform_browser/persistence/session_storage.d.ts +24 -0
  270. package/dist/node-esm/src/platform_browser/persistence/session_storage.test.d.ts +17 -0
  271. package/dist/node-esm/src/platform_browser/popup_redirect.d.ts +24 -0
  272. package/dist/node-esm/src/platform_browser/popup_redirect.test.d.ts +17 -0
  273. package/dist/node-esm/src/platform_browser/providers/phone.d.ts +149 -0
  274. package/dist/node-esm/src/platform_browser/providers/phone.test.d.ts +17 -0
  275. package/dist/node-esm/src/platform_browser/recaptcha/recaptcha.d.ts +23 -0
  276. package/dist/node-esm/src/platform_browser/recaptcha/recaptcha_loader.d.ts +44 -0
  277. package/dist/node-esm/src/platform_browser/recaptcha/recaptcha_loader.test.d.ts +17 -0
  278. package/dist/node-esm/src/platform_browser/recaptcha/recaptcha_mock.d.ts +51 -0
  279. package/dist/node-esm/src/platform_browser/recaptcha/recaptcha_mock.test.d.ts +17 -0
  280. package/dist/node-esm/src/platform_browser/recaptcha/recaptcha_verifier.d.ts +94 -0
  281. package/dist/node-esm/src/platform_browser/recaptcha/recaptcha_verifier.test.d.ts +17 -0
  282. package/dist/node-esm/src/platform_browser/strategies/phone.d.ts +98 -0
  283. package/dist/node-esm/src/platform_browser/strategies/phone.test.d.ts +17 -0
  284. package/dist/node-esm/src/platform_browser/strategies/popup.d.ts +103 -0
  285. package/dist/node-esm/src/platform_browser/strategies/popup.test.d.ts +17 -0
  286. package/dist/node-esm/src/platform_browser/strategies/redirect.d.ts +156 -0
  287. package/dist/node-esm/src/platform_browser/strategies/redirect.test.d.ts +17 -0
  288. package/dist/node-esm/src/platform_browser/util/popup.d.ts +24 -0
  289. package/dist/node-esm/src/platform_browser/util/popup.test.d.ts +17 -0
  290. package/dist/node-esm/src/platform_browser/util/worker.d.ts +20 -0
  291. package/dist/node-esm/src/platform_cordova/plugins.d.ts +42 -0
  292. package/dist/node-esm/src/platform_cordova/popup_redirect/events.d.ts +39 -0
  293. package/dist/node-esm/src/platform_cordova/popup_redirect/events.test.d.ts +17 -0
  294. package/dist/node-esm/src/platform_cordova/popup_redirect/popup_redirect.d.ts +24 -0
  295. package/dist/node-esm/src/platform_cordova/popup_redirect/popup_redirect.test.d.ts +17 -0
  296. package/dist/node-esm/src/platform_cordova/popup_redirect/utils.d.ts +47 -0
  297. package/dist/node-esm/src/platform_cordova/popup_redirect/utils.test.d.ts +17 -0
  298. package/dist/node-esm/src/platform_cordova/strategies/redirect.d.ts +20 -0
  299. package/dist/node-esm/src/platform_node/index.d.ts +49 -0
  300. package/dist/node-esm/src/platform_react_native/persistence/react_native.d.ts +31 -0
  301. package/dist/node-esm/src/platform_react_native/persistence/react_native.test.d.ts +17 -0
  302. package/dist/node-esm/test/helpers/api/helper.d.ts +20 -0
  303. package/dist/node-esm/test/helpers/delay.d.ts +20 -0
  304. package/dist/node-esm/test/helpers/erroring_unavailable_persistence.d.ts +36 -0
  305. package/dist/node-esm/test/helpers/fake_service_worker.d.ts +22 -0
  306. package/dist/node-esm/test/helpers/id_token_response.d.ts +18 -0
  307. package/dist/node-esm/test/helpers/iframe_event.d.ts +19 -0
  308. package/dist/node-esm/test/helpers/integration/emulator_rest_helpers.d.ts +35 -0
  309. package/dist/node-esm/test/helpers/integration/helpers.d.ts +20 -0
  310. package/dist/node-esm/test/helpers/integration/settings.d.ts +23 -0
  311. package/dist/node-esm/test/helpers/jwt.d.ts +17 -0
  312. package/dist/node-esm/test/helpers/mock_auth.d.ts +37 -0
  313. package/dist/node-esm/test/helpers/mock_auth_credential.d.ts +31 -0
  314. package/dist/node-esm/test/helpers/mock_fetch.d.ts +30 -0
  315. package/dist/node-esm/test/helpers/mock_fetch.test.d.ts +17 -0
  316. package/dist/node-esm/test/helpers/mock_popup_redirect_resolver.d.ts +24 -0
  317. package/dist/node-esm/test/helpers/redirect_persistence.d.ts +24 -0
  318. package/dist/node-esm/test/helpers/timeout_stub.d.ts +34 -0
  319. package/dist/node-esm/test/integration/flows/anonymous.test.d.ts +17 -0
  320. package/dist/node-esm/test/integration/flows/custom.local.test.d.ts +17 -0
  321. package/dist/node-esm/test/integration/flows/email.test.d.ts +17 -0
  322. package/dist/node-esm/test/integration/flows/idp.local.test.d.ts +17 -0
  323. package/dist/node-esm/test/integration/flows/oob.local.test.d.ts +17 -0
  324. package/dist/node-esm/test/integration/flows/phone.test.d.ts +17 -0
  325. package/dist/node-esm/test/integration/webdriver/anonymous.test.d.ts +17 -0
  326. package/dist/node-esm/test/integration/webdriver/compat/firebaseui.test.d.ts +17 -0
  327. package/dist/node-esm/test/integration/webdriver/persistence.test.d.ts +17 -0
  328. package/dist/node-esm/test/integration/webdriver/popup.test.d.ts +17 -0
  329. package/dist/node-esm/test/integration/webdriver/redirect.test.d.ts +17 -0
  330. package/dist/node-esm/test/integration/webdriver/util/auth_driver.d.ts +46 -0
  331. package/dist/node-esm/test/integration/webdriver/util/functions.d.ts +77 -0
  332. package/dist/node-esm/test/integration/webdriver/util/idp_page.d.ts +31 -0
  333. package/dist/node-esm/test/integration/webdriver/util/js_load_condition.d.ts +25 -0
  334. package/dist/node-esm/test/integration/webdriver/util/test_runner.d.ts +19 -0
  335. package/dist/node-esm/test/integration/webdriver/util/test_server.d.ts +27 -0
  336. package/dist/node-esm/test/integration/webdriver/util/ui_page.d.ts +33 -0
  337. package/dist/rn/index.js +70 -64
  338. package/dist/rn/index.js.map +1 -1
  339. package/dist/rn/index.rn.d.ts +3 -0
  340. package/dist/rn/internal.js +338 -1465
  341. package/dist/rn/internal.js.map +1 -1
  342. package/dist/rn/{enum_maps-81db3ff6.js → phone-fe0b5242.js} +1195 -34
  343. package/dist/rn/phone-fe0b5242.js.map +1 -0
  344. package/dist/rn/src/core/errors.d.ts +2 -2
  345. package/dist/rn/src/core/strategies/abstract_popup_redirect_operation.d.ts +1 -1
  346. package/dist/rn/src/mfa/mfa_error.d.ts +4 -5
  347. package/dist/rn/src/model/public_types.d.ts +25 -19
  348. package/dist/rn/src/platform_browser/persistence/browser.d.ts +4 -3
  349. package/dist/rn/src/platform_browser/persistence/browser.test.d.ts +17 -0
  350. package/dist/rn/src/platform_browser/strategies/phone.d.ts +3 -0
  351. package/dist/rn/test/helpers/erroring_unavailable_persistence.d.ts +36 -0
  352. package/dist/src/core/errors.d.ts +2 -2
  353. package/dist/src/core/strategies/abstract_popup_redirect_operation.d.ts +1 -1
  354. package/dist/src/mfa/mfa_error.d.ts +4 -5
  355. package/dist/src/model/public_types.d.ts +25 -19
  356. package/dist/src/platform_browser/persistence/browser.d.ts +4 -3
  357. package/dist/src/platform_browser/persistence/browser.test.d.ts +17 -0
  358. package/dist/src/platform_browser/strategies/phone.d.ts +3 -0
  359. package/dist/test/helpers/erroring_unavailable_persistence.d.ts +36 -0
  360. package/package.json +31 -9
  361. package/dist/cordova/popup_redirect-f608cd47.js.map +0 -1
  362. package/dist/esm2017/index-f41a0691.js.map +0 -1
  363. package/dist/esm5/index-fd8b7af5.js.map +0 -1
  364. package/dist/node/index-358613ec.js.map +0 -1
  365. package/dist/rn/enum_maps-81db3ff6.js.map +0 -1
@@ -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 { IdTokenResponse } from '../../model/id_token';
18
+ import { Auth } from '../../model/public_types';
19
+ export interface SignInWithCustomTokenRequest {
20
+ token: string;
21
+ returnSecureToken: boolean;
22
+ tenantId?: string;
23
+ }
24
+ export interface SignInWithCustomTokenResponse extends IdTokenResponse {
25
+ }
26
+ export declare function signInWithCustomToken(auth: Auth, request: SignInWithCustomTokenRequest): Promise<SignInWithCustomTokenResponse>;
@@ -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,76 @@
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 { ActionCodeOperation, Auth } from '../../model/public_types';
18
+ import { IdToken, IdTokenResponse } from '../../model/id_token';
19
+ export interface SignInWithPasswordRequest {
20
+ returnSecureToken?: boolean;
21
+ email: string;
22
+ password: string;
23
+ tenantId?: string;
24
+ }
25
+ export interface SignInWithPasswordResponse extends IdTokenResponse {
26
+ email: string;
27
+ displayName: string;
28
+ }
29
+ export declare function signInWithPassword(auth: Auth, request: SignInWithPasswordRequest): Promise<SignInWithPasswordResponse>;
30
+ export interface GetOobCodeRequest {
31
+ email?: string;
32
+ continueUrl?: string;
33
+ iOSBundleId?: string;
34
+ iosAppStoreId?: string;
35
+ androidPackageName?: string;
36
+ androidInstallApp?: boolean;
37
+ androidMinimumVersionCode?: string;
38
+ canHandleCodeInApp?: boolean;
39
+ dynamicLinkDomain?: string;
40
+ tenantId?: string;
41
+ targetProjectid?: string;
42
+ }
43
+ export interface VerifyEmailRequest extends GetOobCodeRequest {
44
+ requestType: ActionCodeOperation.VERIFY_EMAIL;
45
+ idToken: IdToken;
46
+ }
47
+ export interface PasswordResetRequest extends GetOobCodeRequest {
48
+ requestType: ActionCodeOperation.PASSWORD_RESET;
49
+ email: string;
50
+ captchaResp?: string;
51
+ }
52
+ export interface EmailSignInRequest extends GetOobCodeRequest {
53
+ requestType: ActionCodeOperation.EMAIL_SIGNIN;
54
+ email: string;
55
+ }
56
+ export interface VerifyAndChangeEmailRequest extends GetOobCodeRequest {
57
+ requestType: ActionCodeOperation.VERIFY_AND_CHANGE_EMAIL;
58
+ idToken: IdToken;
59
+ newEmail: string;
60
+ }
61
+ interface GetOobCodeResponse {
62
+ email: string;
63
+ }
64
+ export interface VerifyEmailResponse extends GetOobCodeResponse {
65
+ }
66
+ export interface PasswordResetResponse extends GetOobCodeResponse {
67
+ }
68
+ export interface EmailSignInResponse extends GetOobCodeResponse {
69
+ }
70
+ export interface VerifyAndChangeEmailResponse extends GetOobCodeRequest {
71
+ }
72
+ export declare function sendEmailVerification(auth: Auth, request: VerifyEmailRequest): Promise<VerifyEmailResponse>;
73
+ export declare function sendPasswordResetEmail(auth: Auth, request: PasswordResetRequest): Promise<PasswordResetResponse>;
74
+ export declare function sendSignInLinkToEmail(auth: Auth, request: EmailSignInRequest): Promise<EmailSignInResponse>;
75
+ export declare function verifyAndChangeEmail(auth: Auth, request: VerifyAndChangeEmailRequest): Promise<VerifyAndChangeEmailResponse>;
76
+ 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,32 @@
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 SignInWithEmailLinkRequest {
20
+ email: string;
21
+ oobCode: string;
22
+ tenantId?: string;
23
+ }
24
+ export interface SignInWithEmailLinkResponse extends IdTokenResponse {
25
+ email: string;
26
+ isNewUser: boolean;
27
+ }
28
+ export declare function signInWithEmailLink(auth: Auth, request: SignInWithEmailLinkRequest): Promise<SignInWithEmailLinkResponse>;
29
+ export interface SignInWithEmailLinkForLinkingRequest extends SignInWithEmailLinkRequest {
30
+ idToken: string;
31
+ }
32
+ export declare function signInWithEmailLinkForLinking(auth: Auth, request: SignInWithEmailLinkForLinkingRequest): Promise<SignInWithEmailLinkResponse>;
@@ -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,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>>;