@appwrite.io/console 1.6.0 → 1.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +9 -1
- package/README.md +3 -3
- package/dist/cjs/sdk.js +6807 -3959
- package/dist/cjs/sdk.js.map +1 -1
- package/dist/esm/sdk.js +6805 -3960
- package/dist/esm/sdk.js.map +1 -1
- package/dist/iife/sdk.js +6807 -3959
- package/docs/examples/account/create-anonymous-session.md +1 -1
- package/docs/examples/account/create-billing-address.md +1 -1
- package/docs/examples/account/create-email-password-session.md +1 -1
- package/docs/examples/account/create-email-token.md +1 -1
- package/docs/examples/account/create-j-w-t.md +1 -1
- package/docs/examples/account/create-magic-u-r-l-token.md +1 -1
- package/docs/examples/account/create-mfa-authenticator.md +1 -1
- package/docs/examples/account/create-mfa-challenge.md +1 -1
- package/docs/examples/account/create-mfa-recovery-codes.md +1 -1
- package/docs/examples/account/create-o-auth2session.md +1 -1
- package/docs/examples/account/create-o-auth2token.md +1 -1
- package/docs/examples/account/create-payment-method.md +1 -1
- package/docs/examples/account/create-phone-token.md +1 -1
- package/docs/examples/account/create-phone-verification.md +1 -1
- package/docs/examples/account/create-push-target.md +1 -1
- package/docs/examples/account/create-recovery.md +1 -1
- package/docs/examples/account/create-session.md +1 -1
- package/docs/examples/account/create-verification.md +1 -1
- package/docs/examples/account/create.md +1 -1
- package/docs/examples/account/delete-billing-address.md +1 -1
- package/docs/examples/account/delete-identity.md +1 -1
- package/docs/examples/account/delete-mfa-authenticator.md +1 -1
- package/docs/examples/account/delete-payment-method.md +1 -1
- package/docs/examples/account/delete-push-target.md +1 -1
- package/docs/examples/account/delete-session.md +1 -1
- package/docs/examples/account/delete-sessions.md +1 -1
- package/docs/examples/account/delete.md +1 -1
- package/docs/examples/account/get-billing-address.md +1 -1
- package/docs/examples/account/get-coupon.md +1 -1
- package/docs/examples/account/get-mfa-recovery-codes.md +1 -1
- package/docs/examples/account/get-payment-method.md +1 -1
- 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/list-billing-addresses.md +1 -1
- package/docs/examples/account/list-identities.md +1 -1
- package/docs/examples/account/list-invoices.md +1 -1
- package/docs/examples/account/list-logs.md +1 -1
- package/docs/examples/account/list-mfa-factors.md +1 -1
- package/docs/examples/account/list-payment-methods.md +1 -1
- package/docs/examples/account/list-sessions.md +1 -1
- package/docs/examples/account/update-billing-address.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-mfa-authenticator.md +1 -1
- package/docs/examples/account/update-mfa-challenge.md +1 -1
- package/docs/examples/account/update-mfa-recovery-codes.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-payment-method-mandate-options.md +1 -1
- package/docs/examples/account/update-payment-method-provider.md +1 -1
- package/docs/examples/account/update-payment-method.md +1 -1
- package/docs/examples/account/update-phone-session.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 +1 -1
- package/docs/examples/account/update-recovery.md +1 -1
- 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/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/backups/create-archive.md +1 -1
- package/docs/examples/backups/create-policy.md +1 -1
- package/docs/examples/backups/create-restoration.md +1 -1
- package/docs/examples/backups/delete-archive.md +1 -1
- package/docs/examples/backups/delete-policy.md +1 -1
- package/docs/examples/backups/get-archive.md +1 -1
- package/docs/examples/backups/get-policy.md +1 -1
- package/docs/examples/backups/get-restoration.md +1 -1
- package/docs/examples/backups/list-archives.md +1 -1
- package/docs/examples/backups/list-policies.md +1 -1
- package/docs/examples/backups/list-restorations.md +1 -1
- package/docs/examples/backups/update-policy.md +1 -1
- package/docs/examples/console/create-program-membership.md +1 -1
- package/docs/examples/console/create-source.md +1 -1
- package/docs/examples/console/get-campaign.md +1 -1
- package/docs/examples/console/get-coupon.md +1 -1
- package/docs/examples/console/get-resource.md +14 -0
- package/docs/examples/console/plans.md +1 -1
- package/docs/examples/console/regions.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 +4 -2
- package/docs/examples/databases/create-documents.md +15 -0
- 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 +3 -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 +1 -1
- 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-documents.md +15 -0
- 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-documents.md +16 -0
- 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/databases/upsert-document.md +17 -0
- package/docs/examples/databases/upsert-documents.md +15 -0
- package/docs/examples/domains/create-preset-google-workspace.md +13 -0
- package/docs/examples/domains/create-preset-i-cloud.md +13 -0
- package/docs/examples/domains/create-preset-mailgun.md +13 -0
- package/docs/examples/domains/create-preset-outlook.md +13 -0
- package/docs/examples/domains/create-preset-proton-mail.md +13 -0
- package/docs/examples/domains/create-preset-zoho.md +13 -0
- package/docs/examples/domains/create-record-a-a-a-a.md +17 -0
- package/docs/examples/domains/create-record-a.md +17 -0
- package/docs/examples/domains/create-record-alias.md +17 -0
- package/docs/examples/domains/create-record-c-a-a.md +17 -0
- package/docs/examples/domains/create-record-c-n-a-m-e.md +17 -0
- package/docs/examples/domains/create-record-h-t-t-p-s.md +17 -0
- package/docs/examples/domains/create-record-m-x.md +18 -0
- package/docs/examples/domains/create-record-n-s.md +17 -0
- package/docs/examples/domains/create-record-s-r-v.md +20 -0
- package/docs/examples/domains/create-record-t-x-t.md +17 -0
- package/docs/examples/domains/create.md +14 -0
- package/docs/examples/domains/delete-record.md +14 -0
- package/docs/examples/domains/delete.md +13 -0
- package/docs/examples/domains/get-preset-google-workspace.md +13 -0
- package/docs/examples/domains/get-preset-i-cloud.md +13 -0
- package/docs/examples/domains/get-preset-mailgun.md +13 -0
- package/docs/examples/domains/get-preset-outlook.md +13 -0
- package/docs/examples/domains/get-preset-proton-mail.md +13 -0
- package/docs/examples/domains/get-preset-zoho.md +13 -0
- package/docs/examples/domains/get-record.md +14 -0
- package/docs/examples/domains/get-zone.md +13 -0
- package/docs/examples/domains/get.md +13 -0
- package/docs/examples/domains/list-records.md +14 -0
- package/docs/examples/domains/list.md +14 -0
- package/docs/examples/domains/update-nameservers.md +13 -0
- package/docs/examples/domains/update-record-a-a-a-a.md +18 -0
- package/docs/examples/domains/update-record-a.md +18 -0
- package/docs/examples/domains/update-record-alias.md +18 -0
- package/docs/examples/domains/update-record-c-a-a.md +18 -0
- package/docs/examples/domains/update-record-c-n-a-m-e.md +18 -0
- package/docs/examples/domains/update-record-h-t-t-p-s.md +18 -0
- package/docs/examples/domains/update-record-m-x.md +19 -0
- package/docs/examples/domains/update-record-n-s.md +18 -0
- package/docs/examples/domains/update-record-s-r-v.md +21 -0
- package/docs/examples/domains/update-record-t-x-t.md +18 -0
- package/docs/examples/domains/update-team.md +14 -0
- package/docs/examples/domains/update-zone.md +14 -0
- package/docs/examples/functions/create-deployment.md +1 -1
- package/docs/examples/functions/create-duplicate-deployment.md +15 -0
- package/docs/examples/functions/create-execution.md +1 -1
- package/docs/examples/functions/create-template-deployment.md +18 -0
- package/docs/examples/functions/create-variable.md +3 -2
- package/docs/examples/functions/create-vcs-deployment.md +16 -0
- package/docs/examples/functions/create.md +1 -5
- package/docs/examples/functions/delete-deployment.md +1 -1
- package/docs/examples/functions/delete-execution.md +1 -1
- package/docs/examples/functions/delete-variable.md +1 -1
- package/docs/examples/functions/delete.md +1 -1
- package/docs/examples/functions/get-deployment-download.md +4 -3
- package/docs/examples/functions/get-deployment.md +1 -1
- package/docs/examples/functions/get-execution.md +1 -1
- package/docs/examples/functions/get-template.md +1 -1
- package/docs/examples/functions/get-usage.md +2 -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 +2 -3
- package/docs/examples/functions/list-runtimes.md +1 -1
- package/docs/examples/functions/list-specifications.md +1 -1
- package/docs/examples/functions/list-templates.md +1 -1
- package/docs/examples/functions/list-usage.md +13 -0
- package/docs/examples/functions/list-variables.md +1 -1
- package/docs/examples/functions/list.md +1 -1
- package/docs/examples/functions/update-deployment-status.md +14 -0
- package/docs/examples/functions/update-function-deployment.md +14 -0
- package/docs/examples/functions/update-variable.md +3 -2
- 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 +1 -1
- package/docs/examples/health/get-d-b.md +1 -1
- package/docs/examples/health/get-failed-jobs.md +1 -1
- package/docs/examples/health/get-pub-sub.md +1 -1
- package/docs/examples/health/get-queue-billing-aggregation.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-priority-builds.md +1 -1
- package/docs/examples/health/get-queue-region-manager.md +13 -0
- package/docs/examples/health/get-queue-stats-resources.md +1 -1
- package/docs/examples/health/get-queue-usage.md +1 -1
- package/docs/examples/health/get-queue-webhooks.md +1 -1
- package/docs/examples/health/get-storage-local.md +1 -1
- package/docs/examples/health/get-storage.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 +1 -1
- package/docs/examples/messaging/create-email.md +1 -1
- package/docs/examples/messaging/create-fcm-provider.md +1 -1
- package/docs/examples/messaging/create-mailgun-provider.md +1 -1
- package/docs/examples/messaging/create-msg91provider.md +1 -1
- package/docs/examples/messaging/create-push.md +1 -1
- package/docs/examples/messaging/create-sendgrid-provider.md +1 -1
- package/docs/examples/messaging/create-sms.md +1 -1
- package/docs/examples/messaging/create-smtp-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/delete.md +1 -1
- 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/list-targets.md +1 -1
- package/docs/examples/messaging/list-topic-logs.md +1 -1
- package/docs/examples/messaging/list-topics.md +1 -1
- package/docs/examples/messaging/update-apns-provider.md +1 -1
- package/docs/examples/messaging/update-email.md +1 -1
- package/docs/examples/messaging/update-fcm-provider.md +1 -1
- 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 +1 -1
- package/docs/examples/messaging/update-sendgrid-provider.md +1 -1
- package/docs/examples/messaging/update-sms.md +1 -1
- package/docs/examples/messaging/update-smtp-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-csv-migration.md +15 -0
- package/docs/examples/migrations/create-firebase-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.md +1 -1
- package/docs/examples/migrations/get-appwrite-report.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.md +1 -1
- package/docs/examples/migrations/retry.md +1 -1
- package/docs/examples/organizations/add-credit.md +1 -1
- package/docs/examples/organizations/create-invoice-payment.md +1 -1
- package/docs/examples/organizations/create.md +1 -1
- package/docs/examples/organizations/delete-backup-payment-method.md +1 -1
- package/docs/examples/organizations/delete-billing-address.md +1 -1
- package/docs/examples/organizations/delete-default-payment-method.md +1 -1
- package/docs/examples/organizations/delete.md +1 -1
- package/docs/examples/organizations/get-aggregation.md +1 -1
- package/docs/examples/organizations/get-billing-address.md +1 -1
- package/docs/examples/organizations/get-credit.md +1 -1
- package/docs/examples/organizations/get-invoice-download.md +1 -1
- package/docs/examples/organizations/get-invoice-view.md +1 -1
- package/docs/examples/organizations/get-invoice.md +1 -1
- package/docs/examples/organizations/get-payment-method.md +1 -1
- package/docs/examples/organizations/get-plan.md +1 -1
- package/docs/examples/organizations/get-scopes.md +1 -1
- package/docs/examples/organizations/list-aggregations.md +1 -1
- package/docs/examples/organizations/list-credits.md +1 -1
- package/docs/examples/organizations/list-invoices.md +1 -1
- package/docs/examples/organizations/list.md +1 -1
- package/docs/examples/organizations/set-backup-payment-method.md +1 -1
- package/docs/examples/organizations/set-billing-address.md +1 -1
- package/docs/examples/organizations/set-billing-email.md +1 -1
- package/docs/examples/organizations/set-billing-tax-id.md +1 -1
- package/docs/examples/organizations/set-default-payment-method.md +1 -1
- package/docs/examples/organizations/update-budget.md +1 -1
- package/docs/examples/organizations/update-plan.md +1 -1
- package/docs/examples/organizations/validate-invoice.md +1 -1
- package/docs/examples/project/create-variable.md +3 -2
- package/docs/examples/project/delete-variable.md +1 -1
- package/docs/examples/project/get-usage.md +1 -1
- 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 +3 -2
- package/docs/examples/projects/create-dev-key.md +15 -0
- package/docs/examples/projects/create-j-w-t.md +1 -1
- package/docs/examples/projects/create-key.md +1 -1
- package/docs/examples/projects/create-platform.md +1 -1
- package/docs/examples/projects/create-smtp-test.md +1 -1
- package/docs/examples/projects/create-webhook.md +1 -1
- package/docs/examples/projects/create.md +2 -2
- package/docs/examples/projects/delete-dev-key.md +14 -0
- package/docs/examples/projects/delete-email-template.md +1 -1
- 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 +1 -1
- package/docs/examples/projects/delete-webhook.md +1 -1
- package/docs/examples/projects/delete.md +1 -1
- package/docs/examples/projects/get-dev-key.md +14 -0
- package/docs/examples/projects/get-email-template.md +1 -1
- 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 +1 -1
- package/docs/examples/projects/get-webhook.md +1 -1
- package/docs/examples/projects/get.md +1 -1
- package/docs/examples/projects/list-dev-keys.md +14 -0
- 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-api-status-all.md +1 -1
- package/docs/examples/projects/update-api-status.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 +1 -1
- package/docs/examples/projects/update-dev-key.md +16 -0
- package/docs/examples/projects/update-email-template.md +1 -1
- package/docs/examples/projects/update-key.md +1 -1
- package/docs/examples/projects/update-memberships-privacy.md +1 -1
- package/docs/examples/projects/update-mock-numbers.md +1 -1
- package/docs/examples/projects/update-o-auth2.md +1 -1
- 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 +1 -1
- package/docs/examples/projects/update-session-alerts.md +1 -1
- package/docs/examples/projects/update-sms-template.md +1 -1
- package/docs/examples/projects/update-smtp.md +1 -1
- 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 +1 -1
- package/docs/examples/projects/update.md +1 -1
- package/docs/examples/proxy/create-a-p-i-rule.md +13 -0
- package/docs/examples/proxy/create-function-rule.md +15 -0
- package/docs/examples/proxy/create-redirect-rule.md +15 -0
- package/docs/examples/proxy/create-site-rule.md +15 -0
- 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/sites/create-deployment.md +18 -0
- package/docs/examples/sites/create-duplicate-deployment.md +14 -0
- package/docs/examples/sites/create-template-deployment.md +18 -0
- package/docs/examples/sites/create-variable.md +16 -0
- package/docs/examples/sites/create-vcs-deployment.md +16 -0
- package/docs/examples/sites/create.md +30 -0
- package/docs/examples/sites/delete-deployment.md +14 -0
- package/docs/examples/sites/delete-log.md +14 -0
- package/docs/examples/sites/delete-variable.md +14 -0
- package/docs/examples/sites/delete.md +13 -0
- package/docs/examples/sites/get-deployment-download.md +15 -0
- package/docs/examples/sites/get-deployment.md +14 -0
- package/docs/examples/sites/get-log.md +14 -0
- package/docs/examples/sites/get-template.md +13 -0
- package/docs/examples/sites/get-usage.md +14 -0
- package/docs/examples/sites/get-variable.md +14 -0
- package/docs/examples/sites/get.md +13 -0
- package/docs/examples/sites/list-deployments.md +15 -0
- package/docs/examples/sites/list-frameworks.md +11 -0
- package/docs/examples/sites/list-logs.md +14 -0
- package/docs/examples/sites/list-specifications.md +11 -0
- package/docs/examples/sites/list-templates.md +16 -0
- package/docs/examples/sites/list-usage.md +13 -0
- package/docs/examples/sites/list-variables.md +13 -0
- package/docs/examples/sites/list.md +14 -0
- package/docs/examples/sites/update-deployment-status.md +14 -0
- package/docs/examples/sites/update-site-deployment.md +14 -0
- package/docs/examples/sites/update-variable.md +17 -0
- package/docs/examples/sites/update.md +30 -0
- 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 +3 -2
- package/docs/examples/storage/get-file-preview.md +4 -3
- package/docs/examples/storage/get-file-view.md +3 -2
- 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/tokens/create-file-token.md +15 -0
- package/docs/examples/tokens/delete.md +13 -0
- package/docs/examples/tokens/get.md +13 -0
- package/docs/examples/tokens/list.md +15 -0
- package/docs/examples/tokens/update.md +14 -0
- package/docs/examples/users/create-argon2user.md +1 -1
- package/docs/examples/users/create-bcrypt-user.md +1 -1
- package/docs/examples/users/create-j-w-t.md +1 -1
- package/docs/examples/users/create-m-d5user.md +1 -1
- package/docs/examples/users/create-mfa-recovery-codes.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 +1 -1
- package/docs/examples/users/create-target.md +1 -1
- package/docs/examples/users/create-token.md +1 -1
- package/docs/examples/users/create.md +1 -1
- package/docs/examples/users/delete-identity.md +1 -1
- package/docs/examples/users/delete-mfa-authenticator.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-mfa-recovery-codes.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-identities.md +1 -1
- package/docs/examples/users/list-logs.md +1 -1
- package/docs/examples/users/list-memberships.md +4 -2
- package/docs/examples/users/list-mfa-factors.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-recovery-codes.md +1 -1
- package/docs/examples/users/update-mfa.md +1 -1
- 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 +3 -2
- 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-contents.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 +3 -2
- 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 +16 -3
- package/src/enums/adapter.ts +4 -0
- package/src/enums/api-service.ts +1 -0
- package/src/enums/build-runtime.ts +62 -0
- package/src/enums/console-resource-type.ts +3 -0
- package/src/enums/deployment-download-type.ts +4 -0
- package/src/enums/framework.ts +16 -0
- package/src/enums/image-format.ts +0 -1
- package/src/enums/name.ts +0 -1
- package/src/enums/region.ts +2 -1
- package/src/enums/runtime.ts +4 -3
- package/src/enums/site-usage-range.ts +5 -0
- package/src/enums/status-code.ts +6 -0
- package/src/enums/v-c-s-deployment-type.ts +5 -0
- package/src/enums/v-c-s-detection-type.ts +4 -0
- package/src/index.ts +13 -2
- package/src/models.ts +1100 -217
- package/src/services/account.ts +0 -16
- package/src/services/avatars.ts +0 -7
- package/src/services/backups.ts +0 -6
- package/src/services/console.ts +36 -5
- package/src/services/databases.ts +194 -18
- package/src/services/domains.ts +1821 -0
- package/src/services/functions.ts +170 -81
- package/src/services/health.ts +9 -34
- package/src/services/locale.ts +0 -8
- package/src/services/messaging.ts +0 -13
- package/src/services/migrations.ts +43 -6
- package/src/services/organizations.ts +0 -47
- package/src/services/project.ts +10 -5
- package/src/services/projects.ts +172 -10
- package/src/services/proxy.ts +124 -14
- package/src/services/sites.ts +1104 -0
- package/src/services/storage.ts +15 -12
- package/src/services/teams.ts +0 -6
- package/src/services/tokens.ts +160 -0
- package/src/services/users.ts +9 -13
- package/src/services/vcs.ts +54 -42
- package/types/enums/adapter.d.ts +4 -0
- package/types/enums/api-service.d.ts +1 -0
- package/types/enums/build-runtime.d.ts +62 -0
- package/types/enums/console-resource-type.d.ts +3 -0
- package/types/enums/deployment-download-type.d.ts +4 -0
- package/types/enums/framework.d.ts +16 -0
- package/types/enums/image-format.d.ts +0 -1
- package/types/enums/name.d.ts +0 -1
- package/types/enums/region.d.ts +3 -2
- package/types/enums/runtime.d.ts +5 -4
- package/types/enums/site-usage-range.d.ts +5 -0
- package/types/enums/status-code.d.ts +6 -0
- package/types/enums/v-c-s-deployment-type.d.ts +5 -0
- package/types/enums/v-c-s-detection-type.d.ts +4 -0
- package/types/index.d.ts +13 -2
- package/types/models.d.ts +1100 -217
- package/types/services/console.d.ts +10 -0
- package/types/services/databases.d.ts +56 -2
- package/types/services/domains.d.ts +524 -0
- package/types/services/functions.d.ts +59 -33
- package/types/services/health.d.ts +6 -6
- package/types/services/migrations.d.ts +10 -0
- package/types/services/organizations.d.ts +0 -10
- package/types/services/project.d.ts +4 -2
- package/types/services/projects.d.ts +48 -0
- package/types/services/proxy.d.ts +33 -5
- package/types/services/sites.d.ts +319 -0
- package/types/services/storage.d.ts +6 -3
- package/types/services/tokens.d.ts +51 -0
- package/types/services/users.d.ts +3 -1
- package/types/services/vcs.d.ts +15 -12
|
@@ -3,6 +3,8 @@ import { AppwriteException, Client, type Payload, UploadProgress } from '../clie
|
|
|
3
3
|
import type { Models } from '../models';
|
|
4
4
|
import { Runtime } from '../enums/runtime';
|
|
5
5
|
import { FunctionUsageRange } from '../enums/function-usage-range';
|
|
6
|
+
import { VCSDeploymentType } from '../enums/v-c-s-deployment-type';
|
|
7
|
+
import { DeploymentDownloadType } from '../enums/deployment-download-type';
|
|
6
8
|
import { ExecutionMethod } from '../enums/execution-method';
|
|
7
9
|
|
|
8
10
|
export class Functions {
|
|
@@ -32,7 +34,6 @@ export class Functions {
|
|
|
32
34
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
33
35
|
|
|
34
36
|
const apiHeaders: { [header: string]: string } = {
|
|
35
|
-
'content-type': 'application/json',
|
|
36
37
|
}
|
|
37
38
|
|
|
38
39
|
return this.client.call(
|
|
@@ -62,15 +63,11 @@ export class Functions {
|
|
|
62
63
|
* @param {string} providerBranch
|
|
63
64
|
* @param {boolean} providerSilentMode
|
|
64
65
|
* @param {string} providerRootDirectory
|
|
65
|
-
* @param {string} templateRepository
|
|
66
|
-
* @param {string} templateOwner
|
|
67
|
-
* @param {string} templateRootDirectory
|
|
68
|
-
* @param {string} templateVersion
|
|
69
66
|
* @param {string} specification
|
|
70
67
|
* @throws {AppwriteException}
|
|
71
68
|
* @returns {Promise<Models.Function>}
|
|
72
69
|
*/
|
|
73
|
-
create(functionId: string, name: string, runtime: Runtime, execute?: string[], events?: string[], schedule?: string, timeout?: number, enabled?: boolean, logging?: boolean, entrypoint?: string, commands?: string, scopes?: string[], installationId?: string, providerRepositoryId?: string, providerBranch?: string, providerSilentMode?: boolean, providerRootDirectory?: string,
|
|
70
|
+
create(functionId: string, name: string, runtime: Runtime, execute?: string[], events?: string[], schedule?: string, timeout?: number, enabled?: boolean, logging?: boolean, entrypoint?: string, commands?: string, scopes?: string[], installationId?: string, providerRepositoryId?: string, providerBranch?: string, providerSilentMode?: boolean, providerRootDirectory?: string, specification?: string): Promise<Models.Function> {
|
|
74
71
|
if (typeof functionId === 'undefined') {
|
|
75
72
|
throw new AppwriteException('Missing required parameter: "functionId"');
|
|
76
73
|
}
|
|
@@ -133,18 +130,6 @@ export class Functions {
|
|
|
133
130
|
if (typeof providerRootDirectory !== 'undefined') {
|
|
134
131
|
payload['providerRootDirectory'] = providerRootDirectory;
|
|
135
132
|
}
|
|
136
|
-
if (typeof templateRepository !== 'undefined') {
|
|
137
|
-
payload['templateRepository'] = templateRepository;
|
|
138
|
-
}
|
|
139
|
-
if (typeof templateOwner !== 'undefined') {
|
|
140
|
-
payload['templateOwner'] = templateOwner;
|
|
141
|
-
}
|
|
142
|
-
if (typeof templateRootDirectory !== 'undefined') {
|
|
143
|
-
payload['templateRootDirectory'] = templateRootDirectory;
|
|
144
|
-
}
|
|
145
|
-
if (typeof templateVersion !== 'undefined') {
|
|
146
|
-
payload['templateVersion'] = templateVersion;
|
|
147
|
-
}
|
|
148
133
|
if (typeof specification !== 'undefined') {
|
|
149
134
|
payload['specification'] = specification;
|
|
150
135
|
}
|
|
@@ -173,7 +158,6 @@ export class Functions {
|
|
|
173
158
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
174
159
|
|
|
175
160
|
const apiHeaders: { [header: string]: string } = {
|
|
176
|
-
'content-type': 'application/json',
|
|
177
161
|
}
|
|
178
162
|
|
|
179
163
|
return this.client.call(
|
|
@@ -185,7 +169,6 @@ export class Functions {
|
|
|
185
169
|
}
|
|
186
170
|
/**
|
|
187
171
|
* List allowed function specifications for this instance.
|
|
188
|
-
|
|
189
172
|
*
|
|
190
173
|
* @throws {AppwriteException}
|
|
191
174
|
* @returns {Promise<Models.SpecificationList>}
|
|
@@ -196,7 +179,6 @@ export class Functions {
|
|
|
196
179
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
197
180
|
|
|
198
181
|
const apiHeaders: { [header: string]: string } = {
|
|
199
|
-
'content-type': 'application/json',
|
|
200
182
|
}
|
|
201
183
|
|
|
202
184
|
return this.client.call(
|
|
@@ -234,7 +216,6 @@ export class Functions {
|
|
|
234
216
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
235
217
|
|
|
236
218
|
const apiHeaders: { [header: string]: string } = {
|
|
237
|
-
'content-type': 'application/json',
|
|
238
219
|
}
|
|
239
220
|
|
|
240
221
|
return this.client.call(
|
|
@@ -260,7 +241,6 @@ export class Functions {
|
|
|
260
241
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
261
242
|
|
|
262
243
|
const apiHeaders: { [header: string]: string } = {
|
|
263
|
-
'content-type': 'application/json',
|
|
264
244
|
}
|
|
265
245
|
|
|
266
246
|
return this.client.call(
|
|
@@ -271,13 +251,13 @@ export class Functions {
|
|
|
271
251
|
);
|
|
272
252
|
}
|
|
273
253
|
/**
|
|
274
|
-
* Get usage metrics and statistics for
|
|
254
|
+
* Get usage metrics and statistics for all functions in the project. View statistics including total deployments, builds, logs, storage usage, and compute time. The response includes both current totals and historical data for each metric. Use the optional range parameter to specify the time window for historical data: 24h (last 24 hours), 30d (last 30 days), or 90d (last 90 days). If not specified, defaults to 30 days.
|
|
275
255
|
*
|
|
276
256
|
* @param {FunctionUsageRange} range
|
|
277
257
|
* @throws {AppwriteException}
|
|
278
258
|
* @returns {Promise<Models.UsageFunctions>}
|
|
279
259
|
*/
|
|
280
|
-
|
|
260
|
+
listUsage(range?: FunctionUsageRange): Promise<Models.UsageFunctions> {
|
|
281
261
|
const apiPath = '/functions/usage';
|
|
282
262
|
const payload: Payload = {};
|
|
283
263
|
if (typeof range !== 'undefined') {
|
|
@@ -286,7 +266,6 @@ export class Functions {
|
|
|
286
266
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
287
267
|
|
|
288
268
|
const apiHeaders: { [header: string]: string } = {
|
|
289
|
-
'content-type': 'application/json',
|
|
290
269
|
}
|
|
291
270
|
|
|
292
271
|
return this.client.call(
|
|
@@ -312,7 +291,6 @@ export class Functions {
|
|
|
312
291
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
313
292
|
|
|
314
293
|
const apiHeaders: { [header: string]: string } = {
|
|
315
|
-
'content-type': 'application/json',
|
|
316
294
|
}
|
|
317
295
|
|
|
318
296
|
return this.client.call(
|
|
@@ -446,7 +424,40 @@ export class Functions {
|
|
|
446
424
|
);
|
|
447
425
|
}
|
|
448
426
|
/**
|
|
449
|
-
*
|
|
427
|
+
* Update the function active deployment. Use this endpoint to switch the code deployment that should be used when visitor opens your function.
|
|
428
|
+
*
|
|
429
|
+
* @param {string} functionId
|
|
430
|
+
* @param {string} deploymentId
|
|
431
|
+
* @throws {AppwriteException}
|
|
432
|
+
* @returns {Promise<Models.Function>}
|
|
433
|
+
*/
|
|
434
|
+
updateFunctionDeployment(functionId: string, deploymentId: string): Promise<Models.Function> {
|
|
435
|
+
if (typeof functionId === 'undefined') {
|
|
436
|
+
throw new AppwriteException('Missing required parameter: "functionId"');
|
|
437
|
+
}
|
|
438
|
+
if (typeof deploymentId === 'undefined') {
|
|
439
|
+
throw new AppwriteException('Missing required parameter: "deploymentId"');
|
|
440
|
+
}
|
|
441
|
+
const apiPath = '/functions/{functionId}/deployment'.replace('{functionId}', functionId);
|
|
442
|
+
const payload: Payload = {};
|
|
443
|
+
if (typeof deploymentId !== 'undefined') {
|
|
444
|
+
payload['deploymentId'] = deploymentId;
|
|
445
|
+
}
|
|
446
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
447
|
+
|
|
448
|
+
const apiHeaders: { [header: string]: string } = {
|
|
449
|
+
'content-type': 'application/json',
|
|
450
|
+
}
|
|
451
|
+
|
|
452
|
+
return this.client.call(
|
|
453
|
+
'patch',
|
|
454
|
+
uri,
|
|
455
|
+
apiHeaders,
|
|
456
|
+
payload
|
|
457
|
+
);
|
|
458
|
+
}
|
|
459
|
+
/**
|
|
460
|
+
* Get a list of all the function's code deployments. You can use the query params to filter your results.
|
|
450
461
|
*
|
|
451
462
|
* @param {string} functionId
|
|
452
463
|
* @param {string[]} queries
|
|
@@ -469,7 +480,6 @@ export class Functions {
|
|
|
469
480
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
470
481
|
|
|
471
482
|
const apiHeaders: { [header: string]: string } = {
|
|
472
|
-
'content-type': 'application/json',
|
|
473
483
|
}
|
|
474
484
|
|
|
475
485
|
return this.client.call(
|
|
@@ -533,22 +543,29 @@ Use the "command" param to set the entrypoint used to execute your cod
|
|
|
533
543
|
);
|
|
534
544
|
}
|
|
535
545
|
/**
|
|
536
|
-
*
|
|
546
|
+
* Create a new build for an existing function deployment. This endpoint allows you to rebuild a deployment with the updated function configuration, including its entrypoint and build commands if they have been modified. The build process will be queued and executed asynchronously. The original deployment's code will be preserved and used for the new build.
|
|
537
547
|
*
|
|
538
548
|
* @param {string} functionId
|
|
539
549
|
* @param {string} deploymentId
|
|
550
|
+
* @param {string} buildId
|
|
540
551
|
* @throws {AppwriteException}
|
|
541
552
|
* @returns {Promise<Models.Deployment>}
|
|
542
553
|
*/
|
|
543
|
-
|
|
554
|
+
createDuplicateDeployment(functionId: string, deploymentId: string, buildId?: string): Promise<Models.Deployment> {
|
|
544
555
|
if (typeof functionId === 'undefined') {
|
|
545
556
|
throw new AppwriteException('Missing required parameter: "functionId"');
|
|
546
557
|
}
|
|
547
558
|
if (typeof deploymentId === 'undefined') {
|
|
548
559
|
throw new AppwriteException('Missing required parameter: "deploymentId"');
|
|
549
560
|
}
|
|
550
|
-
const apiPath = '/functions/{functionId}/deployments/
|
|
561
|
+
const apiPath = '/functions/{functionId}/deployments/duplicate'.replace('{functionId}', functionId);
|
|
551
562
|
const payload: Payload = {};
|
|
563
|
+
if (typeof deploymentId !== 'undefined') {
|
|
564
|
+
payload['deploymentId'] = deploymentId;
|
|
565
|
+
}
|
|
566
|
+
if (typeof buildId !== 'undefined') {
|
|
567
|
+
payload['buildId'] = buildId;
|
|
568
|
+
}
|
|
552
569
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
553
570
|
|
|
554
571
|
const apiHeaders: { [header: string]: string } = {
|
|
@@ -556,29 +573,59 @@ Use the "command" param to set the entrypoint used to execute your cod
|
|
|
556
573
|
}
|
|
557
574
|
|
|
558
575
|
return this.client.call(
|
|
559
|
-
'
|
|
576
|
+
'post',
|
|
560
577
|
uri,
|
|
561
578
|
apiHeaders,
|
|
562
579
|
payload
|
|
563
580
|
);
|
|
564
581
|
}
|
|
565
582
|
/**
|
|
566
|
-
*
|
|
583
|
+
* Create a deployment based on a template.
|
|
584
|
+
|
|
585
|
+
Use this endpoint with combination of [listTemplates](https://appwrite.io/docs/server/functions#listTemplates) to find the template details.
|
|
567
586
|
*
|
|
568
587
|
* @param {string} functionId
|
|
569
|
-
* @param {string}
|
|
588
|
+
* @param {string} repository
|
|
589
|
+
* @param {string} owner
|
|
590
|
+
* @param {string} rootDirectory
|
|
591
|
+
* @param {string} version
|
|
592
|
+
* @param {boolean} activate
|
|
570
593
|
* @throws {AppwriteException}
|
|
571
|
-
* @returns {Promise<Models.
|
|
594
|
+
* @returns {Promise<Models.Deployment>}
|
|
572
595
|
*/
|
|
573
|
-
|
|
596
|
+
createTemplateDeployment(functionId: string, repository: string, owner: string, rootDirectory: string, version: string, activate?: boolean): Promise<Models.Deployment> {
|
|
574
597
|
if (typeof functionId === 'undefined') {
|
|
575
598
|
throw new AppwriteException('Missing required parameter: "functionId"');
|
|
576
599
|
}
|
|
577
|
-
if (typeof
|
|
578
|
-
throw new AppwriteException('Missing required parameter: "
|
|
600
|
+
if (typeof repository === 'undefined') {
|
|
601
|
+
throw new AppwriteException('Missing required parameter: "repository"');
|
|
579
602
|
}
|
|
580
|
-
|
|
603
|
+
if (typeof owner === 'undefined') {
|
|
604
|
+
throw new AppwriteException('Missing required parameter: "owner"');
|
|
605
|
+
}
|
|
606
|
+
if (typeof rootDirectory === 'undefined') {
|
|
607
|
+
throw new AppwriteException('Missing required parameter: "rootDirectory"');
|
|
608
|
+
}
|
|
609
|
+
if (typeof version === 'undefined') {
|
|
610
|
+
throw new AppwriteException('Missing required parameter: "version"');
|
|
611
|
+
}
|
|
612
|
+
const apiPath = '/functions/{functionId}/deployments/template'.replace('{functionId}', functionId);
|
|
581
613
|
const payload: Payload = {};
|
|
614
|
+
if (typeof repository !== 'undefined') {
|
|
615
|
+
payload['repository'] = repository;
|
|
616
|
+
}
|
|
617
|
+
if (typeof owner !== 'undefined') {
|
|
618
|
+
payload['owner'] = owner;
|
|
619
|
+
}
|
|
620
|
+
if (typeof rootDirectory !== 'undefined') {
|
|
621
|
+
payload['rootDirectory'] = rootDirectory;
|
|
622
|
+
}
|
|
623
|
+
if (typeof version !== 'undefined') {
|
|
624
|
+
payload['version'] = version;
|
|
625
|
+
}
|
|
626
|
+
if (typeof activate !== 'undefined') {
|
|
627
|
+
payload['activate'] = activate;
|
|
628
|
+
}
|
|
582
629
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
583
630
|
|
|
584
631
|
const apiHeaders: { [header: string]: string } = {
|
|
@@ -586,29 +633,45 @@ Use the "command" param to set the entrypoint used to execute your cod
|
|
|
586
633
|
}
|
|
587
634
|
|
|
588
635
|
return this.client.call(
|
|
589
|
-
'
|
|
636
|
+
'post',
|
|
590
637
|
uri,
|
|
591
638
|
apiHeaders,
|
|
592
639
|
payload
|
|
593
640
|
);
|
|
594
641
|
}
|
|
595
642
|
/**
|
|
596
|
-
*
|
|
643
|
+
* Create a deployment when a function is connected to VCS.
|
|
644
|
+
|
|
645
|
+
This endpoint lets you create deployment from a branch, commit, or a tag.
|
|
597
646
|
*
|
|
598
647
|
* @param {string} functionId
|
|
599
|
-
* @param {
|
|
648
|
+
* @param {VCSDeploymentType} type
|
|
649
|
+
* @param {string} reference
|
|
650
|
+
* @param {boolean} activate
|
|
600
651
|
* @throws {AppwriteException}
|
|
601
|
-
* @returns {Promise<
|
|
652
|
+
* @returns {Promise<Models.Deployment>}
|
|
602
653
|
*/
|
|
603
|
-
|
|
654
|
+
createVcsDeployment(functionId: string, type: VCSDeploymentType, reference: string, activate?: boolean): Promise<Models.Deployment> {
|
|
604
655
|
if (typeof functionId === 'undefined') {
|
|
605
656
|
throw new AppwriteException('Missing required parameter: "functionId"');
|
|
606
657
|
}
|
|
607
|
-
if (typeof
|
|
608
|
-
throw new AppwriteException('Missing required parameter: "
|
|
658
|
+
if (typeof type === 'undefined') {
|
|
659
|
+
throw new AppwriteException('Missing required parameter: "type"');
|
|
609
660
|
}
|
|
610
|
-
|
|
661
|
+
if (typeof reference === 'undefined') {
|
|
662
|
+
throw new AppwriteException('Missing required parameter: "reference"');
|
|
663
|
+
}
|
|
664
|
+
const apiPath = '/functions/{functionId}/deployments/vcs'.replace('{functionId}', functionId);
|
|
611
665
|
const payload: Payload = {};
|
|
666
|
+
if (typeof type !== 'undefined') {
|
|
667
|
+
payload['type'] = type;
|
|
668
|
+
}
|
|
669
|
+
if (typeof reference !== 'undefined') {
|
|
670
|
+
payload['reference'] = reference;
|
|
671
|
+
}
|
|
672
|
+
if (typeof activate !== 'undefined') {
|
|
673
|
+
payload['activate'] = activate;
|
|
674
|
+
}
|
|
612
675
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
613
676
|
|
|
614
677
|
const apiHeaders: { [header: string]: string } = {
|
|
@@ -616,62 +679,57 @@ Use the "command" param to set the entrypoint used to execute your cod
|
|
|
616
679
|
}
|
|
617
680
|
|
|
618
681
|
return this.client.call(
|
|
619
|
-
'
|
|
682
|
+
'post',
|
|
620
683
|
uri,
|
|
621
684
|
apiHeaders,
|
|
622
685
|
payload
|
|
623
686
|
);
|
|
624
687
|
}
|
|
625
688
|
/**
|
|
626
|
-
*
|
|
689
|
+
* Get a function deployment by its unique ID.
|
|
627
690
|
*
|
|
628
691
|
* @param {string} functionId
|
|
629
692
|
* @param {string} deploymentId
|
|
630
|
-
* @param {string} buildId
|
|
631
693
|
* @throws {AppwriteException}
|
|
632
|
-
* @returns {Promise<
|
|
694
|
+
* @returns {Promise<Models.Deployment>}
|
|
633
695
|
*/
|
|
634
|
-
|
|
696
|
+
getDeployment(functionId: string, deploymentId: string): Promise<Models.Deployment> {
|
|
635
697
|
if (typeof functionId === 'undefined') {
|
|
636
698
|
throw new AppwriteException('Missing required parameter: "functionId"');
|
|
637
699
|
}
|
|
638
700
|
if (typeof deploymentId === 'undefined') {
|
|
639
701
|
throw new AppwriteException('Missing required parameter: "deploymentId"');
|
|
640
702
|
}
|
|
641
|
-
const apiPath = '/functions/{functionId}/deployments/{deploymentId}
|
|
703
|
+
const apiPath = '/functions/{functionId}/deployments/{deploymentId}'.replace('{functionId}', functionId).replace('{deploymentId}', deploymentId);
|
|
642
704
|
const payload: Payload = {};
|
|
643
|
-
if (typeof buildId !== 'undefined') {
|
|
644
|
-
payload['buildId'] = buildId;
|
|
645
|
-
}
|
|
646
705
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
647
706
|
|
|
648
707
|
const apiHeaders: { [header: string]: string } = {
|
|
649
|
-
'content-type': 'application/json',
|
|
650
708
|
}
|
|
651
709
|
|
|
652
710
|
return this.client.call(
|
|
653
|
-
'
|
|
711
|
+
'get',
|
|
654
712
|
uri,
|
|
655
713
|
apiHeaders,
|
|
656
714
|
payload
|
|
657
715
|
);
|
|
658
716
|
}
|
|
659
717
|
/**
|
|
660
|
-
*
|
|
718
|
+
* Delete a code deployment by its unique ID.
|
|
661
719
|
*
|
|
662
720
|
* @param {string} functionId
|
|
663
721
|
* @param {string} deploymentId
|
|
664
722
|
* @throws {AppwriteException}
|
|
665
|
-
* @returns {Promise<
|
|
723
|
+
* @returns {Promise<{}>}
|
|
666
724
|
*/
|
|
667
|
-
|
|
725
|
+
deleteDeployment(functionId: string, deploymentId: string): Promise<{}> {
|
|
668
726
|
if (typeof functionId === 'undefined') {
|
|
669
727
|
throw new AppwriteException('Missing required parameter: "functionId"');
|
|
670
728
|
}
|
|
671
729
|
if (typeof deploymentId === 'undefined') {
|
|
672
730
|
throw new AppwriteException('Missing required parameter: "deploymentId"');
|
|
673
731
|
}
|
|
674
|
-
const apiPath = '/functions/{functionId}/deployments/{deploymentId}
|
|
732
|
+
const apiPath = '/functions/{functionId}/deployments/{deploymentId}'.replace('{functionId}', functionId).replace('{deploymentId}', deploymentId);
|
|
675
733
|
const payload: Payload = {};
|
|
676
734
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
677
735
|
|
|
@@ -680,21 +738,22 @@ Use the "command" param to set the entrypoint used to execute your cod
|
|
|
680
738
|
}
|
|
681
739
|
|
|
682
740
|
return this.client.call(
|
|
683
|
-
'
|
|
741
|
+
'delete',
|
|
684
742
|
uri,
|
|
685
743
|
apiHeaders,
|
|
686
744
|
payload
|
|
687
745
|
);
|
|
688
746
|
}
|
|
689
747
|
/**
|
|
690
|
-
* Get a
|
|
748
|
+
* Get a function deployment content by its unique ID. The endpoint response return with a 'Content-Disposition: attachment' header that tells the browser to start downloading the file to user downloads directory.
|
|
691
749
|
*
|
|
692
750
|
* @param {string} functionId
|
|
693
751
|
* @param {string} deploymentId
|
|
752
|
+
* @param {DeploymentDownloadType} type
|
|
694
753
|
* @throws {AppwriteException}
|
|
695
754
|
* @returns {string}
|
|
696
755
|
*/
|
|
697
|
-
getDeploymentDownload(functionId: string, deploymentId: string): string {
|
|
756
|
+
getDeploymentDownload(functionId: string, deploymentId: string, type?: DeploymentDownloadType): string {
|
|
698
757
|
if (typeof functionId === 'undefined') {
|
|
699
758
|
throw new AppwriteException('Missing required parameter: "functionId"');
|
|
700
759
|
}
|
|
@@ -703,10 +762,12 @@ Use the "command" param to set the entrypoint used to execute your cod
|
|
|
703
762
|
}
|
|
704
763
|
const apiPath = '/functions/{functionId}/deployments/{deploymentId}/download'.replace('{functionId}', functionId).replace('{deploymentId}', deploymentId);
|
|
705
764
|
const payload: Payload = {};
|
|
765
|
+
if (typeof type !== 'undefined') {
|
|
766
|
+
payload['type'] = type;
|
|
767
|
+
}
|
|
706
768
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
707
769
|
|
|
708
770
|
const apiHeaders: { [header: string]: string } = {
|
|
709
|
-
'content-type': 'application/json',
|
|
710
771
|
}
|
|
711
772
|
|
|
712
773
|
payload['project'] = this.client.config.project;
|
|
@@ -717,16 +778,45 @@ Use the "command" param to set the entrypoint used to execute your cod
|
|
|
717
778
|
|
|
718
779
|
return uri.toString();
|
|
719
780
|
}
|
|
781
|
+
/**
|
|
782
|
+
* Cancel an ongoing function deployment build. If the build is already in progress, it will be stopped and marked as canceled. If the build hasn't started yet, it will be marked as canceled without executing. You cannot cancel builds that have already completed (status 'ready') or failed. The response includes the final build status and details.
|
|
783
|
+
*
|
|
784
|
+
* @param {string} functionId
|
|
785
|
+
* @param {string} deploymentId
|
|
786
|
+
* @throws {AppwriteException}
|
|
787
|
+
* @returns {Promise<Models.Deployment>}
|
|
788
|
+
*/
|
|
789
|
+
updateDeploymentStatus(functionId: string, deploymentId: string): Promise<Models.Deployment> {
|
|
790
|
+
if (typeof functionId === 'undefined') {
|
|
791
|
+
throw new AppwriteException('Missing required parameter: "functionId"');
|
|
792
|
+
}
|
|
793
|
+
if (typeof deploymentId === 'undefined') {
|
|
794
|
+
throw new AppwriteException('Missing required parameter: "deploymentId"');
|
|
795
|
+
}
|
|
796
|
+
const apiPath = '/functions/{functionId}/deployments/{deploymentId}/status'.replace('{functionId}', functionId).replace('{deploymentId}', deploymentId);
|
|
797
|
+
const payload: Payload = {};
|
|
798
|
+
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
799
|
+
|
|
800
|
+
const apiHeaders: { [header: string]: string } = {
|
|
801
|
+
'content-type': 'application/json',
|
|
802
|
+
}
|
|
803
|
+
|
|
804
|
+
return this.client.call(
|
|
805
|
+
'patch',
|
|
806
|
+
uri,
|
|
807
|
+
apiHeaders,
|
|
808
|
+
payload
|
|
809
|
+
);
|
|
810
|
+
}
|
|
720
811
|
/**
|
|
721
812
|
* Get a list of all the current user function execution logs. You can use the query params to filter your results.
|
|
722
813
|
*
|
|
723
814
|
* @param {string} functionId
|
|
724
815
|
* @param {string[]} queries
|
|
725
|
-
* @param {string} search
|
|
726
816
|
* @throws {AppwriteException}
|
|
727
817
|
* @returns {Promise<Models.ExecutionList>}
|
|
728
818
|
*/
|
|
729
|
-
listExecutions(functionId: string, queries?: string[]
|
|
819
|
+
listExecutions(functionId: string, queries?: string[]): Promise<Models.ExecutionList> {
|
|
730
820
|
if (typeof functionId === 'undefined') {
|
|
731
821
|
throw new AppwriteException('Missing required parameter: "functionId"');
|
|
732
822
|
}
|
|
@@ -735,13 +825,9 @@ Use the "command" param to set the entrypoint used to execute your cod
|
|
|
735
825
|
if (typeof queries !== 'undefined') {
|
|
736
826
|
payload['queries'] = queries;
|
|
737
827
|
}
|
|
738
|
-
if (typeof search !== 'undefined') {
|
|
739
|
-
payload['search'] = search;
|
|
740
|
-
}
|
|
741
828
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
742
829
|
|
|
743
830
|
const apiHeaders: { [header: string]: string } = {
|
|
744
|
-
'content-type': 'application/json',
|
|
745
831
|
}
|
|
746
832
|
|
|
747
833
|
return this.client.call(
|
|
@@ -821,7 +907,6 @@ Use the "command" param to set the entrypoint used to execute your cod
|
|
|
821
907
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
822
908
|
|
|
823
909
|
const apiHeaders: { [header: string]: string } = {
|
|
824
|
-
'content-type': 'application/json',
|
|
825
910
|
}
|
|
826
911
|
|
|
827
912
|
return this.client.call(
|
|
@@ -833,7 +918,6 @@ Use the "command" param to set the entrypoint used to execute your cod
|
|
|
833
918
|
}
|
|
834
919
|
/**
|
|
835
920
|
* Delete a function execution by its unique ID.
|
|
836
|
-
|
|
837
921
|
*
|
|
838
922
|
* @param {string} functionId
|
|
839
923
|
* @param {string} executionId
|
|
@@ -870,7 +954,7 @@ Use the "command" param to set the entrypoint used to execute your cod
|
|
|
870
954
|
* @throws {AppwriteException}
|
|
871
955
|
* @returns {Promise<Models.UsageFunction>}
|
|
872
956
|
*/
|
|
873
|
-
|
|
957
|
+
getUsage(functionId: string, range?: FunctionUsageRange): Promise<Models.UsageFunction> {
|
|
874
958
|
if (typeof functionId === 'undefined') {
|
|
875
959
|
throw new AppwriteException('Missing required parameter: "functionId"');
|
|
876
960
|
}
|
|
@@ -882,7 +966,6 @@ Use the "command" param to set the entrypoint used to execute your cod
|
|
|
882
966
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
883
967
|
|
|
884
968
|
const apiHeaders: { [header: string]: string } = {
|
|
885
|
-
'content-type': 'application/json',
|
|
886
969
|
}
|
|
887
970
|
|
|
888
971
|
return this.client.call(
|
|
@@ -908,7 +991,6 @@ Use the "command" param to set the entrypoint used to execute your cod
|
|
|
908
991
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
909
992
|
|
|
910
993
|
const apiHeaders: { [header: string]: string } = {
|
|
911
|
-
'content-type': 'application/json',
|
|
912
994
|
}
|
|
913
995
|
|
|
914
996
|
return this.client.call(
|
|
@@ -924,10 +1006,11 @@ Use the "command" param to set the entrypoint used to execute your cod
|
|
|
924
1006
|
* @param {string} functionId
|
|
925
1007
|
* @param {string} key
|
|
926
1008
|
* @param {string} value
|
|
1009
|
+
* @param {boolean} secret
|
|
927
1010
|
* @throws {AppwriteException}
|
|
928
1011
|
* @returns {Promise<Models.Variable>}
|
|
929
1012
|
*/
|
|
930
|
-
createVariable(functionId: string, key: string, value: string): Promise<Models.Variable> {
|
|
1013
|
+
createVariable(functionId: string, key: string, value: string, secret?: boolean): Promise<Models.Variable> {
|
|
931
1014
|
if (typeof functionId === 'undefined') {
|
|
932
1015
|
throw new AppwriteException('Missing required parameter: "functionId"');
|
|
933
1016
|
}
|
|
@@ -945,6 +1028,9 @@ Use the "command" param to set the entrypoint used to execute your cod
|
|
|
945
1028
|
if (typeof value !== 'undefined') {
|
|
946
1029
|
payload['value'] = value;
|
|
947
1030
|
}
|
|
1031
|
+
if (typeof secret !== 'undefined') {
|
|
1032
|
+
payload['secret'] = secret;
|
|
1033
|
+
}
|
|
948
1034
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
949
1035
|
|
|
950
1036
|
const apiHeaders: { [header: string]: string } = {
|
|
@@ -978,7 +1064,6 @@ Use the "command" param to set the entrypoint used to execute your cod
|
|
|
978
1064
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
979
1065
|
|
|
980
1066
|
const apiHeaders: { [header: string]: string } = {
|
|
981
|
-
'content-type': 'application/json',
|
|
982
1067
|
}
|
|
983
1068
|
|
|
984
1069
|
return this.client.call(
|
|
@@ -995,10 +1080,11 @@ Use the "command" param to set the entrypoint used to execute your cod
|
|
|
995
1080
|
* @param {string} variableId
|
|
996
1081
|
* @param {string} key
|
|
997
1082
|
* @param {string} value
|
|
1083
|
+
* @param {boolean} secret
|
|
998
1084
|
* @throws {AppwriteException}
|
|
999
1085
|
* @returns {Promise<Models.Variable>}
|
|
1000
1086
|
*/
|
|
1001
|
-
updateVariable(functionId: string, variableId: string, key: string, value?: string): Promise<Models.Variable> {
|
|
1087
|
+
updateVariable(functionId: string, variableId: string, key: string, value?: string, secret?: boolean): Promise<Models.Variable> {
|
|
1002
1088
|
if (typeof functionId === 'undefined') {
|
|
1003
1089
|
throw new AppwriteException('Missing required parameter: "functionId"');
|
|
1004
1090
|
}
|
|
@@ -1016,6 +1102,9 @@ Use the "command" param to set the entrypoint used to execute your cod
|
|
|
1016
1102
|
if (typeof value !== 'undefined') {
|
|
1017
1103
|
payload['value'] = value;
|
|
1018
1104
|
}
|
|
1105
|
+
if (typeof secret !== 'undefined') {
|
|
1106
|
+
payload['secret'] = secret;
|
|
1107
|
+
}
|
|
1019
1108
|
const uri = new URL(this.client.config.endpoint + apiPath);
|
|
1020
1109
|
|
|
1021
1110
|
const apiHeaders: { [header: string]: string } = {
|