@appwrite.io/console 0.6.0-rc.1 → 0.6.0-rc.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/cjs/sdk.js +1853 -426
- package/dist/cjs/sdk.js.map +1 -1
- package/dist/esm/sdk.js +1854 -427
- package/dist/esm/sdk.js.map +1 -1
- package/dist/iife/sdk.js +1853 -426
- package/docs/examples/account/add-authenticator.md +2 -2
- package/docs/examples/account/create-anonymous-session.md +1 -1
- package/docs/examples/account/{create-magic-u-r-l-session.md → create-email-password-session.md} +2 -2
- package/docs/examples/account/{create-email-session.md → create-email-token.md} +2 -2
- package/docs/examples/account/create-j-w-t.md +1 -1
- package/docs/examples/account/create-magic-u-r-l-token.md +18 -0
- package/docs/examples/account/create-o-auth2session.md +2 -2
- package/docs/examples/account/{create-phone-session.md → create-phone-token.md} +2 -2
- package/docs/examples/account/create-phone-verification.md +1 -1
- package/docs/examples/account/create-push-target.md +18 -0
- package/docs/examples/account/create-recovery.md +1 -1
- package/docs/examples/account/{update-phone-session.md → create-session.md} +2 -2
- package/docs/examples/account/create-verification.md +1 -1
- package/docs/examples/account/create.md +1 -1
- package/docs/examples/account/create2f-a-challenge.md +18 -0
- package/docs/examples/account/delete-authenticator.md +18 -0
- package/docs/examples/account/delete-identity.md +1 -1
- package/docs/examples/account/delete-push-target.md +18 -0
- package/docs/examples/account/delete-session.md +1 -1
- package/docs/examples/account/delete-sessions.md +1 -1
- package/docs/examples/account/{list-providers.md → delete.md} +2 -2
- package/docs/examples/account/get-prefs.md +1 -1
- package/docs/examples/account/get-session.md +1 -1
- package/docs/examples/account/get.md +1 -1
- package/docs/examples/account/{create-challenge.md → list-factors.md} +2 -2
- package/docs/examples/account/list-identities.md +1 -1
- package/docs/examples/account/list-logs.md +1 -1
- package/docs/examples/account/list-sessions.md +1 -1
- package/docs/examples/account/update-challenge.md +1 -1
- package/docs/examples/account/update-email.md +1 -1
- package/docs/examples/account/update-m-f-a.md +1 -1
- package/docs/examples/account/update-magic-u-r-l-session.md +1 -1
- package/docs/examples/account/update-name.md +1 -1
- package/docs/examples/account/update-password.md +1 -1
- package/docs/examples/account/update-phone-verification.md +1 -1
- package/docs/examples/account/update-phone.md +1 -1
- package/docs/examples/account/update-prefs.md +1 -1
- package/docs/examples/account/update-push-target.md +18 -0
- package/docs/examples/account/update-recovery.md +2 -2
- package/docs/examples/account/update-session.md +1 -1
- package/docs/examples/account/update-status.md +1 -1
- package/docs/examples/account/update-verification.md +1 -1
- package/docs/examples/account/verify-authenticator.md +2 -2
- package/docs/examples/assistant/chat.md +1 -1
- package/docs/examples/avatars/get-browser.md +2 -2
- package/docs/examples/avatars/get-credit-card.md +2 -2
- package/docs/examples/avatars/get-favicon.md +1 -1
- package/docs/examples/avatars/get-flag.md +2 -2
- package/docs/examples/avatars/get-image.md +1 -1
- package/docs/examples/avatars/get-initials.md +1 -1
- package/docs/examples/avatars/get-q-r.md +1 -1
- package/docs/examples/console/variables.md +1 -1
- package/docs/examples/databases/create-boolean-attribute.md +1 -1
- package/docs/examples/databases/create-collection.md +1 -1
- package/docs/examples/databases/create-datetime-attribute.md +1 -1
- package/docs/examples/databases/create-document.md +1 -1
- package/docs/examples/databases/create-email-attribute.md +1 -1
- package/docs/examples/databases/create-enum-attribute.md +1 -1
- package/docs/examples/databases/create-float-attribute.md +1 -1
- package/docs/examples/databases/create-index.md +2 -2
- package/docs/examples/databases/create-integer-attribute.md +1 -1
- package/docs/examples/databases/create-ip-attribute.md +1 -1
- package/docs/examples/databases/create-relationship-attribute.md +2 -2
- package/docs/examples/databases/create-string-attribute.md +1 -1
- package/docs/examples/databases/create-url-attribute.md +1 -1
- package/docs/examples/databases/create.md +1 -1
- package/docs/examples/databases/delete-attribute.md +1 -1
- package/docs/examples/databases/delete-collection.md +1 -1
- package/docs/examples/databases/delete-document.md +1 -1
- package/docs/examples/databases/delete-index.md +1 -1
- package/docs/examples/databases/delete.md +1 -1
- package/docs/examples/databases/get-attribute.md +1 -1
- package/docs/examples/databases/get-collection-usage.md +1 -1
- package/docs/examples/databases/get-collection.md +1 -1
- package/docs/examples/databases/get-database-usage.md +1 -1
- package/docs/examples/databases/get-document.md +1 -1
- package/docs/examples/databases/get-index.md +1 -1
- package/docs/examples/databases/get-usage.md +1 -1
- package/docs/examples/databases/get.md +1 -1
- package/docs/examples/databases/list-attributes.md +1 -1
- package/docs/examples/databases/list-collection-logs.md +1 -1
- package/docs/examples/databases/list-collections.md +1 -1
- package/docs/examples/databases/list-document-logs.md +1 -1
- package/docs/examples/databases/list-documents.md +1 -1
- package/docs/examples/databases/list-indexes.md +1 -1
- package/docs/examples/databases/list-logs.md +1 -1
- package/docs/examples/databases/list.md +1 -1
- package/docs/examples/databases/update-boolean-attribute.md +1 -1
- package/docs/examples/databases/update-collection.md +1 -1
- package/docs/examples/databases/update-datetime-attribute.md +1 -1
- package/docs/examples/databases/update-document.md +1 -1
- package/docs/examples/databases/update-email-attribute.md +1 -1
- package/docs/examples/databases/update-enum-attribute.md +1 -1
- package/docs/examples/databases/update-float-attribute.md +1 -1
- package/docs/examples/databases/update-integer-attribute.md +1 -1
- package/docs/examples/databases/update-ip-attribute.md +1 -1
- package/docs/examples/databases/update-relationship-attribute.md +1 -1
- package/docs/examples/databases/update-string-attribute.md +1 -1
- package/docs/examples/databases/update-url-attribute.md +1 -1
- package/docs/examples/databases/update.md +1 -1
- package/docs/examples/functions/create-build.md +1 -1
- package/docs/examples/functions/create-deployment.md +1 -1
- package/docs/examples/functions/create-execution.md +1 -1
- package/docs/examples/functions/create-variable.md +1 -1
- package/docs/examples/functions/create.md +2 -2
- package/docs/examples/functions/delete-deployment.md +1 -1
- package/docs/examples/functions/delete-variable.md +1 -1
- package/docs/examples/functions/delete.md +1 -1
- package/docs/examples/functions/download-deployment.md +1 -1
- package/docs/examples/functions/get-deployment.md +1 -1
- package/docs/examples/functions/get-execution.md +1 -1
- package/docs/examples/functions/get-function-usage.md +1 -1
- package/docs/examples/functions/get-usage.md +1 -1
- package/docs/examples/functions/get-variable.md +1 -1
- package/docs/examples/functions/get.md +1 -1
- package/docs/examples/functions/list-deployments.md +1 -1
- package/docs/examples/functions/list-executions.md +1 -1
- package/docs/examples/functions/list-runtimes.md +1 -1
- package/docs/examples/functions/list-variables.md +1 -1
- package/docs/examples/functions/list.md +1 -1
- package/docs/examples/functions/update-deployment.md +1 -1
- package/docs/examples/functions/update-variable.md +1 -1
- package/docs/examples/functions/update.md +1 -1
- package/docs/examples/graphql/mutation.md +1 -1
- package/docs/examples/graphql/query.md +1 -1
- package/docs/examples/health/get-antivirus.md +1 -1
- package/docs/examples/health/get-cache.md +1 -1
- package/docs/examples/health/get-certificate.md +18 -0
- package/docs/examples/health/get-d-b.md +1 -1
- package/docs/examples/health/get-failed-jobs.md +18 -0
- package/docs/examples/health/get-pub-sub.md +1 -1
- package/docs/examples/health/get-queue-builds.md +1 -1
- package/docs/examples/health/get-queue-certificates.md +1 -1
- package/docs/examples/health/get-queue-databases.md +1 -1
- package/docs/examples/health/get-queue-deletes.md +1 -1
- package/docs/examples/health/get-queue-functions.md +1 -1
- package/docs/examples/health/get-queue-logs.md +1 -1
- package/docs/examples/health/get-queue-mails.md +1 -1
- package/docs/examples/health/get-queue-messaging.md +1 -1
- package/docs/examples/health/get-queue-migrations.md +1 -1
- package/docs/examples/health/get-queue-webhooks.md +1 -1
- package/docs/examples/health/get-queue.md +1 -1
- package/docs/examples/health/get-storage-local.md +1 -1
- package/docs/examples/health/get-time.md +1 -1
- package/docs/examples/health/get.md +1 -1
- package/docs/examples/locale/get.md +1 -1
- package/docs/examples/locale/list-codes.md +1 -1
- package/docs/examples/locale/list-continents.md +1 -1
- package/docs/examples/locale/list-countries-e-u.md +1 -1
- package/docs/examples/locale/list-countries-phones.md +1 -1
- package/docs/examples/locale/list-countries.md +1 -1
- package/docs/examples/locale/list-currencies.md +1 -1
- package/docs/examples/locale/list-languages.md +1 -1
- package/docs/examples/messaging/{create-apns-provider.md → create-a-p-n-s-provider.md} +2 -2
- package/docs/examples/messaging/{create-push-message.md → create-email.md} +2 -2
- package/docs/examples/messaging/{create-fcm-provider.md → create-f-c-m-provider.md} +2 -2
- package/docs/examples/messaging/create-mailgun-provider.md +1 -1
- package/docs/examples/messaging/create-msg91provider.md +1 -1
- package/docs/examples/messaging/{create-s-m-s-message.md → create-push.md} +2 -2
- package/docs/examples/messaging/{update-push-notification.md → create-s-m-s.md} +2 -2
- package/docs/examples/messaging/create-s-m-t-p-provider.md +18 -0
- package/docs/examples/messaging/create-sendgrid-provider.md +1 -1
- package/docs/examples/messaging/create-subscriber.md +1 -1
- package/docs/examples/messaging/create-telesign-provider.md +1 -1
- package/docs/examples/messaging/create-textmagic-provider.md +1 -1
- package/docs/examples/messaging/create-topic.md +1 -1
- package/docs/examples/messaging/create-twilio-provider.md +1 -1
- package/docs/examples/messaging/create-vonage-provider.md +1 -1
- package/docs/examples/messaging/delete-provider.md +1 -1
- package/docs/examples/messaging/delete-subscriber.md +1 -1
- package/docs/examples/messaging/delete-topic.md +1 -1
- package/docs/examples/messaging/{update-fcm-provider.md → delete.md} +2 -2
- package/docs/examples/messaging/get-message.md +1 -1
- package/docs/examples/messaging/get-provider.md +1 -1
- package/docs/examples/messaging/get-subscriber.md +1 -1
- package/docs/examples/messaging/get-topic.md +1 -1
- package/docs/examples/messaging/list-message-logs.md +1 -1
- package/docs/examples/messaging/list-messages.md +1 -1
- package/docs/examples/messaging/list-provider-logs.md +1 -1
- package/docs/examples/messaging/list-providers.md +1 -1
- package/docs/examples/messaging/list-subscriber-logs.md +1 -1
- package/docs/examples/messaging/list-subscribers.md +1 -1
- package/docs/examples/messaging/{update-apns-provider.md → list-targets.md} +2 -2
- package/docs/examples/messaging/list-topic-logs.md +1 -1
- package/docs/examples/messaging/list-topics.md +1 -1
- package/docs/examples/messaging/update-a-p-n-s-provider.md +18 -0
- package/docs/examples/messaging/update-email.md +1 -1
- package/docs/examples/messaging/update-f-c-m-provider.md +18 -0
- package/docs/examples/messaging/update-mailgun-provider.md +1 -1
- package/docs/examples/messaging/update-msg91provider.md +1 -1
- package/docs/examples/messaging/update-push.md +18 -0
- package/docs/examples/messaging/update-s-m-s.md +1 -1
- package/docs/examples/messaging/update-s-m-t-p-provider.md +18 -0
- package/docs/examples/messaging/update-sendgrid-provider.md +1 -1
- package/docs/examples/messaging/update-telesign-provider.md +1 -1
- package/docs/examples/messaging/update-textmagic-provider.md +1 -1
- package/docs/examples/messaging/update-topic.md +1 -1
- package/docs/examples/messaging/update-twilio-provider.md +1 -1
- package/docs/examples/messaging/update-vonage-provider.md +1 -1
- package/docs/examples/migrations/create-appwrite-migration.md +1 -1
- package/docs/examples/migrations/create-firebase-migration.md +1 -1
- package/docs/examples/migrations/create-firebase-o-auth-migration.md +1 -1
- package/docs/examples/migrations/create-n-host-migration.md +1 -1
- package/docs/examples/migrations/create-supabase-migration.md +1 -1
- package/docs/examples/migrations/delete-firebase-auth.md +1 -1
- package/docs/examples/migrations/delete.md +1 -1
- package/docs/examples/migrations/get-appwrite-report.md +1 -1
- package/docs/examples/migrations/get-firebase-report-o-auth.md +1 -1
- package/docs/examples/migrations/get-firebase-report.md +1 -1
- package/docs/examples/migrations/get-n-host-report.md +1 -1
- package/docs/examples/migrations/get-supabase-report.md +1 -1
- package/docs/examples/migrations/get.md +1 -1
- package/docs/examples/migrations/list-firebase-projects.md +1 -1
- package/docs/examples/migrations/list.md +1 -1
- package/docs/examples/migrations/retry.md +1 -1
- package/docs/examples/project/create-variable.md +1 -1
- package/docs/examples/project/delete-variable.md +1 -1
- package/docs/examples/project/get-usage.md +2 -2
- package/docs/examples/project/get-variable.md +1 -1
- package/docs/examples/project/list-variables.md +1 -1
- package/docs/examples/project/update-variable.md +1 -1
- package/docs/examples/projects/create-key.md +1 -1
- package/docs/examples/projects/create-platform.md +2 -2
- package/docs/examples/projects/{update-auth-mfa-factors.md → create-smtp-test.md} +2 -2
- package/docs/examples/projects/create-webhook.md +2 -2
- package/docs/examples/projects/create.md +1 -1
- package/docs/examples/projects/delete-email-template.md +2 -2
- package/docs/examples/projects/delete-key.md +1 -1
- package/docs/examples/projects/delete-platform.md +1 -1
- package/docs/examples/projects/delete-sms-template.md +2 -2
- package/docs/examples/projects/delete-webhook.md +1 -1
- package/docs/examples/projects/delete.md +1 -1
- package/docs/examples/projects/get-email-template.md +2 -2
- package/docs/examples/projects/get-key.md +1 -1
- package/docs/examples/projects/get-platform.md +1 -1
- package/docs/examples/projects/get-sms-template.md +2 -2
- package/docs/examples/projects/get-webhook.md +1 -1
- package/docs/examples/projects/get.md +1 -1
- package/docs/examples/projects/list-keys.md +1 -1
- package/docs/examples/projects/list-platforms.md +1 -1
- package/docs/examples/projects/list-webhooks.md +1 -1
- package/docs/examples/projects/list.md +1 -1
- package/docs/examples/projects/update-auth-duration.md +1 -1
- package/docs/examples/projects/update-auth-limit.md +1 -1
- package/docs/examples/projects/update-auth-password-dictionary.md +1 -1
- package/docs/examples/projects/update-auth-password-history.md +1 -1
- package/docs/examples/projects/update-auth-sessions-limit.md +1 -1
- package/docs/examples/projects/update-auth-status.md +2 -2
- package/docs/examples/projects/update-email-template.md +2 -2
- package/docs/examples/projects/update-key.md +1 -1
- package/docs/examples/projects/update-o-auth2.md +2 -2
- package/docs/examples/projects/update-personal-data-check.md +1 -1
- package/docs/examples/projects/update-platform.md +1 -1
- package/docs/examples/projects/update-service-status-all.md +1 -1
- package/docs/examples/projects/update-service-status.md +2 -2
- package/docs/examples/projects/update-sms-template.md +2 -2
- package/docs/examples/projects/{get-usage.md → update-smtp.md} +2 -2
- package/docs/examples/projects/update-team.md +1 -1
- package/docs/examples/projects/update-webhook-signature.md +1 -1
- package/docs/examples/projects/update-webhook.md +2 -2
- package/docs/examples/projects/update.md +1 -1
- package/docs/examples/proxy/create-rule.md +2 -2
- package/docs/examples/proxy/delete-rule.md +1 -1
- package/docs/examples/proxy/get-rule.md +1 -1
- package/docs/examples/proxy/list-rules.md +1 -1
- package/docs/examples/proxy/update-rule-verification.md +1 -1
- package/docs/examples/storage/create-bucket.md +1 -1
- package/docs/examples/storage/create-file.md +1 -1
- package/docs/examples/storage/delete-bucket.md +1 -1
- package/docs/examples/storage/delete-file.md +1 -1
- package/docs/examples/storage/get-bucket-usage.md +1 -1
- package/docs/examples/storage/get-bucket.md +1 -1
- package/docs/examples/storage/get-file-download.md +1 -1
- package/docs/examples/storage/get-file-preview.md +1 -1
- package/docs/examples/storage/get-file-view.md +1 -1
- package/docs/examples/storage/get-file.md +1 -1
- package/docs/examples/storage/get-usage.md +1 -1
- package/docs/examples/storage/list-buckets.md +1 -1
- package/docs/examples/storage/list-files.md +1 -1
- package/docs/examples/storage/update-bucket.md +1 -1
- package/docs/examples/storage/update-file.md +1 -1
- package/docs/examples/teams/create-membership.md +1 -1
- package/docs/examples/teams/create.md +1 -1
- package/docs/examples/teams/delete-membership.md +1 -1
- package/docs/examples/teams/delete.md +1 -1
- package/docs/examples/teams/get-membership.md +1 -1
- package/docs/examples/teams/get-prefs.md +1 -1
- package/docs/examples/teams/get.md +1 -1
- package/docs/examples/teams/list-logs.md +1 -1
- package/docs/examples/teams/list-memberships.md +1 -1
- package/docs/examples/teams/list.md +1 -1
- package/docs/examples/teams/update-membership-status.md +1 -1
- package/docs/examples/teams/update-membership.md +1 -1
- package/docs/examples/teams/update-name.md +1 -1
- package/docs/examples/teams/update-prefs.md +1 -1
- package/docs/examples/users/create-argon2user.md +1 -1
- package/docs/examples/users/create-bcrypt-user.md +1 -1
- package/docs/examples/users/create-m-d5user.md +1 -1
- package/docs/examples/users/create-p-h-pass-user.md +1 -1
- package/docs/examples/users/create-s-h-a-user.md +1 -1
- package/docs/examples/users/create-scrypt-modified-user.md +1 -1
- package/docs/examples/users/create-scrypt-user.md +1 -1
- package/docs/examples/users/create-session.md +18 -0
- package/docs/examples/users/create-target.md +2 -2
- package/docs/examples/users/create-token.md +18 -0
- package/docs/examples/users/create.md +1 -1
- package/docs/examples/users/delete-authenticator.md +18 -0
- package/docs/examples/users/delete-identity.md +1 -1
- package/docs/examples/users/delete-session.md +1 -1
- package/docs/examples/users/delete-sessions.md +1 -1
- package/docs/examples/users/delete-target.md +1 -1
- package/docs/examples/users/delete.md +1 -1
- package/docs/examples/users/get-prefs.md +1 -1
- package/docs/examples/users/get-target.md +1 -1
- package/docs/examples/users/get-usage.md +1 -1
- package/docs/examples/users/get.md +1 -1
- package/docs/examples/users/list-factors.md +18 -0
- package/docs/examples/users/list-identities.md +1 -1
- package/docs/examples/users/list-logs.md +1 -1
- package/docs/examples/users/list-memberships.md +1 -1
- package/docs/examples/users/list-sessions.md +1 -1
- package/docs/examples/users/list-targets.md +1 -1
- package/docs/examples/users/list.md +1 -1
- package/docs/examples/users/update-email-verification.md +1 -1
- package/docs/examples/users/update-email.md +1 -1
- package/docs/examples/users/update-labels.md +1 -1
- package/docs/examples/users/update-mfa.md +18 -0
- package/docs/examples/users/update-name.md +1 -1
- package/docs/examples/users/update-password.md +1 -1
- package/docs/examples/users/update-phone-verification.md +1 -1
- package/docs/examples/users/update-phone.md +1 -1
- package/docs/examples/users/update-prefs.md +1 -1
- package/docs/examples/users/update-status.md +1 -1
- package/docs/examples/users/update-target.md +1 -1
- package/docs/examples/vcs/create-repository-detection.md +1 -1
- package/docs/examples/vcs/create-repository.md +1 -1
- package/docs/examples/vcs/delete-installation.md +1 -1
- package/docs/examples/vcs/get-installation.md +1 -1
- package/docs/examples/vcs/get-repository.md +1 -1
- package/docs/examples/vcs/list-installations.md +1 -1
- package/docs/examples/vcs/list-repositories.md +1 -1
- package/docs/examples/vcs/list-repository-branches.md +1 -1
- package/docs/examples/vcs/update-external-deployments.md +1 -1
- package/package.json +1 -1
- package/src/client.ts +3 -3
- package/src/enums/a-p-i-service.ts +13 -0
- package/src/enums/auth-method.ts +9 -0
- package/src/enums/authentication-factor.ts +5 -0
- package/src/enums/authenticator-type.ts +3 -0
- package/src/enums/browser.ts +16 -0
- package/src/enums/compression.ts +5 -0
- package/src/enums/credit-card.ts +18 -0
- package/src/enums/database-usage-range.ts +5 -0
- package/src/enums/email-template-locale.ts +133 -0
- package/src/enums/email-template-type.ts +6 -0
- package/src/enums/execution-method.ts +8 -0
- package/src/enums/flag.ts +196 -0
- package/src/enums/function-usage-range.ts +5 -0
- package/src/enums/image-format.ts +7 -0
- package/src/enums/image-gravity.ts +11 -0
- package/src/enums/index-type.ts +6 -0
- package/src/enums/message-status.ts +5 -0
- package/src/enums/messaging-provider-type.ts +5 -0
- package/src/enums/name.ts +14 -0
- package/src/enums/o-auth-provider.ts +41 -0
- package/src/enums/password-hash.ts +13 -0
- package/src/enums/platform-type.ts +15 -0
- package/src/enums/project-usage-range.ts +4 -0
- package/src/enums/region.ts +3 -0
- package/src/enums/relation-mutate.ts +5 -0
- package/src/enums/relationship-type.ts +6 -0
- package/src/enums/resource-type.ts +4 -0
- package/src/enums/runtime.ts +6 -0
- package/src/enums/s-m-s-template-locale.ts +133 -0
- package/src/enums/s-m-s-template-type.ts +5 -0
- package/src/enums/s-m-t-p-encryption.ts +5 -0
- package/src/enums/s-m-t-p-secure.ts +3 -0
- package/src/enums/storage-usage-range.ts +5 -0
- package/src/enums/user-usage-range.ts +5 -0
- package/src/index.ts +35 -1
- package/src/models.ts +278 -199
- package/src/query.ts +61 -34
- package/src/service.ts +7 -7
- package/src/services/account.ts +349 -164
- package/src/services/assistant.ts +1 -0
- package/src/services/avatars.ts +10 -6
- package/src/services/console.ts +1 -0
- package/src/services/databases.ts +18 -13
- package/src/services/functions.ts +14 -10
- package/src/services/graphql.ts +1 -0
- package/src/services/health.ts +54 -0
- package/src/services/locale.ts +1 -0
- package/src/services/messaging.ts +395 -120
- package/src/services/migrations.ts +3 -2
- package/src/services/project.ts +24 -4
- package/src/services/projects.ts +137 -91
- package/src/services/proxy.ts +4 -2
- package/src/services/storage.ts +17 -12
- package/src/services/teams.ts +1 -0
- package/src/services/users.ts +170 -16
- package/src/services/vcs.ts +1 -0
- package/types/enums/a-p-i-service.d.ts +13 -0
- package/types/enums/auth-method.d.ts +9 -0
- package/types/enums/authentication-factor.d.ts +5 -0
- package/types/enums/authenticator-type.d.ts +3 -0
- package/types/enums/browser.d.ts +16 -0
- package/types/enums/compression.d.ts +5 -0
- package/types/enums/credit-card.d.ts +18 -0
- package/types/enums/database-usage-range.d.ts +5 -0
- package/types/enums/email-template-locale.d.ts +133 -0
- package/types/enums/email-template-type.d.ts +6 -0
- package/types/enums/execution-method.d.ts +8 -0
- package/types/enums/flag.d.ts +196 -0
- package/types/enums/function-usage-range.d.ts +5 -0
- package/types/enums/image-format.d.ts +7 -0
- package/types/enums/image-gravity.d.ts +11 -0
- package/types/enums/index-type.d.ts +6 -0
- package/types/enums/message-status.d.ts +5 -0
- package/types/enums/messaging-provider-type.d.ts +5 -0
- package/types/enums/name.d.ts +14 -0
- package/types/enums/o-auth-provider.d.ts +41 -0
- package/types/enums/password-hash.d.ts +13 -0
- package/types/enums/platform-type.d.ts +15 -0
- package/types/enums/project-usage-range.d.ts +4 -0
- package/types/enums/region.d.ts +3 -0
- package/types/enums/relation-mutate.d.ts +5 -0
- package/types/enums/relationship-type.d.ts +6 -0
- package/types/enums/resource-type.d.ts +4 -0
- package/types/enums/runtime.d.ts +6 -0
- package/types/enums/s-m-s-template-locale.d.ts +133 -0
- package/types/enums/s-m-s-template-type.d.ts +5 -0
- package/types/enums/s-m-t-p-encryption.d.ts +5 -0
- package/types/enums/s-m-t-p-secure.d.ts +3 -0
- package/types/enums/storage-usage-range.d.ts +5 -0
- package/types/enums/user-usage-range.d.ts +5 -0
- package/types/index.d.ts +34 -0
- package/types/models.d.ts +278 -199
- package/types/query.d.ts +10 -3
- package/types/services/account.d.ts +151 -89
- package/types/services/avatars.d.ts +9 -6
- package/types/services/databases.d.ts +17 -13
- package/types/services/functions.d.ts +13 -10
- package/types/services/health.d.ts +23 -0
- package/types/services/messaging.d.ts +129 -55
- package/types/services/migrations.d.ts +2 -2
- package/types/services/project.d.ts +5 -2
- package/types/services/projects.d.ts +63 -53
- package/types/services/proxy.d.ts +3 -2
- package/types/services/storage.d.ts +16 -12
- package/types/services/users.d.ts +76 -12
- package/docs/examples/messaging/create-email-message.md +0 -18
- package/docs/examples/projects/update-smtp-configuration.md +0 -18
package/dist/cjs/sdk.js
CHANGED
|
@@ -28,17 +28,63 @@ function __awaiter(thisArg, _arguments, P, generator) {
|
|
|
28
28
|
});
|
|
29
29
|
}
|
|
30
30
|
|
|
31
|
+
class Query {
|
|
32
|
+
constructor(method, attribute, values) {
|
|
33
|
+
this.method = method;
|
|
34
|
+
this.attribute = attribute;
|
|
35
|
+
if (values !== undefined) {
|
|
36
|
+
if (Array.isArray(values)) {
|
|
37
|
+
this.values = values;
|
|
38
|
+
}
|
|
39
|
+
else {
|
|
40
|
+
this.values = [values];
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
toString() {
|
|
45
|
+
return JSON.stringify({
|
|
46
|
+
method: this.method,
|
|
47
|
+
attribute: this.attribute,
|
|
48
|
+
values: this.values,
|
|
49
|
+
});
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
Query.equal = (attribute, value) => new Query("equal", attribute, value).toString();
|
|
53
|
+
Query.notEqual = (attribute, value) => new Query("notEqual", attribute, value).toString();
|
|
54
|
+
Query.lessThan = (attribute, value) => new Query("lessThan", attribute, value).toString();
|
|
55
|
+
Query.lessThanEqual = (attribute, value) => new Query("lessThanEqual", attribute, value).toString();
|
|
56
|
+
Query.greaterThan = (attribute, value) => new Query("greaterThan", attribute, value).toString();
|
|
57
|
+
Query.greaterThanEqual = (attribute, value) => new Query("greaterThanEqual", attribute, value).toString();
|
|
58
|
+
Query.isNull = (attribute) => new Query("isNull", attribute).toString();
|
|
59
|
+
Query.isNotNull = (attribute) => new Query("isNotNull", attribute).toString();
|
|
60
|
+
Query.between = (attribute, start, end) => new Query("between", attribute, [start, end]).toString();
|
|
61
|
+
Query.startsWith = (attribute, value) => new Query("startsWith", attribute, value).toString();
|
|
62
|
+
Query.endsWith = (attribute, value) => new Query("endsWith", attribute, value).toString();
|
|
63
|
+
Query.select = (attributes) => new Query("select", undefined, attributes).toString();
|
|
64
|
+
Query.search = (attribute, value) => new Query("search", attribute, value).toString();
|
|
65
|
+
Query.orderDesc = (attribute) => new Query("orderDesc", attribute).toString();
|
|
66
|
+
Query.orderAsc = (attribute) => new Query("orderAsc", attribute).toString();
|
|
67
|
+
Query.cursorAfter = (documentId) => new Query("cursorAfter", undefined, documentId).toString();
|
|
68
|
+
Query.cursorBefore = (documentId) => new Query("cursorBefore", undefined, documentId).toString();
|
|
69
|
+
Query.limit = (limit) => new Query("limit", undefined, limit).toString();
|
|
70
|
+
Query.offset = (offset) => new Query("offset", undefined, offset).toString();
|
|
71
|
+
Query.contains = (attribute, value) => new Query("contains", attribute, value).toString();
|
|
72
|
+
Query.or = (queries) => new Query("or", undefined, queries.map((query) => JSON.parse(query))).toString();
|
|
73
|
+
Query.and = (queries) => new Query("and", undefined, queries.map((query) => JSON.parse(query))).toString();
|
|
74
|
+
|
|
31
75
|
class Service {
|
|
32
76
|
constructor(client) {
|
|
33
77
|
this.client = client;
|
|
34
78
|
}
|
|
35
79
|
static flatten(data, prefix = '') {
|
|
36
80
|
let output = {};
|
|
37
|
-
for (const key
|
|
38
|
-
let
|
|
39
|
-
let finalKey = prefix ? `${prefix}[${key}]` : key;
|
|
81
|
+
for (const [key, value] of Object.entries(data)) {
|
|
82
|
+
let finalKey = prefix ? prefix + '[' + key + ']' : key;
|
|
40
83
|
if (Array.isArray(value)) {
|
|
41
|
-
output = Object.assign(output,
|
|
84
|
+
output = Object.assign(Object.assign({}, output), Service.flatten(value, finalKey));
|
|
85
|
+
}
|
|
86
|
+
else if (value instanceof Query) {
|
|
87
|
+
output[finalKey] = JSON.stringify(value);
|
|
42
88
|
}
|
|
43
89
|
else {
|
|
44
90
|
output[finalKey] = value;
|
|
@@ -49,36 +95,6 @@ class Service {
|
|
|
49
95
|
}
|
|
50
96
|
Service.CHUNK_SIZE = 5 * 1024 * 1024; // 5MB
|
|
51
97
|
|
|
52
|
-
class Query {
|
|
53
|
-
}
|
|
54
|
-
Query.equal = (attribute, value) => Query.addQuery(attribute, "equal", value);
|
|
55
|
-
Query.notEqual = (attribute, value) => Query.addQuery(attribute, "notEqual", value);
|
|
56
|
-
Query.lessThan = (attribute, value) => Query.addQuery(attribute, "lessThan", value);
|
|
57
|
-
Query.lessThanEqual = (attribute, value) => Query.addQuery(attribute, "lessThanEqual", value);
|
|
58
|
-
Query.greaterThan = (attribute, value) => Query.addQuery(attribute, "greaterThan", value);
|
|
59
|
-
Query.greaterThanEqual = (attribute, value) => Query.addQuery(attribute, "greaterThanEqual", value);
|
|
60
|
-
Query.isNull = (attribute) => `isNull("${attribute}")`;
|
|
61
|
-
Query.isNotNull = (attribute) => `isNotNull("${attribute}")`;
|
|
62
|
-
Query.between = (attribute, start, end) => `between("${attribute}", ${Query.parseValues(start)}, ${Query.parseValues(end)})`;
|
|
63
|
-
Query.startsWith = (attribute, value) => Query.addQuery(attribute, "startsWith", value);
|
|
64
|
-
Query.endsWith = (attribute, value) => Query.addQuery(attribute, "endsWith", value);
|
|
65
|
-
Query.select = (attributes) => `select([${attributes.map((attr) => `"${attr}"`).join(",")}])`;
|
|
66
|
-
Query.search = (attribute, value) => Query.addQuery(attribute, "search", value);
|
|
67
|
-
Query.orderDesc = (attribute) => `orderDesc("${attribute}")`;
|
|
68
|
-
Query.orderAsc = (attribute) => `orderAsc("${attribute}")`;
|
|
69
|
-
Query.cursorAfter = (documentId) => `cursorAfter("${documentId}")`;
|
|
70
|
-
Query.cursorBefore = (documentId) => `cursorBefore("${documentId}")`;
|
|
71
|
-
Query.limit = (limit) => `limit(${limit})`;
|
|
72
|
-
Query.offset = (offset) => `offset(${offset})`;
|
|
73
|
-
Query.addQuery = (attribute, method, value) => value instanceof Array
|
|
74
|
-
? `${method}("${attribute}", [${value
|
|
75
|
-
.map((v) => Query.parseValues(v))
|
|
76
|
-
.join(",")}])`
|
|
77
|
-
: `${method}("${attribute}", [${Query.parseValues(value)}])`;
|
|
78
|
-
Query.parseValues = (value) => typeof value === "string" || value instanceof String
|
|
79
|
-
? `"${value}"`
|
|
80
|
-
: `${value}`;
|
|
81
|
-
|
|
82
98
|
class AppwriteException extends Error {
|
|
83
99
|
constructor(message, code = 0, type = '', response = '') {
|
|
84
100
|
super(message);
|
|
@@ -92,7 +108,7 @@ class AppwriteException extends Error {
|
|
|
92
108
|
class Client {
|
|
93
109
|
constructor() {
|
|
94
110
|
this.config = {
|
|
95
|
-
endpoint: 'https://
|
|
111
|
+
endpoint: 'https://cloud.appwrite.io/v1',
|
|
96
112
|
endpointRealtime: '',
|
|
97
113
|
project: '',
|
|
98
114
|
key: '',
|
|
@@ -104,8 +120,8 @@ class Client {
|
|
|
104
120
|
'x-sdk-name': 'Console',
|
|
105
121
|
'x-sdk-platform': 'console',
|
|
106
122
|
'x-sdk-language': 'web',
|
|
107
|
-
'x-sdk-version': '0.6.0-rc.
|
|
108
|
-
'X-Appwrite-Response-Format': '1.
|
|
123
|
+
'x-sdk-version': '0.6.0-rc.11',
|
|
124
|
+
'X-Appwrite-Response-Format': '1.5.0',
|
|
109
125
|
};
|
|
110
126
|
this.realtime = {
|
|
111
127
|
socket: undefined,
|
|
@@ -508,6 +524,24 @@ class Account extends Service {
|
|
|
508
524
|
}, payload);
|
|
509
525
|
});
|
|
510
526
|
}
|
|
527
|
+
/**
|
|
528
|
+
* Delete account
|
|
529
|
+
*
|
|
530
|
+
* Delete the currently logged in user.
|
|
531
|
+
*
|
|
532
|
+
* @throws {AppwriteException}
|
|
533
|
+
* @returns {Promise}
|
|
534
|
+
*/
|
|
535
|
+
delete() {
|
|
536
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
537
|
+
const apiPath = '/account';
|
|
538
|
+
const payload = {};
|
|
539
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
540
|
+
return yield this.client.call('delete', uri, {
|
|
541
|
+
'content-type': 'application/json',
|
|
542
|
+
}, payload);
|
|
543
|
+
});
|
|
544
|
+
}
|
|
511
545
|
/**
|
|
512
546
|
* Update email
|
|
513
547
|
*
|
|
@@ -552,7 +586,7 @@ class Account extends Service {
|
|
|
552
586
|
*
|
|
553
587
|
* Get the list of identities for the currently logged in user.
|
|
554
588
|
*
|
|
555
|
-
* @param {string} queries
|
|
589
|
+
* @param {string[]} queries
|
|
556
590
|
* @throws {AppwriteException}
|
|
557
591
|
* @returns {Promise}
|
|
558
592
|
*/
|
|
@@ -570,7 +604,7 @@ class Account extends Service {
|
|
|
570
604
|
});
|
|
571
605
|
}
|
|
572
606
|
/**
|
|
573
|
-
* Delete
|
|
607
|
+
* Delete identity
|
|
574
608
|
*
|
|
575
609
|
* Delete an identity by its unique ID.
|
|
576
610
|
*
|
|
@@ -661,22 +695,22 @@ class Account extends Service {
|
|
|
661
695
|
});
|
|
662
696
|
}
|
|
663
697
|
/**
|
|
664
|
-
* Create
|
|
698
|
+
* Create 2FA Challenge
|
|
665
699
|
*
|
|
666
700
|
*
|
|
667
|
-
* @param {
|
|
701
|
+
* @param {AuthenticationFactor} factor
|
|
668
702
|
* @throws {AppwriteException}
|
|
669
703
|
* @returns {Promise}
|
|
670
704
|
*/
|
|
671
|
-
|
|
705
|
+
create2FAChallenge(factor) {
|
|
672
706
|
return __awaiter(this, void 0, void 0, function* () {
|
|
673
|
-
if (typeof
|
|
674
|
-
throw new AppwriteException('Missing required parameter: "
|
|
707
|
+
if (typeof factor === 'undefined') {
|
|
708
|
+
throw new AppwriteException('Missing required parameter: "factor"');
|
|
675
709
|
}
|
|
676
710
|
const apiPath = '/account/mfa/challenge';
|
|
677
711
|
const payload = {};
|
|
678
|
-
if (typeof
|
|
679
|
-
payload['
|
|
712
|
+
if (typeof factor !== 'undefined') {
|
|
713
|
+
payload['factor'] = factor;
|
|
680
714
|
}
|
|
681
715
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
682
716
|
return yield this.client.call('post', uri, {
|
|
@@ -716,16 +750,15 @@ class Account extends Service {
|
|
|
716
750
|
});
|
|
717
751
|
}
|
|
718
752
|
/**
|
|
719
|
-
* List
|
|
753
|
+
* List Factors
|
|
720
754
|
*
|
|
721
|
-
* Get the currently logged in user.
|
|
722
755
|
*
|
|
723
756
|
* @throws {AppwriteException}
|
|
724
757
|
* @returns {Promise}
|
|
725
758
|
*/
|
|
726
|
-
|
|
759
|
+
listFactors() {
|
|
727
760
|
return __awaiter(this, void 0, void 0, function* () {
|
|
728
|
-
const apiPath = '/account/mfa/
|
|
761
|
+
const apiPath = '/account/mfa/factors';
|
|
729
762
|
const payload = {};
|
|
730
763
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
731
764
|
return yield this.client.call('get', uri, {
|
|
@@ -737,16 +770,16 @@ class Account extends Service {
|
|
|
737
770
|
* Add Authenticator
|
|
738
771
|
*
|
|
739
772
|
*
|
|
740
|
-
* @param {
|
|
773
|
+
* @param {AuthenticatorType} type
|
|
741
774
|
* @throws {AppwriteException}
|
|
742
775
|
* @returns {Promise}
|
|
743
776
|
*/
|
|
744
|
-
addAuthenticator(
|
|
777
|
+
addAuthenticator(type) {
|
|
745
778
|
return __awaiter(this, void 0, void 0, function* () {
|
|
746
|
-
if (typeof
|
|
747
|
-
throw new AppwriteException('Missing required parameter: "
|
|
779
|
+
if (typeof type === 'undefined') {
|
|
780
|
+
throw new AppwriteException('Missing required parameter: "type"');
|
|
748
781
|
}
|
|
749
|
-
const apiPath = '/account/mfa/{
|
|
782
|
+
const apiPath = '/account/mfa/{type}'.replace('{type}', type);
|
|
750
783
|
const payload = {};
|
|
751
784
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
752
785
|
return yield this.client.call('post', uri, {
|
|
@@ -758,20 +791,20 @@ class Account extends Service {
|
|
|
758
791
|
* Verify Authenticator
|
|
759
792
|
*
|
|
760
793
|
*
|
|
761
|
-
* @param {
|
|
794
|
+
* @param {AuthenticatorType} type
|
|
762
795
|
* @param {string} otp
|
|
763
796
|
* @throws {AppwriteException}
|
|
764
797
|
* @returns {Promise}
|
|
765
798
|
*/
|
|
766
|
-
verifyAuthenticator(
|
|
799
|
+
verifyAuthenticator(type, otp) {
|
|
767
800
|
return __awaiter(this, void 0, void 0, function* () {
|
|
768
|
-
if (typeof
|
|
769
|
-
throw new AppwriteException('Missing required parameter: "
|
|
801
|
+
if (typeof type === 'undefined') {
|
|
802
|
+
throw new AppwriteException('Missing required parameter: "type"');
|
|
770
803
|
}
|
|
771
804
|
if (typeof otp === 'undefined') {
|
|
772
805
|
throw new AppwriteException('Missing required parameter: "otp"');
|
|
773
806
|
}
|
|
774
|
-
const apiPath = '/account/mfa/{
|
|
807
|
+
const apiPath = '/account/mfa/{type}'.replace('{type}', type);
|
|
775
808
|
const payload = {};
|
|
776
809
|
if (typeof otp !== 'undefined') {
|
|
777
810
|
payload['otp'] = otp;
|
|
@@ -782,6 +815,34 @@ class Account extends Service {
|
|
|
782
815
|
}, payload);
|
|
783
816
|
});
|
|
784
817
|
}
|
|
818
|
+
/**
|
|
819
|
+
* Delete Authenticator
|
|
820
|
+
*
|
|
821
|
+
*
|
|
822
|
+
* @param {AuthenticatorType} type
|
|
823
|
+
* @param {string} otp
|
|
824
|
+
* @throws {AppwriteException}
|
|
825
|
+
* @returns {Promise}
|
|
826
|
+
*/
|
|
827
|
+
deleteAuthenticator(type, otp) {
|
|
828
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
829
|
+
if (typeof type === 'undefined') {
|
|
830
|
+
throw new AppwriteException('Missing required parameter: "type"');
|
|
831
|
+
}
|
|
832
|
+
if (typeof otp === 'undefined') {
|
|
833
|
+
throw new AppwriteException('Missing required parameter: "otp"');
|
|
834
|
+
}
|
|
835
|
+
const apiPath = '/account/mfa/{type}'.replace('{type}', type);
|
|
836
|
+
const payload = {};
|
|
837
|
+
if (typeof otp !== 'undefined') {
|
|
838
|
+
payload['otp'] = otp;
|
|
839
|
+
}
|
|
840
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
841
|
+
return yield this.client.call('delete', uri, {
|
|
842
|
+
'content-type': 'application/json',
|
|
843
|
+
}, payload);
|
|
844
|
+
});
|
|
845
|
+
}
|
|
785
846
|
/**
|
|
786
847
|
* Update name
|
|
787
848
|
*
|
|
@@ -975,11 +1036,10 @@ class Account extends Service {
|
|
|
975
1036
|
* @param {string} userId
|
|
976
1037
|
* @param {string} secret
|
|
977
1038
|
* @param {string} password
|
|
978
|
-
* @param {string} passwordAgain
|
|
979
1039
|
* @throws {AppwriteException}
|
|
980
1040
|
* @returns {Promise}
|
|
981
1041
|
*/
|
|
982
|
-
updateRecovery(userId, secret, password
|
|
1042
|
+
updateRecovery(userId, secret, password) {
|
|
983
1043
|
return __awaiter(this, void 0, void 0, function* () {
|
|
984
1044
|
if (typeof userId === 'undefined') {
|
|
985
1045
|
throw new AppwriteException('Missing required parameter: "userId"');
|
|
@@ -990,9 +1050,6 @@ class Account extends Service {
|
|
|
990
1050
|
if (typeof password === 'undefined') {
|
|
991
1051
|
throw new AppwriteException('Missing required parameter: "password"');
|
|
992
1052
|
}
|
|
993
|
-
if (typeof passwordAgain === 'undefined') {
|
|
994
|
-
throw new AppwriteException('Missing required parameter: "passwordAgain"');
|
|
995
|
-
}
|
|
996
1053
|
const apiPath = '/account/recovery';
|
|
997
1054
|
const payload = {};
|
|
998
1055
|
if (typeof userId !== 'undefined') {
|
|
@@ -1004,9 +1061,6 @@ class Account extends Service {
|
|
|
1004
1061
|
if (typeof password !== 'undefined') {
|
|
1005
1062
|
payload['password'] = password;
|
|
1006
1063
|
}
|
|
1007
|
-
if (typeof passwordAgain !== 'undefined') {
|
|
1008
|
-
payload['passwordAgain'] = passwordAgain;
|
|
1009
|
-
}
|
|
1010
1064
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
1011
1065
|
return yield this.client.call('put', uri, {
|
|
1012
1066
|
'content-type': 'application/json',
|
|
@@ -1076,7 +1130,7 @@ class Account extends Service {
|
|
|
1076
1130
|
});
|
|
1077
1131
|
}
|
|
1078
1132
|
/**
|
|
1079
|
-
* Create email session
|
|
1133
|
+
* Create email password session
|
|
1080
1134
|
*
|
|
1081
1135
|
* Allow the user to login into their account by providing a valid email and
|
|
1082
1136
|
* password combination. This route will create a new session for the user.
|
|
@@ -1090,7 +1144,7 @@ class Account extends Service {
|
|
|
1090
1144
|
* @throws {AppwriteException}
|
|
1091
1145
|
* @returns {Promise}
|
|
1092
1146
|
*/
|
|
1093
|
-
|
|
1147
|
+
createEmailPasswordSession(email, password) {
|
|
1094
1148
|
return __awaiter(this, void 0, void 0, function* () {
|
|
1095
1149
|
if (typeof email === 'undefined') {
|
|
1096
1150
|
throw new AppwriteException('Missing required parameter: "email"');
|
|
@@ -1113,70 +1167,11 @@ class Account extends Service {
|
|
|
1113
1167
|
});
|
|
1114
1168
|
}
|
|
1115
1169
|
/**
|
|
1116
|
-
* Create
|
|
1117
|
-
*
|
|
1118
|
-
* Sends the user an email with a secret key for creating a session. If the
|
|
1119
|
-
* provided user ID has not been registered, a new user will be created. When
|
|
1120
|
-
* the user clicks the link in the email, the user is redirected back to the
|
|
1121
|
-
* URL you provided with the secret key and userId values attached to the URL
|
|
1122
|
-
* query string. Use the query string parameters to submit a request to the
|
|
1123
|
-
* [PUT
|
|
1124
|
-
* /account/sessions/magic-url](https://appwrite.io/docs/references/cloud/client-web/account#updateMagicURLSession)
|
|
1125
|
-
* endpoint to complete the login process. The link sent to the user's email
|
|
1126
|
-
* address is valid for 1 hour. If you are on a mobile device you can leave
|
|
1127
|
-
* the URL parameter empty, so that the login completion will be handled by
|
|
1128
|
-
* your Appwrite instance by default.
|
|
1129
|
-
*
|
|
1130
|
-
* A user is limited to 10 active sessions at a time by default. [Learn more
|
|
1131
|
-
* about session
|
|
1132
|
-
* limits](https://appwrite.io/docs/authentication-security#limits).
|
|
1170
|
+
* Create session (deprecated)
|
|
1133
1171
|
*
|
|
1134
|
-
*
|
|
1135
|
-
*
|
|
1136
|
-
*
|
|
1137
|
-
* @param {string} url
|
|
1138
|
-
* @throws {AppwriteException}
|
|
1139
|
-
* @returns {Promise}
|
|
1140
|
-
*/
|
|
1141
|
-
createMagicURLSession(userId, email, url) {
|
|
1142
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
1143
|
-
if (typeof userId === 'undefined') {
|
|
1144
|
-
throw new AppwriteException('Missing required parameter: "userId"');
|
|
1145
|
-
}
|
|
1146
|
-
if (typeof email === 'undefined') {
|
|
1147
|
-
throw new AppwriteException('Missing required parameter: "email"');
|
|
1148
|
-
}
|
|
1149
|
-
const apiPath = '/account/sessions/magic-url';
|
|
1150
|
-
const payload = {};
|
|
1151
|
-
if (typeof userId !== 'undefined') {
|
|
1152
|
-
payload['userId'] = userId;
|
|
1153
|
-
}
|
|
1154
|
-
if (typeof email !== 'undefined') {
|
|
1155
|
-
payload['email'] = email;
|
|
1156
|
-
}
|
|
1157
|
-
if (typeof url !== 'undefined') {
|
|
1158
|
-
payload['url'] = url;
|
|
1159
|
-
}
|
|
1160
|
-
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
1161
|
-
return yield this.client.call('post', uri, {
|
|
1162
|
-
'content-type': 'application/json',
|
|
1163
|
-
}, payload);
|
|
1164
|
-
});
|
|
1165
|
-
}
|
|
1166
|
-
/**
|
|
1167
|
-
* Create magic URL session (confirmation)
|
|
1168
|
-
*
|
|
1169
|
-
* Use this endpoint to complete creating the session with the Magic URL. Both
|
|
1170
|
-
* the **userId** and **secret** arguments will be passed as query parameters
|
|
1171
|
-
* to the redirect URL you have provided when sending your request to the
|
|
1172
|
-
* [POST
|
|
1173
|
-
* /account/sessions/magic-url](https://appwrite.io/docs/references/cloud/client-web/account#createMagicURLSession)
|
|
1174
|
-
* endpoint.
|
|
1175
|
-
*
|
|
1176
|
-
* Please note that in order to avoid a [Redirect
|
|
1177
|
-
* Attack](https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.md)
|
|
1178
|
-
* the only valid redirect URLs are the ones from domains you have set when
|
|
1179
|
-
* adding your platforms in the console interface.
|
|
1172
|
+
* Use this endpoint to create a session from token. Provide the **userId**
|
|
1173
|
+
* and **secret** parameters from the successful response of authentication
|
|
1174
|
+
* flows initiated by token creation. For example, magic URL and phone login.
|
|
1180
1175
|
*
|
|
1181
1176
|
* @param {string} userId
|
|
1182
1177
|
* @param {string} secret
|
|
@@ -1225,14 +1220,15 @@ class Account extends Service {
|
|
|
1225
1220
|
* limits](https://appwrite.io/docs/authentication-security#limits).
|
|
1226
1221
|
*
|
|
1227
1222
|
*
|
|
1228
|
-
* @param {
|
|
1223
|
+
* @param {OAuthProvider} provider
|
|
1229
1224
|
* @param {string} success
|
|
1230
1225
|
* @param {string} failure
|
|
1226
|
+
* @param {boolean} token
|
|
1231
1227
|
* @param {string[]} scopes
|
|
1232
1228
|
* @throws {AppwriteException}
|
|
1233
1229
|
* @returns {void|string}
|
|
1234
1230
|
*/
|
|
1235
|
-
createOAuth2Session(provider, success, failure, scopes) {
|
|
1231
|
+
createOAuth2Session(provider, success, failure, token, scopes) {
|
|
1236
1232
|
if (typeof provider === 'undefined') {
|
|
1237
1233
|
throw new AppwriteException('Missing required parameter: "provider"');
|
|
1238
1234
|
}
|
|
@@ -1244,6 +1240,9 @@ class Account extends Service {
|
|
|
1244
1240
|
if (typeof failure !== 'undefined') {
|
|
1245
1241
|
payload['failure'] = failure;
|
|
1246
1242
|
}
|
|
1243
|
+
if (typeof token !== 'undefined') {
|
|
1244
|
+
payload['token'] = token;
|
|
1245
|
+
}
|
|
1247
1246
|
if (typeof scopes !== 'undefined') {
|
|
1248
1247
|
payload['scopes'] = scopes;
|
|
1249
1248
|
}
|
|
@@ -1260,61 +1259,18 @@ class Account extends Service {
|
|
|
1260
1259
|
}
|
|
1261
1260
|
}
|
|
1262
1261
|
/**
|
|
1263
|
-
* Create
|
|
1264
|
-
*
|
|
1265
|
-
* Sends the user an SMS with a secret key for creating a session. If the
|
|
1266
|
-
* provided user ID has not be registered, a new user will be created. Use the
|
|
1267
|
-
* returned user ID and secret and submit a request to the [PUT
|
|
1268
|
-
* /account/sessions/phone](https://appwrite.io/docs/references/cloud/client-web/account#updatePhoneSession)
|
|
1269
|
-
* endpoint to complete the login process. The secret sent to the user's phone
|
|
1270
|
-
* is valid for 15 minutes.
|
|
1271
|
-
*
|
|
1272
|
-
* A user is limited to 10 active sessions at a time by default. [Learn more
|
|
1273
|
-
* about session
|
|
1274
|
-
* limits](https://appwrite.io/docs/authentication-security#limits).
|
|
1275
|
-
*
|
|
1276
|
-
* @param {string} userId
|
|
1277
|
-
* @param {string} phone
|
|
1278
|
-
* @throws {AppwriteException}
|
|
1279
|
-
* @returns {Promise}
|
|
1280
|
-
*/
|
|
1281
|
-
createPhoneSession(userId, phone) {
|
|
1282
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
1283
|
-
if (typeof userId === 'undefined') {
|
|
1284
|
-
throw new AppwriteException('Missing required parameter: "userId"');
|
|
1285
|
-
}
|
|
1286
|
-
if (typeof phone === 'undefined') {
|
|
1287
|
-
throw new AppwriteException('Missing required parameter: "phone"');
|
|
1288
|
-
}
|
|
1289
|
-
const apiPath = '/account/sessions/phone';
|
|
1290
|
-
const payload = {};
|
|
1291
|
-
if (typeof userId !== 'undefined') {
|
|
1292
|
-
payload['userId'] = userId;
|
|
1293
|
-
}
|
|
1294
|
-
if (typeof phone !== 'undefined') {
|
|
1295
|
-
payload['phone'] = phone;
|
|
1296
|
-
}
|
|
1297
|
-
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
1298
|
-
return yield this.client.call('post', uri, {
|
|
1299
|
-
'content-type': 'application/json',
|
|
1300
|
-
}, payload);
|
|
1301
|
-
});
|
|
1302
|
-
}
|
|
1303
|
-
/**
|
|
1304
|
-
* Create phone session (confirmation)
|
|
1262
|
+
* Create session
|
|
1305
1263
|
*
|
|
1306
|
-
* Use this endpoint to
|
|
1307
|
-
* **
|
|
1308
|
-
*
|
|
1309
|
-
* endpoint and the **secret** received via SMS to successfully update and
|
|
1310
|
-
* confirm the phone session.
|
|
1264
|
+
* Use this endpoint to create a session from token. Provide the **userId**
|
|
1265
|
+
* and **secret** parameters from the successful response of authentication
|
|
1266
|
+
* flows initiated by token creation. For example, magic URL and phone login.
|
|
1311
1267
|
*
|
|
1312
1268
|
* @param {string} userId
|
|
1313
1269
|
* @param {string} secret
|
|
1314
1270
|
* @throws {AppwriteException}
|
|
1315
1271
|
* @returns {Promise}
|
|
1316
1272
|
*/
|
|
1317
|
-
|
|
1273
|
+
createSession(userId, secret) {
|
|
1318
1274
|
return __awaiter(this, void 0, void 0, function* () {
|
|
1319
1275
|
if (typeof userId === 'undefined') {
|
|
1320
1276
|
throw new AppwriteException('Missing required parameter: "userId"');
|
|
@@ -1322,7 +1278,7 @@ class Account extends Service {
|
|
|
1322
1278
|
if (typeof secret === 'undefined') {
|
|
1323
1279
|
throw new AppwriteException('Missing required parameter: "secret"');
|
|
1324
1280
|
}
|
|
1325
|
-
const apiPath = '/account/sessions/
|
|
1281
|
+
const apiPath = '/account/sessions/token';
|
|
1326
1282
|
const payload = {};
|
|
1327
1283
|
if (typeof userId !== 'undefined') {
|
|
1328
1284
|
payload['userId'] = userId;
|
|
@@ -1331,7 +1287,7 @@ class Account extends Service {
|
|
|
1331
1287
|
payload['secret'] = secret;
|
|
1332
1288
|
}
|
|
1333
1289
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
1334
|
-
return yield this.client.call('
|
|
1290
|
+
return yield this.client.call('post', uri, {
|
|
1335
1291
|
'content-type': 'application/json',
|
|
1336
1292
|
}, payload);
|
|
1337
1293
|
});
|
|
@@ -1360,11 +1316,10 @@ class Account extends Service {
|
|
|
1360
1316
|
});
|
|
1361
1317
|
}
|
|
1362
1318
|
/**
|
|
1363
|
-
* Update
|
|
1319
|
+
* Update (or renew) a session
|
|
1364
1320
|
*
|
|
1365
|
-
*
|
|
1366
|
-
*
|
|
1367
|
-
* "refresh" the access token.
|
|
1321
|
+
* Extend session's expiry to increase it's lifespan. Extending a session is
|
|
1322
|
+
* useful when session length is short such as 5 minutes.
|
|
1368
1323
|
*
|
|
1369
1324
|
* @param {string} sessionId
|
|
1370
1325
|
* @throws {AppwriteException}
|
|
@@ -1429,6 +1384,231 @@ class Account extends Service {
|
|
|
1429
1384
|
}, payload);
|
|
1430
1385
|
});
|
|
1431
1386
|
}
|
|
1387
|
+
/**
|
|
1388
|
+
* Create a push target
|
|
1389
|
+
*
|
|
1390
|
+
*
|
|
1391
|
+
* @param {string} targetId
|
|
1392
|
+
* @param {string} identifier
|
|
1393
|
+
* @param {string} providerId
|
|
1394
|
+
* @throws {AppwriteException}
|
|
1395
|
+
* @returns {Promise}
|
|
1396
|
+
*/
|
|
1397
|
+
createPushTarget(targetId, identifier, providerId) {
|
|
1398
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
1399
|
+
if (typeof targetId === 'undefined') {
|
|
1400
|
+
throw new AppwriteException('Missing required parameter: "targetId"');
|
|
1401
|
+
}
|
|
1402
|
+
if (typeof identifier === 'undefined') {
|
|
1403
|
+
throw new AppwriteException('Missing required parameter: "identifier"');
|
|
1404
|
+
}
|
|
1405
|
+
const apiPath = '/account/targets/push';
|
|
1406
|
+
const payload = {};
|
|
1407
|
+
if (typeof targetId !== 'undefined') {
|
|
1408
|
+
payload['targetId'] = targetId;
|
|
1409
|
+
}
|
|
1410
|
+
if (typeof identifier !== 'undefined') {
|
|
1411
|
+
payload['identifier'] = identifier;
|
|
1412
|
+
}
|
|
1413
|
+
if (typeof providerId !== 'undefined') {
|
|
1414
|
+
payload['providerId'] = providerId;
|
|
1415
|
+
}
|
|
1416
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
1417
|
+
return yield this.client.call('post', uri, {
|
|
1418
|
+
'content-type': 'application/json',
|
|
1419
|
+
}, payload);
|
|
1420
|
+
});
|
|
1421
|
+
}
|
|
1422
|
+
/**
|
|
1423
|
+
* Update a push target
|
|
1424
|
+
*
|
|
1425
|
+
*
|
|
1426
|
+
* @param {string} targetId
|
|
1427
|
+
* @param {string} identifier
|
|
1428
|
+
* @throws {AppwriteException}
|
|
1429
|
+
* @returns {Promise}
|
|
1430
|
+
*/
|
|
1431
|
+
updatePushTarget(targetId, identifier) {
|
|
1432
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
1433
|
+
if (typeof targetId === 'undefined') {
|
|
1434
|
+
throw new AppwriteException('Missing required parameter: "targetId"');
|
|
1435
|
+
}
|
|
1436
|
+
if (typeof identifier === 'undefined') {
|
|
1437
|
+
throw new AppwriteException('Missing required parameter: "identifier"');
|
|
1438
|
+
}
|
|
1439
|
+
const apiPath = '/account/targets/{targetId}/push'.replace('{targetId}', targetId);
|
|
1440
|
+
const payload = {};
|
|
1441
|
+
if (typeof identifier !== 'undefined') {
|
|
1442
|
+
payload['identifier'] = identifier;
|
|
1443
|
+
}
|
|
1444
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
1445
|
+
return yield this.client.call('put', uri, {
|
|
1446
|
+
'content-type': 'application/json',
|
|
1447
|
+
}, payload);
|
|
1448
|
+
});
|
|
1449
|
+
}
|
|
1450
|
+
/**
|
|
1451
|
+
* Delete a push target
|
|
1452
|
+
*
|
|
1453
|
+
*
|
|
1454
|
+
* @param {string} targetId
|
|
1455
|
+
* @throws {AppwriteException}
|
|
1456
|
+
* @returns {Promise}
|
|
1457
|
+
*/
|
|
1458
|
+
deletePushTarget(targetId) {
|
|
1459
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
1460
|
+
if (typeof targetId === 'undefined') {
|
|
1461
|
+
throw new AppwriteException('Missing required parameter: "targetId"');
|
|
1462
|
+
}
|
|
1463
|
+
const apiPath = '/account/targets/{targetId}/push'.replace('{targetId}', targetId);
|
|
1464
|
+
const payload = {};
|
|
1465
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
1466
|
+
return yield this.client.call('delete', uri, {
|
|
1467
|
+
'content-type': 'application/json',
|
|
1468
|
+
}, payload);
|
|
1469
|
+
});
|
|
1470
|
+
}
|
|
1471
|
+
/**
|
|
1472
|
+
* Create email token (OTP)
|
|
1473
|
+
*
|
|
1474
|
+
* Sends the user an email with a secret key for creating a session. If the
|
|
1475
|
+
* provided user ID has not be registered, a new user will be created. Use the
|
|
1476
|
+
* returned user ID and secret and submit a request to the [POST
|
|
1477
|
+
* /v1/account/sessions/token](https://appwrite.io/docs/references/cloud/client-web/account#createSession)
|
|
1478
|
+
* endpoint to complete the login process. The secret sent to the user's email
|
|
1479
|
+
* is valid for 15 minutes.
|
|
1480
|
+
*
|
|
1481
|
+
* A user is limited to 10 active sessions at a time by default. [Learn more
|
|
1482
|
+
* about session
|
|
1483
|
+
* limits](https://appwrite.io/docs/authentication-security#limits).
|
|
1484
|
+
*
|
|
1485
|
+
* @param {string} userId
|
|
1486
|
+
* @param {string} email
|
|
1487
|
+
* @param {boolean} phrase
|
|
1488
|
+
* @throws {AppwriteException}
|
|
1489
|
+
* @returns {Promise}
|
|
1490
|
+
*/
|
|
1491
|
+
createEmailToken(userId, email, phrase) {
|
|
1492
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
1493
|
+
if (typeof userId === 'undefined') {
|
|
1494
|
+
throw new AppwriteException('Missing required parameter: "userId"');
|
|
1495
|
+
}
|
|
1496
|
+
if (typeof email === 'undefined') {
|
|
1497
|
+
throw new AppwriteException('Missing required parameter: "email"');
|
|
1498
|
+
}
|
|
1499
|
+
const apiPath = '/account/tokens/email';
|
|
1500
|
+
const payload = {};
|
|
1501
|
+
if (typeof userId !== 'undefined') {
|
|
1502
|
+
payload['userId'] = userId;
|
|
1503
|
+
}
|
|
1504
|
+
if (typeof email !== 'undefined') {
|
|
1505
|
+
payload['email'] = email;
|
|
1506
|
+
}
|
|
1507
|
+
if (typeof phrase !== 'undefined') {
|
|
1508
|
+
payload['phrase'] = phrase;
|
|
1509
|
+
}
|
|
1510
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
1511
|
+
return yield this.client.call('post', uri, {
|
|
1512
|
+
'content-type': 'application/json',
|
|
1513
|
+
}, payload);
|
|
1514
|
+
});
|
|
1515
|
+
}
|
|
1516
|
+
/**
|
|
1517
|
+
* Create magic URL token
|
|
1518
|
+
*
|
|
1519
|
+
* Sends the user an email with a secret key for creating a session. If the
|
|
1520
|
+
* provided user ID has not been registered, a new user will be created. When
|
|
1521
|
+
* the user clicks the link in the email, the user is redirected back to the
|
|
1522
|
+
* URL you provided with the secret key and userId values attached to the URL
|
|
1523
|
+
* query string. Use the query string parameters to submit a request to the
|
|
1524
|
+
* [POST
|
|
1525
|
+
* /v1/account/sessions/token](https://appwrite.io/docs/references/cloud/client-web/account#createSession)
|
|
1526
|
+
* endpoint to complete the login process. The link sent to the user's email
|
|
1527
|
+
* address is valid for 1 hour. If you are on a mobile device you can leave
|
|
1528
|
+
* the URL parameter empty, so that the login completion will be handled by
|
|
1529
|
+
* your Appwrite instance by default.
|
|
1530
|
+
*
|
|
1531
|
+
* A user is limited to 10 active sessions at a time by default. [Learn more
|
|
1532
|
+
* about session
|
|
1533
|
+
* limits](https://appwrite.io/docs/authentication-security#limits).
|
|
1534
|
+
*
|
|
1535
|
+
*
|
|
1536
|
+
* @param {string} userId
|
|
1537
|
+
* @param {string} email
|
|
1538
|
+
* @param {string} url
|
|
1539
|
+
* @param {boolean} phrase
|
|
1540
|
+
* @throws {AppwriteException}
|
|
1541
|
+
* @returns {Promise}
|
|
1542
|
+
*/
|
|
1543
|
+
createMagicURLToken(userId, email, url, phrase) {
|
|
1544
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
1545
|
+
if (typeof userId === 'undefined') {
|
|
1546
|
+
throw new AppwriteException('Missing required parameter: "userId"');
|
|
1547
|
+
}
|
|
1548
|
+
if (typeof email === 'undefined') {
|
|
1549
|
+
throw new AppwriteException('Missing required parameter: "email"');
|
|
1550
|
+
}
|
|
1551
|
+
const apiPath = '/account/tokens/magic-url';
|
|
1552
|
+
const payload = {};
|
|
1553
|
+
if (typeof userId !== 'undefined') {
|
|
1554
|
+
payload['userId'] = userId;
|
|
1555
|
+
}
|
|
1556
|
+
if (typeof email !== 'undefined') {
|
|
1557
|
+
payload['email'] = email;
|
|
1558
|
+
}
|
|
1559
|
+
if (typeof url !== 'undefined') {
|
|
1560
|
+
payload['url'] = url;
|
|
1561
|
+
}
|
|
1562
|
+
if (typeof phrase !== 'undefined') {
|
|
1563
|
+
payload['phrase'] = phrase;
|
|
1564
|
+
}
|
|
1565
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
1566
|
+
return yield this.client.call('post', uri, {
|
|
1567
|
+
'content-type': 'application/json',
|
|
1568
|
+
}, payload);
|
|
1569
|
+
});
|
|
1570
|
+
}
|
|
1571
|
+
/**
|
|
1572
|
+
* Create phone token
|
|
1573
|
+
*
|
|
1574
|
+
* Sends the user an SMS with a secret key for creating a session. If the
|
|
1575
|
+
* provided user ID has not be registered, a new user will be created. Use the
|
|
1576
|
+
* returned user ID and secret and submit a request to the [POST
|
|
1577
|
+
* /v1/account/sessions/token](https://appwrite.io/docs/references/cloud/client-web/account#createSession)
|
|
1578
|
+
* endpoint to complete the login process. The secret sent to the user's phone
|
|
1579
|
+
* is valid for 15 minutes.
|
|
1580
|
+
*
|
|
1581
|
+
* A user is limited to 10 active sessions at a time by default. [Learn more
|
|
1582
|
+
* about session
|
|
1583
|
+
* limits](https://appwrite.io/docs/authentication-security#limits).
|
|
1584
|
+
*
|
|
1585
|
+
* @param {string} userId
|
|
1586
|
+
* @param {string} phone
|
|
1587
|
+
* @throws {AppwriteException}
|
|
1588
|
+
* @returns {Promise}
|
|
1589
|
+
*/
|
|
1590
|
+
createPhoneToken(userId, phone) {
|
|
1591
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
1592
|
+
if (typeof userId === 'undefined') {
|
|
1593
|
+
throw new AppwriteException('Missing required parameter: "userId"');
|
|
1594
|
+
}
|
|
1595
|
+
if (typeof phone === 'undefined') {
|
|
1596
|
+
throw new AppwriteException('Missing required parameter: "phone"');
|
|
1597
|
+
}
|
|
1598
|
+
const apiPath = '/account/tokens/phone';
|
|
1599
|
+
const payload = {};
|
|
1600
|
+
if (typeof userId !== 'undefined') {
|
|
1601
|
+
payload['userId'] = userId;
|
|
1602
|
+
}
|
|
1603
|
+
if (typeof phone !== 'undefined') {
|
|
1604
|
+
payload['phone'] = phone;
|
|
1605
|
+
}
|
|
1606
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
1607
|
+
return yield this.client.call('post', uri, {
|
|
1608
|
+
'content-type': 'application/json',
|
|
1609
|
+
}, payload);
|
|
1610
|
+
});
|
|
1611
|
+
}
|
|
1432
1612
|
/**
|
|
1433
1613
|
* Create email verification
|
|
1434
1614
|
*
|
|
@@ -1583,7 +1763,7 @@ class Avatars extends Service {
|
|
|
1583
1763
|
* image at source quality. If dimensions are not specified, the default size
|
|
1584
1764
|
* of image returned is 100x100px.
|
|
1585
1765
|
*
|
|
1586
|
-
* @param {
|
|
1766
|
+
* @param {Browser} code
|
|
1587
1767
|
* @param {number} width
|
|
1588
1768
|
* @param {number} height
|
|
1589
1769
|
* @param {number} quality
|
|
@@ -1625,7 +1805,7 @@ class Avatars extends Service {
|
|
|
1625
1805
|
* of image returned is 100x100px.
|
|
1626
1806
|
*
|
|
1627
1807
|
*
|
|
1628
|
-
* @param {
|
|
1808
|
+
* @param {CreditCard} code
|
|
1629
1809
|
* @param {number} width
|
|
1630
1810
|
* @param {number} height
|
|
1631
1811
|
* @param {number} quality
|
|
@@ -1695,7 +1875,7 @@ class Avatars extends Service {
|
|
|
1695
1875
|
* of image returned is 100x100px.
|
|
1696
1876
|
*
|
|
1697
1877
|
*
|
|
1698
|
-
* @param {
|
|
1878
|
+
* @param {Flag} code
|
|
1699
1879
|
* @param {number} width
|
|
1700
1880
|
* @param {number} height
|
|
1701
1881
|
* @param {number} quality
|
|
@@ -1982,7 +2162,7 @@ class Databases extends Service {
|
|
|
1982
2162
|
* Get usage stats for the database
|
|
1983
2163
|
*
|
|
1984
2164
|
*
|
|
1985
|
-
* @param {
|
|
2165
|
+
* @param {DatabaseUsageRange} range
|
|
1986
2166
|
* @throws {AppwriteException}
|
|
1987
2167
|
* @returns {Promise}
|
|
1988
2168
|
*/
|
|
@@ -3013,11 +3193,11 @@ class Databases extends Service {
|
|
|
3013
3193
|
* @param {string} databaseId
|
|
3014
3194
|
* @param {string} collectionId
|
|
3015
3195
|
* @param {string} relatedCollectionId
|
|
3016
|
-
* @param {
|
|
3196
|
+
* @param {RelationshipType} type
|
|
3017
3197
|
* @param {boolean} twoWay
|
|
3018
3198
|
* @param {string} key
|
|
3019
3199
|
* @param {string} twoWayKey
|
|
3020
|
-
* @param {
|
|
3200
|
+
* @param {RelationMutate} onDelete
|
|
3021
3201
|
* @throws {AppwriteException}
|
|
3022
3202
|
* @returns {Promise}
|
|
3023
3203
|
*/
|
|
@@ -3330,7 +3510,7 @@ class Databases extends Service {
|
|
|
3330
3510
|
* @param {string} databaseId
|
|
3331
3511
|
* @param {string} collectionId
|
|
3332
3512
|
* @param {string} key
|
|
3333
|
-
* @param {
|
|
3513
|
+
* @param {RelationMutate} onDelete
|
|
3334
3514
|
* @throws {AppwriteException}
|
|
3335
3515
|
* @returns {Promise}
|
|
3336
3516
|
*/
|
|
@@ -3608,7 +3788,7 @@ class Databases extends Service {
|
|
|
3608
3788
|
* @param {string} databaseId
|
|
3609
3789
|
* @param {string} collectionId
|
|
3610
3790
|
* @param {string} key
|
|
3611
|
-
* @param {
|
|
3791
|
+
* @param {IndexType} type
|
|
3612
3792
|
* @param {string[]} attributes
|
|
3613
3793
|
* @param {string[]} orders
|
|
3614
3794
|
* @throws {AppwriteException}
|
|
@@ -3745,7 +3925,7 @@ class Databases extends Service {
|
|
|
3745
3925
|
*
|
|
3746
3926
|
* @param {string} databaseId
|
|
3747
3927
|
* @param {string} collectionId
|
|
3748
|
-
* @param {
|
|
3928
|
+
* @param {DatabaseUsageRange} range
|
|
3749
3929
|
* @throws {AppwriteException}
|
|
3750
3930
|
* @returns {Promise}
|
|
3751
3931
|
*/
|
|
@@ -3799,7 +3979,7 @@ class Databases extends Service {
|
|
|
3799
3979
|
*
|
|
3800
3980
|
*
|
|
3801
3981
|
* @param {string} databaseId
|
|
3802
|
-
* @param {
|
|
3982
|
+
* @param {DatabaseUsageRange} range
|
|
3803
3983
|
* @throws {AppwriteException}
|
|
3804
3984
|
* @returns {Promise}
|
|
3805
3985
|
*/
|
|
@@ -3862,7 +4042,7 @@ class Functions extends Service {
|
|
|
3862
4042
|
*
|
|
3863
4043
|
* @param {string} functionId
|
|
3864
4044
|
* @param {string} name
|
|
3865
|
-
* @param {
|
|
4045
|
+
* @param {Runtime} runtime
|
|
3866
4046
|
* @param {string[]} execute
|
|
3867
4047
|
* @param {string[]} events
|
|
3868
4048
|
* @param {string} schedule
|
|
@@ -3984,7 +4164,7 @@ class Functions extends Service {
|
|
|
3984
4164
|
* Get functions usage
|
|
3985
4165
|
*
|
|
3986
4166
|
*
|
|
3987
|
-
* @param {
|
|
4167
|
+
* @param {FunctionUsageRange} range
|
|
3988
4168
|
* @throws {AppwriteException}
|
|
3989
4169
|
* @returns {Promise}
|
|
3990
4170
|
*/
|
|
@@ -4030,7 +4210,7 @@ class Functions extends Service {
|
|
|
4030
4210
|
*
|
|
4031
4211
|
* @param {string} functionId
|
|
4032
4212
|
* @param {string} name
|
|
4033
|
-
* @param {
|
|
4213
|
+
* @param {Runtime} runtime
|
|
4034
4214
|
* @param {string[]} execute
|
|
4035
4215
|
* @param {string[]} events
|
|
4036
4216
|
* @param {string} schedule
|
|
@@ -4427,7 +4607,7 @@ class Functions extends Service {
|
|
|
4427
4607
|
* @param {string} body
|
|
4428
4608
|
* @param {boolean} async
|
|
4429
4609
|
* @param {string} xpath
|
|
4430
|
-
* @param {
|
|
4610
|
+
* @param {ExecutionMethod} method
|
|
4431
4611
|
* @param {object} headers
|
|
4432
4612
|
* @throws {AppwriteException}
|
|
4433
4613
|
* @returns {Promise}
|
|
@@ -4491,7 +4671,7 @@ class Functions extends Service {
|
|
|
4491
4671
|
*
|
|
4492
4672
|
*
|
|
4493
4673
|
* @param {string} functionId
|
|
4494
|
-
* @param {
|
|
4674
|
+
* @param {FunctionUsageRange} range
|
|
4495
4675
|
* @throws {AppwriteException}
|
|
4496
4676
|
* @returns {Promise}
|
|
4497
4677
|
*/
|
|
@@ -4778,6 +4958,28 @@ class Health extends Service {
|
|
|
4778
4958
|
}, payload);
|
|
4779
4959
|
});
|
|
4780
4960
|
}
|
|
4961
|
+
/**
|
|
4962
|
+
* Get the SSL certificate for a domain
|
|
4963
|
+
*
|
|
4964
|
+
* Get the SSL certificate for a domain
|
|
4965
|
+
*
|
|
4966
|
+
* @param {string} domain
|
|
4967
|
+
* @throws {AppwriteException}
|
|
4968
|
+
* @returns {Promise}
|
|
4969
|
+
*/
|
|
4970
|
+
getCertificate(domain) {
|
|
4971
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
4972
|
+
const apiPath = '/health/certificate';
|
|
4973
|
+
const payload = {};
|
|
4974
|
+
if (typeof domain !== 'undefined') {
|
|
4975
|
+
payload['domain'] = domain;
|
|
4976
|
+
}
|
|
4977
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
4978
|
+
return yield this.client.call('get', uri, {
|
|
4979
|
+
'content-type': 'application/json',
|
|
4980
|
+
}, payload);
|
|
4981
|
+
});
|
|
4982
|
+
}
|
|
4781
4983
|
/**
|
|
4782
4984
|
* Get DB
|
|
4783
4985
|
*
|
|
@@ -4930,6 +5132,33 @@ class Health extends Service {
|
|
|
4930
5132
|
}, payload);
|
|
4931
5133
|
});
|
|
4932
5134
|
}
|
|
5135
|
+
/**
|
|
5136
|
+
* Get number of failed queue jobs
|
|
5137
|
+
*
|
|
5138
|
+
* Returns the amount of failed jobs in a given queue.
|
|
5139
|
+
*
|
|
5140
|
+
*
|
|
5141
|
+
* @param {Name} name
|
|
5142
|
+
* @param {number} threshold
|
|
5143
|
+
* @throws {AppwriteException}
|
|
5144
|
+
* @returns {Promise}
|
|
5145
|
+
*/
|
|
5146
|
+
getFailedJobs(name, threshold) {
|
|
5147
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
5148
|
+
if (typeof name === 'undefined') {
|
|
5149
|
+
throw new AppwriteException('Missing required parameter: "name"');
|
|
5150
|
+
}
|
|
5151
|
+
const apiPath = '/health/queue/failed/{name}'.replace('{name}', name);
|
|
5152
|
+
const payload = {};
|
|
5153
|
+
if (typeof threshold !== 'undefined') {
|
|
5154
|
+
payload['threshold'] = threshold;
|
|
5155
|
+
}
|
|
5156
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
5157
|
+
return yield this.client.call('get', uri, {
|
|
5158
|
+
'content-type': 'application/json',
|
|
5159
|
+
}, payload);
|
|
5160
|
+
});
|
|
5161
|
+
}
|
|
4933
5162
|
/**
|
|
4934
5163
|
* Get functions queue
|
|
4935
5164
|
*
|
|
@@ -5281,7 +5510,7 @@ class Messaging extends Service {
|
|
|
5281
5510
|
* List messages
|
|
5282
5511
|
*
|
|
5283
5512
|
*
|
|
5284
|
-
* @param {string} queries
|
|
5513
|
+
* @param {string[]} queries
|
|
5285
5514
|
* @param {string} search
|
|
5286
5515
|
* @throws {AppwriteException}
|
|
5287
5516
|
* @returns {Promise}
|
|
@@ -5312,14 +5541,15 @@ class Messaging extends Service {
|
|
|
5312
5541
|
* @param {string[]} topics
|
|
5313
5542
|
* @param {string[]} users
|
|
5314
5543
|
* @param {string[]} targets
|
|
5315
|
-
* @param {string}
|
|
5316
|
-
* @param {string}
|
|
5544
|
+
* @param {string[]} cc
|
|
5545
|
+
* @param {string[]} bcc
|
|
5546
|
+
* @param {MessageStatus} status
|
|
5317
5547
|
* @param {boolean} html
|
|
5318
5548
|
* @param {string} scheduledAt
|
|
5319
5549
|
* @throws {AppwriteException}
|
|
5320
5550
|
* @returns {Promise}
|
|
5321
5551
|
*/
|
|
5322
|
-
|
|
5552
|
+
createEmail(messageId, subject, content, topics, users, targets, cc, bcc, status, html, scheduledAt) {
|
|
5323
5553
|
return __awaiter(this, void 0, void 0, function* () {
|
|
5324
5554
|
if (typeof messageId === 'undefined') {
|
|
5325
5555
|
throw new AppwriteException('Missing required parameter: "messageId"');
|
|
@@ -5350,8 +5580,11 @@ class Messaging extends Service {
|
|
|
5350
5580
|
if (typeof targets !== 'undefined') {
|
|
5351
5581
|
payload['targets'] = targets;
|
|
5352
5582
|
}
|
|
5353
|
-
if (typeof
|
|
5354
|
-
payload['
|
|
5583
|
+
if (typeof cc !== 'undefined') {
|
|
5584
|
+
payload['cc'] = cc;
|
|
5585
|
+
}
|
|
5586
|
+
if (typeof bcc !== 'undefined') {
|
|
5587
|
+
payload['bcc'] = bcc;
|
|
5355
5588
|
}
|
|
5356
5589
|
if (typeof status !== 'undefined') {
|
|
5357
5590
|
payload['status'] = status;
|
|
@@ -5377,15 +5610,16 @@ class Messaging extends Service {
|
|
|
5377
5610
|
* @param {string[]} users
|
|
5378
5611
|
* @param {string[]} targets
|
|
5379
5612
|
* @param {string} subject
|
|
5380
|
-
* @param {string} description
|
|
5381
5613
|
* @param {string} content
|
|
5382
|
-
* @param {
|
|
5614
|
+
* @param {MessageStatus} status
|
|
5383
5615
|
* @param {boolean} html
|
|
5616
|
+
* @param {string[]} cc
|
|
5617
|
+
* @param {string[]} bcc
|
|
5384
5618
|
* @param {string} scheduledAt
|
|
5385
5619
|
* @throws {AppwriteException}
|
|
5386
5620
|
* @returns {Promise}
|
|
5387
5621
|
*/
|
|
5388
|
-
updateEmail(messageId, topics, users, targets, subject,
|
|
5622
|
+
updateEmail(messageId, topics, users, targets, subject, content, status, html, cc, bcc, scheduledAt) {
|
|
5389
5623
|
return __awaiter(this, void 0, void 0, function* () {
|
|
5390
5624
|
if (typeof messageId === 'undefined') {
|
|
5391
5625
|
throw new AppwriteException('Missing required parameter: "messageId"');
|
|
@@ -5404,9 +5638,6 @@ class Messaging extends Service {
|
|
|
5404
5638
|
if (typeof subject !== 'undefined') {
|
|
5405
5639
|
payload['subject'] = subject;
|
|
5406
5640
|
}
|
|
5407
|
-
if (typeof description !== 'undefined') {
|
|
5408
|
-
payload['description'] = description;
|
|
5409
|
-
}
|
|
5410
5641
|
if (typeof content !== 'undefined') {
|
|
5411
5642
|
payload['content'] = content;
|
|
5412
5643
|
}
|
|
@@ -5416,6 +5647,12 @@ class Messaging extends Service {
|
|
|
5416
5647
|
if (typeof html !== 'undefined') {
|
|
5417
5648
|
payload['html'] = html;
|
|
5418
5649
|
}
|
|
5650
|
+
if (typeof cc !== 'undefined') {
|
|
5651
|
+
payload['cc'] = cc;
|
|
5652
|
+
}
|
|
5653
|
+
if (typeof bcc !== 'undefined') {
|
|
5654
|
+
payload['bcc'] = bcc;
|
|
5655
|
+
}
|
|
5419
5656
|
if (typeof scheduledAt !== 'undefined') {
|
|
5420
5657
|
payload['scheduledAt'] = scheduledAt;
|
|
5421
5658
|
}
|
|
@@ -5435,7 +5672,6 @@ class Messaging extends Service {
|
|
|
5435
5672
|
* @param {string[]} topics
|
|
5436
5673
|
* @param {string[]} users
|
|
5437
5674
|
* @param {string[]} targets
|
|
5438
|
-
* @param {string} description
|
|
5439
5675
|
* @param {object} data
|
|
5440
5676
|
* @param {string} action
|
|
5441
5677
|
* @param {string} icon
|
|
@@ -5443,12 +5679,12 @@ class Messaging extends Service {
|
|
|
5443
5679
|
* @param {string} color
|
|
5444
5680
|
* @param {string} tag
|
|
5445
5681
|
* @param {string} badge
|
|
5446
|
-
* @param {
|
|
5682
|
+
* @param {MessageStatus} status
|
|
5447
5683
|
* @param {string} scheduledAt
|
|
5448
5684
|
* @throws {AppwriteException}
|
|
5449
5685
|
* @returns {Promise}
|
|
5450
5686
|
*/
|
|
5451
|
-
|
|
5687
|
+
createPush(messageId, title, body, topics, users, targets, data, action, icon, sound, color, tag, badge, status, scheduledAt) {
|
|
5452
5688
|
return __awaiter(this, void 0, void 0, function* () {
|
|
5453
5689
|
if (typeof messageId === 'undefined') {
|
|
5454
5690
|
throw new AppwriteException('Missing required parameter: "messageId"');
|
|
@@ -5479,9 +5715,6 @@ class Messaging extends Service {
|
|
|
5479
5715
|
if (typeof targets !== 'undefined') {
|
|
5480
5716
|
payload['targets'] = targets;
|
|
5481
5717
|
}
|
|
5482
|
-
if (typeof description !== 'undefined') {
|
|
5483
|
-
payload['description'] = description;
|
|
5484
|
-
}
|
|
5485
5718
|
if (typeof data !== 'undefined') {
|
|
5486
5719
|
payload['data'] = data;
|
|
5487
5720
|
}
|
|
@@ -5523,7 +5756,6 @@ class Messaging extends Service {
|
|
|
5523
5756
|
* @param {string[]} topics
|
|
5524
5757
|
* @param {string[]} users
|
|
5525
5758
|
* @param {string[]} targets
|
|
5526
|
-
* @param {string} description
|
|
5527
5759
|
* @param {string} title
|
|
5528
5760
|
* @param {string} body
|
|
5529
5761
|
* @param {object} data
|
|
@@ -5532,13 +5764,13 @@ class Messaging extends Service {
|
|
|
5532
5764
|
* @param {string} sound
|
|
5533
5765
|
* @param {string} color
|
|
5534
5766
|
* @param {string} tag
|
|
5535
|
-
* @param {
|
|
5536
|
-
* @param {
|
|
5767
|
+
* @param {number} badge
|
|
5768
|
+
* @param {MessageStatus} status
|
|
5537
5769
|
* @param {string} scheduledAt
|
|
5538
5770
|
* @throws {AppwriteException}
|
|
5539
5771
|
* @returns {Promise}
|
|
5540
5772
|
*/
|
|
5541
|
-
|
|
5773
|
+
updatePush(messageId, topics, users, targets, title, body, data, action, icon, sound, color, tag, badge, status, scheduledAt) {
|
|
5542
5774
|
return __awaiter(this, void 0, void 0, function* () {
|
|
5543
5775
|
if (typeof messageId === 'undefined') {
|
|
5544
5776
|
throw new AppwriteException('Missing required parameter: "messageId"');
|
|
@@ -5554,9 +5786,6 @@ class Messaging extends Service {
|
|
|
5554
5786
|
if (typeof targets !== 'undefined') {
|
|
5555
5787
|
payload['targets'] = targets;
|
|
5556
5788
|
}
|
|
5557
|
-
if (typeof description !== 'undefined') {
|
|
5558
|
-
payload['description'] = description;
|
|
5559
|
-
}
|
|
5560
5789
|
if (typeof title !== 'undefined') {
|
|
5561
5790
|
payload['title'] = title;
|
|
5562
5791
|
}
|
|
@@ -5605,13 +5834,12 @@ class Messaging extends Service {
|
|
|
5605
5834
|
* @param {string[]} topics
|
|
5606
5835
|
* @param {string[]} users
|
|
5607
5836
|
* @param {string[]} targets
|
|
5608
|
-
* @param {
|
|
5609
|
-
* @param {string} status
|
|
5837
|
+
* @param {MessageStatus} status
|
|
5610
5838
|
* @param {string} scheduledAt
|
|
5611
5839
|
* @throws {AppwriteException}
|
|
5612
5840
|
* @returns {Promise}
|
|
5613
5841
|
*/
|
|
5614
|
-
|
|
5842
|
+
createSMS(messageId, content, topics, users, targets, status, scheduledAt) {
|
|
5615
5843
|
return __awaiter(this, void 0, void 0, function* () {
|
|
5616
5844
|
if (typeof messageId === 'undefined') {
|
|
5617
5845
|
throw new AppwriteException('Missing required parameter: "messageId"');
|
|
@@ -5636,9 +5864,6 @@ class Messaging extends Service {
|
|
|
5636
5864
|
if (typeof targets !== 'undefined') {
|
|
5637
5865
|
payload['targets'] = targets;
|
|
5638
5866
|
}
|
|
5639
|
-
if (typeof description !== 'undefined') {
|
|
5640
|
-
payload['description'] = description;
|
|
5641
|
-
}
|
|
5642
5867
|
if (typeof status !== 'undefined') {
|
|
5643
5868
|
payload['status'] = status;
|
|
5644
5869
|
}
|
|
@@ -5659,14 +5884,13 @@ class Messaging extends Service {
|
|
|
5659
5884
|
* @param {string[]} topics
|
|
5660
5885
|
* @param {string[]} users
|
|
5661
5886
|
* @param {string[]} targets
|
|
5662
|
-
* @param {string} description
|
|
5663
5887
|
* @param {string} content
|
|
5664
|
-
* @param {
|
|
5888
|
+
* @param {MessageStatus} status
|
|
5665
5889
|
* @param {string} scheduledAt
|
|
5666
5890
|
* @throws {AppwriteException}
|
|
5667
5891
|
* @returns {Promise}
|
|
5668
5892
|
*/
|
|
5669
|
-
updateSMS(messageId, topics, users, targets,
|
|
5893
|
+
updateSMS(messageId, topics, users, targets, content, status, scheduledAt) {
|
|
5670
5894
|
return __awaiter(this, void 0, void 0, function* () {
|
|
5671
5895
|
if (typeof messageId === 'undefined') {
|
|
5672
5896
|
throw new AppwriteException('Missing required parameter: "messageId"');
|
|
@@ -5682,9 +5906,6 @@ class Messaging extends Service {
|
|
|
5682
5906
|
if (typeof targets !== 'undefined') {
|
|
5683
5907
|
payload['targets'] = targets;
|
|
5684
5908
|
}
|
|
5685
|
-
if (typeof description !== 'undefined') {
|
|
5686
|
-
payload['description'] = description;
|
|
5687
|
-
}
|
|
5688
5909
|
if (typeof content !== 'undefined') {
|
|
5689
5910
|
payload['content'] = content;
|
|
5690
5911
|
}
|
|
@@ -5695,20 +5916,41 @@ class Messaging extends Service {
|
|
|
5695
5916
|
payload['scheduledAt'] = scheduledAt;
|
|
5696
5917
|
}
|
|
5697
5918
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
5698
|
-
return yield this.client.call('patch', uri, {
|
|
5919
|
+
return yield this.client.call('patch', uri, {
|
|
5920
|
+
'content-type': 'application/json',
|
|
5921
|
+
}, payload);
|
|
5922
|
+
});
|
|
5923
|
+
}
|
|
5924
|
+
/**
|
|
5925
|
+
* Get a message
|
|
5926
|
+
*
|
|
5927
|
+
*
|
|
5928
|
+
* @param {string} messageId
|
|
5929
|
+
* @throws {AppwriteException}
|
|
5930
|
+
* @returns {Promise}
|
|
5931
|
+
*/
|
|
5932
|
+
getMessage(messageId) {
|
|
5933
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
5934
|
+
if (typeof messageId === 'undefined') {
|
|
5935
|
+
throw new AppwriteException('Missing required parameter: "messageId"');
|
|
5936
|
+
}
|
|
5937
|
+
const apiPath = '/messaging/messages/{messageId}'.replace('{messageId}', messageId);
|
|
5938
|
+
const payload = {};
|
|
5939
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
5940
|
+
return yield this.client.call('get', uri, {
|
|
5699
5941
|
'content-type': 'application/json',
|
|
5700
5942
|
}, payload);
|
|
5701
5943
|
});
|
|
5702
5944
|
}
|
|
5703
5945
|
/**
|
|
5704
|
-
*
|
|
5946
|
+
* Delete a message
|
|
5705
5947
|
*
|
|
5706
5948
|
*
|
|
5707
5949
|
* @param {string} messageId
|
|
5708
5950
|
* @throws {AppwriteException}
|
|
5709
5951
|
* @returns {Promise}
|
|
5710
5952
|
*/
|
|
5711
|
-
|
|
5953
|
+
delete(messageId) {
|
|
5712
5954
|
return __awaiter(this, void 0, void 0, function* () {
|
|
5713
5955
|
if (typeof messageId === 'undefined') {
|
|
5714
5956
|
throw new AppwriteException('Missing required parameter: "messageId"');
|
|
@@ -5716,7 +5958,7 @@ class Messaging extends Service {
|
|
|
5716
5958
|
const apiPath = '/messaging/messages/{messageId}'.replace('{messageId}', messageId);
|
|
5717
5959
|
const payload = {};
|
|
5718
5960
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
5719
|
-
return yield this.client.call('
|
|
5961
|
+
return yield this.client.call('delete', uri, {
|
|
5720
5962
|
'content-type': 'application/json',
|
|
5721
5963
|
}, payload);
|
|
5722
5964
|
});
|
|
@@ -5746,11 +5988,38 @@ class Messaging extends Service {
|
|
|
5746
5988
|
}, payload);
|
|
5747
5989
|
});
|
|
5748
5990
|
}
|
|
5991
|
+
/**
|
|
5992
|
+
* List message targets
|
|
5993
|
+
*
|
|
5994
|
+
* List the targets associated with a message as set via the targets
|
|
5995
|
+
* attribute.
|
|
5996
|
+
*
|
|
5997
|
+
* @param {string} messageId
|
|
5998
|
+
* @param {string[]} queries
|
|
5999
|
+
* @throws {AppwriteException}
|
|
6000
|
+
* @returns {Promise}
|
|
6001
|
+
*/
|
|
6002
|
+
listTargets(messageId, queries) {
|
|
6003
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
6004
|
+
if (typeof messageId === 'undefined') {
|
|
6005
|
+
throw new AppwriteException('Missing required parameter: "messageId"');
|
|
6006
|
+
}
|
|
6007
|
+
const apiPath = '/messaging/messages/{messageId}/targets'.replace('{messageId}', messageId);
|
|
6008
|
+
const payload = {};
|
|
6009
|
+
if (typeof queries !== 'undefined') {
|
|
6010
|
+
payload['queries'] = queries;
|
|
6011
|
+
}
|
|
6012
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
6013
|
+
return yield this.client.call('get', uri, {
|
|
6014
|
+
'content-type': 'application/json',
|
|
6015
|
+
}, payload);
|
|
6016
|
+
});
|
|
6017
|
+
}
|
|
5749
6018
|
/**
|
|
5750
6019
|
* List providers
|
|
5751
6020
|
*
|
|
5752
6021
|
*
|
|
5753
|
-
* @param {string} queries
|
|
6022
|
+
* @param {string[]} queries
|
|
5754
6023
|
* @param {string} search
|
|
5755
6024
|
* @throws {AppwriteException}
|
|
5756
6025
|
* @returns {Promise}
|
|
@@ -5781,12 +6050,11 @@ class Messaging extends Service {
|
|
|
5781
6050
|
* @param {string} authKeyId
|
|
5782
6051
|
* @param {string} teamId
|
|
5783
6052
|
* @param {string} bundleId
|
|
5784
|
-
* @param {string} endpoint
|
|
5785
6053
|
* @param {boolean} enabled
|
|
5786
6054
|
* @throws {AppwriteException}
|
|
5787
6055
|
* @returns {Promise}
|
|
5788
6056
|
*/
|
|
5789
|
-
|
|
6057
|
+
createAPNSProvider(providerId, name, authKey, authKeyId, teamId, bundleId, enabled) {
|
|
5790
6058
|
return __awaiter(this, void 0, void 0, function* () {
|
|
5791
6059
|
if (typeof providerId === 'undefined') {
|
|
5792
6060
|
throw new AppwriteException('Missing required parameter: "providerId"');
|
|
@@ -5814,9 +6082,6 @@ class Messaging extends Service {
|
|
|
5814
6082
|
if (typeof bundleId !== 'undefined') {
|
|
5815
6083
|
payload['bundleId'] = bundleId;
|
|
5816
6084
|
}
|
|
5817
|
-
if (typeof endpoint !== 'undefined') {
|
|
5818
|
-
payload['endpoint'] = endpoint;
|
|
5819
|
-
}
|
|
5820
6085
|
if (typeof enabled !== 'undefined') {
|
|
5821
6086
|
payload['enabled'] = enabled;
|
|
5822
6087
|
}
|
|
@@ -5837,11 +6102,10 @@ class Messaging extends Service {
|
|
|
5837
6102
|
* @param {string} authKeyId
|
|
5838
6103
|
* @param {string} teamId
|
|
5839
6104
|
* @param {string} bundleId
|
|
5840
|
-
* @param {string} endpoint
|
|
5841
6105
|
* @throws {AppwriteException}
|
|
5842
6106
|
* @returns {Promise}
|
|
5843
6107
|
*/
|
|
5844
|
-
|
|
6108
|
+
updateAPNSProvider(providerId, name, enabled, authKey, authKeyId, teamId, bundleId) {
|
|
5845
6109
|
return __awaiter(this, void 0, void 0, function* () {
|
|
5846
6110
|
if (typeof providerId === 'undefined') {
|
|
5847
6111
|
throw new AppwriteException('Missing required parameter: "providerId"');
|
|
@@ -5866,9 +6130,6 @@ class Messaging extends Service {
|
|
|
5866
6130
|
if (typeof bundleId !== 'undefined') {
|
|
5867
6131
|
payload['bundleId'] = bundleId;
|
|
5868
6132
|
}
|
|
5869
|
-
if (typeof endpoint !== 'undefined') {
|
|
5870
|
-
payload['endpoint'] = endpoint;
|
|
5871
|
-
}
|
|
5872
6133
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
5873
6134
|
return yield this.client.call('patch', uri, {
|
|
5874
6135
|
'content-type': 'application/json',
|
|
@@ -5881,12 +6142,12 @@ class Messaging extends Service {
|
|
|
5881
6142
|
*
|
|
5882
6143
|
* @param {string} providerId
|
|
5883
6144
|
* @param {string} name
|
|
5884
|
-
* @param {
|
|
6145
|
+
* @param {object} serviceAccountJSON
|
|
5885
6146
|
* @param {boolean} enabled
|
|
5886
6147
|
* @throws {AppwriteException}
|
|
5887
6148
|
* @returns {Promise}
|
|
5888
6149
|
*/
|
|
5889
|
-
|
|
6150
|
+
createFCMProvider(providerId, name, serviceAccountJSON, enabled) {
|
|
5890
6151
|
return __awaiter(this, void 0, void 0, function* () {
|
|
5891
6152
|
if (typeof providerId === 'undefined') {
|
|
5892
6153
|
throw new AppwriteException('Missing required parameter: "providerId"');
|
|
@@ -5902,8 +6163,8 @@ class Messaging extends Service {
|
|
|
5902
6163
|
if (typeof name !== 'undefined') {
|
|
5903
6164
|
payload['name'] = name;
|
|
5904
6165
|
}
|
|
5905
|
-
if (typeof
|
|
5906
|
-
payload['
|
|
6166
|
+
if (typeof serviceAccountJSON !== 'undefined') {
|
|
6167
|
+
payload['serviceAccountJSON'] = serviceAccountJSON;
|
|
5907
6168
|
}
|
|
5908
6169
|
if (typeof enabled !== 'undefined') {
|
|
5909
6170
|
payload['enabled'] = enabled;
|
|
@@ -5921,11 +6182,11 @@ class Messaging extends Service {
|
|
|
5921
6182
|
* @param {string} providerId
|
|
5922
6183
|
* @param {string} name
|
|
5923
6184
|
* @param {boolean} enabled
|
|
5924
|
-
* @param {
|
|
6185
|
+
* @param {object} serviceAccountJSON
|
|
5925
6186
|
* @throws {AppwriteException}
|
|
5926
6187
|
* @returns {Promise}
|
|
5927
6188
|
*/
|
|
5928
|
-
|
|
6189
|
+
updateFCMProvider(providerId, name, enabled, serviceAccountJSON) {
|
|
5929
6190
|
return __awaiter(this, void 0, void 0, function* () {
|
|
5930
6191
|
if (typeof providerId === 'undefined') {
|
|
5931
6192
|
throw new AppwriteException('Missing required parameter: "providerId"');
|
|
@@ -5938,8 +6199,8 @@ class Messaging extends Service {
|
|
|
5938
6199
|
if (typeof enabled !== 'undefined') {
|
|
5939
6200
|
payload['enabled'] = enabled;
|
|
5940
6201
|
}
|
|
5941
|
-
if (typeof
|
|
5942
|
-
payload['
|
|
6202
|
+
if (typeof serviceAccountJSON !== 'undefined') {
|
|
6203
|
+
payload['serviceAccountJSON'] = serviceAccountJSON;
|
|
5943
6204
|
}
|
|
5944
6205
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
5945
6206
|
return yield this.client.call('patch', uri, {
|
|
@@ -5953,15 +6214,18 @@ class Messaging extends Service {
|
|
|
5953
6214
|
*
|
|
5954
6215
|
* @param {string} providerId
|
|
5955
6216
|
* @param {string} name
|
|
5956
|
-
* @param {string} from
|
|
5957
6217
|
* @param {string} apiKey
|
|
5958
6218
|
* @param {string} domain
|
|
5959
6219
|
* @param {boolean} isEuRegion
|
|
6220
|
+
* @param {string} fromName
|
|
6221
|
+
* @param {string} fromEmail
|
|
6222
|
+
* @param {string} replyToName
|
|
6223
|
+
* @param {string} replyToEmail
|
|
5960
6224
|
* @param {boolean} enabled
|
|
5961
6225
|
* @throws {AppwriteException}
|
|
5962
6226
|
* @returns {Promise}
|
|
5963
6227
|
*/
|
|
5964
|
-
createMailgunProvider(providerId, name,
|
|
6228
|
+
createMailgunProvider(providerId, name, apiKey, domain, isEuRegion, fromName, fromEmail, replyToName, replyToEmail, enabled) {
|
|
5965
6229
|
return __awaiter(this, void 0, void 0, function* () {
|
|
5966
6230
|
if (typeof providerId === 'undefined') {
|
|
5967
6231
|
throw new AppwriteException('Missing required parameter: "providerId"');
|
|
@@ -5977,9 +6241,6 @@ class Messaging extends Service {
|
|
|
5977
6241
|
if (typeof name !== 'undefined') {
|
|
5978
6242
|
payload['name'] = name;
|
|
5979
6243
|
}
|
|
5980
|
-
if (typeof from !== 'undefined') {
|
|
5981
|
-
payload['from'] = from;
|
|
5982
|
-
}
|
|
5983
6244
|
if (typeof apiKey !== 'undefined') {
|
|
5984
6245
|
payload['apiKey'] = apiKey;
|
|
5985
6246
|
}
|
|
@@ -5989,6 +6250,18 @@ class Messaging extends Service {
|
|
|
5989
6250
|
if (typeof isEuRegion !== 'undefined') {
|
|
5990
6251
|
payload['isEuRegion'] = isEuRegion;
|
|
5991
6252
|
}
|
|
6253
|
+
if (typeof fromName !== 'undefined') {
|
|
6254
|
+
payload['fromName'] = fromName;
|
|
6255
|
+
}
|
|
6256
|
+
if (typeof fromEmail !== 'undefined') {
|
|
6257
|
+
payload['fromEmail'] = fromEmail;
|
|
6258
|
+
}
|
|
6259
|
+
if (typeof replyToName !== 'undefined') {
|
|
6260
|
+
payload['replyToName'] = replyToName;
|
|
6261
|
+
}
|
|
6262
|
+
if (typeof replyToEmail !== 'undefined') {
|
|
6263
|
+
payload['replyToEmail'] = replyToEmail;
|
|
6264
|
+
}
|
|
5992
6265
|
if (typeof enabled !== 'undefined') {
|
|
5993
6266
|
payload['enabled'] = enabled;
|
|
5994
6267
|
}
|
|
@@ -6004,15 +6277,18 @@ class Messaging extends Service {
|
|
|
6004
6277
|
*
|
|
6005
6278
|
* @param {string} providerId
|
|
6006
6279
|
* @param {string} name
|
|
6007
|
-
* @param {boolean} enabled
|
|
6008
|
-
* @param {boolean} isEuRegion
|
|
6009
|
-
* @param {string} from
|
|
6010
6280
|
* @param {string} apiKey
|
|
6011
6281
|
* @param {string} domain
|
|
6282
|
+
* @param {boolean} isEuRegion
|
|
6283
|
+
* @param {boolean} enabled
|
|
6284
|
+
* @param {string} fromName
|
|
6285
|
+
* @param {string} fromEmail
|
|
6286
|
+
* @param {string} replyToName
|
|
6287
|
+
* @param {string} replyToEmail
|
|
6012
6288
|
* @throws {AppwriteException}
|
|
6013
6289
|
* @returns {Promise}
|
|
6014
6290
|
*/
|
|
6015
|
-
updateMailgunProvider(providerId, name,
|
|
6291
|
+
updateMailgunProvider(providerId, name, apiKey, domain, isEuRegion, enabled, fromName, fromEmail, replyToName, replyToEmail) {
|
|
6016
6292
|
return __awaiter(this, void 0, void 0, function* () {
|
|
6017
6293
|
if (typeof providerId === 'undefined') {
|
|
6018
6294
|
throw new AppwriteException('Missing required parameter: "providerId"');
|
|
@@ -6022,20 +6298,29 @@ class Messaging extends Service {
|
|
|
6022
6298
|
if (typeof name !== 'undefined') {
|
|
6023
6299
|
payload['name'] = name;
|
|
6024
6300
|
}
|
|
6025
|
-
if (typeof
|
|
6026
|
-
payload['
|
|
6301
|
+
if (typeof apiKey !== 'undefined') {
|
|
6302
|
+
payload['apiKey'] = apiKey;
|
|
6303
|
+
}
|
|
6304
|
+
if (typeof domain !== 'undefined') {
|
|
6305
|
+
payload['domain'] = domain;
|
|
6027
6306
|
}
|
|
6028
6307
|
if (typeof isEuRegion !== 'undefined') {
|
|
6029
6308
|
payload['isEuRegion'] = isEuRegion;
|
|
6030
6309
|
}
|
|
6031
|
-
if (typeof
|
|
6032
|
-
payload['
|
|
6310
|
+
if (typeof enabled !== 'undefined') {
|
|
6311
|
+
payload['enabled'] = enabled;
|
|
6033
6312
|
}
|
|
6034
|
-
if (typeof
|
|
6035
|
-
payload['
|
|
6313
|
+
if (typeof fromName !== 'undefined') {
|
|
6314
|
+
payload['fromName'] = fromName;
|
|
6036
6315
|
}
|
|
6037
|
-
if (typeof
|
|
6038
|
-
payload['
|
|
6316
|
+
if (typeof fromEmail !== 'undefined') {
|
|
6317
|
+
payload['fromEmail'] = fromEmail;
|
|
6318
|
+
}
|
|
6319
|
+
if (typeof replyToName !== 'undefined') {
|
|
6320
|
+
payload['replyToName'] = replyToName;
|
|
6321
|
+
}
|
|
6322
|
+
if (typeof replyToEmail !== 'undefined') {
|
|
6323
|
+
payload['replyToEmail'] = replyToEmail;
|
|
6039
6324
|
}
|
|
6040
6325
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
6041
6326
|
return yield this.client.call('patch', uri, {
|
|
@@ -6137,13 +6422,16 @@ class Messaging extends Service {
|
|
|
6137
6422
|
*
|
|
6138
6423
|
* @param {string} providerId
|
|
6139
6424
|
* @param {string} name
|
|
6140
|
-
* @param {string} from
|
|
6141
6425
|
* @param {string} apiKey
|
|
6426
|
+
* @param {string} fromName
|
|
6427
|
+
* @param {string} fromEmail
|
|
6428
|
+
* @param {string} replyToName
|
|
6429
|
+
* @param {string} replyToEmail
|
|
6142
6430
|
* @param {boolean} enabled
|
|
6143
6431
|
* @throws {AppwriteException}
|
|
6144
6432
|
* @returns {Promise}
|
|
6145
6433
|
*/
|
|
6146
|
-
createSendgridProvider(providerId, name,
|
|
6434
|
+
createSendgridProvider(providerId, name, apiKey, fromName, fromEmail, replyToName, replyToEmail, enabled) {
|
|
6147
6435
|
return __awaiter(this, void 0, void 0, function* () {
|
|
6148
6436
|
if (typeof providerId === 'undefined') {
|
|
6149
6437
|
throw new AppwriteException('Missing required parameter: "providerId"');
|
|
@@ -6159,12 +6447,21 @@ class Messaging extends Service {
|
|
|
6159
6447
|
if (typeof name !== 'undefined') {
|
|
6160
6448
|
payload['name'] = name;
|
|
6161
6449
|
}
|
|
6162
|
-
if (typeof from !== 'undefined') {
|
|
6163
|
-
payload['from'] = from;
|
|
6164
|
-
}
|
|
6165
6450
|
if (typeof apiKey !== 'undefined') {
|
|
6166
6451
|
payload['apiKey'] = apiKey;
|
|
6167
6452
|
}
|
|
6453
|
+
if (typeof fromName !== 'undefined') {
|
|
6454
|
+
payload['fromName'] = fromName;
|
|
6455
|
+
}
|
|
6456
|
+
if (typeof fromEmail !== 'undefined') {
|
|
6457
|
+
payload['fromEmail'] = fromEmail;
|
|
6458
|
+
}
|
|
6459
|
+
if (typeof replyToName !== 'undefined') {
|
|
6460
|
+
payload['replyToName'] = replyToName;
|
|
6461
|
+
}
|
|
6462
|
+
if (typeof replyToEmail !== 'undefined') {
|
|
6463
|
+
payload['replyToEmail'] = replyToEmail;
|
|
6464
|
+
}
|
|
6168
6465
|
if (typeof enabled !== 'undefined') {
|
|
6169
6466
|
payload['enabled'] = enabled;
|
|
6170
6467
|
}
|
|
@@ -6182,11 +6479,14 @@ class Messaging extends Service {
|
|
|
6182
6479
|
* @param {string} name
|
|
6183
6480
|
* @param {boolean} enabled
|
|
6184
6481
|
* @param {string} apiKey
|
|
6185
|
-
* @param {string}
|
|
6482
|
+
* @param {string} fromName
|
|
6483
|
+
* @param {string} fromEmail
|
|
6484
|
+
* @param {string} replyToName
|
|
6485
|
+
* @param {string} replyToEmail
|
|
6186
6486
|
* @throws {AppwriteException}
|
|
6187
6487
|
* @returns {Promise}
|
|
6188
6488
|
*/
|
|
6189
|
-
updateSendgridProvider(providerId, name, enabled, apiKey,
|
|
6489
|
+
updateSendgridProvider(providerId, name, enabled, apiKey, fromName, fromEmail, replyToName, replyToEmail) {
|
|
6190
6490
|
return __awaiter(this, void 0, void 0, function* () {
|
|
6191
6491
|
if (typeof providerId === 'undefined') {
|
|
6192
6492
|
throw new AppwriteException('Missing required parameter: "providerId"');
|
|
@@ -6202,8 +6502,17 @@ class Messaging extends Service {
|
|
|
6202
6502
|
if (typeof apiKey !== 'undefined') {
|
|
6203
6503
|
payload['apiKey'] = apiKey;
|
|
6204
6504
|
}
|
|
6205
|
-
if (typeof
|
|
6206
|
-
payload['
|
|
6505
|
+
if (typeof fromName !== 'undefined') {
|
|
6506
|
+
payload['fromName'] = fromName;
|
|
6507
|
+
}
|
|
6508
|
+
if (typeof fromEmail !== 'undefined') {
|
|
6509
|
+
payload['fromEmail'] = fromEmail;
|
|
6510
|
+
}
|
|
6511
|
+
if (typeof replyToName !== 'undefined') {
|
|
6512
|
+
payload['replyToName'] = replyToName;
|
|
6513
|
+
}
|
|
6514
|
+
if (typeof replyToEmail !== 'undefined') {
|
|
6515
|
+
payload['replyToEmail'] = replyToEmail;
|
|
6207
6516
|
}
|
|
6208
6517
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
6209
6518
|
return yield this.client.call('patch', uri, {
|
|
@@ -6212,19 +6521,27 @@ class Messaging extends Service {
|
|
|
6212
6521
|
});
|
|
6213
6522
|
}
|
|
6214
6523
|
/**
|
|
6215
|
-
* Create
|
|
6524
|
+
* Create SMTP provider
|
|
6216
6525
|
*
|
|
6217
6526
|
*
|
|
6218
6527
|
* @param {string} providerId
|
|
6219
6528
|
* @param {string} name
|
|
6220
|
-
* @param {string}
|
|
6529
|
+
* @param {string} host
|
|
6530
|
+
* @param {number} port
|
|
6221
6531
|
* @param {string} username
|
|
6222
6532
|
* @param {string} password
|
|
6533
|
+
* @param {SMTPEncryption} encryption
|
|
6534
|
+
* @param {boolean} autoTLS
|
|
6535
|
+
* @param {string} mailer
|
|
6536
|
+
* @param {string} fromName
|
|
6537
|
+
* @param {string} fromEmail
|
|
6538
|
+
* @param {string} replyToName
|
|
6539
|
+
* @param {string} replyToEmail
|
|
6223
6540
|
* @param {boolean} enabled
|
|
6224
6541
|
* @throws {AppwriteException}
|
|
6225
6542
|
* @returns {Promise}
|
|
6226
6543
|
*/
|
|
6227
|
-
|
|
6544
|
+
createSMTPProvider(providerId, name, host, port, username, password, encryption, autoTLS, mailer, fromName, fromEmail, replyToName, replyToEmail, enabled) {
|
|
6228
6545
|
return __awaiter(this, void 0, void 0, function* () {
|
|
6229
6546
|
if (typeof providerId === 'undefined') {
|
|
6230
6547
|
throw new AppwriteException('Missing required parameter: "providerId"');
|
|
@@ -6232,7 +6549,10 @@ class Messaging extends Service {
|
|
|
6232
6549
|
if (typeof name === 'undefined') {
|
|
6233
6550
|
throw new AppwriteException('Missing required parameter: "name"');
|
|
6234
6551
|
}
|
|
6235
|
-
|
|
6552
|
+
if (typeof host === 'undefined') {
|
|
6553
|
+
throw new AppwriteException('Missing required parameter: "host"');
|
|
6554
|
+
}
|
|
6555
|
+
const apiPath = '/messaging/providers/smtp';
|
|
6236
6556
|
const payload = {};
|
|
6237
6557
|
if (typeof providerId !== 'undefined') {
|
|
6238
6558
|
payload['providerId'] = providerId;
|
|
@@ -6240,8 +6560,11 @@ class Messaging extends Service {
|
|
|
6240
6560
|
if (typeof name !== 'undefined') {
|
|
6241
6561
|
payload['name'] = name;
|
|
6242
6562
|
}
|
|
6243
|
-
if (typeof
|
|
6244
|
-
payload['
|
|
6563
|
+
if (typeof host !== 'undefined') {
|
|
6564
|
+
payload['host'] = host;
|
|
6565
|
+
}
|
|
6566
|
+
if (typeof port !== 'undefined') {
|
|
6567
|
+
payload['port'] = port;
|
|
6245
6568
|
}
|
|
6246
6569
|
if (typeof username !== 'undefined') {
|
|
6247
6570
|
payload['username'] = username;
|
|
@@ -6249,6 +6572,27 @@ class Messaging extends Service {
|
|
|
6249
6572
|
if (typeof password !== 'undefined') {
|
|
6250
6573
|
payload['password'] = password;
|
|
6251
6574
|
}
|
|
6575
|
+
if (typeof encryption !== 'undefined') {
|
|
6576
|
+
payload['encryption'] = encryption;
|
|
6577
|
+
}
|
|
6578
|
+
if (typeof autoTLS !== 'undefined') {
|
|
6579
|
+
payload['autoTLS'] = autoTLS;
|
|
6580
|
+
}
|
|
6581
|
+
if (typeof mailer !== 'undefined') {
|
|
6582
|
+
payload['mailer'] = mailer;
|
|
6583
|
+
}
|
|
6584
|
+
if (typeof fromName !== 'undefined') {
|
|
6585
|
+
payload['fromName'] = fromName;
|
|
6586
|
+
}
|
|
6587
|
+
if (typeof fromEmail !== 'undefined') {
|
|
6588
|
+
payload['fromEmail'] = fromEmail;
|
|
6589
|
+
}
|
|
6590
|
+
if (typeof replyToName !== 'undefined') {
|
|
6591
|
+
payload['replyToName'] = replyToName;
|
|
6592
|
+
}
|
|
6593
|
+
if (typeof replyToEmail !== 'undefined') {
|
|
6594
|
+
payload['replyToEmail'] = replyToEmail;
|
|
6595
|
+
}
|
|
6252
6596
|
if (typeof enabled !== 'undefined') {
|
|
6253
6597
|
payload['enabled'] = enabled;
|
|
6254
6598
|
}
|
|
@@ -6259,30 +6603,41 @@ class Messaging extends Service {
|
|
|
6259
6603
|
});
|
|
6260
6604
|
}
|
|
6261
6605
|
/**
|
|
6262
|
-
* Update
|
|
6606
|
+
* Update SMTP provider
|
|
6263
6607
|
*
|
|
6264
6608
|
*
|
|
6265
6609
|
* @param {string} providerId
|
|
6266
6610
|
* @param {string} name
|
|
6267
|
-
* @param {
|
|
6611
|
+
* @param {string} host
|
|
6612
|
+
* @param {number} port
|
|
6268
6613
|
* @param {string} username
|
|
6269
6614
|
* @param {string} password
|
|
6270
|
-
* @param {
|
|
6615
|
+
* @param {SMTPEncryption} encryption
|
|
6616
|
+
* @param {boolean} autoTLS
|
|
6617
|
+
* @param {string} mailer
|
|
6618
|
+
* @param {string} fromName
|
|
6619
|
+
* @param {string} fromEmail
|
|
6620
|
+
* @param {string} replyToName
|
|
6621
|
+
* @param {string} replyToEmail
|
|
6622
|
+
* @param {boolean} enabled
|
|
6271
6623
|
* @throws {AppwriteException}
|
|
6272
6624
|
* @returns {Promise}
|
|
6273
6625
|
*/
|
|
6274
|
-
|
|
6626
|
+
updateSMTPProvider(providerId, name, host, port, username, password, encryption, autoTLS, mailer, fromName, fromEmail, replyToName, replyToEmail, enabled) {
|
|
6275
6627
|
return __awaiter(this, void 0, void 0, function* () {
|
|
6276
6628
|
if (typeof providerId === 'undefined') {
|
|
6277
6629
|
throw new AppwriteException('Missing required parameter: "providerId"');
|
|
6278
6630
|
}
|
|
6279
|
-
const apiPath = '/messaging/providers/
|
|
6631
|
+
const apiPath = '/messaging/providers/smtp/{providerId}'.replace('{providerId}', providerId);
|
|
6280
6632
|
const payload = {};
|
|
6281
6633
|
if (typeof name !== 'undefined') {
|
|
6282
6634
|
payload['name'] = name;
|
|
6283
6635
|
}
|
|
6284
|
-
if (typeof
|
|
6285
|
-
payload['
|
|
6636
|
+
if (typeof host !== 'undefined') {
|
|
6637
|
+
payload['host'] = host;
|
|
6638
|
+
}
|
|
6639
|
+
if (typeof port !== 'undefined') {
|
|
6640
|
+
payload['port'] = port;
|
|
6286
6641
|
}
|
|
6287
6642
|
if (typeof username !== 'undefined') {
|
|
6288
6643
|
payload['username'] = username;
|
|
@@ -6290,6 +6645,115 @@ class Messaging extends Service {
|
|
|
6290
6645
|
if (typeof password !== 'undefined') {
|
|
6291
6646
|
payload['password'] = password;
|
|
6292
6647
|
}
|
|
6648
|
+
if (typeof encryption !== 'undefined') {
|
|
6649
|
+
payload['encryption'] = encryption;
|
|
6650
|
+
}
|
|
6651
|
+
if (typeof autoTLS !== 'undefined') {
|
|
6652
|
+
payload['autoTLS'] = autoTLS;
|
|
6653
|
+
}
|
|
6654
|
+
if (typeof mailer !== 'undefined') {
|
|
6655
|
+
payload['mailer'] = mailer;
|
|
6656
|
+
}
|
|
6657
|
+
if (typeof fromName !== 'undefined') {
|
|
6658
|
+
payload['fromName'] = fromName;
|
|
6659
|
+
}
|
|
6660
|
+
if (typeof fromEmail !== 'undefined') {
|
|
6661
|
+
payload['fromEmail'] = fromEmail;
|
|
6662
|
+
}
|
|
6663
|
+
if (typeof replyToName !== 'undefined') {
|
|
6664
|
+
payload['replyToName'] = replyToName;
|
|
6665
|
+
}
|
|
6666
|
+
if (typeof replyToEmail !== 'undefined') {
|
|
6667
|
+
payload['replyToEmail'] = replyToEmail;
|
|
6668
|
+
}
|
|
6669
|
+
if (typeof enabled !== 'undefined') {
|
|
6670
|
+
payload['enabled'] = enabled;
|
|
6671
|
+
}
|
|
6672
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
6673
|
+
return yield this.client.call('patch', uri, {
|
|
6674
|
+
'content-type': 'application/json',
|
|
6675
|
+
}, payload);
|
|
6676
|
+
});
|
|
6677
|
+
}
|
|
6678
|
+
/**
|
|
6679
|
+
* Create Telesign provider
|
|
6680
|
+
*
|
|
6681
|
+
*
|
|
6682
|
+
* @param {string} providerId
|
|
6683
|
+
* @param {string} name
|
|
6684
|
+
* @param {string} from
|
|
6685
|
+
* @param {string} customerId
|
|
6686
|
+
* @param {string} apiKey
|
|
6687
|
+
* @param {boolean} enabled
|
|
6688
|
+
* @throws {AppwriteException}
|
|
6689
|
+
* @returns {Promise}
|
|
6690
|
+
*/
|
|
6691
|
+
createTelesignProvider(providerId, name, from, customerId, apiKey, enabled) {
|
|
6692
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
6693
|
+
if (typeof providerId === 'undefined') {
|
|
6694
|
+
throw new AppwriteException('Missing required parameter: "providerId"');
|
|
6695
|
+
}
|
|
6696
|
+
if (typeof name === 'undefined') {
|
|
6697
|
+
throw new AppwriteException('Missing required parameter: "name"');
|
|
6698
|
+
}
|
|
6699
|
+
const apiPath = '/messaging/providers/telesign';
|
|
6700
|
+
const payload = {};
|
|
6701
|
+
if (typeof providerId !== 'undefined') {
|
|
6702
|
+
payload['providerId'] = providerId;
|
|
6703
|
+
}
|
|
6704
|
+
if (typeof name !== 'undefined') {
|
|
6705
|
+
payload['name'] = name;
|
|
6706
|
+
}
|
|
6707
|
+
if (typeof from !== 'undefined') {
|
|
6708
|
+
payload['from'] = from;
|
|
6709
|
+
}
|
|
6710
|
+
if (typeof customerId !== 'undefined') {
|
|
6711
|
+
payload['customerId'] = customerId;
|
|
6712
|
+
}
|
|
6713
|
+
if (typeof apiKey !== 'undefined') {
|
|
6714
|
+
payload['apiKey'] = apiKey;
|
|
6715
|
+
}
|
|
6716
|
+
if (typeof enabled !== 'undefined') {
|
|
6717
|
+
payload['enabled'] = enabled;
|
|
6718
|
+
}
|
|
6719
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
6720
|
+
return yield this.client.call('post', uri, {
|
|
6721
|
+
'content-type': 'application/json',
|
|
6722
|
+
}, payload);
|
|
6723
|
+
});
|
|
6724
|
+
}
|
|
6725
|
+
/**
|
|
6726
|
+
* Update Telesign provider
|
|
6727
|
+
*
|
|
6728
|
+
*
|
|
6729
|
+
* @param {string} providerId
|
|
6730
|
+
* @param {string} name
|
|
6731
|
+
* @param {boolean} enabled
|
|
6732
|
+
* @param {string} customerId
|
|
6733
|
+
* @param {string} apiKey
|
|
6734
|
+
* @param {string} from
|
|
6735
|
+
* @throws {AppwriteException}
|
|
6736
|
+
* @returns {Promise}
|
|
6737
|
+
*/
|
|
6738
|
+
updateTelesignProvider(providerId, name, enabled, customerId, apiKey, from) {
|
|
6739
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
6740
|
+
if (typeof providerId === 'undefined') {
|
|
6741
|
+
throw new AppwriteException('Missing required parameter: "providerId"');
|
|
6742
|
+
}
|
|
6743
|
+
const apiPath = '/messaging/providers/telesign/{providerId}'.replace('{providerId}', providerId);
|
|
6744
|
+
const payload = {};
|
|
6745
|
+
if (typeof name !== 'undefined') {
|
|
6746
|
+
payload['name'] = name;
|
|
6747
|
+
}
|
|
6748
|
+
if (typeof enabled !== 'undefined') {
|
|
6749
|
+
payload['enabled'] = enabled;
|
|
6750
|
+
}
|
|
6751
|
+
if (typeof customerId !== 'undefined') {
|
|
6752
|
+
payload['customerId'] = customerId;
|
|
6753
|
+
}
|
|
6754
|
+
if (typeof apiKey !== 'undefined') {
|
|
6755
|
+
payload['apiKey'] = apiKey;
|
|
6756
|
+
}
|
|
6293
6757
|
if (typeof from !== 'undefined') {
|
|
6294
6758
|
payload['from'] = from;
|
|
6295
6759
|
}
|
|
@@ -6659,7 +7123,7 @@ class Messaging extends Service {
|
|
|
6659
7123
|
* List topics.
|
|
6660
7124
|
*
|
|
6661
7125
|
*
|
|
6662
|
-
* @param {string} queries
|
|
7126
|
+
* @param {string[]} queries
|
|
6663
7127
|
* @param {string} search
|
|
6664
7128
|
* @throws {AppwriteException}
|
|
6665
7129
|
* @returns {Promise}
|
|
@@ -6686,11 +7150,11 @@ class Messaging extends Service {
|
|
|
6686
7150
|
*
|
|
6687
7151
|
* @param {string} topicId
|
|
6688
7152
|
* @param {string} name
|
|
6689
|
-
* @param {string}
|
|
7153
|
+
* @param {string[]} subscribe
|
|
6690
7154
|
* @throws {AppwriteException}
|
|
6691
7155
|
* @returns {Promise}
|
|
6692
7156
|
*/
|
|
6693
|
-
createTopic(topicId, name,
|
|
7157
|
+
createTopic(topicId, name, subscribe) {
|
|
6694
7158
|
return __awaiter(this, void 0, void 0, function* () {
|
|
6695
7159
|
if (typeof topicId === 'undefined') {
|
|
6696
7160
|
throw new AppwriteException('Missing required parameter: "topicId"');
|
|
@@ -6706,8 +7170,8 @@ class Messaging extends Service {
|
|
|
6706
7170
|
if (typeof name !== 'undefined') {
|
|
6707
7171
|
payload['name'] = name;
|
|
6708
7172
|
}
|
|
6709
|
-
if (typeof
|
|
6710
|
-
payload['
|
|
7173
|
+
if (typeof subscribe !== 'undefined') {
|
|
7174
|
+
payload['subscribe'] = subscribe;
|
|
6711
7175
|
}
|
|
6712
7176
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
6713
7177
|
return yield this.client.call('post', uri, {
|
|
@@ -6742,11 +7206,10 @@ class Messaging extends Service {
|
|
|
6742
7206
|
*
|
|
6743
7207
|
* @param {string} topicId
|
|
6744
7208
|
* @param {string} name
|
|
6745
|
-
* @param {string} description
|
|
6746
7209
|
* @throws {AppwriteException}
|
|
6747
7210
|
* @returns {Promise}
|
|
6748
7211
|
*/
|
|
6749
|
-
updateTopic(topicId, name
|
|
7212
|
+
updateTopic(topicId, name) {
|
|
6750
7213
|
return __awaiter(this, void 0, void 0, function* () {
|
|
6751
7214
|
if (typeof topicId === 'undefined') {
|
|
6752
7215
|
throw new AppwriteException('Missing required parameter: "topicId"');
|
|
@@ -6756,9 +7219,6 @@ class Messaging extends Service {
|
|
|
6756
7219
|
if (typeof name !== 'undefined') {
|
|
6757
7220
|
payload['name'] = name;
|
|
6758
7221
|
}
|
|
6759
|
-
if (typeof description !== 'undefined') {
|
|
6760
|
-
payload['description'] = description;
|
|
6761
|
-
}
|
|
6762
7222
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
6763
7223
|
return yield this.client.call('patch', uri, {
|
|
6764
7224
|
'content-type': 'application/json',
|
|
@@ -6816,7 +7276,7 @@ class Messaging extends Service {
|
|
|
6816
7276
|
*
|
|
6817
7277
|
*
|
|
6818
7278
|
* @param {string} topicId
|
|
6819
|
-
* @param {string} queries
|
|
7279
|
+
* @param {string[]} queries
|
|
6820
7280
|
* @param {string} search
|
|
6821
7281
|
* @throws {AppwriteException}
|
|
6822
7282
|
* @returns {Promise}
|
|
@@ -6935,7 +7395,7 @@ class Migrations extends Service {
|
|
|
6935
7395
|
* List Migrations
|
|
6936
7396
|
*
|
|
6937
7397
|
*
|
|
6938
|
-
* @param {string} queries
|
|
7398
|
+
* @param {string[]} queries
|
|
6939
7399
|
* @param {string} search
|
|
6940
7400
|
* @throws {AppwriteException}
|
|
6941
7401
|
* @returns {Promise}
|
|
@@ -7543,16 +8003,30 @@ class Project extends Service {
|
|
|
7543
8003
|
* Get usage stats for a project
|
|
7544
8004
|
*
|
|
7545
8005
|
*
|
|
7546
|
-
* @param {string}
|
|
8006
|
+
* @param {string} startDate
|
|
8007
|
+
* @param {string} endDate
|
|
8008
|
+
* @param {ProjectUsageRange} period
|
|
7547
8009
|
* @throws {AppwriteException}
|
|
7548
8010
|
* @returns {Promise}
|
|
7549
8011
|
*/
|
|
7550
|
-
getUsage(
|
|
8012
|
+
getUsage(startDate, endDate, period) {
|
|
7551
8013
|
return __awaiter(this, void 0, void 0, function* () {
|
|
8014
|
+
if (typeof startDate === 'undefined') {
|
|
8015
|
+
throw new AppwriteException('Missing required parameter: "startDate"');
|
|
8016
|
+
}
|
|
8017
|
+
if (typeof endDate === 'undefined') {
|
|
8018
|
+
throw new AppwriteException('Missing required parameter: "endDate"');
|
|
8019
|
+
}
|
|
7552
8020
|
const apiPath = '/project/usage';
|
|
7553
8021
|
const payload = {};
|
|
7554
|
-
if (typeof
|
|
7555
|
-
payload['
|
|
8022
|
+
if (typeof startDate !== 'undefined') {
|
|
8023
|
+
payload['startDate'] = startDate;
|
|
8024
|
+
}
|
|
8025
|
+
if (typeof endDate !== 'undefined') {
|
|
8026
|
+
payload['endDate'] = endDate;
|
|
8027
|
+
}
|
|
8028
|
+
if (typeof period !== 'undefined') {
|
|
8029
|
+
payload['period'] = period;
|
|
7556
8030
|
}
|
|
7557
8031
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
7558
8032
|
return yield this.client.call('get', uri, {
|
|
@@ -7728,7 +8202,7 @@ class Projects extends Service {
|
|
|
7728
8202
|
* @param {string} projectId
|
|
7729
8203
|
* @param {string} name
|
|
7730
8204
|
* @param {string} teamId
|
|
7731
|
-
* @param {
|
|
8205
|
+
* @param {Region} region
|
|
7732
8206
|
* @param {string} description
|
|
7733
8207
|
* @param {string} logo
|
|
7734
8208
|
* @param {string} url
|
|
@@ -7924,36 +8398,8 @@ class Projects extends Service {
|
|
|
7924
8398
|
}
|
|
7925
8399
|
const apiPath = '/projects/{projectId}/auth/duration'.replace('{projectId}', projectId);
|
|
7926
8400
|
const payload = {};
|
|
7927
|
-
if (typeof duration !== 'undefined') {
|
|
7928
|
-
payload['duration'] = duration;
|
|
7929
|
-
}
|
|
7930
|
-
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
7931
|
-
return yield this.client.call('patch', uri, {
|
|
7932
|
-
'content-type': 'application/json',
|
|
7933
|
-
}, payload);
|
|
7934
|
-
});
|
|
7935
|
-
}
|
|
7936
|
-
/**
|
|
7937
|
-
* Update project users limit
|
|
7938
|
-
*
|
|
7939
|
-
*
|
|
7940
|
-
* @param {string} projectId
|
|
7941
|
-
* @param {number} limit
|
|
7942
|
-
* @throws {AppwriteException}
|
|
7943
|
-
* @returns {Promise}
|
|
7944
|
-
*/
|
|
7945
|
-
updateAuthLimit(projectId, limit) {
|
|
7946
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
7947
|
-
if (typeof projectId === 'undefined') {
|
|
7948
|
-
throw new AppwriteException('Missing required parameter: "projectId"');
|
|
7949
|
-
}
|
|
7950
|
-
if (typeof limit === 'undefined') {
|
|
7951
|
-
throw new AppwriteException('Missing required parameter: "limit"');
|
|
7952
|
-
}
|
|
7953
|
-
const apiPath = '/projects/{projectId}/auth/limit'.replace('{projectId}', projectId);
|
|
7954
|
-
const payload = {};
|
|
7955
|
-
if (typeof limit !== 'undefined') {
|
|
7956
|
-
payload['limit'] = limit;
|
|
8401
|
+
if (typeof duration !== 'undefined') {
|
|
8402
|
+
payload['duration'] = duration;
|
|
7957
8403
|
}
|
|
7958
8404
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
7959
8405
|
return yield this.client.call('patch', uri, {
|
|
@@ -7962,7 +8408,7 @@ class Projects extends Service {
|
|
|
7962
8408
|
});
|
|
7963
8409
|
}
|
|
7964
8410
|
/**
|
|
7965
|
-
* Update project
|
|
8411
|
+
* Update project users limit
|
|
7966
8412
|
*
|
|
7967
8413
|
*
|
|
7968
8414
|
* @param {string} projectId
|
|
@@ -7970,7 +8416,7 @@ class Projects extends Service {
|
|
|
7970
8416
|
* @throws {AppwriteException}
|
|
7971
8417
|
* @returns {Promise}
|
|
7972
8418
|
*/
|
|
7973
|
-
|
|
8419
|
+
updateAuthLimit(projectId, limit) {
|
|
7974
8420
|
return __awaiter(this, void 0, void 0, function* () {
|
|
7975
8421
|
if (typeof projectId === 'undefined') {
|
|
7976
8422
|
throw new AppwriteException('Missing required parameter: "projectId"');
|
|
@@ -7978,7 +8424,7 @@ class Projects extends Service {
|
|
|
7978
8424
|
if (typeof limit === 'undefined') {
|
|
7979
8425
|
throw new AppwriteException('Missing required parameter: "limit"');
|
|
7980
8426
|
}
|
|
7981
|
-
const apiPath = '/projects/{projectId}/auth/
|
|
8427
|
+
const apiPath = '/projects/{projectId}/auth/limit'.replace('{projectId}', projectId);
|
|
7982
8428
|
const payload = {};
|
|
7983
8429
|
if (typeof limit !== 'undefined') {
|
|
7984
8430
|
payload['limit'] = limit;
|
|
@@ -7990,26 +8436,26 @@ class Projects extends Service {
|
|
|
7990
8436
|
});
|
|
7991
8437
|
}
|
|
7992
8438
|
/**
|
|
7993
|
-
* Update
|
|
8439
|
+
* Update project user sessions limit
|
|
7994
8440
|
*
|
|
7995
8441
|
*
|
|
7996
8442
|
* @param {string} projectId
|
|
7997
|
-
* @param {number}
|
|
8443
|
+
* @param {number} limit
|
|
7998
8444
|
* @throws {AppwriteException}
|
|
7999
8445
|
* @returns {Promise}
|
|
8000
8446
|
*/
|
|
8001
|
-
|
|
8447
|
+
updateAuthSessionsLimit(projectId, limit) {
|
|
8002
8448
|
return __awaiter(this, void 0, void 0, function* () {
|
|
8003
8449
|
if (typeof projectId === 'undefined') {
|
|
8004
8450
|
throw new AppwriteException('Missing required parameter: "projectId"');
|
|
8005
8451
|
}
|
|
8006
|
-
if (typeof
|
|
8007
|
-
throw new AppwriteException('Missing required parameter: "
|
|
8452
|
+
if (typeof limit === 'undefined') {
|
|
8453
|
+
throw new AppwriteException('Missing required parameter: "limit"');
|
|
8008
8454
|
}
|
|
8009
|
-
const apiPath = '/projects/{projectId}/auth/
|
|
8455
|
+
const apiPath = '/projects/{projectId}/auth/max-sessions'.replace('{projectId}', projectId);
|
|
8010
8456
|
const payload = {};
|
|
8011
|
-
if (typeof
|
|
8012
|
-
payload['
|
|
8457
|
+
if (typeof limit !== 'undefined') {
|
|
8458
|
+
payload['limit'] = limit;
|
|
8013
8459
|
}
|
|
8014
8460
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
8015
8461
|
return yield this.client.call('patch', uri, {
|
|
@@ -8106,7 +8552,7 @@ class Projects extends Service {
|
|
|
8106
8552
|
*
|
|
8107
8553
|
*
|
|
8108
8554
|
* @param {string} projectId
|
|
8109
|
-
* @param {
|
|
8555
|
+
* @param {AuthMethod} method
|
|
8110
8556
|
* @param {boolean} status
|
|
8111
8557
|
* @throws {AppwriteException}
|
|
8112
8558
|
* @returns {Promise}
|
|
@@ -8291,7 +8737,7 @@ class Projects extends Service {
|
|
|
8291
8737
|
*
|
|
8292
8738
|
*
|
|
8293
8739
|
* @param {string} projectId
|
|
8294
|
-
* @param {
|
|
8740
|
+
* @param {OAuthProvider} provider
|
|
8295
8741
|
* @param {string} appId
|
|
8296
8742
|
* @param {string} secret
|
|
8297
8743
|
* @param {boolean} enabled
|
|
@@ -8352,7 +8798,7 @@ class Projects extends Service {
|
|
|
8352
8798
|
*
|
|
8353
8799
|
*
|
|
8354
8800
|
* @param {string} projectId
|
|
8355
|
-
* @param {
|
|
8801
|
+
* @param {PlatformType} type
|
|
8356
8802
|
* @param {string} name
|
|
8357
8803
|
* @param {string} key
|
|
8358
8804
|
* @param {string} store
|
|
@@ -8493,7 +8939,7 @@ class Projects extends Service {
|
|
|
8493
8939
|
*
|
|
8494
8940
|
*
|
|
8495
8941
|
* @param {string} projectId
|
|
8496
|
-
* @param {
|
|
8942
|
+
* @param {APIService} service
|
|
8497
8943
|
* @param {boolean} status
|
|
8498
8944
|
* @throws {AppwriteException}
|
|
8499
8945
|
* @returns {Promise}
|
|
@@ -8552,7 +8998,7 @@ class Projects extends Service {
|
|
|
8552
8998
|
});
|
|
8553
8999
|
}
|
|
8554
9000
|
/**
|
|
8555
|
-
* Update SMTP
|
|
9001
|
+
* Update SMTP
|
|
8556
9002
|
*
|
|
8557
9003
|
*
|
|
8558
9004
|
* @param {string} projectId
|
|
@@ -8564,11 +9010,11 @@ class Projects extends Service {
|
|
|
8564
9010
|
* @param {number} port
|
|
8565
9011
|
* @param {string} username
|
|
8566
9012
|
* @param {string} password
|
|
8567
|
-
* @param {
|
|
9013
|
+
* @param {SMTPSecure} secure
|
|
8568
9014
|
* @throws {AppwriteException}
|
|
8569
9015
|
* @returns {Promise}
|
|
8570
9016
|
*/
|
|
8571
|
-
|
|
9017
|
+
updateSmtp(projectId, enabled, senderName, senderEmail, replyTo, host, port, username, password, secure) {
|
|
8572
9018
|
return __awaiter(this, void 0, void 0, function* () {
|
|
8573
9019
|
if (typeof projectId === 'undefined') {
|
|
8574
9020
|
throw new AppwriteException('Missing required parameter: "projectId"');
|
|
@@ -8611,6 +9057,75 @@ class Projects extends Service {
|
|
|
8611
9057
|
}, payload);
|
|
8612
9058
|
});
|
|
8613
9059
|
}
|
|
9060
|
+
/**
|
|
9061
|
+
* Create SMTP test
|
|
9062
|
+
*
|
|
9063
|
+
*
|
|
9064
|
+
* @param {string} projectId
|
|
9065
|
+
* @param {string[]} emails
|
|
9066
|
+
* @param {string} senderName
|
|
9067
|
+
* @param {string} senderEmail
|
|
9068
|
+
* @param {string} host
|
|
9069
|
+
* @param {string} replyTo
|
|
9070
|
+
* @param {number} port
|
|
9071
|
+
* @param {string} username
|
|
9072
|
+
* @param {string} password
|
|
9073
|
+
* @param {SMTPSecure} secure
|
|
9074
|
+
* @throws {AppwriteException}
|
|
9075
|
+
* @returns {Promise}
|
|
9076
|
+
*/
|
|
9077
|
+
createSmtpTest(projectId, emails, senderName, senderEmail, host, replyTo, port, username, password, secure) {
|
|
9078
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
9079
|
+
if (typeof projectId === 'undefined') {
|
|
9080
|
+
throw new AppwriteException('Missing required parameter: "projectId"');
|
|
9081
|
+
}
|
|
9082
|
+
if (typeof emails === 'undefined') {
|
|
9083
|
+
throw new AppwriteException('Missing required parameter: "emails"');
|
|
9084
|
+
}
|
|
9085
|
+
if (typeof senderName === 'undefined') {
|
|
9086
|
+
throw new AppwriteException('Missing required parameter: "senderName"');
|
|
9087
|
+
}
|
|
9088
|
+
if (typeof senderEmail === 'undefined') {
|
|
9089
|
+
throw new AppwriteException('Missing required parameter: "senderEmail"');
|
|
9090
|
+
}
|
|
9091
|
+
if (typeof host === 'undefined') {
|
|
9092
|
+
throw new AppwriteException('Missing required parameter: "host"');
|
|
9093
|
+
}
|
|
9094
|
+
const apiPath = '/projects/{projectId}/smtp/tests'.replace('{projectId}', projectId);
|
|
9095
|
+
const payload = {};
|
|
9096
|
+
if (typeof emails !== 'undefined') {
|
|
9097
|
+
payload['emails'] = emails;
|
|
9098
|
+
}
|
|
9099
|
+
if (typeof senderName !== 'undefined') {
|
|
9100
|
+
payload['senderName'] = senderName;
|
|
9101
|
+
}
|
|
9102
|
+
if (typeof senderEmail !== 'undefined') {
|
|
9103
|
+
payload['senderEmail'] = senderEmail;
|
|
9104
|
+
}
|
|
9105
|
+
if (typeof replyTo !== 'undefined') {
|
|
9106
|
+
payload['replyTo'] = replyTo;
|
|
9107
|
+
}
|
|
9108
|
+
if (typeof host !== 'undefined') {
|
|
9109
|
+
payload['host'] = host;
|
|
9110
|
+
}
|
|
9111
|
+
if (typeof port !== 'undefined') {
|
|
9112
|
+
payload['port'] = port;
|
|
9113
|
+
}
|
|
9114
|
+
if (typeof username !== 'undefined') {
|
|
9115
|
+
payload['username'] = username;
|
|
9116
|
+
}
|
|
9117
|
+
if (typeof password !== 'undefined') {
|
|
9118
|
+
payload['password'] = password;
|
|
9119
|
+
}
|
|
9120
|
+
if (typeof secure !== 'undefined') {
|
|
9121
|
+
payload['secure'] = secure;
|
|
9122
|
+
}
|
|
9123
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
9124
|
+
return yield this.client.call('post', uri, {
|
|
9125
|
+
'content-type': 'application/json',
|
|
9126
|
+
}, payload);
|
|
9127
|
+
});
|
|
9128
|
+
}
|
|
8614
9129
|
/**
|
|
8615
9130
|
* Update Project Team
|
|
8616
9131
|
*
|
|
@@ -8644,8 +9159,8 @@ class Projects extends Service {
|
|
|
8644
9159
|
*
|
|
8645
9160
|
*
|
|
8646
9161
|
* @param {string} projectId
|
|
8647
|
-
* @param {
|
|
8648
|
-
* @param {
|
|
9162
|
+
* @param {EmailTemplateType} type
|
|
9163
|
+
* @param {EmailTemplateLocale} locale
|
|
8649
9164
|
* @throws {AppwriteException}
|
|
8650
9165
|
* @returns {Promise}
|
|
8651
9166
|
*/
|
|
@@ -8673,8 +9188,8 @@ class Projects extends Service {
|
|
|
8673
9188
|
*
|
|
8674
9189
|
*
|
|
8675
9190
|
* @param {string} projectId
|
|
8676
|
-
* @param {
|
|
8677
|
-
* @param {
|
|
9191
|
+
* @param {EmailTemplateType} type
|
|
9192
|
+
* @param {EmailTemplateLocale} locale
|
|
8678
9193
|
* @param {string} subject
|
|
8679
9194
|
* @param {string} message
|
|
8680
9195
|
* @param {string} senderName
|
|
@@ -8728,8 +9243,8 @@ class Projects extends Service {
|
|
|
8728
9243
|
*
|
|
8729
9244
|
*
|
|
8730
9245
|
* @param {string} projectId
|
|
8731
|
-
* @param {
|
|
8732
|
-
* @param {
|
|
9246
|
+
* @param {EmailTemplateType} type
|
|
9247
|
+
* @param {EmailTemplateLocale} locale
|
|
8733
9248
|
* @throws {AppwriteException}
|
|
8734
9249
|
* @returns {Promise}
|
|
8735
9250
|
*/
|
|
@@ -8757,8 +9272,8 @@ class Projects extends Service {
|
|
|
8757
9272
|
*
|
|
8758
9273
|
*
|
|
8759
9274
|
* @param {string} projectId
|
|
8760
|
-
* @param {
|
|
8761
|
-
* @param {
|
|
9275
|
+
* @param {SMSTemplateType} type
|
|
9276
|
+
* @param {SMSTemplateLocale} locale
|
|
8762
9277
|
* @throws {AppwriteException}
|
|
8763
9278
|
* @returns {Promise}
|
|
8764
9279
|
*/
|
|
@@ -8786,8 +9301,8 @@ class Projects extends Service {
|
|
|
8786
9301
|
*
|
|
8787
9302
|
*
|
|
8788
9303
|
* @param {string} projectId
|
|
8789
|
-
* @param {
|
|
8790
|
-
* @param {
|
|
9304
|
+
* @param {SMSTemplateType} type
|
|
9305
|
+
* @param {SMSTemplateLocale} locale
|
|
8791
9306
|
* @param {string} message
|
|
8792
9307
|
* @throws {AppwriteException}
|
|
8793
9308
|
* @returns {Promise}
|
|
@@ -8822,8 +9337,8 @@ class Projects extends Service {
|
|
|
8822
9337
|
*
|
|
8823
9338
|
*
|
|
8824
9339
|
* @param {string} projectId
|
|
8825
|
-
* @param {
|
|
8826
|
-
* @param {
|
|
9340
|
+
* @param {SMSTemplateType} type
|
|
9341
|
+
* @param {SMSTemplateLocale} locale
|
|
8827
9342
|
* @throws {AppwriteException}
|
|
8828
9343
|
* @returns {Promise}
|
|
8829
9344
|
*/
|
|
@@ -8846,31 +9361,6 @@ class Projects extends Service {
|
|
|
8846
9361
|
}, payload);
|
|
8847
9362
|
});
|
|
8848
9363
|
}
|
|
8849
|
-
/**
|
|
8850
|
-
* Get usage stats for a project
|
|
8851
|
-
*
|
|
8852
|
-
*
|
|
8853
|
-
* @param {string} projectId
|
|
8854
|
-
* @param {string} range
|
|
8855
|
-
* @throws {AppwriteException}
|
|
8856
|
-
* @returns {Promise}
|
|
8857
|
-
*/
|
|
8858
|
-
getUsage(projectId, range) {
|
|
8859
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
8860
|
-
if (typeof projectId === 'undefined') {
|
|
8861
|
-
throw new AppwriteException('Missing required parameter: "projectId"');
|
|
8862
|
-
}
|
|
8863
|
-
const apiPath = '/projects/{projectId}/usage'.replace('{projectId}', projectId);
|
|
8864
|
-
const payload = {};
|
|
8865
|
-
if (typeof range !== 'undefined') {
|
|
8866
|
-
payload['range'] = range;
|
|
8867
|
-
}
|
|
8868
|
-
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
8869
|
-
return yield this.client.call('get', uri, {
|
|
8870
|
-
'content-type': 'application/json',
|
|
8871
|
-
}, payload);
|
|
8872
|
-
});
|
|
8873
|
-
}
|
|
8874
9364
|
/**
|
|
8875
9365
|
* List webhooks
|
|
8876
9366
|
*
|
|
@@ -8901,12 +9391,13 @@ class Projects extends Service {
|
|
|
8901
9391
|
* @param {string[]} events
|
|
8902
9392
|
* @param {string} url
|
|
8903
9393
|
* @param {boolean} security
|
|
9394
|
+
* @param {boolean} enabled
|
|
8904
9395
|
* @param {string} httpUser
|
|
8905
9396
|
* @param {string} httpPass
|
|
8906
9397
|
* @throws {AppwriteException}
|
|
8907
9398
|
* @returns {Promise}
|
|
8908
9399
|
*/
|
|
8909
|
-
createWebhook(projectId, name, events, url, security, httpUser, httpPass) {
|
|
9400
|
+
createWebhook(projectId, name, events, url, security, enabled, httpUser, httpPass) {
|
|
8910
9401
|
return __awaiter(this, void 0, void 0, function* () {
|
|
8911
9402
|
if (typeof projectId === 'undefined') {
|
|
8912
9403
|
throw new AppwriteException('Missing required parameter: "projectId"');
|
|
@@ -8928,6 +9419,9 @@ class Projects extends Service {
|
|
|
8928
9419
|
if (typeof name !== 'undefined') {
|
|
8929
9420
|
payload['name'] = name;
|
|
8930
9421
|
}
|
|
9422
|
+
if (typeof enabled !== 'undefined') {
|
|
9423
|
+
payload['enabled'] = enabled;
|
|
9424
|
+
}
|
|
8931
9425
|
if (typeof events !== 'undefined') {
|
|
8932
9426
|
payload['events'] = events;
|
|
8933
9427
|
}
|
|
@@ -8984,12 +9478,13 @@ class Projects extends Service {
|
|
|
8984
9478
|
* @param {string[]} events
|
|
8985
9479
|
* @param {string} url
|
|
8986
9480
|
* @param {boolean} security
|
|
9481
|
+
* @param {boolean} enabled
|
|
8987
9482
|
* @param {string} httpUser
|
|
8988
9483
|
* @param {string} httpPass
|
|
8989
9484
|
* @throws {AppwriteException}
|
|
8990
9485
|
* @returns {Promise}
|
|
8991
9486
|
*/
|
|
8992
|
-
updateWebhook(projectId, webhookId, name, events, url, security, httpUser, httpPass) {
|
|
9487
|
+
updateWebhook(projectId, webhookId, name, events, url, security, enabled, httpUser, httpPass) {
|
|
8993
9488
|
return __awaiter(this, void 0, void 0, function* () {
|
|
8994
9489
|
if (typeof projectId === 'undefined') {
|
|
8995
9490
|
throw new AppwriteException('Missing required parameter: "projectId"');
|
|
@@ -9014,6 +9509,9 @@ class Projects extends Service {
|
|
|
9014
9509
|
if (typeof name !== 'undefined') {
|
|
9015
9510
|
payload['name'] = name;
|
|
9016
9511
|
}
|
|
9512
|
+
if (typeof enabled !== 'undefined') {
|
|
9513
|
+
payload['enabled'] = enabled;
|
|
9514
|
+
}
|
|
9017
9515
|
if (typeof events !== 'undefined') {
|
|
9018
9516
|
payload['events'] = events;
|
|
9019
9517
|
}
|
|
@@ -9124,7 +9622,7 @@ class Proxy extends Service {
|
|
|
9124
9622
|
* Create a new proxy rule.
|
|
9125
9623
|
*
|
|
9126
9624
|
* @param {string} domain
|
|
9127
|
-
* @param {
|
|
9625
|
+
* @param {ResourceType} resourceType
|
|
9128
9626
|
* @param {string} resourceId
|
|
9129
9627
|
* @throws {AppwriteException}
|
|
9130
9628
|
* @returns {Promise}
|
|
@@ -9264,7 +9762,7 @@ class Storage extends Service {
|
|
|
9264
9762
|
* @param {boolean} enabled
|
|
9265
9763
|
* @param {number} maximumFileSize
|
|
9266
9764
|
* @param {string[]} allowedFileExtensions
|
|
9267
|
-
* @param {
|
|
9765
|
+
* @param {Compression} compression
|
|
9268
9766
|
* @param {boolean} encryption
|
|
9269
9767
|
* @param {boolean} antivirus
|
|
9270
9768
|
* @throws {AppwriteException}
|
|
@@ -9351,7 +9849,7 @@ class Storage extends Service {
|
|
|
9351
9849
|
* @param {boolean} enabled
|
|
9352
9850
|
* @param {number} maximumFileSize
|
|
9353
9851
|
* @param {string[]} allowedFileExtensions
|
|
9354
|
-
* @param {
|
|
9852
|
+
* @param {Compression} compression
|
|
9355
9853
|
* @param {boolean} encryption
|
|
9356
9854
|
* @param {boolean} antivirus
|
|
9357
9855
|
* @throws {AppwriteException}
|
|
@@ -9680,7 +10178,7 @@ class Storage extends Service {
|
|
|
9680
10178
|
* @param {string} fileId
|
|
9681
10179
|
* @param {number} width
|
|
9682
10180
|
* @param {number} height
|
|
9683
|
-
* @param {
|
|
10181
|
+
* @param {ImageGravity} gravity
|
|
9684
10182
|
* @param {number} quality
|
|
9685
10183
|
* @param {number} borderWidth
|
|
9686
10184
|
* @param {string} borderColor
|
|
@@ -9688,7 +10186,7 @@ class Storage extends Service {
|
|
|
9688
10186
|
* @param {number} opacity
|
|
9689
10187
|
* @param {number} rotation
|
|
9690
10188
|
* @param {string} background
|
|
9691
|
-
* @param {
|
|
10189
|
+
* @param {ImageFormat} output
|
|
9692
10190
|
* @throws {AppwriteException}
|
|
9693
10191
|
* @returns {URL}
|
|
9694
10192
|
*/
|
|
@@ -9773,7 +10271,7 @@ class Storage extends Service {
|
|
|
9773
10271
|
* Get usage stats for storage
|
|
9774
10272
|
*
|
|
9775
10273
|
*
|
|
9776
|
-
* @param {
|
|
10274
|
+
* @param {StorageUsageRange} range
|
|
9777
10275
|
* @throws {AppwriteException}
|
|
9778
10276
|
* @returns {Promise}
|
|
9779
10277
|
*/
|
|
@@ -9791,11 +10289,11 @@ class Storage extends Service {
|
|
|
9791
10289
|
});
|
|
9792
10290
|
}
|
|
9793
10291
|
/**
|
|
9794
|
-
* Get usage stats for
|
|
10292
|
+
* Get usage stats for storage bucket
|
|
9795
10293
|
*
|
|
9796
10294
|
*
|
|
9797
10295
|
* @param {string} bucketId
|
|
9798
|
-
* @param {
|
|
10296
|
+
* @param {StorageUsageRange} range
|
|
9799
10297
|
* @throws {AppwriteException}
|
|
9800
10298
|
* @returns {Promise}
|
|
9801
10299
|
*/
|
|
@@ -10449,7 +10947,7 @@ class Users extends Service {
|
|
|
10449
10947
|
*
|
|
10450
10948
|
* Get identities for all users.
|
|
10451
10949
|
*
|
|
10452
|
-
* @param {string} queries
|
|
10950
|
+
* @param {string[]} queries
|
|
10453
10951
|
* @param {string} search
|
|
10454
10952
|
* @throws {AppwriteException}
|
|
10455
10953
|
* @returns {Promise}
|
|
@@ -10471,7 +10969,7 @@ class Users extends Service {
|
|
|
10471
10969
|
});
|
|
10472
10970
|
}
|
|
10473
10971
|
/**
|
|
10474
|
-
* Delete
|
|
10972
|
+
* Delete identity
|
|
10475
10973
|
*
|
|
10476
10974
|
* Delete an identity by its unique ID.
|
|
10477
10975
|
*
|
|
@@ -10744,7 +11242,7 @@ class Users extends Service {
|
|
|
10744
11242
|
* @param {string} userId
|
|
10745
11243
|
* @param {string} email
|
|
10746
11244
|
* @param {string} password
|
|
10747
|
-
* @param {
|
|
11245
|
+
* @param {PasswordHash} passwordVersion
|
|
10748
11246
|
* @param {string} name
|
|
10749
11247
|
* @throws {AppwriteException}
|
|
10750
11248
|
* @returns {Promise}
|
|
@@ -10787,21 +11285,17 @@ class Users extends Service {
|
|
|
10787
11285
|
* Get usage stats for the users API
|
|
10788
11286
|
*
|
|
10789
11287
|
*
|
|
10790
|
-
* @param {
|
|
10791
|
-
* @param {string} provider
|
|
11288
|
+
* @param {UserUsageRange} range
|
|
10792
11289
|
* @throws {AppwriteException}
|
|
10793
11290
|
* @returns {Promise}
|
|
10794
11291
|
*/
|
|
10795
|
-
getUsage(range
|
|
11292
|
+
getUsage(range) {
|
|
10796
11293
|
return __awaiter(this, void 0, void 0, function* () {
|
|
10797
11294
|
const apiPath = '/users/usage';
|
|
10798
11295
|
const payload = {};
|
|
10799
11296
|
if (typeof range !== 'undefined') {
|
|
10800
11297
|
payload['range'] = range;
|
|
10801
11298
|
}
|
|
10802
|
-
if (typeof provider !== 'undefined') {
|
|
10803
|
-
payload['provider'] = provider;
|
|
10804
|
-
}
|
|
10805
11299
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
10806
11300
|
return yield this.client.call('get', uri, {
|
|
10807
11301
|
'content-type': 'application/json',
|
|
@@ -10968,6 +11462,87 @@ class Users extends Service {
|
|
|
10968
11462
|
}, payload);
|
|
10969
11463
|
});
|
|
10970
11464
|
}
|
|
11465
|
+
/**
|
|
11466
|
+
* Update MFA
|
|
11467
|
+
*
|
|
11468
|
+
*
|
|
11469
|
+
* @param {string} userId
|
|
11470
|
+
* @param {boolean} mfa
|
|
11471
|
+
* @throws {AppwriteException}
|
|
11472
|
+
* @returns {Promise}
|
|
11473
|
+
*/
|
|
11474
|
+
updateMfa(userId, mfa) {
|
|
11475
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
11476
|
+
if (typeof userId === 'undefined') {
|
|
11477
|
+
throw new AppwriteException('Missing required parameter: "userId"');
|
|
11478
|
+
}
|
|
11479
|
+
if (typeof mfa === 'undefined') {
|
|
11480
|
+
throw new AppwriteException('Missing required parameter: "mfa"');
|
|
11481
|
+
}
|
|
11482
|
+
const apiPath = '/users/{userId}/mfa'.replace('{userId}', userId);
|
|
11483
|
+
const payload = {};
|
|
11484
|
+
if (typeof mfa !== 'undefined') {
|
|
11485
|
+
payload['mfa'] = mfa;
|
|
11486
|
+
}
|
|
11487
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
11488
|
+
return yield this.client.call('patch', uri, {
|
|
11489
|
+
'content-type': 'application/json',
|
|
11490
|
+
}, payload);
|
|
11491
|
+
});
|
|
11492
|
+
}
|
|
11493
|
+
/**
|
|
11494
|
+
* List Factors
|
|
11495
|
+
*
|
|
11496
|
+
*
|
|
11497
|
+
* @param {string} userId
|
|
11498
|
+
* @throws {AppwriteException}
|
|
11499
|
+
* @returns {Promise}
|
|
11500
|
+
*/
|
|
11501
|
+
listFactors(userId) {
|
|
11502
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
11503
|
+
if (typeof userId === 'undefined') {
|
|
11504
|
+
throw new AppwriteException('Missing required parameter: "userId"');
|
|
11505
|
+
}
|
|
11506
|
+
const apiPath = '/users/{userId}/mfa/factors'.replace('{userId}', userId);
|
|
11507
|
+
const payload = {};
|
|
11508
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
11509
|
+
return yield this.client.call('get', uri, {
|
|
11510
|
+
'content-type': 'application/json',
|
|
11511
|
+
}, payload);
|
|
11512
|
+
});
|
|
11513
|
+
}
|
|
11514
|
+
/**
|
|
11515
|
+
* Delete Authenticator
|
|
11516
|
+
*
|
|
11517
|
+
*
|
|
11518
|
+
* @param {string} userId
|
|
11519
|
+
* @param {AuthenticatorType} type
|
|
11520
|
+
* @param {string} otp
|
|
11521
|
+
* @throws {AppwriteException}
|
|
11522
|
+
* @returns {Promise}
|
|
11523
|
+
*/
|
|
11524
|
+
deleteAuthenticator(userId, type, otp) {
|
|
11525
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
11526
|
+
if (typeof userId === 'undefined') {
|
|
11527
|
+
throw new AppwriteException('Missing required parameter: "userId"');
|
|
11528
|
+
}
|
|
11529
|
+
if (typeof type === 'undefined') {
|
|
11530
|
+
throw new AppwriteException('Missing required parameter: "type"');
|
|
11531
|
+
}
|
|
11532
|
+
if (typeof otp === 'undefined') {
|
|
11533
|
+
throw new AppwriteException('Missing required parameter: "otp"');
|
|
11534
|
+
}
|
|
11535
|
+
const apiPath = '/users/{userId}/mfa/{type}'.replace('{userId}', userId).replace('{type}', type);
|
|
11536
|
+
const payload = {};
|
|
11537
|
+
if (typeof otp !== 'undefined') {
|
|
11538
|
+
payload['otp'] = otp;
|
|
11539
|
+
}
|
|
11540
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
11541
|
+
return yield this.client.call('delete', uri, {
|
|
11542
|
+
'content-type': 'application/json',
|
|
11543
|
+
}, payload);
|
|
11544
|
+
});
|
|
11545
|
+
}
|
|
10971
11546
|
/**
|
|
10972
11547
|
* Update name
|
|
10973
11548
|
*
|
|
@@ -11130,6 +11705,33 @@ class Users extends Service {
|
|
|
11130
11705
|
}, payload);
|
|
11131
11706
|
});
|
|
11132
11707
|
}
|
|
11708
|
+
/**
|
|
11709
|
+
* Create session
|
|
11710
|
+
*
|
|
11711
|
+
* Creates a session for a user. Returns an immediately usable session object.
|
|
11712
|
+
*
|
|
11713
|
+
* If you want to generate a token for a custom authentication flow, use the
|
|
11714
|
+
* [POST
|
|
11715
|
+
* /users/{userId}/tokens](https://appwrite.io/docs/server/users#createToken)
|
|
11716
|
+
* endpoint.
|
|
11717
|
+
*
|
|
11718
|
+
* @param {string} userId
|
|
11719
|
+
* @throws {AppwriteException}
|
|
11720
|
+
* @returns {Promise}
|
|
11721
|
+
*/
|
|
11722
|
+
createSession(userId) {
|
|
11723
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
11724
|
+
if (typeof userId === 'undefined') {
|
|
11725
|
+
throw new AppwriteException('Missing required parameter: "userId"');
|
|
11726
|
+
}
|
|
11727
|
+
const apiPath = '/users/{userId}/sessions'.replace('{userId}', userId);
|
|
11728
|
+
const payload = {};
|
|
11729
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
11730
|
+
return yield this.client.call('post', uri, {
|
|
11731
|
+
'content-type': 'application/json',
|
|
11732
|
+
}, payload);
|
|
11733
|
+
});
|
|
11734
|
+
}
|
|
11133
11735
|
/**
|
|
11134
11736
|
* Delete user sessions
|
|
11135
11737
|
*
|
|
@@ -11213,7 +11815,7 @@ class Users extends Service {
|
|
|
11213
11815
|
*
|
|
11214
11816
|
*
|
|
11215
11817
|
* @param {string} userId
|
|
11216
|
-
* @param {string} queries
|
|
11818
|
+
* @param {string[]} queries
|
|
11217
11819
|
* @throws {AppwriteException}
|
|
11218
11820
|
* @returns {Promise}
|
|
11219
11821
|
*/
|
|
@@ -11239,7 +11841,7 @@ class Users extends Service {
|
|
|
11239
11841
|
*
|
|
11240
11842
|
* @param {string} userId
|
|
11241
11843
|
* @param {string} targetId
|
|
11242
|
-
* @param {
|
|
11844
|
+
* @param {MessagingProviderType} providerType
|
|
11243
11845
|
* @param {string} identifier
|
|
11244
11846
|
* @param {string} providerId
|
|
11245
11847
|
* @param {string} name
|
|
@@ -11370,6 +11972,40 @@ class Users extends Service {
|
|
|
11370
11972
|
}, payload);
|
|
11371
11973
|
});
|
|
11372
11974
|
}
|
|
11975
|
+
/**
|
|
11976
|
+
* Create token
|
|
11977
|
+
*
|
|
11978
|
+
* Returns a token with a secret key for creating a session. If the provided
|
|
11979
|
+
* user ID has not be registered, a new user will be created. Use the returned
|
|
11980
|
+
* user ID and secret and submit a request to the [PUT
|
|
11981
|
+
* /account/sessions/custom](https://appwrite.io/docs/references/cloud/client-web/account#updateCustomSession)
|
|
11982
|
+
* endpoint to complete the login process.
|
|
11983
|
+
*
|
|
11984
|
+
* @param {string} userId
|
|
11985
|
+
* @param {number} length
|
|
11986
|
+
* @param {number} expire
|
|
11987
|
+
* @throws {AppwriteException}
|
|
11988
|
+
* @returns {Promise}
|
|
11989
|
+
*/
|
|
11990
|
+
createToken(userId, length, expire) {
|
|
11991
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
11992
|
+
if (typeof userId === 'undefined') {
|
|
11993
|
+
throw new AppwriteException('Missing required parameter: "userId"');
|
|
11994
|
+
}
|
|
11995
|
+
const apiPath = '/users/{userId}/tokens'.replace('{userId}', userId);
|
|
11996
|
+
const payload = {};
|
|
11997
|
+
if (typeof length !== 'undefined') {
|
|
11998
|
+
payload['length'] = length;
|
|
11999
|
+
}
|
|
12000
|
+
if (typeof expire !== 'undefined') {
|
|
12001
|
+
payload['expire'] = expire;
|
|
12002
|
+
}
|
|
12003
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
12004
|
+
return yield this.client.call('post', uri, {
|
|
12005
|
+
'content-type': 'application/json',
|
|
12006
|
+
}, payload);
|
|
12007
|
+
});
|
|
12008
|
+
}
|
|
11373
12009
|
/**
|
|
11374
12010
|
* Update email verification
|
|
11375
12011
|
*
|
|
@@ -11795,6 +12431,797 @@ class ID {
|
|
|
11795
12431
|
}
|
|
11796
12432
|
}
|
|
11797
12433
|
|
|
12434
|
+
exports.AuthenticationFactor = void 0;
|
|
12435
|
+
(function (AuthenticationFactor) {
|
|
12436
|
+
AuthenticationFactor["Totp"] = "totp";
|
|
12437
|
+
AuthenticationFactor["Phone"] = "phone";
|
|
12438
|
+
AuthenticationFactor["Email"] = "email";
|
|
12439
|
+
})(exports.AuthenticationFactor || (exports.AuthenticationFactor = {}));
|
|
12440
|
+
|
|
12441
|
+
exports.AuthenticatorType = void 0;
|
|
12442
|
+
(function (AuthenticatorType) {
|
|
12443
|
+
AuthenticatorType["Totp"] = "totp";
|
|
12444
|
+
})(exports.AuthenticatorType || (exports.AuthenticatorType = {}));
|
|
12445
|
+
|
|
12446
|
+
exports.OAuthProvider = void 0;
|
|
12447
|
+
(function (OAuthProvider) {
|
|
12448
|
+
OAuthProvider["Amazon"] = "amazon";
|
|
12449
|
+
OAuthProvider["Apple"] = "apple";
|
|
12450
|
+
OAuthProvider["Auth0"] = "auth0";
|
|
12451
|
+
OAuthProvider["Authentik"] = "authentik";
|
|
12452
|
+
OAuthProvider["Autodesk"] = "autodesk";
|
|
12453
|
+
OAuthProvider["Bitbucket"] = "bitbucket";
|
|
12454
|
+
OAuthProvider["Bitly"] = "bitly";
|
|
12455
|
+
OAuthProvider["Box"] = "box";
|
|
12456
|
+
OAuthProvider["Dailymotion"] = "dailymotion";
|
|
12457
|
+
OAuthProvider["Discord"] = "discord";
|
|
12458
|
+
OAuthProvider["Disqus"] = "disqus";
|
|
12459
|
+
OAuthProvider["Dropbox"] = "dropbox";
|
|
12460
|
+
OAuthProvider["Etsy"] = "etsy";
|
|
12461
|
+
OAuthProvider["Facebook"] = "facebook";
|
|
12462
|
+
OAuthProvider["Github"] = "github";
|
|
12463
|
+
OAuthProvider["Gitlab"] = "gitlab";
|
|
12464
|
+
OAuthProvider["Google"] = "google";
|
|
12465
|
+
OAuthProvider["Linkedin"] = "linkedin";
|
|
12466
|
+
OAuthProvider["Microsoft"] = "microsoft";
|
|
12467
|
+
OAuthProvider["Notion"] = "notion";
|
|
12468
|
+
OAuthProvider["Oidc"] = "oidc";
|
|
12469
|
+
OAuthProvider["Okta"] = "okta";
|
|
12470
|
+
OAuthProvider["Paypal"] = "paypal";
|
|
12471
|
+
OAuthProvider["PaypalSandbox"] = "paypalSandbox";
|
|
12472
|
+
OAuthProvider["Podio"] = "podio";
|
|
12473
|
+
OAuthProvider["Salesforce"] = "salesforce";
|
|
12474
|
+
OAuthProvider["Slack"] = "slack";
|
|
12475
|
+
OAuthProvider["Spotify"] = "spotify";
|
|
12476
|
+
OAuthProvider["Stripe"] = "stripe";
|
|
12477
|
+
OAuthProvider["Tradeshift"] = "tradeshift";
|
|
12478
|
+
OAuthProvider["TradeshiftBox"] = "tradeshiftBox";
|
|
12479
|
+
OAuthProvider["Twitch"] = "twitch";
|
|
12480
|
+
OAuthProvider["Wordpress"] = "wordpress";
|
|
12481
|
+
OAuthProvider["Yahoo"] = "yahoo";
|
|
12482
|
+
OAuthProvider["Yammer"] = "yammer";
|
|
12483
|
+
OAuthProvider["Yandex"] = "yandex";
|
|
12484
|
+
OAuthProvider["Zoho"] = "zoho";
|
|
12485
|
+
OAuthProvider["Zoom"] = "zoom";
|
|
12486
|
+
OAuthProvider["Mock"] = "mock";
|
|
12487
|
+
})(exports.OAuthProvider || (exports.OAuthProvider = {}));
|
|
12488
|
+
|
|
12489
|
+
exports.Browser = void 0;
|
|
12490
|
+
(function (Browser) {
|
|
12491
|
+
Browser["AvantBrowser"] = "aa";
|
|
12492
|
+
Browser["AndroidWebViewBeta"] = "an";
|
|
12493
|
+
Browser["GoogleChrome"] = "ch";
|
|
12494
|
+
Browser["GoogleChromeIOS"] = "ci";
|
|
12495
|
+
Browser["GoogleChromeMobile"] = "cm";
|
|
12496
|
+
Browser["Chromium"] = "cr";
|
|
12497
|
+
Browser["MozillaFirefox"] = "ff";
|
|
12498
|
+
Browser["Safari"] = "sf";
|
|
12499
|
+
Browser["MobileSafari"] = "mf";
|
|
12500
|
+
Browser["MicrosoftEdge"] = "ps";
|
|
12501
|
+
Browser["MicrosoftEdgeIOS"] = "oi";
|
|
12502
|
+
Browser["OperaMini"] = "om";
|
|
12503
|
+
Browser["Opera"] = "op";
|
|
12504
|
+
Browser["OperaNext"] = "on";
|
|
12505
|
+
})(exports.Browser || (exports.Browser = {}));
|
|
12506
|
+
|
|
12507
|
+
exports.CreditCard = void 0;
|
|
12508
|
+
(function (CreditCard) {
|
|
12509
|
+
CreditCard["AmericanExpress"] = "amex";
|
|
12510
|
+
CreditCard["Argencard"] = "argencard";
|
|
12511
|
+
CreditCard["Cabal"] = "cabal";
|
|
12512
|
+
CreditCard["Consosud"] = "censosud";
|
|
12513
|
+
CreditCard["DinersClub"] = "diners";
|
|
12514
|
+
CreditCard["Discover"] = "discover";
|
|
12515
|
+
CreditCard["Elo"] = "elo";
|
|
12516
|
+
CreditCard["Hipercard"] = "hipercard";
|
|
12517
|
+
CreditCard["JCB"] = "jcb";
|
|
12518
|
+
CreditCard["Mastercard"] = "mastercard";
|
|
12519
|
+
CreditCard["Naranja"] = "naranja";
|
|
12520
|
+
CreditCard["TarjetaShopping"] = "targeta-shopping";
|
|
12521
|
+
CreditCard["UnionChinaPay"] = "union-china-pay";
|
|
12522
|
+
CreditCard["Visa"] = "visa";
|
|
12523
|
+
CreditCard["MIR"] = "mir";
|
|
12524
|
+
CreditCard["Maestro"] = "maestro";
|
|
12525
|
+
})(exports.CreditCard || (exports.CreditCard = {}));
|
|
12526
|
+
|
|
12527
|
+
exports.Flag = void 0;
|
|
12528
|
+
(function (Flag) {
|
|
12529
|
+
Flag["Afghanistan"] = "af";
|
|
12530
|
+
Flag["Angola"] = "ao";
|
|
12531
|
+
Flag["Albania"] = "al";
|
|
12532
|
+
Flag["Andorra"] = "ad";
|
|
12533
|
+
Flag["UnitedArabEmirates"] = "ae";
|
|
12534
|
+
Flag["Argentina"] = "ar";
|
|
12535
|
+
Flag["Armenia"] = "am";
|
|
12536
|
+
Flag["AntiguaAndBarbuda"] = "ag";
|
|
12537
|
+
Flag["Australia"] = "au";
|
|
12538
|
+
Flag["Austria"] = "at";
|
|
12539
|
+
Flag["Azerbaijan"] = "az";
|
|
12540
|
+
Flag["Burundi"] = "bi";
|
|
12541
|
+
Flag["Belgium"] = "be";
|
|
12542
|
+
Flag["Benin"] = "bj";
|
|
12543
|
+
Flag["BurkinaFaso"] = "bf";
|
|
12544
|
+
Flag["Bangladesh"] = "bd";
|
|
12545
|
+
Flag["Bulgaria"] = "bg";
|
|
12546
|
+
Flag["Bahrain"] = "bh";
|
|
12547
|
+
Flag["Bahamas"] = "bs";
|
|
12548
|
+
Flag["BosniaAndHerzegovina"] = "ba";
|
|
12549
|
+
Flag["Belarus"] = "by";
|
|
12550
|
+
Flag["Belize"] = "bz";
|
|
12551
|
+
Flag["Bolivia"] = "bo";
|
|
12552
|
+
Flag["Brazil"] = "br";
|
|
12553
|
+
Flag["Barbados"] = "bb";
|
|
12554
|
+
Flag["BruneiDarussalam"] = "bn";
|
|
12555
|
+
Flag["Bhutan"] = "bt";
|
|
12556
|
+
Flag["Botswana"] = "bw";
|
|
12557
|
+
Flag["CentralAfricanRepublic"] = "cf";
|
|
12558
|
+
Flag["Canada"] = "ca";
|
|
12559
|
+
Flag["Switzerland"] = "ch";
|
|
12560
|
+
Flag["Chile"] = "cl";
|
|
12561
|
+
Flag["China"] = "cn";
|
|
12562
|
+
Flag["CTeDIvoire"] = "ci";
|
|
12563
|
+
Flag["Cameroon"] = "cm";
|
|
12564
|
+
Flag["DemocraticRepublicOfTheCongo"] = "cd";
|
|
12565
|
+
Flag["RepublicOfTheCongo"] = "cg";
|
|
12566
|
+
Flag["Colombia"] = "co";
|
|
12567
|
+
Flag["Comoros"] = "km";
|
|
12568
|
+
Flag["CapeVerde"] = "cv";
|
|
12569
|
+
Flag["CostaRica"] = "cr";
|
|
12570
|
+
Flag["Cuba"] = "cu";
|
|
12571
|
+
Flag["Cyprus"] = "cy";
|
|
12572
|
+
Flag["CzechRepublic"] = "cz";
|
|
12573
|
+
Flag["Germany"] = "de";
|
|
12574
|
+
Flag["Djibouti"] = "dj";
|
|
12575
|
+
Flag["Dominica"] = "dm";
|
|
12576
|
+
Flag["Denmark"] = "dk";
|
|
12577
|
+
Flag["DominicanRepublic"] = "do";
|
|
12578
|
+
Flag["Algeria"] = "dz";
|
|
12579
|
+
Flag["Ecuador"] = "ec";
|
|
12580
|
+
Flag["Egypt"] = "eg";
|
|
12581
|
+
Flag["Eritrea"] = "er";
|
|
12582
|
+
Flag["Spain"] = "es";
|
|
12583
|
+
Flag["Estonia"] = "ee";
|
|
12584
|
+
Flag["Ethiopia"] = "et";
|
|
12585
|
+
Flag["Finland"] = "fi";
|
|
12586
|
+
Flag["Fiji"] = "fj";
|
|
12587
|
+
Flag["France"] = "fr";
|
|
12588
|
+
Flag["MicronesiaFederatedStatesOf"] = "fm";
|
|
12589
|
+
Flag["Gabon"] = "ga";
|
|
12590
|
+
Flag["UnitedKingdom"] = "gb";
|
|
12591
|
+
Flag["Georgia"] = "ge";
|
|
12592
|
+
Flag["Ghana"] = "gh";
|
|
12593
|
+
Flag["Guinea"] = "gn";
|
|
12594
|
+
Flag["Gambia"] = "gm";
|
|
12595
|
+
Flag["GuineaBissau"] = "gw";
|
|
12596
|
+
Flag["EquatorialGuinea"] = "gq";
|
|
12597
|
+
Flag["Greece"] = "gr";
|
|
12598
|
+
Flag["Grenada"] = "gd";
|
|
12599
|
+
Flag["Guatemala"] = "gt";
|
|
12600
|
+
Flag["Guyana"] = "gy";
|
|
12601
|
+
Flag["Honduras"] = "hn";
|
|
12602
|
+
Flag["Croatia"] = "hr";
|
|
12603
|
+
Flag["Haiti"] = "ht";
|
|
12604
|
+
Flag["Hungary"] = "hu";
|
|
12605
|
+
Flag["Indonesia"] = "id";
|
|
12606
|
+
Flag["India"] = "in";
|
|
12607
|
+
Flag["Ireland"] = "ie";
|
|
12608
|
+
Flag["IranIslamicRepublicOf"] = "ir";
|
|
12609
|
+
Flag["Iraq"] = "iq";
|
|
12610
|
+
Flag["Iceland"] = "is";
|
|
12611
|
+
Flag["Israel"] = "il";
|
|
12612
|
+
Flag["Italy"] = "it";
|
|
12613
|
+
Flag["Jamaica"] = "jm";
|
|
12614
|
+
Flag["Jordan"] = "jo";
|
|
12615
|
+
Flag["Japan"] = "jp";
|
|
12616
|
+
Flag["Kazakhstan"] = "kz";
|
|
12617
|
+
Flag["Kenya"] = "ke";
|
|
12618
|
+
Flag["Kyrgyzstan"] = "kg";
|
|
12619
|
+
Flag["Cambodia"] = "kh";
|
|
12620
|
+
Flag["Kiribati"] = "ki";
|
|
12621
|
+
Flag["SaintKittsAndNevis"] = "kn";
|
|
12622
|
+
Flag["SouthKorea"] = "kr";
|
|
12623
|
+
Flag["Kuwait"] = "kw";
|
|
12624
|
+
Flag["LaoPeopleSDemocraticRepublic"] = "la";
|
|
12625
|
+
Flag["Lebanon"] = "lb";
|
|
12626
|
+
Flag["Liberia"] = "lr";
|
|
12627
|
+
Flag["Libya"] = "ly";
|
|
12628
|
+
Flag["SaintLucia"] = "lc";
|
|
12629
|
+
Flag["Liechtenstein"] = "li";
|
|
12630
|
+
Flag["SriLanka"] = "lk";
|
|
12631
|
+
Flag["Lesotho"] = "ls";
|
|
12632
|
+
Flag["Lithuania"] = "lt";
|
|
12633
|
+
Flag["Luxembourg"] = "lu";
|
|
12634
|
+
Flag["Latvia"] = "lv";
|
|
12635
|
+
Flag["Morocco"] = "ma";
|
|
12636
|
+
Flag["Monaco"] = "mc";
|
|
12637
|
+
Flag["Moldova"] = "md";
|
|
12638
|
+
Flag["Madagascar"] = "mg";
|
|
12639
|
+
Flag["Maldives"] = "mv";
|
|
12640
|
+
Flag["Mexico"] = "mx";
|
|
12641
|
+
Flag["MarshallIslands"] = "mh";
|
|
12642
|
+
Flag["NorthMacedonia"] = "mk";
|
|
12643
|
+
Flag["Mali"] = "ml";
|
|
12644
|
+
Flag["Malta"] = "mt";
|
|
12645
|
+
Flag["Myanmar"] = "mm";
|
|
12646
|
+
Flag["Montenegro"] = "me";
|
|
12647
|
+
Flag["Mongolia"] = "mn";
|
|
12648
|
+
Flag["Mozambique"] = "mz";
|
|
12649
|
+
Flag["Mauritania"] = "mr";
|
|
12650
|
+
Flag["Mauritius"] = "mu";
|
|
12651
|
+
Flag["Malawi"] = "mw";
|
|
12652
|
+
Flag["Malaysia"] = "my";
|
|
12653
|
+
Flag["Namibia"] = "na";
|
|
12654
|
+
Flag["Niger"] = "ne";
|
|
12655
|
+
Flag["Nigeria"] = "ng";
|
|
12656
|
+
Flag["Nicaragua"] = "ni";
|
|
12657
|
+
Flag["Netherlands"] = "nl";
|
|
12658
|
+
Flag["Norway"] = "no";
|
|
12659
|
+
Flag["Nepal"] = "np";
|
|
12660
|
+
Flag["Nauru"] = "nr";
|
|
12661
|
+
Flag["NewZealand"] = "nz";
|
|
12662
|
+
Flag["Oman"] = "om";
|
|
12663
|
+
Flag["Pakistan"] = "pk";
|
|
12664
|
+
Flag["Panama"] = "pa";
|
|
12665
|
+
Flag["Peru"] = "pe";
|
|
12666
|
+
Flag["Philippines"] = "ph";
|
|
12667
|
+
Flag["Palau"] = "pw";
|
|
12668
|
+
Flag["PapuaNewGuinea"] = "pg";
|
|
12669
|
+
Flag["Poland"] = "pl";
|
|
12670
|
+
Flag["NorthKorea"] = "kp";
|
|
12671
|
+
Flag["Portugal"] = "pt";
|
|
12672
|
+
Flag["Paraguay"] = "py";
|
|
12673
|
+
Flag["Qatar"] = "qa";
|
|
12674
|
+
Flag["Romania"] = "ro";
|
|
12675
|
+
Flag["Russia"] = "ru";
|
|
12676
|
+
Flag["Rwanda"] = "rw";
|
|
12677
|
+
Flag["SaudiArabia"] = "sa";
|
|
12678
|
+
Flag["Sudan"] = "sd";
|
|
12679
|
+
Flag["Senegal"] = "sn";
|
|
12680
|
+
Flag["Singapore"] = "sg";
|
|
12681
|
+
Flag["SolomonIslands"] = "sb";
|
|
12682
|
+
Flag["SierraLeone"] = "sl";
|
|
12683
|
+
Flag["ElSalvador"] = "sv";
|
|
12684
|
+
Flag["SanMarino"] = "sm";
|
|
12685
|
+
Flag["Somalia"] = "so";
|
|
12686
|
+
Flag["Serbia"] = "rs";
|
|
12687
|
+
Flag["SouthSudan"] = "ss";
|
|
12688
|
+
Flag["SaoTomeAndPrincipe"] = "st";
|
|
12689
|
+
Flag["Suriname"] = "sr";
|
|
12690
|
+
Flag["Slovakia"] = "sk";
|
|
12691
|
+
Flag["Slovenia"] = "si";
|
|
12692
|
+
Flag["Sweden"] = "se";
|
|
12693
|
+
Flag["Eswatini"] = "sz";
|
|
12694
|
+
Flag["Seychelles"] = "sc";
|
|
12695
|
+
Flag["Syria"] = "sy";
|
|
12696
|
+
Flag["Chad"] = "td";
|
|
12697
|
+
Flag["Togo"] = "tg";
|
|
12698
|
+
Flag["Thailand"] = "th";
|
|
12699
|
+
Flag["Tajikistan"] = "tj";
|
|
12700
|
+
Flag["Turkmenistan"] = "tm";
|
|
12701
|
+
Flag["TimorLeste"] = "tl";
|
|
12702
|
+
Flag["Tonga"] = "to";
|
|
12703
|
+
Flag["TrinidadAndTobago"] = "tt";
|
|
12704
|
+
Flag["Tunisia"] = "tn";
|
|
12705
|
+
Flag["Turkey"] = "tr";
|
|
12706
|
+
Flag["Tuvalu"] = "tv";
|
|
12707
|
+
Flag["Tanzania"] = "tz";
|
|
12708
|
+
Flag["Uganda"] = "ug";
|
|
12709
|
+
Flag["Ukraine"] = "ua";
|
|
12710
|
+
Flag["Uruguay"] = "uy";
|
|
12711
|
+
Flag["UnitedStates"] = "us";
|
|
12712
|
+
Flag["Uzbekistan"] = "uz";
|
|
12713
|
+
Flag["VaticanCity"] = "va";
|
|
12714
|
+
Flag["SaintVincentAndTheGrenadines"] = "vc";
|
|
12715
|
+
Flag["Venezuela"] = "ve";
|
|
12716
|
+
Flag["Vietnam"] = "vn";
|
|
12717
|
+
Flag["Vanuatu"] = "vu";
|
|
12718
|
+
Flag["Samoa"] = "ws";
|
|
12719
|
+
Flag["Yemen"] = "ye";
|
|
12720
|
+
Flag["SouthAfrica"] = "za";
|
|
12721
|
+
Flag["Zambia"] = "zm";
|
|
12722
|
+
Flag["Zimbabwe"] = "zw";
|
|
12723
|
+
})(exports.Flag || (exports.Flag = {}));
|
|
12724
|
+
|
|
12725
|
+
exports.DatabaseUsageRange = void 0;
|
|
12726
|
+
(function (DatabaseUsageRange) {
|
|
12727
|
+
DatabaseUsageRange["TwentyFourHours"] = "24h";
|
|
12728
|
+
DatabaseUsageRange["ThirtyDays"] = "30d";
|
|
12729
|
+
DatabaseUsageRange["NinetyDays"] = "90d";
|
|
12730
|
+
})(exports.DatabaseUsageRange || (exports.DatabaseUsageRange = {}));
|
|
12731
|
+
|
|
12732
|
+
exports.RelationshipType = void 0;
|
|
12733
|
+
(function (RelationshipType) {
|
|
12734
|
+
RelationshipType["OneToOne"] = "oneToOne";
|
|
12735
|
+
RelationshipType["ManyToOne"] = "manyToOne";
|
|
12736
|
+
RelationshipType["ManyToMany"] = "manyToMany";
|
|
12737
|
+
RelationshipType["OneToMany"] = "oneToMany";
|
|
12738
|
+
})(exports.RelationshipType || (exports.RelationshipType = {}));
|
|
12739
|
+
|
|
12740
|
+
exports.RelationMutate = void 0;
|
|
12741
|
+
(function (RelationMutate) {
|
|
12742
|
+
RelationMutate["Cascade"] = "cascade";
|
|
12743
|
+
RelationMutate["Restrict"] = "restrict";
|
|
12744
|
+
RelationMutate["SetNull"] = "setNull";
|
|
12745
|
+
})(exports.RelationMutate || (exports.RelationMutate = {}));
|
|
12746
|
+
|
|
12747
|
+
exports.IndexType = void 0;
|
|
12748
|
+
(function (IndexType) {
|
|
12749
|
+
IndexType["Key"] = "key";
|
|
12750
|
+
IndexType["Fulltext"] = "fulltext";
|
|
12751
|
+
IndexType["Unique"] = "unique";
|
|
12752
|
+
IndexType["Spatial"] = "spatial";
|
|
12753
|
+
})(exports.IndexType || (exports.IndexType = {}));
|
|
12754
|
+
|
|
12755
|
+
exports.Runtime = void 0;
|
|
12756
|
+
(function (Runtime) {
|
|
12757
|
+
Runtime["Node180"] = "node-18.0";
|
|
12758
|
+
Runtime["Php80"] = "php-8.0";
|
|
12759
|
+
Runtime["Ruby31"] = "ruby-3.1";
|
|
12760
|
+
Runtime["Python39"] = "python-3.9";
|
|
12761
|
+
})(exports.Runtime || (exports.Runtime = {}));
|
|
12762
|
+
|
|
12763
|
+
exports.FunctionUsageRange = void 0;
|
|
12764
|
+
(function (FunctionUsageRange) {
|
|
12765
|
+
FunctionUsageRange["TwentyFourHours"] = "24h";
|
|
12766
|
+
FunctionUsageRange["ThirtyDays"] = "30d";
|
|
12767
|
+
FunctionUsageRange["NinetyDays"] = "90d";
|
|
12768
|
+
})(exports.FunctionUsageRange || (exports.FunctionUsageRange = {}));
|
|
12769
|
+
|
|
12770
|
+
exports.ExecutionMethod = void 0;
|
|
12771
|
+
(function (ExecutionMethod) {
|
|
12772
|
+
ExecutionMethod["GET"] = "GET";
|
|
12773
|
+
ExecutionMethod["POST"] = "POST";
|
|
12774
|
+
ExecutionMethod["PUT"] = "PUT";
|
|
12775
|
+
ExecutionMethod["PATCH"] = "PATCH";
|
|
12776
|
+
ExecutionMethod["DELETE"] = "DELETE";
|
|
12777
|
+
ExecutionMethod["OPTIONS"] = "OPTIONS";
|
|
12778
|
+
})(exports.ExecutionMethod || (exports.ExecutionMethod = {}));
|
|
12779
|
+
|
|
12780
|
+
exports.Name = void 0;
|
|
12781
|
+
(function (Name) {
|
|
12782
|
+
Name["V1database"] = "v1-database";
|
|
12783
|
+
Name["V1deletes"] = "v1-deletes";
|
|
12784
|
+
Name["V1audits"] = "v1-audits";
|
|
12785
|
+
Name["V1mails"] = "v1-mails";
|
|
12786
|
+
Name["V1functions"] = "v1-functions";
|
|
12787
|
+
Name["V1usage"] = "v1-usage";
|
|
12788
|
+
Name["Webhooksv1"] = "webhooksv1";
|
|
12789
|
+
Name["V1certificates"] = "v1-certificates";
|
|
12790
|
+
Name["V1builds"] = "v1-builds";
|
|
12791
|
+
Name["V1messaging"] = "v1-messaging";
|
|
12792
|
+
Name["V1migrations"] = "v1-migrations";
|
|
12793
|
+
Name["Hamsterv1"] = "hamsterv1";
|
|
12794
|
+
})(exports.Name || (exports.Name = {}));
|
|
12795
|
+
|
|
12796
|
+
exports.MessageStatus = void 0;
|
|
12797
|
+
(function (MessageStatus) {
|
|
12798
|
+
MessageStatus["Draft"] = "draft";
|
|
12799
|
+
MessageStatus["Scheduled"] = "scheduled";
|
|
12800
|
+
MessageStatus["Processing"] = "processing";
|
|
12801
|
+
})(exports.MessageStatus || (exports.MessageStatus = {}));
|
|
12802
|
+
|
|
12803
|
+
exports.SMTPEncryption = void 0;
|
|
12804
|
+
(function (SMTPEncryption) {
|
|
12805
|
+
SMTPEncryption["None"] = "none";
|
|
12806
|
+
SMTPEncryption["Ssl"] = "ssl";
|
|
12807
|
+
SMTPEncryption["Tls"] = "tls";
|
|
12808
|
+
})(exports.SMTPEncryption || (exports.SMTPEncryption = {}));
|
|
12809
|
+
|
|
12810
|
+
exports.ProjectUsageRange = void 0;
|
|
12811
|
+
(function (ProjectUsageRange) {
|
|
12812
|
+
ProjectUsageRange["OneHour"] = "1h";
|
|
12813
|
+
ProjectUsageRange["OneDay"] = "1d";
|
|
12814
|
+
})(exports.ProjectUsageRange || (exports.ProjectUsageRange = {}));
|
|
12815
|
+
|
|
12816
|
+
exports.Region = void 0;
|
|
12817
|
+
(function (Region) {
|
|
12818
|
+
Region["Default"] = "default";
|
|
12819
|
+
})(exports.Region || (exports.Region = {}));
|
|
12820
|
+
|
|
12821
|
+
exports.AuthMethod = void 0;
|
|
12822
|
+
(function (AuthMethod) {
|
|
12823
|
+
AuthMethod["Emailpassword"] = "email-password";
|
|
12824
|
+
AuthMethod["Magicurl"] = "magic-url";
|
|
12825
|
+
AuthMethod["Emailotp"] = "email-otp";
|
|
12826
|
+
AuthMethod["Anonymous"] = "anonymous";
|
|
12827
|
+
AuthMethod["Invites"] = "invites";
|
|
12828
|
+
AuthMethod["Jwt"] = "jwt";
|
|
12829
|
+
AuthMethod["Phone"] = "phone";
|
|
12830
|
+
})(exports.AuthMethod || (exports.AuthMethod = {}));
|
|
12831
|
+
|
|
12832
|
+
exports.PlatformType = void 0;
|
|
12833
|
+
(function (PlatformType) {
|
|
12834
|
+
PlatformType["Web"] = "web";
|
|
12835
|
+
PlatformType["Flutterweb"] = "flutter-web";
|
|
12836
|
+
PlatformType["Flutterios"] = "flutter-ios";
|
|
12837
|
+
PlatformType["Flutterandroid"] = "flutter-android";
|
|
12838
|
+
PlatformType["Flutterlinux"] = "flutter-linux";
|
|
12839
|
+
PlatformType["Fluttermacos"] = "flutter-macos";
|
|
12840
|
+
PlatformType["Flutterwindows"] = "flutter-windows";
|
|
12841
|
+
PlatformType["Appleios"] = "apple-ios";
|
|
12842
|
+
PlatformType["Applemacos"] = "apple-macos";
|
|
12843
|
+
PlatformType["Applewatchos"] = "apple-watchos";
|
|
12844
|
+
PlatformType["Appletvos"] = "apple-tvos";
|
|
12845
|
+
PlatformType["Android"] = "android";
|
|
12846
|
+
PlatformType["Unity"] = "unity";
|
|
12847
|
+
})(exports.PlatformType || (exports.PlatformType = {}));
|
|
12848
|
+
|
|
12849
|
+
exports.APIService = void 0;
|
|
12850
|
+
(function (APIService) {
|
|
12851
|
+
APIService["Account"] = "account";
|
|
12852
|
+
APIService["Avatars"] = "avatars";
|
|
12853
|
+
APIService["Databases"] = "databases";
|
|
12854
|
+
APIService["Locale"] = "locale";
|
|
12855
|
+
APIService["Health"] = "health";
|
|
12856
|
+
APIService["Storage"] = "storage";
|
|
12857
|
+
APIService["Teams"] = "teams";
|
|
12858
|
+
APIService["Users"] = "users";
|
|
12859
|
+
APIService["Functions"] = "functions";
|
|
12860
|
+
APIService["Graphql"] = "graphql";
|
|
12861
|
+
APIService["Messaging"] = "messaging";
|
|
12862
|
+
})(exports.APIService || (exports.APIService = {}));
|
|
12863
|
+
|
|
12864
|
+
exports.SMTPSecure = void 0;
|
|
12865
|
+
(function (SMTPSecure) {
|
|
12866
|
+
SMTPSecure["Tls"] = "tls";
|
|
12867
|
+
})(exports.SMTPSecure || (exports.SMTPSecure = {}));
|
|
12868
|
+
|
|
12869
|
+
exports.EmailTemplateType = void 0;
|
|
12870
|
+
(function (EmailTemplateType) {
|
|
12871
|
+
EmailTemplateType["Verification"] = "verification";
|
|
12872
|
+
EmailTemplateType["Magicsession"] = "magicsession";
|
|
12873
|
+
EmailTemplateType["Recovery"] = "recovery";
|
|
12874
|
+
EmailTemplateType["Invitation"] = "invitation";
|
|
12875
|
+
})(exports.EmailTemplateType || (exports.EmailTemplateType = {}));
|
|
12876
|
+
|
|
12877
|
+
exports.EmailTemplateLocale = void 0;
|
|
12878
|
+
(function (EmailTemplateLocale) {
|
|
12879
|
+
EmailTemplateLocale["Af"] = "af";
|
|
12880
|
+
EmailTemplateLocale["Arae"] = "ar-ae";
|
|
12881
|
+
EmailTemplateLocale["Arbh"] = "ar-bh";
|
|
12882
|
+
EmailTemplateLocale["Ardz"] = "ar-dz";
|
|
12883
|
+
EmailTemplateLocale["Areg"] = "ar-eg";
|
|
12884
|
+
EmailTemplateLocale["Ariq"] = "ar-iq";
|
|
12885
|
+
EmailTemplateLocale["Arjo"] = "ar-jo";
|
|
12886
|
+
EmailTemplateLocale["Arkw"] = "ar-kw";
|
|
12887
|
+
EmailTemplateLocale["Arlb"] = "ar-lb";
|
|
12888
|
+
EmailTemplateLocale["Arly"] = "ar-ly";
|
|
12889
|
+
EmailTemplateLocale["Arma"] = "ar-ma";
|
|
12890
|
+
EmailTemplateLocale["Arom"] = "ar-om";
|
|
12891
|
+
EmailTemplateLocale["Arqa"] = "ar-qa";
|
|
12892
|
+
EmailTemplateLocale["Arsa"] = "ar-sa";
|
|
12893
|
+
EmailTemplateLocale["Arsy"] = "ar-sy";
|
|
12894
|
+
EmailTemplateLocale["Artn"] = "ar-tn";
|
|
12895
|
+
EmailTemplateLocale["Arye"] = "ar-ye";
|
|
12896
|
+
EmailTemplateLocale["As"] = "as";
|
|
12897
|
+
EmailTemplateLocale["Az"] = "az";
|
|
12898
|
+
EmailTemplateLocale["Be"] = "be";
|
|
12899
|
+
EmailTemplateLocale["Bg"] = "bg";
|
|
12900
|
+
EmailTemplateLocale["Bh"] = "bh";
|
|
12901
|
+
EmailTemplateLocale["Bn"] = "bn";
|
|
12902
|
+
EmailTemplateLocale["Bs"] = "bs";
|
|
12903
|
+
EmailTemplateLocale["Ca"] = "ca";
|
|
12904
|
+
EmailTemplateLocale["Cs"] = "cs";
|
|
12905
|
+
EmailTemplateLocale["Cy"] = "cy";
|
|
12906
|
+
EmailTemplateLocale["Da"] = "da";
|
|
12907
|
+
EmailTemplateLocale["De"] = "de";
|
|
12908
|
+
EmailTemplateLocale["Deat"] = "de-at";
|
|
12909
|
+
EmailTemplateLocale["Dech"] = "de-ch";
|
|
12910
|
+
EmailTemplateLocale["Deli"] = "de-li";
|
|
12911
|
+
EmailTemplateLocale["Delu"] = "de-lu";
|
|
12912
|
+
EmailTemplateLocale["El"] = "el";
|
|
12913
|
+
EmailTemplateLocale["En"] = "en";
|
|
12914
|
+
EmailTemplateLocale["Enau"] = "en-au";
|
|
12915
|
+
EmailTemplateLocale["Enbz"] = "en-bz";
|
|
12916
|
+
EmailTemplateLocale["Enca"] = "en-ca";
|
|
12917
|
+
EmailTemplateLocale["Engb"] = "en-gb";
|
|
12918
|
+
EmailTemplateLocale["Enie"] = "en-ie";
|
|
12919
|
+
EmailTemplateLocale["Enjm"] = "en-jm";
|
|
12920
|
+
EmailTemplateLocale["Ennz"] = "en-nz";
|
|
12921
|
+
EmailTemplateLocale["Entt"] = "en-tt";
|
|
12922
|
+
EmailTemplateLocale["Enus"] = "en-us";
|
|
12923
|
+
EmailTemplateLocale["Enza"] = "en-za";
|
|
12924
|
+
EmailTemplateLocale["Eo"] = "eo";
|
|
12925
|
+
EmailTemplateLocale["Es"] = "es";
|
|
12926
|
+
EmailTemplateLocale["Esar"] = "es-ar";
|
|
12927
|
+
EmailTemplateLocale["Esbo"] = "es-bo";
|
|
12928
|
+
EmailTemplateLocale["Escl"] = "es-cl";
|
|
12929
|
+
EmailTemplateLocale["Esco"] = "es-co";
|
|
12930
|
+
EmailTemplateLocale["Escr"] = "es-cr";
|
|
12931
|
+
EmailTemplateLocale["Esdo"] = "es-do";
|
|
12932
|
+
EmailTemplateLocale["Esec"] = "es-ec";
|
|
12933
|
+
EmailTemplateLocale["Esgt"] = "es-gt";
|
|
12934
|
+
EmailTemplateLocale["Eshn"] = "es-hn";
|
|
12935
|
+
EmailTemplateLocale["Esmx"] = "es-mx";
|
|
12936
|
+
EmailTemplateLocale["Esni"] = "es-ni";
|
|
12937
|
+
EmailTemplateLocale["Espa"] = "es-pa";
|
|
12938
|
+
EmailTemplateLocale["Espe"] = "es-pe";
|
|
12939
|
+
EmailTemplateLocale["Espr"] = "es-pr";
|
|
12940
|
+
EmailTemplateLocale["Espy"] = "es-py";
|
|
12941
|
+
EmailTemplateLocale["Essv"] = "es-sv";
|
|
12942
|
+
EmailTemplateLocale["Esuy"] = "es-uy";
|
|
12943
|
+
EmailTemplateLocale["Esve"] = "es-ve";
|
|
12944
|
+
EmailTemplateLocale["Et"] = "et";
|
|
12945
|
+
EmailTemplateLocale["Eu"] = "eu";
|
|
12946
|
+
EmailTemplateLocale["Fa"] = "fa";
|
|
12947
|
+
EmailTemplateLocale["Fi"] = "fi";
|
|
12948
|
+
EmailTemplateLocale["Fo"] = "fo";
|
|
12949
|
+
EmailTemplateLocale["Fr"] = "fr";
|
|
12950
|
+
EmailTemplateLocale["Frbe"] = "fr-be";
|
|
12951
|
+
EmailTemplateLocale["Frca"] = "fr-ca";
|
|
12952
|
+
EmailTemplateLocale["Frch"] = "fr-ch";
|
|
12953
|
+
EmailTemplateLocale["Frlu"] = "fr-lu";
|
|
12954
|
+
EmailTemplateLocale["Ga"] = "ga";
|
|
12955
|
+
EmailTemplateLocale["Gd"] = "gd";
|
|
12956
|
+
EmailTemplateLocale["He"] = "he";
|
|
12957
|
+
EmailTemplateLocale["Hi"] = "hi";
|
|
12958
|
+
EmailTemplateLocale["Hr"] = "hr";
|
|
12959
|
+
EmailTemplateLocale["Hu"] = "hu";
|
|
12960
|
+
EmailTemplateLocale["Id"] = "id";
|
|
12961
|
+
EmailTemplateLocale["Is"] = "is";
|
|
12962
|
+
EmailTemplateLocale["It"] = "it";
|
|
12963
|
+
EmailTemplateLocale["Itch"] = "it-ch";
|
|
12964
|
+
EmailTemplateLocale["Ja"] = "ja";
|
|
12965
|
+
EmailTemplateLocale["Ji"] = "ji";
|
|
12966
|
+
EmailTemplateLocale["Ko"] = "ko";
|
|
12967
|
+
EmailTemplateLocale["Ku"] = "ku";
|
|
12968
|
+
EmailTemplateLocale["Lt"] = "lt";
|
|
12969
|
+
EmailTemplateLocale["Lv"] = "lv";
|
|
12970
|
+
EmailTemplateLocale["Mk"] = "mk";
|
|
12971
|
+
EmailTemplateLocale["Ml"] = "ml";
|
|
12972
|
+
EmailTemplateLocale["Ms"] = "ms";
|
|
12973
|
+
EmailTemplateLocale["Mt"] = "mt";
|
|
12974
|
+
EmailTemplateLocale["Nb"] = "nb";
|
|
12975
|
+
EmailTemplateLocale["Ne"] = "ne";
|
|
12976
|
+
EmailTemplateLocale["Nl"] = "nl";
|
|
12977
|
+
EmailTemplateLocale["Nlbe"] = "nl-be";
|
|
12978
|
+
EmailTemplateLocale["Nn"] = "nn";
|
|
12979
|
+
EmailTemplateLocale["No"] = "no";
|
|
12980
|
+
EmailTemplateLocale["Pa"] = "pa";
|
|
12981
|
+
EmailTemplateLocale["Pl"] = "pl";
|
|
12982
|
+
EmailTemplateLocale["Pt"] = "pt";
|
|
12983
|
+
EmailTemplateLocale["Ptbr"] = "pt-br";
|
|
12984
|
+
EmailTemplateLocale["Rm"] = "rm";
|
|
12985
|
+
EmailTemplateLocale["Ro"] = "ro";
|
|
12986
|
+
EmailTemplateLocale["Romd"] = "ro-md";
|
|
12987
|
+
EmailTemplateLocale["Ru"] = "ru";
|
|
12988
|
+
EmailTemplateLocale["Rumd"] = "ru-md";
|
|
12989
|
+
EmailTemplateLocale["Sb"] = "sb";
|
|
12990
|
+
EmailTemplateLocale["Sk"] = "sk";
|
|
12991
|
+
EmailTemplateLocale["Sl"] = "sl";
|
|
12992
|
+
EmailTemplateLocale["Sq"] = "sq";
|
|
12993
|
+
EmailTemplateLocale["Sr"] = "sr";
|
|
12994
|
+
EmailTemplateLocale["Sv"] = "sv";
|
|
12995
|
+
EmailTemplateLocale["Svfi"] = "sv-fi";
|
|
12996
|
+
EmailTemplateLocale["Th"] = "th";
|
|
12997
|
+
EmailTemplateLocale["Tn"] = "tn";
|
|
12998
|
+
EmailTemplateLocale["Tr"] = "tr";
|
|
12999
|
+
EmailTemplateLocale["Ts"] = "ts";
|
|
13000
|
+
EmailTemplateLocale["Ua"] = "ua";
|
|
13001
|
+
EmailTemplateLocale["Ur"] = "ur";
|
|
13002
|
+
EmailTemplateLocale["Ve"] = "ve";
|
|
13003
|
+
EmailTemplateLocale["Vi"] = "vi";
|
|
13004
|
+
EmailTemplateLocale["Xh"] = "xh";
|
|
13005
|
+
EmailTemplateLocale["Zhcn"] = "zh-cn";
|
|
13006
|
+
EmailTemplateLocale["Zhhk"] = "zh-hk";
|
|
13007
|
+
EmailTemplateLocale["Zhsg"] = "zh-sg";
|
|
13008
|
+
EmailTemplateLocale["Zhtw"] = "zh-tw";
|
|
13009
|
+
EmailTemplateLocale["Zu"] = "zu";
|
|
13010
|
+
})(exports.EmailTemplateLocale || (exports.EmailTemplateLocale = {}));
|
|
13011
|
+
|
|
13012
|
+
exports.SMSTemplateType = void 0;
|
|
13013
|
+
(function (SMSTemplateType) {
|
|
13014
|
+
SMSTemplateType["Verification"] = "verification";
|
|
13015
|
+
SMSTemplateType["Login"] = "login";
|
|
13016
|
+
SMSTemplateType["Invitation"] = "invitation";
|
|
13017
|
+
})(exports.SMSTemplateType || (exports.SMSTemplateType = {}));
|
|
13018
|
+
|
|
13019
|
+
exports.SMSTemplateLocale = void 0;
|
|
13020
|
+
(function (SMSTemplateLocale) {
|
|
13021
|
+
SMSTemplateLocale["Af"] = "af";
|
|
13022
|
+
SMSTemplateLocale["Arae"] = "ar-ae";
|
|
13023
|
+
SMSTemplateLocale["Arbh"] = "ar-bh";
|
|
13024
|
+
SMSTemplateLocale["Ardz"] = "ar-dz";
|
|
13025
|
+
SMSTemplateLocale["Areg"] = "ar-eg";
|
|
13026
|
+
SMSTemplateLocale["Ariq"] = "ar-iq";
|
|
13027
|
+
SMSTemplateLocale["Arjo"] = "ar-jo";
|
|
13028
|
+
SMSTemplateLocale["Arkw"] = "ar-kw";
|
|
13029
|
+
SMSTemplateLocale["Arlb"] = "ar-lb";
|
|
13030
|
+
SMSTemplateLocale["Arly"] = "ar-ly";
|
|
13031
|
+
SMSTemplateLocale["Arma"] = "ar-ma";
|
|
13032
|
+
SMSTemplateLocale["Arom"] = "ar-om";
|
|
13033
|
+
SMSTemplateLocale["Arqa"] = "ar-qa";
|
|
13034
|
+
SMSTemplateLocale["Arsa"] = "ar-sa";
|
|
13035
|
+
SMSTemplateLocale["Arsy"] = "ar-sy";
|
|
13036
|
+
SMSTemplateLocale["Artn"] = "ar-tn";
|
|
13037
|
+
SMSTemplateLocale["Arye"] = "ar-ye";
|
|
13038
|
+
SMSTemplateLocale["As"] = "as";
|
|
13039
|
+
SMSTemplateLocale["Az"] = "az";
|
|
13040
|
+
SMSTemplateLocale["Be"] = "be";
|
|
13041
|
+
SMSTemplateLocale["Bg"] = "bg";
|
|
13042
|
+
SMSTemplateLocale["Bh"] = "bh";
|
|
13043
|
+
SMSTemplateLocale["Bn"] = "bn";
|
|
13044
|
+
SMSTemplateLocale["Bs"] = "bs";
|
|
13045
|
+
SMSTemplateLocale["Ca"] = "ca";
|
|
13046
|
+
SMSTemplateLocale["Cs"] = "cs";
|
|
13047
|
+
SMSTemplateLocale["Cy"] = "cy";
|
|
13048
|
+
SMSTemplateLocale["Da"] = "da";
|
|
13049
|
+
SMSTemplateLocale["De"] = "de";
|
|
13050
|
+
SMSTemplateLocale["Deat"] = "de-at";
|
|
13051
|
+
SMSTemplateLocale["Dech"] = "de-ch";
|
|
13052
|
+
SMSTemplateLocale["Deli"] = "de-li";
|
|
13053
|
+
SMSTemplateLocale["Delu"] = "de-lu";
|
|
13054
|
+
SMSTemplateLocale["El"] = "el";
|
|
13055
|
+
SMSTemplateLocale["En"] = "en";
|
|
13056
|
+
SMSTemplateLocale["Enau"] = "en-au";
|
|
13057
|
+
SMSTemplateLocale["Enbz"] = "en-bz";
|
|
13058
|
+
SMSTemplateLocale["Enca"] = "en-ca";
|
|
13059
|
+
SMSTemplateLocale["Engb"] = "en-gb";
|
|
13060
|
+
SMSTemplateLocale["Enie"] = "en-ie";
|
|
13061
|
+
SMSTemplateLocale["Enjm"] = "en-jm";
|
|
13062
|
+
SMSTemplateLocale["Ennz"] = "en-nz";
|
|
13063
|
+
SMSTemplateLocale["Entt"] = "en-tt";
|
|
13064
|
+
SMSTemplateLocale["Enus"] = "en-us";
|
|
13065
|
+
SMSTemplateLocale["Enza"] = "en-za";
|
|
13066
|
+
SMSTemplateLocale["Eo"] = "eo";
|
|
13067
|
+
SMSTemplateLocale["Es"] = "es";
|
|
13068
|
+
SMSTemplateLocale["Esar"] = "es-ar";
|
|
13069
|
+
SMSTemplateLocale["Esbo"] = "es-bo";
|
|
13070
|
+
SMSTemplateLocale["Escl"] = "es-cl";
|
|
13071
|
+
SMSTemplateLocale["Esco"] = "es-co";
|
|
13072
|
+
SMSTemplateLocale["Escr"] = "es-cr";
|
|
13073
|
+
SMSTemplateLocale["Esdo"] = "es-do";
|
|
13074
|
+
SMSTemplateLocale["Esec"] = "es-ec";
|
|
13075
|
+
SMSTemplateLocale["Esgt"] = "es-gt";
|
|
13076
|
+
SMSTemplateLocale["Eshn"] = "es-hn";
|
|
13077
|
+
SMSTemplateLocale["Esmx"] = "es-mx";
|
|
13078
|
+
SMSTemplateLocale["Esni"] = "es-ni";
|
|
13079
|
+
SMSTemplateLocale["Espa"] = "es-pa";
|
|
13080
|
+
SMSTemplateLocale["Espe"] = "es-pe";
|
|
13081
|
+
SMSTemplateLocale["Espr"] = "es-pr";
|
|
13082
|
+
SMSTemplateLocale["Espy"] = "es-py";
|
|
13083
|
+
SMSTemplateLocale["Essv"] = "es-sv";
|
|
13084
|
+
SMSTemplateLocale["Esuy"] = "es-uy";
|
|
13085
|
+
SMSTemplateLocale["Esve"] = "es-ve";
|
|
13086
|
+
SMSTemplateLocale["Et"] = "et";
|
|
13087
|
+
SMSTemplateLocale["Eu"] = "eu";
|
|
13088
|
+
SMSTemplateLocale["Fa"] = "fa";
|
|
13089
|
+
SMSTemplateLocale["Fi"] = "fi";
|
|
13090
|
+
SMSTemplateLocale["Fo"] = "fo";
|
|
13091
|
+
SMSTemplateLocale["Fr"] = "fr";
|
|
13092
|
+
SMSTemplateLocale["Frbe"] = "fr-be";
|
|
13093
|
+
SMSTemplateLocale["Frca"] = "fr-ca";
|
|
13094
|
+
SMSTemplateLocale["Frch"] = "fr-ch";
|
|
13095
|
+
SMSTemplateLocale["Frlu"] = "fr-lu";
|
|
13096
|
+
SMSTemplateLocale["Ga"] = "ga";
|
|
13097
|
+
SMSTemplateLocale["Gd"] = "gd";
|
|
13098
|
+
SMSTemplateLocale["He"] = "he";
|
|
13099
|
+
SMSTemplateLocale["Hi"] = "hi";
|
|
13100
|
+
SMSTemplateLocale["Hr"] = "hr";
|
|
13101
|
+
SMSTemplateLocale["Hu"] = "hu";
|
|
13102
|
+
SMSTemplateLocale["Id"] = "id";
|
|
13103
|
+
SMSTemplateLocale["Is"] = "is";
|
|
13104
|
+
SMSTemplateLocale["It"] = "it";
|
|
13105
|
+
SMSTemplateLocale["Itch"] = "it-ch";
|
|
13106
|
+
SMSTemplateLocale["Ja"] = "ja";
|
|
13107
|
+
SMSTemplateLocale["Ji"] = "ji";
|
|
13108
|
+
SMSTemplateLocale["Ko"] = "ko";
|
|
13109
|
+
SMSTemplateLocale["Ku"] = "ku";
|
|
13110
|
+
SMSTemplateLocale["Lt"] = "lt";
|
|
13111
|
+
SMSTemplateLocale["Lv"] = "lv";
|
|
13112
|
+
SMSTemplateLocale["Mk"] = "mk";
|
|
13113
|
+
SMSTemplateLocale["Ml"] = "ml";
|
|
13114
|
+
SMSTemplateLocale["Ms"] = "ms";
|
|
13115
|
+
SMSTemplateLocale["Mt"] = "mt";
|
|
13116
|
+
SMSTemplateLocale["Nb"] = "nb";
|
|
13117
|
+
SMSTemplateLocale["Ne"] = "ne";
|
|
13118
|
+
SMSTemplateLocale["Nl"] = "nl";
|
|
13119
|
+
SMSTemplateLocale["Nlbe"] = "nl-be";
|
|
13120
|
+
SMSTemplateLocale["Nn"] = "nn";
|
|
13121
|
+
SMSTemplateLocale["No"] = "no";
|
|
13122
|
+
SMSTemplateLocale["Pa"] = "pa";
|
|
13123
|
+
SMSTemplateLocale["Pl"] = "pl";
|
|
13124
|
+
SMSTemplateLocale["Pt"] = "pt";
|
|
13125
|
+
SMSTemplateLocale["Ptbr"] = "pt-br";
|
|
13126
|
+
SMSTemplateLocale["Rm"] = "rm";
|
|
13127
|
+
SMSTemplateLocale["Ro"] = "ro";
|
|
13128
|
+
SMSTemplateLocale["Romd"] = "ro-md";
|
|
13129
|
+
SMSTemplateLocale["Ru"] = "ru";
|
|
13130
|
+
SMSTemplateLocale["Rumd"] = "ru-md";
|
|
13131
|
+
SMSTemplateLocale["Sb"] = "sb";
|
|
13132
|
+
SMSTemplateLocale["Sk"] = "sk";
|
|
13133
|
+
SMSTemplateLocale["Sl"] = "sl";
|
|
13134
|
+
SMSTemplateLocale["Sq"] = "sq";
|
|
13135
|
+
SMSTemplateLocale["Sr"] = "sr";
|
|
13136
|
+
SMSTemplateLocale["Sv"] = "sv";
|
|
13137
|
+
SMSTemplateLocale["Svfi"] = "sv-fi";
|
|
13138
|
+
SMSTemplateLocale["Th"] = "th";
|
|
13139
|
+
SMSTemplateLocale["Tn"] = "tn";
|
|
13140
|
+
SMSTemplateLocale["Tr"] = "tr";
|
|
13141
|
+
SMSTemplateLocale["Ts"] = "ts";
|
|
13142
|
+
SMSTemplateLocale["Ua"] = "ua";
|
|
13143
|
+
SMSTemplateLocale["Ur"] = "ur";
|
|
13144
|
+
SMSTemplateLocale["Ve"] = "ve";
|
|
13145
|
+
SMSTemplateLocale["Vi"] = "vi";
|
|
13146
|
+
SMSTemplateLocale["Xh"] = "xh";
|
|
13147
|
+
SMSTemplateLocale["Zhcn"] = "zh-cn";
|
|
13148
|
+
SMSTemplateLocale["Zhhk"] = "zh-hk";
|
|
13149
|
+
SMSTemplateLocale["Zhsg"] = "zh-sg";
|
|
13150
|
+
SMSTemplateLocale["Zhtw"] = "zh-tw";
|
|
13151
|
+
SMSTemplateLocale["Zu"] = "zu";
|
|
13152
|
+
})(exports.SMSTemplateLocale || (exports.SMSTemplateLocale = {}));
|
|
13153
|
+
|
|
13154
|
+
exports.ResourceType = void 0;
|
|
13155
|
+
(function (ResourceType) {
|
|
13156
|
+
ResourceType["Api"] = "api";
|
|
13157
|
+
ResourceType["Function"] = "function";
|
|
13158
|
+
})(exports.ResourceType || (exports.ResourceType = {}));
|
|
13159
|
+
|
|
13160
|
+
exports.Compression = void 0;
|
|
13161
|
+
(function (Compression) {
|
|
13162
|
+
Compression["None"] = "none";
|
|
13163
|
+
Compression["Gzip"] = "gzip";
|
|
13164
|
+
Compression["Zstd"] = "zstd";
|
|
13165
|
+
})(exports.Compression || (exports.Compression = {}));
|
|
13166
|
+
|
|
13167
|
+
exports.ImageGravity = void 0;
|
|
13168
|
+
(function (ImageGravity) {
|
|
13169
|
+
ImageGravity["Center"] = "center";
|
|
13170
|
+
ImageGravity["Topleft"] = "top-left";
|
|
13171
|
+
ImageGravity["Top"] = "top";
|
|
13172
|
+
ImageGravity["Topright"] = "top-right";
|
|
13173
|
+
ImageGravity["Left"] = "left";
|
|
13174
|
+
ImageGravity["Right"] = "right";
|
|
13175
|
+
ImageGravity["Bottomleft"] = "bottom-left";
|
|
13176
|
+
ImageGravity["Bottom"] = "bottom";
|
|
13177
|
+
ImageGravity["Bottomright"] = "bottom-right";
|
|
13178
|
+
})(exports.ImageGravity || (exports.ImageGravity = {}));
|
|
13179
|
+
|
|
13180
|
+
exports.ImageFormat = void 0;
|
|
13181
|
+
(function (ImageFormat) {
|
|
13182
|
+
ImageFormat["Jpg"] = "jpg";
|
|
13183
|
+
ImageFormat["Jpeg"] = "jpeg";
|
|
13184
|
+
ImageFormat["Gif"] = "gif";
|
|
13185
|
+
ImageFormat["Png"] = "png";
|
|
13186
|
+
ImageFormat["Webp"] = "webp";
|
|
13187
|
+
})(exports.ImageFormat || (exports.ImageFormat = {}));
|
|
13188
|
+
|
|
13189
|
+
exports.StorageUsageRange = void 0;
|
|
13190
|
+
(function (StorageUsageRange) {
|
|
13191
|
+
StorageUsageRange["TwentyFourHours"] = "24h";
|
|
13192
|
+
StorageUsageRange["ThirtyDays"] = "30d";
|
|
13193
|
+
StorageUsageRange["NinetyDays"] = "90d";
|
|
13194
|
+
})(exports.StorageUsageRange || (exports.StorageUsageRange = {}));
|
|
13195
|
+
|
|
13196
|
+
exports.PasswordHash = void 0;
|
|
13197
|
+
(function (PasswordHash) {
|
|
13198
|
+
PasswordHash["Sha1"] = "sha1";
|
|
13199
|
+
PasswordHash["Sha224"] = "sha224";
|
|
13200
|
+
PasswordHash["Sha256"] = "sha256";
|
|
13201
|
+
PasswordHash["Sha384"] = "sha384";
|
|
13202
|
+
PasswordHash["Sha512224"] = "sha512/224";
|
|
13203
|
+
PasswordHash["Sha512256"] = "sha512/256";
|
|
13204
|
+
PasswordHash["Sha512"] = "sha512";
|
|
13205
|
+
PasswordHash["Sha3224"] = "sha3-224";
|
|
13206
|
+
PasswordHash["Sha3256"] = "sha3-256";
|
|
13207
|
+
PasswordHash["Sha3384"] = "sha3-384";
|
|
13208
|
+
PasswordHash["Sha3512"] = "sha3-512";
|
|
13209
|
+
})(exports.PasswordHash || (exports.PasswordHash = {}));
|
|
13210
|
+
|
|
13211
|
+
exports.UserUsageRange = void 0;
|
|
13212
|
+
(function (UserUsageRange) {
|
|
13213
|
+
UserUsageRange["TwentyFourHours"] = "24h";
|
|
13214
|
+
UserUsageRange["ThirtyDays"] = "30d";
|
|
13215
|
+
UserUsageRange["NinetyDays"] = "90d";
|
|
13216
|
+
})(exports.UserUsageRange || (exports.UserUsageRange = {}));
|
|
13217
|
+
|
|
13218
|
+
exports.MessagingProviderType = void 0;
|
|
13219
|
+
(function (MessagingProviderType) {
|
|
13220
|
+
MessagingProviderType["Email"] = "email";
|
|
13221
|
+
MessagingProviderType["Sms"] = "sms";
|
|
13222
|
+
MessagingProviderType["Push"] = "push";
|
|
13223
|
+
})(exports.MessagingProviderType || (exports.MessagingProviderType = {}));
|
|
13224
|
+
|
|
11798
13225
|
exports.Account = Account;
|
|
11799
13226
|
exports.AppwriteException = AppwriteException;
|
|
11800
13227
|
exports.Assistant = Assistant;
|