mirror of
https://github.com/appwrite/appwrite.git
synced 2026-05-26 13:51:13 +00:00
Compare commits
172
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
7e9d74e141 | ||
|
|
3d8cee4676 | ||
|
|
7efbae4310 | ||
|
|
1c9fd39fd6 | ||
|
|
8c854b7d07 | ||
|
|
c713357131 | ||
|
|
fe9ecb6fcb | ||
|
|
ab1541808b | ||
|
|
623a8a747d | ||
|
|
21237f8e02 | ||
|
|
f0ed75f585 | ||
|
|
34ce5099e2 | ||
|
|
c6e4afdb49 | ||
|
|
448e60479d | ||
|
|
8fe7de7ff9 | ||
|
|
8e70a5239d | ||
|
|
28beb27759 | ||
|
|
b1f5b6946a | ||
|
|
9ac594c537 | ||
|
|
6547637c96 | ||
|
|
13a7ead598 | ||
|
|
d40e793137 | ||
|
|
e5fa23ef6c | ||
|
|
053665eef9 | ||
|
|
66afd1064d | ||
|
|
e2758691af | ||
|
|
9a8a42f479 | ||
|
|
3347573f17 | ||
|
|
cceb108fd3 | ||
|
|
b905686c0e | ||
|
|
ad43be5dab | ||
|
|
ceb11e039f | ||
|
|
63e06750cf | ||
|
|
a4f7cf9f73 | ||
|
|
ba10bed271 | ||
|
|
e2979410da | ||
|
|
9b68b54743 | ||
|
|
0fbdbb386f | ||
|
|
50f26e8702 | ||
|
|
a2463f8cc3 | ||
|
|
0cdabbf959 | ||
|
|
4b752c15e8 | ||
|
|
fcce6f8d34 | ||
|
|
2443266ac5 | ||
|
|
4616a2e95d | ||
|
|
9a0e1c1840 | ||
|
|
bdbe94b56f | ||
|
|
0974e1335f | ||
|
|
61f8c99da7 | ||
|
|
150d09f656 | ||
|
|
bfce804f79 | ||
|
|
a479ce63fc | ||
|
|
8765d5650a | ||
|
|
e3ee724178 | ||
|
|
ce2f2d0ebc | ||
|
|
9f7e3146a4 | ||
|
|
e6039cf65e | ||
|
|
7b3bceeb7d | ||
|
|
90ef76ad82 | ||
|
|
5a8a900b18 | ||
|
|
c2645be4e1 | ||
|
|
20221cd6b6 | ||
|
|
275ff3dbf2 | ||
|
|
b6fbddad81 | ||
|
|
39c5b6c4d0 | ||
|
|
f9274dad3f | ||
|
|
3568af54b3 | ||
|
|
71b6ac0364 | ||
|
|
919b01a1b1 | ||
|
|
3d69998f9c | ||
|
|
d2000ee9d8 | ||
|
|
0718f90405 | ||
|
|
73f5b4227d | ||
|
|
52766cfdba | ||
|
|
ba542554ce | ||
|
|
deb5039352 | ||
|
|
793057c823 | ||
|
|
4a86b2d5b1 | ||
|
|
d36e42377b | ||
|
|
d9522ac6b8 | ||
|
|
db1b87ecbb | ||
|
|
99d16dfc60 | ||
|
|
725870b1b1 | ||
|
|
38ef0ad399 | ||
|
|
c961316f46 | ||
|
|
2349401a86 | ||
|
|
6274d5a3e4 | ||
|
|
83b9815644 | ||
|
|
afb0fcbc6f | ||
|
|
1da4736d5d | ||
|
|
5722241ff8 | ||
|
|
37910a4c5c | ||
|
|
0c7551b0c1 | ||
|
|
653ac184e1 | ||
|
|
b20c493fa6 | ||
|
|
b91268b3cd | ||
|
|
831a261c04 | ||
|
|
c784cf950b | ||
|
|
64b4ea9551 | ||
|
|
3ef6154ebe | ||
|
|
a96ba5499e | ||
|
|
599aa1dcca | ||
|
|
ae2ffd259c | ||
|
|
3d471bae56 | ||
|
|
d0f2293755 | ||
|
|
d6bd26da43 | ||
|
|
16d6c9e5e3 | ||
|
|
26d3cef528 | ||
|
|
fb7691be3b | ||
|
|
501cba216b | ||
|
|
f3fd2fd191 | ||
|
|
a970969c4d | ||
|
|
f0e4c9184d | ||
|
|
decad9ff9d | ||
|
|
dc43b5977f | ||
|
|
e1fbaf14eb | ||
|
|
d721425cfe | ||
|
|
02dd275be4 | ||
|
|
3391563829 | ||
|
|
5709265f6c | ||
|
|
89d5a28c28 | ||
|
|
f613a06d19 | ||
|
|
30f4b846d2 | ||
|
|
a3742bc65e | ||
|
|
cd1b2b6c05 | ||
|
|
c13aed651a | ||
|
|
dbccb16784 | ||
|
|
c0be333c0f | ||
|
|
d96c7eb3e9 | ||
|
|
4fca374fe9 | ||
|
|
9b82dd0411 | ||
|
|
0904881de8 | ||
|
|
d38399dcc0 | ||
|
|
68b0fe8c70 | ||
|
|
7c2a1ade1f | ||
|
|
5c2828bc78 | ||
|
|
111b2abeeb | ||
|
|
9503507011 | ||
|
|
a6d1f46133 | ||
|
|
145b884628 | ||
|
|
0e22b06f0a | ||
|
|
9e79d883a0 | ||
|
|
02e8a7b429 | ||
|
|
ca861119f9 | ||
|
|
0bfbae4cdd | ||
|
|
61de3b9e08 | ||
|
|
7b1e163c77 | ||
|
|
3f710ddc70 | ||
|
|
1546add5d5 | ||
|
|
734c44c1da | ||
|
|
68524067cf | ||
|
|
cc6319a2c7 | ||
|
|
4aaaa460b2 | ||
|
|
dee3d375db | ||
|
|
462634d311 | ||
|
|
e769cf4e48 | ||
|
|
fbaffa980a | ||
|
|
26f61c1855 | ||
|
|
dae62d863a | ||
|
|
681fa198c9 | ||
|
|
e7b8e6c90d | ||
|
|
d7cc3895cb | ||
|
|
a0b21a0bd4 | ||
|
|
65e99ff0de | ||
|
|
ecd6880fe0 | ||
|
|
e20adbba61 | ||
|
|
30d58e6371 | ||
|
|
6ed2000478 | ||
|
|
25403ea35e | ||
|
|
815c75fa9a | ||
|
|
8b3b07a710 | ||
|
|
33f88fa5e0 |
@@ -1582,6 +1582,17 @@ return [
|
||||
'required' => true,
|
||||
'array' => false,
|
||||
],
|
||||
[
|
||||
'$id' => ID::custom('transformations'),
|
||||
'type' => Database::VAR_BOOLEAN,
|
||||
'signed' => true,
|
||||
'size' => 0,
|
||||
'format' => '',
|
||||
'filters' => [],
|
||||
'required' => false,
|
||||
'array' => false,
|
||||
'default' => true,
|
||||
],
|
||||
[
|
||||
'$id' => ID::custom('search'),
|
||||
'type' => Database::VAR_STRING,
|
||||
|
||||
@@ -522,6 +522,11 @@ return [
|
||||
'description' => 'The requested file is not publicly readable.',
|
||||
'code' => 403,
|
||||
],
|
||||
Exception::STORAGE_BUCKET_TRANSFORMATIONS_DISABLED => [
|
||||
'name' => Exception::STORAGE_BUCKET_TRANSFORMATIONS_DISABLED,
|
||||
'description' => 'Image transformations are disabled for the requested bucket.',
|
||||
'code' => 403,
|
||||
],
|
||||
|
||||
/** Tokens */
|
||||
Exception::TOKEN_NOT_FOUND => [
|
||||
|
||||
@@ -215,7 +215,7 @@ return [
|
||||
'key' => 'ssr',
|
||||
'buildCommand' => 'npm run build',
|
||||
'installCommand' => 'npm install',
|
||||
'outputDirectory' => './dist',
|
||||
'outputDirectory' => './.output',
|
||||
'startCommand' => 'bash helpers/tanstack-start/server.sh',
|
||||
],
|
||||
'static' => [
|
||||
|
||||
@@ -60,7 +60,7 @@ return [
|
||||
[
|
||||
'key' => 'flutter',
|
||||
'name' => 'Flutter',
|
||||
'version' => '20.3.1',
|
||||
'version' => '20.3.2',
|
||||
'url' => 'https://github.com/appwrite/sdk-for-flutter',
|
||||
'package' => 'https://pub.dev/packages/appwrite',
|
||||
'enabled' => true,
|
||||
@@ -226,7 +226,7 @@ return [
|
||||
[
|
||||
'key' => 'cli',
|
||||
'name' => 'Command Line',
|
||||
'version' => '11.1.1',
|
||||
'version' => '12.0.0',
|
||||
'url' => 'https://github.com/appwrite/sdk-for-cli',
|
||||
'package' => 'https://www.npmjs.com/package/appwrite-cli',
|
||||
'enabled' => true,
|
||||
|
||||
@@ -47,10 +47,10 @@ return [ // List of publicly visible scopes
|
||||
'description' => 'Access to create, update, and delete your project\'s database table\'s columns',
|
||||
],
|
||||
'indexes.read' => [
|
||||
'description' => 'Access to read your project\'s database collection\'s indexes',
|
||||
'description' => 'Access to read your project\'s database table\'s indexes',
|
||||
],
|
||||
'indexes.write' => [
|
||||
'description' => 'Access to create, update, and delete your project\'s database collection\'s indexes',
|
||||
'description' => 'Access to create, update, and delete your project\'s database table\'s indexes',
|
||||
],
|
||||
'documents.read' => [
|
||||
'description' => 'Access to read your project\'s database documents',
|
||||
|
||||
@@ -7753,7 +7753,8 @@
|
||||
"default": {
|
||||
"type": "string",
|
||||
"description": "Default value for the attribute in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Cannot be set when attribute is required.",
|
||||
"x-example": null
|
||||
"x-example": null,
|
||||
"x-nullable": true
|
||||
},
|
||||
"array": {
|
||||
"type": "boolean",
|
||||
@@ -14414,10 +14415,22 @@
|
||||
"description": "Path to function code in the template repo.",
|
||||
"x-example": "<ROOT_DIRECTORY>"
|
||||
},
|
||||
"version": {
|
||||
"type": {
|
||||
"type": "string",
|
||||
"description": "Version (tag) for the repo linked to the function template.",
|
||||
"x-example": "<VERSION>"
|
||||
"description": "Type for the reference provided. Can be commit, branch, or tag",
|
||||
"x-example": "commit",
|
||||
"enum": [
|
||||
"commit",
|
||||
"branch",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": "TemplateReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
"type": "string",
|
||||
"description": "Reference value, can be a commit hash, branch name, or release tag",
|
||||
"x-example": "<REFERENCE>"
|
||||
},
|
||||
"activate": {
|
||||
"type": "boolean",
|
||||
@@ -14429,7 +14442,8 @@
|
||||
"repository",
|
||||
"owner",
|
||||
"rootDirectory",
|
||||
"version"
|
||||
"type",
|
||||
"reference"
|
||||
]
|
||||
}
|
||||
}
|
||||
@@ -14510,7 +14524,7 @@
|
||||
"branch",
|
||||
"commit"
|
||||
],
|
||||
"x-enum-name": "VCSDeploymentType",
|
||||
"x-enum-name": "VCSReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -32314,10 +32328,22 @@
|
||||
"description": "Path to site code in the template repo.",
|
||||
"x-example": "<ROOT_DIRECTORY>"
|
||||
},
|
||||
"version": {
|
||||
"type": {
|
||||
"type": "string",
|
||||
"description": "Version (tag) for the repo linked to the site template.",
|
||||
"x-example": "<VERSION>"
|
||||
"description": "Type for the reference provided. Can be commit, branch, or tag",
|
||||
"x-example": "branch",
|
||||
"enum": [
|
||||
"branch",
|
||||
"commit",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": "TemplateReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
"type": "string",
|
||||
"description": "Reference value, can be a commit hash, branch name, or release tag",
|
||||
"x-example": "<REFERENCE>"
|
||||
},
|
||||
"activate": {
|
||||
"type": "boolean",
|
||||
@@ -32329,7 +32355,8 @@
|
||||
"repository",
|
||||
"owner",
|
||||
"rootDirectory",
|
||||
"version"
|
||||
"type",
|
||||
"reference"
|
||||
]
|
||||
}
|
||||
}
|
||||
@@ -32411,7 +32438,7 @@
|
||||
"commit",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": "VCSDeploymentType",
|
||||
"x-enum-name": "VCSReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -33455,7 +33482,7 @@
|
||||
"parameters": [
|
||||
{
|
||||
"name": "queries",
|
||||
"description": "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: enabled, name, fileSecurity, maximumFileSize, encryption, antivirus",
|
||||
"description": "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: enabled, name, fileSecurity, maximumFileSize, encryption, antivirus, transformations",
|
||||
"required": false,
|
||||
"schema": {
|
||||
"type": "array",
|
||||
@@ -33605,6 +33632,11 @@
|
||||
"type": "boolean",
|
||||
"description": "Is virus scanning enabled? For file size above 20MB AntiVirus scanning is skipped even if it's enabled",
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Are image transformations enabled?",
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -33799,6 +33831,11 @@
|
||||
"type": "boolean",
|
||||
"description": "Is virus scanning enabled? For file size above 20MB AntiVirus scanning is skipped even if it's enabled",
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Are image transformations enabled?",
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -36096,7 +36133,7 @@
|
||||
},
|
||||
"rowSecurity": {
|
||||
"type": "boolean",
|
||||
"description": "Enables configuring permissions for individual rows. A user needs one of row or table level permissions to access a document. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).",
|
||||
"description": "Enables configuring permissions for individual rows. A user needs one of row or table-level permissions to access a row. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).",
|
||||
"x-example": false
|
||||
},
|
||||
"enabled": {
|
||||
@@ -36593,7 +36630,8 @@
|
||||
"default": {
|
||||
"type": "string",
|
||||
"description": "Default value for the column in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Cannot be set when column is required.",
|
||||
"x-example": null
|
||||
"x-example": null,
|
||||
"x-nullable": true
|
||||
},
|
||||
"array": {
|
||||
"type": "boolean",
|
||||
@@ -53579,6 +53617,11 @@
|
||||
"type": "boolean",
|
||||
"description": "Virus scanning is enabled.",
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Image transformations are enabled.",
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -53593,7 +53636,8 @@
|
||||
"allowedFileExtensions",
|
||||
"compression",
|
||||
"encryption",
|
||||
"antivirus"
|
||||
"antivirus",
|
||||
"transformations"
|
||||
],
|
||||
"example": {
|
||||
"$id": "5e5ea5c16897e",
|
||||
@@ -53612,7 +53656,8 @@
|
||||
],
|
||||
"compression": "gzip",
|
||||
"encryption": false,
|
||||
"antivirus": false
|
||||
"antivirus": false,
|
||||
"transformations": false
|
||||
}
|
||||
},
|
||||
"resourceToken": {
|
||||
@@ -54798,6 +54843,17 @@
|
||||
"type": "string",
|
||||
"description": "Last commit date in ISO 8601 format.",
|
||||
"x-example": "datetime"
|
||||
},
|
||||
"variables": {
|
||||
"type": "array",
|
||||
"description": "Environment variables found in .env files",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"x-example": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -54807,7 +54863,8 @@
|
||||
"provider",
|
||||
"private",
|
||||
"defaultBranch",
|
||||
"pushedAt"
|
||||
"pushedAt",
|
||||
"variables"
|
||||
],
|
||||
"example": {
|
||||
"id": "5e5ea5c16897e",
|
||||
@@ -54816,7 +54873,11 @@
|
||||
"provider": "github",
|
||||
"private": true,
|
||||
"defaultBranch": "main",
|
||||
"pushedAt": "datetime"
|
||||
"pushedAt": "datetime",
|
||||
"variables": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
]
|
||||
}
|
||||
},
|
||||
"providerRepositoryFramework": {
|
||||
@@ -54858,6 +54919,17 @@
|
||||
"description": "Last commit date in ISO 8601 format.",
|
||||
"x-example": "datetime"
|
||||
},
|
||||
"variables": {
|
||||
"type": "array",
|
||||
"description": "Environment variables found in .env files",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"x-example": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
]
|
||||
},
|
||||
"framework": {
|
||||
"type": "string",
|
||||
"description": "Auto-detected framework. Empty if type is not \"framework\".",
|
||||
@@ -54872,6 +54944,7 @@
|
||||
"private",
|
||||
"defaultBranch",
|
||||
"pushedAt",
|
||||
"variables",
|
||||
"framework"
|
||||
],
|
||||
"example": {
|
||||
@@ -54882,6 +54955,10 @@
|
||||
"private": true,
|
||||
"defaultBranch": "main",
|
||||
"pushedAt": "datetime",
|
||||
"variables": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
],
|
||||
"framework": "nextjs"
|
||||
}
|
||||
},
|
||||
@@ -54924,6 +55001,17 @@
|
||||
"description": "Last commit date in ISO 8601 format.",
|
||||
"x-example": "datetime"
|
||||
},
|
||||
"variables": {
|
||||
"type": "array",
|
||||
"description": "Environment variables found in .env files",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"x-example": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
]
|
||||
},
|
||||
"runtime": {
|
||||
"type": "string",
|
||||
"description": "Auto-detected runtime. Empty if type is not \"runtime\".",
|
||||
@@ -54938,6 +55026,7 @@
|
||||
"private",
|
||||
"defaultBranch",
|
||||
"pushedAt",
|
||||
"variables",
|
||||
"runtime"
|
||||
],
|
||||
"example": {
|
||||
@@ -54948,6 +55037,10 @@
|
||||
"private": true,
|
||||
"defaultBranch": "main",
|
||||
"pushedAt": "datetime",
|
||||
"variables": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
],
|
||||
"runtime": "node-22"
|
||||
}
|
||||
},
|
||||
@@ -54955,6 +55048,15 @@
|
||||
"description": "DetectionFramework",
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"variables": {
|
||||
"type": "array",
|
||||
"description": "Environment variables found in .env files",
|
||||
"items": {
|
||||
"$ref": "#\/components\/schemas\/detectionVariable"
|
||||
},
|
||||
"x-example": {},
|
||||
"nullable": true
|
||||
},
|
||||
"framework": {
|
||||
"type": "string",
|
||||
"description": "Framework",
|
||||
@@ -54983,6 +55085,7 @@
|
||||
"outputDirectory"
|
||||
],
|
||||
"example": {
|
||||
"variables": {},
|
||||
"framework": "nuxt",
|
||||
"installCommand": "npm install",
|
||||
"buildCommand": "npm run build",
|
||||
@@ -54993,6 +55096,15 @@
|
||||
"description": "DetectionRuntime",
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"variables": {
|
||||
"type": "array",
|
||||
"description": "Environment variables found in .env files",
|
||||
"items": {
|
||||
"$ref": "#\/components\/schemas\/detectionVariable"
|
||||
},
|
||||
"x-example": {},
|
||||
"nullable": true
|
||||
},
|
||||
"runtime": {
|
||||
"type": "string",
|
||||
"description": "Runtime",
|
||||
@@ -55015,11 +55127,36 @@
|
||||
"commands"
|
||||
],
|
||||
"example": {
|
||||
"variables": {},
|
||||
"runtime": "node",
|
||||
"entrypoint": "index.js",
|
||||
"commands": "npm install && npm run build"
|
||||
}
|
||||
},
|
||||
"detectionVariable": {
|
||||
"description": "DetectionVariable",
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"name": {
|
||||
"type": "string",
|
||||
"description": "Name of environment variable",
|
||||
"x-example": "NODE_ENV"
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"description": "Value of environment variable",
|
||||
"x-example": "production"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"name",
|
||||
"value"
|
||||
],
|
||||
"example": {
|
||||
"name": "NODE_ENV",
|
||||
"value": "production"
|
||||
}
|
||||
},
|
||||
"vcsContent": {
|
||||
"description": "VcsContents",
|
||||
"type": "object",
|
||||
|
||||
@@ -7222,7 +7222,8 @@
|
||||
"default": {
|
||||
"type": "string",
|
||||
"description": "Default value for the attribute in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Cannot be set when attribute is required.",
|
||||
"x-example": null
|
||||
"x-example": null,
|
||||
"x-nullable": true
|
||||
},
|
||||
"array": {
|
||||
"type": "boolean",
|
||||
@@ -13203,10 +13204,22 @@
|
||||
"description": "Path to function code in the template repo.",
|
||||
"x-example": "<ROOT_DIRECTORY>"
|
||||
},
|
||||
"version": {
|
||||
"type": {
|
||||
"type": "string",
|
||||
"description": "Version (tag) for the repo linked to the function template.",
|
||||
"x-example": "<VERSION>"
|
||||
"description": "Type for the reference provided. Can be commit, branch, or tag",
|
||||
"x-example": "commit",
|
||||
"enum": [
|
||||
"commit",
|
||||
"branch",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": "TemplateReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
"type": "string",
|
||||
"description": "Reference value, can be a commit hash, branch name, or release tag",
|
||||
"x-example": "<REFERENCE>"
|
||||
},
|
||||
"activate": {
|
||||
"type": "boolean",
|
||||
@@ -13218,7 +13231,8 @@
|
||||
"repository",
|
||||
"owner",
|
||||
"rootDirectory",
|
||||
"version"
|
||||
"type",
|
||||
"reference"
|
||||
]
|
||||
}
|
||||
}
|
||||
@@ -13300,7 +13314,7 @@
|
||||
"branch",
|
||||
"commit"
|
||||
],
|
||||
"x-enum-name": "VCSDeploymentType",
|
||||
"x-enum-name": "VCSReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -22838,10 +22852,22 @@
|
||||
"description": "Path to site code in the template repo.",
|
||||
"x-example": "<ROOT_DIRECTORY>"
|
||||
},
|
||||
"version": {
|
||||
"type": {
|
||||
"type": "string",
|
||||
"description": "Version (tag) for the repo linked to the site template.",
|
||||
"x-example": "<VERSION>"
|
||||
"description": "Type for the reference provided. Can be commit, branch, or tag",
|
||||
"x-example": "branch",
|
||||
"enum": [
|
||||
"branch",
|
||||
"commit",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": "TemplateReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
"type": "string",
|
||||
"description": "Reference value, can be a commit hash, branch name, or release tag",
|
||||
"x-example": "<REFERENCE>"
|
||||
},
|
||||
"activate": {
|
||||
"type": "boolean",
|
||||
@@ -22853,7 +22879,8 @@
|
||||
"repository",
|
||||
"owner",
|
||||
"rootDirectory",
|
||||
"version"
|
||||
"type",
|
||||
"reference"
|
||||
]
|
||||
}
|
||||
}
|
||||
@@ -22936,7 +22963,7 @@
|
||||
"commit",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": "VCSDeploymentType",
|
||||
"x-enum-name": "VCSReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -23911,7 +23938,7 @@
|
||||
"parameters": [
|
||||
{
|
||||
"name": "queries",
|
||||
"description": "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: enabled, name, fileSecurity, maximumFileSize, encryption, antivirus",
|
||||
"description": "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: enabled, name, fileSecurity, maximumFileSize, encryption, antivirus, transformations",
|
||||
"required": false,
|
||||
"schema": {
|
||||
"type": "array",
|
||||
@@ -24062,6 +24089,11 @@
|
||||
"type": "boolean",
|
||||
"description": "Is virus scanning enabled? For file size above 20MB AntiVirus scanning is skipped even if it's enabled",
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Are image transformations enabled?",
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -24258,6 +24290,11 @@
|
||||
"type": "boolean",
|
||||
"description": "Is virus scanning enabled? For file size above 20MB AntiVirus scanning is skipped even if it's enabled",
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Are image transformations enabled?",
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -26342,7 +26379,7 @@
|
||||
},
|
||||
"rowSecurity": {
|
||||
"type": "boolean",
|
||||
"description": "Enables configuring permissions for individual rows. A user needs one of row or table level permissions to access a document. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).",
|
||||
"description": "Enables configuring permissions for individual rows. A user needs one of row or table-level permissions to access a row. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).",
|
||||
"x-example": false
|
||||
},
|
||||
"enabled": {
|
||||
@@ -26844,7 +26881,8 @@
|
||||
"default": {
|
||||
"type": "string",
|
||||
"description": "Default value for the column in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Cannot be set when column is required.",
|
||||
"x-example": null
|
||||
"x-example": null,
|
||||
"x-nullable": true
|
||||
},
|
||||
"array": {
|
||||
"type": "boolean",
|
||||
@@ -42256,6 +42294,11 @@
|
||||
"type": "boolean",
|
||||
"description": "Virus scanning is enabled.",
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Image transformations are enabled.",
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -42270,7 +42313,8 @@
|
||||
"allowedFileExtensions",
|
||||
"compression",
|
||||
"encryption",
|
||||
"antivirus"
|
||||
"antivirus",
|
||||
"transformations"
|
||||
],
|
||||
"example": {
|
||||
"$id": "5e5ea5c16897e",
|
||||
@@ -42289,7 +42333,8 @@
|
||||
],
|
||||
"compression": "gzip",
|
||||
"encryption": false,
|
||||
"antivirus": false
|
||||
"antivirus": false,
|
||||
"transformations": false
|
||||
}
|
||||
},
|
||||
"resourceToken": {
|
||||
|
||||
@@ -7753,7 +7753,8 @@
|
||||
"default": {
|
||||
"type": "string",
|
||||
"description": "Default value for the attribute in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Cannot be set when attribute is required.",
|
||||
"x-example": null
|
||||
"x-example": null,
|
||||
"x-nullable": true
|
||||
},
|
||||
"array": {
|
||||
"type": "boolean",
|
||||
@@ -14423,7 +14424,7 @@
|
||||
"branch",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": null,
|
||||
"x-enum-name": "TemplateReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -14523,7 +14524,7 @@
|
||||
"branch",
|
||||
"commit"
|
||||
],
|
||||
"x-enum-name": "VCSDeploymentType",
|
||||
"x-enum-name": "VCSReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -32336,7 +32337,7 @@
|
||||
"commit",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": null,
|
||||
"x-enum-name": "TemplateReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -32437,7 +32438,7 @@
|
||||
"commit",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": "VCSDeploymentType",
|
||||
"x-enum-name": "VCSReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -33481,7 +33482,7 @@
|
||||
"parameters": [
|
||||
{
|
||||
"name": "queries",
|
||||
"description": "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: enabled, name, fileSecurity, maximumFileSize, encryption, antivirus",
|
||||
"description": "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: enabled, name, fileSecurity, maximumFileSize, encryption, antivirus, transformations",
|
||||
"required": false,
|
||||
"schema": {
|
||||
"type": "array",
|
||||
@@ -33631,6 +33632,11 @@
|
||||
"type": "boolean",
|
||||
"description": "Is virus scanning enabled? For file size above 20MB AntiVirus scanning is skipped even if it's enabled",
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Are image transformations enabled?",
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -33825,6 +33831,11 @@
|
||||
"type": "boolean",
|
||||
"description": "Is virus scanning enabled? For file size above 20MB AntiVirus scanning is skipped even if it's enabled",
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Are image transformations enabled?",
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -36122,7 +36133,7 @@
|
||||
},
|
||||
"rowSecurity": {
|
||||
"type": "boolean",
|
||||
"description": "Enables configuring permissions for individual rows. A user needs one of row or table level permissions to access a document. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).",
|
||||
"description": "Enables configuring permissions for individual rows. A user needs one of row or table-level permissions to access a row. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).",
|
||||
"x-example": false
|
||||
},
|
||||
"enabled": {
|
||||
@@ -36619,7 +36630,8 @@
|
||||
"default": {
|
||||
"type": "string",
|
||||
"description": "Default value for the column in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Cannot be set when column is required.",
|
||||
"x-example": null
|
||||
"x-example": null,
|
||||
"x-nullable": true
|
||||
},
|
||||
"array": {
|
||||
"type": "boolean",
|
||||
@@ -53605,6 +53617,11 @@
|
||||
"type": "boolean",
|
||||
"description": "Virus scanning is enabled.",
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Image transformations are enabled.",
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -53619,7 +53636,8 @@
|
||||
"allowedFileExtensions",
|
||||
"compression",
|
||||
"encryption",
|
||||
"antivirus"
|
||||
"antivirus",
|
||||
"transformations"
|
||||
],
|
||||
"example": {
|
||||
"$id": "5e5ea5c16897e",
|
||||
@@ -53638,7 +53656,8 @@
|
||||
],
|
||||
"compression": "gzip",
|
||||
"encryption": false,
|
||||
"antivirus": false
|
||||
"antivirus": false,
|
||||
"transformations": false
|
||||
}
|
||||
},
|
||||
"resourceToken": {
|
||||
@@ -54824,6 +54843,17 @@
|
||||
"type": "string",
|
||||
"description": "Last commit date in ISO 8601 format.",
|
||||
"x-example": "datetime"
|
||||
},
|
||||
"variables": {
|
||||
"type": "array",
|
||||
"description": "Environment variables found in .env files",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"x-example": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -54833,7 +54863,8 @@
|
||||
"provider",
|
||||
"private",
|
||||
"defaultBranch",
|
||||
"pushedAt"
|
||||
"pushedAt",
|
||||
"variables"
|
||||
],
|
||||
"example": {
|
||||
"id": "5e5ea5c16897e",
|
||||
@@ -54842,7 +54873,11 @@
|
||||
"provider": "github",
|
||||
"private": true,
|
||||
"defaultBranch": "main",
|
||||
"pushedAt": "datetime"
|
||||
"pushedAt": "datetime",
|
||||
"variables": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
]
|
||||
}
|
||||
},
|
||||
"providerRepositoryFramework": {
|
||||
@@ -54884,6 +54919,17 @@
|
||||
"description": "Last commit date in ISO 8601 format.",
|
||||
"x-example": "datetime"
|
||||
},
|
||||
"variables": {
|
||||
"type": "array",
|
||||
"description": "Environment variables found in .env files",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"x-example": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
]
|
||||
},
|
||||
"framework": {
|
||||
"type": "string",
|
||||
"description": "Auto-detected framework. Empty if type is not \"framework\".",
|
||||
@@ -54898,6 +54944,7 @@
|
||||
"private",
|
||||
"defaultBranch",
|
||||
"pushedAt",
|
||||
"variables",
|
||||
"framework"
|
||||
],
|
||||
"example": {
|
||||
@@ -54908,6 +54955,10 @@
|
||||
"private": true,
|
||||
"defaultBranch": "main",
|
||||
"pushedAt": "datetime",
|
||||
"variables": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
],
|
||||
"framework": "nextjs"
|
||||
}
|
||||
},
|
||||
@@ -54950,6 +55001,17 @@
|
||||
"description": "Last commit date in ISO 8601 format.",
|
||||
"x-example": "datetime"
|
||||
},
|
||||
"variables": {
|
||||
"type": "array",
|
||||
"description": "Environment variables found in .env files",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"x-example": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
]
|
||||
},
|
||||
"runtime": {
|
||||
"type": "string",
|
||||
"description": "Auto-detected runtime. Empty if type is not \"runtime\".",
|
||||
@@ -54964,6 +55026,7 @@
|
||||
"private",
|
||||
"defaultBranch",
|
||||
"pushedAt",
|
||||
"variables",
|
||||
"runtime"
|
||||
],
|
||||
"example": {
|
||||
@@ -54974,6 +55037,10 @@
|
||||
"private": true,
|
||||
"defaultBranch": "main",
|
||||
"pushedAt": "datetime",
|
||||
"variables": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
],
|
||||
"runtime": "node-22"
|
||||
}
|
||||
},
|
||||
@@ -54981,6 +55048,15 @@
|
||||
"description": "DetectionFramework",
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"variables": {
|
||||
"type": "array",
|
||||
"description": "Environment variables found in .env files",
|
||||
"items": {
|
||||
"$ref": "#\/components\/schemas\/detectionVariable"
|
||||
},
|
||||
"x-example": {},
|
||||
"nullable": true
|
||||
},
|
||||
"framework": {
|
||||
"type": "string",
|
||||
"description": "Framework",
|
||||
@@ -55009,6 +55085,7 @@
|
||||
"outputDirectory"
|
||||
],
|
||||
"example": {
|
||||
"variables": {},
|
||||
"framework": "nuxt",
|
||||
"installCommand": "npm install",
|
||||
"buildCommand": "npm run build",
|
||||
@@ -55019,6 +55096,15 @@
|
||||
"description": "DetectionRuntime",
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"variables": {
|
||||
"type": "array",
|
||||
"description": "Environment variables found in .env files",
|
||||
"items": {
|
||||
"$ref": "#\/components\/schemas\/detectionVariable"
|
||||
},
|
||||
"x-example": {},
|
||||
"nullable": true
|
||||
},
|
||||
"runtime": {
|
||||
"type": "string",
|
||||
"description": "Runtime",
|
||||
@@ -55041,11 +55127,36 @@
|
||||
"commands"
|
||||
],
|
||||
"example": {
|
||||
"variables": {},
|
||||
"runtime": "node",
|
||||
"entrypoint": "index.js",
|
||||
"commands": "npm install && npm run build"
|
||||
}
|
||||
},
|
||||
"detectionVariable": {
|
||||
"description": "DetectionVariable",
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"name": {
|
||||
"type": "string",
|
||||
"description": "Name of environment variable",
|
||||
"x-example": "NODE_ENV"
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"description": "Value of environment variable",
|
||||
"x-example": "production"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"name",
|
||||
"value"
|
||||
],
|
||||
"example": {
|
||||
"name": "NODE_ENV",
|
||||
"value": "production"
|
||||
}
|
||||
},
|
||||
"vcsContent": {
|
||||
"description": "VcsContents",
|
||||
"type": "object",
|
||||
|
||||
@@ -7222,7 +7222,8 @@
|
||||
"default": {
|
||||
"type": "string",
|
||||
"description": "Default value for the attribute in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Cannot be set when attribute is required.",
|
||||
"x-example": null
|
||||
"x-example": null,
|
||||
"x-nullable": true
|
||||
},
|
||||
"array": {
|
||||
"type": "boolean",
|
||||
@@ -13212,7 +13213,7 @@
|
||||
"branch",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": null,
|
||||
"x-enum-name": "TemplateReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -13313,7 +13314,7 @@
|
||||
"branch",
|
||||
"commit"
|
||||
],
|
||||
"x-enum-name": "VCSDeploymentType",
|
||||
"x-enum-name": "VCSReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -22860,7 +22861,7 @@
|
||||
"commit",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": null,
|
||||
"x-enum-name": "TemplateReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -22962,7 +22963,7 @@
|
||||
"commit",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": "VCSDeploymentType",
|
||||
"x-enum-name": "VCSReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -23937,7 +23938,7 @@
|
||||
"parameters": [
|
||||
{
|
||||
"name": "queries",
|
||||
"description": "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: enabled, name, fileSecurity, maximumFileSize, encryption, antivirus",
|
||||
"description": "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: enabled, name, fileSecurity, maximumFileSize, encryption, antivirus, transformations",
|
||||
"required": false,
|
||||
"schema": {
|
||||
"type": "array",
|
||||
@@ -24088,6 +24089,11 @@
|
||||
"type": "boolean",
|
||||
"description": "Is virus scanning enabled? For file size above 20MB AntiVirus scanning is skipped even if it's enabled",
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Are image transformations enabled?",
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -24284,6 +24290,11 @@
|
||||
"type": "boolean",
|
||||
"description": "Is virus scanning enabled? For file size above 20MB AntiVirus scanning is skipped even if it's enabled",
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Are image transformations enabled?",
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -26368,7 +26379,7 @@
|
||||
},
|
||||
"rowSecurity": {
|
||||
"type": "boolean",
|
||||
"description": "Enables configuring permissions for individual rows. A user needs one of row or table level permissions to access a document. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).",
|
||||
"description": "Enables configuring permissions for individual rows. A user needs one of row or table-level permissions to access a row. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).",
|
||||
"x-example": false
|
||||
},
|
||||
"enabled": {
|
||||
@@ -26870,7 +26881,8 @@
|
||||
"default": {
|
||||
"type": "string",
|
||||
"description": "Default value for the column in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Cannot be set when column is required.",
|
||||
"x-example": null
|
||||
"x-example": null,
|
||||
"x-nullable": true
|
||||
},
|
||||
"array": {
|
||||
"type": "boolean",
|
||||
@@ -42282,6 +42294,11 @@
|
||||
"type": "boolean",
|
||||
"description": "Virus scanning is enabled.",
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Image transformations are enabled.",
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -42296,7 +42313,8 @@
|
||||
"allowedFileExtensions",
|
||||
"compression",
|
||||
"encryption",
|
||||
"antivirus"
|
||||
"antivirus",
|
||||
"transformations"
|
||||
],
|
||||
"example": {
|
||||
"$id": "5e5ea5c16897e",
|
||||
@@ -42315,7 +42333,8 @@
|
||||
],
|
||||
"compression": "gzip",
|
||||
"encryption": false,
|
||||
"antivirus": false
|
||||
"antivirus": false,
|
||||
"transformations": false
|
||||
}
|
||||
},
|
||||
"resourceToken": {
|
||||
|
||||
@@ -7851,7 +7851,8 @@
|
||||
"type": "string",
|
||||
"description": "Default value for the attribute in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Cannot be set when attribute is required.",
|
||||
"default": null,
|
||||
"x-example": null
|
||||
"x-example": null,
|
||||
"x-nullable": true
|
||||
},
|
||||
"array": {
|
||||
"type": "boolean",
|
||||
@@ -14355,11 +14356,24 @@
|
||||
"default": null,
|
||||
"x-example": "<ROOT_DIRECTORY>"
|
||||
},
|
||||
"version": {
|
||||
"type": {
|
||||
"type": "string",
|
||||
"description": "Version (tag) for the repo linked to the function template.",
|
||||
"description": "Type for the reference provided. Can be commit, branch, or tag",
|
||||
"default": null,
|
||||
"x-example": "<VERSION>"
|
||||
"x-example": "commit",
|
||||
"enum": [
|
||||
"commit",
|
||||
"branch",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": "TemplateReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
"type": "string",
|
||||
"description": "Reference value, can be a commit hash, branch name, or release tag",
|
||||
"default": null,
|
||||
"x-example": "<REFERENCE>"
|
||||
},
|
||||
"activate": {
|
||||
"type": "boolean",
|
||||
@@ -14372,7 +14386,8 @@
|
||||
"repository",
|
||||
"owner",
|
||||
"rootDirectory",
|
||||
"version"
|
||||
"type",
|
||||
"reference"
|
||||
]
|
||||
}
|
||||
}
|
||||
@@ -14452,7 +14467,7 @@
|
||||
"branch",
|
||||
"commit"
|
||||
],
|
||||
"x-enum-name": "VCSDeploymentType",
|
||||
"x-enum-name": "VCSReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -32416,11 +32431,24 @@
|
||||
"default": null,
|
||||
"x-example": "<ROOT_DIRECTORY>"
|
||||
},
|
||||
"version": {
|
||||
"type": {
|
||||
"type": "string",
|
||||
"description": "Version (tag) for the repo linked to the site template.",
|
||||
"description": "Type for the reference provided. Can be commit, branch, or tag",
|
||||
"default": null,
|
||||
"x-example": "<VERSION>"
|
||||
"x-example": "branch",
|
||||
"enum": [
|
||||
"branch",
|
||||
"commit",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": "TemplateReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
"type": "string",
|
||||
"description": "Reference value, can be a commit hash, branch name, or release tag",
|
||||
"default": null,
|
||||
"x-example": "<REFERENCE>"
|
||||
},
|
||||
"activate": {
|
||||
"type": "boolean",
|
||||
@@ -32433,7 +32461,8 @@
|
||||
"repository",
|
||||
"owner",
|
||||
"rootDirectory",
|
||||
"version"
|
||||
"type",
|
||||
"reference"
|
||||
]
|
||||
}
|
||||
}
|
||||
@@ -32514,7 +32543,7 @@
|
||||
"commit",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": "VCSDeploymentType",
|
||||
"x-enum-name": "VCSReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -33536,7 +33565,7 @@
|
||||
"parameters": [
|
||||
{
|
||||
"name": "queries",
|
||||
"description": "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: enabled, name, fileSecurity, maximumFileSize, encryption, antivirus",
|
||||
"description": "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: enabled, name, fileSecurity, maximumFileSize, encryption, antivirus, transformations",
|
||||
"required": false,
|
||||
"type": "array",
|
||||
"collectionFormat": "multi",
|
||||
@@ -33694,6 +33723,12 @@
|
||||
"description": "Is virus scanning enabled? For file size above 20MB AntiVirus scanning is skipped even if it's enabled",
|
||||
"default": true,
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Are image transformations enabled?",
|
||||
"default": true,
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -33893,6 +33928,12 @@
|
||||
"description": "Is virus scanning enabled? For file size above 20MB AntiVirus scanning is skipped even if it's enabled",
|
||||
"default": true,
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Are image transformations enabled?",
|
||||
"default": true,
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -36122,7 +36163,7 @@
|
||||
},
|
||||
"rowSecurity": {
|
||||
"type": "boolean",
|
||||
"description": "Enables configuring permissions for individual rows. A user needs one of row or table level permissions to access a document. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).",
|
||||
"description": "Enables configuring permissions for individual rows. A user needs one of row or table-level permissions to access a row. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).",
|
||||
"default": false,
|
||||
"x-example": false
|
||||
},
|
||||
@@ -36610,7 +36651,8 @@
|
||||
"type": "string",
|
||||
"description": "Default value for the column in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Cannot be set when column is required.",
|
||||
"default": null,
|
||||
"x-example": null
|
||||
"x-example": null,
|
||||
"x-nullable": true
|
||||
},
|
||||
"array": {
|
||||
"type": "boolean",
|
||||
@@ -53397,6 +53439,11 @@
|
||||
"type": "boolean",
|
||||
"description": "Virus scanning is enabled.",
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Image transformations are enabled.",
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -53411,7 +53458,8 @@
|
||||
"allowedFileExtensions",
|
||||
"compression",
|
||||
"encryption",
|
||||
"antivirus"
|
||||
"antivirus",
|
||||
"transformations"
|
||||
],
|
||||
"example": {
|
||||
"$id": "5e5ea5c16897e",
|
||||
@@ -53430,7 +53478,8 @@
|
||||
],
|
||||
"compression": "gzip",
|
||||
"encryption": false,
|
||||
"antivirus": false
|
||||
"antivirus": false,
|
||||
"transformations": false
|
||||
}
|
||||
},
|
||||
"resourceToken": {
|
||||
@@ -54623,6 +54672,17 @@
|
||||
"type": "string",
|
||||
"description": "Last commit date in ISO 8601 format.",
|
||||
"x-example": "datetime"
|
||||
},
|
||||
"variables": {
|
||||
"type": "array",
|
||||
"description": "Environment variables found in .env files",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"x-example": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -54632,7 +54692,8 @@
|
||||
"provider",
|
||||
"private",
|
||||
"defaultBranch",
|
||||
"pushedAt"
|
||||
"pushedAt",
|
||||
"variables"
|
||||
],
|
||||
"example": {
|
||||
"id": "5e5ea5c16897e",
|
||||
@@ -54641,7 +54702,11 @@
|
||||
"provider": "github",
|
||||
"private": true,
|
||||
"defaultBranch": "main",
|
||||
"pushedAt": "datetime"
|
||||
"pushedAt": "datetime",
|
||||
"variables": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
]
|
||||
}
|
||||
},
|
||||
"providerRepositoryFramework": {
|
||||
@@ -54683,6 +54748,17 @@
|
||||
"description": "Last commit date in ISO 8601 format.",
|
||||
"x-example": "datetime"
|
||||
},
|
||||
"variables": {
|
||||
"type": "array",
|
||||
"description": "Environment variables found in .env files",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"x-example": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
]
|
||||
},
|
||||
"framework": {
|
||||
"type": "string",
|
||||
"description": "Auto-detected framework. Empty if type is not \"framework\".",
|
||||
@@ -54697,6 +54773,7 @@
|
||||
"private",
|
||||
"defaultBranch",
|
||||
"pushedAt",
|
||||
"variables",
|
||||
"framework"
|
||||
],
|
||||
"example": {
|
||||
@@ -54707,6 +54784,10 @@
|
||||
"private": true,
|
||||
"defaultBranch": "main",
|
||||
"pushedAt": "datetime",
|
||||
"variables": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
],
|
||||
"framework": "nextjs"
|
||||
}
|
||||
},
|
||||
@@ -54749,6 +54830,17 @@
|
||||
"description": "Last commit date in ISO 8601 format.",
|
||||
"x-example": "datetime"
|
||||
},
|
||||
"variables": {
|
||||
"type": "array",
|
||||
"description": "Environment variables found in .env files",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"x-example": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
]
|
||||
},
|
||||
"runtime": {
|
||||
"type": "string",
|
||||
"description": "Auto-detected runtime. Empty if type is not \"runtime\".",
|
||||
@@ -54763,6 +54855,7 @@
|
||||
"private",
|
||||
"defaultBranch",
|
||||
"pushedAt",
|
||||
"variables",
|
||||
"runtime"
|
||||
],
|
||||
"example": {
|
||||
@@ -54773,6 +54866,10 @@
|
||||
"private": true,
|
||||
"defaultBranch": "main",
|
||||
"pushedAt": "datetime",
|
||||
"variables": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
],
|
||||
"runtime": "node-22"
|
||||
}
|
||||
},
|
||||
@@ -54780,6 +54877,16 @@
|
||||
"description": "DetectionFramework",
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"variables": {
|
||||
"type": "array",
|
||||
"description": "Environment variables found in .env files",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"$ref": "#\/definitions\/detectionVariable"
|
||||
},
|
||||
"x-example": {},
|
||||
"x-nullable": true
|
||||
},
|
||||
"framework": {
|
||||
"type": "string",
|
||||
"description": "Framework",
|
||||
@@ -54808,6 +54915,7 @@
|
||||
"outputDirectory"
|
||||
],
|
||||
"example": {
|
||||
"variables": {},
|
||||
"framework": "nuxt",
|
||||
"installCommand": "npm install",
|
||||
"buildCommand": "npm run build",
|
||||
@@ -54818,6 +54926,16 @@
|
||||
"description": "DetectionRuntime",
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"variables": {
|
||||
"type": "array",
|
||||
"description": "Environment variables found in .env files",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"$ref": "#\/definitions\/detectionVariable"
|
||||
},
|
||||
"x-example": {},
|
||||
"x-nullable": true
|
||||
},
|
||||
"runtime": {
|
||||
"type": "string",
|
||||
"description": "Runtime",
|
||||
@@ -54840,11 +54958,36 @@
|
||||
"commands"
|
||||
],
|
||||
"example": {
|
||||
"variables": {},
|
||||
"runtime": "node",
|
||||
"entrypoint": "index.js",
|
||||
"commands": "npm install && npm run build"
|
||||
}
|
||||
},
|
||||
"detectionVariable": {
|
||||
"description": "DetectionVariable",
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"name": {
|
||||
"type": "string",
|
||||
"description": "Name of environment variable",
|
||||
"x-example": "NODE_ENV"
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"description": "Value of environment variable",
|
||||
"x-example": "production"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"name",
|
||||
"value"
|
||||
],
|
||||
"example": {
|
||||
"name": "NODE_ENV",
|
||||
"value": "production"
|
||||
}
|
||||
},
|
||||
"vcsContent": {
|
||||
"description": "VcsContents",
|
||||
"type": "object",
|
||||
|
||||
@@ -7310,7 +7310,8 @@
|
||||
"type": "string",
|
||||
"description": "Default value for the attribute in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Cannot be set when attribute is required.",
|
||||
"default": null,
|
||||
"x-example": null
|
||||
"x-example": null,
|
||||
"x-nullable": true
|
||||
},
|
||||
"array": {
|
||||
"type": "boolean",
|
||||
@@ -13171,11 +13172,24 @@
|
||||
"default": null,
|
||||
"x-example": "<ROOT_DIRECTORY>"
|
||||
},
|
||||
"version": {
|
||||
"type": {
|
||||
"type": "string",
|
||||
"description": "Version (tag) for the repo linked to the function template.",
|
||||
"description": "Type for the reference provided. Can be commit, branch, or tag",
|
||||
"default": null,
|
||||
"x-example": "<VERSION>"
|
||||
"x-example": "commit",
|
||||
"enum": [
|
||||
"commit",
|
||||
"branch",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": "TemplateReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
"type": "string",
|
||||
"description": "Reference value, can be a commit hash, branch name, or release tag",
|
||||
"default": null,
|
||||
"x-example": "<REFERENCE>"
|
||||
},
|
||||
"activate": {
|
||||
"type": "boolean",
|
||||
@@ -13188,7 +13202,8 @@
|
||||
"repository",
|
||||
"owner",
|
||||
"rootDirectory",
|
||||
"version"
|
||||
"type",
|
||||
"reference"
|
||||
]
|
||||
}
|
||||
}
|
||||
@@ -13269,7 +13284,7 @@
|
||||
"branch",
|
||||
"commit"
|
||||
],
|
||||
"x-enum-name": "VCSDeploymentType",
|
||||
"x-enum-name": "VCSReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -22989,11 +23004,24 @@
|
||||
"default": null,
|
||||
"x-example": "<ROOT_DIRECTORY>"
|
||||
},
|
||||
"version": {
|
||||
"type": {
|
||||
"type": "string",
|
||||
"description": "Version (tag) for the repo linked to the site template.",
|
||||
"description": "Type for the reference provided. Can be commit, branch, or tag",
|
||||
"default": null,
|
||||
"x-example": "<VERSION>"
|
||||
"x-example": "branch",
|
||||
"enum": [
|
||||
"branch",
|
||||
"commit",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": "TemplateReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
"type": "string",
|
||||
"description": "Reference value, can be a commit hash, branch name, or release tag",
|
||||
"default": null,
|
||||
"x-example": "<REFERENCE>"
|
||||
},
|
||||
"activate": {
|
||||
"type": "boolean",
|
||||
@@ -23006,7 +23034,8 @@
|
||||
"repository",
|
||||
"owner",
|
||||
"rootDirectory",
|
||||
"version"
|
||||
"type",
|
||||
"reference"
|
||||
]
|
||||
}
|
||||
}
|
||||
@@ -23088,7 +23117,7 @@
|
||||
"commit",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": "VCSDeploymentType",
|
||||
"x-enum-name": "VCSReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -24045,7 +24074,7 @@
|
||||
"parameters": [
|
||||
{
|
||||
"name": "queries",
|
||||
"description": "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: enabled, name, fileSecurity, maximumFileSize, encryption, antivirus",
|
||||
"description": "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: enabled, name, fileSecurity, maximumFileSize, encryption, antivirus, transformations",
|
||||
"required": false,
|
||||
"type": "array",
|
||||
"collectionFormat": "multi",
|
||||
@@ -24204,6 +24233,12 @@
|
||||
"description": "Is virus scanning enabled? For file size above 20MB AntiVirus scanning is skipped even if it's enabled",
|
||||
"default": true,
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Are image transformations enabled?",
|
||||
"default": true,
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -24405,6 +24440,12 @@
|
||||
"description": "Is virus scanning enabled? For file size above 20MB AntiVirus scanning is skipped even if it's enabled",
|
||||
"default": true,
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Are image transformations enabled?",
|
||||
"default": true,
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -26429,7 +26470,7 @@
|
||||
},
|
||||
"rowSecurity": {
|
||||
"type": "boolean",
|
||||
"description": "Enables configuring permissions for individual rows. A user needs one of row or table level permissions to access a document. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).",
|
||||
"description": "Enables configuring permissions for individual rows. A user needs one of row or table-level permissions to access a row. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).",
|
||||
"default": false,
|
||||
"x-example": false
|
||||
},
|
||||
@@ -26922,7 +26963,8 @@
|
||||
"type": "string",
|
||||
"description": "Default value for the column in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Cannot be set when column is required.",
|
||||
"default": null,
|
||||
"x-example": null
|
||||
"x-example": null,
|
||||
"x-nullable": true
|
||||
},
|
||||
"array": {
|
||||
"type": "boolean",
|
||||
@@ -42175,6 +42217,11 @@
|
||||
"type": "boolean",
|
||||
"description": "Virus scanning is enabled.",
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Image transformations are enabled.",
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -42189,7 +42236,8 @@
|
||||
"allowedFileExtensions",
|
||||
"compression",
|
||||
"encryption",
|
||||
"antivirus"
|
||||
"antivirus",
|
||||
"transformations"
|
||||
],
|
||||
"example": {
|
||||
"$id": "5e5ea5c16897e",
|
||||
@@ -42208,7 +42256,8 @@
|
||||
],
|
||||
"compression": "gzip",
|
||||
"encryption": false,
|
||||
"antivirus": false
|
||||
"antivirus": false,
|
||||
"transformations": false
|
||||
}
|
||||
},
|
||||
"resourceToken": {
|
||||
|
||||
@@ -7851,7 +7851,8 @@
|
||||
"type": "string",
|
||||
"description": "Default value for the attribute in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Cannot be set when attribute is required.",
|
||||
"default": null,
|
||||
"x-example": null
|
||||
"x-example": null,
|
||||
"x-nullable": true
|
||||
},
|
||||
"array": {
|
||||
"type": "boolean",
|
||||
@@ -14365,7 +14366,7 @@
|
||||
"branch",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": null,
|
||||
"x-enum-name": "TemplateReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -14466,7 +14467,7 @@
|
||||
"branch",
|
||||
"commit"
|
||||
],
|
||||
"x-enum-name": "VCSDeploymentType",
|
||||
"x-enum-name": "VCSReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -32440,7 +32441,7 @@
|
||||
"commit",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": null,
|
||||
"x-enum-name": "TemplateReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -32542,7 +32543,7 @@
|
||||
"commit",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": "VCSDeploymentType",
|
||||
"x-enum-name": "VCSReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -33564,7 +33565,7 @@
|
||||
"parameters": [
|
||||
{
|
||||
"name": "queries",
|
||||
"description": "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: enabled, name, fileSecurity, maximumFileSize, encryption, antivirus",
|
||||
"description": "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: enabled, name, fileSecurity, maximumFileSize, encryption, antivirus, transformations",
|
||||
"required": false,
|
||||
"type": "array",
|
||||
"collectionFormat": "multi",
|
||||
@@ -33722,6 +33723,12 @@
|
||||
"description": "Is virus scanning enabled? For file size above 20MB AntiVirus scanning is skipped even if it's enabled",
|
||||
"default": true,
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Are image transformations enabled?",
|
||||
"default": true,
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -33921,6 +33928,12 @@
|
||||
"description": "Is virus scanning enabled? For file size above 20MB AntiVirus scanning is skipped even if it's enabled",
|
||||
"default": true,
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Are image transformations enabled?",
|
||||
"default": true,
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -36150,7 +36163,7 @@
|
||||
},
|
||||
"rowSecurity": {
|
||||
"type": "boolean",
|
||||
"description": "Enables configuring permissions for individual rows. A user needs one of row or table level permissions to access a document. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).",
|
||||
"description": "Enables configuring permissions for individual rows. A user needs one of row or table-level permissions to access a row. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).",
|
||||
"default": false,
|
||||
"x-example": false
|
||||
},
|
||||
@@ -36638,7 +36651,8 @@
|
||||
"type": "string",
|
||||
"description": "Default value for the column in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Cannot be set when column is required.",
|
||||
"default": null,
|
||||
"x-example": null
|
||||
"x-example": null,
|
||||
"x-nullable": true
|
||||
},
|
||||
"array": {
|
||||
"type": "boolean",
|
||||
@@ -53425,6 +53439,11 @@
|
||||
"type": "boolean",
|
||||
"description": "Virus scanning is enabled.",
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Image transformations are enabled.",
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -53439,7 +53458,8 @@
|
||||
"allowedFileExtensions",
|
||||
"compression",
|
||||
"encryption",
|
||||
"antivirus"
|
||||
"antivirus",
|
||||
"transformations"
|
||||
],
|
||||
"example": {
|
||||
"$id": "5e5ea5c16897e",
|
||||
@@ -53458,7 +53478,8 @@
|
||||
],
|
||||
"compression": "gzip",
|
||||
"encryption": false,
|
||||
"antivirus": false
|
||||
"antivirus": false,
|
||||
"transformations": false
|
||||
}
|
||||
},
|
||||
"resourceToken": {
|
||||
@@ -54651,6 +54672,17 @@
|
||||
"type": "string",
|
||||
"description": "Last commit date in ISO 8601 format.",
|
||||
"x-example": "datetime"
|
||||
},
|
||||
"variables": {
|
||||
"type": "array",
|
||||
"description": "Environment variables found in .env files",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"x-example": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -54660,7 +54692,8 @@
|
||||
"provider",
|
||||
"private",
|
||||
"defaultBranch",
|
||||
"pushedAt"
|
||||
"pushedAt",
|
||||
"variables"
|
||||
],
|
||||
"example": {
|
||||
"id": "5e5ea5c16897e",
|
||||
@@ -54669,7 +54702,11 @@
|
||||
"provider": "github",
|
||||
"private": true,
|
||||
"defaultBranch": "main",
|
||||
"pushedAt": "datetime"
|
||||
"pushedAt": "datetime",
|
||||
"variables": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
]
|
||||
}
|
||||
},
|
||||
"providerRepositoryFramework": {
|
||||
@@ -54711,6 +54748,17 @@
|
||||
"description": "Last commit date in ISO 8601 format.",
|
||||
"x-example": "datetime"
|
||||
},
|
||||
"variables": {
|
||||
"type": "array",
|
||||
"description": "Environment variables found in .env files",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"x-example": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
]
|
||||
},
|
||||
"framework": {
|
||||
"type": "string",
|
||||
"description": "Auto-detected framework. Empty if type is not \"framework\".",
|
||||
@@ -54725,6 +54773,7 @@
|
||||
"private",
|
||||
"defaultBranch",
|
||||
"pushedAt",
|
||||
"variables",
|
||||
"framework"
|
||||
],
|
||||
"example": {
|
||||
@@ -54735,6 +54784,10 @@
|
||||
"private": true,
|
||||
"defaultBranch": "main",
|
||||
"pushedAt": "datetime",
|
||||
"variables": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
],
|
||||
"framework": "nextjs"
|
||||
}
|
||||
},
|
||||
@@ -54777,6 +54830,17 @@
|
||||
"description": "Last commit date in ISO 8601 format.",
|
||||
"x-example": "datetime"
|
||||
},
|
||||
"variables": {
|
||||
"type": "array",
|
||||
"description": "Environment variables found in .env files",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"x-example": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
]
|
||||
},
|
||||
"runtime": {
|
||||
"type": "string",
|
||||
"description": "Auto-detected runtime. Empty if type is not \"runtime\".",
|
||||
@@ -54791,6 +54855,7 @@
|
||||
"private",
|
||||
"defaultBranch",
|
||||
"pushedAt",
|
||||
"variables",
|
||||
"runtime"
|
||||
],
|
||||
"example": {
|
||||
@@ -54801,6 +54866,10 @@
|
||||
"private": true,
|
||||
"defaultBranch": "main",
|
||||
"pushedAt": "datetime",
|
||||
"variables": [
|
||||
"PORT",
|
||||
"NODE_ENV"
|
||||
],
|
||||
"runtime": "node-22"
|
||||
}
|
||||
},
|
||||
@@ -54808,6 +54877,16 @@
|
||||
"description": "DetectionFramework",
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"variables": {
|
||||
"type": "array",
|
||||
"description": "Environment variables found in .env files",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"$ref": "#\/definitions\/detectionVariable"
|
||||
},
|
||||
"x-example": {},
|
||||
"x-nullable": true
|
||||
},
|
||||
"framework": {
|
||||
"type": "string",
|
||||
"description": "Framework",
|
||||
@@ -54836,6 +54915,7 @@
|
||||
"outputDirectory"
|
||||
],
|
||||
"example": {
|
||||
"variables": {},
|
||||
"framework": "nuxt",
|
||||
"installCommand": "npm install",
|
||||
"buildCommand": "npm run build",
|
||||
@@ -54846,6 +54926,16 @@
|
||||
"description": "DetectionRuntime",
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"variables": {
|
||||
"type": "array",
|
||||
"description": "Environment variables found in .env files",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"$ref": "#\/definitions\/detectionVariable"
|
||||
},
|
||||
"x-example": {},
|
||||
"x-nullable": true
|
||||
},
|
||||
"runtime": {
|
||||
"type": "string",
|
||||
"description": "Runtime",
|
||||
@@ -54868,11 +54958,36 @@
|
||||
"commands"
|
||||
],
|
||||
"example": {
|
||||
"variables": {},
|
||||
"runtime": "node",
|
||||
"entrypoint": "index.js",
|
||||
"commands": "npm install && npm run build"
|
||||
}
|
||||
},
|
||||
"detectionVariable": {
|
||||
"description": "DetectionVariable",
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"name": {
|
||||
"type": "string",
|
||||
"description": "Name of environment variable",
|
||||
"x-example": "NODE_ENV"
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"description": "Value of environment variable",
|
||||
"x-example": "production"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"name",
|
||||
"value"
|
||||
],
|
||||
"example": {
|
||||
"name": "NODE_ENV",
|
||||
"value": "production"
|
||||
}
|
||||
},
|
||||
"vcsContent": {
|
||||
"description": "VcsContents",
|
||||
"type": "object",
|
||||
|
||||
@@ -7310,7 +7310,8 @@
|
||||
"type": "string",
|
||||
"description": "Default value for the attribute in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Cannot be set when attribute is required.",
|
||||
"default": null,
|
||||
"x-example": null
|
||||
"x-example": null,
|
||||
"x-nullable": true
|
||||
},
|
||||
"array": {
|
||||
"type": "boolean",
|
||||
@@ -13181,7 +13182,7 @@
|
||||
"branch",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": null,
|
||||
"x-enum-name": "TemplateReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -13283,7 +13284,7 @@
|
||||
"branch",
|
||||
"commit"
|
||||
],
|
||||
"x-enum-name": "VCSDeploymentType",
|
||||
"x-enum-name": "VCSReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -23013,7 +23014,7 @@
|
||||
"commit",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": null,
|
||||
"x-enum-name": "TemplateReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -23116,7 +23117,7 @@
|
||||
"commit",
|
||||
"tag"
|
||||
],
|
||||
"x-enum-name": "VCSDeploymentType",
|
||||
"x-enum-name": "VCSReferenceType",
|
||||
"x-enum-keys": []
|
||||
},
|
||||
"reference": {
|
||||
@@ -24073,7 +24074,7 @@
|
||||
"parameters": [
|
||||
{
|
||||
"name": "queries",
|
||||
"description": "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: enabled, name, fileSecurity, maximumFileSize, encryption, antivirus",
|
||||
"description": "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: enabled, name, fileSecurity, maximumFileSize, encryption, antivirus, transformations",
|
||||
"required": false,
|
||||
"type": "array",
|
||||
"collectionFormat": "multi",
|
||||
@@ -24232,6 +24233,12 @@
|
||||
"description": "Is virus scanning enabled? For file size above 20MB AntiVirus scanning is skipped even if it's enabled",
|
||||
"default": true,
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Are image transformations enabled?",
|
||||
"default": true,
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -24433,6 +24440,12 @@
|
||||
"description": "Is virus scanning enabled? For file size above 20MB AntiVirus scanning is skipped even if it's enabled",
|
||||
"default": true,
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Are image transformations enabled?",
|
||||
"default": true,
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -26457,7 +26470,7 @@
|
||||
},
|
||||
"rowSecurity": {
|
||||
"type": "boolean",
|
||||
"description": "Enables configuring permissions for individual rows. A user needs one of row or table level permissions to access a document. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).",
|
||||
"description": "Enables configuring permissions for individual rows. A user needs one of row or table-level permissions to access a row. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).",
|
||||
"default": false,
|
||||
"x-example": false
|
||||
},
|
||||
@@ -26950,7 +26963,8 @@
|
||||
"type": "string",
|
||||
"description": "Default value for the column in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Cannot be set when column is required.",
|
||||
"default": null,
|
||||
"x-example": null
|
||||
"x-example": null,
|
||||
"x-nullable": true
|
||||
},
|
||||
"array": {
|
||||
"type": "boolean",
|
||||
@@ -42203,6 +42217,11 @@
|
||||
"type": "boolean",
|
||||
"description": "Virus scanning is enabled.",
|
||||
"x-example": false
|
||||
},
|
||||
"transformations": {
|
||||
"type": "boolean",
|
||||
"description": "Image transformations are enabled.",
|
||||
"x-example": false
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -42217,7 +42236,8 @@
|
||||
"allowedFileExtensions",
|
||||
"compression",
|
||||
"encryption",
|
||||
"antivirus"
|
||||
"antivirus",
|
||||
"transformations"
|
||||
],
|
||||
"example": {
|
||||
"$id": "5e5ea5c16897e",
|
||||
@@ -42236,7 +42256,8 @@
|
||||
],
|
||||
"compression": "gzip",
|
||||
"encryption": false,
|
||||
"antivirus": false
|
||||
"antivirus": false,
|
||||
"transformations": false
|
||||
}
|
||||
},
|
||||
"resourceToken": {
|
||||
|
||||
@@ -2,9 +2,7 @@
|
||||
|
||||
use Ahc\Jwt\JWT;
|
||||
use Appwrite\Auth\Auth;
|
||||
use Appwrite\Auth\MFA\Challenge;
|
||||
use Appwrite\Auth\MFA\Type;
|
||||
use Appwrite\Auth\MFA\Type\TOTP;
|
||||
use Appwrite\Auth\OAuth2\Exception as OAuth2Exception;
|
||||
use Appwrite\Auth\Phrase;
|
||||
use Appwrite\Auth\Validator\Password;
|
||||
@@ -4153,943 +4151,6 @@ App::put('/v1/account/verifications/phone')
|
||||
$response->dynamic($verificationDocument, Response::MODEL_TOKEN);
|
||||
});
|
||||
|
||||
App::patch('/v1/account/mfa')
|
||||
->desc('Update MFA')
|
||||
->groups(['api', 'account'])
|
||||
->label('event', 'users.[userId].update.mfa')
|
||||
->label('scope', 'account')
|
||||
->label('audits.event', 'user.update')
|
||||
->label('audits.resource', 'user/{response.$id}')
|
||||
->label('audits.userId', '{response.$id}')
|
||||
->label('sdk', new Method(
|
||||
namespace: 'account',
|
||||
group: 'mfa',
|
||||
name: 'updateMFA',
|
||||
description: '/docs/references/account/update-mfa.md',
|
||||
auth: [AuthType::SESSION, AuthType::JWT],
|
||||
responses: [
|
||||
new SDKResponse(
|
||||
code: Response::STATUS_CODE_OK,
|
||||
model: Response::MODEL_USER,
|
||||
)
|
||||
],
|
||||
contentType: ContentType::JSON
|
||||
))
|
||||
->param('mfa', null, new Boolean(), 'Enable or disable MFA.')
|
||||
->inject('requestTimestamp')
|
||||
->inject('response')
|
||||
->inject('user')
|
||||
->inject('session')
|
||||
->inject('dbForProject')
|
||||
->inject('queueForEvents')
|
||||
->action(function (bool $mfa, ?\DateTime $requestTimestamp, Response $response, Document $user, Document $session, Database $dbForProject, Event $queueForEvents) {
|
||||
|
||||
$user->setAttribute('mfa', $mfa);
|
||||
|
||||
$user = $dbForProject->updateDocument('users', $user->getId(), $user);
|
||||
|
||||
if ($mfa) {
|
||||
$factors = $session->getAttribute('factors', []);
|
||||
$totp = TOTP::getAuthenticatorFromUser($user);
|
||||
if ($totp !== null && $totp->getAttribute('verified', false)) {
|
||||
$factors[] = Type::TOTP;
|
||||
}
|
||||
if ($user->getAttribute('email', false) && $user->getAttribute('emailVerification', false)) {
|
||||
$factors[] = Type::EMAIL;
|
||||
}
|
||||
if ($user->getAttribute('phone', false) && $user->getAttribute('phoneVerification', false)) {
|
||||
$factors[] = Type::PHONE;
|
||||
}
|
||||
$factors = \array_values(\array_unique($factors));
|
||||
|
||||
$session->setAttribute('factors', $factors);
|
||||
$dbForProject->updateDocument('sessions', $session->getId(), $session);
|
||||
}
|
||||
|
||||
$queueForEvents->setParam('userId', $user->getId());
|
||||
|
||||
$response->dynamic($user, Response::MODEL_ACCOUNT);
|
||||
});
|
||||
|
||||
App::get('/v1/account/mfa/factors')
|
||||
->desc('List factors')
|
||||
->groups(['api', 'account', 'mfa'])
|
||||
->label('scope', 'account')
|
||||
->label('sdk', [
|
||||
new Method(
|
||||
namespace: 'account',
|
||||
group: 'mfa',
|
||||
name: 'listMfaFactors',
|
||||
description: '/docs/references/account/list-mfa-factors.md',
|
||||
auth: [AuthType::SESSION, AuthType::JWT],
|
||||
responses: [
|
||||
new SDKResponse(
|
||||
code: Response::STATUS_CODE_OK,
|
||||
model: Response::MODEL_MFA_FACTORS,
|
||||
)
|
||||
],
|
||||
contentType: ContentType::JSON,
|
||||
deprecated: new Deprecated(
|
||||
since: '1.8.0',
|
||||
replaceWith: 'account.listMFAFactors',
|
||||
),
|
||||
),
|
||||
new Method(
|
||||
namespace: 'account',
|
||||
group: 'mfa',
|
||||
name: 'listMFAFactors',
|
||||
description: '/docs/references/account/list-mfa-factors.md',
|
||||
auth: [AuthType::SESSION, AuthType::JWT],
|
||||
responses: [
|
||||
new SDKResponse(
|
||||
code: Response::STATUS_CODE_OK,
|
||||
model: Response::MODEL_MFA_FACTORS,
|
||||
)
|
||||
],
|
||||
contentType: ContentType::JSON
|
||||
)
|
||||
])
|
||||
->inject('response')
|
||||
->inject('user')
|
||||
->action(function (Response $response, Document $user) {
|
||||
|
||||
$mfaRecoveryCodes = $user->getAttribute('mfaRecoveryCodes', []);
|
||||
$recoveryCodeEnabled = \is_array($mfaRecoveryCodes) && \count($mfaRecoveryCodes) > 0;
|
||||
|
||||
$totp = TOTP::getAuthenticatorFromUser($user);
|
||||
|
||||
$factors = new Document([
|
||||
Type::TOTP => $totp !== null && $totp->getAttribute('verified', false),
|
||||
Type::EMAIL => $user->getAttribute('email', false) && $user->getAttribute('emailVerification', false),
|
||||
Type::PHONE => $user->getAttribute('phone', false) && $user->getAttribute('phoneVerification', false),
|
||||
Type::RECOVERY_CODE => $recoveryCodeEnabled
|
||||
]);
|
||||
|
||||
$response->dynamic($factors, Response::MODEL_MFA_FACTORS);
|
||||
});
|
||||
|
||||
App::post('/v1/account/mfa/authenticators/:type')
|
||||
->desc('Create authenticator')
|
||||
->groups(['api', 'account'])
|
||||
->label('event', 'users.[userId].update.mfa')
|
||||
->label('scope', 'account')
|
||||
->label('audits.event', 'user.update')
|
||||
->label('audits.resource', 'user/{response.$id}')
|
||||
->label('audits.userId', '{response.$id}')
|
||||
->label('sdk', [
|
||||
new Method(
|
||||
namespace: 'account',
|
||||
group: 'mfa',
|
||||
name: 'createMfaAuthenticator',
|
||||
description: '/docs/references/account/create-mfa-authenticator.md',
|
||||
auth: [AuthType::SESSION, AuthType::JWT],
|
||||
responses: [
|
||||
new SDKResponse(
|
||||
code: Response::STATUS_CODE_OK,
|
||||
model: Response::MODEL_MFA_TYPE,
|
||||
)
|
||||
],
|
||||
contentType: ContentType::JSON,
|
||||
deprecated: new Deprecated(
|
||||
since: '1.8.0',
|
||||
replaceWith: 'account.createMFAAuthenticator',
|
||||
),
|
||||
),
|
||||
new Method(
|
||||
namespace: 'account',
|
||||
group: 'mfa',
|
||||
name: 'createMFAAuthenticator',
|
||||
description: '/docs/references/account/create-mfa-authenticator.md',
|
||||
auth: [AuthType::SESSION, AuthType::JWT],
|
||||
responses: [
|
||||
new SDKResponse(
|
||||
code: Response::STATUS_CODE_OK,
|
||||
model: Response::MODEL_MFA_TYPE,
|
||||
)
|
||||
],
|
||||
contentType: ContentType::JSON
|
||||
)
|
||||
])
|
||||
->param('type', null, new WhiteList([Type::TOTP]), 'Type of authenticator. Must be `' . Type::TOTP . '`')
|
||||
->inject('requestTimestamp')
|
||||
->inject('response')
|
||||
->inject('project')
|
||||
->inject('user')
|
||||
->inject('dbForProject')
|
||||
->inject('queueForEvents')
|
||||
->action(function (string $type, ?\DateTime $requestTimestamp, Response $response, Document $project, Document $user, Database $dbForProject, Event $queueForEvents) {
|
||||
|
||||
$otp = (match ($type) {
|
||||
Type::TOTP => new TOTP(),
|
||||
default => throw new Exception(Exception::GENERAL_ARGUMENT_INVALID, 'Unknown type.') // Ideally never happens if param validator stays always in sync
|
||||
});
|
||||
|
||||
$otp->setLabel($user->getAttribute('email'));
|
||||
$otp->setIssuer($project->getAttribute('name'));
|
||||
|
||||
$authenticator = TOTP::getAuthenticatorFromUser($user);
|
||||
|
||||
if ($authenticator) {
|
||||
if ($authenticator->getAttribute('verified')) {
|
||||
throw new Exception(Exception::USER_AUTHENTICATOR_ALREADY_VERIFIED);
|
||||
}
|
||||
$dbForProject->deleteDocument('authenticators', $authenticator->getId());
|
||||
}
|
||||
|
||||
$authenticator = new Document([
|
||||
'$id' => ID::unique(),
|
||||
'userId' => $user->getId(),
|
||||
'userInternalId' => $user->getSequence(),
|
||||
'type' => Type::TOTP,
|
||||
'verified' => false,
|
||||
'data' => [
|
||||
'secret' => $otp->getSecret(),
|
||||
],
|
||||
'$permissions' => [
|
||||
Permission::read(Role::user($user->getId())),
|
||||
Permission::update(Role::user($user->getId())),
|
||||
Permission::delete(Role::user($user->getId())),
|
||||
]
|
||||
]);
|
||||
|
||||
$model = new Document([
|
||||
'secret' => $otp->getSecret(),
|
||||
'uri' => $otp->getProvisioningUri()
|
||||
]);
|
||||
|
||||
$authenticator = $dbForProject->createDocument('authenticators', $authenticator);
|
||||
$dbForProject->purgeCachedDocument('users', $user->getId());
|
||||
|
||||
$queueForEvents->setParam('userId', $user->getId());
|
||||
|
||||
$response->dynamic($model, Response::MODEL_MFA_TYPE);
|
||||
});
|
||||
|
||||
App::put('/v1/account/mfa/authenticators/:type')
|
||||
->desc('Update authenticator (confirmation)')
|
||||
->groups(['api', 'account'])
|
||||
->label('event', 'users.[userId].update.mfa')
|
||||
->label('scope', 'account')
|
||||
->label('audits.event', 'user.update')
|
||||
->label('audits.resource', 'user/{response.$id}')
|
||||
->label('audits.userId', '{response.$id}')
|
||||
->label('sdk', [
|
||||
new Method(
|
||||
namespace: 'account',
|
||||
group: 'mfa',
|
||||
name: 'updateMfaAuthenticator',
|
||||
description: '/docs/references/account/update-mfa-authenticator.md',
|
||||
auth: [AuthType::SESSION, AuthType::JWT],
|
||||
responses: [
|
||||
new SDKResponse(
|
||||
code: Response::STATUS_CODE_OK,
|
||||
model: Response::MODEL_USER,
|
||||
)
|
||||
],
|
||||
contentType: ContentType::JSON,
|
||||
deprecated: new Deprecated(
|
||||
since: '1.8.0',
|
||||
replaceWith: 'account.updateMFAAuthenticator',
|
||||
),
|
||||
),
|
||||
new Method(
|
||||
namespace: 'account',
|
||||
group: 'mfa',
|
||||
name: 'updateMFAAuthenticator',
|
||||
description: '/docs/references/account/update-mfa-authenticator.md',
|
||||
auth: [AuthType::SESSION, AuthType::JWT],
|
||||
responses: [
|
||||
new SDKResponse(
|
||||
code: Response::STATUS_CODE_OK,
|
||||
model: Response::MODEL_USER,
|
||||
)
|
||||
],
|
||||
contentType: ContentType::JSON
|
||||
)
|
||||
])
|
||||
->param('type', null, new WhiteList([Type::TOTP]), 'Type of authenticator.')
|
||||
->param('otp', '', new Text(256), 'Valid verification token.')
|
||||
->inject('response')
|
||||
->inject('user')
|
||||
->inject('session')
|
||||
->inject('dbForProject')
|
||||
->inject('queueForEvents')
|
||||
->action(function (string $type, string $otp, Response $response, Document $user, Document $session, Database $dbForProject, Event $queueForEvents) {
|
||||
|
||||
$authenticator = (match ($type) {
|
||||
Type::TOTP => TOTP::getAuthenticatorFromUser($user),
|
||||
default => null
|
||||
});
|
||||
|
||||
if ($authenticator === null) {
|
||||
throw new Exception(Exception::USER_AUTHENTICATOR_NOT_FOUND);
|
||||
}
|
||||
|
||||
if ($authenticator->getAttribute('verified')) {
|
||||
throw new Exception(Exception::USER_AUTHENTICATOR_ALREADY_VERIFIED);
|
||||
}
|
||||
|
||||
$success = (match ($type) {
|
||||
Type::TOTP => Challenge\TOTP::verify($user, $otp),
|
||||
default => false
|
||||
});
|
||||
|
||||
if (!$success) {
|
||||
throw new Exception(Exception::USER_INVALID_TOKEN);
|
||||
}
|
||||
|
||||
$authenticator->setAttribute('verified', true);
|
||||
|
||||
$dbForProject->updateDocument('authenticators', $authenticator->getId(), $authenticator);
|
||||
$dbForProject->purgeCachedDocument('users', $user->getId());
|
||||
|
||||
$factors = $session->getAttribute('factors', []);
|
||||
$factors[] = $type;
|
||||
$factors = \array_values(\array_unique($factors));
|
||||
|
||||
$session->setAttribute('factors', $factors);
|
||||
$dbForProject->updateDocument('sessions', $session->getId(), $session);
|
||||
|
||||
$queueForEvents->setParam('userId', $user->getId());
|
||||
|
||||
$response->dynamic($user, Response::MODEL_ACCOUNT);
|
||||
});
|
||||
|
||||
App::post('/v1/account/mfa/recovery-codes')
|
||||
->desc('Create MFA recovery codes')
|
||||
->groups(['api', 'account'])
|
||||
->label('event', 'users.[userId].update.mfa')
|
||||
->label('scope', 'account')
|
||||
->label('audits.event', 'user.update')
|
||||
->label('audits.resource', 'user/{response.$id}')
|
||||
->label('audits.userId', '{response.$id}')
|
||||
->label('sdk', [
|
||||
new Method(
|
||||
namespace: 'account',
|
||||
group: 'mfa',
|
||||
name: 'createMfaRecoveryCodes',
|
||||
description: '/docs/references/account/create-mfa-recovery-codes.md',
|
||||
auth: [AuthType::SESSION, AuthType::JWT],
|
||||
responses: [
|
||||
new SDKResponse(
|
||||
code: Response::STATUS_CODE_CREATED,
|
||||
model: Response::MODEL_MFA_RECOVERY_CODES,
|
||||
)
|
||||
],
|
||||
contentType: ContentType::JSON,
|
||||
deprecated: new Deprecated(
|
||||
since: '1.8.0',
|
||||
replaceWith: 'account.createMFARecoveryCodes',
|
||||
),
|
||||
),
|
||||
new Method(
|
||||
namespace: 'account',
|
||||
group: 'mfa',
|
||||
name: 'createMFARecoveryCodes',
|
||||
description: '/docs/references/account/create-mfa-recovery-codes.md',
|
||||
auth: [AuthType::SESSION, AuthType::JWT],
|
||||
responses: [
|
||||
new SDKResponse(
|
||||
code: Response::STATUS_CODE_CREATED,
|
||||
model: Response::MODEL_MFA_RECOVERY_CODES,
|
||||
)
|
||||
],
|
||||
contentType: ContentType::JSON
|
||||
)
|
||||
])
|
||||
->inject('response')
|
||||
->inject('user')
|
||||
->inject('dbForProject')
|
||||
->inject('queueForEvents')
|
||||
->action(function (Response $response, Document $user, Database $dbForProject, Event $queueForEvents) {
|
||||
|
||||
$mfaRecoveryCodes = $user->getAttribute('mfaRecoveryCodes', []);
|
||||
|
||||
if (!empty($mfaRecoveryCodes)) {
|
||||
throw new Exception(Exception::USER_RECOVERY_CODES_ALREADY_EXISTS);
|
||||
}
|
||||
|
||||
$mfaRecoveryCodes = Type::generateBackupCodes();
|
||||
$user->setAttribute('mfaRecoveryCodes', $mfaRecoveryCodes);
|
||||
$dbForProject->updateDocument('users', $user->getId(), $user);
|
||||
|
||||
$queueForEvents->setParam('userId', $user->getId());
|
||||
|
||||
$document = new Document([
|
||||
'recoveryCodes' => $mfaRecoveryCodes
|
||||
]);
|
||||
|
||||
$response->dynamic($document, Response::MODEL_MFA_RECOVERY_CODES);
|
||||
});
|
||||
|
||||
App::patch('/v1/account/mfa/recovery-codes')
|
||||
->desc('Update MFA recovery codes (regenerate)')
|
||||
->groups(['api', 'account', 'mfaProtected'])
|
||||
->label('event', 'users.[userId].update.mfa')
|
||||
->label('scope', 'account')
|
||||
->label('audits.event', 'user.update')
|
||||
->label('audits.resource', 'user/{response.$id}')
|
||||
->label('audits.userId', '{response.$id}')
|
||||
->label('sdk', [
|
||||
new Method(
|
||||
namespace: 'account',
|
||||
group: 'mfa',
|
||||
name: 'updateMfaRecoveryCodes',
|
||||
description: '/docs/references/account/update-mfa-recovery-codes.md',
|
||||
auth: [AuthType::SESSION, AuthType::JWT],
|
||||
responses: [
|
||||
new SDKResponse(
|
||||
code: Response::STATUS_CODE_OK,
|
||||
model: Response::MODEL_MFA_RECOVERY_CODES,
|
||||
)
|
||||
],
|
||||
contentType: ContentType::JSON,
|
||||
deprecated: new Deprecated(
|
||||
since: '1.8.0',
|
||||
replaceWith: 'account.updateMFARecoveryCodes',
|
||||
),
|
||||
),
|
||||
new Method(
|
||||
namespace: 'account',
|
||||
group: 'mfa',
|
||||
name: 'updateMFARecoveryCodes',
|
||||
description: '/docs/references/account/update-mfa-recovery-codes.md',
|
||||
auth: [AuthType::SESSION, AuthType::JWT],
|
||||
responses: [
|
||||
new SDKResponse(
|
||||
code: Response::STATUS_CODE_OK,
|
||||
model: Response::MODEL_MFA_RECOVERY_CODES,
|
||||
)
|
||||
],
|
||||
contentType: ContentType::JSON
|
||||
)
|
||||
])
|
||||
->inject('dbForProject')
|
||||
->inject('response')
|
||||
->inject('user')
|
||||
->inject('queueForEvents')
|
||||
->action(function (Database $dbForProject, Response $response, Document $user, Event $queueForEvents) {
|
||||
|
||||
$mfaRecoveryCodes = $user->getAttribute('mfaRecoveryCodes', []);
|
||||
if (empty($mfaRecoveryCodes)) {
|
||||
throw new Exception(Exception::USER_RECOVERY_CODES_NOT_FOUND);
|
||||
}
|
||||
|
||||
$mfaRecoveryCodes = Type::generateBackupCodes();
|
||||
$user->setAttribute('mfaRecoveryCodes', $mfaRecoveryCodes);
|
||||
$dbForProject->updateDocument('users', $user->getId(), $user);
|
||||
|
||||
$queueForEvents->setParam('userId', $user->getId());
|
||||
|
||||
$document = new Document([
|
||||
'recoveryCodes' => $mfaRecoveryCodes
|
||||
]);
|
||||
|
||||
$response->dynamic($document, Response::MODEL_MFA_RECOVERY_CODES);
|
||||
});
|
||||
|
||||
App::get('/v1/account/mfa/recovery-codes')
|
||||
->desc('List MFA recovery codes')
|
||||
->groups(['api', 'account', 'mfaProtected'])
|
||||
->label('scope', 'account')
|
||||
->label('sdk', [
|
||||
new Method(
|
||||
namespace: 'account',
|
||||
group: 'mfa',
|
||||
name: 'getMfaRecoveryCodes',
|
||||
description: '/docs/references/account/get-mfa-recovery-codes.md',
|
||||
auth: [AuthType::SESSION, AuthType::JWT],
|
||||
responses: [
|
||||
new SDKResponse(
|
||||
code: Response::STATUS_CODE_OK,
|
||||
model: Response::MODEL_MFA_RECOVERY_CODES,
|
||||
)
|
||||
],
|
||||
contentType: ContentType::JSON,
|
||||
deprecated: new Deprecated(
|
||||
since: '1.8.0',
|
||||
replaceWith: 'account.getMFARecoveryCodes',
|
||||
),
|
||||
),
|
||||
new Method(
|
||||
namespace: 'account',
|
||||
group: 'mfa',
|
||||
name: 'getMFARecoveryCodes',
|
||||
description: '/docs/references/account/get-mfa-recovery-codes.md',
|
||||
auth: [AuthType::SESSION, AuthType::JWT],
|
||||
responses: [
|
||||
new SDKResponse(
|
||||
code: Response::STATUS_CODE_OK,
|
||||
model: Response::MODEL_MFA_RECOVERY_CODES,
|
||||
)
|
||||
],
|
||||
contentType: ContentType::JSON
|
||||
)
|
||||
])
|
||||
->inject('response')
|
||||
->inject('user')
|
||||
->action(function (Response $response, Document $user) {
|
||||
|
||||
$mfaRecoveryCodes = $user->getAttribute('mfaRecoveryCodes', []);
|
||||
|
||||
if (empty($mfaRecoveryCodes)) {
|
||||
throw new Exception(Exception::USER_RECOVERY_CODES_NOT_FOUND);
|
||||
}
|
||||
|
||||
$document = new Document([
|
||||
'recoveryCodes' => $mfaRecoveryCodes
|
||||
]);
|
||||
|
||||
$response->dynamic($document, Response::MODEL_MFA_RECOVERY_CODES);
|
||||
});
|
||||
|
||||
App::delete('/v1/account/mfa/authenticators/:type')
|
||||
->desc('Delete authenticator')
|
||||
->groups(['api', 'account', 'mfaProtected'])
|
||||
->label('event', 'users.[userId].delete.mfa')
|
||||
->label('scope', 'account')
|
||||
->label('audits.event', 'user.update')
|
||||
->label('audits.resource', 'user/{response.$id}')
|
||||
->label('audits.userId', '{response.$id}')
|
||||
->label('sdk', [
|
||||
new Method(
|
||||
namespace: 'account',
|
||||
group: 'mfa',
|
||||
name: 'deleteMfaAuthenticator',
|
||||
description: '/docs/references/account/delete-mfa-authenticator.md',
|
||||
auth: [AuthType::SESSION, AuthType::JWT],
|
||||
responses: [
|
||||
new SDKResponse(
|
||||
code: Response::STATUS_CODE_NOCONTENT,
|
||||
model: Response::MODEL_NONE,
|
||||
)
|
||||
],
|
||||
contentType: ContentType::NONE,
|
||||
deprecated: new Deprecated(
|
||||
since: '1.8.0',
|
||||
replaceWith: 'account.deleteMFAAuthenticator',
|
||||
),
|
||||
),
|
||||
new Method(
|
||||
namespace: 'account',
|
||||
group: 'mfa',
|
||||
name: 'deleteMFAAuthenticator',
|
||||
description: '/docs/references/account/delete-mfa-authenticator.md',
|
||||
auth: [AuthType::SESSION, AuthType::JWT],
|
||||
responses: [
|
||||
new SDKResponse(
|
||||
code: Response::STATUS_CODE_NOCONTENT,
|
||||
model: Response::MODEL_NONE,
|
||||
)
|
||||
],
|
||||
contentType: ContentType::NONE
|
||||
)
|
||||
])
|
||||
->param('type', null, new WhiteList([Type::TOTP]), 'Type of authenticator.')
|
||||
->inject('response')
|
||||
->inject('user')
|
||||
->inject('dbForProject')
|
||||
->inject('queueForEvents')
|
||||
->action(function (string $type, Response $response, Document $user, Database $dbForProject, Event $queueForEvents) {
|
||||
|
||||
$authenticator = (match ($type) {
|
||||
Type::TOTP => TOTP::getAuthenticatorFromUser($user),
|
||||
default => null
|
||||
});
|
||||
|
||||
if (!$authenticator) {
|
||||
throw new Exception(Exception::USER_AUTHENTICATOR_NOT_FOUND);
|
||||
}
|
||||
|
||||
$dbForProject->deleteDocument('authenticators', $authenticator->getId());
|
||||
$dbForProject->purgeCachedDocument('users', $user->getId());
|
||||
|
||||
$queueForEvents->setParam('userId', $user->getId());
|
||||
|
||||
$response->noContent();
|
||||
});
|
||||
|
||||
App::post('/v1/account/mfa/challenge')
|
||||
->desc('Create MFA challenge')
|
||||
->groups(['api', 'account', 'mfa'])
|
||||
->label('scope', 'account')
|
||||
->label('event', 'users.[userId].challenges.[challengeId].create')
|
||||
->label('audits.event', 'challenge.create')
|
||||
->label('audits.resource', 'user/{response.userId}')
|
||||
->label('audits.userId', '{response.userId}')
|
||||
->label('sdk', [
|
||||
new Method(
|
||||
namespace: 'account',
|
||||
group: 'mfa',
|
||||
name: 'createMfaChallenge',
|
||||
description: '/docs/references/account/create-mfa-challenge.md',
|
||||
auth: [],
|
||||
responses: [
|
||||
new SDKResponse(
|
||||
code: Response::STATUS_CODE_CREATED,
|
||||
model: Response::MODEL_MFA_CHALLENGE,
|
||||
)
|
||||
],
|
||||
contentType: ContentType::JSON,
|
||||
deprecated: new Deprecated(
|
||||
since: '1.8.0',
|
||||
replaceWith: 'account.createMFAChallenge',
|
||||
),
|
||||
),
|
||||
new Method(
|
||||
namespace: 'account',
|
||||
group: 'mfa',
|
||||
name: 'createMFAChallenge',
|
||||
description: '/docs/references/account/create-mfa-challenge.md',
|
||||
auth: [],
|
||||
responses: [
|
||||
new SDKResponse(
|
||||
code: Response::STATUS_CODE_CREATED,
|
||||
model: Response::MODEL_MFA_CHALLENGE,
|
||||
)
|
||||
],
|
||||
contentType: ContentType::JSON
|
||||
)
|
||||
])
|
||||
->label('abuse-limit', 10)
|
||||
->label('abuse-key', 'url:{url},userId:{userId}')
|
||||
->param('factor', '', new WhiteList([Type::EMAIL, Type::PHONE, Type::TOTP, Type::RECOVERY_CODE]), 'Factor used for verification. Must be one of following: `' . Type::EMAIL . '`, `' . Type::PHONE . '`, `' . Type::TOTP . '`, `' . Type::RECOVERY_CODE . '`.')
|
||||
->inject('response')
|
||||
->inject('dbForProject')
|
||||
->inject('user')
|
||||
->inject('locale')
|
||||
->inject('project')
|
||||
->inject('request')
|
||||
->inject('queueForEvents')
|
||||
->inject('queueForMessaging')
|
||||
->inject('queueForMails')
|
||||
->inject('timelimit')
|
||||
->inject('queueForStatsUsage')
|
||||
->inject('plan')
|
||||
->action(function (string $factor, Response $response, Database $dbForProject, Document $user, Locale $locale, Document $project, Request $request, Event $queueForEvents, Messaging $queueForMessaging, Mail $queueForMails, callable $timelimit, StatsUsage $queueForStatsUsage, array $plan) {
|
||||
|
||||
$expire = DateTime::formatTz(DateTime::addSeconds(new \DateTime(), Auth::TOKEN_EXPIRATION_CONFIRM));
|
||||
$code = Auth::codeGenerator();
|
||||
$challenge = new Document([
|
||||
'userId' => $user->getId(),
|
||||
'userInternalId' => $user->getSequence(),
|
||||
'type' => $factor,
|
||||
'token' => Auth::tokenGenerator(),
|
||||
'code' => $code,
|
||||
'expire' => $expire,
|
||||
'$permissions' => [
|
||||
Permission::read(Role::user($user->getId())),
|
||||
Permission::update(Role::user($user->getId())),
|
||||
Permission::delete(Role::user($user->getId())),
|
||||
],
|
||||
]);
|
||||
|
||||
$challenge = $dbForProject->createDocument('challenges', $challenge);
|
||||
|
||||
switch ($factor) {
|
||||
case Type::PHONE:
|
||||
if (empty(System::getEnv('_APP_SMS_PROVIDER'))) {
|
||||
throw new Exception(Exception::GENERAL_PHONE_DISABLED, 'Phone provider not configured');
|
||||
}
|
||||
if (empty($user->getAttribute('phone'))) {
|
||||
throw new Exception(Exception::USER_PHONE_NOT_FOUND);
|
||||
}
|
||||
if (!$user->getAttribute('phoneVerification')) {
|
||||
throw new Exception(Exception::USER_PHONE_NOT_VERIFIED);
|
||||
}
|
||||
|
||||
$message = Template::fromFile(__DIR__ . '/../../config/locale/templates/sms-base.tpl');
|
||||
|
||||
$customTemplate = $project->getAttribute('templates', [])['sms.mfaChallenge-' . $locale->default] ?? [];
|
||||
if (!empty($customTemplate)) {
|
||||
$message = $customTemplate['message'] ?? $message;
|
||||
}
|
||||
|
||||
$messageContent = Template::fromString($locale->getText("sms.verification.body"));
|
||||
$messageContent
|
||||
->setParam('{{project}}', $project->getAttribute('name'))
|
||||
->setParam('{{secret}}', $code);
|
||||
$messageContent = \strip_tags($messageContent->render());
|
||||
$message = $message->setParam('{{token}}', $messageContent);
|
||||
|
||||
$message = $message->render();
|
||||
|
||||
$phone = $user->getAttribute('phone');
|
||||
$queueForMessaging
|
||||
->setType(MESSAGE_SEND_TYPE_INTERNAL)
|
||||
->setMessage(new Document([
|
||||
'$id' => $challenge->getId(),
|
||||
'data' => [
|
||||
'content' => $code,
|
||||
],
|
||||
]))
|
||||
->setRecipients([$phone])
|
||||
->setProviderType(MESSAGE_TYPE_SMS);
|
||||
|
||||
if (isset($plan['authPhone'])) {
|
||||
$timelimit = $timelimit('organization:{organizationId}', $plan['authPhone'], 30 * 24 * 60 * 60); // 30 days
|
||||
$timelimit
|
||||
->setParam('{organizationId}', $project->getAttribute('teamId'));
|
||||
|
||||
$abuse = new Abuse($timelimit);
|
||||
if ($abuse->check() && System::getEnv('_APP_OPTIONS_ABUSE', 'enabled') === 'enabled') {
|
||||
$helper = PhoneNumberUtil::getInstance();
|
||||
$countryCode = $helper->parse($phone)->getCountryCode();
|
||||
|
||||
if (!empty($countryCode)) {
|
||||
$queueForStatsUsage
|
||||
->addMetric(str_replace('{countryCode}', $countryCode, METRIC_AUTH_METHOD_PHONE_COUNTRY_CODE), 1);
|
||||
}
|
||||
}
|
||||
$queueForStatsUsage
|
||||
->addMetric(METRIC_AUTH_METHOD_PHONE, 1)
|
||||
->setProject($project)
|
||||
->trigger();
|
||||
}
|
||||
break;
|
||||
case Type::EMAIL:
|
||||
if (empty(System::getEnv('_APP_SMTP_HOST'))) {
|
||||
throw new Exception(Exception::GENERAL_SMTP_DISABLED, 'SMTP disabled');
|
||||
}
|
||||
if (empty($user->getAttribute('email'))) {
|
||||
throw new Exception(Exception::USER_EMAIL_NOT_FOUND);
|
||||
}
|
||||
if (!$user->getAttribute('emailVerification')) {
|
||||
throw new Exception(Exception::USER_EMAIL_NOT_VERIFIED);
|
||||
}
|
||||
|
||||
$subject = $locale->getText("emails.mfaChallenge.subject");
|
||||
$preview = $locale->getText("emails.mfaChallenge.preview");
|
||||
$heading = $locale->getText("emails.mfaChallenge.heading");
|
||||
|
||||
$customTemplate = $project->getAttribute('templates', [])['email.mfaChallenge-' . $locale->default] ?? [];
|
||||
$smtpBaseTemplate = $project->getAttribute('smtpBaseTemplate', 'email-base');
|
||||
|
||||
$validator = new FileName();
|
||||
if (!$validator->isValid($smtpBaseTemplate)) {
|
||||
throw new Exception(Exception::GENERAL_BAD_REQUEST, 'Invalid template path');
|
||||
}
|
||||
|
||||
$bodyTemplate = __DIR__ . '/../../config/locale/templates/' . $smtpBaseTemplate . '.tpl';
|
||||
|
||||
$detector = new Detector($request->getUserAgent('UNKNOWN'));
|
||||
$agentOs = $detector->getOS();
|
||||
$agentClient = $detector->getClient();
|
||||
$agentDevice = $detector->getDevice();
|
||||
|
||||
$message = Template::fromFile(__DIR__ . '/../../config/locale/templates/email-mfa-challenge.tpl');
|
||||
$message
|
||||
->setParam('{{hello}}', $locale->getText("emails.mfaChallenge.hello"))
|
||||
->setParam('{{description}}', $locale->getText("emails.mfaChallenge.description"))
|
||||
->setParam('{{clientInfo}}', $locale->getText("emails.mfaChallenge.clientInfo"))
|
||||
->setParam('{{thanks}}', $locale->getText("emails.mfaChallenge.thanks"))
|
||||
->setParam('{{signature}}', $locale->getText("emails.mfaChallenge.signature"));
|
||||
|
||||
$body = $message->render();
|
||||
|
||||
$smtp = $project->getAttribute('smtp', []);
|
||||
$smtpEnabled = $smtp['enabled'] ?? false;
|
||||
|
||||
$senderEmail = System::getEnv('_APP_SYSTEM_EMAIL_ADDRESS', APP_EMAIL_TEAM);
|
||||
$senderName = System::getEnv('_APP_SYSTEM_EMAIL_NAME', APP_NAME . ' Server');
|
||||
$replyTo = "";
|
||||
|
||||
if ($smtpEnabled) {
|
||||
if (!empty($smtp['senderEmail'])) {
|
||||
$senderEmail = $smtp['senderEmail'];
|
||||
}
|
||||
if (!empty($smtp['senderName'])) {
|
||||
$senderName = $smtp['senderName'];
|
||||
}
|
||||
if (!empty($smtp['replyTo'])) {
|
||||
$replyTo = $smtp['replyTo'];
|
||||
}
|
||||
|
||||
$queueForMails
|
||||
->setSmtpHost($smtp['host'] ?? '')
|
||||
->setSmtpPort($smtp['port'] ?? '')
|
||||
->setSmtpUsername($smtp['username'] ?? '')
|
||||
->setSmtpPassword($smtp['password'] ?? '')
|
||||
->setSmtpSecure($smtp['secure'] ?? '');
|
||||
|
||||
if (!empty($customTemplate)) {
|
||||
if (!empty($customTemplate['senderEmail'])) {
|
||||
$senderEmail = $customTemplate['senderEmail'];
|
||||
}
|
||||
if (!empty($customTemplate['senderName'])) {
|
||||
$senderName = $customTemplate['senderName'];
|
||||
}
|
||||
if (!empty($customTemplate['replyTo'])) {
|
||||
$replyTo = $customTemplate['replyTo'];
|
||||
}
|
||||
|
||||
$body = $customTemplate['message'] ?? '';
|
||||
$subject = $customTemplate['subject'] ?? $subject;
|
||||
}
|
||||
|
||||
$queueForMails
|
||||
->setSmtpReplyTo($replyTo)
|
||||
->setSmtpSenderEmail($senderEmail)
|
||||
->setSmtpSenderName($senderName);
|
||||
}
|
||||
|
||||
$emailVariables = [
|
||||
'heading' => $heading,
|
||||
'direction' => $locale->getText('settings.direction'),
|
||||
// {{user}}, {{project}} and {{otp}} are required in the templates
|
||||
'user' => $user->getAttribute('name'),
|
||||
'project' => $project->getAttribute('name'),
|
||||
'otp' => $code,
|
||||
'agentDevice' => $agentDevice['deviceBrand'] ?? $agentDevice['deviceBrand'] ?? 'UNKNOWN',
|
||||
'agentClient' => $agentClient['clientName'] ?? 'UNKNOWN',
|
||||
'agentOs' => $agentOs['osName'] ?? 'UNKNOWN',
|
||||
];
|
||||
|
||||
if ($smtpBaseTemplate === APP_BRANDED_EMAIL_BASE_TEMPLATE) {
|
||||
$emailVariables = array_merge($emailVariables, [
|
||||
'accentColor' => APP_EMAIL_ACCENT_COLOR,
|
||||
'logoUrl' => APP_EMAIL_LOGO_URL,
|
||||
'twitterUrl' => APP_SOCIAL_TWITTER,
|
||||
'discordUrl' => APP_SOCIAL_DISCORD,
|
||||
'githubUrl' => APP_SOCIAL_GITHUB_APPWRITE,
|
||||
'termsUrl' => APP_EMAIL_TERMS_URL,
|
||||
'privacyUrl' => APP_EMAIL_PRIVACY_URL,
|
||||
]);
|
||||
}
|
||||
|
||||
$queueForMails
|
||||
->setSubject($subject)
|
||||
->setPreview($preview)
|
||||
->setBody($body)
|
||||
->setBodyTemplate($bodyTemplate)
|
||||
->setVariables($emailVariables)
|
||||
->setRecipient($user->getAttribute('email'))
|
||||
->trigger();
|
||||
break;
|
||||
}
|
||||
|
||||
$queueForEvents
|
||||
->setParam('userId', $user->getId())
|
||||
->setParam('challengeId', $challenge->getId());
|
||||
|
||||
$response->dynamic($challenge, Response::MODEL_MFA_CHALLENGE);
|
||||
});
|
||||
|
||||
App::put('/v1/account/mfa/challenge')
|
||||
->desc('Update MFA challenge (confirmation)')
|
||||
->groups(['api', 'account', 'mfa'])
|
||||
->label('scope', 'account')
|
||||
->label('event', 'users.[userId].sessions.[sessionId].create')
|
||||
->label('audits.event', 'challenges.update')
|
||||
->label('audits.resource', 'user/{response.userId}')
|
||||
->label('audits.userId', '{response.userId}')
|
||||
->label('sdk', [
|
||||
new Method(
|
||||
namespace: 'account',
|
||||
group: 'mfa',
|
||||
name: 'updateMfaChallenge',
|
||||
description: '/docs/references/account/update-mfa-challenge.md',
|
||||
auth: [AuthType::SESSION, AuthType::JWT],
|
||||
responses: [
|
||||
new SDKResponse(
|
||||
code: Response::STATUS_CODE_OK,
|
||||
model: Response::MODEL_SESSION,
|
||||
)
|
||||
],
|
||||
contentType: ContentType::JSON,
|
||||
deprecated: new Deprecated(
|
||||
since: '1.8.0',
|
||||
replaceWith: 'account.updateMFAChallenge',
|
||||
),
|
||||
),
|
||||
new Method(
|
||||
namespace: 'account',
|
||||
group: 'mfa',
|
||||
name: 'updateMFAChallenge',
|
||||
description: '/docs/references/account/update-mfa-challenge.md',
|
||||
auth: [AuthType::SESSION, AuthType::JWT],
|
||||
responses: [
|
||||
new SDKResponse(
|
||||
code: Response::STATUS_CODE_OK,
|
||||
model: Response::MODEL_SESSION,
|
||||
)
|
||||
],
|
||||
contentType: ContentType::JSON
|
||||
)
|
||||
])
|
||||
->label('abuse-limit', 10)
|
||||
->label('abuse-key', 'url:{url},challengeId:{param-challengeId}')
|
||||
->param('challengeId', '', new Text(256), 'ID of the challenge.')
|
||||
->param('otp', '', new Text(256), 'Valid verification token.')
|
||||
->inject('project')
|
||||
->inject('response')
|
||||
->inject('user')
|
||||
->inject('session')
|
||||
->inject('dbForProject')
|
||||
->inject('queueForEvents')
|
||||
->action(function (string $challengeId, string $otp, Document $project, Response $response, Document $user, Document $session, Database $dbForProject, Event $queueForEvents) {
|
||||
|
||||
$challenge = $dbForProject->getDocument('challenges', $challengeId);
|
||||
|
||||
if ($challenge->isEmpty()) {
|
||||
throw new Exception(Exception::USER_INVALID_TOKEN);
|
||||
}
|
||||
|
||||
$type = $challenge->getAttribute('type');
|
||||
|
||||
$recoveryCodeChallenge = function (Document $challenge, Document $user, string $otp) use ($dbForProject) {
|
||||
if (
|
||||
$challenge->isSet('type') &&
|
||||
$challenge->getAttribute('type') === \strtolower(Type::RECOVERY_CODE)
|
||||
) {
|
||||
$mfaRecoveryCodes = $user->getAttribute('mfaRecoveryCodes', []);
|
||||
if (in_array($otp, $mfaRecoveryCodes)) {
|
||||
$mfaRecoveryCodes = array_diff($mfaRecoveryCodes, [$otp]);
|
||||
$mfaRecoveryCodes = array_values($mfaRecoveryCodes);
|
||||
$user->setAttribute('mfaRecoveryCodes', $mfaRecoveryCodes);
|
||||
$dbForProject->updateDocument('users', $user->getId(), $user);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
return false;
|
||||
};
|
||||
|
||||
$success = (match ($type) {
|
||||
Type::TOTP => Challenge\TOTP::challenge($challenge, $user, $otp),
|
||||
Type::PHONE => Challenge\Phone::challenge($challenge, $user, $otp),
|
||||
Type::EMAIL => Challenge\Email::challenge($challenge, $user, $otp),
|
||||
\strtolower(Type::RECOVERY_CODE) => $recoveryCodeChallenge($challenge, $user, $otp),
|
||||
default => false
|
||||
});
|
||||
|
||||
if (!$success) {
|
||||
throw new Exception(Exception::USER_INVALID_TOKEN);
|
||||
}
|
||||
|
||||
$dbForProject->deleteDocument('challenges', $challengeId);
|
||||
$dbForProject->purgeCachedDocument('users', $user->getId());
|
||||
|
||||
$factors = $session->getAttribute('factors', []);
|
||||
$factors[] = $type;
|
||||
$factors = \array_values(\array_unique($factors));
|
||||
|
||||
$session
|
||||
->setAttribute('factors', $factors)
|
||||
->setAttribute('mfaUpdatedAt', DateTime::now());
|
||||
|
||||
$dbForProject->updateDocument('sessions', $session->getId(), $session);
|
||||
|
||||
$queueForEvents
|
||||
->setParam('userId', $user->getId())
|
||||
->setParam('sessionId', $session->getId());
|
||||
|
||||
$response->dynamic($session, Response::MODEL_SESSION);
|
||||
});
|
||||
|
||||
App::post('/v1/account/targets/push')
|
||||
->desc('Create push target')
|
||||
->groups(['api', 'account'])
|
||||
|
||||
@@ -86,10 +86,11 @@ App::post('/v1/storage/buckets')
|
||||
->param('compression', Compression::NONE, new WhiteList([Compression::NONE, Compression::GZIP, Compression::ZSTD], true), 'Compression algorithm choosen for compression. Can be one of ' . Compression::NONE . ', [' . Compression::GZIP . '](https://en.wikipedia.org/wiki/Gzip), or [' . Compression::ZSTD . '](https://en.wikipedia.org/wiki/Zstd), For file size above ' . Storage::human(APP_STORAGE_READ_BUFFER, 0) . ' compression is skipped even if it\'s enabled', true)
|
||||
->param('encryption', true, new Boolean(true), 'Is encryption enabled? For file size above ' . Storage::human(APP_STORAGE_READ_BUFFER, 0) . ' encryption is skipped even if it\'s enabled', true)
|
||||
->param('antivirus', true, new Boolean(true), 'Is virus scanning enabled? For file size above ' . Storage::human(APP_LIMIT_ANTIVIRUS, 0) . ' AntiVirus scanning is skipped even if it\'s enabled', true)
|
||||
->param('transformations', true, new Boolean(true), 'Are image transformations enabled?', true)
|
||||
->inject('response')
|
||||
->inject('dbForProject')
|
||||
->inject('queueForEvents')
|
||||
->action(function (string $bucketId, string $name, ?array $permissions, bool $fileSecurity, bool $enabled, int $maximumFileSize, array $allowedFileExtensions, ?string $compression, ?bool $encryption, bool $antivirus, Response $response, Database $dbForProject, Event $queueForEvents) {
|
||||
->action(function (string $bucketId, string $name, ?array $permissions, bool $fileSecurity, bool $enabled, int $maximumFileSize, array $allowedFileExtensions, ?string $compression, ?bool $encryption, bool $antivirus, bool $transformations, Response $response, Database $dbForProject, Event $queueForEvents) {
|
||||
|
||||
$bucketId = $bucketId === 'unique()' ? ID::unique() : $bucketId;
|
||||
|
||||
@@ -142,6 +143,7 @@ App::post('/v1/storage/buckets')
|
||||
'compression' => $compression,
|
||||
'encryption' => $encryption,
|
||||
'antivirus' => $antivirus,
|
||||
'transformations' => $transformations,
|
||||
'search' => implode(' ', [$bucketId, $name]),
|
||||
]));
|
||||
|
||||
@@ -299,10 +301,11 @@ App::put('/v1/storage/buckets/:bucketId')
|
||||
->param('compression', Compression::NONE, new WhiteList([Compression::NONE, Compression::GZIP, Compression::ZSTD], true), 'Compression algorithm choosen for compression. Can be one of ' . Compression::NONE . ', [' . Compression::GZIP . '](https://en.wikipedia.org/wiki/Gzip), or [' . Compression::ZSTD . '](https://en.wikipedia.org/wiki/Zstd), For file size above ' . Storage::human(APP_STORAGE_READ_BUFFER, 0) . ' compression is skipped even if it\'s enabled', true)
|
||||
->param('encryption', true, new Boolean(true), 'Is encryption enabled? For file size above ' . Storage::human(APP_STORAGE_READ_BUFFER, 0) . ' encryption is skipped even if it\'s enabled', true)
|
||||
->param('antivirus', true, new Boolean(true), 'Is virus scanning enabled? For file size above ' . Storage::human(APP_LIMIT_ANTIVIRUS, 0) . ' AntiVirus scanning is skipped even if it\'s enabled', true)
|
||||
->param('transformations', true, new Boolean(true), 'Are image transformations enabled?', true)
|
||||
->inject('response')
|
||||
->inject('dbForProject')
|
||||
->inject('queueForEvents')
|
||||
->action(function (string $bucketId, string $name, ?array $permissions, bool $fileSecurity, bool $enabled, ?int $maximumFileSize, array $allowedFileExtensions, ?string $compression, ?bool $encryption, bool $antivirus, Response $response, Database $dbForProject, Event $queueForEvents) {
|
||||
->action(function (string $bucketId, string $name, ?array $permissions, bool $fileSecurity, bool $enabled, ?int $maximumFileSize, array $allowedFileExtensions, ?string $compression, ?bool $encryption, bool $antivirus, bool $transformations, Response $response, Database $dbForProject, Event $queueForEvents) {
|
||||
$bucket = $dbForProject->getDocument('buckets', $bucketId);
|
||||
|
||||
if ($bucket->isEmpty()) {
|
||||
@@ -316,6 +319,7 @@ App::put('/v1/storage/buckets/:bucketId')
|
||||
$encryption ??= $bucket->getAttribute('encryption', true);
|
||||
$antivirus ??= $bucket->getAttribute('antivirus', true);
|
||||
$compression ??= $bucket->getAttribute('compression', Compression::NONE);
|
||||
$transformations ??= $bucket->getAttribute('transformations', true);
|
||||
|
||||
// Map aggregate permissions into the multiple permissions they represent.
|
||||
$permissions = Permission::aggregate($permissions);
|
||||
@@ -329,7 +333,8 @@ App::put('/v1/storage/buckets/:bucketId')
|
||||
->setAttribute('enabled', $enabled)
|
||||
->setAttribute('encryption', $encryption)
|
||||
->setAttribute('compression', $compression)
|
||||
->setAttribute('antivirus', $antivirus));
|
||||
->setAttribute('antivirus', $antivirus)
|
||||
->setAttribute('transformations', $transformations));
|
||||
|
||||
$dbForProject->updateCollection('bucket_' . $bucket->getSequence(), $permissions, $fileSecurity);
|
||||
|
||||
@@ -984,6 +989,10 @@ App::get('/v1/storage/buckets/:bucketId/files/:fileId/preview')
|
||||
throw new Exception(Exception::STORAGE_BUCKET_NOT_FOUND);
|
||||
}
|
||||
|
||||
if (!$bucket->getAttribute('transformations', true) && !$isAPIKey && !$isPrivilegedUser) {
|
||||
throw new Exception(Exception::STORAGE_BUCKET_TRANSFORMATIONS_DISABLED);
|
||||
}
|
||||
|
||||
$isToken = !$resourceToken->isEmpty() && $resourceToken->getAttribute('bucketInternalId') === $bucket->getSequence();
|
||||
$fileSecurity = $bucket->getAttribute('fileSecurity', false);
|
||||
$validator = new Authorization(Database::PERMISSION_READ);
|
||||
@@ -1500,6 +1509,7 @@ App::get('/v1/storage/buckets/:bucketId/files/:fileId/push')
|
||||
}
|
||||
|
||||
$isInternal = $decoded['internal'] ?? false;
|
||||
$disposition = $decoded['disposition'] ?? 'inline';
|
||||
$dbForProject = $isInternal ? $dbForPlatform : $dbForProject;
|
||||
|
||||
$isAPIKey = Auth::isAppUser(Authorization::getRoles());
|
||||
@@ -1556,7 +1566,7 @@ App::get('/v1/storage/buckets/:bucketId/files/:fileId/push')
|
||||
->setContentType($contentType)
|
||||
->addHeader('Content-Security-Policy', 'script-src none;')
|
||||
->addHeader('X-Content-Type-Options', 'nosniff')
|
||||
->addHeader('Content-Disposition', 'inline; filename="' . $file->getAttribute('name', '') . '"')
|
||||
->addHeader('Content-Disposition', $disposition . '; filename="' . $file->getAttribute('name', '') . '"')
|
||||
->addHeader('Cache-Control', 'private, max-age=3888000') // 45 days
|
||||
->addHeader('X-Peak', \memory_get_peak_usage());
|
||||
|
||||
|
||||
@@ -5,6 +5,7 @@ use Appwrite\Event\Build;
|
||||
use Appwrite\Event\Delete;
|
||||
use Appwrite\Extend\Exception;
|
||||
use Appwrite\Network\Validator\Redirect;
|
||||
use Appwrite\Platform\Modules\Compute\Base as ComputeBase;
|
||||
use Appwrite\SDK\AuthType;
|
||||
use Appwrite\SDK\ContentType;
|
||||
use Appwrite\SDK\Method;
|
||||
@@ -14,9 +15,12 @@ use Appwrite\Utopia\Database\Validator\Queries\Installations;
|
||||
use Appwrite\Utopia\Request;
|
||||
use Appwrite\Utopia\Response;
|
||||
use Appwrite\Vcs\Comment;
|
||||
use Swoole\Coroutine\WaitGroup;
|
||||
use Utopia\App;
|
||||
use Utopia\CLI\Console;
|
||||
use Utopia\Config\Adapters\Dotenv as ConfigDotenv;
|
||||
use Utopia\Config\Config;
|
||||
use Utopia\Config\Exceptions\Parse;
|
||||
use Utopia\Database\Database;
|
||||
use Utopia\Database\DateTime;
|
||||
use Utopia\Database\Document;
|
||||
@@ -430,6 +434,8 @@ $createGitDeployments = function (GitHub $github, string $providerInstallationId
|
||||
}
|
||||
}
|
||||
|
||||
ComputeBase::updateEmptyManualRule($project, $resource, $deployment, $dbForPlatform);
|
||||
|
||||
if ($resource->getCollection() === 'sites' && !empty($latestCommentId) && !empty($previewRuleId)) {
|
||||
$retries = 0;
|
||||
$lockAcquired = false;
|
||||
@@ -963,6 +969,46 @@ App::post('/v1/vcs/github/installations/:installationId/detections')
|
||||
throw new Exception(Exception::FUNCTION_RUNTIME_NOT_DETECTED);
|
||||
}
|
||||
}
|
||||
|
||||
$wg = new WaitGroup();
|
||||
$envs = [];
|
||||
foreach ($files as $file) {
|
||||
if (!(\str_starts_with($file, '.env'))) {
|
||||
continue;
|
||||
}
|
||||
|
||||
$wg->add();
|
||||
go(function () use ($github, $owner, $repositoryName, $providerRootDirectory, $file, $wg, &$envs) {
|
||||
try {
|
||||
$contentResponse = $github->getRepositoryContent($owner, $repositoryName, \rtrim($providerRootDirectory, '/') . '/' . $file);
|
||||
$envFile = $contentResponse['content'] ?? '';
|
||||
|
||||
$configAdapter = new ConfigDotenv();
|
||||
try {
|
||||
$envObject = $configAdapter->parse($envFile);
|
||||
foreach ($envObject as $envName => $envValue) {
|
||||
$envs[$envName] = $envValue;
|
||||
}
|
||||
} catch (Parse $err) {
|
||||
// Silence error, so rest of endpoint can return
|
||||
}
|
||||
} finally {
|
||||
$wg->done();
|
||||
}
|
||||
});
|
||||
}
|
||||
$wg->wait();
|
||||
|
||||
$variables = [];
|
||||
foreach ($envs as $key => $value) {
|
||||
$variables[] = [
|
||||
'name' => $key,
|
||||
'value' => $value,
|
||||
];
|
||||
}
|
||||
|
||||
$output->setAttribute('variables', $variables);
|
||||
|
||||
$response->dynamic($output, $type === 'framework' ? Response::MODEL_DETECTION_FRAMEWORK : Response::MODEL_DETECTION_RUNTIME);
|
||||
});
|
||||
|
||||
@@ -1137,6 +1183,44 @@ App::get('/v1/vcs/github/installations/:installationId/providerRepositories')
|
||||
$repo['runtime'] = $runtimeWithVersion ?? '';
|
||||
}
|
||||
}
|
||||
|
||||
$wg = new WaitGroup();
|
||||
$envs = [];
|
||||
foreach ($files as $file) {
|
||||
if (!(\str_starts_with($file, '.env'))) {
|
||||
continue;
|
||||
}
|
||||
|
||||
$wg->add();
|
||||
go(function () use ($github, $repo, $file, $wg, &$envs) {
|
||||
try {
|
||||
$contentResponse = $github->getRepositoryContent($repo['organization'], $repo['name'], $file);
|
||||
$envFile = $contentResponse['content'] ?? '';
|
||||
|
||||
$configAdapter = new ConfigDotenv();
|
||||
try {
|
||||
$envObject = $configAdapter->parse($envFile);
|
||||
foreach ($envObject as $envName => $envValue) {
|
||||
$envs[$envName] = $envValue;
|
||||
}
|
||||
} catch (Parse) {
|
||||
// Silence error, so rest of endpoint can return
|
||||
}
|
||||
} finally {
|
||||
$wg->done();
|
||||
}
|
||||
});
|
||||
}
|
||||
$wg->wait();
|
||||
|
||||
$repo['variables'] = [];
|
||||
foreach ($envs as $key => $value) {
|
||||
$repo['variables'][] = [
|
||||
'name' => $key,
|
||||
'value' => $value,
|
||||
];
|
||||
}
|
||||
|
||||
return $repo;
|
||||
};
|
||||
}, $repos));
|
||||
|
||||
@@ -613,6 +613,10 @@ App::init()
|
||||
throw new Exception(Exception::STORAGE_BUCKET_NOT_FOUND);
|
||||
}
|
||||
|
||||
if (!$bucket->getAttribute('transformations', true) && !$isAppUser && !$isPrivilegedUser) {
|
||||
throw new Exception(Exception::STORAGE_BUCKET_TRANSFORMATIONS_DISABLED);
|
||||
}
|
||||
|
||||
$fileSecurity = $bucket->getAttribute('fileSecurity', false);
|
||||
$validator = new Authorization(Database::PERMISSION_READ);
|
||||
$valid = $validator->isValid($bucket->getRead());
|
||||
|
||||
+39
-36
@@ -1,42 +1,45 @@
|
||||
<?php
|
||||
|
||||
use Utopia\Config\Adapters\PHP;
|
||||
use Utopia\Config\Config;
|
||||
|
||||
require_once __DIR__ . '/../config/storage/resource_limits.php';
|
||||
|
||||
Config::load('template-runtimes', __DIR__ . '/../config/template-runtimes.php');
|
||||
Config::load('events', __DIR__ . '/../config/events.php');
|
||||
Config::load('auth', __DIR__ . '/../config/auth.php');
|
||||
Config::load('apis', __DIR__ . '/../config/apis.php'); // List of APIs
|
||||
Config::load('errors', __DIR__ . '/../config/errors.php');
|
||||
Config::load('oAuthProviders', __DIR__ . '/../config/oAuthProviders.php');
|
||||
Config::load('platforms', __DIR__ . '/../config/platforms.php');
|
||||
Config::load('console', __DIR__ . '/../config/console.php');
|
||||
Config::load('collections', __DIR__ . '/../config/collections.php');
|
||||
Config::load('frameworks', __DIR__ . '/../config/frameworks.php');
|
||||
Config::load('runtimes', __DIR__ . '/../config/runtimes.php');
|
||||
Config::load('runtimes-v2', __DIR__ . '/../config/runtimes-v2.php');
|
||||
Config::load('usage', __DIR__ . '/../config/usage.php');
|
||||
Config::load('roles', __DIR__ . '/../config/roles.php'); // User roles and scopes
|
||||
Config::load('scopes', __DIR__ . '/../config/scopes.php'); // User roles and scopes
|
||||
Config::load('services', __DIR__ . '/../config/services.php'); // List of services
|
||||
Config::load('variables', __DIR__ . '/../config/variables.php'); // List of env variables
|
||||
Config::load('regions', __DIR__ . '/../config/regions.php'); // List of available regions
|
||||
Config::load('avatar-browsers', __DIR__ . '/../config/avatars/browsers.php');
|
||||
Config::load('avatar-credit-cards', __DIR__ . '/../config/avatars/credit-cards.php');
|
||||
Config::load('avatar-flags', __DIR__ . '/../config/avatars/flags.php');
|
||||
Config::load('locale-codes', __DIR__ . '/../config/locale/codes.php');
|
||||
Config::load('locale-currencies', __DIR__ . '/../config/locale/currencies.php');
|
||||
Config::load('locale-eu', __DIR__ . '/../config/locale/eu.php');
|
||||
Config::load('locale-languages', __DIR__ . '/../config/locale/languages.php');
|
||||
Config::load('locale-phones', __DIR__ . '/../config/locale/phones.php');
|
||||
Config::load('locale-countries', __DIR__ . '/../config/locale/countries.php');
|
||||
Config::load('locale-continents', __DIR__ . '/../config/locale/continents.php');
|
||||
Config::load('locale-templates', __DIR__ . '/../config/locale/templates.php');
|
||||
Config::load('storage-logos', __DIR__ . '/../config/storage/logos.php');
|
||||
Config::load('storage-mimes', __DIR__ . '/../config/storage/mimes.php');
|
||||
Config::load('storage-inputs', __DIR__ . '/../config/storage/inputs.php');
|
||||
Config::load('storage-outputs', __DIR__ . '/../config/storage/outputs.php');
|
||||
Config::load('specifications', __DIR__ . '/../config/specifications.php');
|
||||
Config::load('templates-function', __DIR__ . '/../config/templates/function.php');
|
||||
Config::load('templates-site', __DIR__ . '/../config/templates/site.php');
|
||||
$configAdapter = new PHP();
|
||||
|
||||
Config::load('template-runtimes', __DIR__ . '/../config/template-runtimes.php', $configAdapter);
|
||||
Config::load('events', __DIR__ . '/../config/events.php', $configAdapter);
|
||||
Config::load('auth', __DIR__ . '/../config/auth.php', $configAdapter);
|
||||
Config::load('apis', __DIR__ . '/../config/apis.php', $configAdapter); // List of APIs
|
||||
Config::load('errors', __DIR__ . '/../config/errors.php', $configAdapter);
|
||||
Config::load('oAuthProviders', __DIR__ . '/../config/oAuthProviders.php', $configAdapter);
|
||||
Config::load('platforms', __DIR__ . '/../config/platforms.php', $configAdapter);
|
||||
Config::load('console', __DIR__ . '/../config/console.php', $configAdapter);
|
||||
Config::load('collections', __DIR__ . '/../config/collections.php', $configAdapter);
|
||||
Config::load('frameworks', __DIR__ . '/../config/frameworks.php', $configAdapter);
|
||||
Config::load('runtimes', __DIR__ . '/../config/runtimes.php', $configAdapter);
|
||||
Config::load('runtimes-v2', __DIR__ . '/../config/runtimes-v2.php', $configAdapter);
|
||||
Config::load('usage', __DIR__ . '/../config/usage.php', $configAdapter);
|
||||
Config::load('roles', __DIR__ . '/../config/roles.php', $configAdapter); // User roles and scopes
|
||||
Config::load('scopes', __DIR__ . '/../config/scopes.php', $configAdapter); // User roles and scopes
|
||||
Config::load('services', __DIR__ . '/../config/services.php', $configAdapter); // List of services
|
||||
Config::load('variables', __DIR__ . '/../config/variables.php', $configAdapter); // List of env variables
|
||||
Config::load('regions', __DIR__ . '/../config/regions.php', $configAdapter); // List of available regions
|
||||
Config::load('avatar-browsers', __DIR__ . '/../config/avatars/browsers.php', $configAdapter);
|
||||
Config::load('avatar-credit-cards', __DIR__ . '/../config/avatars/credit-cards.php', $configAdapter);
|
||||
Config::load('avatar-flags', __DIR__ . '/../config/avatars/flags.php', $configAdapter);
|
||||
Config::load('locale-codes', __DIR__ . '/../config/locale/codes.php', $configAdapter);
|
||||
Config::load('locale-currencies', __DIR__ . '/../config/locale/currencies.php', $configAdapter);
|
||||
Config::load('locale-eu', __DIR__ . '/../config/locale/eu.php', $configAdapter);
|
||||
Config::load('locale-languages', __DIR__ . '/../config/locale/languages.php', $configAdapter);
|
||||
Config::load('locale-phones', __DIR__ . '/../config/locale/phones.php', $configAdapter);
|
||||
Config::load('locale-countries', __DIR__ . '/../config/locale/countries.php', $configAdapter);
|
||||
Config::load('locale-continents', __DIR__ . '/../config/locale/continents.php', $configAdapter);
|
||||
Config::load('locale-templates', __DIR__ . '/../config/locale/templates.php', $configAdapter);
|
||||
Config::load('storage-logos', __DIR__ . '/../config/storage/logos.php', $configAdapter);
|
||||
Config::load('storage-mimes', __DIR__ . '/../config/storage/mimes.php', $configAdapter);
|
||||
Config::load('storage-inputs', __DIR__ . '/../config/storage/inputs.php', $configAdapter);
|
||||
Config::load('storage-outputs', __DIR__ . '/../config/storage/outputs.php', $configAdapter);
|
||||
Config::load('specifications', __DIR__ . '/../config/specifications.php', $configAdapter);
|
||||
Config::load('templates-function', __DIR__ . '/../config/templates/function.php', $configAdapter);
|
||||
Config::load('templates-site', __DIR__ . '/../config/templates/site.php', $configAdapter);
|
||||
|
||||
@@ -859,7 +859,7 @@ $image = $this->getParam('image', '');
|
||||
- _APP_ASSISTANT_OPENAI_API_KEY
|
||||
|
||||
appwrite-browser:
|
||||
image: appwrite/browser:0.3.1
|
||||
image: appwrite/browser:0.3.2
|
||||
container_name: appwrite-browser
|
||||
<<: *x-logging
|
||||
restart: unless-stopped
|
||||
|
||||
+2
-2
@@ -50,7 +50,7 @@
|
||||
"utopia-php/audit": "1.*",
|
||||
"utopia-php/cache": "0.13.*",
|
||||
"utopia-php/cli": "0.15.*",
|
||||
"utopia-php/config": "0.2.*",
|
||||
"utopia-php/config": "1.*.*",
|
||||
"utopia-php/database": "3.*",
|
||||
"utopia-php/detector": "0.2.*",
|
||||
"utopia-php/domains": "0.9.*",
|
||||
@@ -63,7 +63,7 @@
|
||||
"utopia-php/locale": "0.8.*",
|
||||
"utopia-php/logger": "0.6.*",
|
||||
"utopia-php/messaging": "0.20.*",
|
||||
"utopia-php/migration": "1.*",
|
||||
"utopia-php/migration": "1.3.*",
|
||||
"utopia-php/orchestration": "0.9.*",
|
||||
"utopia-php/platform": "0.7.*",
|
||||
"utopia-php/pools": "0.8.*",
|
||||
|
||||
Generated
+67
-71
@@ -4,7 +4,7 @@
|
||||
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
||||
"This file is @generated automatically"
|
||||
],
|
||||
"content-hash": "ad28b7155175986191bd19bbcd13d623",
|
||||
"content-hash": "1d3d4b19a835b3be79a63146fcdd389b",
|
||||
"packages": [
|
||||
{
|
||||
"name": "adhocore/jwt",
|
||||
@@ -283,16 +283,16 @@
|
||||
},
|
||||
{
|
||||
"name": "brick/math",
|
||||
"version": "0.14.0",
|
||||
"version": "0.14.1",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/brick/math.git",
|
||||
"reference": "113a8ee2656b882d4c3164fa31aa6e12cbb7aaa2"
|
||||
"reference": "f05858549e5f9d7bb45875a75583240a38a281d0"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/brick/math/zipball/113a8ee2656b882d4c3164fa31aa6e12cbb7aaa2",
|
||||
"reference": "113a8ee2656b882d4c3164fa31aa6e12cbb7aaa2",
|
||||
"url": "https://api.github.com/repos/brick/math/zipball/f05858549e5f9d7bb45875a75583240a38a281d0",
|
||||
"reference": "f05858549e5f9d7bb45875a75583240a38a281d0",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@@ -331,7 +331,7 @@
|
||||
],
|
||||
"support": {
|
||||
"issues": "https://github.com/brick/math/issues",
|
||||
"source": "https://github.com/brick/math/tree/0.14.0"
|
||||
"source": "https://github.com/brick/math/tree/0.14.1"
|
||||
},
|
||||
"funding": [
|
||||
{
|
||||
@@ -339,7 +339,7 @@
|
||||
"type": "github"
|
||||
}
|
||||
],
|
||||
"time": "2025-08-29T12:40:03+00:00"
|
||||
"time": "2025-11-24T14:40:29+00:00"
|
||||
},
|
||||
{
|
||||
"name": "chillerlan/php-qrcode",
|
||||
@@ -961,16 +961,16 @@
|
||||
},
|
||||
{
|
||||
"name": "mongodb/mongodb",
|
||||
"version": "2.1.1",
|
||||
"version": "2.1.2",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/mongodb/mongo-php-library.git",
|
||||
"reference": "f399d24905dd42f97dfe0af9706129743ef247ac"
|
||||
"reference": "0a2472ba9cbb932f7e43a8770aedb2fc30612a67"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/mongodb/mongo-php-library/zipball/f399d24905dd42f97dfe0af9706129743ef247ac",
|
||||
"reference": "f399d24905dd42f97dfe0af9706129743ef247ac",
|
||||
"url": "https://api.github.com/repos/mongodb/mongo-php-library/zipball/0a2472ba9cbb932f7e43a8770aedb2fc30612a67",
|
||||
"reference": "0a2472ba9cbb932f7e43a8770aedb2fc30612a67",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@@ -986,7 +986,7 @@
|
||||
"require-dev": {
|
||||
"doctrine/coding-standard": "^12.0",
|
||||
"phpunit/phpunit": "^10.5.35",
|
||||
"rector/rector": "^1.2",
|
||||
"rector/rector": "^2.1.4",
|
||||
"squizlabs/php_codesniffer": "^3.7",
|
||||
"vimeo/psalm": "6.5.*"
|
||||
},
|
||||
@@ -1032,9 +1032,9 @@
|
||||
],
|
||||
"support": {
|
||||
"issues": "https://github.com/mongodb/mongo-php-library/issues",
|
||||
"source": "https://github.com/mongodb/mongo-php-library/tree/2.1.1"
|
||||
"source": "https://github.com/mongodb/mongo-php-library/tree/2.1.2"
|
||||
},
|
||||
"time": "2025-08-13T20:50:05+00:00"
|
||||
"time": "2025-10-06T12:12:40+00:00"
|
||||
},
|
||||
{
|
||||
"name": "mustangostang/spyc",
|
||||
@@ -1763,16 +1763,16 @@
|
||||
},
|
||||
{
|
||||
"name": "php-amqplib/php-amqplib",
|
||||
"version": "v3.7.3",
|
||||
"version": "v3.7.4",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/php-amqplib/php-amqplib.git",
|
||||
"reference": "9f50fe69a9f1a19e2cb25596a354d705de36fe59"
|
||||
"reference": "381b6f7c600e0e0c7463cdd7f7a1a3bc6268e5fd"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/php-amqplib/php-amqplib/zipball/9f50fe69a9f1a19e2cb25596a354d705de36fe59",
|
||||
"reference": "9f50fe69a9f1a19e2cb25596a354d705de36fe59",
|
||||
"url": "https://api.github.com/repos/php-amqplib/php-amqplib/zipball/381b6f7c600e0e0c7463cdd7f7a1a3bc6268e5fd",
|
||||
"reference": "381b6f7c600e0e0c7463cdd7f7a1a3bc6268e5fd",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@@ -1838,9 +1838,9 @@
|
||||
],
|
||||
"support": {
|
||||
"issues": "https://github.com/php-amqplib/php-amqplib/issues",
|
||||
"source": "https://github.com/php-amqplib/php-amqplib/tree/v3.7.3"
|
||||
"source": "https://github.com/php-amqplib/php-amqplib/tree/v3.7.4"
|
||||
},
|
||||
"time": "2025-02-18T20:11:13+00:00"
|
||||
"time": "2025-11-23T17:00:56+00:00"
|
||||
},
|
||||
{
|
||||
"name": "php-http/discovery",
|
||||
@@ -3745,24 +3745,26 @@
|
||||
},
|
||||
{
|
||||
"name": "utopia-php/config",
|
||||
"version": "0.2.2",
|
||||
"version": "1.0.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/utopia-php/config.git",
|
||||
"reference": "a3d7bc0312d7150d5e04b1362dc34b2b136908cc"
|
||||
"reference": "6672bf6c1b54ba608593570cbef31bef75f17dd8"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/utopia-php/config/zipball/a3d7bc0312d7150d5e04b1362dc34b2b136908cc",
|
||||
"reference": "a3d7bc0312d7150d5e04b1362dc34b2b136908cc",
|
||||
"url": "https://api.github.com/repos/utopia-php/config/zipball/6672bf6c1b54ba608593570cbef31bef75f17dd8",
|
||||
"reference": "6672bf6c1b54ba608593570cbef31bef75f17dd8",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": ">=7.3"
|
||||
"ext-yaml": "*",
|
||||
"php": ">=8.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"phpunit/phpunit": "^9.3",
|
||||
"vimeo/psalm": "4.0.1"
|
||||
"laravel/pint": "1.2.*",
|
||||
"phpstan/phpstan": "^2.0",
|
||||
"phpunit/phpunit": "^9.3"
|
||||
},
|
||||
"type": "library",
|
||||
"autoload": {
|
||||
@@ -3774,12 +3776,6 @@
|
||||
"license": [
|
||||
"MIT"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Eldad Fux",
|
||||
"email": "eldad@appwrite.io"
|
||||
}
|
||||
],
|
||||
"description": "A simple Config library to managing application config variables",
|
||||
"keywords": [
|
||||
"config",
|
||||
@@ -3790,9 +3786,9 @@
|
||||
],
|
||||
"support": {
|
||||
"issues": "https://github.com/utopia-php/config/issues",
|
||||
"source": "https://github.com/utopia-php/config/tree/0.2.2"
|
||||
"source": "https://github.com/utopia-php/config/tree/1.0.0"
|
||||
},
|
||||
"time": "2020-10-24T09:49:09+00:00"
|
||||
"time": "2025-11-18T17:02:00+00:00"
|
||||
},
|
||||
{
|
||||
"name": "utopia-php/console",
|
||||
@@ -3844,16 +3840,16 @@
|
||||
},
|
||||
{
|
||||
"name": "utopia-php/database",
|
||||
"version": "3.4.0",
|
||||
"version": "3.5.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/utopia-php/database.git",
|
||||
"reference": "e10b4faa4f3a3ef30a5f6d76acdb605469924aec"
|
||||
"reference": "5da71b65a6123ce2e78795522b05b7458aabfbd7"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/utopia-php/database/zipball/e10b4faa4f3a3ef30a5f6d76acdb605469924aec",
|
||||
"reference": "e10b4faa4f3a3ef30a5f6d76acdb605469924aec",
|
||||
"url": "https://api.github.com/repos/utopia-php/database/zipball/5da71b65a6123ce2e78795522b05b7458aabfbd7",
|
||||
"reference": "5da71b65a6123ce2e78795522b05b7458aabfbd7",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@@ -3896,22 +3892,22 @@
|
||||
],
|
||||
"support": {
|
||||
"issues": "https://github.com/utopia-php/database/issues",
|
||||
"source": "https://github.com/utopia-php/database/tree/3.4.0"
|
||||
"source": "https://github.com/utopia-php/database/tree/3.5.0"
|
||||
},
|
||||
"time": "2025-11-13T06:34:20+00:00"
|
||||
"time": "2025-11-18T08:11:01+00:00"
|
||||
},
|
||||
{
|
||||
"name": "utopia-php/detector",
|
||||
"version": "0.2.2",
|
||||
"version": "0.2.3",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/utopia-php/detector.git",
|
||||
"reference": "9a41be5f21efe2d865de79b08dff94fff85ce5e9"
|
||||
"reference": "c1f49b3e82250c3256ffba48aa9737d6c17a243a"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/utopia-php/detector/zipball/9a41be5f21efe2d865de79b08dff94fff85ce5e9",
|
||||
"reference": "9a41be5f21efe2d865de79b08dff94fff85ce5e9",
|
||||
"url": "https://api.github.com/repos/utopia-php/detector/zipball/c1f49b3e82250c3256ffba48aa9737d6c17a243a",
|
||||
"reference": "c1f49b3e82250c3256ffba48aa9737d6c17a243a",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@@ -3941,9 +3937,9 @@
|
||||
],
|
||||
"support": {
|
||||
"issues": "https://github.com/utopia-php/detector/issues",
|
||||
"source": "https://github.com/utopia-php/detector/tree/0.2.2"
|
||||
"source": "https://github.com/utopia-php/detector/tree/0.2.3"
|
||||
},
|
||||
"time": "2025-10-31T12:43:31+00:00"
|
||||
"time": "2025-11-24T15:52:51+00:00"
|
||||
},
|
||||
{
|
||||
"name": "utopia-php/dns",
|
||||
@@ -4212,16 +4208,16 @@
|
||||
},
|
||||
{
|
||||
"name": "utopia-php/framework",
|
||||
"version": "0.33.28",
|
||||
"version": "0.33.30",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/utopia-php/http.git",
|
||||
"reference": "5aaa94d406577b0059ad28c78022606890dc6de0"
|
||||
"reference": "07cf699a7c47bd1a03b4da1812f1719a66b3c924"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/utopia-php/http/zipball/5aaa94d406577b0059ad28c78022606890dc6de0",
|
||||
"reference": "5aaa94d406577b0059ad28c78022606890dc6de0",
|
||||
"url": "https://api.github.com/repos/utopia-php/http/zipball/07cf699a7c47bd1a03b4da1812f1719a66b3c924",
|
||||
"reference": "07cf699a7c47bd1a03b4da1812f1719a66b3c924",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@@ -4253,9 +4249,9 @@
|
||||
],
|
||||
"support": {
|
||||
"issues": "https://github.com/utopia-php/http/issues",
|
||||
"source": "https://github.com/utopia-php/http/tree/0.33.28"
|
||||
"source": "https://github.com/utopia-php/http/tree/0.33.30"
|
||||
},
|
||||
"time": "2025-09-25T10:44:24+00:00"
|
||||
"time": "2025-11-18T12:18:00+00:00"
|
||||
},
|
||||
{
|
||||
"name": "utopia-php/image",
|
||||
@@ -4460,16 +4456,16 @@
|
||||
},
|
||||
{
|
||||
"name": "utopia-php/migration",
|
||||
"version": "1.3.3",
|
||||
"version": "1.3.6",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/utopia-php/migration.git",
|
||||
"reference": "731b3a963c58c30e0b2368695d57a7e8fcb7455c"
|
||||
"reference": "4abe70cc242bbffebfa377e4126ee2a4a1c9ef7e"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/utopia-php/migration/zipball/731b3a963c58c30e0b2368695d57a7e8fcb7455c",
|
||||
"reference": "731b3a963c58c30e0b2368695d57a7e8fcb7455c",
|
||||
"url": "https://api.github.com/repos/utopia-php/migration/zipball/4abe70cc242bbffebfa377e4126ee2a4a1c9ef7e",
|
||||
"reference": "4abe70cc242bbffebfa377e4126ee2a4a1c9ef7e",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@@ -4509,9 +4505,9 @@
|
||||
],
|
||||
"support": {
|
||||
"issues": "https://github.com/utopia-php/migration/issues",
|
||||
"source": "https://github.com/utopia-php/migration/tree/1.3.3"
|
||||
"source": "https://github.com/utopia-php/migration/tree/1.3.6"
|
||||
},
|
||||
"time": "2025-10-28T04:02:08+00:00"
|
||||
"time": "2025-11-25T11:36:57+00:00"
|
||||
},
|
||||
{
|
||||
"name": "utopia-php/mongo",
|
||||
@@ -5383,16 +5379,16 @@
|
||||
"packages-dev": [
|
||||
{
|
||||
"name": "appwrite/sdk-generator",
|
||||
"version": "1.5.4",
|
||||
"version": "1.5.8",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/appwrite/sdk-generator.git",
|
||||
"reference": "958947b6483a79e11c3812f23bb3056199fa4105"
|
||||
"reference": "05367bc4a4c3e020e9aca114ae875b626ce8fc55"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/appwrite/sdk-generator/zipball/958947b6483a79e11c3812f23bb3056199fa4105",
|
||||
"reference": "958947b6483a79e11c3812f23bb3056199fa4105",
|
||||
"url": "https://api.github.com/repos/appwrite/sdk-generator/zipball/05367bc4a4c3e020e9aca114ae875b626ce8fc55",
|
||||
"reference": "05367bc4a4c3e020e9aca114ae875b626ce8fc55",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@@ -5428,9 +5424,9 @@
|
||||
"description": "Appwrite PHP library for generating API SDKs for multiple programming languages and platforms",
|
||||
"support": {
|
||||
"issues": "https://github.com/appwrite/sdk-generator/issues",
|
||||
"source": "https://github.com/appwrite/sdk-generator/tree/1.5.4"
|
||||
"source": "https://github.com/appwrite/sdk-generator/tree/1.5.8"
|
||||
},
|
||||
"time": "2025-11-12T12:43:42+00:00"
|
||||
"time": "2025-11-20T11:00:34+00:00"
|
||||
},
|
||||
{
|
||||
"name": "doctrine/annotations",
|
||||
@@ -8718,16 +8714,16 @@
|
||||
},
|
||||
{
|
||||
"name": "theseer/tokenizer",
|
||||
"version": "1.2.3",
|
||||
"version": "1.3.1",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/theseer/tokenizer.git",
|
||||
"reference": "737eda637ed5e28c3413cb1ebe8bb52cbf1ca7a2"
|
||||
"reference": "b7489ce515e168639d17feec34b8847c326b0b3c"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/theseer/tokenizer/zipball/737eda637ed5e28c3413cb1ebe8bb52cbf1ca7a2",
|
||||
"reference": "737eda637ed5e28c3413cb1ebe8bb52cbf1ca7a2",
|
||||
"url": "https://api.github.com/repos/theseer/tokenizer/zipball/b7489ce515e168639d17feec34b8847c326b0b3c",
|
||||
"reference": "b7489ce515e168639d17feec34b8847c326b0b3c",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@@ -8756,7 +8752,7 @@
|
||||
"description": "A small library for converting tokenized PHP source code into XML and potentially other formats",
|
||||
"support": {
|
||||
"issues": "https://github.com/theseer/tokenizer/issues",
|
||||
"source": "https://github.com/theseer/tokenizer/tree/1.2.3"
|
||||
"source": "https://github.com/theseer/tokenizer/tree/1.3.1"
|
||||
},
|
||||
"funding": [
|
||||
{
|
||||
@@ -8764,7 +8760,7 @@
|
||||
"type": "github"
|
||||
}
|
||||
],
|
||||
"time": "2024-03-03T12:36:25+00:00"
|
||||
"time": "2025-11-17T20:03:58+00:00"
|
||||
},
|
||||
{
|
||||
"name": "twig/twig",
|
||||
|
||||
@@ -1,7 +0,0 @@
|
||||
services:
|
||||
appwrite:
|
||||
# volumes:
|
||||
# - ~/.ssh:/root/.ssh
|
||||
environment:
|
||||
- GH_TOKEN=
|
||||
- GIT_EMAIL=
|
||||
+1
-1
@@ -958,7 +958,7 @@ services:
|
||||
|
||||
appwrite-browser:
|
||||
container_name: appwrite-browser
|
||||
image: appwrite/browser:0.3.1
|
||||
image: appwrite/browser:0.3.2
|
||||
networks:
|
||||
- appwrite
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
POST /v1/account/mfa/challenge HTTP/1.1
|
||||
POST /v1/account/mfa/challenges HTTP/1.1
|
||||
Host: cloud.appwrite.io
|
||||
Content-Type: application/json
|
||||
X-Appwrite-Response-Format: 1.5.0
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
POST /v1/account/mfa/challenge HTTP/1.1
|
||||
POST /v1/account/mfa/challenges HTTP/1.1
|
||||
Host: <REGION>.cloud.appwrite.io
|
||||
Content-Type: application/json
|
||||
X-Appwrite-Response-Format: 1.6.0
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
POST /v1/account/mfa/challenge HTTP/1.1
|
||||
POST /v1/account/mfa/challenges HTTP/1.1
|
||||
Host: cloud.appwrite.io
|
||||
Content-Type: application/json
|
||||
X-Appwrite-Response-Format: 1.5.0
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
PUT /v1/account/mfa/challenge HTTP/1.1
|
||||
PUT /v1/account/mfa/challenges HTTP/1.1
|
||||
Host: cloud.appwrite.io
|
||||
Content-Type: application/json
|
||||
X-Appwrite-Response-Format: 1.5.0
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
PUT /v1/account/mfa/challenge HTTP/1.1
|
||||
PUT /v1/account/mfa/challenges HTTP/1.1
|
||||
Host: <REGION>.cloud.appwrite.io
|
||||
Content-Type: application/json
|
||||
X-Appwrite-Response-Format: 1.6.0
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
POST /v1/account/mfa/challenge HTTP/1.1
|
||||
POST /v1/account/mfa/challenges HTTP/1.1
|
||||
Host: cloud.appwrite.io
|
||||
Content-Type: application/json
|
||||
X-Appwrite-Response-Format: 1.5.0
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
POST /v1/account/mfa/challenge HTTP/1.1
|
||||
POST /v1/account/mfa/challenges HTTP/1.1
|
||||
Host: <REGION>.cloud.appwrite.io
|
||||
Content-Type: application/json
|
||||
X-Appwrite-Response-Format: 1.6.0
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
POST /v1/account/mfa/challenge HTTP/1.1
|
||||
POST /v1/account/mfa/challenges HTTP/1.1
|
||||
Host: cloud.appwrite.io
|
||||
Content-Type: application/json
|
||||
X-Appwrite-Response-Format: 1.5.0
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
PUT /v1/account/mfa/challenge HTTP/1.1
|
||||
PUT /v1/account/mfa/challenges HTTP/1.1
|
||||
Host: cloud.appwrite.io
|
||||
Content-Type: application/json
|
||||
X-Appwrite-Response-Format: 1.5.0
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
PUT /v1/account/mfa/challenge HTTP/1.1
|
||||
PUT /v1/account/mfa/challenges HTTP/1.1
|
||||
Host: <REGION>.cloud.appwrite.io
|
||||
Content-Type: application/json
|
||||
X-Appwrite-Response-Format: 1.6.0
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
POST /v1/account/mfa/challenge HTTP/1.1
|
||||
POST /v1/account/mfa/challenges HTTP/1.1
|
||||
Host: cloud.appwrite.io
|
||||
Content-Type: application/json
|
||||
X-Appwrite-Response-Format: 1.6.0
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
PUT /v1/account/mfa/challenge HTTP/1.1
|
||||
PUT /v1/account/mfa/challenges HTTP/1.1
|
||||
Host: cloud.appwrite.io
|
||||
Content-Type: application/json
|
||||
X-Appwrite-Response-Format: 1.6.0
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
POST /v1/account/mfa/challenge HTTP/1.1
|
||||
POST /v1/account/mfa/challenges HTTP/1.1
|
||||
Host: cloud.appwrite.io
|
||||
Content-Type: application/json
|
||||
X-Appwrite-Response-Format: 1.6.0
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
PUT /v1/account/mfa/challenge HTTP/1.1
|
||||
PUT /v1/account/mfa/challenges HTTP/1.1
|
||||
Host: cloud.appwrite.io
|
||||
Content-Type: application/json
|
||||
X-Appwrite-Response-Format: 1.6.0
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
POST /v1/account/mfa/challenge HTTP/1.1
|
||||
POST /v1/account/mfa/challenges HTTP/1.1
|
||||
Host: cloud.appwrite.io
|
||||
Content-Type: application/json
|
||||
X-Appwrite-Response-Format: 1.7.0
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
PUT /v1/account/mfa/challenge HTTP/1.1
|
||||
PUT /v1/account/mfa/challenges HTTP/1.1
|
||||
Host: cloud.appwrite.io
|
||||
Content-Type: application/json
|
||||
X-Appwrite-Response-Format: 1.7.0
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
POST /v1/account/mfa/challenge HTTP/1.1
|
||||
POST /v1/account/mfa/challenges HTTP/1.1
|
||||
Host: cloud.appwrite.io
|
||||
Content-Type: application/json
|
||||
X-Appwrite-Response-Format: 1.7.0
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
PUT /v1/account/mfa/challenge HTTP/1.1
|
||||
PUT /v1/account/mfa/challenges HTTP/1.1
|
||||
Host: cloud.appwrite.io
|
||||
Content-Type: application/json
|
||||
X-Appwrite-Response-Format: 1.7.0
|
||||
|
||||
@@ -1,6 +1,9 @@
|
||||
import io.appwrite.Client;
|
||||
import io.appwrite.coroutines.CoroutineCallback;
|
||||
import io.appwrite.services.Avatars;
|
||||
import io.appwrite.enums.Theme;
|
||||
import io.appwrite.enums.Timezone;
|
||||
import io.appwrite.enums.Output;
|
||||
|
||||
Client client = new Client(context)
|
||||
.setEndpoint("https://<REGION>.cloud.appwrite.io/v1") // Your API Endpoint
|
||||
@@ -14,11 +17,11 @@ avatars.getScreenshot(
|
||||
1, // viewportWidth (optional)
|
||||
1, // viewportHeight (optional)
|
||||
0.1, // scale (optional)
|
||||
theme.LIGHT, // theme (optional)
|
||||
Theme.LIGHT, // theme (optional)
|
||||
"<USER_AGENT>", // userAgent (optional)
|
||||
false, // fullpage (optional)
|
||||
"<LOCALE>", // locale (optional)
|
||||
timezone.AFRICA_ABIDJAN, // timezone (optional)
|
||||
Timezone.AFRICA_ABIDJAN, // timezone (optional)
|
||||
-90, // latitude (optional)
|
||||
-180, // longitude (optional)
|
||||
0, // accuracy (optional)
|
||||
@@ -28,7 +31,7 @@ avatars.getScreenshot(
|
||||
0, // width (optional)
|
||||
0, // height (optional)
|
||||
-1, // quality (optional)
|
||||
output.JPG, // output (optional)
|
||||
Output.JPG, // output (optional)
|
||||
new CoroutineCallback<>((result, error) -> {
|
||||
if (error != null) {
|
||||
error.printStackTrace();
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import io.appwrite.Client;
|
||||
import io.appwrite.coroutines.CoroutineCallback;
|
||||
import io.appwrite.services.Functions;
|
||||
import io.appwrite.enums.ExecutionMethod;
|
||||
|
||||
Client client = new Client(context)
|
||||
.setEndpoint("https://<REGION>.cloud.appwrite.io/v1") // Your API Endpoint
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
import io.appwrite.Client;
|
||||
import io.appwrite.coroutines.CoroutineCallback;
|
||||
import io.appwrite.services.Storage;
|
||||
import io.appwrite.enums.ImageGravity;
|
||||
import io.appwrite.enums.ImageFormat;
|
||||
|
||||
Client client = new Client(context)
|
||||
.setEndpoint("https://<REGION>.cloud.appwrite.io/v1") // Your API Endpoint
|
||||
|
||||
@@ -1,6 +1,9 @@
|
||||
import io.appwrite.Client
|
||||
import io.appwrite.coroutines.CoroutineCallback
|
||||
import io.appwrite.services.Avatars
|
||||
import io.appwrite.enums.Theme
|
||||
import io.appwrite.enums.Timezone
|
||||
import io.appwrite.enums.Output
|
||||
|
||||
val client = Client(context)
|
||||
.setEndpoint("https://<REGION>.cloud.appwrite.io/v1") // Your API Endpoint
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import io.appwrite.Client
|
||||
import io.appwrite.coroutines.CoroutineCallback
|
||||
import io.appwrite.services.Functions
|
||||
import io.appwrite.enums.ExecutionMethod
|
||||
|
||||
val client = Client(context)
|
||||
.setEndpoint("https://<REGION>.cloud.appwrite.io/v1") // Your API Endpoint
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
import io.appwrite.Client
|
||||
import io.appwrite.coroutines.CoroutineCallback
|
||||
import io.appwrite.services.Storage
|
||||
import io.appwrite.enums.ImageGravity
|
||||
import io.appwrite.enums.ImageFormat
|
||||
|
||||
val client = Client(context)
|
||||
.setEndpoint("https://<REGION>.cloud.appwrite.io/v1") // Your API Endpoint
|
||||
|
||||
@@ -7,7 +7,7 @@ Client client = Client()
|
||||
Avatars avatars = Avatars(client);
|
||||
|
||||
// Downloading file
|
||||
UInt8List bytes = await avatars.getBrowser(
|
||||
Uint8List bytes = await avatars.getBrowser(
|
||||
code: Browser.avantBrowser,
|
||||
width: 0, // optional
|
||||
height: 0, // optional
|
||||
|
||||
@@ -7,7 +7,7 @@ Client client = Client()
|
||||
Avatars avatars = Avatars(client);
|
||||
|
||||
// Downloading file
|
||||
UInt8List bytes = await avatars.getCreditCard(
|
||||
Uint8List bytes = await avatars.getCreditCard(
|
||||
code: CreditCard.americanExpress,
|
||||
width: 0, // optional
|
||||
height: 0, // optional
|
||||
|
||||
@@ -7,7 +7,7 @@ Client client = Client()
|
||||
Avatars avatars = Avatars(client);
|
||||
|
||||
// Downloading file
|
||||
UInt8List bytes = await avatars.getFavicon(
|
||||
Uint8List bytes = await avatars.getFavicon(
|
||||
url: 'https://example.com',
|
||||
)
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@ Client client = Client()
|
||||
Avatars avatars = Avatars(client);
|
||||
|
||||
// Downloading file
|
||||
UInt8List bytes = await avatars.getFlag(
|
||||
Uint8List bytes = await avatars.getFlag(
|
||||
code: Flag.afghanistan,
|
||||
width: 0, // optional
|
||||
height: 0, // optional
|
||||
|
||||
@@ -7,7 +7,7 @@ Client client = Client()
|
||||
Avatars avatars = Avatars(client);
|
||||
|
||||
// Downloading file
|
||||
UInt8List bytes = await avatars.getImage(
|
||||
Uint8List bytes = await avatars.getImage(
|
||||
url: 'https://example.com',
|
||||
width: 0, // optional
|
||||
height: 0, // optional
|
||||
|
||||
@@ -7,7 +7,7 @@ Client client = Client()
|
||||
Avatars avatars = Avatars(client);
|
||||
|
||||
// Downloading file
|
||||
UInt8List bytes = await avatars.getInitials(
|
||||
Uint8List bytes = await avatars.getInitials(
|
||||
name: '<NAME>', // optional
|
||||
width: 0, // optional
|
||||
height: 0, // optional
|
||||
|
||||
@@ -7,7 +7,7 @@ Client client = Client()
|
||||
Avatars avatars = Avatars(client);
|
||||
|
||||
// Downloading file
|
||||
UInt8List bytes = await avatars.getQR(
|
||||
Uint8List bytes = await avatars.getQR(
|
||||
text: '<TEXT>',
|
||||
size: 1, // optional
|
||||
margin: 0, // optional
|
||||
|
||||
@@ -7,17 +7,17 @@ Client client = Client()
|
||||
Avatars avatars = Avatars(client);
|
||||
|
||||
// Downloading file
|
||||
UInt8List bytes = await avatars.getScreenshot(
|
||||
Uint8List bytes = await avatars.getScreenshot(
|
||||
url: 'https://example.com',
|
||||
headers: {}, // optional
|
||||
viewportWidth: 1, // optional
|
||||
viewportHeight: 1, // optional
|
||||
scale: 0.1, // optional
|
||||
theme: .light, // optional
|
||||
theme: Theme.light, // optional
|
||||
userAgent: '<USER_AGENT>', // optional
|
||||
fullpage: false, // optional
|
||||
locale: '<LOCALE>', // optional
|
||||
timezone: .africaAbidjan, // optional
|
||||
timezone: Timezone.africaAbidjan, // optional
|
||||
latitude: -90, // optional
|
||||
longitude: -180, // optional
|
||||
accuracy: 0, // optional
|
||||
@@ -27,7 +27,7 @@ UInt8List bytes = await avatars.getScreenshot(
|
||||
width: 0, // optional
|
||||
height: 0, // optional
|
||||
quality: -1, // optional
|
||||
output: .jpg, // optional
|
||||
output: Output.jpg, // optional
|
||||
)
|
||||
|
||||
final file = File('path_to_file/filename.ext');
|
||||
@@ -41,11 +41,11 @@ FutureBuilder(
|
||||
viewportWidth:1 , // optional
|
||||
viewportHeight:1 , // optional
|
||||
scale:0.1 , // optional
|
||||
theme: .light, // optional
|
||||
theme: Theme.light, // optional
|
||||
userAgent:'<USER_AGENT>' , // optional
|
||||
fullpage:false , // optional
|
||||
locale:'<LOCALE>' , // optional
|
||||
timezone: .africaAbidjan, // optional
|
||||
timezone: Timezone.africaAbidjan, // optional
|
||||
latitude:-90 , // optional
|
||||
longitude:-180 , // optional
|
||||
accuracy:0 , // optional
|
||||
@@ -55,7 +55,7 @@ FutureBuilder(
|
||||
width:0 , // optional
|
||||
height:0 , // optional
|
||||
quality:-1 , // optional
|
||||
output: .jpg, // optional
|
||||
output: Output.jpg, // optional
|
||||
), // Works for both public file and private file, for private files you need to be logged in
|
||||
builder: (context, snapshot) {
|
||||
return snapshot.hasData && snapshot.data != null
|
||||
|
||||
@@ -7,7 +7,7 @@ Client client = Client()
|
||||
Storage storage = Storage(client);
|
||||
|
||||
// Downloading file
|
||||
UInt8List bytes = await storage.getFileDownload(
|
||||
Uint8List bytes = await storage.getFileDownload(
|
||||
bucketId: '<BUCKET_ID>',
|
||||
fileId: '<FILE_ID>',
|
||||
token: '<TOKEN>', // optional
|
||||
|
||||
@@ -7,7 +7,7 @@ Client client = Client()
|
||||
Storage storage = Storage(client);
|
||||
|
||||
// Downloading file
|
||||
UInt8List bytes = await storage.getFilePreview(
|
||||
Uint8List bytes = await storage.getFilePreview(
|
||||
bucketId: '<BUCKET_ID>',
|
||||
fileId: '<FILE_ID>',
|
||||
width: 0, // optional
|
||||
|
||||
@@ -7,7 +7,7 @@ Client client = Client()
|
||||
Storage storage = Storage(client);
|
||||
|
||||
// Downloading file
|
||||
UInt8List bytes = await storage.getFileView(
|
||||
Uint8List bytes = await storage.getFileView(
|
||||
bucketId: '<BUCKET_ID>',
|
||||
fileId: '<FILE_ID>',
|
||||
token: '<TOKEN>', // optional
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { Client, Avatars, , , } from "react-native-appwrite";
|
||||
import { Client, Avatars, Theme, Timezone, Output } from "react-native-appwrite";
|
||||
|
||||
const client = new Client()
|
||||
.setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
|
||||
@@ -12,11 +12,11 @@ const result = avatars.getScreenshot({
|
||||
viewportWidth: 1, // optional
|
||||
viewportHeight: 1, // optional
|
||||
scale: 0.1, // optional
|
||||
theme: .Light, // optional
|
||||
theme: Theme.Light, // optional
|
||||
userAgent: '<USER_AGENT>', // optional
|
||||
fullpage: false, // optional
|
||||
locale: '<LOCALE>', // optional
|
||||
timezone: .AfricaAbidjan, // optional
|
||||
timezone: Timezone.AfricaAbidjan, // optional
|
||||
latitude: -90, // optional
|
||||
longitude: -180, // optional
|
||||
accuracy: 0, // optional
|
||||
@@ -26,7 +26,7 @@ const result = avatars.getScreenshot({
|
||||
width: 0, // optional
|
||||
height: 0, // optional
|
||||
quality: -1, // optional
|
||||
output: .Jpg // optional
|
||||
output: Output.Jpg // optional
|
||||
});
|
||||
|
||||
console.log(result);
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
POST /v1/account/mfa/challenge HTTP/1.1
|
||||
POST /v1/account/mfa/challenges HTTP/1.1
|
||||
Host: cloud.appwrite.io
|
||||
Content-Type: application/json
|
||||
X-Appwrite-Response-Format: 1.8.0
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
PUT /v1/account/mfa/challenge HTTP/1.1
|
||||
PUT /v1/account/mfa/challenges HTTP/1.1
|
||||
Host: cloud.appwrite.io
|
||||
Content-Type: application/json
|
||||
X-Appwrite-Response-Format: 1.8.0
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { Client, Avatars, , , } from "appwrite";
|
||||
import { Client, Avatars, Theme, Timezone, Output } from "appwrite";
|
||||
|
||||
const client = new Client()
|
||||
.setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
|
||||
@@ -12,11 +12,11 @@ const result = avatars.getScreenshot({
|
||||
viewportWidth: 1, // optional
|
||||
viewportHeight: 1, // optional
|
||||
scale: 0.1, // optional
|
||||
theme: .Light, // optional
|
||||
theme: Theme.Light, // optional
|
||||
userAgent: '<USER_AGENT>', // optional
|
||||
fullpage: false, // optional
|
||||
locale: '<LOCALE>', // optional
|
||||
timezone: .AfricaAbidjan, // optional
|
||||
timezone: Timezone.AfricaAbidjan, // optional
|
||||
latitude: -90, // optional
|
||||
longitude: -180, // optional
|
||||
accuracy: 0, // optional
|
||||
@@ -26,7 +26,7 @@ const result = avatars.getScreenshot({
|
||||
width: 0, // optional
|
||||
height: 0, // optional
|
||||
quality: -1, // optional
|
||||
output: .Jpg // optional
|
||||
output: Output.Jpg // optional
|
||||
});
|
||||
|
||||
console.log(result);
|
||||
|
||||
@@ -3,4 +3,5 @@ appwrite functions create-template-deployment \
|
||||
--repository <REPOSITORY> \
|
||||
--owner <OWNER> \
|
||||
--root-directory <ROOT_DIRECTORY> \
|
||||
--version <VERSION>
|
||||
--type commit \
|
||||
--reference <REFERENCE>
|
||||
|
||||
@@ -3,4 +3,5 @@ appwrite sites create-template-deployment \
|
||||
--repository <REPOSITORY> \
|
||||
--owner <OWNER> \
|
||||
--root-directory <ROOT_DIRECTORY> \
|
||||
--version <VERSION>
|
||||
--type branch \
|
||||
--reference <REFERENCE>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { Client, Avatars, , , } from "@appwrite.io/console";
|
||||
import { Client, Avatars, Theme, Timezone, Output } from "@appwrite.io/console";
|
||||
|
||||
const client = new Client()
|
||||
.setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
|
||||
@@ -12,11 +12,11 @@ const result = avatars.getScreenshot({
|
||||
viewportWidth: 1, // optional
|
||||
viewportHeight: 1, // optional
|
||||
scale: 0.1, // optional
|
||||
theme: .Light, // optional
|
||||
theme: Theme.Light, // optional
|
||||
userAgent: '<USER_AGENT>', // optional
|
||||
fullpage: false, // optional
|
||||
locale: '<LOCALE>', // optional
|
||||
timezone: .AfricaAbidjan, // optional
|
||||
timezone: Timezone.AfricaAbidjan, // optional
|
||||
latitude: -90, // optional
|
||||
longitude: -180, // optional
|
||||
accuracy: 0, // optional
|
||||
@@ -26,7 +26,7 @@ const result = avatars.getScreenshot({
|
||||
width: 0, // optional
|
||||
height: 0, // optional
|
||||
quality: -1, // optional
|
||||
output: .Jpg // optional
|
||||
output: Output.Jpg // optional
|
||||
});
|
||||
|
||||
console.log(result);
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { Client, Functions } from "@appwrite.io/console";
|
||||
import { Client, Functions, } from "@appwrite.io/console";
|
||||
|
||||
const client = new Client()
|
||||
.setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
|
||||
@@ -11,7 +11,8 @@ const result = await functions.createTemplateDeployment({
|
||||
repository: '<REPOSITORY>',
|
||||
owner: '<OWNER>',
|
||||
rootDirectory: '<ROOT_DIRECTORY>',
|
||||
version: '<VERSION>',
|
||||
type: .Commit,
|
||||
reference: '<REFERENCE>',
|
||||
activate: false // optional
|
||||
});
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { Client, Functions, } from "@appwrite.io/console";
|
||||
import { Client, Functions, Runtime } from "@appwrite.io/console";
|
||||
|
||||
const client = new Client()
|
||||
.setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
|
||||
@@ -9,7 +9,7 @@ const functions = new Functions(client);
|
||||
const result = await functions.create({
|
||||
functionId: '<FUNCTION_ID>',
|
||||
name: '<NAME>',
|
||||
runtime: .Node145,
|
||||
runtime: Runtime.Node145,
|
||||
execute: ["any"], // optional
|
||||
events: [], // optional
|
||||
schedule: '', // optional
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { Client, Functions, } from "@appwrite.io/console";
|
||||
import { Client, Functions, Runtime } from "@appwrite.io/console";
|
||||
|
||||
const client = new Client()
|
||||
.setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
|
||||
@@ -9,7 +9,7 @@ const functions = new Functions(client);
|
||||
const result = await functions.update({
|
||||
functionId: '<FUNCTION_ID>',
|
||||
name: '<NAME>',
|
||||
runtime: .Node145, // optional
|
||||
runtime: Runtime.Node145, // optional
|
||||
execute: ["any"], // optional
|
||||
events: [], // optional
|
||||
schedule: '', // optional
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { Client, Health, } from "@appwrite.io/console";
|
||||
import { Client, Health, Name } from "@appwrite.io/console";
|
||||
|
||||
const client = new Client()
|
||||
.setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
|
||||
@@ -7,7 +7,7 @@ const client = new Client()
|
||||
const health = new Health(client);
|
||||
|
||||
const result = await health.getFailedJobs({
|
||||
name: .V1Database,
|
||||
name: Name.V1Database,
|
||||
threshold: null // optional
|
||||
});
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { Client, Projects, } from "@appwrite.io/console";
|
||||
import { Client, Projects, Region } from "@appwrite.io/console";
|
||||
|
||||
const client = new Client()
|
||||
.setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
|
||||
@@ -10,7 +10,7 @@ const result = await projects.create({
|
||||
projectId: '',
|
||||
name: '<NAME>',
|
||||
teamId: '<TEAM_ID>',
|
||||
region: .Default, // optional
|
||||
region: Region.Default, // optional
|
||||
description: '<DESCRIPTION>', // optional
|
||||
logo: '<LOGO>', // optional
|
||||
url: 'https://example.com', // optional
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { Client, Projects, } from "@appwrite.io/console";
|
||||
import { Client, Projects, Api } from "@appwrite.io/console";
|
||||
|
||||
const client = new Client()
|
||||
.setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
|
||||
@@ -8,7 +8,7 @@ const projects = new Projects(client);
|
||||
|
||||
const result = await projects.updateAPIStatus({
|
||||
projectId: '<PROJECT_ID>',
|
||||
api: .Rest,
|
||||
api: Api.Rest,
|
||||
status: false
|
||||
});
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { Client, Proxy, , ProxyResourceType } from "@appwrite.io/console";
|
||||
import { Client, Proxy, StatusCode, ProxyResourceType } from "@appwrite.io/console";
|
||||
|
||||
const client = new Client()
|
||||
.setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
|
||||
@@ -9,7 +9,7 @@ const proxy = new Proxy(client);
|
||||
const result = await proxy.createRedirectRule({
|
||||
domain: '',
|
||||
url: 'https://example.com',
|
||||
statusCode: .MovedPermanently301,
|
||||
statusCode: StatusCode.MovedPermanently301,
|
||||
resourceId: '<RESOURCE_ID>',
|
||||
resourceType: ProxyResourceType.Site
|
||||
});
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { Client, Sites } from "@appwrite.io/console";
|
||||
import { Client, Sites, } from "@appwrite.io/console";
|
||||
|
||||
const client = new Client()
|
||||
.setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
|
||||
@@ -11,7 +11,8 @@ const result = await sites.createTemplateDeployment({
|
||||
repository: '<REPOSITORY>',
|
||||
owner: '<OWNER>',
|
||||
rootDirectory: '<ROOT_DIRECTORY>',
|
||||
version: '<VERSION>',
|
||||
type: .Branch,
|
||||
reference: '<REFERENCE>',
|
||||
activate: false // optional
|
||||
});
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { Client, Sites, , , } from "@appwrite.io/console";
|
||||
import { Client, Sites, Framework, BuildRuntime, Adapter } from "@appwrite.io/console";
|
||||
|
||||
const client = new Client()
|
||||
.setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
|
||||
@@ -9,15 +9,15 @@ const sites = new Sites(client);
|
||||
const result = await sites.create({
|
||||
siteId: '<SITE_ID>',
|
||||
name: '<NAME>',
|
||||
framework: .Analog,
|
||||
buildRuntime: .Node145,
|
||||
framework: Framework.Analog,
|
||||
buildRuntime: BuildRuntime.Node145,
|
||||
enabled: false, // optional
|
||||
logging: false, // optional
|
||||
timeout: 1, // optional
|
||||
installCommand: '<INSTALL_COMMAND>', // optional
|
||||
buildCommand: '<BUILD_COMMAND>', // optional
|
||||
outputDirectory: '<OUTPUT_DIRECTORY>', // optional
|
||||
adapter: .Static, // optional
|
||||
adapter: Adapter.Static, // optional
|
||||
installationId: '<INSTALLATION_ID>', // optional
|
||||
fallbackFile: '<FALLBACK_FILE>', // optional
|
||||
providerRepositoryId: '<PROVIDER_REPOSITORY_ID>', // optional
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { Client, Sites, , , } from "@appwrite.io/console";
|
||||
import { Client, Sites, Framework, BuildRuntime, Adapter } from "@appwrite.io/console";
|
||||
|
||||
const client = new Client()
|
||||
.setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
|
||||
@@ -9,15 +9,15 @@ const sites = new Sites(client);
|
||||
const result = await sites.update({
|
||||
siteId: '<SITE_ID>',
|
||||
name: '<NAME>',
|
||||
framework: .Analog,
|
||||
framework: Framework.Analog,
|
||||
enabled: false, // optional
|
||||
logging: false, // optional
|
||||
timeout: 1, // optional
|
||||
installCommand: '<INSTALL_COMMAND>', // optional
|
||||
buildCommand: '<BUILD_COMMAND>', // optional
|
||||
outputDirectory: '<OUTPUT_DIRECTORY>', // optional
|
||||
buildRuntime: .Node145, // optional
|
||||
adapter: .Static, // optional
|
||||
buildRuntime: BuildRuntime.Node145, // optional
|
||||
adapter: Adapter.Static, // optional
|
||||
fallbackFile: '<FALLBACK_FILE>', // optional
|
||||
installationId: '<INSTALLATION_ID>', // optional
|
||||
providerRepositoryId: '<PROVIDER_REPOSITORY_ID>', // optional
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { Client, Storage, , Permission, Role } from "@appwrite.io/console";
|
||||
import { Client, Storage, Compression, Permission, Role } from "@appwrite.io/console";
|
||||
|
||||
const client = new Client()
|
||||
.setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
|
||||
@@ -14,9 +14,10 @@ const result = await storage.createBucket({
|
||||
enabled: false, // optional
|
||||
maximumFileSize: 1, // optional
|
||||
allowedFileExtensions: [], // optional
|
||||
compression: .None, // optional
|
||||
compression: Compression.None, // optional
|
||||
encryption: false, // optional
|
||||
antivirus: false // optional
|
||||
antivirus: false, // optional
|
||||
transformations: false // optional
|
||||
});
|
||||
|
||||
console.log(result);
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { Client, Storage, , Permission, Role } from "@appwrite.io/console";
|
||||
import { Client, Storage, Compression, Permission, Role } from "@appwrite.io/console";
|
||||
|
||||
const client = new Client()
|
||||
.setEndpoint('https://<REGION>.cloud.appwrite.io/v1') // Your API Endpoint
|
||||
@@ -14,9 +14,10 @@ const result = await storage.updateBucket({
|
||||
enabled: false, // optional
|
||||
maximumFileSize: 1, // optional
|
||||
allowedFileExtensions: [], // optional
|
||||
compression: .None, // optional
|
||||
compression: Compression.None, // optional
|
||||
encryption: false, // optional
|
||||
antivirus: false // optional
|
||||
antivirus: false, // optional
|
||||
transformations: false // optional
|
||||
});
|
||||
|
||||
console.log(result);
|
||||
|
||||
@@ -7,7 +7,7 @@ Client client = Client()
|
||||
|
||||
Avatars avatars = Avatars(client);
|
||||
|
||||
UInt8List result = await avatars.getBrowser(
|
||||
Uint8List result = await avatars.getBrowser(
|
||||
code: Browser.avantBrowser,
|
||||
width: 0, // (optional)
|
||||
height: 0, // (optional)
|
||||
|
||||
@@ -7,7 +7,7 @@ Client client = Client()
|
||||
|
||||
Avatars avatars = Avatars(client);
|
||||
|
||||
UInt8List result = await avatars.getCreditCard(
|
||||
Uint8List result = await avatars.getCreditCard(
|
||||
code: CreditCard.americanExpress,
|
||||
width: 0, // (optional)
|
||||
height: 0, // (optional)
|
||||
|
||||
@@ -7,6 +7,6 @@ Client client = Client()
|
||||
|
||||
Avatars avatars = Avatars(client);
|
||||
|
||||
UInt8List result = await avatars.getFavicon(
|
||||
Uint8List result = await avatars.getFavicon(
|
||||
url: 'https://example.com',
|
||||
);
|
||||
|
||||
@@ -7,7 +7,7 @@ Client client = Client()
|
||||
|
||||
Avatars avatars = Avatars(client);
|
||||
|
||||
UInt8List result = await avatars.getFlag(
|
||||
Uint8List result = await avatars.getFlag(
|
||||
code: Flag.afghanistan,
|
||||
width: 0, // (optional)
|
||||
height: 0, // (optional)
|
||||
|
||||
@@ -7,7 +7,7 @@ Client client = Client()
|
||||
|
||||
Avatars avatars = Avatars(client);
|
||||
|
||||
UInt8List result = await avatars.getImage(
|
||||
Uint8List result = await avatars.getImage(
|
||||
url: 'https://example.com',
|
||||
width: 0, // (optional)
|
||||
height: 0, // (optional)
|
||||
|
||||
@@ -7,7 +7,7 @@ Client client = Client()
|
||||
|
||||
Avatars avatars = Avatars(client);
|
||||
|
||||
UInt8List result = await avatars.getInitials(
|
||||
Uint8List result = await avatars.getInitials(
|
||||
name: '<NAME>', // (optional)
|
||||
width: 0, // (optional)
|
||||
height: 0, // (optional)
|
||||
|
||||
@@ -7,7 +7,7 @@ Client client = Client()
|
||||
|
||||
Avatars avatars = Avatars(client);
|
||||
|
||||
UInt8List result = await avatars.getQR(
|
||||
Uint8List result = await avatars.getQR(
|
||||
text: '<TEXT>',
|
||||
size: 1, // (optional)
|
||||
margin: 0, // (optional)
|
||||
|
||||
@@ -7,17 +7,17 @@ Client client = Client()
|
||||
|
||||
Avatars avatars = Avatars(client);
|
||||
|
||||
UInt8List result = await avatars.getScreenshot(
|
||||
Uint8List result = await avatars.getScreenshot(
|
||||
url: 'https://example.com',
|
||||
headers: {}, // (optional)
|
||||
viewportWidth: 1, // (optional)
|
||||
viewportHeight: 1, // (optional)
|
||||
scale: 0.1, // (optional)
|
||||
theme: .light, // (optional)
|
||||
theme: Theme.light, // (optional)
|
||||
userAgent: '<USER_AGENT>', // (optional)
|
||||
fullpage: false, // (optional)
|
||||
locale: '<LOCALE>', // (optional)
|
||||
timezone: .africaAbidjan, // (optional)
|
||||
timezone: Timezone.africaAbidjan, // (optional)
|
||||
latitude: -90, // (optional)
|
||||
longitude: -180, // (optional)
|
||||
accuracy: 0, // (optional)
|
||||
@@ -27,5 +27,5 @@ UInt8List result = await avatars.getScreenshot(
|
||||
width: 0, // (optional)
|
||||
height: 0, // (optional)
|
||||
quality: -1, // (optional)
|
||||
output: .jpg, // (optional)
|
||||
output: Output.jpg, // (optional)
|
||||
);
|
||||
|
||||
@@ -12,6 +12,7 @@ Deployment result = await functions.createTemplateDeployment(
|
||||
repository: '<REPOSITORY>',
|
||||
owner: '<OWNER>',
|
||||
rootDirectory: '<ROOT_DIRECTORY>',
|
||||
version: '<VERSION>',
|
||||
type: .commit,
|
||||
reference: '<REFERENCE>',
|
||||
activate: false, // (optional)
|
||||
);
|
||||
|
||||
@@ -10,7 +10,7 @@ Functions functions = Functions(client);
|
||||
Func result = await functions.create(
|
||||
functionId: '<FUNCTION_ID>',
|
||||
name: '<NAME>',
|
||||
runtime: .node145,
|
||||
runtime: Runtime.node145,
|
||||
execute: ["any"], // (optional)
|
||||
events: [], // (optional)
|
||||
schedule: '', // (optional)
|
||||
|
||||
@@ -7,7 +7,7 @@ Client client = Client()
|
||||
|
||||
Functions functions = Functions(client);
|
||||
|
||||
UInt8List result = await functions.getDeploymentDownload(
|
||||
Uint8List result = await functions.getDeploymentDownload(
|
||||
functionId: '<FUNCTION_ID>',
|
||||
deploymentId: '<DEPLOYMENT_ID>',
|
||||
type: DeploymentDownloadType.source, // (optional)
|
||||
|
||||
@@ -10,7 +10,7 @@ Functions functions = Functions(client);
|
||||
Func result = await functions.update(
|
||||
functionId: '<FUNCTION_ID>',
|
||||
name: '<NAME>',
|
||||
runtime: .node145, // (optional)
|
||||
runtime: Runtime.node145, // (optional)
|
||||
execute: ["any"], // (optional)
|
||||
events: [], // (optional)
|
||||
schedule: '', // (optional)
|
||||
|
||||
@@ -8,6 +8,6 @@ Client client = Client()
|
||||
Health health = Health(client);
|
||||
|
||||
HealthQueue result = await health.getFailedJobs(
|
||||
name: .v1Database,
|
||||
name: Name.v1Database,
|
||||
threshold: 0, // (optional)
|
||||
);
|
||||
|
||||
@@ -12,6 +12,7 @@ Deployment result = await sites.createTemplateDeployment(
|
||||
repository: '<REPOSITORY>',
|
||||
owner: '<OWNER>',
|
||||
rootDirectory: '<ROOT_DIRECTORY>',
|
||||
version: '<VERSION>',
|
||||
type: .branch,
|
||||
reference: '<REFERENCE>',
|
||||
activate: false, // (optional)
|
||||
);
|
||||
|
||||
@@ -10,15 +10,15 @@ Sites sites = Sites(client);
|
||||
Site result = await sites.create(
|
||||
siteId: '<SITE_ID>',
|
||||
name: '<NAME>',
|
||||
framework: .analog,
|
||||
buildRuntime: .node145,
|
||||
framework: Framework.analog,
|
||||
buildRuntime: BuildRuntime.node145,
|
||||
enabled: false, // (optional)
|
||||
logging: false, // (optional)
|
||||
timeout: 1, // (optional)
|
||||
installCommand: '<INSTALL_COMMAND>', // (optional)
|
||||
buildCommand: '<BUILD_COMMAND>', // (optional)
|
||||
outputDirectory: '<OUTPUT_DIRECTORY>', // (optional)
|
||||
adapter: .static, // (optional)
|
||||
adapter: Adapter.static, // (optional)
|
||||
installationId: '<INSTALLATION_ID>', // (optional)
|
||||
fallbackFile: '<FALLBACK_FILE>', // (optional)
|
||||
providerRepositoryId: '<PROVIDER_REPOSITORY_ID>', // (optional)
|
||||
|
||||
@@ -7,7 +7,7 @@ Client client = Client()
|
||||
|
||||
Sites sites = Sites(client);
|
||||
|
||||
UInt8List result = await sites.getDeploymentDownload(
|
||||
Uint8List result = await sites.getDeploymentDownload(
|
||||
siteId: '<SITE_ID>',
|
||||
deploymentId: '<DEPLOYMENT_ID>',
|
||||
type: DeploymentDownloadType.source, // (optional)
|
||||
|
||||
@@ -10,15 +10,15 @@ Sites sites = Sites(client);
|
||||
Site result = await sites.update(
|
||||
siteId: '<SITE_ID>',
|
||||
name: '<NAME>',
|
||||
framework: .analog,
|
||||
framework: Framework.analog,
|
||||
enabled: false, // (optional)
|
||||
logging: false, // (optional)
|
||||
timeout: 1, // (optional)
|
||||
installCommand: '<INSTALL_COMMAND>', // (optional)
|
||||
buildCommand: '<BUILD_COMMAND>', // (optional)
|
||||
outputDirectory: '<OUTPUT_DIRECTORY>', // (optional)
|
||||
buildRuntime: .node145, // (optional)
|
||||
adapter: .static, // (optional)
|
||||
buildRuntime: BuildRuntime.node145, // (optional)
|
||||
adapter: Adapter.static, // (optional)
|
||||
fallbackFile: '<FALLBACK_FILE>', // (optional)
|
||||
installationId: '<INSTALLATION_ID>', // (optional)
|
||||
providerRepositoryId: '<PROVIDER_REPOSITORY_ID>', // (optional)
|
||||
|
||||
@@ -17,7 +17,8 @@ Bucket result = await storage.createBucket(
|
||||
enabled: false, // (optional)
|
||||
maximumFileSize: 1, // (optional)
|
||||
allowedFileExtensions: [], // (optional)
|
||||
compression: .none, // (optional)
|
||||
compression: Compression.none, // (optional)
|
||||
encryption: false, // (optional)
|
||||
antivirus: false, // (optional)
|
||||
transformations: false, // (optional)
|
||||
);
|
||||
|
||||
@@ -7,7 +7,7 @@ Client client = Client()
|
||||
|
||||
Storage storage = Storage(client);
|
||||
|
||||
UInt8List result = await storage.getFileDownload(
|
||||
Uint8List result = await storage.getFileDownload(
|
||||
bucketId: '<BUCKET_ID>',
|
||||
fileId: '<FILE_ID>',
|
||||
token: '<TOKEN>', // (optional)
|
||||
|
||||
@@ -7,7 +7,7 @@ Client client = Client()
|
||||
|
||||
Storage storage = Storage(client);
|
||||
|
||||
UInt8List result = await storage.getFilePreview(
|
||||
Uint8List result = await storage.getFilePreview(
|
||||
bucketId: '<BUCKET_ID>',
|
||||
fileId: '<FILE_ID>',
|
||||
width: 0, // (optional)
|
||||
|
||||
@@ -7,7 +7,7 @@ Client client = Client()
|
||||
|
||||
Storage storage = Storage(client);
|
||||
|
||||
UInt8List result = await storage.getFileView(
|
||||
Uint8List result = await storage.getFileView(
|
||||
bucketId: '<BUCKET_ID>',
|
||||
fileId: '<FILE_ID>',
|
||||
token: '<TOKEN>', // (optional)
|
||||
|
||||
@@ -17,7 +17,8 @@ Bucket result = await storage.updateBucket(
|
||||
enabled: false, // (optional)
|
||||
maximumFileSize: 1, // (optional)
|
||||
allowedFileExtensions: [], // (optional)
|
||||
compression: .none, // (optional)
|
||||
compression: Compression.none, // (optional)
|
||||
encryption: false, // (optional)
|
||||
antivirus: false, // (optional)
|
||||
transformations: false, // (optional)
|
||||
);
|
||||
|
||||
@@ -16,11 +16,11 @@ byte[] result = await avatars.GetScreenshot(
|
||||
viewportWidth: 1, // optional
|
||||
viewportHeight: 1, // optional
|
||||
scale: 0.1, // optional
|
||||
theme: .Light, // optional
|
||||
theme: Theme.Light, // optional
|
||||
userAgent: "<USER_AGENT>", // optional
|
||||
fullpage: false, // optional
|
||||
locale: "<LOCALE>", // optional
|
||||
timezone: .AfricaAbidjan, // optional
|
||||
timezone: Timezone.AfricaAbidjan, // optional
|
||||
latitude: -90, // optional
|
||||
longitude: -180, // optional
|
||||
accuracy: 0, // optional
|
||||
@@ -30,5 +30,5 @@ byte[] result = await avatars.GetScreenshot(
|
||||
width: 0, // optional
|
||||
height: 0, // optional
|
||||
quality: -1, // optional
|
||||
output: .Jpg // optional
|
||||
output: Output.Jpg // optional
|
||||
);
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user