@appwrite.io/console 13.0.0 → 13.2.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.
Files changed (67) hide show
  1. package/README.md +2 -2
  2. package/dist/cjs/sdk.js +5443 -1380
  3. package/dist/cjs/sdk.js.map +1 -1
  4. package/dist/esm/sdk.js +5438 -1381
  5. package/dist/esm/sdk.js.map +1 -1
  6. package/dist/iife/sdk.js +5451 -1388
  7. package/package.json +1 -1
  8. package/types/channel.d.ts +8 -3
  9. package/types/client.d.ts +1 -1
  10. package/types/enums/account-key-scopes.d.ts +5 -0
  11. package/types/enums/addon.d.ts +2 -1
  12. package/types/enums/appwrite-migration-resource.d.ts +14 -1
  13. package/types/enums/backup-services.d.ts +1 -0
  14. package/types/enums/{resource-type.d.ts → block-resource-type.d.ts} +2 -6
  15. package/types/enums/{theme.d.ts → browser-theme.d.ts} +1 -1
  16. package/types/enums/build-runtime.d.ts +3 -1
  17. package/types/enums/cache-database.d.ts +5 -0
  18. package/types/enums/cache-target.d.ts +8 -0
  19. package/types/enums/{registration-type.d.ts → domain-registration-type.d.ts} +1 -1
  20. package/types/enums/{filter-type.d.ts → domain-suggestion-type.d.ts} +1 -1
  21. package/types/enums/embedding-model.d.ts +6 -0
  22. package/types/enums/function-template-use-case.d.ts +9 -0
  23. package/types/enums/{name.d.ts → health-queue-name.d.ts} +1 -1
  24. package/types/enums/o-auth-provider.d.ts +1 -3
  25. package/types/enums/organization-key-scopes.d.ts +12 -0
  26. package/types/enums/{auth-method.d.ts → project-auth-method-id.d.ts} +1 -1
  27. package/types/enums/{email-template-type.d.ts → project-email-template-id.d.ts} +1 -1
  28. package/types/enums/{email-template-locale.d.ts → project-email-template-locale.d.ts} +1 -1
  29. package/types/enums/{scopes.d.ts → project-key-scopes.d.ts} +12 -8
  30. package/types/enums/{prompt.d.ts → project-o-auth-2-google-prompt.d.ts} +1 -1
  31. package/types/enums/project-o-auth-provider-id.d.ts +45 -0
  32. package/types/enums/{project-policy.d.ts → project-policy-id.d.ts} +6 -2
  33. package/types/enums/{protocol-id.d.ts → project-protocol-id.d.ts} +1 -1
  34. package/types/enums/{service-id.d.ts → project-service-id.d.ts} +3 -2
  35. package/types/enums/project-smtp-secure.d.ts +4 -0
  36. package/types/enums/query-suggestion-resource.d.ts +13 -1
  37. package/types/enums/runtime.d.ts +3 -1
  38. package/types/enums/schedule-resource-type.d.ts +6 -0
  39. package/types/enums/{use-cases.d.ts → site-template-use-case.d.ts} +3 -8
  40. package/types/enums/status-code.d.ts +4 -4
  41. package/types/index.d.ts +30 -19
  42. package/types/models.d.ts +2610 -1109
  43. package/types/services/account.d.ts +11 -11
  44. package/types/services/advisor.d.ts +123 -0
  45. package/types/services/apps.d.ts +266 -0
  46. package/types/services/avatars.d.ts +5 -5
  47. package/types/services/compute.d.ts +1171 -0
  48. package/types/services/console.d.ts +31 -0
  49. package/types/services/documents-db.d.ts +1 -4
  50. package/types/services/domains.d.ts +216 -216
  51. package/types/services/functions.d.ts +29 -18
  52. package/types/services/health.d.ts +13 -5
  53. package/types/services/manager.d.ts +49 -9
  54. package/types/services/messaging.d.ts +92 -0
  55. package/types/services/organization.d.ts +234 -0
  56. package/types/services/organizations.d.ts +0 -126
  57. package/types/services/presences.d.ts +166 -0
  58. package/types/services/project.d.ts +167 -89
  59. package/types/services/projects.d.ts +5 -154
  60. package/types/services/realtime.d.ts +45 -3
  61. package/types/services/sites.d.ts +22 -11
  62. package/types/services/usage.d.ts +50 -0
  63. package/types/services/vectors-db.d.ts +6 -9
  64. package/types/enums/frameworks.d.ts +0 -17
  65. package/types/enums/model.d.ts +0 -3
  66. package/types/enums/runtimes.d.ts +0 -91
  67. package/types/enums/secure.d.ts +0 -4
