appbuild-oceanbase-console 1.12.2 → 1.13.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 (53) hide show
  1. package/dist/cjs/package.json +3 -0
  2. package/dist/cjs/sdk.js +3837 -1017
  3. package/dist/cjs/sdk.js.map +1 -1
  4. package/dist/esm/package.json +3 -0
  5. package/dist/esm/sdk.js +3831 -1018
  6. package/dist/esm/sdk.js.map +1 -1
  7. package/dist/iife/sdk.js +10131 -3554
  8. package/package.json +7 -2
  9. package/types/channel.d.ts +74 -0
  10. package/types/client.d.ts +84 -16
  11. package/types/enums/appwrite-migration-resource.d.ts +25 -0
  12. package/types/enums/backup-services.d.ts +5 -0
  13. package/types/enums/billing-plan-group.d.ts +5 -0
  14. package/types/enums/browser-permission.d.ts +22 -0
  15. package/types/enums/domain-purchase-status.d.ts +6 -0
  16. package/types/enums/domain-transfer-status-enum.d.ts +10 -0
  17. package/types/enums/filter-type.d.ts +4 -0
  18. package/types/enums/firebase-migration-resource.d.ts +12 -0
  19. package/types/enums/frameworks.d.ts +17 -0
  20. package/types/enums/n-host-migration-resource.d.ts +13 -0
  21. package/types/enums/order-by.d.ts +4 -0
  22. package/types/enums/registration-type.d.ts +6 -0
  23. package/types/enums/resource-type.d.ts +6 -0
  24. package/types/enums/runtimes.d.ts +180 -0
  25. package/types/enums/scopes.d.ts +70 -0
  26. package/types/enums/supabase-migration-resource.d.ts +13 -0
  27. package/types/enums/template-reference-type.d.ts +5 -0
  28. package/types/enums/use-cases.d.ts +11 -0
  29. package/types/enums/vcs-reference-type.d.ts +5 -0
  30. package/types/index.d.ts +119 -96
  31. package/types/migrations.d.ts +10 -9
  32. package/types/models.d.ts +1270 -136
  33. package/types/query.d.ts +60 -8
  34. package/types/services/account.d.ts +162 -39
  35. package/types/services/activities.d.ts +46 -0
  36. package/types/services/avatars.d.ts +9 -8
  37. package/types/services/backups.d.ts +13 -12
  38. package/types/services/console.d.ts +41 -3
  39. package/types/services/databases.d.ts +384 -68
  40. package/types/services/domains.d.ts +223 -0
  41. package/types/services/functions.d.ts +46 -31
  42. package/types/services/health.d.ts +49 -6
  43. package/types/services/messaging.d.ts +2 -2
  44. package/types/services/organizations.d.ts +203 -36
  45. package/types/services/projects.d.ts +151 -210
  46. package/types/services/realtime.d.ts +26 -10
  47. package/types/services/sites.d.ts +49 -29
  48. package/types/services/storage.d.ts +12 -12
  49. package/types/services/tables-db.d.ts +352 -34
  50. package/types/services/teams.d.ts +4 -4
  51. package/types/services/users.d.ts +26 -2
  52. package/types/services/vcs.d.ts +4 -1
  53. package/types/services/webhooks.d.ts +165 -0
package/types/query.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- declare type QueryTypesSingle = string | number | boolean;
2
- export declare type QueryTypesList = string[] | number[] | boolean[] | Query[] | any[];
1
+ declare type QueryTypesSingle = string | number | bigint | boolean;
2
+ export declare type QueryTypesList = string[] | number[] | bigint[] | boolean[] | Query[] | any[];
3
3
  export declare type QueryTypes = QueryTypesSingle | QueryTypesList;
4
4
  declare type AttributesTypes = string | string[];
5
5
  /**
@@ -39,6 +39,14 @@ export declare class Query {
39
39
  * @returns {string}
40
40
  */
41
41
  static notEqual: (attribute: string, value: QueryTypes) => string;
42
+ /**
43
+ * Filter resources where attribute matches a regular expression pattern.
44
+ *
45
+ * @param {string} attribute The attribute to filter on.
46
+ * @param {string} pattern The regular expression pattern to match.
47
+ * @returns {string}
48
+ */
49
+ static regex: (attribute: string, pattern: string) => string;
42
50
  /**
43
51
  * Filter resources where attribute is less than value.
44
52
  *
@@ -85,15 +93,29 @@ export declare class Query {
85
93
  * @returns {string}
86
94
  */
87
95
  static isNotNull: (attribute: string) => string;
