@owbase/node 0.0.0-stage → 1.0.1
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/LICENSE +29 -0
- package/NOTICE +134 -0
- package/README.md +78 -2
- package/dist/client.d.mts +235 -0
- package/dist/client.d.ts +235 -0
- package/dist/client.js +710 -0
- package/dist/client.js.map +1 -0
- package/dist/client.mjs +700 -0
- package/dist/client.mjs.map +1 -0
- package/dist/enums/adapter.d.mts +6 -0
- package/dist/enums/adapter.d.ts +6 -0
- package/dist/enums/adapter.js +11 -0
- package/dist/enums/adapter.js.map +1 -0
- package/dist/enums/adapter.mjs +10 -0
- package/dist/enums/adapter.mjs.map +1 -0
- package/dist/enums/attribute-status.d.mts +9 -0
- package/dist/enums/attribute-status.d.ts +9 -0
- package/dist/enums/attribute-status.js +14 -0
- package/dist/enums/attribute-status.js.map +1 -0
- package/dist/enums/attribute-status.mjs +13 -0
- package/dist/enums/attribute-status.mjs.map +1 -0
- package/dist/enums/authentication-factor.d.mts +9 -0
- package/dist/enums/authentication-factor.d.ts +9 -0
- package/dist/enums/authentication-factor.js +14 -0
- package/dist/enums/authentication-factor.js.map +1 -0
- package/dist/enums/authentication-factor.mjs +13 -0
- package/dist/enums/authentication-factor.mjs.map +1 -0
- package/dist/enums/authenticator-type.d.mts +5 -0
- package/dist/enums/authenticator-type.d.ts +5 -0
- package/dist/enums/authenticator-type.js +10 -0
- package/dist/enums/authenticator-type.js.map +1 -0
- package/dist/enums/authenticator-type.mjs +9 -0
- package/dist/enums/authenticator-type.mjs.map +1 -0
- package/dist/enums/browser-permission.d.mts +24 -0
- package/dist/enums/browser-permission.d.ts +24 -0
- package/dist/enums/browser-permission.js +29 -0
- package/dist/enums/browser-permission.js.map +1 -0
- package/dist/enums/browser-permission.mjs +28 -0
- package/dist/enums/browser-permission.mjs.map +1 -0
- package/dist/enums/browser-theme.d.mts +6 -0
- package/dist/enums/browser-theme.d.ts +6 -0
- package/dist/enums/browser-theme.js +11 -0
- package/dist/enums/browser-theme.js.map +1 -0
- package/dist/enums/browser-theme.mjs +10 -0
- package/dist/enums/browser-theme.mjs.map +1 -0
- package/dist/enums/browser.d.mts +18 -0
- package/dist/enums/browser.d.ts +18 -0
- package/dist/enums/browser.js +23 -0
- package/dist/enums/browser.js.map +1 -0
- package/dist/enums/browser.mjs +22 -0
- package/dist/enums/browser.mjs.map +1 -0
- package/dist/enums/build-runtime.d.mts +102 -0
- package/dist/enums/build-runtime.d.ts +102 -0
- package/dist/enums/build-runtime.js +107 -0
- package/dist/enums/build-runtime.js.map +1 -0
- package/dist/enums/build-runtime.mjs +106 -0
- package/dist/enums/build-runtime.mjs.map +1 -0
- package/dist/enums/column-status.d.mts +9 -0
- package/dist/enums/column-status.d.ts +9 -0
- package/dist/enums/column-status.js +14 -0
- package/dist/enums/column-status.js.map +1 -0
- package/dist/enums/column-status.mjs +13 -0
- package/dist/enums/column-status.mjs.map +1 -0
- package/dist/enums/compression.d.mts +7 -0
- package/dist/enums/compression.d.ts +7 -0
- package/dist/enums/compression.js +12 -0
- package/dist/enums/compression.js.map +1 -0
- package/dist/enums/compression.mjs +11 -0
- package/dist/enums/compression.mjs.map +1 -0
- package/dist/enums/credit-card.d.mts +21 -0
- package/dist/enums/credit-card.d.ts +21 -0
- package/dist/enums/credit-card.js +26 -0
- package/dist/enums/credit-card.js.map +1 -0
- package/dist/enums/credit-card.mjs +25 -0
- package/dist/enums/credit-card.mjs.map +1 -0
- package/dist/enums/database-status.d.mts +7 -0
- package/dist/enums/database-status.d.ts +7 -0
- package/dist/enums/database-status.js +12 -0
- package/dist/enums/database-status.js.map +1 -0
- package/dist/enums/database-status.mjs +11 -0
- package/dist/enums/database-status.mjs.map +1 -0
- package/dist/enums/database-type.d.mts +8 -0
- package/dist/enums/database-type.d.ts +8 -0
- package/dist/enums/database-type.js +13 -0
- package/dist/enums/database-type.js.map +1 -0
- package/dist/enums/database-type.mjs +12 -0
- package/dist/enums/database-type.mjs.map +1 -0
- package/dist/enums/databases-index-type.d.mts +8 -0
- package/dist/enums/databases-index-type.d.ts +8 -0
- package/dist/enums/databases-index-type.js +13 -0
- package/dist/enums/databases-index-type.js.map +1 -0
- package/dist/enums/databases-index-type.mjs +12 -0
- package/dist/enums/databases-index-type.mjs.map +1 -0
- package/dist/enums/deployment-download-type.d.mts +6 -0
- package/dist/enums/deployment-download-type.d.ts +6 -0
- package/dist/enums/deployment-download-type.js +11 -0
- package/dist/enums/deployment-download-type.js.map +1 -0
- package/dist/enums/deployment-download-type.mjs +10 -0
- package/dist/enums/deployment-download-type.mjs.map +1 -0
- package/dist/enums/deployment-status.d.mts +10 -0
- package/dist/enums/deployment-status.d.ts +10 -0
- package/dist/enums/deployment-status.js +15 -0
- package/dist/enums/deployment-status.js.map +1 -0
- package/dist/enums/deployment-status.mjs +14 -0
- package/dist/enums/deployment-status.mjs.map +1 -0
- package/dist/enums/embedding-model.d.mts +6 -0
- package/dist/enums/embedding-model.d.ts +6 -0
- package/dist/enums/embedding-model.js +11 -0
- package/dist/enums/embedding-model.js.map +1 -0
- package/dist/enums/embedding-model.mjs +10 -0
- package/dist/enums/embedding-model.mjs.map +1 -0
- package/dist/enums/execution-method.d.mts +11 -0
- package/dist/enums/execution-method.d.ts +11 -0
- package/dist/enums/execution-method.js +16 -0
- package/dist/enums/execution-method.js.map +1 -0
- package/dist/enums/execution-method.mjs +15 -0
- package/dist/enums/execution-method.mjs.map +1 -0
- package/dist/enums/execution-resource-type.d.mts +6 -0
- package/dist/enums/execution-resource-type.d.ts +6 -0
- package/dist/enums/execution-resource-type.js +11 -0
- package/dist/enums/execution-resource-type.js.map +1 -0
- package/dist/enums/execution-resource-type.mjs +10 -0
- package/dist/enums/execution-resource-type.mjs.map +1 -0
- package/dist/enums/execution-status.d.mts +9 -0
- package/dist/enums/execution-status.d.ts +9 -0
- package/dist/enums/execution-status.js +14 -0
- package/dist/enums/execution-status.js.map +1 -0
- package/dist/enums/execution-status.mjs +13 -0
- package/dist/enums/execution-status.mjs.map +1 -0
- package/dist/enums/execution-trigger.d.mts +7 -0
- package/dist/enums/execution-trigger.d.ts +7 -0
- package/dist/enums/execution-trigger.js +12 -0
- package/dist/enums/execution-trigger.js.map +1 -0
- package/dist/enums/execution-trigger.mjs +11 -0
- package/dist/enums/execution-trigger.mjs.map +1 -0
- package/dist/enums/flag.d.mts +199 -0
- package/dist/enums/flag.d.ts +199 -0
- package/dist/enums/flag.js +204 -0
- package/dist/enums/flag.js.map +1 -0
- package/dist/enums/flag.mjs +203 -0
- package/dist/enums/flag.mjs.map +1 -0
- package/dist/enums/framework.d.mts +20 -0
- package/dist/enums/framework.d.ts +20 -0
- package/dist/enums/framework.js +25 -0
- package/dist/enums/framework.js.map +1 -0
- package/dist/enums/framework.mjs +24 -0
- package/dist/enums/framework.mjs.map +1 -0
- package/dist/enums/id-token-provider.d.mts +6 -0
- package/dist/enums/id-token-provider.d.ts +6 -0
- package/dist/enums/id-token-provider.js +11 -0
- package/dist/enums/id-token-provider.js.map +1 -0
- package/dist/enums/id-token-provider.mjs +10 -0
- package/dist/enums/id-token-provider.mjs.map +1 -0
- package/dist/enums/image-format.d.mts +11 -0
- package/dist/enums/image-format.d.ts +11 -0
- package/dist/enums/image-format.js +16 -0
- package/dist/enums/image-format.js.map +1 -0
- package/dist/enums/image-format.mjs +15 -0
- package/dist/enums/image-format.mjs.map +1 -0
- package/dist/enums/image-gravity.d.mts +14 -0
- package/dist/enums/image-gravity.d.ts +14 -0
- package/dist/enums/image-gravity.js +19 -0
- package/dist/enums/image-gravity.js.map +1 -0
- package/dist/enums/image-gravity.mjs +18 -0
- package/dist/enums/image-gravity.mjs.map +1 -0
- package/dist/enums/index-status.d.mts +9 -0
- package/dist/enums/index-status.d.ts +9 -0
- package/dist/enums/index-status.js +14 -0
- package/dist/enums/index-status.js.map +1 -0
- package/dist/enums/index-status.mjs +13 -0
- package/dist/enums/index-status.mjs.map +1 -0
- package/dist/enums/message-priority.d.mts +6 -0
- package/dist/enums/message-priority.d.ts +6 -0
- package/dist/enums/message-priority.js +11 -0
- package/dist/enums/message-priority.js.map +1 -0
- package/dist/enums/message-priority.mjs +10 -0
- package/dist/enums/message-priority.mjs.map +1 -0
- package/dist/enums/message-status.d.mts +9 -0
- package/dist/enums/message-status.d.ts +9 -0
- package/dist/enums/message-status.js +14 -0
- package/dist/enums/message-status.js.map +1 -0
- package/dist/enums/message-status.mjs +13 -0
- package/dist/enums/message-status.mjs.map +1 -0
- package/dist/enums/messaging-provider-type.d.mts +7 -0
- package/dist/enums/messaging-provider-type.d.ts +7 -0
- package/dist/enums/messaging-provider-type.js +12 -0
- package/dist/enums/messaging-provider-type.js.map +1 -0
- package/dist/enums/messaging-provider-type.mjs +11 -0
- package/dist/enums/messaging-provider-type.mjs.map +1 -0
- package/dist/enums/o-auth-2-auth-0-prompt.d.mts +7 -0
- package/dist/enums/o-auth-2-auth-0-prompt.d.ts +7 -0
- package/dist/enums/o-auth-2-auth-0-prompt.js +12 -0
- package/dist/enums/o-auth-2-auth-0-prompt.js.map +1 -0
- package/dist/enums/o-auth-2-auth-0-prompt.mjs +11 -0
- package/dist/enums/o-auth-2-auth-0-prompt.mjs.map +1 -0
- package/dist/enums/o-auth-2-discord-prompt.d.mts +6 -0
- package/dist/enums/o-auth-2-discord-prompt.d.ts +6 -0
- package/dist/enums/o-auth-2-discord-prompt.js +11 -0
- package/dist/enums/o-auth-2-discord-prompt.js.map +1 -0
- package/dist/enums/o-auth-2-discord-prompt.mjs +10 -0
- package/dist/enums/o-auth-2-discord-prompt.mjs.map +1 -0
- package/dist/enums/o-auth-2-github-prompt.d.mts +5 -0
- package/dist/enums/o-auth-2-github-prompt.d.ts +5 -0
- package/dist/enums/o-auth-2-github-prompt.js +10 -0
- package/dist/enums/o-auth-2-github-prompt.js.map +1 -0
- package/dist/enums/o-auth-2-github-prompt.mjs +9 -0
- package/dist/enums/o-auth-2-github-prompt.mjs.map +1 -0
- package/dist/enums/o-auth-2-google-prompt.d.mts +7 -0
- package/dist/enums/o-auth-2-google-prompt.d.ts +7 -0
- package/dist/enums/o-auth-2-google-prompt.js +12 -0
- package/dist/enums/o-auth-2-google-prompt.js.map +1 -0
- package/dist/enums/o-auth-2-google-prompt.mjs +11 -0
- package/dist/enums/o-auth-2-google-prompt.mjs.map +1 -0
- package/dist/enums/o-auth-2-kakao-prompt.d.mts +8 -0
- package/dist/enums/o-auth-2-kakao-prompt.d.ts +8 -0
- package/dist/enums/o-auth-2-kakao-prompt.js +13 -0
- package/dist/enums/o-auth-2-kakao-prompt.js.map +1 -0
- package/dist/enums/o-auth-2-kakao-prompt.mjs +12 -0
- package/dist/enums/o-auth-2-kakao-prompt.mjs.map +1 -0
- package/dist/enums/o-auth-2-microsoft-prompt.d.mts +8 -0
- package/dist/enums/o-auth-2-microsoft-prompt.d.ts +8 -0
- package/dist/enums/o-auth-2-microsoft-prompt.js +13 -0
- package/dist/enums/o-auth-2-microsoft-prompt.js.map +1 -0
- package/dist/enums/o-auth-2-microsoft-prompt.mjs +12 -0
- package/dist/enums/o-auth-2-microsoft-prompt.mjs.map +1 -0
- package/dist/enums/o-auth-2-oidc-prompt.d.mts +8 -0
- package/dist/enums/o-auth-2-oidc-prompt.d.ts +8 -0
- package/dist/enums/o-auth-2-oidc-prompt.js +13 -0
- package/dist/enums/o-auth-2-oidc-prompt.js.map +1 -0
- package/dist/enums/o-auth-2-oidc-prompt.mjs +12 -0
- package/dist/enums/o-auth-2-oidc-prompt.mjs.map +1 -0
- package/dist/enums/o-auth-2-okta-prompt.d.mts +7 -0
- package/dist/enums/o-auth-2-okta-prompt.d.ts +7 -0
- package/dist/enums/o-auth-2-okta-prompt.js +12 -0
- package/dist/enums/o-auth-2-okta-prompt.js.map +1 -0
- package/dist/enums/o-auth-2-okta-prompt.mjs +11 -0
- package/dist/enums/o-auth-2-okta-prompt.mjs.map +1 -0
- package/dist/enums/o-auth-2-salesforce-prompt.d.mts +6 -0
- package/dist/enums/o-auth-2-salesforce-prompt.d.ts +6 -0
- package/dist/enums/o-auth-2-salesforce-prompt.js +11 -0
- package/dist/enums/o-auth-2-salesforce-prompt.js.map +1 -0
- package/dist/enums/o-auth-2-salesforce-prompt.mjs +10 -0
- package/dist/enums/o-auth-2-salesforce-prompt.mjs.map +1 -0
- package/dist/enums/o-auth-2-zoho-prompt.d.mts +5 -0
- package/dist/enums/o-auth-2-zoho-prompt.d.ts +5 -0
- package/dist/enums/o-auth-2-zoho-prompt.js +10 -0
- package/dist/enums/o-auth-2-zoho-prompt.js.map +1 -0
- package/dist/enums/o-auth-2-zoho-prompt.mjs +9 -0
- package/dist/enums/o-auth-2-zoho-prompt.mjs.map +1 -0
- package/dist/enums/o-auth-provider.d.mts +53 -0
- package/dist/enums/o-auth-provider.d.ts +53 -0
- package/dist/enums/o-auth-provider.js +58 -0
- package/dist/enums/o-auth-provider.js.map +1 -0
- package/dist/enums/o-auth-provider.mjs +57 -0
- package/dist/enums/o-auth-provider.mjs.map +1 -0
- package/dist/enums/order-by.d.mts +6 -0
- package/dist/enums/order-by.d.ts +6 -0
- package/dist/enums/order-by.js +11 -0
- package/dist/enums/order-by.js.map +1 -0
- package/dist/enums/order-by.mjs +10 -0
- package/dist/enums/order-by.mjs.map +1 -0
- package/dist/enums/password-hash.d.mts +15 -0
- package/dist/enums/password-hash.d.ts +15 -0
- package/dist/enums/password-hash.js +20 -0
- package/dist/enums/password-hash.js.map +1 -0
- package/dist/enums/password-hash.mjs +19 -0
- package/dist/enums/password-hash.mjs.map +1 -0
- package/dist/enums/platform-type.d.mts +9 -0
- package/dist/enums/platform-type.d.ts +9 -0
- package/dist/enums/platform-type.js +14 -0
- package/dist/enums/platform-type.js.map +1 -0
- package/dist/enums/platform-type.mjs +13 -0
- package/dist/enums/platform-type.mjs.map +1 -0
- package/dist/enums/project-auth-method-id.d.mts +12 -0
- package/dist/enums/project-auth-method-id.d.ts +12 -0
- package/dist/enums/project-auth-method-id.js +17 -0
- package/dist/enums/project-auth-method-id.js.map +1 -0
- package/dist/enums/project-auth-method-id.mjs +16 -0
- package/dist/enums/project-auth-method-id.mjs.map +1 -0
- package/dist/enums/project-email-template-id.d.mts +13 -0
- package/dist/enums/project-email-template-id.d.ts +13 -0
- package/dist/enums/project-email-template-id.js +18 -0
- package/dist/enums/project-email-template-id.js.map +1 -0
- package/dist/enums/project-email-template-id.mjs +17 -0
- package/dist/enums/project-email-template-id.mjs.map +1 -0
- package/dist/enums/project-email-template-locale.d.mts +135 -0
- package/dist/enums/project-email-template-locale.d.ts +135 -0
- package/dist/enums/project-email-template-locale.js +140 -0
- package/dist/enums/project-email-template-locale.js.map +1 -0
- package/dist/enums/project-email-template-locale.mjs +139 -0
- package/dist/enums/project-email-template-locale.mjs.map +1 -0
- package/dist/enums/project-key-scopes.d.mts +109 -0
- package/dist/enums/project-key-scopes.d.ts +109 -0
- package/dist/enums/project-key-scopes.js +114 -0
- package/dist/enums/project-key-scopes.js.map +1 -0
- package/dist/enums/project-key-scopes.mjs +113 -0
- package/dist/enums/project-key-scopes.mjs.map +1 -0
- package/dist/enums/project-o-auth-2-auth-0-prompt.d.mts +7 -0
- package/dist/enums/project-o-auth-2-auth-0-prompt.d.ts +7 -0
- package/dist/enums/project-o-auth-2-auth-0-prompt.js +12 -0
- package/dist/enums/project-o-auth-2-auth-0-prompt.js.map +1 -0
- package/dist/enums/project-o-auth-2-auth-0-prompt.mjs +11 -0
- package/dist/enums/project-o-auth-2-auth-0-prompt.mjs.map +1 -0
- package/dist/enums/project-o-auth-2-discord-prompt.d.mts +6 -0
- package/dist/enums/project-o-auth-2-discord-prompt.d.ts +6 -0
- package/dist/enums/project-o-auth-2-discord-prompt.js +11 -0
- package/dist/enums/project-o-auth-2-discord-prompt.js.map +1 -0
- package/dist/enums/project-o-auth-2-discord-prompt.mjs +10 -0
- package/dist/enums/project-o-auth-2-discord-prompt.mjs.map +1 -0
- package/dist/enums/project-o-auth-2-git-hub-prompt.d.mts +5 -0
- package/dist/enums/project-o-auth-2-git-hub-prompt.d.ts +5 -0
- package/dist/enums/project-o-auth-2-git-hub-prompt.js +10 -0
- package/dist/enums/project-o-auth-2-git-hub-prompt.js.map +1 -0
- package/dist/enums/project-o-auth-2-git-hub-prompt.mjs +9 -0
- package/dist/enums/project-o-auth-2-git-hub-prompt.mjs.map +1 -0
- package/dist/enums/project-o-auth-2-google-prompt.d.mts +7 -0
- package/dist/enums/project-o-auth-2-google-prompt.d.ts +7 -0
- package/dist/enums/project-o-auth-2-google-prompt.js +12 -0
- package/dist/enums/project-o-auth-2-google-prompt.js.map +1 -0
- package/dist/enums/project-o-auth-2-google-prompt.mjs +11 -0
- package/dist/enums/project-o-auth-2-google-prompt.mjs.map +1 -0
- package/dist/enums/project-o-auth-2-kakao-prompt.d.mts +8 -0
- package/dist/enums/project-o-auth-2-kakao-prompt.d.ts +8 -0
- package/dist/enums/project-o-auth-2-kakao-prompt.js +13 -0
- package/dist/enums/project-o-auth-2-kakao-prompt.js.map +1 -0
- package/dist/enums/project-o-auth-2-kakao-prompt.mjs +12 -0
- package/dist/enums/project-o-auth-2-kakao-prompt.mjs.map +1 -0
- package/dist/enums/project-o-auth-2-microsoft-prompt.d.mts +8 -0
- package/dist/enums/project-o-auth-2-microsoft-prompt.d.ts +8 -0
- package/dist/enums/project-o-auth-2-microsoft-prompt.js +13 -0
- package/dist/enums/project-o-auth-2-microsoft-prompt.js.map +1 -0
- package/dist/enums/project-o-auth-2-microsoft-prompt.mjs +12 -0
- package/dist/enums/project-o-auth-2-microsoft-prompt.mjs.map +1 -0
- package/dist/enums/project-o-auth-2-oidc-prompt.d.mts +8 -0
- package/dist/enums/project-o-auth-2-oidc-prompt.d.ts +8 -0
- package/dist/enums/project-o-auth-2-oidc-prompt.js +13 -0
- package/dist/enums/project-o-auth-2-oidc-prompt.js.map +1 -0
- package/dist/enums/project-o-auth-2-oidc-prompt.mjs +12 -0
- package/dist/enums/project-o-auth-2-oidc-prompt.mjs.map +1 -0
- package/dist/enums/project-o-auth-2-okta-prompt.d.mts +7 -0
- package/dist/enums/project-o-auth-2-okta-prompt.d.ts +7 -0
- package/dist/enums/project-o-auth-2-okta-prompt.js +12 -0
- package/dist/enums/project-o-auth-2-okta-prompt.js.map +1 -0
- package/dist/enums/project-o-auth-2-okta-prompt.mjs +11 -0
- package/dist/enums/project-o-auth-2-okta-prompt.mjs.map +1 -0
- package/dist/enums/project-o-auth-2-salesforce-prompt.d.mts +6 -0
- package/dist/enums/project-o-auth-2-salesforce-prompt.d.ts +6 -0
- package/dist/enums/project-o-auth-2-salesforce-prompt.js +11 -0
- package/dist/enums/project-o-auth-2-salesforce-prompt.js.map +1 -0
- package/dist/enums/project-o-auth-2-salesforce-prompt.mjs +10 -0
- package/dist/enums/project-o-auth-2-salesforce-prompt.mjs.map +1 -0
- package/dist/enums/project-o-auth-2-zoho-prompt.d.mts +5 -0
- package/dist/enums/project-o-auth-2-zoho-prompt.d.ts +5 -0
- package/dist/enums/project-o-auth-2-zoho-prompt.js +10 -0
- package/dist/enums/project-o-auth-2-zoho-prompt.js.map +1 -0
- package/dist/enums/project-o-auth-2-zoho-prompt.mjs +9 -0
- package/dist/enums/project-o-auth-2-zoho-prompt.mjs.map +1 -0
- package/dist/enums/project-o-auth-provider-id.d.mts +53 -0
- package/dist/enums/project-o-auth-provider-id.d.ts +53 -0
- package/dist/enums/project-o-auth-provider-id.js +58 -0
- package/dist/enums/project-o-auth-provider-id.js.map +1 -0
- package/dist/enums/project-o-auth-provider-id.mjs +57 -0
- package/dist/enums/project-o-auth-provider-id.mjs.map +1 -0
- package/dist/enums/project-policy-id.d.mts +21 -0
- package/dist/enums/project-policy-id.d.ts +21 -0
- package/dist/enums/project-policy-id.js +26 -0
- package/dist/enums/project-policy-id.js.map +1 -0
- package/dist/enums/project-policy-id.mjs +25 -0
- package/dist/enums/project-policy-id.mjs.map +1 -0
- package/dist/enums/project-protocol-id.d.mts +7 -0
- package/dist/enums/project-protocol-id.d.ts +7 -0
- package/dist/enums/project-protocol-id.js +12 -0
- package/dist/enums/project-protocol-id.js.map +1 -0
- package/dist/enums/project-protocol-id.mjs +11 -0
- package/dist/enums/project-protocol-id.mjs.map +1 -0
- package/dist/enums/project-service-id.d.mts +22 -0
- package/dist/enums/project-service-id.d.ts +22 -0
- package/dist/enums/project-service-id.js +27 -0
- package/dist/enums/project-service-id.js.map +1 -0
- package/dist/enums/project-service-id.mjs +26 -0
- package/dist/enums/project-service-id.mjs.map +1 -0
- package/dist/enums/project-smtp-secure.d.mts +6 -0
- package/dist/enums/project-smtp-secure.d.ts +6 -0
- package/dist/enums/project-smtp-secure.js +11 -0
- package/dist/enums/project-smtp-secure.js.map +1 -0
- package/dist/enums/project-smtp-secure.mjs +10 -0
- package/dist/enums/project-smtp-secure.mjs.map +1 -0
- package/dist/enums/proxy-resource-type.d.mts +6 -0
- package/dist/enums/proxy-resource-type.d.ts +6 -0
- package/dist/enums/proxy-resource-type.js +11 -0
- package/dist/enums/proxy-resource-type.js.map +1 -0
- package/dist/enums/proxy-resource-type.mjs +10 -0
- package/dist/enums/proxy-resource-type.mjs.map +1 -0
- package/dist/enums/proxy-rule-deployment-resource-type.d.mts +6 -0
- package/dist/enums/proxy-rule-deployment-resource-type.d.ts +6 -0
- package/dist/enums/proxy-rule-deployment-resource-type.js +11 -0
- package/dist/enums/proxy-rule-deployment-resource-type.js.map +1 -0
- package/dist/enums/proxy-rule-deployment-resource-type.mjs +10 -0
- package/dist/enums/proxy-rule-deployment-resource-type.mjs.map +1 -0
- package/dist/enums/proxy-rule-status.d.mts +7 -0
- package/dist/enums/proxy-rule-status.d.ts +7 -0
- package/dist/enums/proxy-rule-status.js +12 -0
- package/dist/enums/proxy-rule-status.js.map +1 -0
- package/dist/enums/proxy-rule-status.mjs +11 -0
- package/dist/enums/proxy-rule-status.mjs.map +1 -0
- package/dist/enums/region.d.mts +5 -0
- package/dist/enums/region.d.ts +5 -0
- package/dist/enums/region.js +10 -0
- package/dist/enums/region.js.map +1 -0
- package/dist/enums/region.mjs +9 -0
- package/dist/enums/region.mjs.map +1 -0
- package/dist/enums/relation-mutate.d.mts +7 -0
- package/dist/enums/relation-mutate.d.ts +7 -0
- package/dist/enums/relation-mutate.js +12 -0
- package/dist/enums/relation-mutate.js.map +1 -0
- package/dist/enums/relation-mutate.mjs +11 -0
- package/dist/enums/relation-mutate.mjs.map +1 -0
- package/dist/enums/relationship-type.d.mts +8 -0
- package/dist/enums/relationship-type.d.ts +8 -0
- package/dist/enums/relationship-type.js +13 -0
- package/dist/enums/relationship-type.js.map +1 -0
- package/dist/enums/relationship-type.mjs +12 -0
- package/dist/enums/relationship-type.mjs.map +1 -0
- package/dist/enums/runtime.d.mts +102 -0
- package/dist/enums/runtime.d.ts +102 -0
- package/dist/enums/runtime.js +107 -0
- package/dist/enums/runtime.js.map +1 -0
- package/dist/enums/runtime.mjs +106 -0
- package/dist/enums/runtime.mjs.map +1 -0
- package/dist/enums/smtp-encryption.d.mts +7 -0
- package/dist/enums/smtp-encryption.d.ts +7 -0
- package/dist/enums/smtp-encryption.js +12 -0
- package/dist/enums/smtp-encryption.js.map +1 -0
- package/dist/enums/smtp-encryption.mjs +11 -0
- package/dist/enums/smtp-encryption.mjs.map +1 -0
- package/dist/enums/status-code.d.mts +8 -0
- package/dist/enums/status-code.d.ts +8 -0
- package/dist/enums/status-code.js +13 -0
- package/dist/enums/status-code.js.map +1 -0
- package/dist/enums/status-code.mjs +12 -0
- package/dist/enums/status-code.mjs.map +1 -0
- package/dist/enums/tables-db-index-type.d.mts +8 -0
- package/dist/enums/tables-db-index-type.d.ts +8 -0
- package/dist/enums/tables-db-index-type.js +13 -0
- package/dist/enums/tables-db-index-type.js.map +1 -0
- package/dist/enums/tables-db-index-type.mjs +12 -0
- package/dist/enums/tables-db-index-type.mjs.map +1 -0
- package/dist/enums/template-reference-type.d.mts +7 -0
- package/dist/enums/template-reference-type.d.ts +7 -0
- package/dist/enums/template-reference-type.js +12 -0
- package/dist/enums/template-reference-type.js.map +1 -0
- package/dist/enums/template-reference-type.mjs +11 -0
- package/dist/enums/template-reference-type.mjs.map +1 -0
- package/dist/enums/timezone.d.mts +423 -0
- package/dist/enums/timezone.d.ts +423 -0
- package/dist/enums/timezone.js +428 -0
- package/dist/enums/timezone.js.map +1 -0
- package/dist/enums/timezone.mjs +427 -0
- package/dist/enums/timezone.mjs.map +1 -0
- package/dist/enums/vcs-reference-type.d.mts +7 -0
- package/dist/enums/vcs-reference-type.d.ts +7 -0
- package/dist/enums/vcs-reference-type.js +12 -0
- package/dist/enums/vcs-reference-type.js.map +1 -0
- package/dist/enums/vcs-reference-type.mjs +11 -0
- package/dist/enums/vcs-reference-type.mjs.map +1 -0
- package/dist/id.d.mts +22 -0
- package/dist/id.d.ts +22 -0
- package/dist/id.js +45 -0
- package/dist/id.js.map +1 -0
- package/dist/id.mjs +44 -0
- package/dist/id.mjs.map +1 -0
- package/dist/index.d.mts +106 -0
- package/dist/index.d.ts +106 -0
- package/dist/index.js +533 -0
- package/dist/index.js.map +1 -0
- package/dist/index.mjs +104 -0
- package/dist/index.mjs.map +1 -0
- package/dist/inputFile.d.mts +21 -0
- package/dist/inputFile.d.ts +21 -0
- package/dist/inputFile.js +133 -0
- package/dist/inputFile.js.map +1 -0
- package/dist/inputFile.mjs +132 -0
- package/dist/inputFile.mjs.map +1 -0
- package/dist/models.d.mts +6790 -0
- package/dist/models.d.ts +6790 -0
- package/dist/models.js +4 -0
- package/dist/models.js.map +1 -0
- package/dist/models.mjs +3 -0
- package/dist/models.mjs.map +1 -0
- package/dist/operator.d.mts +181 -0
- package/dist/operator.d.ts +181 -0
- package/dist/operator.js +271 -0
- package/dist/operator.js.map +1 -0
- package/dist/operator.mjs +269 -0
- package/dist/operator.mjs.map +1 -0
- package/dist/permission.d.mts +45 -0
- package/dist/permission.d.ts +45 -0
- package/dist/permission.js +56 -0
- package/dist/permission.js.map +1 -0
- package/dist/permission.mjs +55 -0
- package/dist/permission.mjs.map +1 -0
- package/dist/query.d.mts +467 -0
- package/dist/query.d.ts +467 -0
- package/dist/query.js +517 -0
- package/dist/query.js.map +1 -0
- package/dist/query.mjs +512 -0
- package/dist/query.mjs.map +1 -0
- package/dist/role.d.mts +72 -0
- package/dist/role.d.ts +72 -0
- package/dist/role.js +96 -0
- package/dist/role.js.map +1 -0
- package/dist/role.mjs +95 -0
- package/dist/role.mjs.map +1 -0
- package/dist/services/account.d.mts +1349 -0
- package/dist/services/account.d.ts +1349 -0
- package/dist/services/account.js +1891 -0
- package/dist/services/account.js.map +1 -0
- package/dist/services/account.mjs +1890 -0
- package/dist/services/account.mjs.map +1 -0
- package/dist/services/advisor.d.mts +154 -0
- package/dist/services/advisor.d.ts +154 -0
- package/dist/services/advisor.js +155 -0
- package/dist/services/advisor.js.map +1 -0
- package/dist/services/advisor.mjs +154 -0
- package/dist/services/advisor.mjs.map +1 -0
- package/dist/services/avatars.d.mts +424 -0
- package/dist/services/avatars.d.ts +424 -0
- package/dist/services/avatars.js +553 -0
- package/dist/services/avatars.js.map +1 -0
- package/dist/services/avatars.mjs +552 -0
- package/dist/services/avatars.mjs.map +1 -0
- package/dist/services/databases.d.mts +2424 -0
- package/dist/services/databases.d.ts +2424 -0
- package/dist/services/databases.js +3878 -0
- package/dist/services/databases.js.map +1 -0
- package/dist/services/databases.mjs +3877 -0
- package/dist/services/databases.mjs.map +1 -0
- package/dist/services/embeddings.d.mts +62 -0
- package/dist/services/embeddings.d.ts +62 -0
- package/dist/services/embeddings.js +44 -0
- package/dist/services/embeddings.js.map +1 -0
- package/dist/services/embeddings.mjs +43 -0
- package/dist/services/embeddings.mjs.map +1 -0
- package/dist/services/functions.d.mts +831 -0
- package/dist/services/functions.d.ts +831 -0
- package/dist/services/functions.js +1258 -0
- package/dist/services/functions.js.map +1 -0
- package/dist/services/functions.mjs +1257 -0
- package/dist/services/functions.mjs.map +1 -0
- package/dist/services/graphql.d.mts +75 -0
- package/dist/services/graphql.d.ts +75 -0
- package/dist/services/graphql.js +67 -0
- package/dist/services/graphql.js.map +1 -0
- package/dist/services/graphql.mjs +66 -0
- package/dist/services/graphql.mjs.map +1 -0
- package/dist/services/locale.d.mts +179 -0
- package/dist/services/locale.d.ts +179 -0
- package/dist/services/locale.js +183 -0
- package/dist/services/locale.js.map +1 -0
- package/dist/services/locale.mjs +182 -0
- package/dist/services/locale.mjs.map +1 -0
- package/dist/services/messaging.d.mts +2042 -0
- package/dist/services/messaging.d.ts +2042 -0
- package/dist/services/messaging.js +3148 -0
- package/dist/services/messaging.js.map +1 -0
- package/dist/services/messaging.mjs +3147 -0
- package/dist/services/messaging.mjs.map +1 -0
- package/dist/services/organization.d.mts +278 -0
- package/dist/services/organization.d.ts +278 -0
- package/dist/services/organization.js +368 -0
- package/dist/services/organization.js.map +1 -0
- package/dist/services/organization.mjs +367 -0
- package/dist/services/organization.mjs.map +1 -0
- package/dist/services/presences.d.mts +181 -0
- package/dist/services/presences.d.ts +181 -0
- package/dist/services/presences.js +220 -0
- package/dist/services/presences.js.map +1 -0
- package/dist/services/presences.mjs +219 -0
- package/dist/services/presences.mjs.map +1 -0
- package/dist/services/project.d.mts +2689 -0
- package/dist/services/project.d.ts +2689 -0
- package/dist/services/project.js +3753 -0
- package/dist/services/project.js.map +1 -0
- package/dist/services/project.mjs +3752 -0
- package/dist/services/project.mjs.map +1 -0
- package/dist/services/proxy.d.mts +234 -0
- package/dist/services/proxy.d.ts +234 -0
- package/dist/services/proxy.js +287 -0
- package/dist/services/proxy.js.map +1 -0
- package/dist/services/proxy.mjs +286 -0
- package/dist/services/proxy.mjs.map +1 -0
- package/dist/services/sites.d.mts +799 -0
- package/dist/services/sites.d.ts +799 -0
- package/dist/services/sites.js +1181 -0
- package/dist/services/sites.js.map +1 -0
- package/dist/services/sites.mjs +1180 -0
- package/dist/services/sites.mjs.map +1 -0
- package/dist/services/storage.d.mts +456 -0
- package/dist/services/storage.d.ts +456 -0
- package/dist/services/storage.js +617 -0
- package/dist/services/storage.js.map +1 -0
- package/dist/services/storage.mjs +616 -0
- package/dist/services/storage.mjs.map +1 -0
- package/dist/services/tables-db.d.mts +2353 -0
- package/dist/services/tables-db.d.ts +2353 -0
- package/dist/services/tables-db.js +3550 -0
- package/dist/services/tables-db.js.map +1 -0
- package/dist/services/tables-db.mjs +3549 -0
- package/dist/services/tables-db.mjs.map +1 -0
- package/dist/services/teams.d.mts +372 -0
- package/dist/services/teams.d.ts +372 -0
- package/dist/services/teams.js +482 -0
- package/dist/services/teams.js.map +1 -0
- package/dist/services/teams.mjs +481 -0
- package/dist/services/teams.mjs.map +1 -0
- package/dist/services/tokens.d.mts +150 -0
- package/dist/services/tokens.d.ts +150 -0
- package/dist/services/tokens.js +165 -0
- package/dist/services/tokens.js.map +1 -0
- package/dist/services/tokens.mjs +164 -0
- package/dist/services/tokens.mjs.map +1 -0
- package/dist/services/users.d.mts +1308 -0
- package/dist/services/users.d.ts +1308 -0
- package/dist/services/users.js +1897 -0
- package/dist/services/users.js.map +1 -0
- package/dist/services/users.mjs +1896 -0
- package/dist/services/users.mjs.map +1 -0
- package/dist/services/webhooks.d.mts +202 -0
- package/dist/services/webhooks.d.ts +202 -0
- package/dist/services/webhooks.js +277 -0
- package/dist/services/webhooks.js.map +1 -0
- package/dist/services/webhooks.mjs +276 -0
- package/dist/services/webhooks.mjs.map +1 -0
- package/dist/topic.d.mts +36 -0
- package/dist/topic.d.ts +36 -0
- package/dist/topic.js +86 -0
- package/dist/topic.js.map +1 -0
- package/dist/topic.mjs +84 -0
- package/dist/topic.mjs.map +1 -0
- package/package.json +82 -5
|
@@ -0,0 +1,1349 @@
|
|
|
1
|
+
import { Client } from '../client.mjs';
|
|
2
|
+
import { Models } from '../models.mjs';
|
|
3
|
+
import { AuthenticatorType } from '../enums/authenticator-type.mjs';
|
|
4
|
+
import { AuthenticationFactor } from '../enums/authentication-factor.mjs';
|
|
5
|
+
import { IdTokenProvider } from '../enums/id-token-provider.mjs';
|
|
6
|
+
import { OAuthProvider } from '../enums/o-auth-provider.mjs';
|
|
7
|
+
import 'undici';
|
|
8
|
+
import '../query.mjs';
|
|
9
|
+
import '../enums/database-type.mjs';
|
|
10
|
+
import '../enums/database-status.mjs';
|
|
11
|
+
import '../enums/attribute-status.mjs';
|
|
12
|
+
import '../enums/column-status.mjs';
|
|
13
|
+
import '../enums/index-status.mjs';
|
|
14
|
+
import '../enums/deployment-status.mjs';
|
|
15
|
+
import '../enums/execution-resource-type.mjs';
|
|
16
|
+
import '../enums/execution-trigger.mjs';
|
|
17
|
+
import '../enums/execution-status.mjs';
|
|
18
|
+
import '../enums/project-auth-method-id.mjs';
|
|
19
|
+
import '../enums/project-service-id.mjs';
|
|
20
|
+
import '../enums/project-protocol-id.mjs';
|
|
21
|
+
import '../enums/o-auth-2-github-prompt.mjs';
|
|
22
|
+
import '../enums/o-auth-2-discord-prompt.mjs';
|
|
23
|
+
import '../enums/o-auth-2-google-prompt.mjs';
|
|
24
|
+
import '../enums/o-auth-2-zoho-prompt.mjs';
|
|
25
|
+
import '../enums/o-auth-2-salesforce-prompt.mjs';
|
|
26
|
+
import '../enums/o-auth-2-auth-0-prompt.mjs';
|
|
27
|
+
import '../enums/o-auth-2-oidc-prompt.mjs';
|
|
28
|
+
import '../enums/o-auth-2-okta-prompt.mjs';
|
|
29
|
+
import '../enums/o-auth-2-microsoft-prompt.mjs';
|
|
30
|
+
import '../enums/o-auth-2-kakao-prompt.mjs';
|
|
31
|
+
import '../enums/platform-type.mjs';
|
|
32
|
+
import '../enums/proxy-rule-deployment-resource-type.mjs';
|
|
33
|
+
import '../enums/proxy-rule-status.mjs';
|
|
34
|
+
import '../enums/message-status.mjs';
|
|
35
|
+
|
|
36
|
+
declare class Account {
|
|
37
|
+
client: Client;
|
|
38
|
+
constructor(client: Client);
|
|
39
|
+
/**
|
|
40
|
+
* Get the currently logged in user.
|
|
41
|
+
*
|
|
42
|
+
* @throws {OwbaseException}
|
|
43
|
+
* @returns {Promise<Models.User<Preferences>>}
|
|
44
|
+
*/
|
|
45
|
+
get<Preferences extends Models.Preferences = Models.DefaultPreferences>(): Promise<Models.User<Preferences>>;
|
|
46
|
+
/**
|
|
47
|
+
* Use this endpoint to allow a new user to register a new account in your project. After the user registration completes successfully, you can use the [/account/verfication](https://docs.owbase.dev/references/cloud/client-web/account#createVerification) route to start verifying the user email address. To allow the new user to login to their new account, you need to create a new [account session](https://docs.owbase.dev/references/cloud/client-web/account#createEmailSession).
|
|
48
|
+
*
|
|
49
|
+
* @param {string} params.userId - User ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars.
|
|
50
|
+
* @param {string} params.email - User email.
|
|
51
|
+
* @param {string} params.password - New user password. Must be between 8 and 256 chars.
|
|
52
|
+
* @param {string} params.name - User name. Max length: 128 chars.
|
|
53
|
+
* @throws {OwbaseException}
|
|
54
|
+
* @returns {Promise<Models.User<Preferences>>}
|
|
55
|
+
*/
|
|
56
|
+
create<Preferences extends Models.Preferences = Models.DefaultPreferences>(params: {
|
|
57
|
+
userId: string;
|
|
58
|
+
email: string;
|
|
59
|
+
password: string;
|
|
60
|
+
name?: string;
|
|
61
|
+
}): Promise<Models.User<Preferences>>;
|
|
62
|
+
/**
|
|
63
|
+
* Use this endpoint to allow a new user to register a new account in your project. After the user registration completes successfully, you can use the [/account/verfication](https://docs.owbase.dev/references/cloud/client-web/account#createVerification) route to start verifying the user email address. To allow the new user to login to their new account, you need to create a new [account session](https://docs.owbase.dev/references/cloud/client-web/account#createEmailSession).
|
|
64
|
+
*
|
|
65
|
+
* @param {string} userId - User ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars.
|
|
66
|
+
* @param {string} email - User email.
|
|
67
|
+
* @param {string} password - New user password. Must be between 8 and 256 chars.
|
|
68
|
+
* @param {string} name - User name. Max length: 128 chars.
|
|
69
|
+
* @throws {OwbaseException}
|
|
70
|
+
* @returns {Promise<Models.User<Preferences>>}
|
|
71
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
72
|
+
*/
|
|
73
|
+
create<Preferences extends Models.Preferences = Models.DefaultPreferences>(userId: string, email: string, password: string, name?: string): Promise<Models.User<Preferences>>;
|
|
74
|
+
/**
|
|
75
|
+
* Update currently logged in user account email address. After changing user address, the user confirmation status will get reset. A new confirmation email is not sent automatically however you can use the send confirmation email endpoint again to send the confirmation email. For security measures, user password is required to complete this request.
|
|
76
|
+
* This endpoint can also be used to convert an anonymous account to a normal one, by passing an email address and a new password.
|
|
77
|
+
*
|
|
78
|
+
*
|
|
79
|
+
* @param {string} params.email - User email.
|
|
80
|
+
* @param {string} params.password - User password. Must be at least 8 chars.
|
|
81
|
+
* @throws {OwbaseException}
|
|
82
|
+
* @returns {Promise<Models.User<Preferences>>}
|
|
83
|
+
*/
|
|
84
|
+
updateEmail<Preferences extends Models.Preferences = Models.DefaultPreferences>(params: {
|
|
85
|
+
email: string;
|
|
86
|
+
password: string;
|
|
87
|
+
}): Promise<Models.User<Preferences>>;
|
|
88
|
+
/**
|
|
89
|
+
* Update currently logged in user account email address. After changing user address, the user confirmation status will get reset. A new confirmation email is not sent automatically however you can use the send confirmation email endpoint again to send the confirmation email. For security measures, user password is required to complete this request.
|
|
90
|
+
* This endpoint can also be used to convert an anonymous account to a normal one, by passing an email address and a new password.
|
|
91
|
+
*
|
|
92
|
+
*
|
|
93
|
+
* @param {string} email - User email.
|
|
94
|
+
* @param {string} password - User password. Must be at least 8 chars.
|
|
95
|
+
* @throws {OwbaseException}
|
|
96
|
+
* @returns {Promise<Models.User<Preferences>>}
|
|
97
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
98
|
+
*/
|
|
99
|
+
updateEmail<Preferences extends Models.Preferences = Models.DefaultPreferences>(email: string, password: string): Promise<Models.User<Preferences>>;
|
|
100
|
+
/**
|
|
101
|
+
* Get the list of identities for the currently logged in user.
|
|
102
|
+
*
|
|
103
|
+
* @param {string[]} params.queries - Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https://docs.owbase.dev/queries). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following attributes: userId, provider, providerUid, providerEmail, providerAccessTokenExpiry
|
|
104
|
+
* @param {boolean} params.total - When set to false, the total count returned will be 0 and will not be calculated.
|
|
105
|
+
* @throws {OwbaseException}
|
|
106
|
+
* @returns {Promise<Models.IdentityList>}
|
|
107
|
+
*/
|
|
108
|
+
listIdentities(params?: {
|
|
109
|
+
queries?: string[];
|
|
110
|
+
total?: boolean;
|
|
111
|
+
}): Promise<Models.IdentityList>;
|
|
112
|
+
/**
|
|
113
|
+
* Get the list of identities for the currently logged in user.
|
|
114
|
+
*
|
|
115
|
+
* @param {string[]} queries - Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https://docs.owbase.dev/queries). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following attributes: userId, provider, providerUid, providerEmail, providerAccessTokenExpiry
|
|
116
|
+
* @param {boolean} total - When set to false, the total count returned will be 0 and will not be calculated.
|
|
117
|
+
* @throws {OwbaseException}
|
|
118
|
+
* @returns {Promise<Models.IdentityList>}
|
|
119
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
120
|
+
*/
|
|
121
|
+
listIdentities(queries?: string[], total?: boolean): Promise<Models.IdentityList>;
|
|
122
|
+
/**
|
|
123
|
+
* Delete an identity by its unique ID.
|
|
124
|
+
*
|
|
125
|
+
* @param {string} params.identityId - Identity ID.
|
|
126
|
+
* @throws {OwbaseException}
|
|
127
|
+
* @returns {Promise<{}>}
|
|
128
|
+
*/
|
|
129
|
+
deleteIdentity(params: {
|
|
130
|
+
identityId: string;
|
|
131
|
+
}): Promise<{}>;
|
|
132
|
+
/**
|
|
133
|
+
* Delete an identity by its unique ID.
|
|
134
|
+
*
|
|
135
|
+
* @param {string} identityId - Identity ID.
|
|
136
|
+
* @throws {OwbaseException}
|
|
137
|
+
* @returns {Promise<{}>}
|
|
138
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
139
|
+
*/
|
|
140
|
+
deleteIdentity(identityId: string): Promise<{}>;
|
|
141
|
+
/**
|
|
142
|
+
* Enable or disable MFA on an account.
|
|
143
|
+
*
|
|
144
|
+
* @param {boolean} params.mfa - Enable or disable MFA.
|
|
145
|
+
* @throws {OwbaseException}
|
|
146
|
+
* @returns {Promise<Models.User<Preferences>>}
|
|
147
|
+
*/
|
|
148
|
+
updateMFA<Preferences extends Models.Preferences = Models.DefaultPreferences>(params: {
|
|
149
|
+
mfa: boolean;
|
|
150
|
+
}): Promise<Models.User<Preferences>>;
|
|
151
|
+
/**
|
|
152
|
+
* Enable or disable MFA on an account.
|
|
153
|
+
*
|
|
154
|
+
* @param {boolean} mfa - Enable or disable MFA.
|
|
155
|
+
* @throws {OwbaseException}
|
|
156
|
+
* @returns {Promise<Models.User<Preferences>>}
|
|
157
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
158
|
+
*/
|
|
159
|
+
updateMFA<Preferences extends Models.Preferences = Models.DefaultPreferences>(mfa: boolean): Promise<Models.User<Preferences>>;
|
|
160
|
+
/**
|
|
161
|
+
* Add an authenticator app to be used as an MFA factor. Verify the authenticator using the [verify authenticator](/docs/references/cloud/client-web/account#updateMfaAuthenticator) method.
|
|
162
|
+
*
|
|
163
|
+
* @param {AuthenticatorType} params.type - Type of authenticator. Must be `totp`
|
|
164
|
+
* @throws {OwbaseException}
|
|
165
|
+
* @returns {Promise<Models.MfaType>}
|
|
166
|
+
* @deprecated This API has been deprecated since 1.8.0. Please use `Account.createMFAAuthenticator` instead.
|
|
167
|
+
*/
|
|
168
|
+
createMfaAuthenticator(params: {
|
|
169
|
+
type: AuthenticatorType;
|
|
170
|
+
}): Promise<Models.MfaType>;
|
|
171
|
+
/**
|
|
172
|
+
* Add an authenticator app to be used as an MFA factor. Verify the authenticator using the [verify authenticator](/docs/references/cloud/client-web/account#updateMfaAuthenticator) method.
|
|
173
|
+
*
|
|
174
|
+
* @param {AuthenticatorType} type - Type of authenticator. Must be `totp`
|
|
175
|
+
* @throws {OwbaseException}
|
|
176
|
+
* @returns {Promise<Models.MfaType>}
|
|
177
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
178
|
+
*/
|
|
179
|
+
createMfaAuthenticator(type: AuthenticatorType): Promise<Models.MfaType>;
|
|
180
|
+
/**
|
|
181
|
+
* Add an authenticator app to be used as an MFA factor. Verify the authenticator using the [verify authenticator](/docs/references/cloud/client-web/account#updateMfaAuthenticator) method.
|
|
182
|
+
*
|
|
183
|
+
* @param {AuthenticatorType} params.type - Type of authenticator. Must be `totp`
|
|
184
|
+
* @throws {OwbaseException}
|
|
185
|
+
* @returns {Promise<Models.MfaType>}
|
|
186
|
+
*/
|
|
187
|
+
createMFAAuthenticator(params: {
|
|
188
|
+
type: AuthenticatorType;
|
|
189
|
+
}): Promise<Models.MfaType>;
|
|
190
|
+
/**
|
|
191
|
+
* Add an authenticator app to be used as an MFA factor. Verify the authenticator using the [verify authenticator](/docs/references/cloud/client-web/account#updateMfaAuthenticator) method.
|
|
192
|
+
*
|
|
193
|
+
* @param {AuthenticatorType} type - Type of authenticator. Must be `totp`
|
|
194
|
+
* @throws {OwbaseException}
|
|
195
|
+
* @returns {Promise<Models.MfaType>}
|
|
196
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
197
|
+
*/
|
|
198
|
+
createMFAAuthenticator(type: AuthenticatorType): Promise<Models.MfaType>;
|
|
199
|
+
/**
|
|
200
|
+
* Verify an authenticator app after adding it using the [add authenticator](/docs/references/cloud/client-web/account#createMfaAuthenticator) method.
|
|
201
|
+
*
|
|
202
|
+
* @param {AuthenticatorType} params.type - Type of authenticator.
|
|
203
|
+
* @param {string} params.otp - Valid verification token.
|
|
204
|
+
* @throws {OwbaseException}
|
|
205
|
+
* @returns {Promise<Models.User<Preferences>>}
|
|
206
|
+
* @deprecated This API has been deprecated since 1.8.0. Please use `Account.updateMFAAuthenticator` instead.
|
|
207
|
+
*/
|
|
208
|
+
updateMfaAuthenticator<Preferences extends Models.Preferences = Models.DefaultPreferences>(params: {
|
|
209
|
+
type: AuthenticatorType;
|
|
210
|
+
otp: string;
|
|
211
|
+
}): Promise<Models.User<Preferences>>;
|
|
212
|
+
/**
|
|
213
|
+
* Verify an authenticator app after adding it using the [add authenticator](/docs/references/cloud/client-web/account#createMfaAuthenticator) method.
|
|
214
|
+
*
|
|
215
|
+
* @param {AuthenticatorType} type - Type of authenticator.
|
|
216
|
+
* @param {string} otp - Valid verification token.
|
|
217
|
+
* @throws {OwbaseException}
|
|
218
|
+
* @returns {Promise<Models.User<Preferences>>}
|
|
219
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
220
|
+
*/
|
|
221
|
+
updateMfaAuthenticator<Preferences extends Models.Preferences = Models.DefaultPreferences>(type: AuthenticatorType, otp: string): Promise<Models.User<Preferences>>;
|
|
222
|
+
/**
|
|
223
|
+
* Verify an authenticator app after adding it using the [add authenticator](/docs/references/cloud/client-web/account#createMfaAuthenticator) method.
|
|
224
|
+
*
|
|
225
|
+
* @param {AuthenticatorType} params.type - Type of authenticator.
|
|
226
|
+
* @param {string} params.otp - Valid verification token.
|
|
227
|
+
* @throws {OwbaseException}
|
|
228
|
+
* @returns {Promise<Models.User<Preferences>>}
|
|
229
|
+
*/
|
|
230
|
+
updateMFAAuthenticator<Preferences extends Models.Preferences = Models.DefaultPreferences>(params: {
|
|
231
|
+
type: AuthenticatorType;
|
|
232
|
+
otp: string;
|
|
233
|
+
}): Promise<Models.User<Preferences>>;
|
|
234
|
+
/**
|
|
235
|
+
* Verify an authenticator app after adding it using the [add authenticator](/docs/references/cloud/client-web/account#createMfaAuthenticator) method.
|
|
236
|
+
*
|
|
237
|
+
* @param {AuthenticatorType} type - Type of authenticator.
|
|
238
|
+
* @param {string} otp - Valid verification token.
|
|
239
|
+
* @throws {OwbaseException}
|
|
240
|
+
* @returns {Promise<Models.User<Preferences>>}
|
|
241
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
242
|
+
*/
|
|
243
|
+
updateMFAAuthenticator<Preferences extends Models.Preferences = Models.DefaultPreferences>(type: AuthenticatorType, otp: string): Promise<Models.User<Preferences>>;
|
|
244
|
+
/**
|
|
245
|
+
* Delete an authenticator for a user by ID.
|
|
246
|
+
*
|
|
247
|
+
* @param {AuthenticatorType} params.type - Type of authenticator.
|
|
248
|
+
* @throws {OwbaseException}
|
|
249
|
+
* @returns {Promise<{}>}
|
|
250
|
+
* @deprecated This API has been deprecated since 1.8.0. Please use `Account.deleteMFAAuthenticator` instead.
|
|
251
|
+
*/
|
|
252
|
+
deleteMfaAuthenticator(params: {
|
|
253
|
+
type: AuthenticatorType;
|
|
254
|
+
}): Promise<{}>;
|
|
255
|
+
/**
|
|
256
|
+
* Delete an authenticator for a user by ID.
|
|
257
|
+
*
|
|
258
|
+
* @param {AuthenticatorType} type - Type of authenticator.
|
|
259
|
+
* @throws {OwbaseException}
|
|
260
|
+
* @returns {Promise<{}>}
|
|
261
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
262
|
+
*/
|
|
263
|
+
deleteMfaAuthenticator(type: AuthenticatorType): Promise<{}>;
|
|
264
|
+
/**
|
|
265
|
+
* Delete an authenticator for a user by ID.
|
|
266
|
+
*
|
|
267
|
+
* @param {AuthenticatorType} params.type - Type of authenticator.
|
|
268
|
+
* @throws {OwbaseException}
|
|
269
|
+
* @returns {Promise<{}>}
|
|
270
|
+
*/
|
|
271
|
+
deleteMFAAuthenticator(params: {
|
|
272
|
+
type: AuthenticatorType;
|
|
273
|
+
}): Promise<{}>;
|
|
274
|
+
/**
|
|
275
|
+
* Delete an authenticator for a user by ID.
|
|
276
|
+
*
|
|
277
|
+
* @param {AuthenticatorType} type - Type of authenticator.
|
|
278
|
+
* @throws {OwbaseException}
|
|
279
|
+
* @returns {Promise<{}>}
|
|
280
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
281
|
+
*/
|
|
282
|
+
deleteMFAAuthenticator(type: AuthenticatorType): Promise<{}>;
|
|
283
|
+
/**
|
|
284
|
+
* Begin the process of MFA verification after sign-in. Finish the flow with [updateMfaChallenge](/docs/references/cloud/client-web/account#updateMfaChallenge) method.
|
|
285
|
+
*
|
|
286
|
+
* @param {AuthenticationFactor} params.factor - Factor used for verification. Must be one of following: `email`, `phone`, `totp`, `recoveryCode`, `custom`.
|
|
287
|
+
* @throws {OwbaseException}
|
|
288
|
+
* @returns {Promise<Models.MfaChallenge>}
|
|
289
|
+
* @deprecated This API has been deprecated since 1.8.0. Please use `Account.createMFAChallenge` instead.
|
|
290
|
+
*/
|
|
291
|
+
createMfaChallenge(params: {
|
|
292
|
+
factor: AuthenticationFactor;
|
|
293
|
+
}): Promise<Models.MfaChallenge>;
|
|
294
|
+
/**
|
|
295
|
+
* Begin the process of MFA verification after sign-in. Finish the flow with [updateMfaChallenge](/docs/references/cloud/client-web/account#updateMfaChallenge) method.
|
|
296
|
+
*
|
|
297
|
+
* @param {AuthenticationFactor} factor - Factor used for verification. Must be one of following: `email`, `phone`, `totp`, `recoveryCode`, `custom`.
|
|
298
|
+
* @throws {OwbaseException}
|
|
299
|
+
* @returns {Promise<Models.MfaChallenge>}
|
|
300
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
301
|
+
*/
|
|
302
|
+
createMfaChallenge(factor: AuthenticationFactor): Promise<Models.MfaChallenge>;
|
|
303
|
+
/**
|
|
304
|
+
* Begin the process of MFA verification after sign-in. Finish the flow with [updateMfaChallenge](/docs/references/cloud/client-web/account#updateMfaChallenge) method.
|
|
305
|
+
*
|
|
306
|
+
* @param {AuthenticationFactor} params.factor - Factor used for verification. Must be one of following: `email`, `phone`, `totp`, `recoveryCode`, `custom`.
|
|
307
|
+
* @throws {OwbaseException}
|
|
308
|
+
* @returns {Promise<Models.MfaChallenge>}
|
|
309
|
+
*/
|
|
310
|
+
createMFAChallenge(params: {
|
|
311
|
+
factor: AuthenticationFactor;
|
|
312
|
+
}): Promise<Models.MfaChallenge>;
|
|
313
|
+
/**
|
|
314
|
+
* Begin the process of MFA verification after sign-in. Finish the flow with [updateMfaChallenge](/docs/references/cloud/client-web/account#updateMfaChallenge) method.
|
|
315
|
+
*
|
|
316
|
+
* @param {AuthenticationFactor} factor - Factor used for verification. Must be one of following: `email`, `phone`, `totp`, `recoveryCode`, `custom`.
|
|
317
|
+
* @throws {OwbaseException}
|
|
318
|
+
* @returns {Promise<Models.MfaChallenge>}
|
|
319
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
320
|
+
*/
|
|
321
|
+
createMFAChallenge(factor: AuthenticationFactor): Promise<Models.MfaChallenge>;
|
|
322
|
+
/**
|
|
323
|
+
* Complete the MFA challenge by providing the one-time password. Finish the process of MFA verification by providing the one-time password. To begin the flow, use [createMfaChallenge](/docs/references/cloud/client-web/account#createMfaChallenge) method.
|
|
324
|
+
*
|
|
325
|
+
* @param {string} params.challengeId - ID of the challenge.
|
|
326
|
+
* @param {string} params.otp - Valid verification token.
|
|
327
|
+
* @throws {OwbaseException}
|
|
328
|
+
* @returns {Promise<Models.Session>}
|
|
329
|
+
* @deprecated This API has been deprecated since 1.8.0. Please use `Account.updateMFAChallenge` instead.
|
|
330
|
+
*/
|
|
331
|
+
updateMfaChallenge(params: {
|
|
332
|
+
challengeId: string;
|
|
333
|
+
otp: string;
|
|
334
|
+
}): Promise<Models.Session>;
|
|
335
|
+
/**
|
|
336
|
+
* Complete the MFA challenge by providing the one-time password. Finish the process of MFA verification by providing the one-time password. To begin the flow, use [createMfaChallenge](/docs/references/cloud/client-web/account#createMfaChallenge) method.
|
|
337
|
+
*
|
|
338
|
+
* @param {string} challengeId - ID of the challenge.
|
|
339
|
+
* @param {string} otp - Valid verification token.
|
|
340
|
+
* @throws {OwbaseException}
|
|
341
|
+
* @returns {Promise<Models.Session>}
|
|
342
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
343
|
+
*/
|
|
344
|
+
updateMfaChallenge(challengeId: string, otp: string): Promise<Models.Session>;
|
|
345
|
+
/**
|
|
346
|
+
* Complete the MFA challenge by providing the one-time password. Finish the process of MFA verification by providing the one-time password. To begin the flow, use [createMfaChallenge](/docs/references/cloud/client-web/account#createMfaChallenge) method.
|
|
347
|
+
*
|
|
348
|
+
* @param {string} params.challengeId - ID of the challenge.
|
|
349
|
+
* @param {string} params.otp - Valid verification token.
|
|
350
|
+
* @throws {OwbaseException}
|
|
351
|
+
* @returns {Promise<Models.Session>}
|
|
352
|
+
*/
|
|
353
|
+
updateMFAChallenge(params: {
|
|
354
|
+
challengeId: string;
|
|
355
|
+
otp: string;
|
|
356
|
+
}): Promise<Models.Session>;
|
|
357
|
+
/**
|
|
358
|
+
* Complete the MFA challenge by providing the one-time password. Finish the process of MFA verification by providing the one-time password. To begin the flow, use [createMfaChallenge](/docs/references/cloud/client-web/account#createMfaChallenge) method.
|
|
359
|
+
*
|
|
360
|
+
* @param {string} challengeId - ID of the challenge.
|
|
361
|
+
* @param {string} otp - Valid verification token.
|
|
362
|
+
* @throws {OwbaseException}
|
|
363
|
+
* @returns {Promise<Models.Session>}
|
|
364
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
365
|
+
*/
|
|
366
|
+
updateMFAChallenge(challengeId: string, otp: string): Promise<Models.Session>;
|
|
367
|
+
/**
|
|
368
|
+
* List the factors available on the account to be used as a MFA challange.
|
|
369
|
+
*
|
|
370
|
+
* @throws {OwbaseException}
|
|
371
|
+
* @returns {Promise<Models.MfaFactors>}
|
|
372
|
+
* @deprecated This API has been deprecated since 1.8.0. Please use `Account.listMFAFactors` instead.
|
|
373
|
+
*/
|
|
374
|
+
listMfaFactors(): Promise<Models.MfaFactors>;
|
|
375
|
+
/**
|
|
376
|
+
* List the factors available on the account to be used as a MFA challange.
|
|
377
|
+
*
|
|
378
|
+
* @throws {OwbaseException}
|
|
379
|
+
* @returns {Promise<Models.MfaFactors>}
|
|
380
|
+
*/
|
|
381
|
+
listMFAFactors(): Promise<Models.MfaFactors>;
|
|
382
|
+
/**
|
|
383
|
+
* Get recovery codes that can be used as backup for MFA flow. Before getting codes, they must be generated using [createMfaRecoveryCodes](/docs/references/cloud/client-web/account#createMfaRecoveryCodes) method. An OTP challenge is required to read recovery codes.
|
|
384
|
+
*
|
|
385
|
+
* @throws {OwbaseException}
|
|
386
|
+
* @returns {Promise<Models.MfaRecoveryCodes>}
|
|
387
|
+
* @deprecated This API has been deprecated since 1.8.0. Please use `Account.getMFARecoveryCodes` instead.
|
|
388
|
+
*/
|
|
389
|
+
getMfaRecoveryCodes(): Promise<Models.MfaRecoveryCodes>;
|
|
390
|
+
/**
|
|
391
|
+
* Get recovery codes that can be used as backup for MFA flow. Before getting codes, they must be generated using [createMfaRecoveryCodes](/docs/references/cloud/client-web/account#createMfaRecoveryCodes) method. An OTP challenge is required to read recovery codes.
|
|
392
|
+
*
|
|
393
|
+
* @throws {OwbaseException}
|
|
394
|
+
* @returns {Promise<Models.MfaRecoveryCodes>}
|
|
395
|
+
*/
|
|
396
|
+
getMFARecoveryCodes(): Promise<Models.MfaRecoveryCodes>;
|
|
397
|
+
/**
|
|
398
|
+
* Generate recovery codes as backup for MFA flow. It's recommended to generate and show then immediately after user successfully adds their authehticator. Recovery codes can be used as a MFA verification type in [createMfaChallenge](/docs/references/cloud/client-web/account#createMfaChallenge) method.
|
|
399
|
+
*
|
|
400
|
+
* @throws {OwbaseException}
|
|
401
|
+
* @returns {Promise<Models.MfaRecoveryCodes>}
|
|
402
|
+
* @deprecated This API has been deprecated since 1.8.0. Please use `Account.createMFARecoveryCodes` instead.
|
|
403
|
+
*/
|
|
404
|
+
createMfaRecoveryCodes(): Promise<Models.MfaRecoveryCodes>;
|
|
405
|
+
/**
|
|
406
|
+
* Generate recovery codes as backup for MFA flow. It's recommended to generate and show then immediately after user successfully adds their authehticator. Recovery codes can be used as a MFA verification type in [createMfaChallenge](/docs/references/cloud/client-web/account#createMfaChallenge) method.
|
|
407
|
+
*
|
|
408
|
+
* @throws {OwbaseException}
|
|
409
|
+
* @returns {Promise<Models.MfaRecoveryCodes>}
|
|
410
|
+
*/
|
|
411
|
+
createMFARecoveryCodes(): Promise<Models.MfaRecoveryCodes>;
|
|
412
|
+
/**
|
|
413
|
+
* Regenerate recovery codes that can be used as backup for MFA flow. Before regenerating codes, they must be first generated using [createMfaRecoveryCodes](/docs/references/cloud/client-web/account#createMfaRecoveryCodes) method. An OTP challenge is required to regenreate recovery codes.
|
|
414
|
+
*
|
|
415
|
+
* @throws {OwbaseException}
|
|
416
|
+
* @returns {Promise<Models.MfaRecoveryCodes>}
|
|
417
|
+
* @deprecated This API has been deprecated since 1.8.0. Please use `Account.updateMFARecoveryCodes` instead.
|
|
418
|
+
*/
|
|
419
|
+
updateMfaRecoveryCodes(): Promise<Models.MfaRecoveryCodes>;
|
|
420
|
+
/**
|
|
421
|
+
* Regenerate recovery codes that can be used as backup for MFA flow. Before regenerating codes, they must be first generated using [createMfaRecoveryCodes](/docs/references/cloud/client-web/account#createMfaRecoveryCodes) method. An OTP challenge is required to regenreate recovery codes.
|
|
422
|
+
*
|
|
423
|
+
* @throws {OwbaseException}
|
|
424
|
+
* @returns {Promise<Models.MfaRecoveryCodes>}
|
|
425
|
+
*/
|
|
426
|
+
updateMFARecoveryCodes(): Promise<Models.MfaRecoveryCodes>;
|
|
427
|
+
/**
|
|
428
|
+
* Update currently logged in user account name.
|
|
429
|
+
*
|
|
430
|
+
* @param {string} params.name - User name. Max length: 128 chars.
|
|
431
|
+
* @throws {OwbaseException}
|
|
432
|
+
* @returns {Promise<Models.User<Preferences>>}
|
|
433
|
+
*/
|
|
434
|
+
updateName<Preferences extends Models.Preferences = Models.DefaultPreferences>(params: {
|
|
435
|
+
name: string;
|
|
436
|
+
}): Promise<Models.User<Preferences>>;
|
|
437
|
+
/**
|
|
438
|
+
* Update currently logged in user account name.
|
|
439
|
+
*
|
|
440
|
+
* @param {string} name - User name. Max length: 128 chars.
|
|
441
|
+
* @throws {OwbaseException}
|
|
442
|
+
* @returns {Promise<Models.User<Preferences>>}
|
|
443
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
444
|
+
*/
|
|
445
|
+
updateName<Preferences extends Models.Preferences = Models.DefaultPreferences>(name: string): Promise<Models.User<Preferences>>;
|
|
446
|
+
/**
|
|
447
|
+
* Get the list of verified passkeys registered by the currently logged in user.
|
|
448
|
+
*
|
|
449
|
+
* @param {string[]} params.queries - Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https://docs.owbase.dev/queries). Maximum of 100 queries are allowed, each 4096 characters long. You may filter and order on the following attributes: $id, $createdAt, $updatedAt, name, accessedAt
|
|
450
|
+
* @param {boolean} params.total - When set to false, the total count returned will be 0 and will not be calculated.
|
|
451
|
+
* @throws {OwbaseException}
|
|
452
|
+
* @returns {Promise<Models.PasskeyList>}
|
|
453
|
+
*/
|
|
454
|
+
listPasskeys(params?: {
|
|
455
|
+
queries?: string[];
|
|
456
|
+
total?: boolean;
|
|
457
|
+
}): Promise<Models.PasskeyList>;
|
|
458
|
+
/**
|
|
459
|
+
* Get the list of verified passkeys registered by the currently logged in user.
|
|
460
|
+
*
|
|
461
|
+
* @param {string[]} queries - Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https://docs.owbase.dev/queries). Maximum of 100 queries are allowed, each 4096 characters long. You may filter and order on the following attributes: $id, $createdAt, $updatedAt, name, accessedAt
|
|
462
|
+
* @param {boolean} total - When set to false, the total count returned will be 0 and will not be calculated.
|
|
463
|
+
* @throws {OwbaseException}
|
|
464
|
+
* @returns {Promise<Models.PasskeyList>}
|
|
465
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
466
|
+
*/
|
|
467
|
+
listPasskeys(queries?: string[], total?: boolean): Promise<Models.PasskeyList>;
|
|
468
|
+
/**
|
|
469
|
+
* Start registering a passkey for the currently logged in user. The session must have signed in or completed an MFA challenge within the last 10 minutes. Pass the returned `publicKey` options to `navigator.credentials.create()`, then complete the registration with [Update passkey verification](/docs/references/cloud/client-web/account#updatePasskeyVerification). The passkey stays pending until verified, and the challenge expires after 5 minutes.
|
|
470
|
+
*
|
|
471
|
+
* @param {string} params.passkeyId - Passkey ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars.
|
|
472
|
+
* @param {string} params.name - Passkey name, shown when listing passkeys. Max length: 128 chars.
|
|
473
|
+
* @throws {OwbaseException}
|
|
474
|
+
* @returns {Promise<Models.PasskeyChallenge>}
|
|
475
|
+
*/
|
|
476
|
+
createPasskey(params?: {
|
|
477
|
+
passkeyId?: string;
|
|
478
|
+
name?: string;
|
|
479
|
+
}): Promise<Models.PasskeyChallenge>;
|
|
480
|
+
/**
|
|
481
|
+
* Start registering a passkey for the currently logged in user. The session must have signed in or completed an MFA challenge within the last 10 minutes. Pass the returned `publicKey` options to `navigator.credentials.create()`, then complete the registration with [Update passkey verification](/docs/references/cloud/client-web/account#updatePasskeyVerification). The passkey stays pending until verified, and the challenge expires after 5 minutes.
|
|
482
|
+
*
|
|
483
|
+
* @param {string} passkeyId - Passkey ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars.
|
|
484
|
+
* @param {string} name - Passkey name, shown when listing passkeys. Max length: 128 chars.
|
|
485
|
+
* @throws {OwbaseException}
|
|
486
|
+
* @returns {Promise<Models.PasskeyChallenge>}
|
|
487
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
488
|
+
*/
|
|
489
|
+
createPasskey(passkeyId?: string, name?: string): Promise<Models.PasskeyChallenge>;
|
|
490
|
+
/**
|
|
491
|
+
* Get a verified passkey of the currently logged in user by its unique ID.
|
|
492
|
+
*
|
|
493
|
+
* @param {string} params.passkeyId - Passkey ID.
|
|
494
|
+
* @throws {OwbaseException}
|
|
495
|
+
* @returns {Promise<Models.Passkey>}
|
|
496
|
+
*/
|
|
497
|
+
getPasskey(params: {
|
|
498
|
+
passkeyId: string;
|
|
499
|
+
}): Promise<Models.Passkey>;
|
|
500
|
+
/**
|
|
501
|
+
* Get a verified passkey of the currently logged in user by its unique ID.
|
|
502
|
+
*
|
|
503
|
+
* @param {string} passkeyId - Passkey ID.
|
|
504
|
+
* @throws {OwbaseException}
|
|
505
|
+
* @returns {Promise<Models.Passkey>}
|
|
506
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
507
|
+
*/
|
|
508
|
+
getPasskey(passkeyId: string): Promise<Models.Passkey>;
|
|
509
|
+
/**
|
|
510
|
+
* Rename a passkey of the currently logged in user.
|
|
511
|
+
*
|
|
512
|
+
* @param {string} params.passkeyId - Passkey ID.
|
|
513
|
+
* @param {string} params.name - Passkey name. Max length: 128 chars.
|
|
514
|
+
* @throws {OwbaseException}
|
|
515
|
+
* @returns {Promise<Models.Passkey>}
|
|
516
|
+
*/
|
|
517
|
+
updatePasskey(params: {
|
|
518
|
+
passkeyId: string;
|
|
519
|
+
name: string;
|
|
520
|
+
}): Promise<Models.Passkey>;
|
|
521
|
+
/**
|
|
522
|
+
* Rename a passkey of the currently logged in user.
|
|
523
|
+
*
|
|
524
|
+
* @param {string} passkeyId - Passkey ID.
|
|
525
|
+
* @param {string} name - Passkey name. Max length: 128 chars.
|
|
526
|
+
* @throws {OwbaseException}
|
|
527
|
+
* @returns {Promise<Models.Passkey>}
|
|
528
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
529
|
+
*/
|
|
530
|
+
updatePasskey(passkeyId: string, name: string): Promise<Models.Passkey>;
|
|
531
|
+
/**
|
|
532
|
+
* Delete a passkey from the currently logged in user. The passkey can no longer be used to sign in, although it may remain stored on the user's device. The session must have signed in or completed an MFA challenge within the last 10 minutes.
|
|
533
|
+
*
|
|
534
|
+
* @param {string} params.passkeyId - Passkey ID.
|
|
535
|
+
* @throws {OwbaseException}
|
|
536
|
+
* @returns {Promise<{}>}
|
|
537
|
+
*/
|
|
538
|
+
deletePasskey(params: {
|
|
539
|
+
passkeyId: string;
|
|
540
|
+
}): Promise<{}>;
|
|
541
|
+
/**
|
|
542
|
+
* Delete a passkey from the currently logged in user. The passkey can no longer be used to sign in, although it may remain stored on the user's device. The session must have signed in or completed an MFA challenge within the last 10 minutes.
|
|
543
|
+
*
|
|
544
|
+
* @param {string} passkeyId - Passkey ID.
|
|
545
|
+
* @throws {OwbaseException}
|
|
546
|
+
* @returns {Promise<{}>}
|
|
547
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
548
|
+
*/
|
|
549
|
+
deletePasskey(passkeyId: string): Promise<{}>;
|
|
550
|
+
/**
|
|
551
|
+
* Complete a passkey registration started with [Create passkey](/docs/references/cloud/client-web/account#createPasskey). Pass the JSON form of the credential returned by `navigator.credentials.create()`, for example `credential.toJSON()`. Each registration can be verified once; a failed attempt requires starting it again.
|
|
552
|
+
*
|
|
553
|
+
* @param {string} params.passkeyId - Passkey ID.
|
|
554
|
+
* @param {object} params.credential - Registration credential returned by the authenticator, in the JSON form produced by `PublicKeyCredential.toJSON()`.
|
|
555
|
+
* @throws {OwbaseException}
|
|
556
|
+
* @returns {Promise<Models.Passkey>}
|
|
557
|
+
*/
|
|
558
|
+
updatePasskeyVerification(params: {
|
|
559
|
+
passkeyId: string;
|
|
560
|
+
credential: object;
|
|
561
|
+
}): Promise<Models.Passkey>;
|
|
562
|
+
/**
|
|
563
|
+
* Complete a passkey registration started with [Create passkey](/docs/references/cloud/client-web/account#createPasskey). Pass the JSON form of the credential returned by `navigator.credentials.create()`, for example `credential.toJSON()`. Each registration can be verified once; a failed attempt requires starting it again.
|
|
564
|
+
*
|
|
565
|
+
* @param {string} passkeyId - Passkey ID.
|
|
566
|
+
* @param {object} credential - Registration credential returned by the authenticator, in the JSON form produced by `PublicKeyCredential.toJSON()`.
|
|
567
|
+
* @throws {OwbaseException}
|
|
568
|
+
* @returns {Promise<Models.Passkey>}
|
|
569
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
570
|
+
*/
|
|
571
|
+
updatePasskeyVerification(passkeyId: string, credential: object): Promise<Models.Passkey>;
|
|
572
|
+
/**
|
|
573
|
+
* Update currently logged in user password. For validation, user is required to pass in the new password, and the old password. For users created with OAuth, Team Invites and Magic URL, oldPassword is optional.
|
|
574
|
+
*
|
|
575
|
+
* @param {string} params.password - New user password. Must be at least 8 chars.
|
|
576
|
+
* @param {string} params.oldPassword - Current user password. Max length: 256 chars.
|
|
577
|
+
* @throws {OwbaseException}
|
|
578
|
+
* @returns {Promise<Models.User<Preferences>>}
|
|
579
|
+
*/
|
|
580
|
+
updatePassword<Preferences extends Models.Preferences = Models.DefaultPreferences>(params: {
|
|
581
|
+
password: string;
|
|
582
|
+
oldPassword?: string;
|
|
583
|
+
}): Promise<Models.User<Preferences>>;
|
|
584
|
+
/**
|
|
585
|
+
* Update currently logged in user password. For validation, user is required to pass in the new password, and the old password. For users created with OAuth, Team Invites and Magic URL, oldPassword is optional.
|
|
586
|
+
*
|
|
587
|
+
* @param {string} password - New user password. Must be at least 8 chars.
|
|
588
|
+
* @param {string} oldPassword - Current user password. Max length: 256 chars.
|
|
589
|
+
* @throws {OwbaseException}
|
|
590
|
+
* @returns {Promise<Models.User<Preferences>>}
|
|
591
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
592
|
+
*/
|
|
593
|
+
updatePassword<Preferences extends Models.Preferences = Models.DefaultPreferences>(password: string, oldPassword?: string): Promise<Models.User<Preferences>>;
|
|
594
|
+
/**
|
|
595
|
+
* Update the currently logged in user's phone number. After updating the phone number, the phone verification status will be reset. A confirmation SMS is not sent automatically, however you can use the [POST /account/verification/phone](https://docs.owbase.dev/references/cloud/client-web/account#createPhoneVerification) endpoint to send a confirmation SMS.
|
|
596
|
+
*
|
|
597
|
+
* @param {string} params.phone - Phone number. Format this number with a leading '+' and a country code, e.g., +16175551212.
|
|
598
|
+
* @param {string} params.password - User password. Must be at least 8 chars.
|
|
599
|
+
* @throws {OwbaseException}
|
|
600
|
+
* @returns {Promise<Models.User<Preferences>>}
|
|
601
|
+
*/
|
|
602
|
+
updatePhone<Preferences extends Models.Preferences = Models.DefaultPreferences>(params: {
|
|
603
|
+
phone: string;
|
|
604
|
+
password: string;
|
|
605
|
+
}): Promise<Models.User<Preferences>>;
|
|
606
|
+
/**
|
|
607
|
+
* Update the currently logged in user's phone number. After updating the phone number, the phone verification status will be reset. A confirmation SMS is not sent automatically, however you can use the [POST /account/verification/phone](https://docs.owbase.dev/references/cloud/client-web/account#createPhoneVerification) endpoint to send a confirmation SMS.
|
|
608
|
+
*
|
|
609
|
+
* @param {string} phone - Phone number. Format this number with a leading '+' and a country code, e.g., +16175551212.
|
|
610
|
+
* @param {string} password - User password. Must be at least 8 chars.
|
|
611
|
+
* @throws {OwbaseException}
|
|
612
|
+
* @returns {Promise<Models.User<Preferences>>}
|
|
613
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
614
|
+
*/
|
|
615
|
+
updatePhone<Preferences extends Models.Preferences = Models.DefaultPreferences>(phone: string, password: string): Promise<Models.User<Preferences>>;
|
|
616
|
+
/**
|
|
617
|
+
* Get the preferences as a key-value object for the currently logged in user.
|
|
618
|
+
*
|
|
619
|
+
* @throws {OwbaseException}
|
|
620
|
+
* @returns {Promise<Preferences>}
|
|
621
|
+
*/
|
|
622
|
+
getPrefs<Preferences extends Models.Preferences = Models.DefaultPreferences>(): Promise<Preferences>;
|
|
623
|
+
/**
|
|
624
|
+
* Update currently logged in user account preferences. The object you pass is stored as is, and replaces any previous value. The maximum allowed prefs size is 64kB and throws error if exceeded.
|
|
625
|
+
*
|
|
626
|
+
* @param {Partial<Preferences>} params.prefs - Prefs key-value JSON object.
|
|
627
|
+
* @throws {OwbaseException}
|
|
628
|
+
* @returns {Promise<Models.User<Preferences>>}
|
|
629
|
+
*/
|
|
630
|
+
updatePrefs<Preferences extends Models.Preferences = Models.DefaultPreferences>(params: {
|
|
631
|
+
prefs: Partial<Preferences>;
|
|
632
|
+
}): Promise<Models.User<Preferences>>;
|
|
633
|
+
/**
|
|
634
|
+
* Update currently logged in user account preferences. The object you pass is stored as is, and replaces any previous value. The maximum allowed prefs size is 64kB and throws error if exceeded.
|
|
635
|
+
*
|
|
636
|
+
* @param {Partial<Preferences>} prefs - Prefs key-value JSON object.
|
|
637
|
+
* @throws {OwbaseException}
|
|
638
|
+
* @returns {Promise<Models.User<Preferences>>}
|
|
639
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
640
|
+
*/
|
|
641
|
+
updatePrefs<Preferences extends Models.Preferences = Models.DefaultPreferences>(prefs: Partial<Preferences>): Promise<Models.User<Preferences>>;
|
|
642
|
+
/**
|
|
643
|
+
* Sends the user an email with a temporary secret key for password reset. When the user clicks the confirmation link he is redirected back to your app password reset URL with the secret key and email address values attached to the URL query string. Use the query string params to submit a request to the [PUT /account/recovery](https://docs.owbase.dev/references/cloud/client-web/account#updateRecovery) endpoint to complete the process. The verification link sent to the user's email address is valid for 1 hour.
|
|
644
|
+
*
|
|
645
|
+
* @param {string} params.email - User email.
|
|
646
|
+
* @param {string} params.url - URL to redirect the user back to your app from the recovery email. Only URLs from hostnames in your project platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
|
|
647
|
+
* @throws {OwbaseException}
|
|
648
|
+
* @returns {Promise<Models.Token>}
|
|
649
|
+
*/
|
|
650
|
+
createRecovery(params: {
|
|
651
|
+
email: string;
|
|
652
|
+
url: string;
|
|
653
|
+
}): Promise<Models.Token>;
|
|
654
|
+
/**
|
|
655
|
+
* Sends the user an email with a temporary secret key for password reset. When the user clicks the confirmation link he is redirected back to your app password reset URL with the secret key and email address values attached to the URL query string. Use the query string params to submit a request to the [PUT /account/recovery](https://docs.owbase.dev/references/cloud/client-web/account#updateRecovery) endpoint to complete the process. The verification link sent to the user's email address is valid for 1 hour.
|
|
656
|
+
*
|
|
657
|
+
* @param {string} email - User email.
|
|
658
|
+
* @param {string} url - URL to redirect the user back to your app from the recovery email. Only URLs from hostnames in your project platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
|
|
659
|
+
* @throws {OwbaseException}
|
|
660
|
+
* @returns {Promise<Models.Token>}
|
|
661
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
662
|
+
*/
|
|
663
|
+
createRecovery(email: string, url: string): Promise<Models.Token>;
|
|
664
|
+
/**
|
|
665
|
+
* Use this endpoint to complete the user account password reset. Both the **userId** and **secret** arguments will be passed as query parameters to the redirect URL you have provided when sending your request to the [POST /account/recovery](https://docs.owbase.dev/references/cloud/client-web/account#createRecovery) endpoint.
|
|
666
|
+
*
|
|
667
|
+
* Please note that in order to avoid a [Redirect Attack](https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.md) the only valid redirect URLs are the ones from domains you have set when adding your platforms in the console interface.
|
|
668
|
+
*
|
|
669
|
+
* @param {string} params.userId - User ID.
|
|
670
|
+
* @param {string} params.secret - Valid reset token.
|
|
671
|
+
* @param {string} params.password - New user password. Must be between 8 and 256 chars.
|
|
672
|
+
* @throws {OwbaseException}
|
|
673
|
+
* @returns {Promise<Models.Token>}
|
|
674
|
+
*/
|
|
675
|
+
updateRecovery(params: {
|
|
676
|
+
userId: string;
|
|
677
|
+
secret: string;
|
|
678
|
+
password: string;
|
|
679
|
+
}): Promise<Models.Token>;
|
|
680
|
+
/**
|
|
681
|
+
* Use this endpoint to complete the user account password reset. Both the **userId** and **secret** arguments will be passed as query parameters to the redirect URL you have provided when sending your request to the [POST /account/recovery](https://docs.owbase.dev/references/cloud/client-web/account#createRecovery) endpoint.
|
|
682
|
+
*
|
|
683
|
+
* Please note that in order to avoid a [Redirect Attack](https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.md) the only valid redirect URLs are the ones from domains you have set when adding your platforms in the console interface.
|
|
684
|
+
*
|
|
685
|
+
* @param {string} userId - User ID.
|
|
686
|
+
* @param {string} secret - Valid reset token.
|
|
687
|
+
* @param {string} password - New user password. Must be between 8 and 256 chars.
|
|
688
|
+
* @throws {OwbaseException}
|
|
689
|
+
* @returns {Promise<Models.Token>}
|
|
690
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
691
|
+
*/
|
|
692
|
+
updateRecovery(userId: string, secret: string, password: string): Promise<Models.Token>;
|
|
693
|
+
/**
|
|
694
|
+
* Use this endpoint to send a 6-digit password recovery code to the user's email address. Unlike [createRecovery](https://docs.owbase.dev/references/cloud/client-web/account#createRecovery), this method requires no redirect URL, which makes it suitable for mobile and desktop apps that cannot host a recovery page. Learn more about how to [complete the recovery process](https://docs.owbase.dev/references/cloud/client-web/account#updateRecoveryOTP). The code sent to the user's email address is valid for 15 minutes.
|
|
695
|
+
*
|
|
696
|
+
* Enable the **phrase** parameter to include a randomly generated security phrase in both the email and the response. Showing that phrase in your app lets the user confirm the email genuinely came from your request, which helps protect against phishing.
|
|
697
|
+
*
|
|
698
|
+
*
|
|
699
|
+
* @param {string} params.email - User email.
|
|
700
|
+
* @param {boolean} params.phrase - Toggle for security phrase. If enabled, email will be sent with a randomly generated phrase and the phrase will also be included in the response. Confirming phrases match increases the security of your authentication flow.
|
|
701
|
+
* @throws {OwbaseException}
|
|
702
|
+
* @returns {Promise<Models.Token>}
|
|
703
|
+
*/
|
|
704
|
+
createRecoveryOTP(params: {
|
|
705
|
+
email: string;
|
|
706
|
+
phrase?: boolean;
|
|
707
|
+
}): Promise<Models.Token>;
|
|
708
|
+
/**
|
|
709
|
+
* Use this endpoint to send a 6-digit password recovery code to the user's email address. Unlike [createRecovery](https://docs.owbase.dev/references/cloud/client-web/account#createRecovery), this method requires no redirect URL, which makes it suitable for mobile and desktop apps that cannot host a recovery page. Learn more about how to [complete the recovery process](https://docs.owbase.dev/references/cloud/client-web/account#updateRecoveryOTP). The code sent to the user's email address is valid for 15 minutes.
|
|
710
|
+
*
|
|
711
|
+
* Enable the **phrase** parameter to include a randomly generated security phrase in both the email and the response. Showing that phrase in your app lets the user confirm the email genuinely came from your request, which helps protect against phishing.
|
|
712
|
+
*
|
|
713
|
+
*
|
|
714
|
+
* @param {string} email - User email.
|
|
715
|
+
* @param {boolean} phrase - Toggle for security phrase. If enabled, email will be sent with a randomly generated phrase and the phrase will also be included in the response. Confirming phrases match increases the security of your authentication flow.
|
|
716
|
+
* @throws {OwbaseException}
|
|
717
|
+
* @returns {Promise<Models.Token>}
|
|
718
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
719
|
+
*/
|
|
720
|
+
createRecoveryOTP(email: string, phrase?: boolean): Promise<Models.Token>;
|
|
721
|
+
/**
|
|
722
|
+
* Use this endpoint to complete the user password recovery process using the 6-digit code that was emailed by [createRecoveryOTP](https://docs.owbase.dev/references/cloud/client-web/account#createRecoveryOTP). Pass the **userId** of the user along with the **secret** code from the email and the new **password** to set. If confirmed, this route will return a 200 status code, the code is consumed and the user's password is updated.
|
|
723
|
+
*
|
|
724
|
+
*
|
|
725
|
+
* @param {string} params.userId - User ID.
|
|
726
|
+
* @param {string} params.secret - Valid recovery OTP code.
|
|
727
|
+
* @param {string} params.password - New user password. Must be between 8 and 256 chars.
|
|
728
|
+
* @throws {OwbaseException}
|
|
729
|
+
* @returns {Promise<Models.Token>}
|
|
730
|
+
*/
|
|
731
|
+
updateRecoveryOTP(params: {
|
|
732
|
+
userId: string;
|
|
733
|
+
secret: string;
|
|
734
|
+
password: string;
|
|
735
|
+
}): Promise<Models.Token>;
|
|
736
|
+
/**
|
|
737
|
+
* Use this endpoint to complete the user password recovery process using the 6-digit code that was emailed by [createRecoveryOTP](https://docs.owbase.dev/references/cloud/client-web/account#createRecoveryOTP). Pass the **userId** of the user along with the **secret** code from the email and the new **password** to set. If confirmed, this route will return a 200 status code, the code is consumed and the user's password is updated.
|
|
738
|
+
*
|
|
739
|
+
*
|
|
740
|
+
* @param {string} userId - User ID.
|
|
741
|
+
* @param {string} secret - Valid recovery OTP code.
|
|
742
|
+
* @param {string} password - New user password. Must be between 8 and 256 chars.
|
|
743
|
+
* @throws {OwbaseException}
|
|
744
|
+
* @returns {Promise<Models.Token>}
|
|
745
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
746
|
+
*/
|
|
747
|
+
updateRecoveryOTP(userId: string, secret: string, password: string): Promise<Models.Token>;
|
|
748
|
+
/**
|
|
749
|
+
* Get the list of active sessions across different devices for the currently logged in user.
|
|
750
|
+
*
|
|
751
|
+
* @param {boolean} params.total - When set to false, the total count returned will be 0 and will not be calculated.
|
|
752
|
+
* @throws {OwbaseException}
|
|
753
|
+
* @returns {Promise<Models.SessionList>}
|
|
754
|
+
*/
|
|
755
|
+
listSessions(params?: {
|
|
756
|
+
total?: boolean;
|
|
757
|
+
}): Promise<Models.SessionList>;
|
|
758
|
+
/**
|
|
759
|
+
* Get the list of active sessions across different devices for the currently logged in user.
|
|
760
|
+
*
|
|
761
|
+
* @param {boolean} total - When set to false, the total count returned will be 0 and will not be calculated.
|
|
762
|
+
* @throws {OwbaseException}
|
|
763
|
+
* @returns {Promise<Models.SessionList>}
|
|
764
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
765
|
+
*/
|
|
766
|
+
listSessions(total?: boolean): Promise<Models.SessionList>;
|
|
767
|
+
/**
|
|
768
|
+
* Delete all sessions from the user account and remove any sessions cookies from the end client. Pass `current` as false to keep the session making the request and sign out of every other session.
|
|
769
|
+
*
|
|
770
|
+
* @param {boolean} params.current - Delete the current session too. Use false to sign out of every other session while staying signed in on this one.
|
|
771
|
+
* @throws {OwbaseException}
|
|
772
|
+
* @returns {Promise<{}>}
|
|
773
|
+
*/
|
|
774
|
+
deleteSessions(params?: {
|
|
775
|
+
current?: boolean;
|
|
776
|
+
}): Promise<{}>;
|
|
777
|
+
/**
|
|
778
|
+
* Delete all sessions from the user account and remove any sessions cookies from the end client. Pass `current` as false to keep the session making the request and sign out of every other session.
|
|
779
|
+
*
|
|
780
|
+
* @param {boolean} current - Delete the current session too. Use false to sign out of every other session while staying signed in on this one.
|
|
781
|
+
* @throws {OwbaseException}
|
|
782
|
+
* @returns {Promise<{}>}
|
|
783
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
784
|
+
*/
|
|
785
|
+
deleteSessions(current?: boolean): Promise<{}>;
|
|
786
|
+
/**
|
|
787
|
+
* Use this endpoint to allow a new user to register an anonymous account in your project. This route will also create a new session for the user. To allow the new user to convert an anonymous account to a normal account, you need to update its [email and password](https://docs.owbase.dev/references/cloud/client-web/account#updateEmail) or create an [OAuth2 session](https://docs.owbase.dev/references/cloud/client-web/account#CreateOAuth2Session).
|
|
788
|
+
*
|
|
789
|
+
* @throws {OwbaseException}
|
|
790
|
+
* @returns {Promise<Models.Session>}
|
|
791
|
+
*/
|
|
792
|
+
createAnonymousSession(): Promise<Models.Session>;
|
|
793
|
+
/**
|
|
794
|
+
* Allow the user to login into their account by providing a valid email and password combination. This route will create a new session for the user. Use the optional `duration` parameter to create a shorter session, for example when the user doesn't choose "remember me". It must be at least 60 seconds and cannot exceed the project maximum session length.
|
|
795
|
+
*
|
|
796
|
+
* A user is limited to 10 active sessions at a time by default. [Learn more about session limits](https://docs.owbase.dev/authentication-security#limits).
|
|
797
|
+
*
|
|
798
|
+
* @param {string} params.email - User email.
|
|
799
|
+
* @param {string} params.password - User password. Must be at least 8 chars.
|
|
800
|
+
* @param {number} params.duration - Session length in seconds. Minimum is 60 seconds, and it cannot exceed the project maximum session length. Defaults to the project maximum session length.
|
|
801
|
+
* @throws {OwbaseException}
|
|
802
|
+
* @returns {Promise<Models.Session>}
|
|
803
|
+
*/
|
|
804
|
+
createEmailPasswordSession(params: {
|
|
805
|
+
email: string;
|
|
806
|
+
password: string;
|
|
807
|
+
duration?: number;
|
|
808
|
+
}): Promise<Models.Session>;
|
|
809
|
+
/**
|
|
810
|
+
* Allow the user to login into their account by providing a valid email and password combination. This route will create a new session for the user. Use the optional `duration` parameter to create a shorter session, for example when the user doesn't choose "remember me". It must be at least 60 seconds and cannot exceed the project maximum session length.
|
|
811
|
+
*
|
|
812
|
+
* A user is limited to 10 active sessions at a time by default. [Learn more about session limits](https://docs.owbase.dev/authentication-security#limits).
|
|
813
|
+
*
|
|
814
|
+
* @param {string} email - User email.
|
|
815
|
+
* @param {string} password - User password. Must be at least 8 chars.
|
|
816
|
+
* @param {number} duration - Session length in seconds. Minimum is 60 seconds, and it cannot exceed the project maximum session length. Defaults to the project maximum session length.
|
|
817
|
+
* @throws {OwbaseException}
|
|
818
|
+
* @returns {Promise<Models.Session>}
|
|
819
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
820
|
+
*/
|
|
821
|
+
createEmailPasswordSession(email: string, password: string, duration?: number): Promise<Models.Session>;
|
|
822
|
+
/**
|
|
823
|
+
* Allow the user to login to their account using an OpenID Connect ID token obtained natively from the OAuth2 provider, for example via Google Credential Manager on Android or Sign in with Apple on iOS. No browser or redirect is involved: the ID token is verified against the provider's published signing keys and a session is created in a single request.
|
|
824
|
+
*
|
|
825
|
+
* Native sign-in is switched on per provider with its nativeEnabled setting. It is independent of the browser-based flow's enabled setting, which has no effect on this endpoint. The token's audience must match the provider's configured client ID or one of its native client IDs; tokens issued for any other client ID are rejected. For Sign in with Apple, register your app's bundle ID as a native client ID. For Google, the web client ID used by Credential Manager is usually the configured client ID; add your Android and iOS client IDs as native client IDs if your app requests tokens for them.
|
|
826
|
+
*
|
|
827
|
+
* Pass the raw nonce used when requesting the ID token so it can be validated against the token's nonce claim. When signing in with Apple, the nonce is required: hash it with SHA-256 before passing it to the Apple SDK, and send the raw value here - Apple tokens requested without a nonce are rejected. For Google the nonce is optional: it is validated whenever the token carries one, and ignored when the provider issued the token without one. Apple only returns the user's name on the first authorization, and never inside the ID token - capture it on the client and pass it via the name parameter.
|
|
828
|
+
*
|
|
829
|
+
* If there is already an active session, the new session will be attached to the logged-in account. If there are no active sessions, the server will attempt to look for a user with the same email address as the verified email received from the provider and attach the new session to the existing user. If no matching user is found - the server will create a new user.
|
|
830
|
+
*
|
|
831
|
+
* This flow does not return provider refresh tokens. You may pass an access token the provider handed your client, along with its lifetime, to store it on the session - but Owbase cannot renew it once it expires. If your app needs long-lived access to provider APIs, use the browser-based OAuth2 flow instead.
|
|
832
|
+
*
|
|
833
|
+
* A user is limited to 10 active sessions at a time by default. [Learn more about session limits](https://docs.owbase.dev/authentication-security#limits).
|
|
834
|
+
*
|
|
835
|
+
*
|
|
836
|
+
* @param {IdTokenProvider} params.provider - OAuth2 provider that issued the ID token. Currently, supported providers are: apple, google.
|
|
837
|
+
* @param {string} params.idToken - OpenID Connect ID token (JWT) obtained natively from the provider, for example via Google Credential Manager or Sign in with Apple.
|
|
838
|
+
* @param {string} params.nonce - Raw nonce used when requesting the ID token. Required for Apple, and whenever the token carries a nonce claim, which must match it. Ignored when the provider issued the token without a nonce.
|
|
839
|
+
* @param {string} params.accessToken - Provider access token to store alongside the session for calling provider APIs. Never used for authentication.
|
|
840
|
+
* @param {number} params.accessTokenExpiry - Seconds until the provider access token expires, as reported by the provider. Stored so clients can tell when the stored token goes stale.
|
|
841
|
+
* @param {string} params.name - User name. Only used when creating a new user and the ID token has no name claim, such as on the first Sign in with Apple authorization.
|
|
842
|
+
* @throws {OwbaseException}
|
|
843
|
+
* @returns {Promise<Models.Session>}
|
|
844
|
+
*/
|
|
845
|
+
createIdTokenSession(params: {
|
|
846
|
+
provider: IdTokenProvider;
|
|
847
|
+
idToken: string;
|
|
848
|
+
nonce?: string;
|
|
849
|
+
accessToken?: string;
|
|
850
|
+
accessTokenExpiry?: number;
|
|
851
|
+
name?: string;
|
|
852
|
+
}): Promise<Models.Session>;
|
|
853
|
+
/**
|
|
854
|
+
* Allow the user to login to their account using an OpenID Connect ID token obtained natively from the OAuth2 provider, for example via Google Credential Manager on Android or Sign in with Apple on iOS. No browser or redirect is involved: the ID token is verified against the provider's published signing keys and a session is created in a single request.
|
|
855
|
+
*
|
|
856
|
+
* Native sign-in is switched on per provider with its nativeEnabled setting. It is independent of the browser-based flow's enabled setting, which has no effect on this endpoint. The token's audience must match the provider's configured client ID or one of its native client IDs; tokens issued for any other client ID are rejected. For Sign in with Apple, register your app's bundle ID as a native client ID. For Google, the web client ID used by Credential Manager is usually the configured client ID; add your Android and iOS client IDs as native client IDs if your app requests tokens for them.
|
|
857
|
+
*
|
|
858
|
+
* Pass the raw nonce used when requesting the ID token so it can be validated against the token's nonce claim. When signing in with Apple, the nonce is required: hash it with SHA-256 before passing it to the Apple SDK, and send the raw value here - Apple tokens requested without a nonce are rejected. For Google the nonce is optional: it is validated whenever the token carries one, and ignored when the provider issued the token without one. Apple only returns the user's name on the first authorization, and never inside the ID token - capture it on the client and pass it via the name parameter.
|
|
859
|
+
*
|
|
860
|
+
* If there is already an active session, the new session will be attached to the logged-in account. If there are no active sessions, the server will attempt to look for a user with the same email address as the verified email received from the provider and attach the new session to the existing user. If no matching user is found - the server will create a new user.
|
|
861
|
+
*
|
|
862
|
+
* This flow does not return provider refresh tokens. You may pass an access token the provider handed your client, along with its lifetime, to store it on the session - but Owbase cannot renew it once it expires. If your app needs long-lived access to provider APIs, use the browser-based OAuth2 flow instead.
|
|
863
|
+
*
|
|
864
|
+
* A user is limited to 10 active sessions at a time by default. [Learn more about session limits](https://docs.owbase.dev/authentication-security#limits).
|
|
865
|
+
*
|
|
866
|
+
*
|
|
867
|
+
* @param {IdTokenProvider} provider - OAuth2 provider that issued the ID token. Currently, supported providers are: apple, google.
|
|
868
|
+
* @param {string} idToken - OpenID Connect ID token (JWT) obtained natively from the provider, for example via Google Credential Manager or Sign in with Apple.
|
|
869
|
+
* @param {string} nonce - Raw nonce used when requesting the ID token. Required for Apple, and whenever the token carries a nonce claim, which must match it. Ignored when the provider issued the token without a nonce.
|
|
870
|
+
* @param {string} accessToken - Provider access token to store alongside the session for calling provider APIs. Never used for authentication.
|
|
871
|
+
* @param {number} accessTokenExpiry - Seconds until the provider access token expires, as reported by the provider. Stored so clients can tell when the stored token goes stale.
|
|
872
|
+
* @param {string} name - User name. Only used when creating a new user and the ID token has no name claim, such as on the first Sign in with Apple authorization.
|
|
873
|
+
* @throws {OwbaseException}
|
|
874
|
+
* @returns {Promise<Models.Session>}
|
|
875
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
876
|
+
*/
|
|
877
|
+
createIdTokenSession(provider: IdTokenProvider, idToken: string, nonce?: string, accessToken?: string, accessTokenExpiry?: number, name?: string): Promise<Models.Session>;
|
|
878
|
+
/**
|
|
879
|
+
* Use this endpoint to create a session from token. Provide the **userId** and **secret** parameters from the successful response of authentication flows initiated by token creation. For example, magic URL and phone login.
|
|
880
|
+
*
|
|
881
|
+
* @param {string} params.userId - User ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars.
|
|
882
|
+
* @param {string} params.secret - Valid verification token.
|
|
883
|
+
* @throws {OwbaseException}
|
|
884
|
+
* @returns {Promise<Models.Session>}
|
|
885
|
+
* @deprecated This API has been deprecated since 1.6.0. Please use `Account.createSession` instead.
|
|
886
|
+
*/
|
|
887
|
+
updateMagicURLSession(params: {
|
|
888
|
+
userId: string;
|
|
889
|
+
secret: string;
|
|
890
|
+
}): Promise<Models.Session>;
|
|
891
|
+
/**
|
|
892
|
+
* Use this endpoint to create a session from token. Provide the **userId** and **secret** parameters from the successful response of authentication flows initiated by token creation. For example, magic URL and phone login.
|
|
893
|
+
*
|
|
894
|
+
* @param {string} userId - User ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars.
|
|
895
|
+
* @param {string} secret - Valid verification token.
|
|
896
|
+
* @throws {OwbaseException}
|
|
897
|
+
* @returns {Promise<Models.Session>}
|
|
898
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
899
|
+
*/
|
|
900
|
+
updateMagicURLSession(userId: string, secret: string): Promise<Models.Session>;
|
|
901
|
+
/**
|
|
902
|
+
* Use this endpoint to create a session from token. Provide the **userId** and **secret** parameters from the successful response of authentication flows initiated by token creation. For example, magic URL and phone login.
|
|
903
|
+
*
|
|
904
|
+
* @param {string} params.userId - User ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars.
|
|
905
|
+
* @param {string} params.secret - Valid verification token.
|
|
906
|
+
* @throws {OwbaseException}
|
|
907
|
+
* @returns {Promise<Models.Session>}
|
|
908
|
+
* @deprecated This API has been deprecated since 1.6.0. Please use `Account.createSession` instead.
|
|
909
|
+
*/
|
|
910
|
+
updatePhoneSession(params: {
|
|
911
|
+
userId: string;
|
|
912
|
+
secret: string;
|
|
913
|
+
}): Promise<Models.Session>;
|
|
914
|
+
/**
|
|
915
|
+
* Use this endpoint to create a session from token. Provide the **userId** and **secret** parameters from the successful response of authentication flows initiated by token creation. For example, magic URL and phone login.
|
|
916
|
+
*
|
|
917
|
+
* @param {string} userId - User ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars.
|
|
918
|
+
* @param {string} secret - Valid verification token.
|
|
919
|
+
* @throws {OwbaseException}
|
|
920
|
+
* @returns {Promise<Models.Session>}
|
|
921
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
922
|
+
*/
|
|
923
|
+
updatePhoneSession(userId: string, secret: string): Promise<Models.Session>;
|
|
924
|
+
/**
|
|
925
|
+
* Use this endpoint to create a session from token. Provide the **userId** and **secret** parameters from the successful response of authentication flows initiated by token creation. For example, magic URL and phone login.
|
|
926
|
+
*
|
|
927
|
+
* @param {string} params.userId - User ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars.
|
|
928
|
+
* @param {string} params.secret - Secret of a token generated by login methods. For example, the `createMagicURLToken` or `createPhoneToken` methods.
|
|
929
|
+
* @throws {OwbaseException}
|
|
930
|
+
* @returns {Promise<Models.Session>}
|
|
931
|
+
*/
|
|
932
|
+
createSession(params: {
|
|
933
|
+
userId: string;
|
|
934
|
+
secret: string;
|
|
935
|
+
}): Promise<Models.Session>;
|
|
936
|
+
/**
|
|
937
|
+
* Use this endpoint to create a session from token. Provide the **userId** and **secret** parameters from the successful response of authentication flows initiated by token creation. For example, magic URL and phone login.
|
|
938
|
+
*
|
|
939
|
+
* @param {string} userId - User ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars.
|
|
940
|
+
* @param {string} secret - Secret of a token generated by login methods. For example, the `createMagicURLToken` or `createPhoneToken` methods.
|
|
941
|
+
* @throws {OwbaseException}
|
|
942
|
+
* @returns {Promise<Models.Session>}
|
|
943
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
944
|
+
*/
|
|
945
|
+
createSession(userId: string, secret: string): Promise<Models.Session>;
|
|
946
|
+
/**
|
|
947
|
+
* Use this endpoint to get a logged in user's session using a Session ID. Inputting 'current' will return the current session being used.
|
|
948
|
+
*
|
|
949
|
+
* @param {string} params.sessionId - Session ID. Use the string 'current' to get the current device session.
|
|
950
|
+
* @throws {OwbaseException}
|
|
951
|
+
* @returns {Promise<Models.Session>}
|
|
952
|
+
*/
|
|
953
|
+
getSession(params: {
|
|
954
|
+
sessionId: string;
|
|
955
|
+
}): Promise<Models.Session>;
|
|
956
|
+
/**
|
|
957
|
+
* Use this endpoint to get a logged in user's session using a Session ID. Inputting 'current' will return the current session being used.
|
|
958
|
+
*
|
|
959
|
+
* @param {string} sessionId - Session ID. Use the string 'current' to get the current device session.
|
|
960
|
+
* @throws {OwbaseException}
|
|
961
|
+
* @returns {Promise<Models.Session>}
|
|
962
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
963
|
+
*/
|
|
964
|
+
getSession(sessionId: string): Promise<Models.Session>;
|
|
965
|
+
/**
|
|
966
|
+
* Use this endpoint to extend a session's length. Extending a session is useful when session expiry is short. If the session was created using an OAuth provider, this endpoint refreshes the access token from the provider.
|
|
967
|
+
*
|
|
968
|
+
* @param {string} params.sessionId - Session ID. Use the string 'current' to update the current device session.
|
|
969
|
+
* @throws {OwbaseException}
|
|
970
|
+
* @returns {Promise<Models.Session>}
|
|
971
|
+
*/
|
|
972
|
+
updateSession(params: {
|
|
973
|
+
sessionId: string;
|
|
974
|
+
}): Promise<Models.Session>;
|
|
975
|
+
/**
|
|
976
|
+
* Use this endpoint to extend a session's length. Extending a session is useful when session expiry is short. If the session was created using an OAuth provider, this endpoint refreshes the access token from the provider.
|
|
977
|
+
*
|
|
978
|
+
* @param {string} sessionId - Session ID. Use the string 'current' to update the current device session.
|
|
979
|
+
* @throws {OwbaseException}
|
|
980
|
+
* @returns {Promise<Models.Session>}
|
|
981
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
982
|
+
*/
|
|
983
|
+
updateSession(sessionId: string): Promise<Models.Session>;
|
|
984
|
+
/**
|
|
985
|
+
* Logout the user. Use 'current' as the session ID to logout on this device, use a session ID to logout on another device. If you're looking to logout the user on all devices, use [Delete Sessions](https://docs.owbase.dev/references/cloud/client-web/account#deleteSessions) instead.
|
|
986
|
+
*
|
|
987
|
+
* @param {string} params.sessionId - Session ID. Use the string 'current' to delete the current device session.
|
|
988
|
+
* @throws {OwbaseException}
|
|
989
|
+
* @returns {Promise<{}>}
|
|
990
|
+
*/
|
|
991
|
+
deleteSession(params: {
|
|
992
|
+
sessionId: string;
|
|
993
|
+
}): Promise<{}>;
|
|
994
|
+
/**
|
|
995
|
+
* Logout the user. Use 'current' as the session ID to logout on this device, use a session ID to logout on another device. If you're looking to logout the user on all devices, use [Delete Sessions](https://docs.owbase.dev/references/cloud/client-web/account#deleteSessions) instead.
|
|
996
|
+
*
|
|
997
|
+
* @param {string} sessionId - Session ID. Use the string 'current' to delete the current device session.
|
|
998
|
+
* @throws {OwbaseException}
|
|
999
|
+
* @returns {Promise<{}>}
|
|
1000
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
1001
|
+
*/
|
|
1002
|
+
deleteSession(sessionId: string): Promise<{}>;
|
|
1003
|
+
/**
|
|
1004
|
+
* Block the currently logged in user account. Behind the scene, the user record is not deleted but permanently blocked from any access. To completely delete a user, use the Users API instead.
|
|
1005
|
+
*
|
|
1006
|
+
* @throws {OwbaseException}
|
|
1007
|
+
* @returns {Promise<Models.User<Preferences>>}
|
|
1008
|
+
*/
|
|
1009
|
+
updateStatus<Preferences extends Models.Preferences = Models.DefaultPreferences>(): Promise<Models.User<Preferences>>;
|
|
1010
|
+
/**
|
|
1011
|
+
* Sends the user an email with a secret key for creating a session. If the email address has never been used, a **new account is created** using the provided `userId`. Otherwise, if the email address is already attached to an account, the **user ID is ignored**. Then, the user will receive an email with the one-time password. Use the returned user ID and secret and submit a request to the [POST /v1/account/sessions/token](https://docs.owbase.dev/references/cloud/client-web/account#createSession) endpoint to complete the login process. The secret sent to the user's email is valid for 15 minutes.
|
|
1012
|
+
*
|
|
1013
|
+
* A user is limited to 10 active sessions at a time by default. [Learn more about session limits](https://docs.owbase.dev/authentication-security#limits).
|
|
1014
|
+
*
|
|
1015
|
+
*
|
|
1016
|
+
* @param {string} params.userId - User ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars. If the email address has never been used, a new account is created using the provided userId. Otherwise, if the email address is already attached to an account, the user ID is ignored.
|
|
1017
|
+
* @param {string} params.email - User email.
|
|
1018
|
+
* @param {boolean} params.phrase - Toggle for security phrase. If enabled, email will be send with a randomly generated phrase and the phrase will also be included in the response. Confirming phrases match increases the security of your authentication flow.
|
|
1019
|
+
* @throws {OwbaseException}
|
|
1020
|
+
* @returns {Promise<Models.Token>}
|
|
1021
|
+
*/
|
|
1022
|
+
createEmailToken(params: {
|
|
1023
|
+
userId: string;
|
|
1024
|
+
email: string;
|
|
1025
|
+
phrase?: boolean;
|
|
1026
|
+
}): Promise<Models.Token>;
|
|
1027
|
+
/**
|
|
1028
|
+
* Sends the user an email with a secret key for creating a session. If the email address has never been used, a **new account is created** using the provided `userId`. Otherwise, if the email address is already attached to an account, the **user ID is ignored**. Then, the user will receive an email with the one-time password. Use the returned user ID and secret and submit a request to the [POST /v1/account/sessions/token](https://docs.owbase.dev/references/cloud/client-web/account#createSession) endpoint to complete the login process. The secret sent to the user's email is valid for 15 minutes.
|
|
1029
|
+
*
|
|
1030
|
+
* A user is limited to 10 active sessions at a time by default. [Learn more about session limits](https://docs.owbase.dev/authentication-security#limits).
|
|
1031
|
+
*
|
|
1032
|
+
*
|
|
1033
|
+
* @param {string} userId - User ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars. If the email address has never been used, a new account is created using the provided userId. Otherwise, if the email address is already attached to an account, the user ID is ignored.
|
|
1034
|
+
* @param {string} email - User email.
|
|
1035
|
+
* @param {boolean} phrase - Toggle for security phrase. If enabled, email will be send with a randomly generated phrase and the phrase will also be included in the response. Confirming phrases match increases the security of your authentication flow.
|
|
1036
|
+
* @throws {OwbaseException}
|
|
1037
|
+
* @returns {Promise<Models.Token>}
|
|
1038
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
1039
|
+
*/
|
|
1040
|
+
createEmailToken(userId: string, email: string, phrase?: boolean): Promise<Models.Token>;
|
|
1041
|
+
/**
|
|
1042
|
+
* Sends the user an email with a secret key for creating a session. If the provided user ID has not been registered, a new user will be created. When the user clicks the link in the email, the user is redirected back to the URL you provided with the secret key and userId values attached to the URL query string. Use the query string parameters to submit a request to the [POST /v1/account/sessions/token](https://docs.owbase.dev/references/cloud/client-web/account#createSession) endpoint to complete the login process. The link sent to the user's email address is valid for 1 hour.
|
|
1043
|
+
*
|
|
1044
|
+
* A user is limited to 10 active sessions at a time by default. [Learn more about session limits](https://docs.owbase.dev/authentication-security#limits).
|
|
1045
|
+
*
|
|
1046
|
+
*
|
|
1047
|
+
* @param {string} params.userId - Unique Id. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars. If the email address has never been used, a new account is created using the provided userId. Otherwise, if the email address is already attached to an account, the user ID is ignored.
|
|
1048
|
+
* @param {string} params.email - User email.
|
|
1049
|
+
* @param {string} params.url - URL to redirect the user back to your app from the magic URL login. Only URLs from hostnames in your project platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
|
|
1050
|
+
* @param {boolean} params.phrase - Toggle for security phrase. If enabled, email will be send with a randomly generated phrase and the phrase will also be included in the response. Confirming phrases match increases the security of your authentication flow.
|
|
1051
|
+
* @throws {OwbaseException}
|
|
1052
|
+
* @returns {Promise<Models.Token>}
|
|
1053
|
+
*/
|
|
1054
|
+
createMagicURLToken(params: {
|
|
1055
|
+
userId: string;
|
|
1056
|
+
email: string;
|
|
1057
|
+
url?: string;
|
|
1058
|
+
phrase?: boolean;
|
|
1059
|
+
}): Promise<Models.Token>;
|
|
1060
|
+
/**
|
|
1061
|
+
* Sends the user an email with a secret key for creating a session. If the provided user ID has not been registered, a new user will be created. When the user clicks the link in the email, the user is redirected back to the URL you provided with the secret key and userId values attached to the URL query string. Use the query string parameters to submit a request to the [POST /v1/account/sessions/token](https://docs.owbase.dev/references/cloud/client-web/account#createSession) endpoint to complete the login process. The link sent to the user's email address is valid for 1 hour.
|
|
1062
|
+
*
|
|
1063
|
+
* A user is limited to 10 active sessions at a time by default. [Learn more about session limits](https://docs.owbase.dev/authentication-security#limits).
|
|
1064
|
+
*
|
|
1065
|
+
*
|
|
1066
|
+
* @param {string} userId - Unique Id. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars. If the email address has never been used, a new account is created using the provided userId. Otherwise, if the email address is already attached to an account, the user ID is ignored.
|
|
1067
|
+
* @param {string} email - User email.
|
|
1068
|
+
* @param {string} url - URL to redirect the user back to your app from the magic URL login. Only URLs from hostnames in your project platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
|
|
1069
|
+
* @param {boolean} phrase - Toggle for security phrase. If enabled, email will be send with a randomly generated phrase and the phrase will also be included in the response. Confirming phrases match increases the security of your authentication flow.
|
|
1070
|
+
* @throws {OwbaseException}
|
|
1071
|
+
* @returns {Promise<Models.Token>}
|
|
1072
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
1073
|
+
*/
|
|
1074
|
+
createMagicURLToken(userId: string, email: string, url?: string, phrase?: boolean): Promise<Models.Token>;
|
|
1075
|
+
/**
|
|
1076
|
+
* Allow the user to login to their account using the OAuth2 provider of their choice. Each OAuth2 provider should be enabled from the Owbase console first. Use the success and failure arguments to provide a redirect URL's back to your app when login is completed.
|
|
1077
|
+
*
|
|
1078
|
+
* If authentication succeeds, `userId` and `secret` of a token will be appended to the success URL as query parameters. These can be used to create a new session using the [Create session](https://docs.owbase.dev/references/cloud/client-web/account#createSession) endpoint.
|
|
1079
|
+
*
|
|
1080
|
+
* If there is already an active session, the OAuth2 identity is attached to the logged-in account and that session stays active until the token is exchanged for a new one.
|
|
1081
|
+
*
|
|
1082
|
+
* A user is limited to 10 active sessions at a time by default. [Learn more about session limits](https://docs.owbase.dev/authentication-security#limits).
|
|
1083
|
+
*
|
|
1084
|
+
* @param {OAuthProvider} params.provider - OAuth2 Provider. Currently, supported providers are: amazon, apple, auth0, authentik, autodesk, bitbucket, bitly, box, cloudflare, dailymotion, discord, disqus, dropbox, etsy, facebook, figma, fusionauth, github, gitlab, google, huggingface, kakao, keycloak, kick, linkedin, microsoft, notion, oidc, okta, paypal, paypalSandbox, podio, resend, salesforce, slack, spotify, stripe, tiktok, tradeshift, tradeshiftBox, twitch, webflow, wordpress, x, yahoo, yammer, yandex, zoho, zoom.
|
|
1085
|
+
* @param {string} params.success - URL to redirect back to your app after a successful login attempt. Only URLs from hostnames in your project's platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
|
|
1086
|
+
* @param {string} params.failure - URL to redirect back to your app after a failed login attempt. Only URLs from hostnames in your project's platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
|
|
1087
|
+
* @param {string[]} params.scopes - A list of custom OAuth2 scopes. Check each provider internal docs for a list of supported scopes. Maximum of 100 scopes are allowed, each 4096 characters long.
|
|
1088
|
+
* @param {string} params.state - An opaque value your app generates and keeps, for example in a cookie. It is returned unchanged as the `state` query parameter on the success and failure URLs, so your app can check that the sign-in it receives is one it started. Printable ASCII only (RFC 6749 Appendix A.5). Max length: 256 chars.
|
|
1089
|
+
* @throws {OwbaseException}
|
|
1090
|
+
* @returns {Promise<string>}
|
|
1091
|
+
*/
|
|
1092
|
+
createOAuth2Token(params: {
|
|
1093
|
+
provider: OAuthProvider;
|
|
1094
|
+
success?: string;
|
|
1095
|
+
failure?: string;
|
|
1096
|
+
scopes?: string[];
|
|
1097
|
+
state?: string;
|
|
1098
|
+
}): Promise<string>;
|
|
1099
|
+
/**
|
|
1100
|
+
* Allow the user to login to their account using the OAuth2 provider of their choice. Each OAuth2 provider should be enabled from the Owbase console first. Use the success and failure arguments to provide a redirect URL's back to your app when login is completed.
|
|
1101
|
+
*
|
|
1102
|
+
* If authentication succeeds, `userId` and `secret` of a token will be appended to the success URL as query parameters. These can be used to create a new session using the [Create session](https://docs.owbase.dev/references/cloud/client-web/account#createSession) endpoint.
|
|
1103
|
+
*
|
|
1104
|
+
* If there is already an active session, the OAuth2 identity is attached to the logged-in account and that session stays active until the token is exchanged for a new one.
|
|
1105
|
+
*
|
|
1106
|
+
* A user is limited to 10 active sessions at a time by default. [Learn more about session limits](https://docs.owbase.dev/authentication-security#limits).
|
|
1107
|
+
*
|
|
1108
|
+
* @param {OAuthProvider} provider - OAuth2 Provider. Currently, supported providers are: amazon, apple, auth0, authentik, autodesk, bitbucket, bitly, box, cloudflare, dailymotion, discord, disqus, dropbox, etsy, facebook, figma, fusionauth, github, gitlab, google, huggingface, kakao, keycloak, kick, linkedin, microsoft, notion, oidc, okta, paypal, paypalSandbox, podio, resend, salesforce, slack, spotify, stripe, tiktok, tradeshift, tradeshiftBox, twitch, webflow, wordpress, x, yahoo, yammer, yandex, zoho, zoom.
|
|
1109
|
+
* @param {string} success - URL to redirect back to your app after a successful login attempt. Only URLs from hostnames in your project's platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
|
|
1110
|
+
* @param {string} failure - URL to redirect back to your app after a failed login attempt. Only URLs from hostnames in your project's platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
|
|
1111
|
+
* @param {string[]} scopes - A list of custom OAuth2 scopes. Check each provider internal docs for a list of supported scopes. Maximum of 100 scopes are allowed, each 4096 characters long.
|
|
1112
|
+
* @param {string} state - An opaque value your app generates and keeps, for example in a cookie. It is returned unchanged as the `state` query parameter on the success and failure URLs, so your app can check that the sign-in it receives is one it started. Printable ASCII only (RFC 6749 Appendix A.5). Max length: 256 chars.
|
|
1113
|
+
* @throws {OwbaseException}
|
|
1114
|
+
* @returns {Promise<string>}
|
|
1115
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
1116
|
+
*/
|
|
1117
|
+
createOAuth2Token(provider: OAuthProvider, success?: string, failure?: string, scopes?: string[], state?: string): Promise<string>;
|
|
1118
|
+
/**
|
|
1119
|
+
* Start signing in with a passkey. No email or user ID is needed: pass the returned `publicKey` options to `navigator.credentials.get()` and the user picks one of their passkeys. Then call [Update passkey token](/docs/references/cloud/client-web/account#updatePasskeyToken) with the credential to receive a token, and exchange it with [Create session](/docs/references/cloud/client-web/account#createSession). The challenge expires after 5 minutes.
|
|
1120
|
+
*
|
|
1121
|
+
* @throws {OwbaseException}
|
|
1122
|
+
* @returns {Promise<Models.PasskeyChallenge>}
|
|
1123
|
+
*/
|
|
1124
|
+
createPasskeyToken(): Promise<Models.PasskeyChallenge>;
|
|
1125
|
+
/**
|
|
1126
|
+
* Complete a passkey sign-in started with [Create passkey token](/docs/references/cloud/client-web/account#createPasskeyToken). Pass the challenge ID and the JSON form of the credential returned by `navigator.credentials.get()`, for example `credential.toJSON()`. The returned token includes its secret and expires after 1 minute: exchange it for a session with [Create session](/docs/references/cloud/client-web/account#createSession). Passkeys require user verification, so the session also satisfies MFA. Each challenge can only be used once.
|
|
1127
|
+
*
|
|
1128
|
+
* @param {string} params.challengeId - Challenge ID returned by createPasskeyToken.
|
|
1129
|
+
* @param {object} params.credential - Authentication credential returned by the authenticator, in the JSON form produced by `PublicKeyCredential.toJSON()`.
|
|
1130
|
+
* @throws {OwbaseException}
|
|
1131
|
+
* @returns {Promise<Models.TokenSecret>}
|
|
1132
|
+
*/
|
|
1133
|
+
updatePasskeyToken(params: {
|
|
1134
|
+
challengeId: string;
|
|
1135
|
+
credential: object;
|
|
1136
|
+
}): Promise<Models.TokenSecret>;
|
|
1137
|
+
/**
|
|
1138
|
+
* Complete a passkey sign-in started with [Create passkey token](/docs/references/cloud/client-web/account#createPasskeyToken). Pass the challenge ID and the JSON form of the credential returned by `navigator.credentials.get()`, for example `credential.toJSON()`. The returned token includes its secret and expires after 1 minute: exchange it for a session with [Create session](/docs/references/cloud/client-web/account#createSession). Passkeys require user verification, so the session also satisfies MFA. Each challenge can only be used once.
|
|
1139
|
+
*
|
|
1140
|
+
* @param {string} challengeId - Challenge ID returned by createPasskeyToken.
|
|
1141
|
+
* @param {object} credential - Authentication credential returned by the authenticator, in the JSON form produced by `PublicKeyCredential.toJSON()`.
|
|
1142
|
+
* @throws {OwbaseException}
|
|
1143
|
+
* @returns {Promise<Models.TokenSecret>}
|
|
1144
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
1145
|
+
*/
|
|
1146
|
+
updatePasskeyToken(challengeId: string, credential: object): Promise<Models.TokenSecret>;
|
|
1147
|
+
/**
|
|
1148
|
+
* Sends the user an SMS with a secret key for creating a session. If the provided user ID has not be registered, a new user will be created. Use the returned user ID and secret and submit a request to the [POST /v1/account/sessions/token](https://docs.owbase.dev/references/cloud/client-web/account#createSession) endpoint to complete the login process. The secret sent to the user's phone is valid for 15 minutes.
|
|
1149
|
+
*
|
|
1150
|
+
* A user is limited to 10 active sessions at a time by default. [Learn more about session limits](https://docs.owbase.dev/authentication-security#limits).
|
|
1151
|
+
*
|
|
1152
|
+
* @param {string} params.userId - Unique Id. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars. If the phone number has never been used, a new account is created using the provided userId. Otherwise, if the phone number is already attached to an account, the user ID is ignored.
|
|
1153
|
+
* @param {string} params.phone - Phone number. Format this number with a leading '+' and a country code, e.g., +16175551212.
|
|
1154
|
+
* @throws {OwbaseException}
|
|
1155
|
+
* @returns {Promise<Models.Token>}
|
|
1156
|
+
*/
|
|
1157
|
+
createPhoneToken(params: {
|
|
1158
|
+
userId: string;
|
|
1159
|
+
phone: string;
|
|
1160
|
+
}): Promise<Models.Token>;
|
|
1161
|
+
/**
|
|
1162
|
+
* Sends the user an SMS with a secret key for creating a session. If the provided user ID has not be registered, a new user will be created. Use the returned user ID and secret and submit a request to the [POST /v1/account/sessions/token](https://docs.owbase.dev/references/cloud/client-web/account#createSession) endpoint to complete the login process. The secret sent to the user's phone is valid for 15 minutes.
|
|
1163
|
+
*
|
|
1164
|
+
* A user is limited to 10 active sessions at a time by default. [Learn more about session limits](https://docs.owbase.dev/authentication-security#limits).
|
|
1165
|
+
*
|
|
1166
|
+
* @param {string} userId - Unique Id. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars. If the phone number has never been used, a new account is created using the provided userId. Otherwise, if the phone number is already attached to an account, the user ID is ignored.
|
|
1167
|
+
* @param {string} phone - Phone number. Format this number with a leading '+' and a country code, e.g., +16175551212.
|
|
1168
|
+
* @throws {OwbaseException}
|
|
1169
|
+
* @returns {Promise<Models.Token>}
|
|
1170
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
1171
|
+
*/
|
|
1172
|
+
createPhoneToken(userId: string, phone: string): Promise<Models.Token>;
|
|
1173
|
+
/**
|
|
1174
|
+
* Use this endpoint to send a verification message to your user email address to confirm they are the valid owners of that address. Both the **userId** and **secret** arguments will be passed as query parameters to the URL you have provided to be attached to the verification email. The provided URL should redirect the user back to your app and allow you to complete the verification process by verifying both the **userId** and **secret** parameters. Learn more about how to [complete the verification process](https://docs.owbase.dev/references/cloud/client-web/account#updateVerification). The verification link sent to the user's email address is valid for 7 days.
|
|
1175
|
+
*
|
|
1176
|
+
* Please note that in order to avoid a [Redirect Attack](https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.md), the only valid redirect URLs are the ones from domains you have set when adding your platforms in the console interface.
|
|
1177
|
+
*
|
|
1178
|
+
*
|
|
1179
|
+
* @param {string} params.url - URL to redirect the user back to your app from the verification email. Only URLs from hostnames in your project platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
|
|
1180
|
+
* @throws {OwbaseException}
|
|
1181
|
+
* @returns {Promise<Models.Token>}
|
|
1182
|
+
*/
|
|
1183
|
+
createEmailVerification(params: {
|
|
1184
|
+
url: string;
|
|
1185
|
+
}): Promise<Models.Token>;
|
|
1186
|
+
/**
|
|
1187
|
+
* Use this endpoint to send a verification message to your user email address to confirm they are the valid owners of that address. Both the **userId** and **secret** arguments will be passed as query parameters to the URL you have provided to be attached to the verification email. The provided URL should redirect the user back to your app and allow you to complete the verification process by verifying both the **userId** and **secret** parameters. Learn more about how to [complete the verification process](https://docs.owbase.dev/references/cloud/client-web/account#updateVerification). The verification link sent to the user's email address is valid for 7 days.
|
|
1188
|
+
*
|
|
1189
|
+
* Please note that in order to avoid a [Redirect Attack](https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.md), the only valid redirect URLs are the ones from domains you have set when adding your platforms in the console interface.
|
|
1190
|
+
*
|
|
1191
|
+
*
|
|
1192
|
+
* @param {string} url - URL to redirect the user back to your app from the verification email. Only URLs from hostnames in your project platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
|
|
1193
|
+
* @throws {OwbaseException}
|
|
1194
|
+
* @returns {Promise<Models.Token>}
|
|
1195
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
1196
|
+
*/
|
|
1197
|
+
createEmailVerification(url: string): Promise<Models.Token>;
|
|
1198
|
+
/**
|
|
1199
|
+
* Use this endpoint to send a verification message to your user email address to confirm they are the valid owners of that address. Both the **userId** and **secret** arguments will be passed as query parameters to the URL you have provided to be attached to the verification email. The provided URL should redirect the user back to your app and allow you to complete the verification process by verifying both the **userId** and **secret** parameters. Learn more about how to [complete the verification process](https://docs.owbase.dev/references/cloud/client-web/account#updateVerification). The verification link sent to the user's email address is valid for 7 days.
|
|
1200
|
+
*
|
|
1201
|
+
* Please note that in order to avoid a [Redirect Attack](https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.md), the only valid redirect URLs are the ones from domains you have set when adding your platforms in the console interface.
|
|
1202
|
+
*
|
|
1203
|
+
*
|
|
1204
|
+
* @param {string} params.url - URL to redirect the user back to your app from the verification email. Only URLs from hostnames in your project platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
|
|
1205
|
+
* @throws {OwbaseException}
|
|
1206
|
+
* @returns {Promise<Models.Token>}
|
|
1207
|
+
* @deprecated This API has been deprecated since 1.8.0. Please use `Account.createEmailVerification` instead.
|
|
1208
|
+
*/
|
|
1209
|
+
createVerification(params: {
|
|
1210
|
+
url: string;
|
|
1211
|
+
}): Promise<Models.Token>;
|
|
1212
|
+
/**
|
|
1213
|
+
* Use this endpoint to send a verification message to your user email address to confirm they are the valid owners of that address. Both the **userId** and **secret** arguments will be passed as query parameters to the URL you have provided to be attached to the verification email. The provided URL should redirect the user back to your app and allow you to complete the verification process by verifying both the **userId** and **secret** parameters. Learn more about how to [complete the verification process](https://docs.owbase.dev/references/cloud/client-web/account#updateVerification). The verification link sent to the user's email address is valid for 7 days.
|
|
1214
|
+
*
|
|
1215
|
+
* Please note that in order to avoid a [Redirect Attack](https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.md), the only valid redirect URLs are the ones from domains you have set when adding your platforms in the console interface.
|
|
1216
|
+
*
|
|
1217
|
+
*
|
|
1218
|
+
* @param {string} url - URL to redirect the user back to your app from the verification email. Only URLs from hostnames in your project platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
|
|
1219
|
+
* @throws {OwbaseException}
|
|
1220
|
+
* @returns {Promise<Models.Token>}
|
|
1221
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
1222
|
+
*/
|
|
1223
|
+
createVerification(url: string): Promise<Models.Token>;
|
|
1224
|
+
/**
|
|
1225
|
+
* Use this endpoint to complete the user email verification process. Use both the **userId** and **secret** parameters that were attached to your app URL to verify the user email ownership. If confirmed this route will return a 200 status code.
|
|
1226
|
+
*
|
|
1227
|
+
* @param {string} params.userId - User ID.
|
|
1228
|
+
* @param {string} params.secret - Valid verification token.
|
|
1229
|
+
* @throws {OwbaseException}
|
|
1230
|
+
* @returns {Promise<Models.Token>}
|
|
1231
|
+
*/
|
|
1232
|
+
updateEmailVerification(params: {
|
|
1233
|
+
userId: string;
|
|
1234
|
+
secret: string;
|
|
1235
|
+
}): Promise<Models.Token>;
|
|
1236
|
+
/**
|
|
1237
|
+
* Use this endpoint to complete the user email verification process. Use both the **userId** and **secret** parameters that were attached to your app URL to verify the user email ownership. If confirmed this route will return a 200 status code.
|
|
1238
|
+
*
|
|
1239
|
+
* @param {string} userId - User ID.
|
|
1240
|
+
* @param {string} secret - Valid verification token.
|
|
1241
|
+
* @throws {OwbaseException}
|
|
1242
|
+
* @returns {Promise<Models.Token>}
|
|
1243
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
1244
|
+
*/
|
|
1245
|
+
updateEmailVerification(userId: string, secret: string): Promise<Models.Token>;
|
|
1246
|
+
/**
|
|
1247
|
+
* Use this endpoint to complete the user email verification process. Use both the **userId** and **secret** parameters that were attached to your app URL to verify the user email ownership. If confirmed this route will return a 200 status code.
|
|
1248
|
+
*
|
|
1249
|
+
* @param {string} params.userId - User ID.
|
|
1250
|
+
* @param {string} params.secret - Valid verification token.
|
|
1251
|
+
* @throws {OwbaseException}
|
|
1252
|
+
* @returns {Promise<Models.Token>}
|
|
1253
|
+
* @deprecated This API has been deprecated since 1.8.0. Please use `Account.updateEmailVerification` instead.
|
|
1254
|
+
*/
|
|
1255
|
+
updateVerification(params: {
|
|
1256
|
+
userId: string;
|
|
1257
|
+
secret: string;
|
|
1258
|
+
}): Promise<Models.Token>;
|
|
1259
|
+
/**
|
|
1260
|
+
* Use this endpoint to complete the user email verification process. Use both the **userId** and **secret** parameters that were attached to your app URL to verify the user email ownership. If confirmed this route will return a 200 status code.
|
|
1261
|
+
*
|
|
1262
|
+
* @param {string} userId - User ID.
|
|
1263
|
+
* @param {string} secret - Valid verification token.
|
|
1264
|
+
* @throws {OwbaseException}
|
|
1265
|
+
* @returns {Promise<Models.Token>}
|
|
1266
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
1267
|
+
*/
|
|
1268
|
+
updateVerification(userId: string, secret: string): Promise<Models.Token>;
|
|
1269
|
+
/**
|
|
1270
|
+
* Use this endpoint to send a 6-digit verification code to the currently logged in user's email address. Unlike [createEmailVerification](https://docs.owbase.dev/references/cloud/client-web/account#createEmailVerification), this method requires no redirect URL, which makes it suitable for mobile and desktop apps that cannot host a verification page. Learn more about how to [complete the verification process](https://docs.owbase.dev/references/cloud/client-web/account#updateEmailVerificationOTP). The code sent to the user's email address is valid for 15 minutes.
|
|
1271
|
+
*
|
|
1272
|
+
* Enable the **phrase** parameter to include a randomly generated security phrase in both the email and the response. Showing that phrase in your app lets the user confirm the email genuinely came from your request, which helps protect against phishing.
|
|
1273
|
+
*
|
|
1274
|
+
*
|
|
1275
|
+
* @param {boolean} params.phrase - Toggle for security phrase. If enabled, email will be sent with a randomly generated phrase and the phrase will also be included in the response. Confirming phrases match increases the security of your authentication flow.
|
|
1276
|
+
* @throws {OwbaseException}
|
|
1277
|
+
* @returns {Promise<Models.Token>}
|
|
1278
|
+
*/
|
|
1279
|
+
createEmailVerificationOTP(params?: {
|
|
1280
|
+
phrase?: boolean;
|
|
1281
|
+
}): Promise<Models.Token>;
|
|
1282
|
+
/**
|
|
1283
|
+
* Use this endpoint to send a 6-digit verification code to the currently logged in user's email address. Unlike [createEmailVerification](https://docs.owbase.dev/references/cloud/client-web/account#createEmailVerification), this method requires no redirect URL, which makes it suitable for mobile and desktop apps that cannot host a verification page. Learn more about how to [complete the verification process](https://docs.owbase.dev/references/cloud/client-web/account#updateEmailVerificationOTP). The code sent to the user's email address is valid for 15 minutes.
|
|
1284
|
+
*
|
|
1285
|
+
* Enable the **phrase** parameter to include a randomly generated security phrase in both the email and the response. Showing that phrase in your app lets the user confirm the email genuinely came from your request, which helps protect against phishing.
|
|
1286
|
+
*
|
|
1287
|
+
*
|
|
1288
|
+
* @param {boolean} phrase - Toggle for security phrase. If enabled, email will be sent with a randomly generated phrase and the phrase will also be included in the response. Confirming phrases match increases the security of your authentication flow.
|
|
1289
|
+
* @throws {OwbaseException}
|
|
1290
|
+
* @returns {Promise<Models.Token>}
|
|
1291
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
1292
|
+
*/
|
|
1293
|
+
createEmailVerificationOTP(phrase?: boolean): Promise<Models.Token>;
|
|
1294
|
+
/**
|
|
1295
|
+
* Use this endpoint to complete the user email verification process using the 6-digit code that was emailed by [createEmailVerificationOTP](https://docs.owbase.dev/references/cloud/client-web/account#createEmailVerificationOTP). Pass the **userId** of the user being verified along with the **secret** code from the email. If confirmed, this route will return a 200 status code and the code is consumed.
|
|
1296
|
+
*
|
|
1297
|
+
*
|
|
1298
|
+
* @param {string} params.userId - User ID.
|
|
1299
|
+
* @param {string} params.secret - Valid verification OTP code.
|
|
1300
|
+
* @throws {OwbaseException}
|
|
1301
|
+
* @returns {Promise<Models.Token>}
|
|
1302
|
+
*/
|
|
1303
|
+
updateEmailVerificationOTP(params: {
|
|
1304
|
+
userId: string;
|
|
1305
|
+
secret: string;
|
|
1306
|
+
}): Promise<Models.Token>;
|
|
1307
|
+
/**
|
|
1308
|
+
* Use this endpoint to complete the user email verification process using the 6-digit code that was emailed by [createEmailVerificationOTP](https://docs.owbase.dev/references/cloud/client-web/account#createEmailVerificationOTP). Pass the **userId** of the user being verified along with the **secret** code from the email. If confirmed, this route will return a 200 status code and the code is consumed.
|
|
1309
|
+
*
|
|
1310
|
+
*
|
|
1311
|
+
* @param {string} userId - User ID.
|
|
1312
|
+
* @param {string} secret - Valid verification OTP code.
|
|
1313
|
+
* @throws {OwbaseException}
|
|
1314
|
+
* @returns {Promise<Models.Token>}
|
|
1315
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
1316
|
+
*/
|
|
1317
|
+
updateEmailVerificationOTP(userId: string, secret: string): Promise<Models.Token>;
|
|
1318
|
+
/**
|
|
1319
|
+
* Use this endpoint to send a verification SMS to the currently logged in user. This endpoint is meant for use after updating a user's phone number using the [accountUpdatePhone](https://docs.owbase.dev/references/cloud/client-web/account#updatePhone) endpoint. Learn more about how to [complete the verification process](https://docs.owbase.dev/references/cloud/client-web/account#updatePhoneVerification). The verification code sent to the user's phone number is valid for 15 minutes.
|
|
1320
|
+
*
|
|
1321
|
+
* @throws {OwbaseException}
|
|
1322
|
+
* @returns {Promise<Models.Token>}
|
|
1323
|
+
*/
|
|
1324
|
+
createPhoneVerification(): Promise<Models.Token>;
|
|
1325
|
+
/**
|
|
1326
|
+
* Use this endpoint to complete the user phone verification process. Use the **userId** and **secret** that were sent to your user's phone number to verify the user email ownership. If confirmed this route will return a 200 status code.
|
|
1327
|
+
*
|
|
1328
|
+
* @param {string} params.userId - User ID.
|
|
1329
|
+
* @param {string} params.secret - Valid verification token.
|
|
1330
|
+
* @throws {OwbaseException}
|
|
1331
|
+
* @returns {Promise<Models.Token>}
|
|
1332
|
+
*/
|
|
1333
|
+
updatePhoneVerification(params: {
|
|
1334
|
+
userId: string;
|
|
1335
|
+
secret: string;
|
|
1336
|
+
}): Promise<Models.Token>;
|
|
1337
|
+
/**
|
|
1338
|
+
* Use this endpoint to complete the user phone verification process. Use the **userId** and **secret** that were sent to your user's phone number to verify the user email ownership. If confirmed this route will return a 200 status code.
|
|
1339
|
+
*
|
|
1340
|
+
* @param {string} userId - User ID.
|
|
1341
|
+
* @param {string} secret - Valid verification token.
|
|
1342
|
+
* @throws {OwbaseException}
|
|
1343
|
+
* @returns {Promise<Models.Token>}
|
|
1344
|
+
* @deprecated Use the object parameter style method for a better developer experience.
|
|
1345
|
+
*/
|
|
1346
|
+
updatePhoneVerification(userId: string, secret: string): Promise<Models.Token>;
|
|
1347
|
+
}
|
|
1348
|
+
|
|
1349
|
+
export { Account };
|