node-appwrite 22.1.3 → 23.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/client.d.mts +33 -0
- package/dist/client.d.ts +33 -0
- package/dist/client.js +52 -4
- package/dist/client.js.map +1 -1
- package/dist/client.mjs +52 -4
- package/dist/client.mjs.map +1 -1
- package/dist/enums/backup-services.d.mts +3 -0
- package/dist/enums/backup-services.d.ts +3 -0
- package/dist/enums/backup-services.js +3 -0
- package/dist/enums/backup-services.js.map +1 -1
- package/dist/enums/backup-services.mjs +3 -0
- package/dist/enums/backup-services.mjs.map +1 -1
- package/dist/enums/database-type.d.mts +3 -1
- package/dist/enums/database-type.d.ts +3 -1
- package/dist/enums/database-type.js +2 -0
- package/dist/enums/database-type.js.map +1 -1
- package/dist/enums/database-type.mjs +2 -0
- package/dist/enums/database-type.mjs.map +1 -1
- package/dist/enums/databases-index-type.d.mts +8 -0
- package/dist/enums/databases-index-type.d.ts +8 -0
- package/dist/enums/databases-index-type.js +13 -0
- package/dist/enums/databases-index-type.js.map +1 -0
- package/dist/enums/databases-index-type.mjs +12 -0
- package/dist/enums/databases-index-type.mjs.map +1 -0
- package/dist/enums/scopes.d.mts +4 -0
- package/dist/enums/scopes.d.ts +4 -0
- package/dist/enums/scopes.js +4 -0
- package/dist/enums/scopes.js.map +1 -1
- package/dist/enums/scopes.mjs +4 -0
- package/dist/enums/scopes.mjs.map +1 -1
- package/dist/enums/{index-type.d.mts → tables-db-index-type.d.mts} +2 -2
- package/dist/enums/{index-type.d.ts → tables-db-index-type.d.ts} +2 -2
- package/dist/enums/tables-db-index-type.js +13 -0
- package/dist/enums/tables-db-index-type.js.map +1 -0
- package/dist/enums/tables-db-index-type.mjs +12 -0
- package/dist/enums/tables-db-index-type.mjs.map +1 -0
- package/dist/enums/template-reference-type.d.mts +1 -1
- package/dist/enums/template-reference-type.d.ts +1 -1
- package/dist/enums/template-reference-type.js +1 -1
- package/dist/enums/template-reference-type.js.map +1 -1
- package/dist/enums/template-reference-type.mjs +1 -1
- package/dist/enums/template-reference-type.mjs.map +1 -1
- package/dist/index.d.mts +4 -1
- package/dist/index.d.ts +4 -1
- package/dist/index.js +18 -3
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +4 -1
- package/dist/index.mjs.map +1 -1
- package/dist/models.d.mts +107 -9
- package/dist/models.d.ts +107 -9
- package/dist/services/databases.d.mts +5 -5
- package/dist/services/databases.d.ts +5 -5
- package/dist/services/databases.js.map +1 -1
- package/dist/services/databases.mjs.map +1 -1
- package/dist/services/functions.d.mts +20 -8
- package/dist/services/functions.d.ts +20 -8
- package/dist/services/functions.js +28 -8
- package/dist/services/functions.js.map +1 -1
- package/dist/services/functions.mjs +28 -8
- package/dist/services/functions.mjs.map +1 -1
- package/dist/services/health.d.mts +0 -95
- package/dist/services/health.d.ts +0 -95
- package/dist/services/health.js +0 -120
- package/dist/services/health.js.map +1 -1
- package/dist/services/health.mjs +0 -120
- package/dist/services/health.mjs.map +1 -1
- package/dist/services/project.d.mts +136 -0
- package/dist/services/project.d.ts +136 -0
- package/dist/services/project.js +183 -0
- package/dist/services/project.js.map +1 -0
- package/dist/services/project.mjs +182 -0
- package/dist/services/project.mjs.map +1 -0
- package/dist/services/sites.d.mts +26 -8
- package/dist/services/sites.d.ts +26 -8
- package/dist/services/sites.js +55 -25
- package/dist/services/sites.js.map +1 -1
- package/dist/services/sites.mjs +55 -25
- package/dist/services/sites.mjs.map +1 -1
- package/dist/services/tables-db.d.mts +5 -5
- package/dist/services/tables-db.d.ts +5 -5
- package/dist/services/tables-db.js.map +1 -1
- package/dist/services/tables-db.mjs.map +1 -1
- package/dist/services/users.d.mts +26 -2
- package/dist/services/users.d.ts +26 -2
- package/dist/services/users.js +34 -0
- package/dist/services/users.js.map +1 -1
- package/dist/services/users.mjs +34 -0
- package/dist/services/users.mjs.map +1 -1
- package/dist/services/webhooks.d.mts +179 -0
- package/dist/services/webhooks.d.ts +179 -0
- package/dist/services/webhooks.js +261 -0
- package/dist/services/webhooks.js.map +1 -0
- package/dist/services/webhooks.mjs +260 -0
- package/dist/services/webhooks.mjs.map +1 -0
- package/package.json +5 -3
- package/dist/enums/index-type.js +0 -13
- package/dist/enums/index-type.js.map +0 -1
- package/dist/enums/index-type.mjs +0 -12
- package/dist/enums/index-type.mjs.map +0 -1
package/dist/models.d.mts
CHANGED
|
@@ -300,6 +300,19 @@ declare namespace Models {
|
|
|
300
300
|
*/
|
|
301
301
|
executions: Execution[];
|
|
302
302
|
};
|
|
303
|
+
/**
|
|
304
|
+
* Webhooks List
|
|
305
|
+
*/
|
|
306
|
+
export type WebhookList = {
|
|
307
|
+
/**
|
|
308
|
+
* Total number of webhooks that matched your query.
|
|
309
|
+
*/
|
|
310
|
+
total: number;
|
|
311
|
+
/**
|
|
312
|
+
* List of webhooks.
|
|
313
|
+
*/
|
|
314
|
+
webhooks: Webhook[];
|
|
315
|
+
};
|
|
303
316
|
/**
|
|
304
317
|
* Countries List
|
|
305
318
|
*/
|
|
@@ -2335,7 +2348,7 @@ declare namespace Models {
|
|
|
2335
2348
|
/**
|
|
2336
2349
|
* Row sequence ID.
|
|
2337
2350
|
*/
|
|
2338
|
-
$sequence:
|
|
2351
|
+
$sequence: string;
|
|
2339
2352
|
/**
|
|
2340
2353
|
* Table ID.
|
|
2341
2354
|
*/
|
|
@@ -2372,7 +2385,7 @@ declare namespace Models {
|
|
|
2372
2385
|
/**
|
|
2373
2386
|
* Document sequence ID.
|
|
2374
2387
|
*/
|
|
2375
|
-
$sequence:
|
|
2388
|
+
$sequence: string;
|
|
2376
2389
|
/**
|
|
2377
2390
|
* Collection ID.
|
|
2378
2391
|
*/
|
|
@@ -2407,15 +2420,15 @@ declare namespace Models {
|
|
|
2407
2420
|
*/
|
|
2408
2421
|
event: string;
|
|
2409
2422
|
/**
|
|
2410
|
-
* User ID.
|
|
2423
|
+
* User ID of the actor recorded for this log. During impersonation, this is the original impersonator, not the impersonated target user.
|
|
2411
2424
|
*/
|
|
2412
2425
|
userId: string;
|
|
2413
2426
|
/**
|
|
2414
|
-
* User
|
|
2427
|
+
* User email of the actor recorded for this log. During impersonation, this is the original impersonator.
|
|
2415
2428
|
*/
|
|
2416
2429
|
userEmail: string;
|
|
2417
2430
|
/**
|
|
2418
|
-
* User
|
|
2431
|
+
* User name of the actor recorded for this log. During impersonation, this is the original impersonator.
|
|
2419
2432
|
*/
|
|
2420
2433
|
userName: string;
|
|
2421
2434
|
/**
|
|
@@ -2567,6 +2580,14 @@ declare namespace Models {
|
|
|
2567
2580
|
* Most recent access date in ISO 8601 format. This attribute is only updated again after 24 hours.
|
|
2568
2581
|
*/
|
|
2569
2582
|
accessedAt: string;
|
|
2583
|
+
/**
|
|
2584
|
+
* Whether the user can impersonate other users.
|
|
2585
|
+
*/
|
|
2586
|
+
impersonator?: boolean;
|
|
2587
|
+
/**
|
|
2588
|
+
* ID of the original actor performing the impersonation. Present only when the current request is impersonating another user. Internal audit logs attribute the action to this user, while the impersonated target is recorded only in internal audit payload data.
|
|
2589
|
+
*/
|
|
2590
|
+
impersonatorUserId?: string;
|
|
2570
2591
|
};
|
|
2571
2592
|
/**
|
|
2572
2593
|
* AlgoMD5
|
|
@@ -3202,6 +3223,10 @@ declare namespace Models {
|
|
|
3202
3223
|
* Site framework.
|
|
3203
3224
|
*/
|
|
3204
3225
|
framework: string;
|
|
3226
|
+
/**
|
|
3227
|
+
* How many days to keep the non-active deployments before they will be automatically deleted.
|
|
3228
|
+
*/
|
|
3229
|
+
deploymentRetention: number;
|
|
3205
3230
|
/**
|
|
3206
3231
|
* Site's active deployment ID.
|
|
3207
3232
|
*/
|
|
@@ -3246,6 +3271,10 @@ declare namespace Models {
|
|
|
3246
3271
|
* The build command used to build the site.
|
|
3247
3272
|
*/
|
|
3248
3273
|
buildCommand: string;
|
|
3274
|
+
/**
|
|
3275
|
+
* Custom command to use when starting site runtime.
|
|
3276
|
+
*/
|
|
3277
|
+
startCommand: string;
|
|
3249
3278
|
/**
|
|
3250
3279
|
* The directory where the site build output is located.
|
|
3251
3280
|
*/
|
|
@@ -3271,9 +3300,13 @@ declare namespace Models {
|
|
|
3271
3300
|
*/
|
|
3272
3301
|
providerSilentMode: boolean;
|
|
3273
3302
|
/**
|
|
3274
|
-
* Machine specification for builds
|
|
3303
|
+
* Machine specification for deployment builds.
|
|
3304
|
+
*/
|
|
3305
|
+
buildSpecification: string;
|
|
3306
|
+
/**
|
|
3307
|
+
* Machine specification for SSR executions.
|
|
3275
3308
|
*/
|
|
3276
|
-
|
|
3309
|
+
runtimeSpecification: string;
|
|
3277
3310
|
/**
|
|
3278
3311
|
* Site build runtime.
|
|
3279
3312
|
*/
|
|
@@ -3327,6 +3360,10 @@ declare namespace Models {
|
|
|
3327
3360
|
* Function execution and build runtime.
|
|
3328
3361
|
*/
|
|
3329
3362
|
runtime: string;
|
|
3363
|
+
/**
|
|
3364
|
+
* How many days to keep the non-active deployments before they will be automatically deleted.
|
|
3365
|
+
*/
|
|
3366
|
+
deploymentRetention: number;
|
|
3330
3367
|
/**
|
|
3331
3368
|
* Function's active deployment ID.
|
|
3332
3369
|
*/
|
|
@@ -3400,9 +3437,13 @@ declare namespace Models {
|
|
|
3400
3437
|
*/
|
|
3401
3438
|
providerSilentMode: boolean;
|
|
3402
3439
|
/**
|
|
3403
|
-
* Machine specification for builds
|
|
3440
|
+
* Machine specification for deployment builds.
|
|
3404
3441
|
*/
|
|
3405
|
-
|
|
3442
|
+
buildSpecification: string;
|
|
3443
|
+
/**
|
|
3444
|
+
* Machine specification for executions.
|
|
3445
|
+
*/
|
|
3446
|
+
runtimeSpecification: string;
|
|
3406
3447
|
};
|
|
3407
3448
|
/**
|
|
3408
3449
|
* Runtime
|
|
@@ -3681,6 +3722,63 @@ declare namespace Models {
|
|
|
3681
3722
|
*/
|
|
3682
3723
|
scheduledAt?: string;
|
|
3683
3724
|
};
|
|
3725
|
+
/**
|
|
3726
|
+
* Webhook
|
|
3727
|
+
*/
|
|
3728
|
+
export type Webhook = {
|
|
3729
|
+
/**
|
|
3730
|
+
* Webhook ID.
|
|
3731
|
+
*/
|
|
3732
|
+
$id: string;
|
|
3733
|
+
/**
|
|
3734
|
+
* Webhook creation date in ISO 8601 format.
|
|
3735
|
+
*/
|
|
3736
|
+
$createdAt: string;
|
|
3737
|
+
/**
|
|
3738
|
+
* Webhook update date in ISO 8601 format.
|
|
3739
|
+
*/
|
|
3740
|
+
$updatedAt: string;
|
|
3741
|
+
/**
|
|
3742
|
+
* Webhook name.
|
|
3743
|
+
*/
|
|
3744
|
+
name: string;
|
|
3745
|
+
/**
|
|
3746
|
+
* Webhook URL endpoint.
|
|
3747
|
+
*/
|
|
3748
|
+
url: string;
|
|
3749
|
+
/**
|
|
3750
|
+
* Webhook trigger events.
|
|
3751
|
+
*/
|
|
3752
|
+
events: string[];
|
|
3753
|
+
/**
|
|
3754
|
+
* Indicated if SSL / TLS Certificate verification is enabled.
|
|
3755
|
+
*/
|
|
3756
|
+
security: boolean;
|
|
3757
|
+
/**
|
|
3758
|
+
* HTTP basic authentication username.
|
|
3759
|
+
*/
|
|
3760
|
+
httpUser: string;
|
|
3761
|
+
/**
|
|
3762
|
+
* HTTP basic authentication password.
|
|
3763
|
+
*/
|
|
3764
|
+
httpPass: string;
|
|
3765
|
+
/**
|
|
3766
|
+
* Signature key which can be used to validated incoming
|
|
3767
|
+
*/
|
|
3768
|
+
signatureKey: string;
|
|
3769
|
+
/**
|
|
3770
|
+
* Indicates if this webhook is enabled.
|
|
3771
|
+
*/
|
|
3772
|
+
enabled: boolean;
|
|
3773
|
+
/**
|
|
3774
|
+
* Webhook error logs from the most recent failure.
|
|
3775
|
+
*/
|
|
3776
|
+
logs: string;
|
|
3777
|
+
/**
|
|
3778
|
+
* Number of consecutive failed webhook attempts.
|
|
3779
|
+
*/
|
|
3780
|
+
attempts: number;
|
|
3781
|
+
};
|
|
3684
3782
|
/**
|
|
3685
3783
|
* Variable
|
|
3686
3784
|
*/
|
package/dist/models.d.ts
CHANGED
|
@@ -300,6 +300,19 @@ declare namespace Models {
|
|
|
300
300
|
*/
|
|
301
301
|
executions: Execution[];
|
|
302
302
|
};
|
|
303
|
+
/**
|
|
304
|
+
* Webhooks List
|
|
305
|
+
*/
|
|
306
|
+
export type WebhookList = {
|
|
307
|
+
/**
|
|
308
|
+
* Total number of webhooks that matched your query.
|
|
309
|
+
*/
|
|
310
|
+
total: number;
|
|
311
|
+
/**
|
|
312
|
+
* List of webhooks.
|
|
313
|
+
*/
|
|
314
|
+
webhooks: Webhook[];
|
|
315
|
+
};
|
|
303
316
|
/**
|
|
304
317
|
* Countries List
|
|
305
318
|
*/
|
|
@@ -2335,7 +2348,7 @@ declare namespace Models {
|
|
|
2335
2348
|
/**
|
|
2336
2349
|
* Row sequence ID.
|
|
2337
2350
|
*/
|
|
2338
|
-
$sequence:
|
|
2351
|
+
$sequence: string;
|
|
2339
2352
|
/**
|
|
2340
2353
|
* Table ID.
|
|
2341
2354
|
*/
|
|
@@ -2372,7 +2385,7 @@ declare namespace Models {
|
|
|
2372
2385
|
/**
|
|
2373
2386
|
* Document sequence ID.
|
|
2374
2387
|
*/
|
|
2375
|
-
$sequence:
|
|
2388
|
+
$sequence: string;
|
|
2376
2389
|
/**
|
|
2377
2390
|
* Collection ID.
|
|
2378
2391
|
*/
|
|
@@ -2407,15 +2420,15 @@ declare namespace Models {
|
|
|
2407
2420
|
*/
|
|
2408
2421
|
event: string;
|
|
2409
2422
|
/**
|
|
2410
|
-
* User ID.
|
|
2423
|
+
* User ID of the actor recorded for this log. During impersonation, this is the original impersonator, not the impersonated target user.
|
|
2411
2424
|
*/
|
|
2412
2425
|
userId: string;
|
|
2413
2426
|
/**
|
|
2414
|
-
* User
|
|
2427
|
+
* User email of the actor recorded for this log. During impersonation, this is the original impersonator.
|
|
2415
2428
|
*/
|
|
2416
2429
|
userEmail: string;
|
|
2417
2430
|
/**
|
|
2418
|
-
* User
|
|
2431
|
+
* User name of the actor recorded for this log. During impersonation, this is the original impersonator.
|
|
2419
2432
|
*/
|
|
2420
2433
|
userName: string;
|
|
2421
2434
|
/**
|
|
@@ -2567,6 +2580,14 @@ declare namespace Models {
|
|
|
2567
2580
|
* Most recent access date in ISO 8601 format. This attribute is only updated again after 24 hours.
|
|
2568
2581
|
*/
|
|
2569
2582
|
accessedAt: string;
|
|
2583
|
+
/**
|
|
2584
|
+
* Whether the user can impersonate other users.
|
|
2585
|
+
*/
|
|
2586
|
+
impersonator?: boolean;
|
|
2587
|
+
/**
|
|
2588
|
+
* ID of the original actor performing the impersonation. Present only when the current request is impersonating another user. Internal audit logs attribute the action to this user, while the impersonated target is recorded only in internal audit payload data.
|
|
2589
|
+
*/
|
|
2590
|
+
impersonatorUserId?: string;
|
|
2570
2591
|
};
|
|
2571
2592
|
/**
|
|
2572
2593
|
* AlgoMD5
|
|
@@ -3202,6 +3223,10 @@ declare namespace Models {
|
|
|
3202
3223
|
* Site framework.
|
|
3203
3224
|
*/
|
|
3204
3225
|
framework: string;
|
|
3226
|
+
/**
|
|
3227
|
+
* How many days to keep the non-active deployments before they will be automatically deleted.
|
|
3228
|
+
*/
|
|
3229
|
+
deploymentRetention: number;
|
|
3205
3230
|
/**
|
|
3206
3231
|
* Site's active deployment ID.
|
|
3207
3232
|
*/
|
|
@@ -3246,6 +3271,10 @@ declare namespace Models {
|
|
|
3246
3271
|
* The build command used to build the site.
|
|
3247
3272
|
*/
|
|
3248
3273
|
buildCommand: string;
|
|
3274
|
+
/**
|
|
3275
|
+
* Custom command to use when starting site runtime.
|
|
3276
|
+
*/
|
|
3277
|
+
startCommand: string;
|
|
3249
3278
|
/**
|
|
3250
3279
|
* The directory where the site build output is located.
|
|
3251
3280
|
*/
|
|
@@ -3271,9 +3300,13 @@ declare namespace Models {
|
|
|
3271
3300
|
*/
|
|
3272
3301
|
providerSilentMode: boolean;
|
|
3273
3302
|
/**
|
|
3274
|
-
* Machine specification for builds
|
|
3303
|
+
* Machine specification for deployment builds.
|
|
3304
|
+
*/
|
|
3305
|
+
buildSpecification: string;
|
|
3306
|
+
/**
|
|
3307
|
+
* Machine specification for SSR executions.
|
|
3275
3308
|
*/
|
|
3276
|
-
|
|
3309
|
+
runtimeSpecification: string;
|
|
3277
3310
|
/**
|
|
3278
3311
|
* Site build runtime.
|
|
3279
3312
|
*/
|
|
@@ -3327,6 +3360,10 @@ declare namespace Models {
|
|
|
3327
3360
|
* Function execution and build runtime.
|
|
3328
3361
|
*/
|
|
3329
3362
|
runtime: string;
|
|
3363
|
+
/**
|
|
3364
|
+
* How many days to keep the non-active deployments before they will be automatically deleted.
|
|
3365
|
+
*/
|
|
3366
|
+
deploymentRetention: number;
|
|
3330
3367
|
/**
|
|
3331
3368
|
* Function's active deployment ID.
|
|
3332
3369
|
*/
|
|
@@ -3400,9 +3437,13 @@ declare namespace Models {
|
|
|
3400
3437
|
*/
|
|
3401
3438
|
providerSilentMode: boolean;
|
|
3402
3439
|
/**
|
|
3403
|
-
* Machine specification for builds
|
|
3440
|
+
* Machine specification for deployment builds.
|
|
3404
3441
|
*/
|
|
3405
|
-
|
|
3442
|
+
buildSpecification: string;
|
|
3443
|
+
/**
|
|
3444
|
+
* Machine specification for executions.
|
|
3445
|
+
*/
|
|
3446
|
+
runtimeSpecification: string;
|
|
3406
3447
|
};
|
|
3407
3448
|
/**
|
|
3408
3449
|
* Runtime
|
|
@@ -3681,6 +3722,63 @@ declare namespace Models {
|
|
|
3681
3722
|
*/
|
|
3682
3723
|
scheduledAt?: string;
|
|
3683
3724
|
};
|
|
3725
|
+
/**
|
|
3726
|
+
* Webhook
|
|
3727
|
+
*/
|
|
3728
|
+
export type Webhook = {
|
|
3729
|
+
/**
|
|
3730
|
+
* Webhook ID.
|
|
3731
|
+
*/
|
|
3732
|
+
$id: string;
|
|
3733
|
+
/**
|
|
3734
|
+
* Webhook creation date in ISO 8601 format.
|
|
3735
|
+
*/
|
|
3736
|
+
$createdAt: string;
|
|
3737
|
+
/**
|
|
3738
|
+
* Webhook update date in ISO 8601 format.
|
|
3739
|
+
*/
|
|
3740
|
+
$updatedAt: string;
|
|
3741
|
+
/**
|
|
3742
|
+
* Webhook name.
|
|
3743
|
+
*/
|
|
3744
|
+
name: string;
|
|
3745
|
+
/**
|
|
3746
|
+
* Webhook URL endpoint.
|
|
3747
|
+
*/
|
|
3748
|
+
url: string;
|
|
3749
|
+
/**
|
|
3750
|
+
* Webhook trigger events.
|
|
3751
|
+
*/
|
|
3752
|
+
events: string[];
|
|
3753
|
+
/**
|
|
3754
|
+
* Indicated if SSL / TLS Certificate verification is enabled.
|
|
3755
|
+
*/
|
|
3756
|
+
security: boolean;
|
|
3757
|
+
/**
|
|
3758
|
+
* HTTP basic authentication username.
|
|
3759
|
+
*/
|
|
3760
|
+
httpUser: string;
|
|
3761
|
+
/**
|
|
3762
|
+
* HTTP basic authentication password.
|
|
3763
|
+
*/
|
|
3764
|
+
httpPass: string;
|
|
3765
|
+
/**
|
|
3766
|
+
* Signature key which can be used to validated incoming
|
|
3767
|
+
*/
|
|
3768
|
+
signatureKey: string;
|
|
3769
|
+
/**
|
|
3770
|
+
* Indicates if this webhook is enabled.
|
|
3771
|
+
*/
|
|
3772
|
+
enabled: boolean;
|
|
3773
|
+
/**
|
|
3774
|
+
* Webhook error logs from the most recent failure.
|
|
3775
|
+
*/
|
|
3776
|
+
logs: string;
|
|
3777
|
+
/**
|
|
3778
|
+
* Number of consecutive failed webhook attempts.
|
|
3779
|
+
*/
|
|
3780
|
+
attempts: number;
|
|
3781
|
+
};
|
|
3684
3782
|
/**
|
|
3685
3783
|
* Variable
|
|
3686
3784
|
*/
|
|
@@ -2,7 +2,7 @@ import { Client } from '../client.mjs';
|
|
|
2
2
|
import { Models } from '../models.mjs';
|
|
3
3
|
import { RelationshipType } from '../enums/relationship-type.mjs';
|
|
4
4
|
import { RelationMutate } from '../enums/relation-mutate.mjs';
|
|
5
|
-
import {
|
|
5
|
+
import { DatabasesIndexType } from '../enums/databases-index-type.mjs';
|
|
6
6
|
import { OrderBy } from '../enums/order-by.mjs';
|
|
7
7
|
import '../query.mjs';
|
|
8
8
|
import '../enums/database-type.mjs';
|
|
@@ -2211,7 +2211,7 @@ declare class Databases {
|
|
|
2211
2211
|
* @param {string} params.databaseId - Database ID.
|
|
2212
2212
|
* @param {string} params.collectionId - Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#databasesCreateCollection).
|
|
2213
2213
|
* @param {string} params.key - Index Key.
|
|
2214
|
-
* @param {
|
|
2214
|
+
* @param {DatabasesIndexType} params.type - Index type.
|
|
2215
2215
|
* @param {string[]} params.attributes - Array of attributes to index. Maximum of 100 attributes are allowed, each 32 characters long.
|
|
2216
2216
|
* @param {OrderBy[]} params.orders - Array of index orders. Maximum of 100 orders are allowed.
|
|
2217
2217
|
* @param {number[]} params.lengths - Length of index. Maximum of 100
|
|
@@ -2223,7 +2223,7 @@ declare class Databases {
|
|
|
2223
2223
|
databaseId: string;
|
|
2224
2224
|
collectionId: string;
|
|
2225
2225
|
key: string;
|
|
2226
|
-
type:
|
|
2226
|
+
type: DatabasesIndexType;
|
|
2227
2227
|
attributes: string[];
|
|
2228
2228
|
orders?: OrderBy[];
|
|
2229
2229
|
lengths?: number[];
|
|
@@ -2235,7 +2235,7 @@ declare class Databases {
|
|
|
2235
2235
|
* @param {string} databaseId - Database ID.
|
|
2236
2236
|
* @param {string} collectionId - Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#databasesCreateCollection).
|
|
2237
2237
|
* @param {string} key - Index Key.
|
|
2238
|
-
* @param {
|
|
2238
|
+
* @param {DatabasesIndexType} type - Index type.
|
|
2239
2239
|
* @param {string[]} attributes - Array of attributes to index. Maximum of 100 attributes are allowed, each 32 characters long.
|
|
2240
2240
|
* @param {OrderBy[]} orders - Array of index orders. Maximum of 100 orders are allowed.
|
|
2241
2241
|
* @param {number[]} lengths - Length of index. Maximum of 100
|
|
@@ -2243,7 +2243,7 @@ declare class Databases {
|
|
|
2243
2243
|
* @returns {Promise<Models.Index>}
|
|
2244
2244
|
* @deprecated Use the object parameter style method for a better developer experience.
|
|
2245
2245
|
*/
|
|
2246
|
-
createIndex(databaseId: string, collectionId: string, key: string, type:
|
|
2246
|
+
createIndex(databaseId: string, collectionId: string, key: string, type: DatabasesIndexType, attributes: string[], orders?: OrderBy[], lengths?: number[]): Promise<Models.Index>;
|
|
2247
2247
|
/**
|
|
2248
2248
|
* Get an index by its unique ID.
|
|
2249
2249
|
*
|
|
@@ -2,7 +2,7 @@ import { Client } from '../client.js';
|
|
|
2
2
|
import { Models } from '../models.js';
|
|
3
3
|
import { RelationshipType } from '../enums/relationship-type.js';
|
|
4
4
|
import { RelationMutate } from '../enums/relation-mutate.js';
|
|
5
|
-
import {
|
|
5
|
+
import { DatabasesIndexType } from '../enums/databases-index-type.js';
|
|
6
6
|
import { OrderBy } from '../enums/order-by.js';
|
|
7
7
|
import '../query.js';
|
|
8
8
|
import '../enums/database-type.js';
|
|
@@ -2211,7 +2211,7 @@ declare class Databases {
|
|
|
2211
2211
|
* @param {string} params.databaseId - Database ID.
|
|
2212
2212
|
* @param {string} params.collectionId - Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#databasesCreateCollection).
|
|
2213
2213
|
* @param {string} params.key - Index Key.
|
|
2214
|
-
* @param {
|
|
2214
|
+
* @param {DatabasesIndexType} params.type - Index type.
|
|
2215
2215
|
* @param {string[]} params.attributes - Array of attributes to index. Maximum of 100 attributes are allowed, each 32 characters long.
|
|
2216
2216
|
* @param {OrderBy[]} params.orders - Array of index orders. Maximum of 100 orders are allowed.
|
|
2217
2217
|
* @param {number[]} params.lengths - Length of index. Maximum of 100
|
|
@@ -2223,7 +2223,7 @@ declare class Databases {
|
|
|
2223
2223
|
databaseId: string;
|
|
2224
2224
|
collectionId: string;
|
|
2225
2225
|
key: string;
|
|
2226
|
-
type:
|
|
2226
|
+
type: DatabasesIndexType;
|
|
2227
2227
|
attributes: string[];
|
|
2228
2228
|
orders?: OrderBy[];
|
|
2229
2229
|
lengths?: number[];
|
|
@@ -2235,7 +2235,7 @@ declare class Databases {
|
|
|
2235
2235
|
* @param {string} databaseId - Database ID.
|
|
2236
2236
|
* @param {string} collectionId - Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#databasesCreateCollection).
|
|
2237
2237
|
* @param {string} key - Index Key.
|
|
2238
|
-
* @param {
|
|
2238
|
+
* @param {DatabasesIndexType} type - Index type.
|
|
2239
2239
|
* @param {string[]} attributes - Array of attributes to index. Maximum of 100 attributes are allowed, each 32 characters long.
|
|
2240
2240
|
* @param {OrderBy[]} orders - Array of index orders. Maximum of 100 orders are allowed.
|
|
2241
2241
|
* @param {number[]} lengths - Length of index. Maximum of 100
|
|
@@ -2243,7 +2243,7 @@ declare class Databases {
|
|
|
2243
2243
|
* @returns {Promise<Models.Index>}
|
|
2244
2244
|
* @deprecated Use the object parameter style method for a better developer experience.
|
|
2245
2245
|
*/
|
|
2246
|
-
createIndex(databaseId: string, collectionId: string, key: string, type:
|
|
2246
|
+
createIndex(databaseId: string, collectionId: string, key: string, type: DatabasesIndexType, attributes: string[], orders?: OrderBy[], lengths?: number[]): Promise<Models.Index>;
|
|
2247
2247
|
/**
|
|
2248
2248
|
* Get an index by its unique ID.
|
|
2249
2249
|
*
|