96
+ /**
97
+ * Filter resources where the specified attributes exist.
98
+ *
99
+ * @param {string[]} attributes The list of attributes that must exist.
100
+ * @returns {string}
101
+ */
102
+ static exists: (attributes: string[]) => string;
103
+ /**
104
+ * Filter resources where the specified attributes do not exist.
105
+ *
106
+ * @param {string[]} attributes The list of attributes that must not exist.
107
+ * @returns {string}
108
+ */
109
+ static notExists: (attributes: string[]) => string;
88
110
  /**
89
111
  * Filter resources where attribute is between start and end (inclusive).
90
112
  *
91
113
  * @param {string} attribute
92
- * @param {string | number} start
93
- * @param {string | number} end
114
+ * @param {string | number | bigint} start
115
+ * @param {string | number | bigint} end
94
116
  * @returns {string}
95
117
  */
96
- static between: (attribute: string, start: string | number, end: string | number) => string;
118
+ static between: (attribute: string, start: string | number | bigint, end: string | number | bigint) => string;
97
119
  /**
98
120
  * Filter resources where attribute starts with value.
99
121
  *
@@ -176,12 +198,34 @@ export declare class Query {
176
198
  static offset: (offset: number) => string;
177
199
  /**
178
200
  * Filter resources where attribute contains the specified value.
201
+ * For string attributes, checks if the string contains the substring.
179
202
  *
203
+ * Note: For array attributes, use {@link containsAny} or {@link containsAll} instead.
180
204
  * @param {string} attribute
181
205
  * @param {string | string[]} value
182
206
  * @returns {string}
183
207
  */
184
208
  static contains: (attribute: string, value: string | any[]) => string;
209
+ /**
210
+ * Filter resources where attribute contains ANY of the specified values.
211
+ * For array and relationship attributes, matches documents where the attribute
212
+ * contains at least one of the given values.
213
+ *
214
+ * @param {string} attribute
215
+ * @param {any[]} value
216
+ * @returns {string}
217
+ */
218
+ static containsAny: (attribute: string, value: any[]) => string;
219
+ /**
220
+ * Filter resources where attribute contains ALL of the specified values.
221
+ * For array and relationship attributes, matches documents where the attribute
222
+ * contains every one of the given values.
223
+ *
224
+ * @param {string} attribute
225
+ * @param {any[]} value
226
+ * @returns {string}
227
+ */
228
+ static containsAll: (attribute: string, value: any[]) => string;
185
229
  /**
186
230
  * Filter resources where attribute does not contain the specified value.
187
231
  *
@@ -203,11 +247,11 @@ export declare class Query {
203
247
  * Filter resources where attribute is not between start and end (exclusive).
204
248
  *
205
249
  * @param {string} attribute
206
- * @param {string | number} start
207
- * @param {string | number} end
250
+ * @param {string | number | bigint} start
251
+ * @param {string | number | bigint} end
208
252
  * @returns {string}
209
253
  */
210
- static notBetween: (attribute: string, start: string | number, end: string | number) => string;
254
+ static notBetween: (attribute: string, start: string | number | bigint, end: string | number | bigint) => string;
211
255
  /**
212
256
  * Filter resources where attribute does not start with value.
213
257
  *
@@ -282,6 +326,14 @@ export declare class Query {
282
326
  * @returns {string}
283
327
  */
284
328
  static and: (queries: string[]) => string;
329
+ /**
330
+ * Filter array elements where at least one element matches all the specified queries.
331
+ *
332
+ * @param {string} attribute The attribute containing the array to filter on.
333
+ * @param {string[]} queries The list of query strings to match against array elements.
334
+ * @returns {string}
335
+ */
336
+ static elemMatch: (attribute: string, queries: string[]) => string;
285
337
  /**
286
338
  * Filter resources where attribute is at a specific distance from the given coordinates.
287
339
  *
@@ -1,5 +1,6 @@
1
1
  import { Client } from '../client';
2
2
  import type { Models } from '../models';
3
+ import { Scopes } from '../enums/scopes';
3
4
  import { AuthenticatorType } from '../enums/authenticator-type';
4
5
  import { AuthenticationFactor } from '../enums/authentication-factor';
5
6
  import { OAuthProvider } from '../enums/o-auth-provider';
@@ -70,37 +71,37 @@ export declare class Account {
70
71
  /**
71
72
  * Add a new billing address to a user's account.
72
73
  *
73
- * @param {string} params.country -
74
- * @param {string} params.streetAddress -
75
- * @param {string} params.city -
76
- * @param {string} params.state -
77
- * @param {string} params.postalCode - Postal code
74
+ * @param {string} params.country - Country
75
+ * @param {string} params.city - City
76
+ * @param {string} params.streetAddress - Street address
78
77
  * @param {string} params.addressLine2 - Address line 2
78
+ * @param {string} params.state - State or province
79
+ * @param {string} params.postalCode - Postal code
79
80
  * @throws {AppwriteException}
80
81
  * @returns {Promise<Models.BillingAddress>}
81
82
  */