@@ -0,0 +1,1171 @@
1
+ import { Client } from '../client';
2
+ import type { Models } from '../models';
3
+ export declare class Compute {
4
+ client: Client;
5
+ constructor(client: Client);
6
+ /**
7
+ * List all dedicated databases. Results support pagination.
8
+ *
9
+ * @param {string[]} params.queries - Array of query strings.
10
+ * @throws {AppwriteException}
11
+ * @returns {Promise<Models.DedicatedDatabaseList>}
12
+ */
13
+ listDatabases(params?: {
14
+ queries?: string[];
15
+ }): Promise<Models.DedicatedDatabaseList>;
16
+ /**
17
+ * List all dedicated databases. Results support pagination.
18
+ *
19
+ * @param {string[]} queries - Array of query strings.
20
+ * @throws {AppwriteException}
21
+ * @returns {Promise<Models.DedicatedDatabaseList>}
22
+ * @deprecated Use the object parameter style method for a better developer experience.
23
+ */
24
+ listDatabases(queries?: string[]): Promise<Models.DedicatedDatabaseList>;
25
+ /**
26
+ * Create a new dedicated database with the chosen engine and configuration. Status will be 'provisioning' until the database is ready.
27
+ *
28
+ * @param {string} params.databaseId - Database ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars.
29
+ * @param {string} params.name - Database display name. Max length: 128 chars.
30
+ * @param {string} params.database - Physical database/catalog name. Defaults to databaseId.
31
+ * @param {string} params.engine - Database engine: postgres, mysql, mariadb, or mongodb.
32
+ * @param {string} params.version - Database engine version. Defaults to latest for selected engine.
33
+ * @param {string} params.region - Region identifier. Use one of the enabled region codes (e.g., fra, nyc, syd).
34
+ * @param {string} params.type - Database type: shared (serverless) or dedicated (always-on).
35
+ * @param {string} params.specification - Specification identifier.
36
+ * @param {string} params.backend - Database backend provider: prisma, or edge.
37
+ * @param {number} params.cpu - CPU in millicores (125-16000).
38
+ * @param {number} params.memory - Memory in MB to allocate (128-65536).
39
+ * @param {number} params.storage - Storage in GB to allocate (1-16384).
40
+ * @param {string} params.storageClass - Storage class: ssd, nvme, or hdd.
41
+ * @param {number} params.storageMaxGb - Maximum storage limit in GB. 0 uses system default.
42
+ * @param {boolean} params.highAvailability - Enable high availability.
43
+ * @param {number} params.highAvailabilityReplicaCount - Number of high availability replicas (0-5).
44
+ * @param {string} params.highAvailabilitySyncMode - Replication sync mode preference. Allowed values: async, sync, quorum.
45
+ * @param {number} params.networkMaxConnections - Maximum concurrent connections.
46
+ * @param {number} params.networkIdleTimeoutSeconds - Connection idle timeout in seconds.
47
+ * @param {string[]} params.networkIPAllowlist - IP addresses/CIDR ranges allowed to connect.
48
+ * @param {number} params.idleTimeoutMinutes - Minutes of inactivity before container scales to zero.
49
+ * @param {boolean} params.backupEnabled - Enable automatic backups.
50
+ * @param {boolean} params.backupPitr - Enable point-in-time recovery.
51
+ * @param {string} params.backupCron - Backup schedule in cron format.
52
+ * @param {number} params.backupRetentionDays - Number of days to retain backups.
53
+ * @param {number} params.pitrRetentionDays - Number of days to retain PITR data.
54
+ * @param {boolean} params.storageAutoscaling - Enable automatic storage expansion when usage exceeds threshold.
55
+ * @param {number} params.storageAutoscalingThresholdPercent - Storage usage percentage (50-95) that triggers automatic expansion.
56
+ * @param {number} params.storageAutoscalingMaxGb - Maximum storage size in GB for autoscaling. 0 means no limit.
57
+ * @param {boolean} params.metricsEnabled - Enable metrics collection.
58
+ * @param {boolean} params.poolerEnabled - Enable connection pooler on provision.
59
+ * @throws {AppwriteException}
60
+ * @returns {Promise<Models.DedicatedDatabase>}
61
+ */
62
+ createDatabase(params: {
63
+ databaseId: string;
64
+ name: string;
65
+ database?: string;
66
+ engine?: string;
67
+ version?: string;
68
+ region?: string;
69
+ type?: string;
70
+ specification?: string;
71
+ backend?: string;
72
+ cpu?: number;
73
+ memory?: number;
74
+ storage?: number;
75
+ storageClass?: string;
76
+ storageMaxGb?: number;
77
+ highAvailability?: boolean;
78
+ highAvailabilityReplicaCount?: number;
79
+ highAvailabilitySyncMode?: string;
80
+ networkMaxConnections?: number;
81
+ networkIdleTimeoutSeconds?: number;
82
+ networkIPAllowlist?: string[];
83
+ idleTimeoutMinutes?: number;
84
+ backupEnabled?: boolean;
85
+ backupPitr?: boolean;
86
+ backupCron?: string;
87
+ backupRetentionDays?: number;
88
+ pitrRetentionDays?: number;
89
+ storageAutoscaling?: boolean;
90
+ storageAutoscalingThresholdPercent?: number;
91
+ storageAutoscalingMaxGb?: number;
92
+ metricsEnabled?: boolean;
93
+ poolerEnabled?: boolean;
94
+ }): Promise<Models.DedicatedDatabase>;
95
+ /**
96
+ * Create a new dedicated database with the chosen engine and configuration. Status will be 'provisioning' until the database is ready.
97
+ *
98
+ * @param {string} databaseId - Database ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars.
99
+ * @param {string} name - Database display name. Max length: 128 chars.
100
+ * @param {string} database - Physical database/catalog name. Defaults to databaseId.
101
+ * @param {string} engine - Database engine: postgres, mysql, mariadb, or mongodb.
102
+ * @param {string} version - Database engine version. Defaults to latest for selected engine.
103
+ * @param {string} region - Region identifier. Use one of the enabled region codes (e.g., fra, nyc, syd).
104
+ * @param {string} type - Database type: shared (serverless) or dedicated (always-on).
105
+ * @param {string} specification - Specification identifier.
106
+ * @param {string} backend - Database backend provider: prisma, or edge.
107
+ * @param {number} cpu - CPU in millicores (125-16000).
108
+ * @param {number} memory - Memory in MB to allocate (128-65536).
109
+ * @param {number} storage - Storage in GB to allocate (1-16384).
110
+ * @param {string} storageClass - Storage class: ssd, nvme, or hdd.
111
+ * @param {number} storageMaxGb - Maximum storage limit in GB. 0 uses system default.
112
+ * @param {boolean} highAvailability - Enable high availability.
113
+ * @param {number} highAvailabilityReplicaCount - Number of high availability replicas (0-5).
114
+ * @param {string} highAvailabilitySyncMode - Replication sync mode preference. Allowed values: async, sync, quorum.
115
+ * @param {number} networkMaxConnections - Maximum concurrent connections.
116
+ * @param {number} networkIdleTimeoutSeconds - Connection idle timeout in seconds.
117
+ * @param {string[]} networkIPAllowlist - IP addresses/CIDR ranges allowed to connect.
118
+ * @param {number} idleTimeoutMinutes - Minutes of inactivity before container scales to zero.
119
+ * @param {boolean} backupEnabled - Enable automatic backups.
120
+ * @param {boolean} backupPitr - Enable point-in-time recovery.
121
+ * @param {string} backupCron - Backup schedule in cron format.
122
+ * @param {number} backupRetentionDays - Number of days to retain backups.
123
+ * @param {number} pitrRetentionDays - Number of days to retain PITR data.
124
+ * @param {boolean} storageAutoscaling - Enable automatic storage expansion when usage exceeds threshold.
125
+ * @param {number} storageAutoscalingThresholdPercent - Storage usage percentage (50-95) that triggers automatic expansion.
126
+ * @param {number} storageAutoscalingMaxGb - Maximum storage size in GB for autoscaling. 0 means no limit.
127
+ * @param {boolean} metricsEnabled - Enable metrics collection.
128
+ * @param {boolean} poolerEnabled - Enable connection pooler on provision.
129
+ * @throws {AppwriteException}
130
+ * @returns {Promise<Models.DedicatedDatabase>}
131
+ * @deprecated Use the object parameter style method for a better developer experience.
132
+ */
133
+ createDatabase(databaseId: string, name: string, database?: string, engine?: string, version?: string, region?: string, type?: string, specification?: string, backend?: string, cpu?: number, memory?: number, storage?: number, storageClass?: string, storageMaxGb?: number, highAvailability?: boolean, highAvailabilityReplicaCount?: number, highAvailabilitySyncMode?: string, networkMaxConnections?: number, networkIdleTimeoutSeconds?: number, networkIPAllowlist?: string[], idleTimeoutMinutes?: number, backupEnabled?: boolean, backupPitr?: boolean, backupCron?: string, backupRetentionDays?: number, pitrRetentionDays?: number, storageAutoscaling?: boolean, storageAutoscalingThresholdPercent?: number, storageAutoscalingMaxGb?: number, metricsEnabled?: boolean, poolerEnabled?: boolean): Promise<Models.DedicatedDatabase>;
134
+ /**
135
+ * List the dedicated database specifications available on the current plan. Each specification reports its resource limits, pricing, and whether it is enabled for the organization.
136
+ *
137
+ * @throws {AppwriteException}
138
+ * @returns {Promise<Models.DedicatedDatabaseSpecificationList>}
139
+ */
140
+ listDatabaseSpecifications(): Promise<Models.DedicatedDatabaseSpecificationList>;
141
+ /**
142
+ * Get a dedicated database by its unique ID. Returns the database configuration and current status.
143
+ *
144
+ * @param {string} params.databaseId - Database ID.
145
+ * @throws {AppwriteException}
146
+ * @returns {Promise<Models.DedicatedDatabase>}
147
+ */
148
+ getDatabase(params: {
149
+ databaseId: string;
150
+ }): Promise<Models.DedicatedDatabase>;
151
+ /**
152
+ * Get a dedicated database by its unique ID. Returns the database configuration and current status.
153
+ *
154
+ * @param {string} databaseId - Database ID.
155
+ * @throws {AppwriteException}
156
+ * @returns {Promise<Models.DedicatedDatabase>}
157
+ * @deprecated Use the object parameter style method for a better developer experience.
158
+ */
159
+ getDatabase(databaseId: string): Promise<Models.DedicatedDatabase>;
160
+ /**
161
+ * Update a dedicated database configuration. All changes are applied with zero downtime. Resource changes (cpu, memory) are handled via rolling cutover. Storage expansion is done online. All other settings are applied in-place.
162
+ *
163
+ * @param {string} params.databaseId - Database ID.
164
+ * @param {string} params.name - Database display name.
165
+ * @param {string} params.status - Database status. Allowed values: ready, paused, inactive. Set to "paused" to pause, "ready" to resume, or "inactive" to spin down a shared database.
166
+ * @param {string} params.specification - Specification. Changes cpu, memory, and type based on specification config.
167
+ * @param {number} params.cpu - CPU cores to allocate (125-16000).
168
+ * @param {number} params.memory - Memory in MB to allocate (128-65536).
169
+ * @param {number} params.storage - Storage in GB to allocate (1-16384).
170
+ * @param {string} params.storageClass - Storage class. Allowed values: ssd, nvme, hdd.
171
+ * @param {boolean} params.highAvailability - Enable high availability.
172
+ * @param {number} params.highAvailabilityReplicaCount - Number of high availability replicas (0-5).
173
+ * @param {string} params.highAvailabilitySyncMode - Replication sync mode preference. Allowed values: async, sync, quorum.
174
+ * @param {number} params.networkMaxConnections - Maximum concurrent connections.
175
+ * @param {number} params.networkIdleTimeoutSeconds - Connection idle timeout in seconds (60-86400).
176
+ * @param {string[]} params.networkIPAllowlist - IP addresses/CIDR ranges allowed to connect.
177
+ * @param {number} params.idleTimeoutMinutes - Minutes before container scales to zero.
178
+ * @param {boolean} params.backupEnabled - Enable automatic backups.
179
+ * @param {boolean} params.backupPitr - Enable point-in-time recovery.
180
+ * @param {string} params.backupCron - Backup schedule in cron format.
181
+ * @param {number} params.backupRetentionDays - Days to retain backups.
182
+ * @param {number} params.pitrRetentionDays - Days to retain PITR data.
183
+ * @param {boolean} params.storageAutoscaling - Enable automatic storage expansion when usage exceeds threshold.
184
+ * @param {number} params.storageAutoscalingThresholdPercent - Storage usage percentage (50-95) that triggers automatic expansion.
185
+ * @param {number} params.storageAutoscalingMaxGb - Maximum storage size in GB for autoscaling. 0 means no limit.
186
+ * @param {boolean} params.poolerEnabled - Attach or detach the connection pooler sidecar. Set to true to add the sidecar (no-op if already attached) or false to remove it.
187
+ * @param {boolean} params.metricsEnabled - Enable or disable the metrics-agent sidecar.
188
+ * @param {number} params.metricsTraceSampleRate - Fraction of queries to trace (0.0–1.0). Forwarded to the sidecar.
189
+ * @param {number} params.metricsSlowQueryLogThresholdMs - Threshold in ms above which queries are logged as slow. Forwarded to the sidecar.
190
+ * @param {boolean} params.sqlApiEnabled - Enable the SQL API sidecar for this database.
191
+ * @param {string[]} params.sqlApiAllowedStatements - Statement types the SQL API accepts. Allowed values: SELECT, INSERT, UPDATE, DELETE.
192
+ * @param {number} params.sqlApiMaxRows - Maximum rows returned per SQL API execution (1-1000000).
193
+ * @param {number} params.sqlApiMaxBytes - Maximum serialised SQL API result payload in bytes (1024-104857600).
194
+ * @param {number} params.sqlApiTimeoutSeconds - Per-call SQL API execution timeout in seconds (1-300).
195
+ * @throws {AppwriteException}
196
+ * @returns {Promise<Models.DedicatedDatabase>}
197
+ */
198
+ updateDatabase(params: {
199
+ databaseId: string;
200
+ name?: string;
201
+ status?: string;
202
+ specification?: string;
203
+ cpu?: number;
204
+ memory?: number;
205
+ storage?: number;
206
+ storageClass?: string;
207
+ highAvailability?: boolean;
208
+ highAvailabilityReplicaCount?: number;
209
+ highAvailabilitySyncMode?: string;
210
+ networkMaxConnections?: number;
211
+ networkIdleTimeoutSeconds?: number;
212
+ networkIPAllowlist?: string[];
213
+ idleTimeoutMinutes?: number;
214
+ backupEnabled?: boolean;
215
+ backupPitr?: boolean;
216
+ backupCron?: string;
217
+ backupRetentionDays?: number;
218
+ pitrRetentionDays?: number;
219
+ storageAutoscaling?: boolean;
220
+ storageAutoscalingThresholdPercent?: number;
221
+ storageAutoscalingMaxGb?: number;
222
+ poolerEnabled?: boolean;
223
+ metricsEnabled?: boolean;
224
+ metricsTraceSampleRate?: number;
225
+ metricsSlowQueryLogThresholdMs?: number;
226
+ sqlApiEnabled?: boolean;
227
+ sqlApiAllowedStatements?: string[];
228
+ sqlApiMaxRows?: number;
229
+ sqlApiMaxBytes?: number;
230
+ sqlApiTimeoutSeconds?: number;
231
+ }): Promise<Models.DedicatedDatabase>;
232
+ /**
233
+ * Update a dedicated database configuration. All changes are applied with zero downtime. Resource changes (cpu, memory) are handled via rolling cutover. Storage expansion is done online. All other settings are applied in-place.
234
+ *
235
+ * @param {string} databaseId - Database ID.
236
+ * @param {string} name - Database display name.
237
+ * @param {string} status - Database status. Allowed values: ready, paused, inactive. Set to "paused" to pause, "ready" to resume, or "inactive" to spin down a shared database.
238
+ * @param {string} specification - Specification. Changes cpu, memory, and type based on specification config.
239
+ * @param {number} cpu - CPU cores to allocate (125-16000).
240
+ * @param {number} memory - Memory in MB to allocate (128-65536).
241
+ * @param {number} storage - Storage in GB to allocate (1-16384).
242
+ * @param {string} storageClass - Storage class. Allowed values: ssd, nvme, hdd.
243
+ * @param {boolean} highAvailability - Enable high availability.
244
+ * @param {number} highAvailabilityReplicaCount - Number of high availability replicas (0-5).
245
+ * @param {string} highAvailabilitySyncMode - Replication sync mode preference. Allowed values: async, sync, quorum.
246
+ * @param {number} networkMaxConnections - Maximum concurrent connections.
247
+ * @param {number} networkIdleTimeoutSeconds - Connection idle timeout in seconds (60-86400).
248
+ * @param {string[]} networkIPAllowlist - IP addresses/CIDR ranges allowed to connect.
249
+ * @param {number} idleTimeoutMinutes - Minutes before container scales to zero.
250
+ * @param {boolean} backupEnabled - Enable automatic backups.
251
+ * @param {boolean} backupPitr - Enable point-in-time recovery.
252
+ * @param {string} backupCron - Backup schedule in cron format.
253
+ * @param {number} backupRetentionDays - Days to retain backups.
254
+ * @param {number} pitrRetentionDays - Days to retain PITR data.
255
+ * @param {boolean} storageAutoscaling - Enable automatic storage expansion when usage exceeds threshold.
256
+ * @param {number} storageAutoscalingThresholdPercent - Storage usage percentage (50-95) that triggers automatic expansion.
257
+ * @param {number} storageAutoscalingMaxGb - Maximum storage size in GB for autoscaling. 0 means no limit.
258
+ * @param {boolean} poolerEnabled - Attach or detach the connection pooler sidecar. Set to true to add the sidecar (no-op if already attached) or false to remove it.
259
+ * @param {boolean} metricsEnabled - Enable or disable the metrics-agent sidecar.
260
+ * @param {number} metricsTraceSampleRate - Fraction of queries to trace (0.0–1.0). Forwarded to the sidecar.
261
+ * @param {number} metricsSlowQueryLogThresholdMs - Threshold in ms above which queries are logged as slow. Forwarded to the sidecar.
262
+ * @param {boolean} sqlApiEnabled - Enable the SQL API sidecar for this database.
263
+ * @param {string[]} sqlApiAllowedStatements - Statement types the SQL API accepts. Allowed values: SELECT, INSERT, UPDATE, DELETE.
264
+ * @param {number} sqlApiMaxRows - Maximum rows returned per SQL API execution (1-1000000).
265
+ * @param {number} sqlApiMaxBytes - Maximum serialised SQL API result payload in bytes (1024-104857600).
266
+ * @param {number} sqlApiTimeoutSeconds - Per-call SQL API execution timeout in seconds (1-300).
267
+ * @throws {AppwriteException}
268
+ * @returns {Promise<Models.DedicatedDatabase>}
269
+ * @deprecated Use the object parameter style method for a better developer experience.
270
+ */
271
+ updateDatabase(databaseId: string, name?: string, status?: string, specification?: string, cpu?: number, memory?: number, storage?: number, storageClass?: string, highAvailability?: boolean, highAvailabilityReplicaCount?: number, highAvailabilitySyncMode?: string, networkMaxConnections?: number, networkIdleTimeoutSeconds?: number, networkIPAllowlist?: string[], idleTimeoutMinutes?: number, backupEnabled?: boolean, backupPitr?: boolean, backupCron?: string, backupRetentionDays?: number, pitrRetentionDays?: number, storageAutoscaling?: boolean, storageAutoscalingThresholdPercent?: number, storageAutoscalingMaxGb?: number, poolerEnabled?: boolean, metricsEnabled?: boolean, metricsTraceSampleRate?: number, metricsSlowQueryLogThresholdMs?: number, sqlApiEnabled?: boolean, sqlApiAllowedStatements?: string[], sqlApiMaxRows?: number, sqlApiMaxBytes?: number, sqlApiTimeoutSeconds?: number): Promise<Models.DedicatedDatabase>;
272
+ /**
273
+ * Delete a dedicated database. This action is irreversible. The database status will be set to 'deleting' and all resources will be cleaned up.
274
+ *
275
+ * @param {string} params.databaseId - Database ID.
276
+ * @throws {AppwriteException}
277
+ * @returns {Promise<{}>}
278
+ */
279
+ deleteDatabase(params: {
280
+ databaseId: string;
281
+ }): Promise<{}>;
282
+ /**
283
+ * Delete a dedicated database. This action is irreversible. The database status will be set to 'deleting' and all resources will be cleaned up.
284
+ *
285
+ * @param {string} databaseId - Database ID.
286
+ * @throws {AppwriteException}
287
+ * @returns {Promise<{}>}
288
+ * @deprecated Use the object parameter style method for a better developer experience.
289
+ */
290
+ deleteDatabase(databaseId: string): Promise<{}>;
291
+ /**
292
+ * List all backups for a dedicated database. Results can be filtered by status and type.
293
+ *
294
+ * @param {string} params.databaseId - Database ID.
295
+ * @param {string[]} params.queries - Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https://appwrite.io/docs/queries). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following attributes: status, type, databaseId
296
+ * @throws {AppwriteException}
297
+ * @returns {Promise<Models.DedicatedDatabaseBackupList>}
298
+ */
299
+ listDatabaseBackups(params: {
300
+ databaseId: string;
301
+ queries?: string[];
302
+ }): Promise<Models.DedicatedDatabaseBackupList>;
303
+ /**
304
+ * List all backups for a dedicated database. Results can be filtered by status and type.
305
+ *
306
+ * @param {string} databaseId - Database ID.
307
+ * @param {string[]} queries - Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https://appwrite.io/docs/queries). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following attributes: status, type, databaseId
308
+ * @throws {AppwriteException}
309
+ * @returns {Promise<Models.DedicatedDatabaseBackupList>}
310
+ * @deprecated Use the object parameter style method for a better developer experience.
311
+ */
312
+ listDatabaseBackups(databaseId: string, queries?: string[]): Promise<Models.DedicatedDatabaseBackupList>;
313
+ /**
314
+ * Create a manual backup of a dedicated database. The backup will be created asynchronously and its status can be checked via the get backup endpoint.
315
+ *
316
+ * @param {string} params.databaseId - Database ID.
317
+ * @param {string} params.type - Backup type: full or incremental.
318
+ * @throws {AppwriteException}
319
+ * @returns {Promise<Models.DedicatedDatabaseBackup>}
320
+ */
321
+ createDatabaseBackup(params: {
322
+ databaseId: string;
323
+ type?: string;
324
+ }): Promise<Models.DedicatedDatabaseBackup>;
325
+ /**
326
+ * Create a manual backup of a dedicated database. The backup will be created asynchronously and its status can be checked via the get backup endpoint.
327
+ *
328
+ * @param {string} databaseId - Database ID.
329
+ * @param {string} type - Backup type: full or incremental.
330
+ * @throws {AppwriteException}
331
+ * @returns {Promise<Models.DedicatedDatabaseBackup>}
332
+ * @deprecated Use the object parameter style method for a better developer experience.
333
+ */
334
+ createDatabaseBackup(databaseId: string, type?: string): Promise<Models.DedicatedDatabaseBackup>;
335
+ /**
336
+ * List scheduled backup policies for a dedicated database.
337
+ *
338
+ * @param {string} params.databaseId - Database ID.
339
+ * @param {string[]} params.queries - Array of query strings generated using the Query class provided by the SDK.
340
+ * @throws {AppwriteException}
341
+ * @returns {Promise<Models.BackupPolicyList>}
342
+ */
343
+ listDatabaseBackupPolicies(params: {
344
+ databaseId: string;
345
+ queries?: string[];
346
+ }): Promise<Models.BackupPolicyList>;
347
+ /**
348
+ * List scheduled backup policies for a dedicated database.
349
+ *
350
+ * @param {string} databaseId - Database ID.
351
+ * @param {string[]} queries - Array of query strings generated using the Query class provided by the SDK.
352
+ * @throws {AppwriteException}
353
+ * @returns {Promise<Models.BackupPolicyList>}
354
+ * @deprecated Use the object parameter style method for a better developer experience.
355
+ */
356
+ listDatabaseBackupPolicies(databaseId: string, queries?: string[]): Promise<Models.BackupPolicyList>;
357
+ /**
358
+ * Create a scheduled backup policy for a dedicated database.
359
+ *
360
+ * @param {string} params.databaseId - Database ID.
361
+ * @param {string} params.policyId - Policy ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars.
362
+ * @param {string} params.name - Policy name. Max length: 128 chars.
363
+ * @param {string} params.schedule - Schedule CRON syntax.
364
+ * @param {number} params.retention - Days to keep backups before deletion.
365
+ * @param {string} params.type - Backup type: full or incremental.
366
+ * @param {boolean} params.enabled - Is policy enabled? When disabled, no backups will be taken.
367
+ * @throws {AppwriteException}
368
+ * @returns {Promise<Models.BackupPolicy>}
369
+ */
370
+ createDatabaseBackupPolicy(params: {
371
+ databaseId: string;
372
+ policyId: string;
373
+ name: string;
374
+ schedule: string;
375
+ retention: number;
376
+ type?: string;
377
+ enabled?: boolean;
378
+ }): Promise<Models.BackupPolicy>;
379
+ /**
380
+ * Create a scheduled backup policy for a dedicated database.
381
+ *
382
+ * @param {string} databaseId - Database ID.
383
+ * @param {string} policyId - Policy ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars.
384
+ * @param {string} name - Policy name. Max length: 128 chars.
385
+ * @param {string} schedule - Schedule CRON syntax.
386
+ * @param {number} retention - Days to keep backups before deletion.
387
+ * @param {string} type - Backup type: full or incremental.
388
+ * @param {boolean} enabled - Is policy enabled? When disabled, no backups will be taken.
389
+ * @throws {AppwriteException}
390
+ * @returns {Promise<Models.BackupPolicy>}
391
+ * @deprecated Use the object parameter style method for a better developer experience.
392
+ */
393
+ createDatabaseBackupPolicy(databaseId: string, policyId: string, name: string, schedule: string, retention: number, type?: string, enabled?: boolean): Promise<Models.BackupPolicy>;
394
+ /**
395
+ * Configure off-cluster backup storage for a dedicated database. Supports S3, GCS, and Azure Blob Storage destinations. Backups will be stored to the configured destination in addition to on-cluster storage.
396
+ *
397
+ * @param {string} params.databaseId - Database ID.
398
+ * @param {string} params.provider - Storage provider for off-cluster backups. Allowed values: s3 (Amazon S3 or S3-compatible), gcs (Google Cloud Storage), azure (Azure Blob Storage).
399
+ * @param {string} params.bucket - Storage bucket or container name.
400
+ * @param {string} params.accessKey - Access key or client ID for authentication.
401
+ * @param {string} params.secretKey - Secret key or service account JSON for authentication.
402
+ * @param {string} params.region - Storage region.
403
+ * @param {string} params.prefix - Object key prefix for backups.
404
+ * @param {string} params.endpoint - Custom endpoint for S3-compatible storage (e.g. MinIO).
405
+ * @throws {AppwriteException}
406
+ * @returns {Promise<Models.DedicatedDatabaseBackupStorage>}
407
+ */
408
+ updateDatabaseBackupStorage(params: {
409
+ databaseId: string;
410
+ provider: string;
411
+ bucket: string;
412
+ accessKey: string;
413
+ secretKey: string;
414
+ region?: string;
415
+ prefix?: string;
416
+ endpoint?: string;
417
+ }): Promise<Models.DedicatedDatabaseBackupStorage>;
418
+ /**
419
+ * Configure off-cluster backup storage for a dedicated database. Supports S3, GCS, and Azure Blob Storage destinations. Backups will be stored to the configured destination in addition to on-cluster storage.
420
+ *
421
+ * @param {string} databaseId - Database ID.
422
+ * @param {string} provider - Storage provider for off-cluster backups. Allowed values: s3 (Amazon S3 or S3-compatible), gcs (Google Cloud Storage), azure (Azure Blob Storage).
423
+ * @param {string} bucket - Storage bucket or container name.
424
+ * @param {string} accessKey - Access key or client ID for authentication.
425
+ * @param {string} secretKey - Secret key or service account JSON for authentication.
426
+ * @param {string} region - Storage region.
427
+ * @param {string} prefix - Object key prefix for backups.
428
+ * @param {string} endpoint - Custom endpoint for S3-compatible storage (e.g. MinIO).
429
+ * @throws {AppwriteException}
430
+ * @returns {Promise<Models.DedicatedDatabaseBackupStorage>}
431
+ * @deprecated Use the object parameter style method for a better developer experience.
432
+ */
433
+ updateDatabaseBackupStorage(databaseId: string, provider: string, bucket: string, accessKey: string, secretKey: string, region?: string, prefix?: string, endpoint?: string): Promise<Models.DedicatedDatabaseBackupStorage>;
434
+ /**
435
+ * Get details of a specific database backup including its status, size, and timestamps.
436
+ *
437
+ * @param {string} params.databaseId - Database ID.
438
+ * @param {string} params.backupId - Backup ID.
439
+ * @throws {AppwriteException}
440
+ * @returns {Promise<Models.DedicatedDatabaseBackup>}
441
+ */
442
+ getDatabaseBackup(params: {
443
+ databaseId: string;
444
+ backupId: string;
445
+ }): Promise<Models.DedicatedDatabaseBackup>;
446
+ /**
447
+ * Get details of a specific database backup including its status, size, and timestamps.
448
+ *
449
+ * @param {string} databaseId - Database ID.
450
+ * @param {string} backupId - Backup ID.
451
+ * @throws {AppwriteException}
452
+ * @returns {Promise<Models.DedicatedDatabaseBackup>}
453
+ * @deprecated Use the object parameter style method for a better developer experience.
454
+ */
455
+ getDatabaseBackup(databaseId: string, backupId: string): Promise<Models.DedicatedDatabaseBackup>;
456
+ /**
457
+ * Delete a database backup. This will permanently remove the backup from storage and cannot be undone.
458
+ *
459
+ * @param {string} params.databaseId - Database ID.
460
+ * @param {string} params.backupId - Backup ID.
461
+ * @throws {AppwriteException}
462
+ * @returns {Promise<{}>}
463
+ */
464
+ deleteDatabaseBackup(params: {
465
+ databaseId: string;
466
+ backupId: string;
467
+ }): Promise<{}>;
468
+ /**
469
+ * Delete a database backup. This will permanently remove the backup from storage and cannot be undone.
470
+ *
471
+ * @param {string} databaseId - Database ID.
472
+ * @param {string} backupId - Backup ID.
473
+ * @throws {AppwriteException}
474
+ * @returns {Promise<{}>}
475
+ * @deprecated Use the object parameter style method for a better developer experience.
476
+ */
477
+ deleteDatabaseBackup(databaseId: string, backupId: string): Promise<{}>;
478
+ /**
479
+ * List all ephemeral branches for a dedicated database. Returns branch metadata including ID, name, namespace, and expiration time.
480
+ *
481
+ * @param {string} params.databaseId - Database ID.
482
+ * @throws {AppwriteException}
483
+ * @returns {Promise<Models.DedicatedDatabaseBranchList>}
484
+ */
485
+ listDatabaseBranches(params: {
486
+ databaseId: string;
487
+ }): Promise<Models.DedicatedDatabaseBranchList>;
488
+ /**
489
+ * List all ephemeral branches for a dedicated database. Returns branch metadata including ID, name, namespace, and expiration time.
490
+ *
491
+ * @param {string} databaseId - Database ID.
492
+ * @throws {AppwriteException}
493
+ * @returns {Promise<Models.DedicatedDatabaseBranchList>}
494
+ * @deprecated Use the object parameter style method for a better developer experience.
495
+ */
496
+ listDatabaseBranches(databaseId: string): Promise<Models.DedicatedDatabaseBranchList>;
497
+ /**
498
+ * Create an ephemeral database branch from the primary via PVC snapshot. The branch is a full copy of the database at the current point in time, useful for testing schema migrations or running experiments without affecting production data. Branches expire after the configured TTL (default 24 hours). The branch is created asynchronously.
499
+ *
500
+ * @param {string} params.databaseId - Database ID.
501
+ * @param {string} params.branchId - Branch ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars.
502
+ * @param {number} params.ttl - Time-to-live in seconds before the branch expires. Min 300 (5 min), max 604800 (7 days). Default: 86400 (24h).
503
+ * @throws {AppwriteException}
504
+ * @returns {Promise<Models.DedicatedDatabase>}
505
+ */
506
+ createDatabaseBranch(params: {
507
+ databaseId: string;
508
+ branchId?: string;
509
+ ttl?: number;
510
+ }): Promise<Models.DedicatedDatabase>;
511
+ /**
512
+ * Create an ephemeral database branch from the primary via PVC snapshot. The branch is a full copy of the database at the current point in time, useful for testing schema migrations or running experiments without affecting production data. Branches expire after the configured TTL (default 24 hours). The branch is created asynchronously.
513
+ *
514
+ * @param {string} databaseId - Database ID.
515
+ * @param {string} branchId - Branch ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can't start with a special char. Max length is 36 chars.
516
+ * @param {number} ttl - Time-to-live in seconds before the branch expires. Min 300 (5 min), max 604800 (7 days). Default: 86400 (24h).
517
+ * @throws {AppwriteException}
518
+ * @returns {Promise<Models.DedicatedDatabase>}
519
+ * @deprecated Use the object parameter style method for a better developer experience.
520
+ */
521
+ createDatabaseBranch(databaseId: string, branchId?: string, ttl?: number): Promise<Models.DedicatedDatabase>;
522
+ /**
523
+ * Delete an ephemeral database branch. This removes the branch namespace, its PVC, and the associated VolumeSnapshot. The deletion runs asynchronously and is irreversible.
524
+ *
525
+ * @param {string} params.databaseId - Database ID.
526
+ * @param {string} params.branchId - Branch ID.
527
+ * @throws {AppwriteException}
528
+ * @returns {Promise<Models.DedicatedDatabase>}
529
+ */
530
+ deleteDatabaseBranch(params: {
531
+ databaseId: string;
532
+ branchId: string;
533
+ }): Promise<Models.DedicatedDatabase>;
534
+ /**
535
+ * Delete an ephemeral database branch. This removes the branch namespace, its PVC, and the associated VolumeSnapshot. The deletion runs asynchronously and is irreversible.
536
+ *
537
+ * @param {string} databaseId - Database ID.
538
+ * @param {string} branchId - Branch ID.
539
+ * @throws {AppwriteException}
540
+ * @returns {Promise<Models.DedicatedDatabase>}
541
+ * @deprecated Use the object parameter style method for a better developer experience.
542
+ */
543
+ deleteDatabaseBranch(databaseId: string, branchId: string): Promise<Models.DedicatedDatabase>;
544
+ /**
545
+ * List all database connection users/roles for a dedicated database.
546
+ *
547
+ * @param {string} params.databaseId - Database ID.
548
+ * @throws {AppwriteException}
549
+ * @returns {Promise<Models.DedicatedDatabaseConnectionList>}
550
+ */
551
+ listDatabaseConnections(params: {
552
+ databaseId: string;
553
+ }): Promise<Models.DedicatedDatabaseConnectionList>;
554
+ /**
555
+ * List all database connection users/roles for a dedicated database.
556
+ *
557
+ * @param {string} databaseId - Database ID.
558
+ * @throws {AppwriteException}
559
+ * @returns {Promise<Models.DedicatedDatabaseConnectionList>}
560
+ * @deprecated Use the object parameter style method for a better developer experience.
561
+ */
562
+ listDatabaseConnections(databaseId: string): Promise<Models.DedicatedDatabaseConnectionList>;
563
+ /**
564
+ * Create a new database connection user/role. Returns the connection details including the generated credentials.
565
+ *
566
+ * @param {string} params.databaseId - Database ID.
567
+ * @param {string} params.username - Connection username.
568
+ * @param {string} params.role - Connection role for the new user. Common values: readonly (read-only access), readwrite (full read and write access).
569
+ * @throws {AppwriteException}
570
+ * @returns {Promise<Models.DedicatedDatabaseConnection>}
571
+ */
572
+ createDatabaseConnection(params: {
573
+ databaseId: string;
574
+ username: string;
575
+ role?: string;
576
+ }): Promise<Models.DedicatedDatabaseConnection>;
577
+ /**
578
+ * Create a new database connection user/role. Returns the connection details including the generated credentials.
579
+ *
580
+ * @param {string} databaseId - Database ID.
581
+ * @param {string} username - Connection username.
582
+ * @param {string} role - Connection role for the new user. Common values: readonly (read-only access), readwrite (full read and write access).
583
+ * @throws {AppwriteException}
584
+ * @returns {Promise<Models.DedicatedDatabaseConnection>}
585
+ * @deprecated Use the object parameter style method for a better developer experience.
586
+ */
587
+ createDatabaseConnection(databaseId: string, username: string, role?: string): Promise<Models.DedicatedDatabaseConnection>;
588
+ /**
589
+ * Delete a database connection user/role. The connection will be terminated immediately.
590
+ *
591
+ * @param {string} params.databaseId - Database ID.
592
+ * @param {string} params.connectionId - Connection ID.
593
+ * @throws {AppwriteException}
594
+ * @returns {Promise<{}>}
595
+ */
596
+ deleteDatabaseConnection(params: {
597
+ databaseId: string;
598
+ connectionId: string;
599
+ }): Promise<{}>;
600
+ /**
601
+ * Delete a database connection user/role. The connection will be terminated immediately.
602
+ *
603
+ * @param {string} databaseId - Database ID.
604
+ * @param {string} connectionId - Connection ID.
605
+ * @throws {AppwriteException}
606
+ * @returns {Promise<{}>}
607
+ * @deprecated Use the object parameter style method for a better developer experience.
608
+ */
609
+ deleteDatabaseConnection(databaseId: string, connectionId: string): Promise<{}>;
610
+ /**
611
+ * Get connection credentials for a dedicated database. Returns the hostname, port, username, password, database name, and full connection string.
612
+ *
613
+ * @param {string} params.databaseId - Database ID.
614
+ * @throws {AppwriteException}
615
+ * @returns {Promise<Models.DedicatedDatabaseCredentials>}
616
+ */
617
+ getDatabaseCredentials(params: {
618
+ databaseId: string;
619
+ }): Promise<Models.DedicatedDatabaseCredentials>;
620
+ /**
621
+ * Get connection credentials for a dedicated database. Returns the hostname, port, username, password, database name, and full connection string.
622
+ *
623
+ * @param {string} databaseId - Database ID.
624
+ * @throws {AppwriteException}
625
+ * @returns {Promise<Models.DedicatedDatabaseCredentials>}
626
+ * @deprecated Use the object parameter style method for a better developer experience.
627
+ */
628
+ getDatabaseCredentials(databaseId: string): Promise<Models.DedicatedDatabaseCredentials>;
629
+ /**
630
+ * Rotate the primary credentials for a dedicated database. Generates a new password and updates the database. Previous credentials will stop working immediately.
631
+ *
632
+ * @param {string} params.databaseId - Database ID.
633
+ * @throws {AppwriteException}
634
+ * @returns {Promise<Models.DedicatedDatabaseCredentials>}
635
+ */
636
+ updateDatabaseCredentials(params: {
637
+ databaseId: string;
638
+ }): Promise<Models.DedicatedDatabaseCredentials>;
639
+ /**
640
+ * Rotate the primary credentials for a dedicated database. Generates a new password and updates the database. Previous credentials will stop working immediately.
641
+ *
642
+ * @param {string} databaseId - Database ID.
643
+ * @throws {AppwriteException}
644
+ * @returns {Promise<Models.DedicatedDatabaseCredentials>}
645
+ * @deprecated Use the object parameter style method for a better developer experience.
646
+ */
647
+ updateDatabaseCredentials(databaseId: string): Promise<Models.DedicatedDatabaseCredentials>;
648
+ /**
649
+ * Execute SQL through the console-facing Cloud endpoint. Cloud proxies through the edge platform to the per-database SQL API sidecar. Application traffic should bypass cloud entirely and POST directly to the per-database hostname: `https://db-{project}-{db}.{region}.appwrite.center/v1/sql/execute` with an `X-Appwrite-Key` header — that path scales to the whole DB fleet without a per-query cloud round-trip. The statement type must be on the database's configured allow-list. Use bound parameters for any user-supplied values — the API does not interpolate raw strings.
650
+ *
651
+ * @param {string} params.databaseId - Database ID.
652
+ * @param {string} params.sql - SQL statement to execute. Exactly one statement per request.
653
+ * @param {object} params.bindings - Optional bound parameters. Pass either a positional list or a name => value map matching the placeholder style used in the SQL.
654
+ * @param {number} params.timeoutSeconds - Per-call execution timeout override. Must be less than or equal to the database's configured sqlApiTimeoutSeconds.
655
+ * @throws {AppwriteException}
656
+ * @returns {Promise<Models.DedicatedDatabaseExecution>}
657
+ */
658
+ createDatabaseExecution(params: {
659
+ databaseId: string;
660
+ sql: string;
661
+ bindings?: object;
662
+ timeoutSeconds?: number;
663
+ }): Promise<Models.DedicatedDatabaseExecution>;
664
+ /**
665
+ * Execute SQL through the console-facing Cloud endpoint. Cloud proxies through the edge platform to the per-database SQL API sidecar. Application traffic should bypass cloud entirely and POST directly to the per-database hostname: `https://db-{project}-{db}.{region}.appwrite.center/v1/sql/execute` with an `X-Appwrite-Key` header — that path scales to the whole DB fleet without a per-query cloud round-trip. The statement type must be on the database's configured allow-list. Use bound parameters for any user-supplied values — the API does not interpolate raw strings.
666
+ *
667
+ * @param {string} databaseId - Database ID.
668
+ * @param {string} sql - SQL statement to execute. Exactly one statement per request.
669
+ * @param {object} bindings - Optional bound parameters. Pass either a positional list or a name => value map matching the placeholder style used in the SQL.
670
+ * @param {number} timeoutSeconds - Per-call execution timeout override. Must be less than or equal to the database's configured sqlApiTimeoutSeconds.
671
+ * @throws {AppwriteException}
672
+ * @returns {Promise<Models.DedicatedDatabaseExecution>}
673
+ * @deprecated Use the object parameter style method for a better developer experience.
674
+ */
675
+ createDatabaseExecution(databaseId: string, sql: string, bindings?: object, timeoutSeconds?: number): Promise<Models.DedicatedDatabaseExecution>;
676
+ /**
677
+ * Run EXPLAIN on a query against a dedicated database. Available for SQL-compatible engines. Returns the query execution plan including scan types, estimated cost, and resource usage. Optionally run EXPLAIN ANALYZE to get actual execution statistics.
678
+ *
679
+ * @param {string} params.databaseId - Database ID.
680
+ * @param {string} params.query - Query to explain. Must be a valid query for the database engine.
681
+ * @param {boolean} params.analyze - Run EXPLAIN ANALYZE to get actual execution statistics. This executes the query.
682
+ * @throws {AppwriteException}
683
+ * @returns {Promise<Models.DedicatedDatabaseQueryExplanation>}
684
+ */
685
+ createDatabaseQueryExplanation(params: {
686
+ databaseId: string;
687
+ query: string;
688
+ analyze?: boolean;
689
+ }): Promise<Models.DedicatedDatabaseQueryExplanation>;
690
+ /**
691
+ * Run EXPLAIN on a query against a dedicated database. Available for SQL-compatible engines. Returns the query execution plan including scan types, estimated cost, and resource usage. Optionally run EXPLAIN ANALYZE to get actual execution statistics.
692
+ *
693
+ * @param {string} databaseId - Database ID.
694
+ * @param {string} query - Query to explain. Must be a valid query for the database engine.
695
+ * @param {boolean} analyze - Run EXPLAIN ANALYZE to get actual execution statistics. This executes the query.
696
+ * @throws {AppwriteException}
697
+ * @returns {Promise<Models.DedicatedDatabaseQueryExplanation>}
698
+ * @deprecated Use the object parameter style method for a better developer experience.
699
+ */
700
+ createDatabaseQueryExplanation(databaseId: string, query: string, analyze?: boolean): Promise<Models.DedicatedDatabaseQueryExplanation>;
701
+ /**
702
+ * List installed and available extensions for a PostgreSQL database.
703
+ *
704
+ * @param {string} params.databaseId - Database ID.
705
+ * @throws {AppwriteException}
706
+ * @returns {Promise<Models.DedicatedDatabaseExtensions>}
707
+ */
708
+ listDatabaseExtensions(params: {
709
+ databaseId: string;
710
+ }): Promise<Models.DedicatedDatabaseExtensions>;
711
+ /**
712
+ * List installed and available extensions for a PostgreSQL database.
713
+ *
714
+ * @param {string} databaseId - Database ID.
715
+ * @throws {AppwriteException}
716
+ * @returns {Promise<Models.DedicatedDatabaseExtensions>}
717
+ * @deprecated Use the object parameter style method for a better developer experience.
718
+ */
719
+ listDatabaseExtensions(databaseId: string): Promise<Models.DedicatedDatabaseExtensions>;
720
+ /**
721
+ * Install a database extension. Only available for PostgreSQL databases. The install runs asynchronously; poll the extensions list endpoint for status.
722
+ *
723
+ * @param {string} params.databaseId - Database ID.
724
+ * @param {string} params.name - Extension name (e.g., pgvector, postgis, uuid-ossp).
725
+ * @throws {AppwriteException}
726
+ * @returns {Promise<Models.DedicatedDatabase>}
727
+ */
728
+ createDatabaseExtension(params: {
729
+ databaseId: string;
730
+ name: string;
731
+ }): Promise<Models.DedicatedDatabase>;
732
+ /**
733
+ * Install a database extension. Only available for PostgreSQL databases. The install runs asynchronously; poll the extensions list endpoint for status.
734
+ *
735
+ * @param {string} databaseId - Database ID.
736
+ * @param {string} name - Extension name (e.g., pgvector, postgis, uuid-ossp).
737
+ * @throws {AppwriteException}
738
+ * @returns {Promise<Models.DedicatedDatabase>}
739
+ * @deprecated Use the object parameter style method for a better developer experience.
740
+ */
741
+ createDatabaseExtension(databaseId: string, name: string): Promise<Models.DedicatedDatabase>;
742
+ /**
743
+ * Uninstall a database extension from a PostgreSQL database. The uninstall runs asynchronously; poll the extensions list endpoint for status.
744
+ *
745
+ * @param {string} params.databaseId - Database ID.
746
+ * @param {string} params.extensionName - Extension name to uninstall.
747
+ * @throws {AppwriteException}
748
+ * @returns {Promise<Models.DedicatedDatabase>}
749
+ */
750
+ deleteDatabaseExtension(params: {
751
+ databaseId: string;
752
+ extensionName: string;
753
+ }): Promise<Models.DedicatedDatabase>;
754
+ /**
755
+ * Uninstall a database extension from a PostgreSQL database. The uninstall runs asynchronously; poll the extensions list endpoint for status.
756
+ *
757
+ * @param {string} databaseId - Database ID.
758
+ * @param {string} extensionName - Extension name to uninstall.
759
+ * @throws {AppwriteException}
760
+ * @returns {Promise<Models.DedicatedDatabase>}
761
+ * @deprecated Use the object parameter style method for a better developer experience.
762
+ */
763
+ deleteDatabaseExtension(databaseId: string, extensionName: string): Promise<Models.DedicatedDatabase>;
764
+ /**
765
+ * Get high availability status for a dedicated database. Returns replica statuses, replication lag, and sync mode.
766
+ *
767
+ * @param {string} params.databaseId - Database ID.
768
+ * @throws {AppwriteException}
769
+ * @returns {Promise<Models.DedicatedDatabaseHAStatus>}
770
+ */
771
+ getDatabaseHAStatus(params: {
772
+ databaseId: string;
773
+ }): Promise<Models.DedicatedDatabaseHAStatus>;
774
+ /**
775
+ * Get high availability status for a dedicated database. Returns replica statuses, replication lag, and sync mode.
776
+ *
777
+ * @param {string} databaseId - Database ID.
778
+ * @throws {AppwriteException}
779
+ * @returns {Promise<Models.DedicatedDatabaseHAStatus>}
780
+ * @deprecated Use the object parameter style method for a better developer experience.
781
+ */
782
+ getDatabaseHAStatus(databaseId: string): Promise<Models.DedicatedDatabaseHAStatus>;
783
+ /**
784
+ * Trigger a manual failover for a dedicated database with high availability enabled. Promotes a replica to primary. The failover runs asynchronously; poll the database document for status updates.
785
+ *
786
+ * @param {string} params.databaseId - Database ID.
787
+ * @param {string} params.targetReplicaId - Target replica ID to promote. If not specified, the healthiest replica is selected.
788
+ * @throws {AppwriteException}
789
+ * @returns {Promise<Models.DedicatedDatabase>}
790
+ */
791
+ createDatabaseFailover(params: {
792
+ databaseId: string;
793
+ targetReplicaId?: string;
794
+ }): Promise<Models.DedicatedDatabase>;
795
+ /**
796
+ * Trigger a manual failover for a dedicated database with high availability enabled. Promotes a replica to primary. The failover runs asynchronously; poll the database document for status updates.
797
+ *
798
+ * @param {string} databaseId - Database ID.
799
+ * @param {string} targetReplicaId - Target replica ID to promote. If not specified, the healthiest replica is selected.
800
+ * @throws {AppwriteException}
801
+ * @returns {Promise<Models.DedicatedDatabase>}
802
+ * @deprecated Use the object parameter style method for a better developer experience.
803
+ */
804
+ createDatabaseFailover(databaseId: string, targetReplicaId?: string): Promise<Models.DedicatedDatabase>;
805
+ /**
806
+ * Get query-level performance insights for a dedicated database. Returns top queries by execution time, wait events, and aggregate query statistics.
807
+ *
808
+ * @param {string} params.databaseId - Database ID.
809
+ * @param {string} params.period - Analysis period for performance insights. Allowed values: 1h (last hour), 24h (last 24 hours), 7d (last 7 days).
810
+ * @param {number} params.limit - Maximum number of queries to return.
811
+ * @throws {AppwriteException}
812
+ * @returns {Promise<Models.DedicatedDatabasePerformanceInsights>}
813
+ */
814
+ getDatabaseInsights(params: {
815
+ databaseId: string;
816
+ period?: string;
817
+ limit?: number;
818
+ }): Promise<Models.DedicatedDatabasePerformanceInsights>;
819
+ /**
820
+ * Get query-level performance insights for a dedicated database. Returns top queries by execution time, wait events, and aggregate query statistics.
821
+ *
822
+ * @param {string} databaseId - Database ID.
823
+ * @param {string} period - Analysis period for performance insights. Allowed values: 1h (last hour), 24h (last 24 hours), 7d (last 7 days).
824
+ * @param {number} limit - Maximum number of queries to return.
825
+ * @throws {AppwriteException}
826
+ * @returns {Promise<Models.DedicatedDatabasePerformanceInsights>}
827
+ * @deprecated Use the object parameter style method for a better developer experience.
828
+ */
829
+ getDatabaseInsights(databaseId: string, period?: string, limit?: number): Promise<Models.DedicatedDatabasePerformanceInsights>;
830
+ /**
831
+ * Update the maintenance window for a dedicated database. Maintenance operations like minor version upgrades will be performed during this window.
832
+ *
833
+ * @param {string} params.databaseId - Database ID.
834
+ * @param {string} params.day - Day of the week for the maintenance window. Allowed values: sun, mon, tue, wed, thu, fri, sat.
835
+ * @param {number} params.hourUtc - Hour in UTC (0-23) for maintenance window start.
836
+ * @throws {AppwriteException}
837
+ * @returns {Promise<Models.DedicatedDatabase>}
838
+ */
839
+ updateDatabaseMaintenanceWindow(params: {
840
+ databaseId: string;
841
+ day: string;
842
+ hourUtc: number;
843
+ }): Promise<Models.DedicatedDatabase>;
844
+ /**
845
+ * Update the maintenance window for a dedicated database. Maintenance operations like minor version upgrades will be performed during this window.
846
+ *
847
+ * @param {string} databaseId - Database ID.
848
+ * @param {string} day - Day of the week for the maintenance window. Allowed values: sun, mon, tue, wed, thu, fri, sat.
849
+ * @param {number} hourUtc - Hour in UTC (0-23) for maintenance window start.
850
+ * @throws {AppwriteException}
851
+ * @returns {Promise<Models.DedicatedDatabase>}
852
+ * @deprecated Use the object parameter style method for a better developer experience.
853
+ */
854
+ updateDatabaseMaintenanceWindow(databaseId: string, day: string, hourUtc: number): Promise<Models.DedicatedDatabase>;
855
+ /**
856
+ * Get detailed performance metrics for a dedicated database. Returns CPU, memory, storage, IOPS, QPS, and connection metrics.
857
+ *
858
+ * @param {string} params.databaseId - Database ID.
859
+ * @param {string} params.period - Metrics aggregation period. Allowed values: 1h (last hour), 24h (last 24 hours), 7d (last 7 days), 30d (last 30 days).
860
+ * @throws {AppwriteException}
861
+ * @returns {Promise<Models.DedicatedDatabaseMetrics>}
862
+ */
863
+ getDatabaseMetrics(params: {
864
+ databaseId: string;
865
+ period?: string;
866
+ }): Promise<Models.DedicatedDatabaseMetrics>;
867
+ /**
868
+ * Get detailed performance metrics for a dedicated database. Returns CPU, memory, storage, IOPS, QPS, and connection metrics.
869
+ *
870
+ * @param {string} databaseId - Database ID.
871
+ * @param {string} period - Metrics aggregation period. Allowed values: 1h (last hour), 24h (last 24 hours), 7d (last 7 days), 30d (last 30 days).
872
+ * @throws {AppwriteException}
873
+ * @returns {Promise<Models.DedicatedDatabaseMetrics>}
874
+ * @deprecated Use the object parameter style method for a better developer experience.
875
+ */
876
+ getDatabaseMetrics(databaseId: string, period?: string): Promise<Models.DedicatedDatabaseMetrics>;
877
+ /**
878
+ * Migrate a database between shared and dedicated types. Shared to dedicated provisions an always-on dedicated instance; dedicated to shared converts to a serverless instance that scales to zero when idle. Data is copied to the target with a brief read-only window during cutover.
879
+ *
880
+ * @param {string} params.databaseId - Database ID.
881
+ * @param {string} params.targetType - Target database type to migrate to. Allowed values: shared (serverless, scales to zero when idle), dedicated (always-on with persistent resources).
882
+ * @param {string} params.specification - Target compute specification to provision when migrating to dedicated. Ignored for shared. Defaults to the database's current specification.
883
+ * @throws {AppwriteException}
884
+ * @returns {Promise<Models.DedicatedDatabase>}
885
+ */
886
+ createDatabaseMigration(params: {
887
+ databaseId: string;
888
+ targetType: string;
889
+ specification?: string;
890
+ }): Promise<Models.DedicatedDatabase>;
891
+ /**
892
+ * Migrate a database between shared and dedicated types. Shared to dedicated provisions an always-on dedicated instance; dedicated to shared converts to a serverless instance that scales to zero when idle. Data is copied to the target with a brief read-only window during cutover.
893
+ *
894
+ * @param {string} databaseId - Database ID.
895
+ * @param {string} targetType - Target database type to migrate to. Allowed values: shared (serverless, scales to zero when idle), dedicated (always-on with persistent resources).
896
+ * @param {string} specification - Target compute specification to provision when migrating to dedicated. Ignored for shared. Defaults to the database's current specification.
897
+ * @throws {AppwriteException}
898
+ * @returns {Promise<Models.DedicatedDatabase>}
899
+ * @deprecated Use the object parameter style method for a better developer experience.
900
+ */
901
+ createDatabaseMigration(databaseId: string, targetType: string, specification?: string): Promise<Models.DedicatedDatabase>;
902
+ /**
903
+ * Get available point-in-time recovery windows for a dedicated database. Returns the earliest and latest recovery points.
904
+ *
905
+ * @param {string} params.databaseId - Database ID.
906
+ * @throws {AppwriteException}
907
+ * @returns {Promise<Models.DedicatedDatabasePITRWindows>}
908
+ */
909
+ getDatabasePITRWindows(params: {
910
+ databaseId: string;
911
+ }): Promise<Models.DedicatedDatabasePITRWindows>;
912
+ /**
913
+ * Get available point-in-time recovery windows for a dedicated database. Returns the earliest and latest recovery points.
914
+ *
915
+ * @param {string} databaseId - Database ID.
916
+ * @throws {AppwriteException}
917
+ * @returns {Promise<Models.DedicatedDatabasePITRWindows>}
918
+ * @deprecated Use the object parameter style method for a better developer experience.
919
+ */
920
+ getDatabasePITRWindows(databaseId: string): Promise<Models.DedicatedDatabasePITRWindows>;
921
+ /**
922
+ * Get the connection pooler configuration for a dedicated database. Returns pooler mode, max connections, and pool size settings.
923
+ *
924
+ * @param {string} params.databaseId - Database ID.
925
+ * @throws {AppwriteException}
926
+ * @returns {Promise<Models.DedicatedDatabasePooler>}
927
+ */
928
+ getDatabasePooler(params: {
929
+ databaseId: string;
930
+ }): Promise<Models.DedicatedDatabasePooler>;
931
+ /**
932
+ * Get the connection pooler configuration for a dedicated database. Returns pooler mode, max connections, and pool size settings.
933
+ *
934
+ * @param {string} databaseId - Database ID.
935
+ * @throws {AppwriteException}
936
+ * @returns {Promise<Models.DedicatedDatabasePooler>}
937
+ * @deprecated Use the object parameter style method for a better developer experience.
938
+ */
939
+ getDatabasePooler(databaseId: string): Promise<Models.DedicatedDatabasePooler>;
940
+ /**
941
+ * Update the connection pooler configuration for a dedicated database. Configure pool mode, max connections, and pool sizes.
942
+ *
943
+ * @param {string} params.databaseId - Database ID.
944
+ * @param {string} params.mode - Connection pool mode. Allowed values: transaction, session. Transaction mode returns connections to the pool after each transaction; session mode holds connections for the entire session lifetime.
945
+ * @param {number} params.maxConnections - Maximum pooled connections.
946
+ * @param {number} params.defaultPoolSize - Default pool size per user.
947
+ * @param {boolean} params.readWriteSplitting - Route SELECTs to HA replicas, writes and locked reads to the primary. Defaults to true when HA is enabled.
948
+ * @param {string} params.poolerCpuRequest - Pooler sidecar CPU request override (Kubernetes quantity, e.g. "250m" or "1"). Leave null for the proportional default (5% of DB CPU, floor 100m).
949
+ * @param {string} params.poolerCpuLimit - Pooler sidecar CPU limit override (Kubernetes quantity, e.g. "500m" or "1"). Leave null for the proportional default (10% of DB CPU, floor 200m). Changing this field rolls the database pod.
950
+ * @param {string} params.poolerMemoryRequest - Pooler sidecar memory request override (Kubernetes quantity, e.g. "128Mi" or "1Gi"). Leave null for the proportional default (7.5% of DB memory, floor 64Mi).
951
+ * @param {string} params.poolerMemoryLimit - Pooler sidecar memory limit override (Kubernetes quantity, e.g. "256Mi" or "1Gi"). Leave null for the proportional default (15% of DB memory, floor 128Mi). Changing this field rolls the database pod.
952
+ * @throws {AppwriteException}
953
+ * @returns {Promise<Models.DedicatedDatabasePooler>}
954
+ */
955
+ updateDatabasePooler(params: {
956
+ databaseId: string;
957
+ mode?: string;
958
+ maxConnections?: number;
959
+ defaultPoolSize?: number;
960
+ readWriteSplitting?: boolean;
961
+ poolerCpuRequest?: string;
962
+ poolerCpuLimit?: string;
963
+ poolerMemoryRequest?: string;
964
+ poolerMemoryLimit?: string;
965
+ }): Promise<Models.DedicatedDatabasePooler>;
966
+ /**
967
+ * Update the connection pooler configuration for a dedicated database. Configure pool mode, max connections, and pool sizes.
968
+ *
969
+ * @param {string} databaseId - Database ID.
970
+ * @param {string} mode - Connection pool mode. Allowed values: transaction, session. Transaction mode returns connections to the pool after each transaction; session mode holds connections for the entire session lifetime.
971
+ * @param {number} maxConnections - Maximum pooled connections.
972
+ * @param {number} defaultPoolSize - Default pool size per user.
973
+ * @param {boolean} readWriteSplitting - Route SELECTs to HA replicas, writes and locked reads to the primary. Defaults to true when HA is enabled.
974
+ * @param {string} poolerCpuRequest - Pooler sidecar CPU request override (Kubernetes quantity, e.g. "250m" or "1"). Leave null for the proportional default (5% of DB CPU, floor 100m).
975
+ * @param {string} poolerCpuLimit - Pooler sidecar CPU limit override (Kubernetes quantity, e.g. "500m" or "1"). Leave null for the proportional default (10% of DB CPU, floor 200m). Changing this field rolls the database pod.
976
+ * @param {string} poolerMemoryRequest - Pooler sidecar memory request override (Kubernetes quantity, e.g. "128Mi" or "1Gi"). Leave null for the proportional default (7.5% of DB memory, floor 64Mi).
977
+ * @param {string} poolerMemoryLimit - Pooler sidecar memory limit override (Kubernetes quantity, e.g. "256Mi" or "1Gi"). Leave null for the proportional default (15% of DB memory, floor 128Mi). Changing this field rolls the database pod.
978
+ * @throws {AppwriteException}
979
+ * @returns {Promise<Models.DedicatedDatabasePooler>}
980
+ * @deprecated Use the object parameter style method for a better developer experience.
981
+ */
982
+ updateDatabasePooler(databaseId: string, mode?: string, maxConnections?: number, defaultPoolSize?: number, readWriteSplitting?: boolean, poolerCpuRequest?: string, poolerCpuLimit?: string, poolerMemoryRequest?: string, poolerMemoryLimit?: string): Promise<Models.DedicatedDatabasePooler>;
983
+ /**
984
+ * List all restorations for a dedicated database. Results can be filtered by status and type.
985
+ *
986
+ * @param {string} params.databaseId - Database ID.
987
+ * @param {string} params.status - Filter by restoration status.
988
+ * @param {string} params.type - Filter by restoration type.
989
+ * @param {number} params.limit - Maximum number of restorations to return.
990
+ * @param {number} params.offset - Number of restorations to skip.
991
+ * @throws {AppwriteException}
992
+ * @returns {Promise<Models.DedicatedDatabaseRestorationList>}
993
+ */
994
+ listDatabaseRestorations(params: {
995
+ databaseId: string;
996
+ status?: string;
997
+ type?: string;
998
+ limit?: number;
999
+ offset?: number;
1000
+ }): Promise<Models.DedicatedDatabaseRestorationList>;
1001
+ /**
1002
+ * List all restorations for a dedicated database. Results can be filtered by status and type.
1003
+ *
1004
+ * @param {string} databaseId - Database ID.
1005
+ * @param {string} status - Filter by restoration status.
1006
+ * @param {string} type - Filter by restoration type.
1007
+ * @param {number} limit - Maximum number of restorations to return.
1008
+ * @param {number} offset - Number of restorations to skip.
1009
+ * @throws {AppwriteException}
1010
+ * @returns {Promise<Models.DedicatedDatabaseRestorationList>}
1011
+ * @deprecated Use the object parameter style method for a better developer experience.
1012
+ */
1013
+ listDatabaseRestorations(databaseId: string, status?: string, type?: string, limit?: number, offset?: number): Promise<Models.DedicatedDatabaseRestorationList>;
1014
+ /**
1015
+ * Restore a database from a backup or to a specific point in time (PITR). For backup restoration, provide a backupId. For PITR, provide a targetTime. PITR requires the database to have PITR enabled and is only available for enterprise databases.
1016
+ *
1017
+ * @param {string} params.databaseId - Database ID.
1018
+ * @param {string} params.type - Restoration type. Allowed values: backup, pitr. Use "backup" to restore from a specific backup, or "pitr" for point-in-time recovery.
1019
+ * @param {string} params.backupId - Backup ID to restore from (required for backup type).
1020
+ * @param {number} params.targetTime - Target time for PITR as Unix timestamp (required for pitr type).
1021
+ * @throws {AppwriteException}
1022
+ * @returns {Promise<Models.DedicatedDatabaseRestoration>}
1023
+ */
1024
+ createDatabaseRestoration(params: {
1025
+ databaseId: string;
1026
+ type?: string;
1027
+ backupId?: string;
1028
+ targetTime?: number;
1029
+ }): Promise<Models.DedicatedDatabaseRestoration>;
1030
+ /**
1031
+ * Restore a database from a backup or to a specific point in time (PITR). For backup restoration, provide a backupId. For PITR, provide a targetTime. PITR requires the database to have PITR enabled and is only available for enterprise databases.
1032
+ *
1033
+ * @param {string} databaseId - Database ID.
1034
+ * @param {string} type - Restoration type. Allowed values: backup, pitr. Use "backup" to restore from a specific backup, or "pitr" for point-in-time recovery.
1035
+ * @param {string} backupId - Backup ID to restore from (required for backup type).
1036
+ * @param {number} targetTime - Target time for PITR as Unix timestamp (required for pitr type).
1037
+ * @throws {AppwriteException}
1038
+ * @returns {Promise<Models.DedicatedDatabaseRestoration>}
1039
+ * @deprecated Use the object parameter style method for a better developer experience.
1040
+ */
1041
+ createDatabaseRestoration(databaseId: string, type?: string, backupId?: string, targetTime?: number): Promise<Models.DedicatedDatabaseRestoration>;
1042
+ /**
1043
+ * Get details of a specific database restoration including its status, type, and timestamps.
1044
+ *
1045
+ * @param {string} params.databaseId - Database ID.
1046
+ * @param {string} params.restorationId - Restoration ID.
1047
+ * @throws {AppwriteException}
1048
+ * @returns {Promise<Models.DedicatedDatabaseRestoration>}
1049
+ */
1050
+ getDatabaseRestoration(params: {
1051
+ databaseId: string;
1052
+ restorationId: string;
1053
+ }): Promise<Models.DedicatedDatabaseRestoration>;
1054
+ /**
1055
+ * Get details of a specific database restoration including its status, type, and timestamps.
1056
+ *
1057
+ * @param {string} databaseId - Database ID.
1058
+ * @param {string} restorationId - Restoration ID.
1059
+ * @throws {AppwriteException}
1060
+ * @returns {Promise<Models.DedicatedDatabaseRestoration>}
1061
+ * @deprecated Use the object parameter style method for a better developer experience.
1062
+ */
1063
+ getDatabaseRestoration(databaseId: string, restorationId: string): Promise<Models.DedicatedDatabaseRestoration>;
1064
+ /**
1065
+ * Get the current schema for a dedicated database. Returns collections, fields, data types, constraints, and indexes.
1066
+ *
1067
+ * @param {string} params.databaseId - Database ID.
1068
+ * @throws {AppwriteException}
1069
+ * @returns {Promise<Models.DedicatedDatabaseSchema>}
1070
+ */
1071
+ getDatabaseSchema(params: {
1072
+ databaseId: string;
1073
+ }): Promise<Models.DedicatedDatabaseSchema>;
1074
+ /**
1075
+ * Get the current schema for a dedicated database. Returns collections, fields, data types, constraints, and indexes.
1076
+ *
1077
+ * @param {string} databaseId - Database ID.
1078
+ * @throws {AppwriteException}
1079
+ * @returns {Promise<Models.DedicatedDatabaseSchema>}
1080
+ * @deprecated Use the object parameter style method for a better developer experience.
1081
+ */
1082
+ getDatabaseSchema(databaseId: string): Promise<Models.DedicatedDatabaseSchema>;
1083
+ /**
1084
+ * Preview a schema change against a dedicated database. Returns the expected impact including affected collections, records, and a dry-run diff of the schema before and after the change.
1085
+ *
1086
+ * @param {string} params.databaseId - Database ID.
1087
+ * @param {string} params.sql - Schema statement to preview.
1088
+ * @throws {AppwriteException}
1089
+ * @returns {Promise<Models.DedicatedDatabaseSchemaPreview>}
1090
+ */
1091
+ createDatabaseSchemaPreview(params: {
1092
+ databaseId: string;
1093
+ sql: string;
1094
+ }): Promise<Models.DedicatedDatabaseSchemaPreview>;
1095
+ /**
1096
+ * Preview a schema change against a dedicated database. Returns the expected impact including affected collections, records, and a dry-run diff of the schema before and after the change.
1097
+ *
1098
+ * @param {string} databaseId - Database ID.
1099
+ * @param {string} sql - Schema statement to preview.
1100
+ * @throws {AppwriteException}
1101
+ * @returns {Promise<Models.DedicatedDatabaseSchemaPreview>}
1102
+ * @deprecated Use the object parameter style method for a better developer experience.
1103
+ */
1104
+ createDatabaseSchemaPreview(databaseId: string, sql: string): Promise<Models.DedicatedDatabaseSchemaPreview>;
1105
+ /**
1106
+ * List slow queries for a dedicated database. Returns queries that exceeded the specified threshold.
1107
+ *
1108
+ * @param {string} params.databaseId - Database ID.
1109
+ * @param {number} params.limit - Maximum number of queries to return.
1110
+ * @param {number} params.thresholdMs - Minimum query duration in milliseconds.
1111
+ * @throws {AppwriteException}
1112
+ * @returns {Promise<Models.DedicatedDatabaseSlowQueryList>}
1113
+ */
1114
+ listDatabaseQueries(params: {
1115
+ databaseId: string;
1116
+ limit?: number;
1117
+ thresholdMs?: number;
1118
+ }): Promise<Models.DedicatedDatabaseSlowQueryList>;
1119
+ /**
1120
+ * List slow queries for a dedicated database. Returns queries that exceeded the specified threshold.
1121
+ *
1122
+ * @param {string} databaseId - Database ID.
1123
+ * @param {number} limit - Maximum number of queries to return.
1124
+ * @param {number} thresholdMs - Minimum query duration in milliseconds.
1125
+ * @throws {AppwriteException}
1126
+ * @returns {Promise<Models.DedicatedDatabaseSlowQueryList>}
1127
+ * @deprecated Use the object parameter style method for a better developer experience.
1128
+ */
1129
+ listDatabaseQueries(databaseId: string, limit?: number, thresholdMs?: number): Promise<Models.DedicatedDatabaseSlowQueryList>;
1130
+ /**
1131
+ * Get real-time health and status information for a dedicated database. Returns health status, readiness, uptime, connection info, replica status, and volume information.
1132
+ *
1133
+ * @param {string} params.databaseId - Database ID.
1134
+ * @throws {AppwriteException}
1135
+ * @returns {Promise<Models.DatabaseStatus>}
1136
+ */
1137
+ getDatabaseStatus(params: {
1138
+ databaseId: string;
1139
+ }): Promise<Models.DatabaseStatus>;
1140
+ /**
1141
+ * Get real-time health and status information for a dedicated database. Returns health status, readiness, uptime, connection info, replica status, and volume information.
1142
+ *
1143
+ * @param {string} databaseId - Database ID.
1144
+ * @throws {AppwriteException}
1145
+ * @returns {Promise<Models.DatabaseStatus>}
1146
+ * @deprecated Use the object parameter style method for a better developer experience.
1147
+ */
1148
+ getDatabaseStatus(databaseId: string): Promise<Models.DatabaseStatus>;
1149
+ /**
1150
+ * Upgrade a dedicated database to a new engine version. Uses blue-green deployment for zero-downtime cutover.
1151
+ *
1152
+ * @param {string} params.databaseId - Database ID.
1153
+ * @param {string} params.targetVersion - Target engine version to upgrade to.
1154
+ * @throws {AppwriteException}
1155
+ * @returns {Promise<Models.DedicatedDatabase>}
1156
+ */
1157
+ createDatabaseUpgrade(params: {
1158
+ databaseId: string;
1159
+ targetVersion: string;
1160
+ }): Promise<Models.DedicatedDatabase>;
1161
+ /**
1162
+ * Upgrade a dedicated database to a new engine version. Uses blue-green deployment for zero-downtime cutover.
1163
+ *
1164
+ * @param {string} databaseId - Database ID.
1165
+ * @param {string} targetVersion - Target engine version to upgrade to.
1166
+ * @throws {AppwriteException}
1167
+ * @returns {Promise<Models.DedicatedDatabase>}
1168
+ * @deprecated Use the object parameter style method for a better developer experience.
1169
+ */
1170
+ createDatabaseUpgrade(databaseId: string, targetVersion: string): Promise<Models.DedicatedDatabase>;
1171
+ }