appwrite-cli 16.0.0 → 17.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/CHANGELOG.md +13 -0
- package/README.md +4 -4
- package/dist/bundle-win-arm64.mjs +868 -653
- package/dist/cli.cjs +840 -625
- package/dist/index.cjs +293 -489
- package/dist/index.js +321 -517
- package/dist/lib/commands/push.d.ts.map +1 -1
- package/dist/lib/commands/run.d.ts.map +1 -1
- package/dist/lib/constants.d.ts +1 -1
- package/dist/lib/questions.d.ts.map +1 -1
- package/docs/examples/project/create-variable.md +1 -0
- package/docs/examples/project/update-variable.md +1 -2
- package/docs/examples/users/update-impersonator.md +5 -0
- package/install.ps1 +2 -2
- package/install.sh +1 -1
- package/lib/commands/push.ts +6 -24
- package/lib/commands/run.ts +5 -7
- package/lib/commands/services/account.ts +0 -169
- package/lib/commands/services/health.ts +0 -68
- package/lib/commands/services/project.ts +21 -12
- package/lib/commands/services/projects.ts +0 -12
- package/lib/commands/services/users.ts +14 -1
- package/lib/constants.ts +1 -1
- package/lib/questions.ts +13 -7
- package/package.json +1 -1
- package/scoop/appwrite.config.json +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"push.d.ts","sourceRoot":"","sources":["../../../lib/commands/push.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAcpC,OAAO,EAEL,KAAK,YAAY,EACjB,KAAK,UAAU,EACf,KAAK,cAAc,EACpB,MAAM,aAAa,CAAC;AA+CrB,OAAO,EAIL,MAAM,EAEP,MAAM,sBAAsB,CAAC;AAc9B,MAAM,WAAW,WAAW;IAC1B,GAAG,CAAC,EAAE,OAAO,CAAC;IACd,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,MA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C;QACzB,MAAM,EAAE,GAAG,EAAE,CAAC;KACf,CAAC;IA6VW,SAAS,CACpB,KAAK,EAAE,GAAG,EAAE,EACZ,OAAO,GAAE;QACP,KAAK,CAAC,EAAE,OAAO,CAAC;QAChB,IAAI,CAAC,EAAE,OAAO,CAAC;QACf,aAAa,CAAC,EAAE,OAAO,CAAC;KACpB,GACL,OAAO,CAAC;QACT,kBAAkB,EAAE,MAAM,CAAC;QAC3B,oBAAoB,EAAE,MAAM,CAAC;QAC7B,iBAAiB,EAAE,GAAG,EAAE,CAAC;QACzB,MAAM,EAAE,GAAG,EAAE,CAAC;KACf,CAAC;IAuVW,UAAU,CACrB,MAAM,EAAE,GAAG,EAAE,EACb,OAAO,GAAE,gBAAqB,GAC7B,OAAO,CAAC;QACT,kBAAkB,EAAE,MAAM,CAAC;QAC3B,MAAM,EAAE,GAAG,EAAE,CAAC;KACf,CAAC;IAyIW,eAAe,CAC1B,WAAW,EAAE,mBAAmB,EAAE,EAClC,OAAO,GAAE;QAAE,gBAAgB,CAAC,EAAE,OAAO,CAAA;KAAO,GAC3C,OAAO,CAAC;QACT,kBAAkB,EAAE,MAAM,CAAC;QAC3B,MAAM,EAAE,KAAK,EAAE,CAAC;KACjB,CAAC;CAsLH;AAo3BD,eAAO,MAAM,IAAI,SAEqD,CAAC;AA6EvE,eAAO,MAAM,MAAM,SAQhB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"run.d.ts","sourceRoot":"","sources":["../../../lib/commands/run.ts"],"names":[],"mappings":"AAYA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;
|
|
1
|
+
{"version":3,"file":"run.d.ts","sourceRoot":"","sources":["../../../lib/commands/run.ts"],"names":[],"mappings":"AAYA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AA8XpC,eAAO,MAAM,GAAG,SASb,CAAC"}
|
package/dist/lib/constants.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export declare const SDK_TITLE = "Appwrite";
|
|
2
2
|
export declare const SDK_TITLE_LOWER = "appwrite";
|
|
3
|
-
export declare const SDK_VERSION = "
|
|
3
|
+
export declare const SDK_VERSION = "17.0.0";
|
|
4
4
|
export declare const SDK_NAME = "Command Line";
|
|
5
5
|
export declare const SDK_PLATFORM = "console";
|
|
6
6
|
export declare const SDK_LANGUAGE = "cli";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"questions.d.ts","sourceRoot":"","sources":["../../lib/questions.ts"],"names":[],"mappings":"AAiBA,UAAU,OAAO;IACf,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAC;CACpB;AAED,UAAU,MAAM;IACd,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,GAAG,CAAC;IACX,QAAQ,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;IAC5B,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,UAAU,QAAQ;IAChB,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,CAAC,EAAE,GAAG,CAAC;IACd,IAAI,CAAC,EAAE,CAAC,CAAC,OAAO,EAAE,OAAO,KAAK,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC,GAAG,OAAO,CAAC;IACpE,OAAO,CAAC,EACJ,CAAC,CAAC,OAAO,EAAE,OAAO,KAAK,OAAO,CAAC,MAAM,EAAE,CAAC,GAAG,MAAM,EAAE,CAAC,GACpD,CAAC,MAAM,OAAO,CAAC,MAAM,EAAE,CAAC,GAAG,MAAM,EAAE,CAAC,GACpC,MAAM,EAAE,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AAEF,eAAO,MAAM,sBAAsB,EAAE,QAAQ,EAqB5C,CAAC;AAEF,eAAO,MAAM,sBAAsB,EAAE,QAAQ,EAe5C,CAAC;AAEF,eAAO,MAAM,kBAAkB,EAAE,QAAQ,EAmBxC,CAAC;AAEF,eAAO,MAAM,sBAAsB,EAAE,QAAQ,EAmB5C,CAAC;AAEF,eAAO,MAAM,wBAAwB,EAAE,QAAQ,EAmB9C,CAAC;AAEF,eAAO,MAAM,mBAAmB,EAAE,QAAQ,EAmBzC,CAAC;AAEF,eAAO,MAAM,mBAAmB,EAAE,QAAQ,EAMzC,CAAC;AAEF,eAAO,MAAM,+BAA+B,EAAE,QAAQ,EAMrD,CAAC;AAEF,eAAO,MAAM,oBAAoB,EAAE,QAAQ,EAmB1C,CAAC;AAEF,eAAO,MAAM,4BAA4B,EAAE,QAAQ,EAkBlD,CAAC;AAEF,eAAO,MAAM,sBAAsB,EAAE,QAAQ,EAY5C,CAAC;AAEF,eAAO,MAAM,kBAAkB,EAAE,QAAQ,EAmBxC,CAAC;AAEF,eAAO,MAAM,oBAAoB,EAAE,QAAQ,EAiC1C,CAAC;AAEF,eAAO,MAAM,qBAAqB,EAAE,QAAQ,EAY3C,CAAC;AAEF,eAAO,MAAM,qBAAqB,EAAE,QAAQ,EAsB3C,CAAC;AAEF,eAAO,MAAM,mBAAmB,EAAE,QAAQ,EA+DzC,CAAC"}
|
package/install.ps1
CHANGED
|
@@ -13,8 +13,8 @@
|
|
|
13
13
|
# You can use "View source" of this page to see the full script.
|
|
14
14
|
|
|
15
15
|
# REPO
|
|
16
|
-
$GITHUB_x64_URL = "https://github.com/appwrite/sdk-for-cli/releases/download/
|
|
17
|
-
$GITHUB_arm64_URL = "https://github.com/appwrite/sdk-for-cli/releases/download/
|
|
16
|
+
$GITHUB_x64_URL = "https://github.com/appwrite/sdk-for-cli/releases/download/17.0.0/appwrite-cli-win-x64.exe"
|
|
17
|
+
$GITHUB_arm64_URL = "https://github.com/appwrite/sdk-for-cli/releases/download/17.0.0/appwrite-cli-win-arm64.exe"
|
|
18
18
|
|
|
19
19
|
$APPWRITE_BINARY_NAME = "appwrite.exe"
|
|
20
20
|
|
package/install.sh
CHANGED
|
@@ -96,7 +96,7 @@ printSuccess() {
|
|
|
96
96
|
downloadBinary() {
|
|
97
97
|
echo "[2/4] Downloading executable for $OS ($ARCH) ..."
|
|
98
98
|
|
|
99
|
-
GITHUB_LATEST_VERSION="
|
|
99
|
+
GITHUB_LATEST_VERSION="17.0.0"
|
|
100
100
|
GITHUB_FILE="appwrite-cli-${OS}-${ARCH}"
|
|
101
101
|
GITHUB_URL="https://github.com/$GITHUB_REPOSITORY_NAME/releases/download/$GITHUB_LATEST_VERSION/$GITHUB_FILE"
|
|
102
102
|
|
package/lib/commands/push.ts
CHANGED
|
@@ -829,18 +829,9 @@ export class Push {
|
|
|
829
829
|
const functionsServiceForVars = await getFunctionsService(
|
|
830
830
|
this.projectClient,
|
|
831
831
|
);
|
|
832
|
-
const { variables } = await
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
functionId: args.functionId,
|
|
836
|
-
});
|
|
837
|
-
},
|
|
838
|
-
{
|
|
839
|
-
functionId: func["$id"],
|
|
840
|
-
},
|
|
841
|
-
100,
|
|
842
|
-
"variables",
|
|
843
|
-
);
|
|
832
|
+
const { variables } = await functionsServiceForVars.listVariables({
|
|
833
|
+
functionId: func["$id"],
|
|
834
|
+
});
|
|
844
835
|
|
|
845
836
|
await Promise.all(
|
|
846
837
|
variables.map(async (variable: any) => {
|
|
@@ -1199,18 +1190,9 @@ export class Push {
|
|
|
1199
1190
|
.replaceSpinner(SPINNER_DOTS);
|
|
1200
1191
|
|
|
1201
1192
|
const sitesServiceForVars = await getSitesService(this.projectClient);
|
|
1202
|
-
const { variables } = await
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
siteId: args.siteId,
|
|
1206
|
-
});
|
|
1207
|
-
},
|
|
1208
|
-
{
|
|
1209
|
-
siteId: site["$id"],
|
|
1210
|
-
},
|
|
1211
|
-
100,
|
|
1212
|
-
"variables",
|
|
1213
|
-
);
|
|
1193
|
+
const { variables } = await sitesServiceForVars.listVariables({
|
|
1194
|
+
siteId: site["$id"],
|
|
1195
|
+
});
|
|
1214
1196
|
|
|
1215
1197
|
await Promise.all(
|
|
1216
1198
|
variables.map(async (variable: any) => {
|
package/lib/commands/run.ts
CHANGED
|
@@ -12,7 +12,6 @@ import inquirer from "inquirer";
|
|
|
12
12
|
import path from "path";
|
|
13
13
|
import { Command } from "commander";
|
|
14
14
|
import { localConfig, globalConfig } from "../config.js";
|
|
15
|
-
import { paginate } from "../paginate.js";
|
|
16
15
|
import { getFunctionsService } from "../services.js";
|
|
17
16
|
import { questionsRunFunctions } from "../questions.js";
|
|
18
17
|
import {
|
|
@@ -177,12 +176,11 @@ const runFunction = async ({
|
|
|
177
176
|
|
|
178
177
|
if (withVariables) {
|
|
179
178
|
try {
|
|
180
|
-
const { variables: remoteVariables } = await
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
);
|
|
179
|
+
const { variables: remoteVariables } = await (
|
|
180
|
+
await getFunctionsService()
|
|
181
|
+
).listVariables({
|
|
182
|
+
functionId: func["$id"],
|
|
183
|
+
});
|
|
186
184
|
|
|
187
185
|
remoteVariables.forEach((v) => {
|
|
188
186
|
allVariables[v.key] = v.value;
|
|
@@ -58,83 +58,6 @@ account
|
|
|
58
58
|
),
|
|
59
59
|
);
|
|
60
60
|
|
|
61
|
-
account
|
|
62
|
-
.command(`list-billing-addresses`)
|
|
63
|
-
.description(`List all billing addresses for a user.`)
|
|
64
|
-
.option(`--queries [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: userId, expired, failed`)
|
|
65
|
-
.action(
|
|
66
|
-
actionRunner(
|
|
67
|
-
async ({ queries }) =>
|
|
68
|
-
parse(await (await getAccountClient()).listBillingAddresses(queries)),
|
|
69
|
-
),
|
|
70
|
-
);
|
|
71
|
-
|
|
72
|
-
account
|
|
73
|
-
.command(`create-billing-address`)
|
|
74
|
-
.description(`Add a new billing address to a user's account.`)
|
|
75
|
-
.requiredOption(`--country <country>`, `Country`)
|
|
76
|
-
.requiredOption(`--city <city>`, `City`)
|
|
77
|
-
.requiredOption(`--street-address <street-address>`, `Street address`)
|
|
78
|
-
.option(`--address-line-2 <address-line-2>`, `Address line 2`)
|
|
79
|
-
.option(`--state <state>`, `State or province`)
|
|
80
|
-
.option(`--postal-code <postal-code>`, `Postal code`)
|
|
81
|
-
.action(
|
|
82
|
-
actionRunner(
|
|
83
|
-
async ({ country, city, streetAddress, addressLine2, state, postalCode }) =>
|
|
84
|
-
parse(await (await getAccountClient()).createBillingAddress(country, city, streetAddress, addressLine2, state, postalCode)),
|
|
85
|
-
),
|
|
86
|
-
);
|
|
87
|
-
|
|
88
|
-
account
|
|
89
|
-
.command(`get-billing-address`)
|
|
90
|
-
.description(`Get a specific billing address for a user using it's ID.`)
|
|
91
|
-
.requiredOption(`--billing-address-id <billing-address-id>`, `Unique ID of billing address`)
|
|
92
|
-
.action(
|
|
93
|
-
actionRunner(
|
|
94
|
-
async ({ billingAddressId }) =>
|
|
95
|
-
parse(await (await getAccountClient()).getBillingAddress(billingAddressId)),
|
|
96
|
-
),
|
|
97
|
-
);
|
|
98
|
-
|
|
99
|
-
account
|
|
100
|
-
.command(`update-billing-address`)
|
|
101
|
-
.description(`Update a specific billing address using it's ID.`)
|
|
102
|
-
.requiredOption(`--billing-address-id <billing-address-id>`, `Unique ID of billing address`)
|
|
103
|
-
.requiredOption(`--country <country>`, `Country`)
|
|
104
|
-
.requiredOption(`--city <city>`, `City`)
|
|
105
|
-
.requiredOption(`--street-address <street-address>`, `Street address`)
|
|
106
|
-
.option(`--address-line-2 <address-line-2>`, `Address line 2`)
|
|
107
|
-
.option(`--state <state>`, `State or province`)
|
|
108
|
-
.option(`--postal-code <postal-code>`, `Postal code`)
|
|
109
|
-
.action(
|
|
110
|
-
actionRunner(
|
|
111
|
-
async ({ billingAddressId, country, city, streetAddress, addressLine2, state, postalCode }) =>
|
|
112
|
-
parse(await (await getAccountClient()).updateBillingAddress(billingAddressId, country, city, streetAddress, addressLine2, state, postalCode)),
|
|
113
|
-
),
|
|
114
|
-
);
|
|
115
|
-
|
|
116
|
-
account
|
|
117
|
-
.command(`delete-billing-address`)
|
|
118
|
-
.description(`Delete a specific billing address using it's ID.`)
|
|
119
|
-
.requiredOption(`--billing-address-id <billing-address-id>`, `Billing address unique ID`)
|
|
120
|
-
.action(
|
|
121
|
-
actionRunner(
|
|
122
|
-
async ({ billingAddressId }) =>
|
|
123
|
-
parse(await (await getAccountClient()).deleteBillingAddress(billingAddressId)),
|
|
124
|
-
),
|
|
125
|
-
);
|
|
126
|
-
|
|
127
|
-
account
|
|
128
|
-
.command(`get-coupon`)
|
|
129
|
-
.description(`Get coupon details for an account.`)
|
|
130
|
-
.requiredOption(`--coupon-id <coupon-id>`, `ID of the coupon`)
|
|
131
|
-
.action(
|
|
132
|
-
actionRunner(
|
|
133
|
-
async ({ couponId }) =>
|
|
134
|
-
parse(await (await getAccountClient()).getCoupon(couponId)),
|
|
135
|
-
),
|
|
136
|
-
);
|
|
137
|
-
|
|
138
61
|
account
|
|
139
62
|
.command(`update-email`)
|
|
140
63
|
.description(`Update currently logged in user account email address. After changing user address, the user confirmation status will get reset. A new confirmation email is not sent automatically however you can use the send confirmation email endpoint again to send the confirmation email. For security measures, user password is required to complete this request.
|
|
@@ -177,17 +100,6 @@ account
|
|
|
177
100
|
),
|
|
178
101
|
);
|
|
179
102
|
|
|
180
|
-
account
|
|
181
|
-
.command(`list-invoices`)
|
|
182
|
-
.description(`List all invoices tied to an account.`)
|
|
183
|
-
.option(`--queries [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`)
|
|
184
|
-
.action(
|
|
185
|
-
actionRunner(
|
|
186
|
-
async ({ queries }) =>
|
|
187
|
-
parse(await (await getAccountClient()).listInvoices(queries)),
|
|
188
|
-
),
|
|
189
|
-
);
|
|
190
|
-
|
|
191
103
|
account
|
|
192
104
|
.command(`create-jwt`)
|
|
193
105
|
.description(`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.`)
|
|
@@ -408,87 +320,6 @@ account
|
|
|
408
320
|
),
|
|
409
321
|
);
|
|
410
322
|
|
|
411
|
-
account
|
|
412
|
-
.command(`list-payment-methods`)
|
|
413
|
-
.description(`List payment methods for this account.`)
|
|
414
|
-
.option(`--queries [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: userId, expired, failed`)
|
|
415
|
-
.action(
|
|
416
|
-
actionRunner(
|
|
417
|
-
async ({ queries }) =>
|
|
418
|
-
parse(await (await getAccountClient()).listPaymentMethods(queries)),
|
|
419
|
-
),
|
|
420
|
-
);
|
|
421
|
-
|
|
422
|
-
account
|
|
423
|
-
.command(`create-payment-method`)
|
|
424
|
-
.description(`Create a new payment method for the current user account.`)
|
|
425
|
-
.action(
|
|
426
|
-
actionRunner(
|
|
427
|
-
async () => parse(await (await getAccountClient()).createPaymentMethod()),
|
|
428
|
-
),
|
|
429
|
-
);
|
|
430
|
-
|
|
431
|
-
account
|
|
432
|
-
.command(`get-payment-method`)
|
|
433
|
-
.description(`Get a specific payment method for the user.`)
|
|
434
|
-
.requiredOption(`--payment-method-id <payment-method-id>`, `Unique ID of payment method`)
|
|
435
|
-
.action(
|
|
436
|
-
actionRunner(
|
|
437
|
-
async ({ paymentMethodId }) =>
|
|
438
|
-
parse(await (await getAccountClient()).getPaymentMethod(paymentMethodId)),
|
|
439
|
-
),
|
|
440
|
-
);
|
|
441
|
-
|
|
442
|
-
account
|
|
443
|
-
.command(`update-payment-method`)
|
|
444
|
-
.description(`Update a new payment method for the current user account.`)
|
|
445
|
-
.requiredOption(`--payment-method-id <payment-method-id>`, `Unique ID of payment method`)
|
|
446
|
-
.requiredOption(`--expiry-month <expiry-month>`, `Payment expiry month`, parseInteger)
|
|
447
|
-
.requiredOption(`--expiry-year <expiry-year>`, `Expiry year`, parseInteger)
|
|
448
|
-
.option(`--state <state>`, `State of the payment method country`)
|
|
449
|
-
.action(
|
|
450
|
-
actionRunner(
|
|
451
|
-
async ({ paymentMethodId, expiryMonth, expiryYear, state }) =>
|
|
452
|
-
parse(await (await getAccountClient()).updatePaymentMethod(paymentMethodId, expiryMonth, expiryYear, state)),
|
|
453
|
-
),
|
|
454
|
-
);
|
|
455
|
-
|
|
456
|
-
account
|
|
457
|
-
.command(`delete-payment-method`)
|
|
458
|
-
.description(`Delete a specific payment method from a user's account.`)
|
|
459
|
-
.requiredOption(`--payment-method-id <payment-method-id>`, `Unique ID of payment method`)
|
|
460
|
-
.action(
|
|
461
|
-
actionRunner(
|
|
462
|
-
async ({ paymentMethodId }) =>
|
|
463
|
-
parse(await (await getAccountClient()).deletePaymentMethod(paymentMethodId)),
|
|
464
|
-
),
|
|
465
|
-
);
|
|
466
|
-
|
|
467
|
-
account
|
|
468
|
-
.command(`update-payment-method-provider`)
|
|
469
|
-
.description(`Update payment method provider.`)
|
|
470
|
-
.requiredOption(`--payment-method-id <payment-method-id>`, `Unique ID of payment method`)
|
|
471
|
-
.requiredOption(`--provider-method-id <provider-method-id>`, `Payment method ID from the payment provider`)
|
|
472
|
-
.requiredOption(`--name <name>`, `Name in the payment method`)
|
|
473
|
-
.option(`--state <state>`, `State of the payment method country`)
|
|
474
|
-
.action(
|
|
475
|
-
actionRunner(
|
|
476
|
-
async ({ paymentMethodId, providerMethodId, name, state }) =>
|
|
477
|
-
parse(await (await getAccountClient()).updatePaymentMethodProvider(paymentMethodId, providerMethodId, name, state)),
|
|
478
|
-
),
|
|
479
|
-
);
|
|
480
|
-
|
|
481
|
-
account
|
|
482
|
-
.command(`update-payment-method-mandate-options`)
|
|
483
|
-
.description(`Update payment method mandate options.`)
|
|
484
|
-
.requiredOption(`--payment-method-id <payment-method-id>`, `Unique ID of payment method`)
|
|
485
|
-
.action(
|
|
486
|
-
actionRunner(
|
|
487
|
-
async ({ paymentMethodId }) =>
|
|
488
|
-
parse(await (await getAccountClient()).updatePaymentMethodMandateOptions(paymentMethodId)),
|
|
489
|
-
),
|
|
490
|
-
);
|
|
491
|
-
|
|
492
323
|
account
|
|
493
324
|
.command(`update-phone`)
|
|
494
325
|
.description(`Update the currently logged in user's phone number. After updating the phone number, the phone verification status will be reset. A confirmation SMS is not sent automatically, however you can use the [POST /account/verification/phone](https://appwrite.io/docs/references/cloud/client-web/account#createPhoneVerification) endpoint to send a confirmation SMS.`)
|
|
@@ -64,19 +64,6 @@ health
|
|
|
64
64
|
),
|
|
65
65
|
);
|
|
66
66
|
|
|
67
|
-
health
|
|
68
|
-
.command(`get-console-pausing`)
|
|
69
|
-
.description(`Get console pausing health status. Monitors projects approaching the pause threshold to detect potential issues with console access tracking.
|
|
70
|
-
`)
|
|
71
|
-
.option(`--threshold <threshold>`, `Percentage threshold of projects approaching pause. When hit (equal or higher), endpoint returns server error. Default value is 10.`, parseInteger)
|
|
72
|
-
.option(`--inactivity-days <inactivity-days>`, `Number of days of inactivity before a project is paused. Should match the plan's projectInactivityDays setting. Default value is 7.`, parseInteger)
|
|
73
|
-
.action(
|
|
74
|
-
actionRunner(
|
|
75
|
-
async ({ threshold, inactivityDays }) =>
|
|
76
|
-
parse(await (await getHealthClient()).getConsolePausing(threshold, inactivityDays)),
|
|
77
|
-
),
|
|
78
|
-
);
|
|
79
|
-
|
|
80
67
|
health
|
|
81
68
|
.command(`get-db`)
|
|
82
69
|
.description(`Check the Appwrite database servers are up and connection is successful.`)
|
|
@@ -106,28 +93,6 @@ health
|
|
|
106
93
|
),
|
|
107
94
|
);
|
|
108
95
|
|
|
109
|
-
health
|
|
110
|
-
.command(`get-queue-billing-project-aggregation`)
|
|
111
|
-
.description(`Get billing project aggregation queue.`)
|
|
112
|
-
.option(`--threshold <threshold>`, `Queue size threshold. When hit (equal or higher), endpoint returns server error. Default value is 5000.`, parseInteger)
|
|
113
|
-
.action(
|
|
114
|
-
actionRunner(
|
|
115
|
-
async ({ threshold }) =>
|
|
116
|
-
parse(await (await getHealthClient()).getQueueBillingProjectAggregation(threshold)),
|
|
117
|
-
),
|
|
118
|
-
);
|
|
119
|
-
|
|
120
|
-
health
|
|
121
|
-
.command(`get-queue-billing-team-aggregation`)
|
|
122
|
-
.description(`Get billing team aggregation queue.`)
|
|
123
|
-
.option(`--threshold <threshold>`, `Queue size threshold. When hit (equal or higher), endpoint returns server error. Default value is 5000.`, parseInteger)
|
|
124
|
-
.action(
|
|
125
|
-
actionRunner(
|
|
126
|
-
async ({ threshold }) =>
|
|
127
|
-
parse(await (await getHealthClient()).getQueueBillingTeamAggregation(threshold)),
|
|
128
|
-
),
|
|
129
|
-
);
|
|
130
|
-
|
|
131
96
|
health
|
|
132
97
|
.command(`get-queue-builds`)
|
|
133
98
|
.description(`Get the number of builds that are waiting to be processed in the Appwrite internal queue server.`)
|
|
@@ -139,17 +104,6 @@ health
|
|
|
139
104
|
),
|
|
140
105
|
);
|
|
141
106
|
|
|
142
|
-
health
|
|
143
|
-
.command(`get-queue-priority-builds`)
|
|
144
|
-
.description(`Get the priority builds queue size.`)
|
|
145
|
-
.option(`--threshold <threshold>`, `Queue size threshold. When hit (equal or higher), endpoint returns server error. Default value is 500.`, parseInteger)
|
|
146
|
-
.action(
|
|
147
|
-
actionRunner(
|
|
148
|
-
async ({ threshold }) =>
|
|
149
|
-
parse(await (await getHealthClient()).getQueuePriorityBuilds(threshold)),
|
|
150
|
-
),
|
|
151
|
-
);
|
|
152
|
-
|
|
153
107
|
health
|
|
154
108
|
.command(`get-queue-certificates`)
|
|
155
109
|
.description(`Get the number of certificates that are waiting to be issued against [Letsencrypt](https://letsencrypt.org/) in the Appwrite internal queue server.`)
|
|
@@ -252,17 +206,6 @@ health
|
|
|
252
206
|
),
|
|
253
207
|
);
|
|
254
208
|
|
|
255
|
-
health
|
|
256
|
-
.command(`get-queue-region-manager`)
|
|
257
|
-
.description(`Get region manager queue.`)
|
|
258
|
-
.option(`--threshold <threshold>`, `Queue size threshold. When hit (equal or higher), endpoint returns server error. Default value is 100.`, parseInteger)
|
|
259
|
-
.action(
|
|
260
|
-
actionRunner(
|
|
261
|
-
async ({ threshold }) =>
|
|
262
|
-
parse(await (await getHealthClient()).getQueueRegionManager(threshold)),
|
|
263
|
-
),
|
|
264
|
-
);
|
|
265
|
-
|
|
266
209
|
health
|
|
267
210
|
.command(`get-queue-stats-resources`)
|
|
268
211
|
.description(`Get the number of metrics that are waiting to be processed in the Appwrite stats resources queue.`)
|
|
@@ -285,17 +228,6 @@ health
|
|
|
285
228
|
),
|
|
286
229
|
);
|
|
287
230
|
|
|
288
|
-
health
|
|
289
|
-
.command(`get-queue-threats`)
|
|
290
|
-
.description(`Get threats queue.`)
|
|
291
|
-
.option(`--threshold <threshold>`, `Queue size threshold. When hit (equal or higher), endpoint returns server error. Default value is 100.`, parseInteger)
|
|
292
|
-
.action(
|
|
293
|
-
actionRunner(
|
|
294
|
-
async ({ threshold }) =>
|
|
295
|
-
parse(await (await getHealthClient()).getQueueThreats(threshold)),
|
|
296
|
-
),
|
|
297
|
-
);
|
|
298
|
-
|
|
299
231
|
health
|
|
300
232
|
.command(`get-queue-webhooks`)
|
|
301
233
|
.description(`Get the number of webhooks that are waiting to be processed in the Appwrite internal queue server.`)
|
|
@@ -41,16 +41,25 @@ project
|
|
|
41
41
|
|
|
42
42
|
project
|
|
43
43
|
.command(`list-variables`)
|
|
44
|
-
.description(`Get a list of all project
|
|
44
|
+
.description(`Get a list of all project environment variables.`)
|
|
45
|
+
.option(`--queries [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: key, resourceType, resourceId, secret`)
|
|
46
|
+
.option(
|
|
47
|
+
`--total [value]`,
|
|
48
|
+
`When set to false, the total count returned will be 0 and will not be calculated.`,
|
|
49
|
+
(value: string | undefined) =>
|
|
50
|
+
value === undefined ? true : parseBool(value),
|
|
51
|
+
)
|
|
45
52
|
.action(
|
|
46
53
|
actionRunner(
|
|
47
|
-
async (
|
|
54
|
+
async ({ queries, total }) =>
|
|
55
|
+
parse(await (await getProjectClient()).listVariables(queries, total)),
|
|
48
56
|
),
|
|
49
57
|
);
|
|
50
58
|
|
|
51
59
|
project
|
|
52
60
|
.command(`create-variable`)
|
|
53
|
-
.description(`Create a new project variable.
|
|
61
|
+
.description(`Create a new project environment variable. These variables can be accessed by all functions and sites in the project.`)
|
|
62
|
+
.requiredOption(`--variable-id <variable-id>`, `Variable 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.`)
|
|
54
63
|
.requiredOption(`--key <key>`, `Variable key. Max length: 255 chars.`)
|
|
55
64
|
.requiredOption(`--value <value>`, `Variable value. Max length: 8192 chars.`)
|
|
56
65
|
.option(
|
|
@@ -61,15 +70,15 @@ project
|
|
|
61
70
|
)
|
|
62
71
|
.action(
|
|
63
72
|
actionRunner(
|
|
64
|
-
async ({ key, value, secret }) =>
|
|
65
|
-
parse(await (await getProjectClient()).createVariable(key, value, secret)),
|
|
73
|
+
async ({ variableId, key, value, secret }) =>
|
|
74
|
+
parse(await (await getProjectClient()).createVariable(variableId, key, value, secret)),
|
|
66
75
|
),
|
|
67
76
|
);
|
|
68
77
|
|
|
69
78
|
project
|
|
70
79
|
.command(`get-variable`)
|
|
71
|
-
.description(`Get a
|
|
72
|
-
.requiredOption(`--variable-id <variable-id>`, `Variable
|
|
80
|
+
.description(`Get a variable by its unique ID. `)
|
|
81
|
+
.requiredOption(`--variable-id <variable-id>`, `Variable ID.`)
|
|
73
82
|
.action(
|
|
74
83
|
actionRunner(
|
|
75
84
|
async ({ variableId }) =>
|
|
@@ -79,9 +88,9 @@ project
|
|
|
79
88
|
|
|
80
89
|
project
|
|
81
90
|
.command(`update-variable`)
|
|
82
|
-
.description(`Update
|
|
83
|
-
.requiredOption(`--variable-id <variable-id>`, `Variable
|
|
84
|
-
.
|
|
91
|
+
.description(`Update variable by its unique ID.`)
|
|
92
|
+
.requiredOption(`--variable-id <variable-id>`, `Variable ID.`)
|
|
93
|
+
.option(`--key <key>`, `Variable key. Max length: 255 chars.`)
|
|
85
94
|
.option(`--value <value>`, `Variable value. Max length: 8192 chars.`)
|
|
86
95
|
.option(
|
|
87
96
|
`--secret [value]`,
|
|
@@ -98,8 +107,8 @@ project
|
|
|
98
107
|
|
|
99
108
|
project
|
|
100
109
|
.command(`delete-variable`)
|
|
101
|
-
.description(`Delete a
|
|
102
|
-
.requiredOption(`--variable-id <variable-id>`, `Variable
|
|
110
|
+
.description(`Delete a variable by its unique ID. `)
|
|
111
|
+
.requiredOption(`--variable-id <variable-id>`, `Variable ID.`)
|
|
103
112
|
.action(
|
|
104
113
|
actionRunner(
|
|
105
114
|
async ({ variableId }) =>
|
|
@@ -270,18 +270,6 @@ projects
|
|
|
270
270
|
),
|
|
271
271
|
);
|
|
272
272
|
|
|
273
|
-
projects
|
|
274
|
-
.command(`update-console-access`)
|
|
275
|
-
.description(`Record console access to a project. This endpoint updates the last accessed timestamp for the project to track console activity.
|
|
276
|
-
`)
|
|
277
|
-
.requiredOption(`--project-id <project-id>`, `Project ID`)
|
|
278
|
-
.action(
|
|
279
|
-
actionRunner(
|
|
280
|
-
async ({ projectId }) =>
|
|
281
|
-
parse(await (await getProjectsClient()).updateConsoleAccess(projectId)),
|
|
282
|
-
),
|
|
283
|
-
);
|
|
284
|
-
|
|
285
273
|
projects
|
|
286
274
|
.command(`list-dev-keys`)
|
|
287
275
|
.description(`List all the project\'s dev keys. Dev keys are project specific and allow you to bypass rate limits and get better error logging during development.'`)
|
|
@@ -29,7 +29,7 @@ export const users = new Command("users")
|
|
|
29
29
|
users
|
|
30
30
|
.command(`list`)
|
|
31
31
|
.description(`Get a list of all the project's users. You can use the query params to filter your results.`)
|
|
32
|
-
.option(`--queries [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: name, email, phone, status, passwordUpdate, registration, emailVerification, phoneVerification, labels`)
|
|
32
|
+
.option(`--queries [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: name, email, phone, status, passwordUpdate, registration, emailVerification, phoneVerification, labels, impersonator`)
|
|
33
33
|
.option(`--search <search>`, `Search term to filter your list results. Max length: 256 chars.`)
|
|
34
34
|
.option(
|
|
35
35
|
`--total [value]`,
|
|
@@ -241,6 +241,19 @@ users
|
|
|
241
241
|
),
|
|
242
242
|
);
|
|
243
243
|
|
|
244
|
+
users
|
|
245
|
+
.command(`update-impersonator`)
|
|
246
|
+
.description(`Enable or disable whether a user can impersonate other users. When impersonation headers are used, the request runs as the target user for API behavior, while internal audit logs still attribute the action to the original impersonator and store the impersonated target details only in internal audit payload data.
|
|
247
|
+
`)
|
|
248
|
+
.requiredOption(`--user-id <user-id>`, `User ID.`)
|
|
249
|
+
.requiredOption(`--impersonator <impersonator>`, `Whether the user can impersonate other users. When true, the user can browse project users to choose a target and can pass impersonation headers to act as that user. Internal audit logs still attribute impersonated actions to the original impersonator and store the target user details only in internal audit payload data.`, parseBool)
|
|
250
|
+
.action(
|
|
251
|
+
actionRunner(
|
|
252
|
+
async ({ userId, impersonator }) =>
|
|
253
|
+
parse(await (await getUsersClient()).updateImpersonator(userId, impersonator)),
|
|
254
|
+
),
|
|
255
|
+
);
|
|
256
|
+
|
|
244
257
|
users
|
|
245
258
|
.command(`create-jwt`)
|
|
246
259
|
.description(`Use this endpoint to create a JSON Web Token for user by its unique ID. You can use the resulting JWT to authenticate on behalf of the user. The JWT secret will become invalid if the session it uses gets deleted.`)
|
package/lib/constants.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// SDK
|
|
2
2
|
export const SDK_TITLE = 'Appwrite';
|
|
3
3
|
export const SDK_TITLE_LOWER = 'appwrite';
|
|
4
|
-
export const SDK_VERSION = '
|
|
4
|
+
export const SDK_VERSION = '17.0.0';
|
|
5
5
|
export const SDK_NAME = 'Command Line';
|
|
6
6
|
export const SDK_PLATFORM = 'console';
|
|
7
7
|
export const SDK_LANGUAGE = 'cli';
|
package/lib/questions.ts
CHANGED
|
@@ -187,15 +187,19 @@ export const questionsInitProject: Question[] = [
|
|
|
187
187
|
const client = await sdkForConsole(true);
|
|
188
188
|
const { teams } = isCloud()
|
|
189
189
|
? await paginate(
|
|
190
|
-
async (
|
|
191
|
-
(await getOrganizationsService(
|
|
190
|
+
async (args) =>
|
|
191
|
+
(await getOrganizationsService(args.sdk as Client)).list({
|
|
192
|
+
queries: args.queries as string[],
|
|
193
|
+
}),
|
|
192
194
|
{ sdk: client },
|
|
193
195
|
100,
|
|
194
196
|
"teams",
|
|
195
197
|
)
|
|
196
198
|
: await paginate(
|
|
197
|
-
async (
|
|
198
|
-
(await getTeamsService(
|
|
199
|
+
async (args) =>
|
|
200
|
+
(await getTeamsService(args.sdk as Client)).list({
|
|
201
|
+
queries: args.queries as string[],
|
|
202
|
+
}),
|
|
199
203
|
{ parseOutput: false, sdk: client },
|
|
200
204
|
100,
|
|
201
205
|
"teams",
|
|
@@ -247,7 +251,7 @@ export const questionsInitProject: Question[] = [
|
|
|
247
251
|
];
|
|
248
252
|
|
|
249
253
|
const { projects } = await paginate(
|
|
250
|
-
async () => (await getProjectsService()).list(queries),
|
|
254
|
+
async (args) => (await getProjectsService()).list(args.queries as string[]),
|
|
251
255
|
{ parseOutput: false },
|
|
252
256
|
100,
|
|
253
257
|
"projects",
|
|
@@ -342,7 +346,8 @@ export const questionsPullFunctions: Question[] = [
|
|
|
342
346
|
validate: (value: any) => validateRequired("function", value),
|
|
343
347
|
choices: async () => {
|
|
344
348
|
const { functions } = await paginate(
|
|
345
|
-
async () =>
|
|
349
|
+
async (args) =>
|
|
350
|
+
(await getFunctionsService()).list(args.queries as string[]),
|
|
346
351
|
{ parseOutput: false },
|
|
347
352
|
100,
|
|
348
353
|
"functions",
|
|
@@ -385,7 +390,8 @@ export const questionsPullSites: Question[] = [
|
|
|
385
390
|
validate: (value: any) => validateRequired("site", value),
|
|
386
391
|
choices: async () => {
|
|
387
392
|
const { sites } = await paginate(
|
|
388
|
-
async () =>
|
|
393
|
+
async (args) =>
|
|
394
|
+
(await getSitesService()).list(args.queries as string[]),
|
|
389
395
|
{ parseOutput: false },
|
|
390
396
|
100,
|
|
391
397
|
"sites",
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"type": "module",
|
|
4
4
|
"homepage": "https://appwrite.io/support",
|
|
5
5
|
"description": "Appwrite is an open-source self-hosted backend server that abstracts and simplifies complex and repetitive development tasks behind a very simple REST API",
|
|
6
|
-
"version": "
|
|
6
|
+
"version": "17.0.0",
|
|
7
7
|
"license": "BSD-3-Clause",
|
|
8
8
|
"main": "dist/index.cjs",
|
|
9
9
|
"module": "dist/index.js",
|