82
83
  createBillingAddress(params: {
83
84
  country: string;
84
- streetAddress: string;
85
85
  city: string;
86
- state: string;
87
- postalCode?: string;
86
+ streetAddress: string;
88
87
  addressLine2?: string;
88
+ state?: string;
89
+ postalCode?: string;
89
90
  }): Promise<Models.BillingAddress>;
90
91
  /**
91
92
  * Add a new billing address to a user's account.
92
93
  *
93
- * @param {string} country -
94
- * @param {string} streetAddress -
95
- * @param {string} city -
96
- * @param {string} state -
97
- * @param {string} postalCode - Postal code
94
+ * @param {string} country - Country
95
+ * @param {string} city - City
96
+ * @param {string} streetAddress - Street address
98
97
  * @param {string} addressLine2 - Address line 2
98
+ * @param {string} state - State or province
99
+ * @param {string} postalCode - Postal code
99
100
  * @throws {AppwriteException}
100
101
  * @returns {Promise<Models.BillingAddress>}
101
102
  * @deprecated Use the object parameter style method for a better developer experience.
102
103
  */
103
- createBillingAddress(country: string, streetAddress: string, city: string, state: string, postalCode?: string, addressLine2?: string): Promise<Models.BillingAddress>;
104
+ createBillingAddress(country: string, city: string, streetAddress: string, addressLine2?: string, state?: string, postalCode?: string): Promise<Models.BillingAddress>;
104
105
  /**
105
106
  * Get a specific billing address for a user using it's ID.
106
107
  *
@@ -123,40 +124,40 @@ export declare class Account {
123
124
  /**
124
125
  * Update a specific billing address using it's ID.
125
126
  *
126
- * @param {string} params.billingAddressId - Billing address unique ID
127
- * @param {string} params.country -
128
- * @param {string} params.streetAddress -
129
- * @param {string} params.city -
130
- * @param {string} params.state -
131
- * @param {string} params.postalCode - Postla code
127
+ * @param {string} params.billingAddressId - Unique ID of billing address
128
+ * @param {string} params.country - Country
129
+ * @param {string} params.city - City
130
+ * @param {string} params.streetAddress - Street address
132
131
  * @param {string} params.addressLine2 - Address line 2
132
+ * @param {string} params.state - State or province
133
+ * @param {string} params.postalCode - Postal code
133
134
  * @throws {AppwriteException}
134
135
  * @returns {Promise<Models.BillingAddress>}
135
136
  */
136
137
  updateBillingAddress(params: {
137
138
  billingAddressId: string;
138
139
  country: string;
139
- streetAddress: string;
140
140
  city: string;
141
- state: string;
142
- postalCode?: string;
141
+ streetAddress: string;
143
142
  addressLine2?: string;
143
+ state?: string;
144
+ postalCode?: string;
144
145
  }): Promise<Models.BillingAddress>;
145
146
  /**
146
147
  * Update a specific billing address using it's ID.
147
148
  *
148
- * @param {string} billingAddressId - Billing address unique ID
149
- * @param {string} country -
150
- * @param {string} streetAddress -
151
- * @param {string} city -
152
- * @param {string} state -
153
- * @param {string} postalCode - Postla code
149
+ * @param {string} billingAddressId - Unique ID of billing address
150
+ * @param {string} country - Country
151
+ * @param {string} city - City
152
+ * @param {string} streetAddress - Street address
154
153
  * @param {string} addressLine2 - Address line 2
154
+ * @param {string} state - State or province
155
+ * @param {string} postalCode - Postal code
155
156
  * @throws {AppwriteException}
156
157
  * @returns {Promise<Models.BillingAddress>}
157
158
  * @deprecated Use the object parameter style method for a better developer experience.
158
159
  */
159
- updateBillingAddress(billingAddressId: string, country: string, streetAddress: string, city: string, state: string, postalCode?: string, addressLine2?: string): Promise<Models.BillingAddress>;
160
+ updateBillingAddress(billingAddressId: string, country: string, city: string, streetAddress: string, addressLine2?: string, state?: string, postalCode?: string): Promise<Models.BillingAddress>;
160
161
  /**
161
162
  * Delete a specific billing address using it's ID.
162
163
  *
@@ -265,7 +266,7 @@ export declare class Account {
265
266
  /**
266
267
  * List all invoices tied to an account.
267
268
  *
268
- * @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/databases#querying-documents). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following attributes: teamId, aggregationId, amount, currency, from, to, dueAt, attempts, status, grossAmount
269
+ * @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/databases#querying-documents). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following attributes: teamId, aggregationId, type, amount, currency, from, to, dueAt, attempts, status, grossAmount
269
270
  * @throws {AppwriteException}
270
271
  * @returns {Promise<Models.InvoiceList>}
271
272
  */
