@appwrite.io/console 1.5.2 → 1.6.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/README.md +3 -3
  2. package/dist/cjs/sdk.js +7673 -9723
  3. package/dist/cjs/sdk.js.map +1 -1
  4. package/dist/esm/sdk.js +7673 -9723
  5. package/dist/esm/sdk.js.map +1 -1
  6. package/dist/iife/sdk.js +7673 -9723
  7. package/docs/examples/organizations/validate-invoice.md +14 -0
  8. package/package.json +1 -1
  9. package/src/client.ts +21 -4
  10. package/src/enums/o-auth-provider.ts +1 -0
  11. package/src/models.ts +118 -6
  12. package/src/services/account.ts +126 -430
  13. package/src/services/assistant.ts +2 -7
  14. package/src/services/avatars.ts +7 -21
  15. package/src/services/backups.ts +24 -84
  16. package/src/services/console.ts +14 -49
  17. package/src/services/databases.ts +96 -336
  18. package/src/services/functions.ts +55 -192
  19. package/src/services/graphql.ts +4 -14
  20. package/src/services/health.ts +50 -175
  21. package/src/services/locale.ts +16 -56
  22. package/src/services/messaging.ts +92 -322
  23. package/src/services/migrations.ts +24 -84
  24. package/src/services/organizations.ts +86 -196
  25. package/src/services/project.ts +12 -42
  26. package/src/services/projects.ts +92 -322
  27. package/src/services/proxy.ts +10 -35
  28. package/src/services/storage.ts +27 -93
  29. package/src/services/teams.ts +28 -98
  30. package/src/services/users.ts +86 -301
  31. package/src/services/vcs.ts +20 -70
  32. package/types/enums/o-auth-provider.d.ts +1 -0
  33. package/types/models.d.ts +118 -6
  34. package/types/services/account.d.ts +4 -128
  35. package/types/services/assistant.d.ts +0 -2
  36. package/types/services/avatars.d.ts +0 -14
  37. package/types/services/backups.d.ts +0 -24
  38. package/types/services/console.d.ts +0 -14
  39. package/types/services/databases.d.ts +0 -96
  40. package/types/services/functions.d.ts +0 -56
  41. package/types/services/graphql.d.ts +0 -4
  42. package/types/services/health.d.ts +0 -50
  43. package/types/services/locale.d.ts +0 -16
  44. package/types/services/messaging.d.ts +0 -92
  45. package/types/services/migrations.d.ts +0 -24
  46. package/types/services/organizations.d.ts +11 -58
  47. package/types/services/project.d.ts +0 -12
  48. package/types/services/projects.d.ts +0 -92
  49. package/types/services/proxy.d.ts +0 -10
  50. package/types/services/storage.d.ts +0 -30
  51. package/types/services/teams.d.ts +0 -28
  52. package/types/services/users.d.ts +0 -86
  53. package/types/services/vcs.d.ts +0 -20
@@ -11,14 +11,12 @@ export class Health {
11
11
  }
12
12
 
13
13
  /**
14
- * Get HTTP
15
- *
16
14
  * Check the Appwrite HTTP server is up and responsive.
17
15
  *
18
16
  * @throws {AppwriteException}
19
17
  * @returns {Promise<Models.HealthStatus>}
20
18
  */