@@ -275,7 +276,7 @@ export declare class Account {
275
276
  /**
276
277
  * List all invoices tied to an account.
277
278
  *
278
- * @param {string[]} queries - Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https://appwrite.io/docs/databases#querying-documents). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following attributes: teamId, aggregationId, amount, currency, from, to, dueAt, attempts, status, grossAmount
279
+ * @param {string[]} queries - Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https://appwrite.io/docs/databases#querying-documents). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following attributes: teamId, aggregationId, type, amount, currency, from, to, dueAt, attempts, status, grossAmount
279
280
  * @throws {AppwriteException}
280
281
  * @returns {Promise<Models.InvoiceList>}
281
282
  * @deprecated Use the object parameter style method for a better developer experience.
@@ -284,10 +285,132 @@ export declare class Account {
284
285
  /**
285
286
  * Use this endpoint to create a JSON Web Token. You can use the resulting JWT to authenticate on behalf of the current user when working with the Appwrite server-side API and SDKs. The JWT secret is valid for 15 minutes from its creation and will be invalid if the user will logout in that time frame.
286
287
  *
288
+ * @param {number} params.duration - Time in seconds before JWT expires. Default duration is 900 seconds, and maximum is 3600 seconds.
287
289
  * @throws {AppwriteException}
288
290
  * @returns {Promise<Models.Jwt>}
289
291
  */
290
- createJWT(): Promise<Models.Jwt>;
292
+ createJWT(params?: {
293
+ duration?: number;
294
+ }): Promise<Models.Jwt>;
295
+ /**
296
+ * Use this endpoint to create a JSON Web Token. You can use the resulting JWT to authenticate on behalf of the current user when working with the Appwrite server-side API and SDKs. The JWT secret is valid for 15 minutes from its creation and will be invalid if the user will logout in that time frame.
297
+ *
298
+ * @param {number} duration - Time in seconds before JWT expires. Default duration is 900 seconds, and maximum is 3600 seconds.
299
+ * @throws {AppwriteException}
300
+ * @returns {Promise<Models.Jwt>}
301
+ * @deprecated Use the object parameter style method for a better developer experience.
302
+ */
303
+ createJWT(duration?: number): Promise<Models.Jwt>;
304
+ /**
305
+ * Get a list of all API keys from the current account.
306
+ *
307
+ * @param {boolean} params.total - When set to false, the total count returned will be 0 and will not be calculated.
308
+ * @throws {AppwriteException}
309
+ * @returns {Promise<Models.KeyList>}
310
+ */
311
+ listKeys(params?: {
312
+ total?: boolean;
313
+ }): Promise<Models.KeyList>;
314
+ /**
315
+ * Get a list of all API keys from the current account.
316
+ *
317
+ * @param {boolean} total - When set to false, the total count returned will be 0 and will not be calculated.
318
+ * @throws {AppwriteException}
319
+ * @returns {Promise<Models.KeyList>}
320
+ * @deprecated Use the object parameter style method for a better developer experience.
321
+ */
322
+ listKeys(total?: boolean): Promise<Models.KeyList>;
323
+ /**
324
+ * Create a new account API key.
325
+ *
326
+ * @param {string} params.name - Key name. Max length: 128 chars.
327
+ * @param {Scopes[]} params.scopes - Key scopes list. Maximum of 100 scopes are allowed.
328
+ * @param {string} params.expire - Expiration time in [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format. Use null for unlimited expiration.
329
+ * @throws {AppwriteException}
330
+ * @returns {Promise<Models.Key>}
331
+ */
332
+ createKey(params: {
333
+ name: string;
334
+ scopes: Scopes[];
335
+ expire?: string;
336
+ }): Promise<Models.Key>;
337
+ /**
338
+ * Create a new account API key.
339
+ *
340
+ * @param {string} name - Key name. Max length: 128 chars.
341
+ * @param {Scopes[]} scopes - Key scopes list. Maximum of 100 scopes are allowed.
342
+ * @param {string} expire - Expiration time in [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format. Use null for unlimited expiration.
343
+ * @throws {AppwriteException}
344
+ * @returns {Promise<Models.Key>}
345
+ * @deprecated Use the object parameter style method for a better developer experience.
346
+ */
347
+ createKey(name: string, scopes: Scopes[], expire?: string): Promise<Models.Key>;
348
+ /**
349
+ * Get a key by its unique ID. This endpoint returns details about a specific API key in your account including it's scopes.
350
+ *
351
+ * @param {string} params.keyId - Key unique ID.
352
+ * @throws {AppwriteException}
353
+ * @returns {Promise<Models.Key>}
354
+ */
355
+ getKey(params: {
356
+ keyId: string;
357
+ }): Promise<Models.Key>;
358
+ /**
359
+ * Get a key by its unique ID. This endpoint returns details about a specific API key in your account including it's scopes.
360
+ *
361
+ * @param {string} keyId - Key unique ID.
362
+ * @throws {AppwriteException}
363
+ * @returns {Promise<Models.Key>}
364
+ * @deprecated Use the object parameter style method for a better developer experience.
365
+ */
366
+ getKey(keyId: string): Promise<Models.Key>;
367
+ /**
368
+ * Update a key by its unique ID. Use this endpoint to update the name, scopes, or expiration time of an API key.
369
+ *
370
+ * @param {string} params.keyId - Key unique ID.
371
+ * @param {string} params.name - Key name. Max length: 128 chars.
372
+ * @param {Scopes[]} params.scopes - Key scopes list. Maximum of 100 scopes are allowed.
373
+ * @param {string} params.expire - Expiration time in [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format. Use null for unlimited expiration.
374
+ * @throws {AppwriteException}
375
+ * @returns {Promise<Models.Key>}
376
+ */
377
+ updateKey(params: {
378
+ keyId: string;
379
+ name: string;
380
+ scopes: Scopes[];
381
+ expire?: string;
382
+ }): Promise<Models.Key>;
383
+ /**
384
+ * Update a key by its unique ID. Use this endpoint to update the name, scopes, or expiration time of an API key.
385
+ *
386
+ * @param {string} keyId - Key unique ID.
387
+ * @param {string} name - Key name. Max length: 128 chars.
388
+ * @param {Scopes[]} scopes - Key scopes list. Maximum of 100 scopes are allowed.
389
+ * @param {string} expire - Expiration time in [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format. Use null for unlimited expiration.
390
+ * @throws {AppwriteException}
391
+ * @returns {Promise<Models.Key>}
392
+ * @deprecated Use the object parameter style method for a better developer experience.
393
+ */
394
+ updateKey(keyId: string, name: string, scopes: Scopes[], expire?: string): Promise<Models.Key>;
395
+ /**
396
+ * Delete a key by its unique ID. Once deleted, the key can no longer be used to authenticate API calls.
397
+ *
398
+ * @param {string} params.keyId - Key unique ID.
399
+ * @throws {AppwriteException}
400
+ * @returns {Promise<{}>}
401
+ */
402
+ deleteKey(params: {
403
+ keyId: string;
404
+ }): Promise<{}>;
405
+ /**
406
+ * Delete a key by its unique ID. Once deleted, the key can no longer be used to authenticate API calls.
407
+ *
408
+ * @param {string} keyId - Key unique ID.
409
+ * @throws {AppwriteException}
410
+ * @returns {Promise<{}>}
411
+ * @deprecated Use the object parameter style method for a better developer experience.
412
+ */
413
+ deleteKey(keyId: string): Promise<{}>;
291
414
  /**
292
415
  * Get the list of latest security activity logs for the currently logged in user. Each log returns user IP address, location and date and time of log.
293
416
  *
@@ -696,7 +819,7 @@ export declare class Account {
696
819
  paymentMethodId: string;
697
820
  expiryMonth: number;
698
821
  expiryYear: number;
699
- state: string;
822
+ state?: string;
700
823
  }): Promise<Models.PaymentMethod>;
701
824
  /**
702
825
  * Update a new payment method for the current user account.
@@ -709,7 +832,7 @@ export declare class Account {
709
832
  * @returns {Promise<Models.PaymentMethod>}
710
833
  * @deprecated Use the object parameter style method for a better developer experience.
711
834
  */
712
- updatePaymentMethod(paymentMethodId: string, expiryMonth: number, expiryYear: number, state: string): Promise<Models.PaymentMethod>;
835
+ updatePaymentMethod(paymentMethodId: string, expiryMonth: number, expiryYear: number, state?: string): Promise<Models.PaymentMethod>;
713
836
  /**
714
837
  * Delete a specific payment method from a user's account.
715
838
  *
@@ -953,7 +1076,7 @@ export declare class Account {
953
1076
  * A user is limited to 10 active sessions at a time by default. [Learn more about session limits](https://appwrite.io/docs/authentication-security#limits).
954
1077
  *
955
1078
  *
956
- * @param {OAuthProvider} params.provider - OAuth2 Provider. Currently, supported providers are: amazon, apple, auth0, authentik, autodesk, bitbucket, bitly, box, dailymotion, discord, disqus, dropbox, etsy, facebook, figma, github, gitlab, google, linkedin, microsoft, notion, oidc, okta, paypal, paypalSandbox, podio, salesforce, slack, spotify, stripe, tradeshift, tradeshiftBox, twitch, wordpress, yahoo, yammer, yandex, zoho, zoom, githubImagine.
1079
+ * @param {OAuthProvider} params.provider - OAuth2 Provider. Currently, supported providers are: amazon, apple, auth0, authentik, autodesk, bitbucket, bitly, box, dailymotion, discord, disqus, dropbox, etsy, facebook, figma, github, gitlab, google, linkedin, microsoft, notion, oidc, okta, paypal, paypalSandbox, podio, salesforce, slack, spotify, stripe, tradeshift, tradeshiftBox, twitch, wordpress, yahoo, yammer, yandex, zoho, zoom.
957
1080
  * @param {string} params.success - URL to redirect back to your app after a successful login attempt. Only URLs from hostnames in your project's platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
958
1081
  * @param {string} params.failure - URL to redirect back to your app after a failed login attempt. Only URLs from hostnames in your project's platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
959
1082
  * @param {string[]} params.scopes - A list of custom OAuth2 scopes. Check each provider internal docs for a list of supported scopes. Maximum of 100 scopes are allowed, each 4096 characters long.
@@ -974,7 +1097,7 @@ export declare class Account {
974
1097
  * A user is limited to 10 active sessions at a time by default. [Learn more about session limits](https://appwrite.io/docs/authentication-security#limits).
975
1098
  *
976
1099
  *
977
- * @param {OAuthProvider} provider - OAuth2 Provider. Currently, supported providers are: amazon, apple, auth0, authentik, autodesk, bitbucket, bitly, box, dailymotion, discord, disqus, dropbox, etsy, facebook, figma, github, gitlab, google, linkedin, microsoft, notion, oidc, okta, paypal, paypalSandbox, podio, salesforce, slack, spotify, stripe, tradeshift, tradeshiftBox, twitch, wordpress, yahoo, yammer, yandex, zoho, zoom, githubImagine.
1100
+ * @param {OAuthProvider} provider - OAuth2 Provider. Currently, supported providers are: amazon, apple, auth0, authentik, autodesk, bitbucket, bitly, box, dailymotion, discord, disqus, dropbox, etsy, facebook, figma, github, gitlab, google, linkedin, microsoft, notion, oidc, okta, paypal, paypalSandbox, podio, salesforce, slack, spotify, stripe, tradeshift, tradeshiftBox, twitch, wordpress, yahoo, yammer, yandex, zoho, zoom.
978
1101
  * @param {string} success - URL to redirect back to your app after a successful login attempt. Only URLs from hostnames in your project's platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
979
1102
  * @param {string} failure - URL to redirect back to your app after a failed login attempt. Only URLs from hostnames in your project's platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
980
1103
  * @param {string[]} scopes - A list of custom OAuth2 scopes. Check each provider internal docs for a list of supported scopes. Maximum of 100 scopes are allowed, each 4096 characters long.
@@ -1230,7 +1353,7 @@ export declare class Account {
1230
1353
  *
1231
1354
  * A user is limited to 10 active sessions at a time by default. [Learn more about session limits](https://appwrite.io/docs/authentication-security#limits).
1232
1355
  *
1233
- * @param {OAuthProvider} params.provider - OAuth2 Provider. Currently, supported providers are: amazon, apple, auth0, authentik, autodesk, bitbucket, bitly, box, dailymotion, discord, disqus, dropbox, etsy, facebook, figma, github, gitlab, google, linkedin, microsoft, notion, oidc, okta, paypal, paypalSandbox, podio, salesforce, slack, spotify, stripe, tradeshift, tradeshiftBox, twitch, wordpress, yahoo, yammer, yandex, zoho, zoom, githubImagine.
1356
+ * @param {OAuthProvider} params.provider - OAuth2 Provider. Currently, supported providers are: amazon, apple, auth0, authentik, autodesk, bitbucket, bitly, box, dailymotion, discord, disqus, dropbox, etsy, facebook, figma, github, gitlab, google, linkedin, microsoft, notion, oidc, okta, paypal, paypalSandbox, podio, salesforce, slack, spotify, stripe, tradeshift, tradeshiftBox, twitch, wordpress, yahoo, yammer, yandex, zoho, zoom.
1234
1357
  * @param {string} params.success - URL to redirect back to your app after a successful login attempt. Only URLs from hostnames in your project's platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
1235
1358
  * @param {string} params.failure - URL to redirect back to your app after a failed login attempt. Only URLs from hostnames in your project's platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
1236
1359
  * @param {string[]} params.scopes - A list of custom OAuth2 scopes. Check each provider internal docs for a list of supported scopes. Maximum of 100 scopes are allowed, each 4096 characters long.
@@ -1250,7 +1373,7 @@ export declare class Account {
1250
1373
  *
1251
1374
  * A user is limited to 10 active sessions at a time by default. [Learn more about session limits](https://appwrite.io/docs/authentication-security#limits).
1252
1375
  *
1253
- * @param {OAuthProvider} provider - OAuth2 Provider. Currently, supported providers are: amazon, apple, auth0, authentik, autodesk, bitbucket, bitly, box, dailymotion, discord, disqus, dropbox, etsy, facebook, figma, github, gitlab, google, linkedin, microsoft, notion, oidc, okta, paypal, paypalSandbox, podio, salesforce, slack, spotify, stripe, tradeshift, tradeshiftBox, twitch, wordpress, yahoo, yammer, yandex, zoho, zoom, githubImagine.
1376
+ * @param {OAuthProvider} provider - OAuth2 Provider. Currently, supported providers are: amazon, apple, auth0, authentik, autodesk, bitbucket, bitly, box, dailymotion, discord, disqus, dropbox, etsy, facebook, figma, github, gitlab, google, linkedin, microsoft, notion, oidc, okta, paypal, paypalSandbox, podio, salesforce, slack, spotify, stripe, tradeshift, tradeshiftBox, twitch, wordpress, yahoo, yammer, yandex, zoho, zoom.
1254
1377
  * @param {string} success - URL to redirect back to your app after a successful login attempt. Only URLs from hostnames in your project's platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
1255
1378
  * @param {string} failure - URL to redirect back to your app after a failed login attempt. Only URLs from hostnames in your project's platform list are allowed. This requirement helps to prevent an [open redirect](https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html) attack against your project API.
1256
1379
  * @param {string[]} scopes - A list of custom OAuth2 scopes. Check each provider internal docs for a list of supported scopes. Maximum of 100 scopes are allowed, each 4096 characters long.
@@ -0,0 +1,46 @@
1
+ import { Client } from '../client';
2
+ import type { Models } from '../models';
3
+ export declare class Activities {
4
+ client: Client;
5
+ constructor(client: Client);
6
+ /**
7
+ * List all events for selected filters.
8
+ *
9
+ * @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/databases#querying-documents). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on attributes such as userId, teamId, etc.
10
+ * @throws {AppwriteException}
11
+ * @returns {Promise<Models.ActivityEventList>}
12
+ */
13
+ listEvents(params?: {
14
+ queries?: string;
15
+ }): Promise<Models.ActivityEventList>;
16
+ /**
17
+ * List all events for selected filters.
18
+ *
19
+ * @param {string} queries - Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https://appwrite.io/docs/databases#querying-documents). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on attributes such as userId, teamId, etc.
20
+ * @throws {AppwriteException}
21
+ * @returns {Promise<Models.ActivityEventList>}
22
+ * @deprecated Use the object parameter style method for a better developer experience.
23
+ */
24
+ listEvents(queries?: string): Promise<Models.ActivityEventList>;
25
+ /**
26
+ * Get event by ID.
27
+ *
28
+ *
29
+ * @param {string} params.eventId - Event ID.
30
+ * @throws {AppwriteException}
31
+ * @returns {Promise<Models.ActivityEvent>}
32
+ */
33
+ getEvent(params: {
34
+ eventId: string;
35
+ }): Promise<Models.ActivityEvent>;
36
+ /**
37
+ * Get event by ID.
38
+ *
39
+ *
40
+ * @param {string} eventId - Event ID.
41
+ * @throws {AppwriteException}
42
+ * @returns {Promise<Models.ActivityEvent>}
43
+ * @deprecated Use the object parameter style method for a better developer experience.
44
+ */
45
+ getEvent(eventId: string): Promise<Models.ActivityEvent>;
46
+ }
@@ -4,7 +4,8 @@ import { CreditCard } from '../enums/credit-card';
4
4
  import { Flag } from '../enums/flag';