21
- async get(): Promise<Models.HealthStatus> {
19
+ get(): Promise<Models.HealthStatus> {
22
20
  const apiPath = '/health';
23
21
  const payload: Payload = {};
24
22
  const uri = new URL(this.client.config.endpoint + apiPath);
@@ -27,10 +25,7 @@ export class Health {
27
25
  'content-type': 'application/json',
28
26
  }
29
27
 
30
- payload['project'] = this.client.config.project;
31
-
32
-
33
- return await this.client.call(
28
+ return this.client.call(
34
29
  'get',
35
30
  uri,
36
31
  apiHeaders,
@@ -38,14 +33,12 @@ export class Health {
38
33
  );
39
34
  }
40
35
  /**
41
- * Get antivirus
42
- *
43
36
  * Check the Appwrite Antivirus server is up and connection is successful.
44
37
  *
45
38
  * @throws {AppwriteException}
46
39
  * @returns {Promise<Models.HealthAntivirus>}
47
40
  */
48
- async getAntivirus(): Promise<Models.HealthAntivirus> {
41
+ getAntivirus(): Promise<Models.HealthAntivirus> {
49
42
  const apiPath = '/health/anti-virus';
50
43
  const payload: Payload = {};
51
44
  const uri = new URL(this.client.config.endpoint + apiPath);
@@ -54,10 +47,7 @@ export class Health {
54
47
  'content-type': 'application/json',
55
48
  }
56
49
 
57
- payload['project'] = this.client.config.project;
58
-
59
-
60
- return await this.client.call(
50
+ return this.client.call(
61
51
  'get',
62
52
  uri,
63
53
  apiHeaders,
@@ -65,14 +55,12 @@ export class Health {
65
55
  );
66
56
  }
67
57
  /**
68
- * Get cache
69
- *
70
58
  * Check the Appwrite in-memory cache servers are up and connection is successful.
71
59
  *
72
60
  * @throws {AppwriteException}
73
61
  * @returns {Promise<Models.HealthStatus>}
74
62
  */
75
- async getCache(): Promise<Models.HealthStatus> {
63
+ getCache(): Promise<Models.HealthStatus> {
76
64
  const apiPath = '/health/cache';
77
65
  const payload: Payload = {};
78
66
  const uri = new URL(this.client.config.endpoint + apiPath);
@@ -81,10 +69,7 @@ export class Health {
81
69
  'content-type': 'application/json',
82
70
  }
83
71
 
84
- payload['project'] = this.client.config.project;
85
-
86
-
87
- return await this.client.call(
72
+ return this.client.call(
88
73
  'get',
89
74
  uri,
90
75
  apiHeaders,
@@ -92,15 +77,13 @@ export class Health {
92
77
  );
93
78
  }
94
79
  /**
95
- * Get the SSL certificate for a domain
96
- *
97
80
  * Get the SSL certificate for a domain
98
81
  *
99
82
  * @param {string} domain
100
83
  * @throws {AppwriteException}
101
84
  * @returns {Promise<Models.HealthCertificate>}
102
85
  */
103
- async getCertificate(domain?: string): Promise<Models.HealthCertificate> {
86
+ getCertificate(domain?: string): Promise<Models.HealthCertificate> {
104
87
  const apiPath = '/health/certificate';
105
88
  const payload: Payload = {};
106
89
  if (typeof domain !== 'undefined') {
@@ -112,10 +95,7 @@ export class Health {
112
95
  'content-type': 'application/json',
113
96
  }
114
97
 
115
- payload['project'] = this.client.config.project;
116
-
117
-
118
- return await this.client.call(
98
+ return this.client.call(
119
99
  'get',
120
100
  uri,
121
101
  apiHeaders,
@@ -123,14 +103,12 @@ export class Health {
123
103
  );
124
104
  }
125
105
  /**
126
- * Get DB
127
- *
128
106
  * Check the Appwrite database servers are up and connection is successful.
129
107
  *
130
108
  * @throws {AppwriteException}
131
109
  * @returns {Promise<Models.HealthStatus>}
132
110
  */
133
- async getDB(): Promise<Models.HealthStatus> {
111
+ getDB(): Promise<Models.HealthStatus> {
134
112
  const apiPath = '/health/db';
135
113
  const payload: Payload = {};
136
114
  const uri = new URL(this.client.config.endpoint + apiPath);
@@ -139,10 +117,7 @@ export class Health {
139
117
  'content-type': 'application/json',
140
118
  }
141
119
 
142
- payload['project'] = this.client.config.project;
143
-
144
-
145
- return await this.client.call(
120
+ return this.client.call(
146
121
  'get',
147
122
  uri,
148
123
  apiHeaders,
@@ -150,14 +125,12 @@ export class Health {
150
125
  );
151
126
  }
152
127
  /**
153
- * Get pubsub
154
- *
155
128
  * Check the Appwrite pub-sub servers are up and connection is successful.
156
129
  *
157
130
  * @throws {AppwriteException}
158
131
  * @returns {Promise<Models.HealthStatus>}
159
132
  */
160
- async getPubSub(): Promise<Models.HealthStatus> {
133
+ getPubSub(): Promise<Models.HealthStatus> {
161
134
  const apiPath = '/health/pubsub';
162
135
  const payload: Payload = {};
163
136
  const uri = new URL(this.client.config.endpoint + apiPath);
@@ -166,10 +139,7 @@ export class Health {
166
139
  'content-type': 'application/json',
167
140
  }
168
141
 
169
- payload['project'] = this.client.config.project;
170
-
171
-
172
- return await this.client.call(
142
+ return this.client.call(
173
143
  'get',
174
144
  uri,
175
145
  apiHeaders,
@@ -177,15 +147,13 @@ export class Health {
177
147
  );
178
148
  }
179
149
  /**
180
- * Get billing aggregation queue
181
- *
182
150
  * Get billing aggregation queue
183
151
  *
184
152
  * @param {number} threshold
185
153
  * @throws {AppwriteException}
186
154
  * @returns {Promise<Models.HealthQueue>}
187
155
  */
188
- async getQueueBillingAggregation(threshold?: number): Promise<Models.HealthQueue> {
156
+ getQueueBillingAggregation(threshold?: number): Promise<Models.HealthQueue> {
189
157
  const apiPath = '/health/queue/billing-aggregation';
190
158
  const payload: Payload = {};
191
159
  if (typeof threshold !== 'undefined') {
@@ -197,10 +165,7 @@ export class Health {
197
165
  'content-type': 'application/json',
198
166
  }
199
167
 
200
- payload['project'] = this.client.config.project;
201
-
202
-
203
- return await this.client.call(
168
+ return this.client.call(
204
169
  'get',
205
170
  uri,
206
171
  apiHeaders,
@@ -208,15 +173,13 @@ export class Health {
208
173
  );
209
174
  }
210
175
  /**
211
- * Get builds queue
212
- *
213
176
  * Get the number of builds that are waiting to be processed in the Appwrite internal queue server.
214
177
  *
215
178
  * @param {number} threshold
216
179
  * @throws {AppwriteException}
217
180
  * @returns {Promise<Models.HealthQueue>}
218
181
  */
219
- async getQueueBuilds(threshold?: number): Promise<Models.HealthQueue> {
182
+ getQueueBuilds(threshold?: number): Promise<Models.HealthQueue> {
220
183
  const apiPath = '/health/queue/builds';
221
184
  const payload: Payload = {};
222
185
  if (typeof threshold !== 'undefined') {
@@ -228,10 +191,7 @@ export class Health {
228
191
  'content-type': 'application/json',
229
192
  }
230
193
 
231
- payload['project'] = this.client.config.project;
232
-
233
-
234
- return await this.client.call(
194
+ return this.client.call(
235
195
  'get',
236
196
  uri,
237
197
  apiHeaders,
@@ -239,15 +199,13 @@ export class Health {
239
199
  );
240
200
  }
241
201
  /**
242
- * Get billing aggregation queue
243
- *
244
202
  * Get the priority builds queue size.
245
203
  *
246
204
  * @param {number} threshold
247
205
  * @throws {AppwriteException}
248
206
  * @returns {Promise<Models.HealthQueue>}
249
207
  */
250
- async getQueuePriorityBuilds(threshold?: number): Promise<Models.HealthQueue> {
208
+ getQueuePriorityBuilds(threshold?: number): Promise<Models.HealthQueue> {
251
209
  const apiPath = '/health/queue/builds-priority';
252
210
  const payload: Payload = {};
253
211
  if (typeof threshold !== 'undefined') {
@@ -259,10 +217,7 @@ export class Health {
259
217
  'content-type': 'application/json',
260
218
  }
261
219
 
262
- payload['project'] = this.client.config.project;
263
-
264
-
265
- return await this.client.call(
220
+ return this.client.call(
266
221
  'get',
267
222
  uri,
268
223
  apiHeaders,
@@ -270,15 +225,13 @@ export class Health {
270
225
  );
271
226
  }
272
227
  /**
273
- * Get certificates queue
274
- *
275
228
  * Get the number of certificates that are waiting to be issued against [Letsencrypt](https://letsencrypt.org/) in the Appwrite internal queue server.
276
229
  *
277
230
  * @param {number} threshold
278
231
  * @throws {AppwriteException}
279
232
  * @returns {Promise<Models.HealthQueue>}
280
233
  */
281
- async getQueueCertificates(threshold?: number): Promise<Models.HealthQueue> {
234
+ getQueueCertificates(threshold?: number): Promise<Models.HealthQueue> {
282
235
  const apiPath = '/health/queue/certificates';
283
236
  const payload: Payload = {};
284
237
  if (typeof threshold !== 'undefined') {
@@ -290,10 +243,7 @@ export class Health {
290
243
  'content-type': 'application/json',
291
244
  }
292
245
 
293
- payload['project'] = this.client.config.project;
294
-
295
-
296
- return await this.client.call(
246
+ return this.client.call(
297
247
  'get',
298
248
  uri,
299
249
  apiHeaders,
@@ -301,8 +251,6 @@ export class Health {
301
251
  );
302
252
  }
303
253
  /**
304
- * Get databases queue
305
- *
306
254
  * Get the number of database changes that are waiting to be processed in the Appwrite internal queue server.
307
255
  *
308
256
  * @param {string} name
@@ -310,7 +258,7 @@ export class Health {
310
258
  * @throws {AppwriteException}
311
259
  * @returns {Promise<Models.HealthQueue>}
312
260
  */
313
- async getQueueDatabases(name?: string, threshold?: number): Promise<Models.HealthQueue> {
261
+ getQueueDatabases(name?: string, threshold?: number): Promise<Models.HealthQueue> {
314
262
  const apiPath = '/health/queue/databases';
315
263
  const payload: Payload = {};
316
264
  if (typeof name !== 'undefined') {
@@ -325,10 +273,7 @@ export class Health {
325
273
  'content-type': 'application/json',
326
274
  }
327
275
 
328
- payload['project'] = this.client.config.project;
329
-
330
-
331
- return await this.client.call(
276
+ return this.client.call(
332
277
  'get',
333
278
  uri,
334
279
  apiHeaders,
@@ -336,15 +281,13 @@ export class Health {
336
281
  );
337
282
  }
338
283
  /**
339
- * Get deletes queue
340
- *
341
284
  * Get the number of background destructive changes that are waiting to be processed in the Appwrite internal queue server.
342
285
  *
343
286
  * @param {number} threshold
344
287
  * @throws {AppwriteException}
345
288
  * @returns {Promise<Models.HealthQueue>}
346
289
  */
347
- async getQueueDeletes(threshold?: number): Promise<Models.HealthQueue> {
290
+ getQueueDeletes(threshold?: number): Promise<Models.HealthQueue> {
348
291
  const apiPath = '/health/queue/deletes';
349
292
  const payload: Payload = {};
350
293
  if (typeof threshold !== 'undefined') {
@@ -356,10 +299,7 @@ export class Health {
356
299
  'content-type': 'application/json',
357
300
  }
358
301
 
359
- payload['project'] = this.client.config.project;
360
-
361
-
362
- return await this.client.call(
302
+ return this.client.call(
363
303
  'get',
364
304
  uri,
365
305
  apiHeaders,
@@ -367,8 +307,6 @@ export class Health {
367
307
  );
368
308
  }
369
309
  /**
370
- * Get number of failed queue jobs
371
- *
372
310
  * Returns the amount of failed jobs in a given queue.
373
311
 
374
312
  *
@@ -377,7 +315,7 @@ export class Health {
377
315
  * @throws {AppwriteException}
378
316
  * @returns {Promise<Models.HealthQueue>}
379
317
  */
380
- async getFailedJobs(name: Name, threshold?: number): Promise<Models.HealthQueue> {
318
+ getFailedJobs(name: Name, threshold?: number): Promise<Models.HealthQueue> {
381
319
  if (typeof name === 'undefined') {
382
320
  throw new AppwriteException('Missing required parameter: "name"');
383
321
  }
@@ -392,10 +330,7 @@ export class Health {
392
330
  'content-type': 'application/json',
393
331
  }
394
332
 
395
- payload['project'] = this.client.config.project;
396
-
397
-
398
- return await this.client.call(
333
+ return this.client.call(
399
334
  'get',
400
335
  uri,
401
336
  apiHeaders,
@@ -403,15 +338,13 @@ export class Health {
403
338
  );
404
339
  }
405
340
  /**
406
- * Get functions queue
407
- *
408
341
  * Get the number of function executions that are waiting to be processed in the Appwrite internal queue server.
409
342
  *
410
343
  * @param {number} threshold
411
344
  * @throws {AppwriteException}
412
345
  * @returns {Promise<Models.HealthQueue>}
413
346
  */
414
- async getQueueFunctions(threshold?: number): Promise<Models.HealthQueue> {
347
+ getQueueFunctions(threshold?: number): Promise<Models.HealthQueue> {
415
348
  const apiPath = '/health/queue/functions';
416
349
  const payload: Payload = {};
417
350
  if (typeof threshold !== 'undefined') {
@@ -423,10 +356,7 @@ export class Health {
423
356
  'content-type': 'application/json',
424
357
  }
425
358
 
426
- payload['project'] = this.client.config.project;
427
-
428
-
429
- return await this.client.call(
359
+ return this.client.call(
430
360
  'get',
431
361
  uri,
432
362
  apiHeaders,
@@ -434,15 +364,13 @@ export class Health {
434
364
  );
435
365
  }
436
366
  /**
437
- * Get logs queue
438
- *
439
367
  * Get the number of logs that are waiting to be processed in the Appwrite internal queue server.
440
368
  *
441
369
  * @param {number} threshold
442
370
  * @throws {AppwriteException}
443
371
  * @returns {Promise<Models.HealthQueue>}
444
372
  */
445
- async getQueueLogs(threshold?: number): Promise<Models.HealthQueue> {
373
+ getQueueLogs(threshold?: number): Promise<Models.HealthQueue> {
446
374
  const apiPath = '/health/queue/logs';
447
375
  const payload: Payload = {};
448
376
  if (typeof threshold !== 'undefined') {
@@ -454,10 +382,7 @@ export class Health {
454
382
  'content-type': 'application/json',
455
383
  }
456
384
 
457
- payload['project'] = this.client.config.project;
458
-
459
-
460
- return await this.client.call(
385
+ return this.client.call(
461
386
  'get',
462
387
  uri,
463
388
  apiHeaders,
@@ -465,15 +390,13 @@ export class Health {
465
390
  );
466
391
  }
467
392
  /**
468
- * Get mails queue
469
- *
470
393
  * Get the number of mails that are waiting to be processed in the Appwrite internal queue server.
471
394
  *
472
395
  * @param {number} threshold
473
396
  * @throws {AppwriteException}
474
397
  * @returns {Promise<Models.HealthQueue>}
475
398
  */
476
- async getQueueMails(threshold?: number): Promise<Models.HealthQueue> {
399
+ getQueueMails(threshold?: number): Promise<Models.HealthQueue> {
477
400
  const apiPath = '/health/queue/mails';
478
401
  const payload: Payload = {};
479
402
  if (typeof threshold !== 'undefined') {
@@ -485,10 +408,7 @@ export class Health {
485
408
  'content-type': 'application/json',
486
409
  }
487
410
 
488
- payload['project'] = this.client.config.project;
489
-
490
-
491
- return await this.client.call(
411
+ return this.client.call(
492
412
  'get',
493
413
  uri,
494
414
  apiHeaders,
@@ -496,15 +416,13 @@ export class Health {
496
416
  );
497
417
  }
498
418
  /**
499
- * Get messaging queue
500
- *
501
419
  * Get the number of messages that are waiting to be processed in the Appwrite internal queue server.
502
420
  *
503
421
  * @param {number} threshold
504
422
  * @throws {AppwriteException}
505
423
  * @returns {Promise<Models.HealthQueue>}
506
424
  */
507
- async getQueueMessaging(threshold?: number): Promise<Models.HealthQueue> {
425
+ getQueueMessaging(threshold?: number): Promise<Models.HealthQueue> {
508
426
  const apiPath = '/health/queue/messaging';
509
427
  const payload: Payload = {};
510
428
  if (typeof threshold !== 'undefined') {
@@ -516,10 +434,7 @@ export class Health {
516
434
  'content-type': 'application/json',
517
435
  }
518
436
 
519
- payload['project'] = this.client.config.project;
520
-
521
-
522
- return await this.client.call(
437
+ return this.client.call(
523
438
  'get',
524
439
  uri,
525
440
  apiHeaders,
@@ -527,15 +442,13 @@ export class Health {
527
442
  );
528
443
  }
529
444
  /**
530
- * Get migrations queue
531
- *
532
445
  * Get the number of migrations that are waiting to be processed in the Appwrite internal queue server.
533
446
  *
534
447
  * @param {number} threshold
535
448
  * @throws {AppwriteException}
536
449
  * @returns {Promise<Models.HealthQueue>}
537
450
  */
538
- async getQueueMigrations(threshold?: number): Promise<Models.HealthQueue> {
451
+ getQueueMigrations(threshold?: number): Promise<Models.HealthQueue> {
539
452
  const apiPath = '/health/queue/migrations';
540
453
  const payload: Payload = {};
541
454
  if (typeof threshold !== 'undefined') {
@@ -547,10 +460,7 @@ export class Health {
547
460
  'content-type': 'application/json',
548
461
  }
549
462
 
550
- payload['project'] = this.client.config.project;
551
-
552
-
553
- return await this.client.call(
463
+ return this.client.call(
554
464
  'get',
555
465
  uri,
556
466
  apiHeaders,
@@ -558,15 +468,13 @@ export class Health {
558
468
  );
559
469
  }
560
470
  /**
561
- * Get stats resources queue
562
- *
563
471
  * Get the number of metrics that are waiting to be processed in the Appwrite stats resources queue.
564
472
  *
565
473
  * @param {number} threshold
566
474
  * @throws {AppwriteException}
567
475
  * @returns {Promise<Models.HealthQueue>}
568
476
  */
569
- async getQueueStatsResources(threshold?: number): Promise<Models.HealthQueue> {
477
+ getQueueStatsResources(threshold?: number): Promise<Models.HealthQueue> {
570
478
  const apiPath = '/health/queue/stats-resources';
571
479
  const payload: Payload = {};
572
480
  if (typeof threshold !== 'undefined') {
@@ -578,10 +486,7 @@ export class Health {
578
486
  'content-type': 'application/json',
579
487
  }
580
488
 
581
- payload['project'] = this.client.config.project;
582
-
583
-
584
- return await this.client.call(
489
+ return this.client.call(
585
490
  'get',
586
491
  uri,
587
492
  apiHeaders,
@@ -589,15 +494,13 @@ export class Health {
589
494
  );
590
495
  }
591
496
  /**
592
- * Get stats usage queue
593
- *
594
497
  * Get the number of metrics that are waiting to be processed in the Appwrite internal queue server.
595
498
  *
596
499
  * @param {number} threshold
597
500
  * @throws {AppwriteException}
598
501
  * @returns {Promise<Models.HealthQueue>}
599
502
  */
600
- async getQueueUsage(threshold?: number): Promise<Models.HealthQueue> {
503
+ getQueueUsage(threshold?: number): Promise<Models.HealthQueue> {
601
504
  const apiPath = '/health/queue/stats-usage';
602
505
  const payload: Payload = {};
603
506
  if (typeof threshold !== 'undefined') {
@@ -609,10 +512,7 @@ export class Health {
609
512
  'content-type': 'application/json',
610
513
  }
611
514
 
612
- payload['project'] = this.client.config.project;
613
-
614
-
615
- return await this.client.call(
515
+ return this.client.call(
616
516
  'get',
617
517
  uri,
618
518
  apiHeaders,
@@ -620,15 +520,13 @@ export class Health {
620
520
  );
621
521
  }
622
522
  /**
623
- * Get usage dump queue
624
- *
625
523
  * Get the number of projects containing metrics that are waiting to be processed in the Appwrite internal queue server.
626
524
  *
627
525
  * @param {number} threshold
628
526
  * @throws {AppwriteException}
629
527
  * @returns {Promise<Models.HealthQueue>}
630
528
  */
631
- async getQueueStatsUsageDump(threshold?: number): Promise<Models.HealthQueue> {
529
+ getQueueStatsUsageDump(threshold?: number): Promise<Models.HealthQueue> {
632
530
  const apiPath = '/health/queue/stats-usage-dump';
633
531
  const payload: Payload = {};
634
532
  if (typeof threshold !== 'undefined') {
@@ -640,10 +538,7 @@ export class Health {
640
538
  'content-type': 'application/json',
641
539
  }
642
540
 
643
- payload['project'] = this.client.config.project;
644
-
645
-
646
- return await this.client.call(
541
+ return this.client.call(
647
542
  'get',
648
543
  uri,
649
544
  apiHeaders,
@@ -651,15 +546,13 @@ export class Health {
651
546
  );
652
547
  }
653
548
  /**
654
- * Get webhooks queue
655
- *
656
549
  * Get the number of webhooks that are waiting to be processed in the Appwrite internal queue server.
657
550
  *
658
551
  * @param {number} threshold
659
552
  * @throws {AppwriteException}
660
553
  * @returns {Promise<Models.HealthQueue>}
661
554
  */
662
- async getQueueWebhooks(threshold?: number): Promise<Models.HealthQueue> {
555
+ getQueueWebhooks(threshold?: number): Promise<Models.HealthQueue> {
663
556
  const apiPath = '/health/queue/webhooks';
664
557
  const payload: Payload = {};
665
558
  if (typeof threshold !== 'undefined') {
@@ -671,10 +564,7 @@ export class Health {
671
564
  'content-type': 'application/json',
672
565
  }
673
566
 
674
- payload['project'] = this.client.config.project;
675
-
676
-
677
- return await this.client.call(
567
+ return this.client.call(
678
568
  'get',
679
569
  uri,
680
570
  apiHeaders,
@@ -682,14 +572,12 @@ export class Health {
682
572
  );
683
573
  }
684
574
  /**
685
- * Get storage
686
- *
687
575
  * Check the Appwrite storage device is up and connection is successful.
688
576
  *
689
577
  * @throws {AppwriteException}
690
578
  * @returns {Promise<Models.HealthStatus>}
691
579
  */
692
- async getStorage(): Promise<Models.HealthStatus> {
580
+ getStorage(): Promise<Models.HealthStatus> {
693
581
  const apiPath = '/health/storage';
694
582
  const payload: Payload = {};
695
583
  const uri = new URL(this.client.config.endpoint + apiPath);
@@ -698,10 +586,7 @@ export class Health {
698
586
  'content-type': 'application/json',
699
587
  }
700
588
 
701
- payload['project'] = this.client.config.project;
702
-
703
-
704
- return await this.client.call(
589
+ return this.client.call(
705
590
  'get',
706
591
  uri,
707
592
  apiHeaders,
@@ -709,14 +594,12 @@ export class Health {
709
594
  );
710
595
  }
711
596
  /**
712
- * Get local storage
713
- *
714
597
  * Check the Appwrite local storage device is up and connection is successful.
715
598
  *
716
599
  * @throws {AppwriteException}
717
600
  * @returns {Promise<Models.HealthStatus>}
718
601
  */
719
- async getStorageLocal(): Promise<Models.HealthStatus> {
602
+ getStorageLocal(): Promise<Models.HealthStatus> {
720
603
  const apiPath = '/health/storage/local';
721
604
  const payload: Payload = {};
722
605
  const uri = new URL(this.client.config.endpoint + apiPath);
@@ -725,10 +608,7 @@ export class Health {
725
608
  'content-type': 'application/json',
726
609
  }
727
610
 
728
- payload['project'] = this.client.config.project;
729
-
730
-
731
- return await this.client.call(
611
+ return this.client.call(
732
612
  'get',
733
613
  uri,
734
614
  apiHeaders,
@@ -736,14 +616,12 @@ export class Health {
736
616
  );
737
617
  }
738
618
  /**
739
- * Get time
740
- *
741
619
  * Check the Appwrite server time is synced with Google remote NTP server. We use this technology to smoothly handle leap seconds with no disruptive events. The [Network Time Protocol](https://en.wikipedia.org/wiki/Network_Time_Protocol) (NTP) is used by hundreds of millions of computers and devices to synchronize their clocks over the Internet. If your computer sets its own clock, it likely uses NTP.
742
620
  *
743
621
  * @throws {AppwriteException}
744
622
  * @returns {Promise<Models.HealthTime>}
745
623
  */
746
- async getTime(): Promise<Models.HealthTime> {
624
+ getTime(): Promise<Models.HealthTime> {
747
625
  const apiPath = '/health/time';
748
626
  const payload: Payload = {};
749
627
  const uri = new URL(this.client.config.endpoint + apiPath);
@@ -752,10 +630,7 @@ export class Health {
752
630
  'content-type': 'application/json',
753
631
  }
754
632
 
755
- payload['project'] = this.client.config.project;
756
-
757
-
758
- return await this.client.call(
633
+ return this.client.call(
759
634
  'get',
760
635
  uri,
761
636
  apiHeaders,