5
5
  import { Theme } from '../enums/theme';
6
6
  import { Timezone } from '../enums/timezone';
7
- import { Output } from '../enums/output';
7
+ import { BrowserPermission } from '../enums/browser-permission';
8
+ import { ImageFormat } from '../enums/image-format';
8
9
  export declare class Avatars {
9
10
  client: Client;
10
11
  constructor(client: Client);
@@ -253,12 +254,12 @@ export declare class Avatars {
253
254
  * @param {number} params.longitude - Geolocation longitude. Pass a number between -180 to 180. Defaults to 0.
254
255
  * @param {number} params.accuracy - Geolocation accuracy in meters. Pass a number between 0 to 100000. Defaults to 0.
255
256
  * @param {boolean} params.touch - Enable touch support. Pass 0 for no touch, or 1 for touch enabled. Defaults to 0.
256
- * @param {string[]} params.permissions - Browser permissions to grant. Pass an array of permission names like ["geolocation", "camera", "microphone"]. Defaults to empty.
257
+ * @param {BrowserPermission[]} params.permissions - Browser permissions to grant. Pass an array of permission names like ["geolocation", "camera", "microphone"]. Defaults to empty.
257
258
  * @param {number} params.sleep - Wait time in seconds before taking the screenshot. Pass an integer between 0 to 10. Defaults to 0.
258
259
  * @param {number} params.width - Output image width. Pass 0 to use original width, or an integer between 1 to 2000. Defaults to 0 (original width).
259
260
  * @param {number} params.height - Output image height. Pass 0 to use original height, or an integer between 1 to 2000. Defaults to 0 (original height).
260
261
  * @param {number} params.quality - Screenshot quality. Pass an integer between 0 to 100. Defaults to keep existing image quality.
261
- * @param {Output} params.output - Output format type (jpeg, jpg, png, gif and webp).
262
+ * @param {ImageFormat} params.output - Output format type (jpeg, jpg, png, gif and webp).
262
263
  * @throws {AppwriteException}
263
264
  * @returns {string}
264
265
  */
@@ -277,12 +278,12 @@ export declare class Avatars {
277
278
  longitude?: number;
278
279
  accuracy?: number;
279
280
  touch?: boolean;
280
- permissions?: string[];
281
+ permissions?: BrowserPermission[];
281
282
  sleep?: number;
282
283
  width?: number;
283
284
  height?: number;
284
285
  quality?: number;
285
- output?: Output;
286
+ output?: ImageFormat;
286
287
  }): string;
287
288
  /**
288
289
  * Use this endpoint to capture a screenshot of any website URL. This endpoint uses a headless browser to render the webpage and capture it as an image.
@@ -305,15 +306,15 @@ export declare class Avatars {
305
306
  * @param {number} longitude - Geolocation longitude. Pass a number between -180 to 180. Defaults to 0.
306
307
  * @param {number} accuracy - Geolocation accuracy in meters. Pass a number between 0 to 100000. Defaults to 0.
307
308
  * @param {boolean} touch - Enable touch support. Pass 0 for no touch, or 1 for touch enabled. Defaults to 0.
308
- * @param {string[]} permissions - Browser permissions to grant. Pass an array of permission names like ["geolocation", "camera", "microphone"]. Defaults to empty.
309
+ * @param {BrowserPermission[]} permissions - Browser permissions to grant. Pass an array of permission names like ["geolocation", "camera", "microphone"]. Defaults to empty.
309
310
  * @param {number} sleep - Wait time in seconds before taking the screenshot. Pass an integer between 0 to 10. Defaults to 0.
310
311
  * @param {number} width - Output image width. Pass 0 to use original width, or an integer between 1 to 2000. Defaults to 0 (original width).
311
312
  * @param {number} height - Output image height. Pass 0 to use original height, or an integer between 1 to 2000. Defaults to 0 (original height).
312
313
  * @param {number} quality - Screenshot quality. Pass an integer between 0 to 100. Defaults to keep existing image quality.
313
- * @param {Output} output - Output format type (jpeg, jpg, png, gif and webp).
314
+ * @param {ImageFormat} output - Output format type (jpeg, jpg, png, gif and webp).
314
315
  * @throws {AppwriteException}
315
316
  * @returns {string}
316
317
  * @deprecated Use the object parameter style method for a better developer experience.
317
318
  */
318
- getScreenshot(url: string, headers?: object, viewportWidth?: number, viewportHeight?: number, scale?: number, theme?: Theme, userAgent?: string, fullpage?: boolean, locale?: string, timezone?: Timezone, latitude?: number, longitude?: number, accuracy?: number, touch?: boolean, permissions?: string[], sleep?: number, width?: number, height?: number, quality?: number, output?: Output): string;
319
+ getScreenshot(url: string, headers?: object, viewportWidth?: number, viewportHeight?: number, scale?: number, theme?: Theme, userAgent?: string, fullpage?: boolean, locale?: string, timezone?: Timezone, latitude?: number, longitude?: number, accuracy?: number, touch?: boolean, permissions?: BrowserPermission[], sleep?: number, width?: number, height?: number, quality?: number, output?: ImageFormat): string;
319
320
  }