From 6e16340f16c7388e3e2fdfe1c73659052d392c11 Mon Sep 17 00:00:00 2001 From: Atharva Deosthale Date: Sat, 13 Sep 2025 17:56:19 +0530 Subject: [PATCH 01/24] feat: add branch deployments to appwrite --- .../specs/open-api3-latest-console.json | 151 ++++++++++-- app/config/specs/open-api3-latest-server.json | 126 ++++++++-- app/config/specs/swagger2-latest-console.json | 159 ++++++++++-- app/config/specs/swagger2-latest-server.json | 134 ++++++++-- .../Modules/Functions/Workers/Builds.php | 12 +- .../Sites/Http/Deployments/Direct/Create.php | 231 ++++++++++++++++++ .../Platform/Modules/Sites/Services/Http.php | 2 + 7 files changed, 731 insertions(+), 84 deletions(-) create mode 100644 src/Appwrite/Platform/Modules/Sites/Http/Deployments/Direct/Create.php diff --git a/app/config/specs/open-api3-latest-console.json b/app/config/specs/open-api3-latest-console.json index 02d97fffc7..0de652e3fb 100644 --- a/app/config/specs/open-api3-latest-console.json +++ b/app/config/specs/open-api3-latest-console.json @@ -4888,7 +4888,7 @@ "x-appwrite": { "method": "getResource", "group": null, - "weight": 496, + "weight": 497, "cookies": false, "type": "", "demo": "console\/get-resource.md", @@ -28209,7 +28209,7 @@ "x-appwrite": { "method": "listRules", "group": null, - "weight": 502, + "weight": 503, "cookies": false, "type": "", "demo": "proxy\/list-rules.md", @@ -28283,7 +28283,7 @@ "x-appwrite": { "method": "createAPIRule", "group": null, - "weight": 497, + "weight": 498, "cookies": false, "type": "", "demo": "proxy\/create-api-rule.md", @@ -28350,7 +28350,7 @@ "x-appwrite": { "method": "createFunctionRule", "group": null, - "weight": 499, + "weight": 500, "cookies": false, "type": "", "demo": "proxy\/create-function-rule.md", @@ -28428,7 +28428,7 @@ "x-appwrite": { "method": "createRedirectRule", "group": null, - "weight": 500, + "weight": 501, "cookies": false, "type": "", "demo": "proxy\/create-redirect-rule.md", @@ -28541,7 +28541,7 @@ "x-appwrite": { "method": "createSiteRule", "group": null, - "weight": 498, + "weight": 499, "cookies": false, "type": "", "demo": "proxy\/create-site-rule.md", @@ -28619,7 +28619,7 @@ "x-appwrite": { "method": "getRule", "group": null, - "weight": 501, + "weight": 502, "cookies": false, "type": "", "demo": "proxy\/get-rule.md", @@ -28670,7 +28670,7 @@ "x-appwrite": { "method": "deleteRule", "group": null, - "weight": 503, + "weight": 504, "cookies": false, "type": "", "demo": "proxy\/delete-rule.md", @@ -28730,7 +28730,7 @@ "x-appwrite": { "method": "updateRuleVerification", "group": null, - "weight": 504, + "weight": 505, "cookies": false, "type": "", "demo": "proxy\/update-rule-verification.md", @@ -29085,6 +29085,103 @@ } } }, + "\/sites\/direct": { + "post": { + "summary": "Create direct deployment", + "operationId": "sitesCreateDirectDeployment", + "tags": [ + "sites" + ], + "description": "Create a deployment directly from a repository branch.", + "responses": { + "202": { + "description": "Deployment", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/deployment" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "createDirectDeployment", + "group": "deployments", + "weight": 483, + "cookies": false, + "type": "", + "demo": "sites\/create-direct-deployment.md", + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/masterCreate a deployment directly from a repository branch.", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "sites.write", + "platforms": [ + "server" + ], + "packaging": false, + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "siteId": { + "type": "string", + "description": "Site ID.", + "x-example": "" + }, + "repository": { + "type": "string", + "description": "Repository name of the template.", + "x-example": "" + }, + "owner": { + "type": "string", + "description": "The name of the owner of the template.", + "x-example": "" + }, + "rootDirectory": { + "type": "string", + "description": "Path to site code in the template repo.", + "x-example": "" + }, + "branch": { + "type": "string", + "description": "Branch to create deployment from.", + "x-example": "" + }, + "activate": { + "type": "boolean", + "description": "Automatically activate the deployment when it is finished building.", + "x-example": false + } + }, + "required": [ + "siteId", + "repository", + "owner", + "rootDirectory", + "branch" + ] + } + } + } + } + } + }, "\/sites\/frameworks": { "get": { "summary": "List frameworks", @@ -29158,7 +29255,7 @@ "x-appwrite": { "method": "listSpecifications", "group": "frameworks", - "weight": 495, + "weight": 496, "cookies": false, "type": "", "demo": "sites\/list-specifications.md", @@ -29208,7 +29305,7 @@ "x-appwrite": { "method": "listTemplates", "group": "templates", - "weight": 491, + "weight": 492, "cookies": false, "type": "", "demo": "sites\/list-templates.md", @@ -29308,7 +29405,7 @@ "x-appwrite": { "method": "getTemplate", "group": "templates", - "weight": 492, + "weight": 493, "cookies": false, "type": "", "demo": "sites\/get-template.md", @@ -29368,7 +29465,7 @@ "x-appwrite": { "method": "listUsage", "group": null, - "weight": 493, + "weight": 494, "cookies": false, "type": "", "demo": "sites\/list-usage.md", @@ -30637,7 +30734,7 @@ "x-appwrite": { "method": "listLogs", "group": "logs", - "weight": 484, + "weight": 485, "cookies": false, "type": "", "demo": "sites\/list-logs.md", @@ -30708,7 +30805,7 @@ "x-appwrite": { "method": "getLog", "group": "logs", - "weight": 483, + "weight": 484, "cookies": false, "type": "", "demo": "sites\/get-log.md", @@ -30770,7 +30867,7 @@ "x-appwrite": { "method": "deleteLog", "group": "logs", - "weight": 485, + "weight": 486, "cookies": false, "type": "", "demo": "sites\/delete-log.md", @@ -30841,7 +30938,7 @@ "x-appwrite": { "method": "getUsage", "group": null, - "weight": 494, + "weight": 495, "cookies": false, "type": "", "demo": "sites\/get-usage.md", @@ -30923,7 +31020,7 @@ "x-appwrite": { "method": "listVariables", "group": "variables", - "weight": 488, + "weight": 489, "cookies": false, "type": "", "demo": "sites\/list-variables.md", @@ -30982,7 +31079,7 @@ "x-appwrite": { "method": "createVariable", "group": "variables", - "weight": 486, + "weight": 487, "cookies": false, "type": "", "demo": "sites\/create-variable.md", @@ -31073,7 +31170,7 @@ "x-appwrite": { "method": "getVariable", "group": "variables", - "weight": 487, + "weight": 488, "cookies": false, "type": "", "demo": "sites\/get-variable.md", @@ -31142,7 +31239,7 @@ "x-appwrite": { "method": "updateVariable", "group": "variables", - "weight": 489, + "weight": 490, "cookies": false, "type": "", "demo": "sites\/update-variable.md", @@ -31233,7 +31330,7 @@ "x-appwrite": { "method": "deleteVariable", "group": "variables", - "weight": 490, + "weight": 491, "cookies": false, "type": "", "demo": "sites\/delete-variable.md", @@ -39984,7 +40081,7 @@ "x-appwrite": { "method": "list", "group": "files", - "weight": 507, + "weight": 508, "cookies": false, "type": "", "demo": "tokens\/list.md", @@ -40064,7 +40161,7 @@ "x-appwrite": { "method": "createFileToken", "group": "files", - "weight": 505, + "weight": 506, "cookies": false, "type": "", "demo": "tokens\/create-file-token.md", @@ -40153,7 +40250,7 @@ "x-appwrite": { "method": "get", "group": "tokens", - "weight": 506, + "weight": 507, "cookies": false, "type": "", "demo": "tokens\/get.md", @@ -40213,7 +40310,7 @@ "x-appwrite": { "method": "update", "group": "tokens", - "weight": 508, + "weight": 509, "cookies": false, "type": "", "demo": "tokens\/update.md", @@ -40283,7 +40380,7 @@ "x-appwrite": { "method": "delete", "group": "tokens", - "weight": 509, + "weight": 510, "cookies": false, "type": "", "demo": "tokens\/delete.md", diff --git a/app/config/specs/open-api3-latest-server.json b/app/config/specs/open-api3-latest-server.json index 09d53dbdf0..d8d7178eb2 100644 --- a/app/config/specs/open-api3-latest-server.json +++ b/app/config/specs/open-api3-latest-server.json @@ -20014,6 +20014,104 @@ } } }, + "\/sites\/direct": { + "post": { + "summary": "Create direct deployment", + "operationId": "sitesCreateDirectDeployment", + "tags": [ + "sites" + ], + "description": "Create a deployment directly from a repository branch.", + "responses": { + "202": { + "description": "Deployment", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/deployment" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "createDirectDeployment", + "group": "deployments", + "weight": 483, + "cookies": false, + "type": "", + "demo": "sites\/create-direct-deployment.md", + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/masterCreate a deployment directly from a repository branch.", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "sites.write", + "platforms": [ + "server" + ], + "packaging": false, + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "siteId": { + "type": "string", + "description": "Site ID.", + "x-example": "" + }, + "repository": { + "type": "string", + "description": "Repository name of the template.", + "x-example": "" + }, + "owner": { + "type": "string", + "description": "The name of the owner of the template.", + "x-example": "" + }, + "rootDirectory": { + "type": "string", + "description": "Path to site code in the template repo.", + "x-example": "" + }, + "branch": { + "type": "string", + "description": "Branch to create deployment from.", + "x-example": "" + }, + "activate": { + "type": "boolean", + "description": "Automatically activate the deployment when it is finished building.", + "x-example": false + } + }, + "required": [ + "siteId", + "repository", + "owner", + "rootDirectory", + "branch" + ] + } + } + } + } + } + }, "\/sites\/frameworks": { "get": { "summary": "List frameworks", @@ -20088,7 +20186,7 @@ "x-appwrite": { "method": "listSpecifications", "group": "frameworks", - "weight": 495, + "weight": 496, "cookies": false, "type": "", "demo": "sites\/list-specifications.md", @@ -21349,7 +21447,7 @@ "x-appwrite": { "method": "listLogs", "group": "logs", - "weight": 484, + "weight": 485, "cookies": false, "type": "", "demo": "sites\/list-logs.md", @@ -21421,7 +21519,7 @@ "x-appwrite": { "method": "getLog", "group": "logs", - "weight": 483, + "weight": 484, "cookies": false, "type": "", "demo": "sites\/get-log.md", @@ -21484,7 +21582,7 @@ "x-appwrite": { "method": "deleteLog", "group": "logs", - "weight": 485, + "weight": 486, "cookies": false, "type": "", "demo": "sites\/delete-log.md", @@ -21556,7 +21654,7 @@ "x-appwrite": { "method": "listVariables", "group": "variables", - "weight": 488, + "weight": 489, "cookies": false, "type": "", "demo": "sites\/list-variables.md", @@ -21616,7 +21714,7 @@ "x-appwrite": { "method": "createVariable", "group": "variables", - "weight": 486, + "weight": 487, "cookies": false, "type": "", "demo": "sites\/create-variable.md", @@ -21708,7 +21806,7 @@ "x-appwrite": { "method": "getVariable", "group": "variables", - "weight": 487, + "weight": 488, "cookies": false, "type": "", "demo": "sites\/get-variable.md", @@ -21778,7 +21876,7 @@ "x-appwrite": { "method": "updateVariable", "group": "variables", - "weight": 489, + "weight": 490, "cookies": false, "type": "", "demo": "sites\/update-variable.md", @@ -21870,7 +21968,7 @@ "x-appwrite": { "method": "deleteVariable", "group": "variables", - "weight": 490, + "weight": 491, "cookies": false, "type": "", "demo": "sites\/delete-variable.md", @@ -30024,7 +30122,7 @@ "x-appwrite": { "method": "list", "group": "files", - "weight": 507, + "weight": 508, "cookies": false, "type": "", "demo": "tokens\/list.md", @@ -30105,7 +30203,7 @@ "x-appwrite": { "method": "createFileToken", "group": "files", - "weight": 505, + "weight": 506, "cookies": false, "type": "", "demo": "tokens\/create-file-token.md", @@ -30195,7 +30293,7 @@ "x-appwrite": { "method": "get", "group": "tokens", - "weight": 506, + "weight": 507, "cookies": false, "type": "", "demo": "tokens\/get.md", @@ -30256,7 +30354,7 @@ "x-appwrite": { "method": "update", "group": "tokens", - "weight": 508, + "weight": 509, "cookies": false, "type": "", "demo": "tokens\/update.md", @@ -30327,7 +30425,7 @@ "x-appwrite": { "method": "delete", "group": "tokens", - "weight": 509, + "weight": 510, "cookies": false, "type": "", "demo": "tokens\/delete.md", diff --git a/app/config/specs/swagger2-latest-console.json b/app/config/specs/swagger2-latest-console.json index 6d5721c73b..22823cd40e 100644 --- a/app/config/specs/swagger2-latest-console.json +++ b/app/config/specs/swagger2-latest-console.json @@ -5052,7 +5052,7 @@ "x-appwrite": { "method": "getResource", "group": null, - "weight": 496, + "weight": 497, "cookies": false, "type": "", "demo": "console\/get-resource.md", @@ -28351,7 +28351,7 @@ "x-appwrite": { "method": "listRules", "group": null, - "weight": 502, + "weight": 503, "cookies": false, "type": "", "demo": "proxy\/list-rules.md", @@ -28424,7 +28424,7 @@ "x-appwrite": { "method": "createAPIRule", "group": null, - "weight": 497, + "weight": 498, "cookies": false, "type": "", "demo": "proxy\/create-api-rule.md", @@ -28494,7 +28494,7 @@ "x-appwrite": { "method": "createFunctionRule", "group": null, - "weight": 499, + "weight": 500, "cookies": false, "type": "", "demo": "proxy\/create-function-rule.md", @@ -28577,7 +28577,7 @@ "x-appwrite": { "method": "createRedirectRule", "group": null, - "weight": 500, + "weight": 501, "cookies": false, "type": "", "demo": "proxy\/create-redirect-rule.md", @@ -28697,7 +28697,7 @@ "x-appwrite": { "method": "createSiteRule", "group": null, - "weight": 498, + "weight": 499, "cookies": false, "type": "", "demo": "proxy\/create-site-rule.md", @@ -28778,7 +28778,7 @@ "x-appwrite": { "method": "getRule", "group": null, - "weight": 501, + "weight": 502, "cookies": false, "type": "", "demo": "proxy\/get-rule.md", @@ -28831,7 +28831,7 @@ "x-appwrite": { "method": "deleteRule", "group": null, - "weight": 503, + "weight": 504, "cookies": false, "type": "", "demo": "proxy\/delete-rule.md", @@ -28891,7 +28891,7 @@ "x-appwrite": { "method": "updateRuleVerification", "group": null, - "weight": 504, + "weight": 505, "cookies": false, "type": "", "demo": "proxy\/update-rule-verification.md", @@ -29264,6 +29264,111 @@ ] } }, + "\/sites\/direct": { + "post": { + "summary": "Create direct deployment", + "operationId": "sitesCreateDirectDeployment", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "sites" + ], + "description": "Create a deployment directly from a repository branch.", + "responses": { + "202": { + "description": "Deployment", + "schema": { + "$ref": "#\/definitions\/deployment" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "createDirectDeployment", + "group": "deployments", + "weight": 483, + "cookies": false, + "type": "", + "demo": "sites\/create-direct-deployment.md", + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/masterCreate a deployment directly from a repository branch.", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "sites.write", + "platforms": [ + "server" + ], + "packaging": false, + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "siteId": { + "type": "string", + "description": "Site ID.", + "default": null, + "x-example": "" + }, + "repository": { + "type": "string", + "description": "Repository name of the template.", + "default": null, + "x-example": "" + }, + "owner": { + "type": "string", + "description": "The name of the owner of the template.", + "default": null, + "x-example": "" + }, + "rootDirectory": { + "type": "string", + "description": "Path to site code in the template repo.", + "default": null, + "x-example": "" + }, + "branch": { + "type": "string", + "description": "Branch to create deployment from.", + "default": null, + "x-example": "" + }, + "activate": { + "type": "boolean", + "description": "Automatically activate the deployment when it is finished building.", + "default": true, + "x-example": false + } + }, + "required": [ + "siteId", + "repository", + "owner", + "rootDirectory", + "branch" + ] + } + } + ] + } + }, "\/sites\/frameworks": { "get": { "summary": "List frameworks", @@ -29337,7 +29442,7 @@ "x-appwrite": { "method": "listSpecifications", "group": "frameworks", - "weight": 495, + "weight": 496, "cookies": false, "type": "", "demo": "sites\/list-specifications.md", @@ -29387,7 +29492,7 @@ "x-appwrite": { "method": "listTemplates", "group": "templates", - "weight": 491, + "weight": 492, "cookies": false, "type": "", "demo": "sites\/list-templates.md", @@ -29481,7 +29586,7 @@ "x-appwrite": { "method": "getTemplate", "group": "templates", - "weight": 492, + "weight": 493, "cookies": false, "type": "", "demo": "sites\/get-template.md", @@ -29539,7 +29644,7 @@ "x-appwrite": { "method": "listUsage", "group": null, - "weight": 493, + "weight": 494, "cookies": false, "type": "", "demo": "sites\/list-usage.md", @@ -30811,7 +30916,7 @@ "x-appwrite": { "method": "listLogs", "group": "logs", - "weight": 484, + "weight": 485, "cookies": false, "type": "", "demo": "sites\/list-logs.md", @@ -30882,7 +30987,7 @@ "x-appwrite": { "method": "getLog", "group": "logs", - "weight": 483, + "weight": 484, "cookies": false, "type": "", "demo": "sites\/get-log.md", @@ -30946,7 +31051,7 @@ "x-appwrite": { "method": "deleteLog", "group": "logs", - "weight": 485, + "weight": 486, "cookies": false, "type": "", "demo": "sites\/delete-log.md", @@ -31013,7 +31118,7 @@ "x-appwrite": { "method": "getUsage", "group": null, - "weight": 494, + "weight": 495, "cookies": false, "type": "", "demo": "sites\/get-usage.md", @@ -31091,7 +31196,7 @@ "x-appwrite": { "method": "listVariables", "group": "variables", - "weight": 488, + "weight": 489, "cookies": false, "type": "", "demo": "sites\/list-variables.md", @@ -31150,7 +31255,7 @@ "x-appwrite": { "method": "createVariable", "group": "variables", - "weight": 486, + "weight": 487, "cookies": false, "type": "", "demo": "sites\/create-variable.md", @@ -31240,7 +31345,7 @@ "x-appwrite": { "method": "getVariable", "group": "variables", - "weight": 487, + "weight": 488, "cookies": false, "type": "", "demo": "sites\/get-variable.md", @@ -31307,7 +31412,7 @@ "x-appwrite": { "method": "updateVariable", "group": "variables", - "weight": 489, + "weight": 490, "cookies": false, "type": "", "demo": "sites\/update-variable.md", @@ -31399,7 +31504,7 @@ "x-appwrite": { "method": "deleteVariable", "group": "variables", - "weight": 490, + "weight": 491, "cookies": false, "type": "", "demo": "sites\/delete-variable.md", @@ -39916,7 +40021,7 @@ "x-appwrite": { "method": "list", "group": "files", - "weight": 507, + "weight": 508, "cookies": false, "type": "", "demo": "tokens\/list.md", @@ -39996,7 +40101,7 @@ "x-appwrite": { "method": "createFileToken", "group": "files", - "weight": 505, + "weight": 506, "cookies": false, "type": "", "demo": "tokens\/create-file-token.md", @@ -40080,7 +40185,7 @@ "x-appwrite": { "method": "get", "group": "tokens", - "weight": 506, + "weight": 507, "cookies": false, "type": "", "demo": "tokens\/get.md", @@ -40140,7 +40245,7 @@ "x-appwrite": { "method": "update", "group": "tokens", - "weight": 508, + "weight": 509, "cookies": false, "type": "", "demo": "tokens\/update.md", @@ -40211,7 +40316,7 @@ "x-appwrite": { "method": "delete", "group": "tokens", - "weight": 509, + "weight": 510, "cookies": false, "type": "", "demo": "tokens\/delete.md", diff --git a/app/config/specs/swagger2-latest-server.json b/app/config/specs/swagger2-latest-server.json index 98077f1050..c7a5a20c24 100644 --- a/app/config/specs/swagger2-latest-server.json +++ b/app/config/specs/swagger2-latest-server.json @@ -20226,6 +20226,112 @@ ] } }, + "\/sites\/direct": { + "post": { + "summary": "Create direct deployment", + "operationId": "sitesCreateDirectDeployment", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "sites" + ], + "description": "Create a deployment directly from a repository branch.", + "responses": { + "202": { + "description": "Deployment", + "schema": { + "$ref": "#\/definitions\/deployment" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "createDirectDeployment", + "group": "deployments", + "weight": 483, + "cookies": false, + "type": "", + "demo": "sites\/create-direct-deployment.md", + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/masterCreate a deployment directly from a repository branch.", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "sites.write", + "platforms": [ + "server" + ], + "packaging": false, + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "siteId": { + "type": "string", + "description": "Site ID.", + "default": null, + "x-example": "" + }, + "repository": { + "type": "string", + "description": "Repository name of the template.", + "default": null, + "x-example": "" + }, + "owner": { + "type": "string", + "description": "The name of the owner of the template.", + "default": null, + "x-example": "" + }, + "rootDirectory": { + "type": "string", + "description": "Path to site code in the template repo.", + "default": null, + "x-example": "" + }, + "branch": { + "type": "string", + "description": "Branch to create deployment from.", + "default": null, + "x-example": "" + }, + "activate": { + "type": "boolean", + "description": "Automatically activate the deployment when it is finished building.", + "default": true, + "x-example": false + } + }, + "required": [ + "siteId", + "repository", + "owner", + "rootDirectory", + "branch" + ] + } + } + ] + } + }, "\/sites\/frameworks": { "get": { "summary": "List frameworks", @@ -20300,7 +20406,7 @@ "x-appwrite": { "method": "listSpecifications", "group": "frameworks", - "weight": 495, + "weight": 496, "cookies": false, "type": "", "demo": "sites\/list-specifications.md", @@ -21566,7 +21672,7 @@ "x-appwrite": { "method": "listLogs", "group": "logs", - "weight": 484, + "weight": 485, "cookies": false, "type": "", "demo": "sites\/list-logs.md", @@ -21638,7 +21744,7 @@ "x-appwrite": { "method": "getLog", "group": "logs", - "weight": 483, + "weight": 484, "cookies": false, "type": "", "demo": "sites\/get-log.md", @@ -21703,7 +21809,7 @@ "x-appwrite": { "method": "deleteLog", "group": "logs", - "weight": 485, + "weight": 486, "cookies": false, "type": "", "demo": "sites\/delete-log.md", @@ -21771,7 +21877,7 @@ "x-appwrite": { "method": "listVariables", "group": "variables", - "weight": 488, + "weight": 489, "cookies": false, "type": "", "demo": "sites\/list-variables.md", @@ -21831,7 +21937,7 @@ "x-appwrite": { "method": "createVariable", "group": "variables", - "weight": 486, + "weight": 487, "cookies": false, "type": "", "demo": "sites\/create-variable.md", @@ -21922,7 +22028,7 @@ "x-appwrite": { "method": "getVariable", "group": "variables", - "weight": 487, + "weight": 488, "cookies": false, "type": "", "demo": "sites\/get-variable.md", @@ -21990,7 +22096,7 @@ "x-appwrite": { "method": "updateVariable", "group": "variables", - "weight": 489, + "weight": 490, "cookies": false, "type": "", "demo": "sites\/update-variable.md", @@ -22083,7 +22189,7 @@ "x-appwrite": { "method": "deleteVariable", "group": "variables", - "weight": 490, + "weight": 491, "cookies": false, "type": "", "demo": "sites\/delete-variable.md", @@ -30036,7 +30142,7 @@ "x-appwrite": { "method": "list", "group": "files", - "weight": 507, + "weight": 508, "cookies": false, "type": "", "demo": "tokens\/list.md", @@ -30117,7 +30223,7 @@ "x-appwrite": { "method": "createFileToken", "group": "files", - "weight": 505, + "weight": 506, "cookies": false, "type": "", "demo": "tokens\/create-file-token.md", @@ -30202,7 +30308,7 @@ "x-appwrite": { "method": "get", "group": "tokens", - "weight": 506, + "weight": 507, "cookies": false, "type": "", "demo": "tokens\/get.md", @@ -30263,7 +30369,7 @@ "x-appwrite": { "method": "update", "group": "tokens", - "weight": 508, + "weight": 509, "cookies": false, "type": "", "demo": "tokens\/update.md", @@ -30335,7 +30441,7 @@ "x-appwrite": { "method": "delete", "group": "tokens", - "weight": 509, + "weight": 510, "cookies": false, "type": "", "demo": "tokens\/delete.md", diff --git a/src/Appwrite/Platform/Modules/Functions/Workers/Builds.php b/src/Appwrite/Platform/Modules/Functions/Workers/Builds.php index 9547a752ef..2ac05eae77 100644 --- a/src/Appwrite/Platform/Modules/Functions/Workers/Builds.php +++ b/src/Appwrite/Platform/Modules/Functions/Workers/Builds.php @@ -311,19 +311,27 @@ class Builds extends Action $templateRepositoryName = $template->getAttribute('repositoryName', ''); $templateOwnerName = $template->getAttribute('ownerName', ''); $templateVersion = $template->getAttribute('version', ''); + $templateBranch = $template->getAttribute('branch', ''); $templateRootDirectory = $template->getAttribute('rootDirectory', ''); $templateRootDirectory = \rtrim($templateRootDirectory, '/'); $templateRootDirectory = \ltrim($templateRootDirectory, '.'); $templateRootDirectory = \ltrim($templateRootDirectory, '/'); - if (!empty($templateRepositoryName) && !empty($templateOwnerName) && !empty($templateVersion)) { + if (!empty($templateRepositoryName) && !empty($templateOwnerName) && (!empty($templateVersion) || !empty($templateBranch))) { $stdout = ''; $stderr = ''; // Clone template repo $tmpTemplateDirectory = '/tmp/builds/' . $deploymentId . '-template'; - $gitCloneCommandForTemplate = $github->generateCloneCommand($templateOwnerName, $templateRepositoryName, $templateVersion, GitHub::CLONE_TYPE_TAG, $tmpTemplateDirectory, $templateRootDirectory); + + if(empty($templateVersion)) { + $gitCloneCommandForTemplate = $github->generateCloneCommand($templateOwnerName, $templateRepositoryName, $templateBranch, GitHub::CLONE_TYPE_BRANCH, $tmpTemplateDirectory, $templateRootDirectory); + } else { + // True template + $gitCloneCommandForTemplate = $github->generateCloneCommand($templateOwnerName, $templateRepositoryName, $templateVersion, GitHub::CLONE_TYPE_TAG, $tmpTemplateDirectory, $templateRootDirectory); + } + $exit = Console::execute($gitCloneCommandForTemplate, '', $stdout, $stderr); if ($exit !== 0) { diff --git a/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Direct/Create.php b/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Direct/Create.php new file mode 100644 index 0000000000..092a7702df --- /dev/null +++ b/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Direct/Create.php @@ -0,0 +1,231 @@ +setHttpMethod(Action::HTTP_REQUEST_METHOD_POST) + ->setHttpPath('/v1/sites/direct') + ->desc('Create direct deployment') + ->groups(['api', 'sites']) + ->label('scope', 'sites.write') + ->label('resourceType', RESOURCE_TYPE_SITES) + ->label('event', 'sites.[siteId].deployments.[deploymentId].create') + ->label('audits.event', 'deployment.create') + ->label('audits.resource', 'site/{request.siteId}') + ->label('sdk', new Method( + namespace: 'sites', + group: 'deployments', + name: 'createDirectDeployment', + description: <<param('siteId', '', new UID(), 'Site ID.') + ->param('repository', '', new Text(128, 0), 'Repository name of the template.') + ->param('owner', '', new Text(128, 0), 'The name of the owner of the template.') + ->param('rootDirectory', '', new Text(128, 0), 'Path to site code in the template repo.') + ->param('branch', '', new Text(128, 0), 'Branch to create deployment from.') + ->param('activate', true, new Boolean(), 'Automatically activate the deployment when it is finished building.', true) + ->inject('request') + ->inject('response') + ->inject('dbForProject') + ->inject('dbForPlatform') + ->inject('project') + ->inject('queueForEvents') + ->inject('queueForBuilds') + ->inject('gitHub') + ->callback($this->action(...)); + } + + public function action( + string $siteId, + string $repository, + string $owner, + string $rootDirectory, + string $branch, + bool $activate, + Request $request, + Response $response, + Database $dbForProject, + Database $dbForPlatform, + Document $project, + Event $queueForEvents, + Build $queueForBuilds, + GitHub $github + ) { + $site = $dbForProject->getDocument('sites', $siteId); + + if ($site->isEmpty()) { + throw new Exception(Exception::SITE_NOT_FOUND); + } + + $template = new Document([ + 'repositoryName' => $repository, + 'ownerName' => $owner, + 'rootDirectory' => $rootDirectory, + 'branch' => $branch + ]); + + + if (!empty($site->getAttribute('providerRepositoryId'))) { + $installation = $dbForPlatform->getDocument('installations', $site->getAttribute('installationId')); + + $deployment = $this->redeployVcsSite( + request: $request, + site: $site, + project: $project, + installation: $installation, + dbForProject: $dbForProject, + dbForPlatform: $dbForPlatform, + queueForBuilds: $queueForBuilds, + template: $template, + github: $github, + activate: $activate, + ); + + $queueForEvents + ->setParam('siteId', $site->getId()) + ->setParam('deploymentId', $deployment->getId()); + + $response + ->setStatusCode(Response::STATUS_CODE_ACCEPTED) + ->dynamic($deployment, Response::MODEL_DEPLOYMENT); + + return; + } + + $branchUrl = "https://github.com/$owner/$repository/tree/$branch"; + $repositoryUrl = "https://github.com/$owner/$repository"; + + try { + $commitDetails = $github->getLatestCommit($owner, $repository, $branch); + } catch (\Throwable $error) { + // Ignore; deployment can continue + } + + $commands = []; + if (!empty($site->getAttribute('installCommand', ''))) { + $commands[] = $site->getAttribute('installCommand', ''); + } + if (!empty($site->getAttribute('buildCommand', ''))) { + $commands[] = $site->getAttribute('buildCommand', ''); + } + + $deploymentId = ID::unique(); + $deployment = $dbForProject->createDocument('deployments', new Document([ + '$id' => $deploymentId, + '$permissions' => [ + Permission::read(Role::any()), + Permission::update(Role::any()), + Permission::delete(Role::any()), + ], + 'resourceId' => $site->getId(), + 'resourceInternalId' => $site->getSequence(), + 'resourceType' => 'sites', + 'buildCommands' => \implode(' && ', $commands), + 'buildOutput' => $site->getAttribute('outputDirectory', ''), + 'adapter' => $site->getAttribute('adapter', ''), + 'fallbackFile' => $site->getAttribute('fallbackFile', ''), + 'providerRepositoryName' => $repository, + 'providerRepositoryOwner' => $owner, + 'providerRepositoryUrl' => $repositoryUrl, + 'providerBranchUrl' => $branchUrl, + 'providerBranch' => $branch, + 'providerCommitHash' => $commitDetails['commitHash'] ?? '', + 'providerCommitAuthorUrl' => $commitDetails['commitAuthorUrl'] ?? '', + 'providerCommitAuthor' => $commitDetails['commitAuthor'] ?? '', + 'providerCommitMessage' => mb_strimwidth($commitDetails['commitMessage'] ?? '', 0, 255, '...'), + 'providerCommitUrl' => $commitDetails['commitUrl'] ?? '', + 'type' => 'vcs', + 'activate' => $activate, + ])); + + $site = $site + ->setAttribute('latestDeploymentId', $deployment->getId()) + ->setAttribute('latestDeploymentInternalId', $deployment->getSequence()) + ->setAttribute('latestDeploymentCreatedAt', $deployment->getCreatedAt()) + ->setAttribute('latestDeploymentStatus', $deployment->getAttribute('status', '')); + $dbForProject->updateDocument('sites', $site->getId(), $site); + + $sitesDomain = System::getEnv('_APP_DOMAIN_SITES', ''); + $domain = ID::unique() . "." . $sitesDomain; + + // TODO: @christyjacob remove once we migrate the rules in 1.7.x + $ruleId = System::getEnv('_APP_RULES_FORMAT') === 'md5' ? md5($domain) : ID::unique(); + + Authorization::skip( + fn () => $dbForPlatform->createDocument('rules', new Document([ + '$id' => $ruleId, + 'projectId' => $project->getId(), + 'projectInternalId' => $project->getSequence(), + 'domain' => $domain, + 'type' => 'deployment', + 'trigger' => 'deployment', + 'deploymentId' => $deployment->isEmpty() ? '' : $deployment->getId(), + 'deploymentInternalId' => $deployment->isEmpty() ? '' : $deployment->getSequence(), + 'deploymentResourceType' => 'site', + 'deploymentResourceId' => $site->getId(), + 'deploymentResourceInternalId' => $site->getSequence(), + 'status' => 'verified', + 'certificateId' => '', + 'owner' => 'Appwrite', + 'region' => $project->getAttribute('region') + ])) + ); + + $queueForBuilds + ->setType(BUILD_TYPE_DEPLOYMENT) + ->setResource($site) + ->setDeployment($deployment) + ->setTemplate($template); + + $queueForEvents + ->setParam('siteId', $site->getId()) + ->setParam('deploymentId', $deployment->getId()); + + $response + ->setStatusCode(Response::STATUS_CODE_ACCEPTED) + ->dynamic($deployment, Response::MODEL_DEPLOYMENT); + } +} diff --git a/src/Appwrite/Platform/Modules/Sites/Services/Http.php b/src/Appwrite/Platform/Modules/Sites/Services/Http.php index 6bd151f97e..f19b9b6d71 100644 --- a/src/Appwrite/Platform/Modules/Sites/Services/Http.php +++ b/src/Appwrite/Platform/Modules/Sites/Services/Http.php @@ -6,6 +6,7 @@ use Appwrite\Platform\Modules\Sites\Http\Deployments\Create as CreateDeployment; use Appwrite\Platform\Modules\Sites\Http\Deployments\Delete as DeleteDeployment; use Appwrite\Platform\Modules\Sites\Http\Deployments\Download\Get as DownloadDeployment; use Appwrite\Platform\Modules\Sites\Http\Deployments\Duplicate\Create as CreateDuplicateDeployment; +use Appwrite\Platform\Modules\Sites\Http\Deployments\Direct\Create as CreateDirectDeployment; use Appwrite\Platform\Modules\Sites\Http\Deployments\Get as GetDeployment; use Appwrite\Platform\Modules\Sites\Http\Deployments\Status\Update as UpdateDeploymentStatus; use Appwrite\Platform\Modules\Sites\Http\Deployments\Template\Create as CreateTemplateDeployment; @@ -60,6 +61,7 @@ class Http extends Service $this->addAction(DownloadDeployment::getName(), new DownloadDeployment()); $this->addAction(CreateDuplicateDeployment::getName(), new CreateDuplicateDeployment()); $this->addAction(UpdateDeploymentStatus::getName(), new UpdateDeploymentStatus()); + $this->addAction(CreateDirectDeployment::getName(), new CreateDirectDeployment()); // Logs $this->addAction(GetLog::getName(), new GetLog()); From 4858317891faa2a5a0bdcaf4ea3f976d223ae125 Mon Sep 17 00:00:00 2001 From: Atharva Deosthale Date: Sat, 13 Sep 2025 18:02:13 +0530 Subject: [PATCH 02/24] fix: format, lints --- .../Platform/Modules/Functions/Workers/Builds.php | 4 ++-- .../Modules/Sites/Http/Deployments/Direct/Create.php | 8 ++++---- src/Appwrite/Platform/Modules/Sites/Services/Http.php | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/Appwrite/Platform/Modules/Functions/Workers/Builds.php b/src/Appwrite/Platform/Modules/Functions/Workers/Builds.php index 2ac05eae77..62ee96da47 100644 --- a/src/Appwrite/Platform/Modules/Functions/Workers/Builds.php +++ b/src/Appwrite/Platform/Modules/Functions/Workers/Builds.php @@ -324,8 +324,8 @@ class Builds extends Action // Clone template repo $tmpTemplateDirectory = '/tmp/builds/' . $deploymentId . '-template'; - - if(empty($templateVersion)) { + + if (empty($templateVersion)) { $gitCloneCommandForTemplate = $github->generateCloneCommand($templateOwnerName, $templateRepositoryName, $templateBranch, GitHub::CLONE_TYPE_BRANCH, $tmpTemplateDirectory, $templateRootDirectory); } else { // True template diff --git a/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Direct/Create.php b/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Direct/Create.php index 092a7702df..d1df994149 100644 --- a/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Direct/Create.php +++ b/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Direct/Create.php @@ -106,7 +106,7 @@ class Create extends Base 'rootDirectory' => $rootDirectory, 'branch' => $branch ]); - + if (!empty($site->getAttribute('providerRepositoryId'))) { $installation = $dbForPlatform->getDocument('installations', $site->getAttribute('installationId')); @@ -137,11 +137,11 @@ class Create extends Base $branchUrl = "https://github.com/$owner/$repository/tree/$branch"; $repositoryUrl = "https://github.com/$owner/$repository"; - + try { - $commitDetails = $github->getLatestCommit($owner, $repository, $branch); + $commitDetails = $github->getLatestCommit($owner, $repository, $branch); } catch (\Throwable $error) { - // Ignore; deployment can continue + // Ignore; deployment can continue } $commands = []; diff --git a/src/Appwrite/Platform/Modules/Sites/Services/Http.php b/src/Appwrite/Platform/Modules/Sites/Services/Http.php index f19b9b6d71..437356d4e2 100644 --- a/src/Appwrite/Platform/Modules/Sites/Services/Http.php +++ b/src/Appwrite/Platform/Modules/Sites/Services/Http.php @@ -4,9 +4,9 @@ namespace Appwrite\Platform\Modules\Sites\Services; use Appwrite\Platform\Modules\Sites\Http\Deployments\Create as CreateDeployment; use Appwrite\Platform\Modules\Sites\Http\Deployments\Delete as DeleteDeployment; +use Appwrite\Platform\Modules\Sites\Http\Deployments\Direct\Create as CreateDirectDeployment; use Appwrite\Platform\Modules\Sites\Http\Deployments\Download\Get as DownloadDeployment; use Appwrite\Platform\Modules\Sites\Http\Deployments\Duplicate\Create as CreateDuplicateDeployment; -use Appwrite\Platform\Modules\Sites\Http\Deployments\Direct\Create as CreateDirectDeployment; use Appwrite\Platform\Modules\Sites\Http\Deployments\Get as GetDeployment; use Appwrite\Platform\Modules\Sites\Http\Deployments\Status\Update as UpdateDeploymentStatus; use Appwrite\Platform\Modules\Sites\Http\Deployments\Template\Create as CreateTemplateDeployment; From 2b1e3bd9477941431f3f5055ea118b1fe62e9067 Mon Sep 17 00:00:00 2001 From: Atharva Deosthale Date: Sun, 14 Sep 2025 15:15:44 +0530 Subject: [PATCH 03/24] delete the new route and just do it in template route --- .../Http/Deployments/Template/Create.php | 26 ++++++++++++++++--- .../Modules/Functions/Workers/Builds.php | 13 +++------- .../Http/Deployments/Template/Create.php | 26 ++++++++++++++++--- 3 files changed, 50 insertions(+), 15 deletions(-) diff --git a/src/Appwrite/Platform/Modules/Functions/Http/Deployments/Template/Create.php b/src/Appwrite/Platform/Modules/Functions/Http/Deployments/Template/Create.php index 4d93c8e8cd..885e23bfa1 100644 --- a/src/Appwrite/Platform/Modules/Functions/Http/Deployments/Template/Create.php +++ b/src/Appwrite/Platform/Modules/Functions/Http/Deployments/Template/Create.php @@ -65,7 +65,9 @@ class Create extends Base ->param('repository', '', new Text(128, 0), 'Repository name of the template.') ->param('owner', '', new Text(128, 0), 'The name of the owner of the template.') ->param('rootDirectory', '', new Text(128, 0), 'Path to function code in the template repo.') - ->param('version', '', new Text(128, 0), 'Version (tag) for the repo linked to the function template.') + ->param('version', '', new Text(128, 0), 'Version (tag) for the repo linked to the function template.', true) + ->param('type', '', new Text(128, 0), 'Type for the reference provided. Can be commit, branch, or version', true) + ->param('reference', '', new Text(128, 0), 'Reference value, can be a commit hash, branch name, or release tag', true) ->param('activate', false, new Boolean(), 'Automatically activate the deployment when it is finished building.', true) ->inject('request') ->inject('response') @@ -84,6 +86,8 @@ class Create extends Base string $owner, string $rootDirectory, string $version, + string $type, + string $reference, bool $activate, Request $request, Response $response, @@ -100,11 +104,22 @@ class Create extends Base throw new Exception(Exception::FUNCTION_NOT_FOUND); } + if (empty($version) && empty($type) && empty($reference)) { + throw new Exception("Either version or type & reference must be provided"); + } + + $referenceType = !empty($version) ? GitHub::CLONE_TYPE_TAG : $type; + $referenceValue = !empty($version) ? $version : $reference; + + $branchUrl = $type == GitHub::CLONE_TYPE_BRANCH ? "https://github.com/$owner/$repository/tree/$referenceValue" : ""; + $repositoryUrl = "https://github.com/$owner/$repository"; + $template = new Document([ 'repositoryName' => $repository, 'ownerName' => $owner, 'rootDirectory' => $rootDirectory, - 'version' => $version + 'referenceType' => $referenceType, + 'referenceValue' => $referenceValue, ]); if (!empty($function->getAttribute('providerRepositoryId'))) { @@ -146,7 +161,12 @@ class Create extends Base 'resourceType' => 'functions', 'entrypoint' => $function->getAttribute('entrypoint', ''), 'buildCommands' => $function->getAttribute('commands', ''), - 'type' => 'manual', + 'providerRepositoryName' => $repository, + 'providerRepositoryOwner' => $owner, + 'providerRepositoryUrl' => $repositoryUrl, + 'providerBranchUrl' => $branchUrl, + 'providerBranch' => $type == GitHub::CLONE_TYPE_BRANCH ? $referenceValue : '', + 'type' => 'vcs', 'activate' => $activate, ])); diff --git a/src/Appwrite/Platform/Modules/Functions/Workers/Builds.php b/src/Appwrite/Platform/Modules/Functions/Workers/Builds.php index 62ee96da47..4bb49a42c8 100644 --- a/src/Appwrite/Platform/Modules/Functions/Workers/Builds.php +++ b/src/Appwrite/Platform/Modules/Functions/Workers/Builds.php @@ -310,27 +310,22 @@ class Builds extends Action // Non-VCS + Template $templateRepositoryName = $template->getAttribute('repositoryName', ''); $templateOwnerName = $template->getAttribute('ownerName', ''); - $templateVersion = $template->getAttribute('version', ''); - $templateBranch = $template->getAttribute('branch', ''); + $templateReferenceType = $template->getAttribute('referenceType', ''); + $templateReferenceValue = $template->getAttribute('referenceValue', ''); $templateRootDirectory = $template->getAttribute('rootDirectory', ''); $templateRootDirectory = \rtrim($templateRootDirectory, '/'); $templateRootDirectory = \ltrim($templateRootDirectory, '.'); $templateRootDirectory = \ltrim($templateRootDirectory, '/'); - if (!empty($templateRepositoryName) && !empty($templateOwnerName) && (!empty($templateVersion) || !empty($templateBranch))) { + if (!empty($templateRepositoryName) && !empty($templateOwnerName) && !empty($templateReferenceType) && !empty($templateReferenceValue)) { $stdout = ''; $stderr = ''; // Clone template repo $tmpTemplateDirectory = '/tmp/builds/' . $deploymentId . '-template'; - if (empty($templateVersion)) { - $gitCloneCommandForTemplate = $github->generateCloneCommand($templateOwnerName, $templateRepositoryName, $templateBranch, GitHub::CLONE_TYPE_BRANCH, $tmpTemplateDirectory, $templateRootDirectory); - } else { - // True template - $gitCloneCommandForTemplate = $github->generateCloneCommand($templateOwnerName, $templateRepositoryName, $templateVersion, GitHub::CLONE_TYPE_TAG, $tmpTemplateDirectory, $templateRootDirectory); - } + $gitCloneCommandForTemplate = $github->generateCloneCommand($templateOwnerName, $templateRepositoryName, $templateReferenceValue, $templateReferenceType, $tmpTemplateDirectory, $templateRootDirectory); $exit = Console::execute($gitCloneCommandForTemplate, '', $stdout, $stderr); diff --git a/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Template/Create.php b/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Template/Create.php index a2040d830b..0799e0b51f 100644 --- a/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Template/Create.php +++ b/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Template/Create.php @@ -67,7 +67,9 @@ class Create extends Base ->param('repository', '', new Text(128, 0), 'Repository name of the template.') ->param('owner', '', new Text(128, 0), 'The name of the owner of the template.') ->param('rootDirectory', '', new Text(128, 0), 'Path to site code in the template repo.') - ->param('version', '', new Text(128, 0), 'Version (tag) for the repo linked to the site template.') + ->param('version', '', new Text(128, 0), 'Version (tag) for the repo linked to the function template.', true) + ->param('type', '', new Text(128, 0), 'Type for the reference provided. Can be commit, branch, or version', true) + ->param('reference', '', new Text(128, 0), 'Reference value, can be a commit hash, branch name, or release tag', true) ->param('activate', false, new Boolean(), 'Automatically activate the deployment when it is finished building.', true) ->inject('request') ->inject('response') @@ -86,6 +88,8 @@ class Create extends Base string $owner, string $rootDirectory, string $version, + string $type, + string $reference, bool $activate, Request $request, Response $response, @@ -102,11 +106,22 @@ class Create extends Base throw new Exception(Exception::SITE_NOT_FOUND); } + if (empty($version) && empty($type) && empty($reference)) { + throw new Exception("Either version or type & reference must be provided"); + } + + $referenceType = !empty($version) ? GitHub::CLONE_TYPE_TAG : $type; + $referenceValue = !empty($version) ? $version : $reference; + + $branchUrl = $type == GitHub::CLONE_TYPE_BRANCH ? "https://github.com/$owner/$repository/tree/$referenceValue" : ""; + $repositoryUrl = "https://github.com/$owner/$repository"; + $template = new Document([ 'repositoryName' => $repository, 'ownerName' => $owner, 'rootDirectory' => $rootDirectory, - 'version' => $version + 'referenceType' => $referenceType, + 'referenceValue' => $referenceValue ]); if (!empty($site->getAttribute('providerRepositoryId'))) { @@ -157,9 +172,14 @@ class Create extends Base 'resourceType' => 'sites', 'buildCommands' => \implode(' && ', $commands), 'buildOutput' => $site->getAttribute('outputDirectory', ''), + 'providerRepositoryName' => $repository, + 'providerRepositoryOwner' => $owner, + 'providerRepositoryUrl' => $repositoryUrl, + 'providerBranchUrl' => $branchUrl, + 'providerBranch' => $type == GitHub::CLONE_TYPE_BRANCH ? $referenceValue : '', 'adapter' => $site->getAttribute('adapter', ''), 'fallbackFile' => $site->getAttribute('fallbackFile', ''), - 'type' => 'manual', + 'type' => 'vcs', 'activate' => $activate, ])); From cb03bfe74ccd1ac43737053113b27a82e8bd3cbd Mon Sep 17 00:00:00 2001 From: Atharva Deosthale Date: Sun, 14 Sep 2025 15:22:51 +0530 Subject: [PATCH 04/24] specs and sdk --- .../specs/open-api3-latest-console.json | 179 ++++---------- app/config/specs/open-api3-latest-server.json | 154 +++--------- app/config/specs/swagger2-latest-console.json | 195 +++++---------- app/config/specs/swagger2-latest-server.json | 170 ++++--------- .../Sites/Http/Deployments/Direct/Create.php | 231 ------------------ .../Platform/Modules/Sites/Services/Http.php | 2 - 6 files changed, 186 insertions(+), 745 deletions(-) delete mode 100644 src/Appwrite/Platform/Modules/Sites/Http/Deployments/Direct/Create.php diff --git a/app/config/specs/open-api3-latest-console.json b/app/config/specs/open-api3-latest-console.json index 0de652e3fb..96cec5c5a6 100644 --- a/app/config/specs/open-api3-latest-console.json +++ b/app/config/specs/open-api3-latest-console.json @@ -4888,7 +4888,7 @@ "x-appwrite": { "method": "getResource", "group": null, - "weight": 497, + "weight": 496, "cookies": false, "type": "", "demo": "console\/get-resource.md", @@ -12932,6 +12932,16 @@ "description": "Version (tag) for the repo linked to the function template.", "x-example": "" }, + "type": { + "type": "string", + "description": "Type for the reference provided. Can be commit, branch, or version", + "x-example": "" + }, + "reference": { + "type": "string", + "description": "Reference value, can be a commit hash, branch name, or release tag", + "x-example": "" + }, "activate": { "type": "boolean", "description": "Automatically activate the deployment when it is finished building.", @@ -12941,8 +12951,7 @@ "required": [ "repository", "owner", - "rootDirectory", - "version" + "rootDirectory" ] } } @@ -28209,7 +28218,7 @@ "x-appwrite": { "method": "listRules", "group": null, - "weight": 503, + "weight": 502, "cookies": false, "type": "", "demo": "proxy\/list-rules.md", @@ -28283,7 +28292,7 @@ "x-appwrite": { "method": "createAPIRule", "group": null, - "weight": 498, + "weight": 497, "cookies": false, "type": "", "demo": "proxy\/create-api-rule.md", @@ -28350,7 +28359,7 @@ "x-appwrite": { "method": "createFunctionRule", "group": null, - "weight": 500, + "weight": 499, "cookies": false, "type": "", "demo": "proxy\/create-function-rule.md", @@ -28428,7 +28437,7 @@ "x-appwrite": { "method": "createRedirectRule", "group": null, - "weight": 501, + "weight": 500, "cookies": false, "type": "", "demo": "proxy\/create-redirect-rule.md", @@ -28541,7 +28550,7 @@ "x-appwrite": { "method": "createSiteRule", "group": null, - "weight": 499, + "weight": 498, "cookies": false, "type": "", "demo": "proxy\/create-site-rule.md", @@ -28619,7 +28628,7 @@ "x-appwrite": { "method": "getRule", "group": null, - "weight": 502, + "weight": 501, "cookies": false, "type": "", "demo": "proxy\/get-rule.md", @@ -28670,7 +28679,7 @@ "x-appwrite": { "method": "deleteRule", "group": null, - "weight": 504, + "weight": 503, "cookies": false, "type": "", "demo": "proxy\/delete-rule.md", @@ -28730,7 +28739,7 @@ "x-appwrite": { "method": "updateRuleVerification", "group": null, - "weight": 505, + "weight": 504, "cookies": false, "type": "", "demo": "proxy\/update-rule-verification.md", @@ -29085,103 +29094,6 @@ } } }, - "\/sites\/direct": { - "post": { - "summary": "Create direct deployment", - "operationId": "sitesCreateDirectDeployment", - "tags": [ - "sites" - ], - "description": "Create a deployment directly from a repository branch.", - "responses": { - "202": { - "description": "Deployment", - "content": { - "application\/json": { - "schema": { - "$ref": "#\/components\/schemas\/deployment" - } - } - } - } - }, - "deprecated": false, - "x-appwrite": { - "method": "createDirectDeployment", - "group": "deployments", - "weight": 483, - "cookies": false, - "type": "", - "demo": "sites\/create-direct-deployment.md", - "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/masterCreate a deployment directly from a repository branch.", - "rate-limit": 0, - "rate-time": 3600, - "rate-key": "url:{url},ip:{ip}", - "scope": "sites.write", - "platforms": [ - "server" - ], - "packaging": false, - "auth": { - "Project": [] - } - }, - "security": [ - { - "Project": [], - "Key": [] - } - ], - "requestBody": { - "content": { - "application\/json": { - "schema": { - "type": "object", - "properties": { - "siteId": { - "type": "string", - "description": "Site ID.", - "x-example": "" - }, - "repository": { - "type": "string", - "description": "Repository name of the template.", - "x-example": "" - }, - "owner": { - "type": "string", - "description": "The name of the owner of the template.", - "x-example": "" - }, - "rootDirectory": { - "type": "string", - "description": "Path to site code in the template repo.", - "x-example": "" - }, - "branch": { - "type": "string", - "description": "Branch to create deployment from.", - "x-example": "" - }, - "activate": { - "type": "boolean", - "description": "Automatically activate the deployment when it is finished building.", - "x-example": false - } - }, - "required": [ - "siteId", - "repository", - "owner", - "rootDirectory", - "branch" - ] - } - } - } - } - } - }, "\/sites\/frameworks": { "get": { "summary": "List frameworks", @@ -29255,7 +29167,7 @@ "x-appwrite": { "method": "listSpecifications", "group": "frameworks", - "weight": 496, + "weight": 495, "cookies": false, "type": "", "demo": "sites\/list-specifications.md", @@ -29305,7 +29217,7 @@ "x-appwrite": { "method": "listTemplates", "group": "templates", - "weight": 492, + "weight": 491, "cookies": false, "type": "", "demo": "sites\/list-templates.md", @@ -29405,7 +29317,7 @@ "x-appwrite": { "method": "getTemplate", "group": "templates", - "weight": 493, + "weight": 492, "cookies": false, "type": "", "demo": "sites\/get-template.md", @@ -29465,7 +29377,7 @@ "x-appwrite": { "method": "listUsage", "group": null, - "weight": 494, + "weight": 493, "cookies": false, "type": "", "demo": "sites\/list-usage.md", @@ -30304,9 +30216,19 @@ }, "version": { "type": "string", - "description": "Version (tag) for the repo linked to the site template.", + "description": "Version (tag) for the repo linked to the function template.", "x-example": "" }, + "type": { + "type": "string", + "description": "Type for the reference provided. Can be commit, branch, or version", + "x-example": "" + }, + "reference": { + "type": "string", + "description": "Reference value, can be a commit hash, branch name, or release tag", + "x-example": "" + }, "activate": { "type": "boolean", "description": "Automatically activate the deployment when it is finished building.", @@ -30316,8 +30238,7 @@ "required": [ "repository", "owner", - "rootDirectory", - "version" + "rootDirectory" ] } } @@ -30734,7 +30655,7 @@ "x-appwrite": { "method": "listLogs", "group": "logs", - "weight": 485, + "weight": 484, "cookies": false, "type": "", "demo": "sites\/list-logs.md", @@ -30805,7 +30726,7 @@ "x-appwrite": { "method": "getLog", "group": "logs", - "weight": 484, + "weight": 483, "cookies": false, "type": "", "demo": "sites\/get-log.md", @@ -30867,7 +30788,7 @@ "x-appwrite": { "method": "deleteLog", "group": "logs", - "weight": 486, + "weight": 485, "cookies": false, "type": "", "demo": "sites\/delete-log.md", @@ -30938,7 +30859,7 @@ "x-appwrite": { "method": "getUsage", "group": null, - "weight": 495, + "weight": 494, "cookies": false, "type": "", "demo": "sites\/get-usage.md", @@ -31020,7 +30941,7 @@ "x-appwrite": { "method": "listVariables", "group": "variables", - "weight": 489, + "weight": 488, "cookies": false, "type": "", "demo": "sites\/list-variables.md", @@ -31079,7 +31000,7 @@ "x-appwrite": { "method": "createVariable", "group": "variables", - "weight": 487, + "weight": 486, "cookies": false, "type": "", "demo": "sites\/create-variable.md", @@ -31170,7 +31091,7 @@ "x-appwrite": { "method": "getVariable", "group": "variables", - "weight": 488, + "weight": 487, "cookies": false, "type": "", "demo": "sites\/get-variable.md", @@ -31239,7 +31160,7 @@ "x-appwrite": { "method": "updateVariable", "group": "variables", - "weight": 490, + "weight": 489, "cookies": false, "type": "", "demo": "sites\/update-variable.md", @@ -31330,7 +31251,7 @@ "x-appwrite": { "method": "deleteVariable", "group": "variables", - "weight": 491, + "weight": 490, "cookies": false, "type": "", "demo": "sites\/delete-variable.md", @@ -40081,7 +40002,7 @@ "x-appwrite": { "method": "list", "group": "files", - "weight": 508, + "weight": 507, "cookies": false, "type": "", "demo": "tokens\/list.md", @@ -40161,7 +40082,7 @@ "x-appwrite": { "method": "createFileToken", "group": "files", - "weight": 506, + "weight": 505, "cookies": false, "type": "", "demo": "tokens\/create-file-token.md", @@ -40250,7 +40171,7 @@ "x-appwrite": { "method": "get", "group": "tokens", - "weight": 507, + "weight": 506, "cookies": false, "type": "", "demo": "tokens\/get.md", @@ -40310,7 +40231,7 @@ "x-appwrite": { "method": "update", "group": "tokens", - "weight": 509, + "weight": 508, "cookies": false, "type": "", "demo": "tokens\/update.md", @@ -40380,7 +40301,7 @@ "x-appwrite": { "method": "delete", "group": "tokens", - "weight": 510, + "weight": 509, "cookies": false, "type": "", "demo": "tokens\/delete.md", diff --git a/app/config/specs/open-api3-latest-server.json b/app/config/specs/open-api3-latest-server.json index d8d7178eb2..3a1afab16b 100644 --- a/app/config/specs/open-api3-latest-server.json +++ b/app/config/specs/open-api3-latest-server.json @@ -11714,6 +11714,16 @@ "description": "Version (tag) for the repo linked to the function template.", "x-example": "" }, + "type": { + "type": "string", + "description": "Type for the reference provided. Can be commit, branch, or version", + "x-example": "" + }, + "reference": { + "type": "string", + "description": "Reference value, can be a commit hash, branch name, or release tag", + "x-example": "" + }, "activate": { "type": "boolean", "description": "Automatically activate the deployment when it is finished building.", @@ -11723,8 +11733,7 @@ "required": [ "repository", "owner", - "rootDirectory", - "version" + "rootDirectory" ] } } @@ -20014,104 +20023,6 @@ } } }, - "\/sites\/direct": { - "post": { - "summary": "Create direct deployment", - "operationId": "sitesCreateDirectDeployment", - "tags": [ - "sites" - ], - "description": "Create a deployment directly from a repository branch.", - "responses": { - "202": { - "description": "Deployment", - "content": { - "application\/json": { - "schema": { - "$ref": "#\/components\/schemas\/deployment" - } - } - } - } - }, - "deprecated": false, - "x-appwrite": { - "method": "createDirectDeployment", - "group": "deployments", - "weight": 483, - "cookies": false, - "type": "", - "demo": "sites\/create-direct-deployment.md", - "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/masterCreate a deployment directly from a repository branch.", - "rate-limit": 0, - "rate-time": 3600, - "rate-key": "url:{url},ip:{ip}", - "scope": "sites.write", - "platforms": [ - "server" - ], - "packaging": false, - "auth": { - "Project": [], - "Key": [] - } - }, - "security": [ - { - "Project": [], - "Key": [] - } - ], - "requestBody": { - "content": { - "application\/json": { - "schema": { - "type": "object", - "properties": { - "siteId": { - "type": "string", - "description": "Site ID.", - "x-example": "" - }, - "repository": { - "type": "string", - "description": "Repository name of the template.", - "x-example": "" - }, - "owner": { - "type": "string", - "description": "The name of the owner of the template.", - "x-example": "" - }, - "rootDirectory": { - "type": "string", - "description": "Path to site code in the template repo.", - "x-example": "" - }, - "branch": { - "type": "string", - "description": "Branch to create deployment from.", - "x-example": "" - }, - "activate": { - "type": "boolean", - "description": "Automatically activate the deployment when it is finished building.", - "x-example": false - } - }, - "required": [ - "siteId", - "repository", - "owner", - "rootDirectory", - "branch" - ] - } - } - } - } - } - }, "\/sites\/frameworks": { "get": { "summary": "List frameworks", @@ -20186,7 +20097,7 @@ "x-appwrite": { "method": "listSpecifications", "group": "frameworks", - "weight": 496, + "weight": 495, "cookies": false, "type": "", "demo": "sites\/list-specifications.md", @@ -21012,9 +20923,19 @@ }, "version": { "type": "string", - "description": "Version (tag) for the repo linked to the site template.", + "description": "Version (tag) for the repo linked to the function template.", "x-example": "" }, + "type": { + "type": "string", + "description": "Type for the reference provided. Can be commit, branch, or version", + "x-example": "" + }, + "reference": { + "type": "string", + "description": "Reference value, can be a commit hash, branch name, or release tag", + "x-example": "" + }, "activate": { "type": "boolean", "description": "Automatically activate the deployment when it is finished building.", @@ -21024,8 +20945,7 @@ "required": [ "repository", "owner", - "rootDirectory", - "version" + "rootDirectory" ] } } @@ -21447,7 +21367,7 @@ "x-appwrite": { "method": "listLogs", "group": "logs", - "weight": 485, + "weight": 484, "cookies": false, "type": "", "demo": "sites\/list-logs.md", @@ -21519,7 +21439,7 @@ "x-appwrite": { "method": "getLog", "group": "logs", - "weight": 484, + "weight": 483, "cookies": false, "type": "", "demo": "sites\/get-log.md", @@ -21582,7 +21502,7 @@ "x-appwrite": { "method": "deleteLog", "group": "logs", - "weight": 486, + "weight": 485, "cookies": false, "type": "", "demo": "sites\/delete-log.md", @@ -21654,7 +21574,7 @@ "x-appwrite": { "method": "listVariables", "group": "variables", - "weight": 489, + "weight": 488, "cookies": false, "type": "", "demo": "sites\/list-variables.md", @@ -21714,7 +21634,7 @@ "x-appwrite": { "method": "createVariable", "group": "variables", - "weight": 487, + "weight": 486, "cookies": false, "type": "", "demo": "sites\/create-variable.md", @@ -21806,7 +21726,7 @@ "x-appwrite": { "method": "getVariable", "group": "variables", - "weight": 488, + "weight": 487, "cookies": false, "type": "", "demo": "sites\/get-variable.md", @@ -21876,7 +21796,7 @@ "x-appwrite": { "method": "updateVariable", "group": "variables", - "weight": 490, + "weight": 489, "cookies": false, "type": "", "demo": "sites\/update-variable.md", @@ -21968,7 +21888,7 @@ "x-appwrite": { "method": "deleteVariable", "group": "variables", - "weight": 491, + "weight": 490, "cookies": false, "type": "", "demo": "sites\/delete-variable.md", @@ -30122,7 +30042,7 @@ "x-appwrite": { "method": "list", "group": "files", - "weight": 508, + "weight": 507, "cookies": false, "type": "", "demo": "tokens\/list.md", @@ -30203,7 +30123,7 @@ "x-appwrite": { "method": "createFileToken", "group": "files", - "weight": 506, + "weight": 505, "cookies": false, "type": "", "demo": "tokens\/create-file-token.md", @@ -30293,7 +30213,7 @@ "x-appwrite": { "method": "get", "group": "tokens", - "weight": 507, + "weight": 506, "cookies": false, "type": "", "demo": "tokens\/get.md", @@ -30354,7 +30274,7 @@ "x-appwrite": { "method": "update", "group": "tokens", - "weight": 509, + "weight": 508, "cookies": false, "type": "", "demo": "tokens\/update.md", @@ -30425,7 +30345,7 @@ "x-appwrite": { "method": "delete", "group": "tokens", - "weight": 510, + "weight": 509, "cookies": false, "type": "", "demo": "tokens\/delete.md", diff --git a/app/config/specs/swagger2-latest-console.json b/app/config/specs/swagger2-latest-console.json index 22823cd40e..27604767b9 100644 --- a/app/config/specs/swagger2-latest-console.json +++ b/app/config/specs/swagger2-latest-console.json @@ -5052,7 +5052,7 @@ "x-appwrite": { "method": "getResource", "group": null, - "weight": 497, + "weight": 496, "cookies": false, "type": "", "demo": "console\/get-resource.md", @@ -12928,9 +12928,21 @@ "version": { "type": "string", "description": "Version (tag) for the repo linked to the function template.", - "default": null, + "default": "", "x-example": "" }, + "type": { + "type": "string", + "description": "Type for the reference provided. Can be commit, branch, or version", + "default": "", + "x-example": "" + }, + "reference": { + "type": "string", + "description": "Reference value, can be a commit hash, branch name, or release tag", + "default": "", + "x-example": "" + }, "activate": { "type": "boolean", "description": "Automatically activate the deployment when it is finished building.", @@ -12941,8 +12953,7 @@ "required": [ "repository", "owner", - "rootDirectory", - "version" + "rootDirectory" ] } } @@ -28351,7 +28362,7 @@ "x-appwrite": { "method": "listRules", "group": null, - "weight": 503, + "weight": 502, "cookies": false, "type": "", "demo": "proxy\/list-rules.md", @@ -28424,7 +28435,7 @@ "x-appwrite": { "method": "createAPIRule", "group": null, - "weight": 498, + "weight": 497, "cookies": false, "type": "", "demo": "proxy\/create-api-rule.md", @@ -28494,7 +28505,7 @@ "x-appwrite": { "method": "createFunctionRule", "group": null, - "weight": 500, + "weight": 499, "cookies": false, "type": "", "demo": "proxy\/create-function-rule.md", @@ -28577,7 +28588,7 @@ "x-appwrite": { "method": "createRedirectRule", "group": null, - "weight": 501, + "weight": 500, "cookies": false, "type": "", "demo": "proxy\/create-redirect-rule.md", @@ -28697,7 +28708,7 @@ "x-appwrite": { "method": "createSiteRule", "group": null, - "weight": 499, + "weight": 498, "cookies": false, "type": "", "demo": "proxy\/create-site-rule.md", @@ -28778,7 +28789,7 @@ "x-appwrite": { "method": "getRule", "group": null, - "weight": 502, + "weight": 501, "cookies": false, "type": "", "demo": "proxy\/get-rule.md", @@ -28831,7 +28842,7 @@ "x-appwrite": { "method": "deleteRule", "group": null, - "weight": 504, + "weight": 503, "cookies": false, "type": "", "demo": "proxy\/delete-rule.md", @@ -28891,7 +28902,7 @@ "x-appwrite": { "method": "updateRuleVerification", "group": null, - "weight": 505, + "weight": 504, "cookies": false, "type": "", "demo": "proxy\/update-rule-verification.md", @@ -29264,111 +29275,6 @@ ] } }, - "\/sites\/direct": { - "post": { - "summary": "Create direct deployment", - "operationId": "sitesCreateDirectDeployment", - "consumes": [ - "application\/json" - ], - "produces": [ - "application\/json" - ], - "tags": [ - "sites" - ], - "description": "Create a deployment directly from a repository branch.", - "responses": { - "202": { - "description": "Deployment", - "schema": { - "$ref": "#\/definitions\/deployment" - } - } - }, - "deprecated": false, - "x-appwrite": { - "method": "createDirectDeployment", - "group": "deployments", - "weight": 483, - "cookies": false, - "type": "", - "demo": "sites\/create-direct-deployment.md", - "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/masterCreate a deployment directly from a repository branch.", - "rate-limit": 0, - "rate-time": 3600, - "rate-key": "url:{url},ip:{ip}", - "scope": "sites.write", - "platforms": [ - "server" - ], - "packaging": false, - "auth": { - "Project": [] - } - }, - "security": [ - { - "Project": [], - "Key": [] - } - ], - "parameters": [ - { - "name": "payload", - "in": "body", - "schema": { - "type": "object", - "properties": { - "siteId": { - "type": "string", - "description": "Site ID.", - "default": null, - "x-example": "" - }, - "repository": { - "type": "string", - "description": "Repository name of the template.", - "default": null, - "x-example": "" - }, - "owner": { - "type": "string", - "description": "The name of the owner of the template.", - "default": null, - "x-example": "" - }, - "rootDirectory": { - "type": "string", - "description": "Path to site code in the template repo.", - "default": null, - "x-example": "" - }, - "branch": { - "type": "string", - "description": "Branch to create deployment from.", - "default": null, - "x-example": "" - }, - "activate": { - "type": "boolean", - "description": "Automatically activate the deployment when it is finished building.", - "default": true, - "x-example": false - } - }, - "required": [ - "siteId", - "repository", - "owner", - "rootDirectory", - "branch" - ] - } - } - ] - } - }, "\/sites\/frameworks": { "get": { "summary": "List frameworks", @@ -29442,7 +29348,7 @@ "x-appwrite": { "method": "listSpecifications", "group": "frameworks", - "weight": 496, + "weight": 495, "cookies": false, "type": "", "demo": "sites\/list-specifications.md", @@ -29492,7 +29398,7 @@ "x-appwrite": { "method": "listTemplates", "group": "templates", - "weight": 492, + "weight": 491, "cookies": false, "type": "", "demo": "sites\/list-templates.md", @@ -29586,7 +29492,7 @@ "x-appwrite": { "method": "getTemplate", "group": "templates", - "weight": 493, + "weight": 492, "cookies": false, "type": "", "demo": "sites\/get-template.md", @@ -29644,7 +29550,7 @@ "x-appwrite": { "method": "listUsage", "group": null, - "weight": 494, + "weight": 493, "cookies": false, "type": "", "demo": "sites\/list-usage.md", @@ -30490,10 +30396,22 @@ }, "version": { "type": "string", - "description": "Version (tag) for the repo linked to the site template.", - "default": null, + "description": "Version (tag) for the repo linked to the function template.", + "default": "", "x-example": "" }, + "type": { + "type": "string", + "description": "Type for the reference provided. Can be commit, branch, or version", + "default": "", + "x-example": "" + }, + "reference": { + "type": "string", + "description": "Reference value, can be a commit hash, branch name, or release tag", + "default": "", + "x-example": "" + }, "activate": { "type": "boolean", "description": "Automatically activate the deployment when it is finished building.", @@ -30504,8 +30422,7 @@ "required": [ "repository", "owner", - "rootDirectory", - "version" + "rootDirectory" ] } } @@ -30916,7 +30833,7 @@ "x-appwrite": { "method": "listLogs", "group": "logs", - "weight": 485, + "weight": 484, "cookies": false, "type": "", "demo": "sites\/list-logs.md", @@ -30987,7 +30904,7 @@ "x-appwrite": { "method": "getLog", "group": "logs", - "weight": 484, + "weight": 483, "cookies": false, "type": "", "demo": "sites\/get-log.md", @@ -31051,7 +30968,7 @@ "x-appwrite": { "method": "deleteLog", "group": "logs", - "weight": 486, + "weight": 485, "cookies": false, "type": "", "demo": "sites\/delete-log.md", @@ -31118,7 +31035,7 @@ "x-appwrite": { "method": "getUsage", "group": null, - "weight": 495, + "weight": 494, "cookies": false, "type": "", "demo": "sites\/get-usage.md", @@ -31196,7 +31113,7 @@ "x-appwrite": { "method": "listVariables", "group": "variables", - "weight": 489, + "weight": 488, "cookies": false, "type": "", "demo": "sites\/list-variables.md", @@ -31255,7 +31172,7 @@ "x-appwrite": { "method": "createVariable", "group": "variables", - "weight": 487, + "weight": 486, "cookies": false, "type": "", "demo": "sites\/create-variable.md", @@ -31345,7 +31262,7 @@ "x-appwrite": { "method": "getVariable", "group": "variables", - "weight": 488, + "weight": 487, "cookies": false, "type": "", "demo": "sites\/get-variable.md", @@ -31412,7 +31329,7 @@ "x-appwrite": { "method": "updateVariable", "group": "variables", - "weight": 490, + "weight": 489, "cookies": false, "type": "", "demo": "sites\/update-variable.md", @@ -31504,7 +31421,7 @@ "x-appwrite": { "method": "deleteVariable", "group": "variables", - "weight": 491, + "weight": 490, "cookies": false, "type": "", "demo": "sites\/delete-variable.md", @@ -40021,7 +39938,7 @@ "x-appwrite": { "method": "list", "group": "files", - "weight": 508, + "weight": 507, "cookies": false, "type": "", "demo": "tokens\/list.md", @@ -40101,7 +40018,7 @@ "x-appwrite": { "method": "createFileToken", "group": "files", - "weight": 506, + "weight": 505, "cookies": false, "type": "", "demo": "tokens\/create-file-token.md", @@ -40185,7 +40102,7 @@ "x-appwrite": { "method": "get", "group": "tokens", - "weight": 507, + "weight": 506, "cookies": false, "type": "", "demo": "tokens\/get.md", @@ -40245,7 +40162,7 @@ "x-appwrite": { "method": "update", "group": "tokens", - "weight": 509, + "weight": 508, "cookies": false, "type": "", "demo": "tokens\/update.md", @@ -40316,7 +40233,7 @@ "x-appwrite": { "method": "delete", "group": "tokens", - "weight": 510, + "weight": 509, "cookies": false, "type": "", "demo": "tokens\/delete.md", diff --git a/app/config/specs/swagger2-latest-server.json b/app/config/specs/swagger2-latest-server.json index c7a5a20c24..a13c8324a4 100644 --- a/app/config/specs/swagger2-latest-server.json +++ b/app/config/specs/swagger2-latest-server.json @@ -11735,9 +11735,21 @@ "version": { "type": "string", "description": "Version (tag) for the repo linked to the function template.", - "default": null, + "default": "", "x-example": "" }, + "type": { + "type": "string", + "description": "Type for the reference provided. Can be commit, branch, or version", + "default": "", + "x-example": "" + }, + "reference": { + "type": "string", + "description": "Reference value, can be a commit hash, branch name, or release tag", + "default": "", + "x-example": "" + }, "activate": { "type": "boolean", "description": "Automatically activate the deployment when it is finished building.", @@ -11748,8 +11760,7 @@ "required": [ "repository", "owner", - "rootDirectory", - "version" + "rootDirectory" ] } } @@ -20226,112 +20237,6 @@ ] } }, - "\/sites\/direct": { - "post": { - "summary": "Create direct deployment", - "operationId": "sitesCreateDirectDeployment", - "consumes": [ - "application\/json" - ], - "produces": [ - "application\/json" - ], - "tags": [ - "sites" - ], - "description": "Create a deployment directly from a repository branch.", - "responses": { - "202": { - "description": "Deployment", - "schema": { - "$ref": "#\/definitions\/deployment" - } - } - }, - "deprecated": false, - "x-appwrite": { - "method": "createDirectDeployment", - "group": "deployments", - "weight": 483, - "cookies": false, - "type": "", - "demo": "sites\/create-direct-deployment.md", - "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/masterCreate a deployment directly from a repository branch.", - "rate-limit": 0, - "rate-time": 3600, - "rate-key": "url:{url},ip:{ip}", - "scope": "sites.write", - "platforms": [ - "server" - ], - "packaging": false, - "auth": { - "Project": [], - "Key": [] - } - }, - "security": [ - { - "Project": [], - "Key": [] - } - ], - "parameters": [ - { - "name": "payload", - "in": "body", - "schema": { - "type": "object", - "properties": { - "siteId": { - "type": "string", - "description": "Site ID.", - "default": null, - "x-example": "" - }, - "repository": { - "type": "string", - "description": "Repository name of the template.", - "default": null, - "x-example": "" - }, - "owner": { - "type": "string", - "description": "The name of the owner of the template.", - "default": null, - "x-example": "" - }, - "rootDirectory": { - "type": "string", - "description": "Path to site code in the template repo.", - "default": null, - "x-example": "" - }, - "branch": { - "type": "string", - "description": "Branch to create deployment from.", - "default": null, - "x-example": "" - }, - "activate": { - "type": "boolean", - "description": "Automatically activate the deployment when it is finished building.", - "default": true, - "x-example": false - } - }, - "required": [ - "siteId", - "repository", - "owner", - "rootDirectory", - "branch" - ] - } - } - ] - } - }, "\/sites\/frameworks": { "get": { "summary": "List frameworks", @@ -20406,7 +20311,7 @@ "x-appwrite": { "method": "listSpecifications", "group": "frameworks", - "weight": 496, + "weight": 495, "cookies": false, "type": "", "demo": "sites\/list-specifications.md", @@ -21241,10 +21146,22 @@ }, "version": { "type": "string", - "description": "Version (tag) for the repo linked to the site template.", - "default": null, + "description": "Version (tag) for the repo linked to the function template.", + "default": "", "x-example": "" }, + "type": { + "type": "string", + "description": "Type for the reference provided. Can be commit, branch, or version", + "default": "", + "x-example": "" + }, + "reference": { + "type": "string", + "description": "Reference value, can be a commit hash, branch name, or release tag", + "default": "", + "x-example": "" + }, "activate": { "type": "boolean", "description": "Automatically activate the deployment when it is finished building.", @@ -21255,8 +21172,7 @@ "required": [ "repository", "owner", - "rootDirectory", - "version" + "rootDirectory" ] } } @@ -21672,7 +21588,7 @@ "x-appwrite": { "method": "listLogs", "group": "logs", - "weight": 485, + "weight": 484, "cookies": false, "type": "", "demo": "sites\/list-logs.md", @@ -21744,7 +21660,7 @@ "x-appwrite": { "method": "getLog", "group": "logs", - "weight": 484, + "weight": 483, "cookies": false, "type": "", "demo": "sites\/get-log.md", @@ -21809,7 +21725,7 @@ "x-appwrite": { "method": "deleteLog", "group": "logs", - "weight": 486, + "weight": 485, "cookies": false, "type": "", "demo": "sites\/delete-log.md", @@ -21877,7 +21793,7 @@ "x-appwrite": { "method": "listVariables", "group": "variables", - "weight": 489, + "weight": 488, "cookies": false, "type": "", "demo": "sites\/list-variables.md", @@ -21937,7 +21853,7 @@ "x-appwrite": { "method": "createVariable", "group": "variables", - "weight": 487, + "weight": 486, "cookies": false, "type": "", "demo": "sites\/create-variable.md", @@ -22028,7 +21944,7 @@ "x-appwrite": { "method": "getVariable", "group": "variables", - "weight": 488, + "weight": 487, "cookies": false, "type": "", "demo": "sites\/get-variable.md", @@ -22096,7 +22012,7 @@ "x-appwrite": { "method": "updateVariable", "group": "variables", - "weight": 490, + "weight": 489, "cookies": false, "type": "", "demo": "sites\/update-variable.md", @@ -22189,7 +22105,7 @@ "x-appwrite": { "method": "deleteVariable", "group": "variables", - "weight": 491, + "weight": 490, "cookies": false, "type": "", "demo": "sites\/delete-variable.md", @@ -30142,7 +30058,7 @@ "x-appwrite": { "method": "list", "group": "files", - "weight": 508, + "weight": 507, "cookies": false, "type": "", "demo": "tokens\/list.md", @@ -30223,7 +30139,7 @@ "x-appwrite": { "method": "createFileToken", "group": "files", - "weight": 506, + "weight": 505, "cookies": false, "type": "", "demo": "tokens\/create-file-token.md", @@ -30308,7 +30224,7 @@ "x-appwrite": { "method": "get", "group": "tokens", - "weight": 507, + "weight": 506, "cookies": false, "type": "", "demo": "tokens\/get.md", @@ -30369,7 +30285,7 @@ "x-appwrite": { "method": "update", "group": "tokens", - "weight": 509, + "weight": 508, "cookies": false, "type": "", "demo": "tokens\/update.md", @@ -30441,7 +30357,7 @@ "x-appwrite": { "method": "delete", "group": "tokens", - "weight": 510, + "weight": 509, "cookies": false, "type": "", "demo": "tokens\/delete.md", diff --git a/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Direct/Create.php b/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Direct/Create.php deleted file mode 100644 index d1df994149..0000000000 --- a/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Direct/Create.php +++ /dev/null @@ -1,231 +0,0 @@ -setHttpMethod(Action::HTTP_REQUEST_METHOD_POST) - ->setHttpPath('/v1/sites/direct') - ->desc('Create direct deployment') - ->groups(['api', 'sites']) - ->label('scope', 'sites.write') - ->label('resourceType', RESOURCE_TYPE_SITES) - ->label('event', 'sites.[siteId].deployments.[deploymentId].create') - ->label('audits.event', 'deployment.create') - ->label('audits.resource', 'site/{request.siteId}') - ->label('sdk', new Method( - namespace: 'sites', - group: 'deployments', - name: 'createDirectDeployment', - description: <<param('siteId', '', new UID(), 'Site ID.') - ->param('repository', '', new Text(128, 0), 'Repository name of the template.') - ->param('owner', '', new Text(128, 0), 'The name of the owner of the template.') - ->param('rootDirectory', '', new Text(128, 0), 'Path to site code in the template repo.') - ->param('branch', '', new Text(128, 0), 'Branch to create deployment from.') - ->param('activate', true, new Boolean(), 'Automatically activate the deployment when it is finished building.', true) - ->inject('request') - ->inject('response') - ->inject('dbForProject') - ->inject('dbForPlatform') - ->inject('project') - ->inject('queueForEvents') - ->inject('queueForBuilds') - ->inject('gitHub') - ->callback($this->action(...)); - } - - public function action( - string $siteId, - string $repository, - string $owner, - string $rootDirectory, - string $branch, - bool $activate, - Request $request, - Response $response, - Database $dbForProject, - Database $dbForPlatform, - Document $project, - Event $queueForEvents, - Build $queueForBuilds, - GitHub $github - ) { - $site = $dbForProject->getDocument('sites', $siteId); - - if ($site->isEmpty()) { - throw new Exception(Exception::SITE_NOT_FOUND); - } - - $template = new Document([ - 'repositoryName' => $repository, - 'ownerName' => $owner, - 'rootDirectory' => $rootDirectory, - 'branch' => $branch - ]); - - - if (!empty($site->getAttribute('providerRepositoryId'))) { - $installation = $dbForPlatform->getDocument('installations', $site->getAttribute('installationId')); - - $deployment = $this->redeployVcsSite( - request: $request, - site: $site, - project: $project, - installation: $installation, - dbForProject: $dbForProject, - dbForPlatform: $dbForPlatform, - queueForBuilds: $queueForBuilds, - template: $template, - github: $github, - activate: $activate, - ); - - $queueForEvents - ->setParam('siteId', $site->getId()) - ->setParam('deploymentId', $deployment->getId()); - - $response - ->setStatusCode(Response::STATUS_CODE_ACCEPTED) - ->dynamic($deployment, Response::MODEL_DEPLOYMENT); - - return; - } - - $branchUrl = "https://github.com/$owner/$repository/tree/$branch"; - $repositoryUrl = "https://github.com/$owner/$repository"; - - try { - $commitDetails = $github->getLatestCommit($owner, $repository, $branch); - } catch (\Throwable $error) { - // Ignore; deployment can continue - } - - $commands = []; - if (!empty($site->getAttribute('installCommand', ''))) { - $commands[] = $site->getAttribute('installCommand', ''); - } - if (!empty($site->getAttribute('buildCommand', ''))) { - $commands[] = $site->getAttribute('buildCommand', ''); - } - - $deploymentId = ID::unique(); - $deployment = $dbForProject->createDocument('deployments', new Document([ - '$id' => $deploymentId, - '$permissions' => [ - Permission::read(Role::any()), - Permission::update(Role::any()), - Permission::delete(Role::any()), - ], - 'resourceId' => $site->getId(), - 'resourceInternalId' => $site->getSequence(), - 'resourceType' => 'sites', - 'buildCommands' => \implode(' && ', $commands), - 'buildOutput' => $site->getAttribute('outputDirectory', ''), - 'adapter' => $site->getAttribute('adapter', ''), - 'fallbackFile' => $site->getAttribute('fallbackFile', ''), - 'providerRepositoryName' => $repository, - 'providerRepositoryOwner' => $owner, - 'providerRepositoryUrl' => $repositoryUrl, - 'providerBranchUrl' => $branchUrl, - 'providerBranch' => $branch, - 'providerCommitHash' => $commitDetails['commitHash'] ?? '', - 'providerCommitAuthorUrl' => $commitDetails['commitAuthorUrl'] ?? '', - 'providerCommitAuthor' => $commitDetails['commitAuthor'] ?? '', - 'providerCommitMessage' => mb_strimwidth($commitDetails['commitMessage'] ?? '', 0, 255, '...'), - 'providerCommitUrl' => $commitDetails['commitUrl'] ?? '', - 'type' => 'vcs', - 'activate' => $activate, - ])); - - $site = $site - ->setAttribute('latestDeploymentId', $deployment->getId()) - ->setAttribute('latestDeploymentInternalId', $deployment->getSequence()) - ->setAttribute('latestDeploymentCreatedAt', $deployment->getCreatedAt()) - ->setAttribute('latestDeploymentStatus', $deployment->getAttribute('status', '')); - $dbForProject->updateDocument('sites', $site->getId(), $site); - - $sitesDomain = System::getEnv('_APP_DOMAIN_SITES', ''); - $domain = ID::unique() . "." . $sitesDomain; - - // TODO: @christyjacob remove once we migrate the rules in 1.7.x - $ruleId = System::getEnv('_APP_RULES_FORMAT') === 'md5' ? md5($domain) : ID::unique(); - - Authorization::skip( - fn () => $dbForPlatform->createDocument('rules', new Document([ - '$id' => $ruleId, - 'projectId' => $project->getId(), - 'projectInternalId' => $project->getSequence(), - 'domain' => $domain, - 'type' => 'deployment', - 'trigger' => 'deployment', - 'deploymentId' => $deployment->isEmpty() ? '' : $deployment->getId(), - 'deploymentInternalId' => $deployment->isEmpty() ? '' : $deployment->getSequence(), - 'deploymentResourceType' => 'site', - 'deploymentResourceId' => $site->getId(), - 'deploymentResourceInternalId' => $site->getSequence(), - 'status' => 'verified', - 'certificateId' => '', - 'owner' => 'Appwrite', - 'region' => $project->getAttribute('region') - ])) - ); - - $queueForBuilds - ->setType(BUILD_TYPE_DEPLOYMENT) - ->setResource($site) - ->setDeployment($deployment) - ->setTemplate($template); - - $queueForEvents - ->setParam('siteId', $site->getId()) - ->setParam('deploymentId', $deployment->getId()); - - $response - ->setStatusCode(Response::STATUS_CODE_ACCEPTED) - ->dynamic($deployment, Response::MODEL_DEPLOYMENT); - } -} diff --git a/src/Appwrite/Platform/Modules/Sites/Services/Http.php b/src/Appwrite/Platform/Modules/Sites/Services/Http.php index 437356d4e2..6bd151f97e 100644 --- a/src/Appwrite/Platform/Modules/Sites/Services/Http.php +++ b/src/Appwrite/Platform/Modules/Sites/Services/Http.php @@ -4,7 +4,6 @@ namespace Appwrite\Platform\Modules\Sites\Services; use Appwrite\Platform\Modules\Sites\Http\Deployments\Create as CreateDeployment; use Appwrite\Platform\Modules\Sites\Http\Deployments\Delete as DeleteDeployment; -use Appwrite\Platform\Modules\Sites\Http\Deployments\Direct\Create as CreateDirectDeployment; use Appwrite\Platform\Modules\Sites\Http\Deployments\Download\Get as DownloadDeployment; use Appwrite\Platform\Modules\Sites\Http\Deployments\Duplicate\Create as CreateDuplicateDeployment; use Appwrite\Platform\Modules\Sites\Http\Deployments\Get as GetDeployment; @@ -61,7 +60,6 @@ class Http extends Service $this->addAction(DownloadDeployment::getName(), new DownloadDeployment()); $this->addAction(CreateDuplicateDeployment::getName(), new CreateDuplicateDeployment()); $this->addAction(UpdateDeploymentStatus::getName(), new UpdateDeploymentStatus()); - $this->addAction(CreateDirectDeployment::getName(), new CreateDirectDeployment()); // Logs $this->addAction(GetLog::getName(), new GetLog()); From fca27279660b7f13ca652a0f7ae9a417fe087cf6 Mon Sep 17 00:00:00 2001 From: Atharva Deosthale Date: Sun, 14 Sep 2025 15:28:25 +0530 Subject: [PATCH 05/24] add validation for type --- .../Modules/Functions/Http/Deployments/Template/Create.php | 3 ++- .../Modules/Sites/Http/Deployments/Template/Create.php | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/Appwrite/Platform/Modules/Functions/Http/Deployments/Template/Create.php b/src/Appwrite/Platform/Modules/Functions/Http/Deployments/Template/Create.php index 885e23bfa1..6312c24d86 100644 --- a/src/Appwrite/Platform/Modules/Functions/Http/Deployments/Template/Create.php +++ b/src/Appwrite/Platform/Modules/Functions/Http/Deployments/Template/Create.php @@ -21,6 +21,7 @@ use Utopia\Platform\Scope\HTTP; use Utopia\Swoole\Request; use Utopia\Validator\Boolean; use Utopia\Validator\Text; +use Utopia\Validator\WhiteList; use Utopia\VCS\Adapter\Git\GitHub; class Create extends Base @@ -66,7 +67,7 @@ class Create extends Base ->param('owner', '', new Text(128, 0), 'The name of the owner of the template.') ->param('rootDirectory', '', new Text(128, 0), 'Path to function code in the template repo.') ->param('version', '', new Text(128, 0), 'Version (tag) for the repo linked to the function template.', true) - ->param('type', '', new Text(128, 0), 'Type for the reference provided. Can be commit, branch, or version', true) + ->param('type', '', new WhiteList(['commit', 'branch', 'tag']), 'Type for the reference provided. Can be commit, branch, or version', true) ->param('reference', '', new Text(128, 0), 'Reference value, can be a commit hash, branch name, or release tag', true) ->param('activate', false, new Boolean(), 'Automatically activate the deployment when it is finished building.', true) ->inject('request') diff --git a/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Template/Create.php b/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Template/Create.php index 0799e0b51f..3721740e7f 100644 --- a/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Template/Create.php +++ b/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Template/Create.php @@ -23,6 +23,7 @@ use Utopia\Swoole\Request; use Utopia\System\System; use Utopia\Validator\Boolean; use Utopia\Validator\Text; +use Utopia\Validator\WhiteList; use Utopia\VCS\Adapter\Git\GitHub; class Create extends Base @@ -68,7 +69,7 @@ class Create extends Base ->param('owner', '', new Text(128, 0), 'The name of the owner of the template.') ->param('rootDirectory', '', new Text(128, 0), 'Path to site code in the template repo.') ->param('version', '', new Text(128, 0), 'Version (tag) for the repo linked to the function template.', true) - ->param('type', '', new Text(128, 0), 'Type for the reference provided. Can be commit, branch, or version', true) + ->param('type', '', new WhiteList(['branch', 'commit', 'tag']), 'Type for the reference provided. Can be commit, branch, or version', true) ->param('reference', '', new Text(128, 0), 'Reference value, can be a commit hash, branch name, or release tag', true) ->param('activate', false, new Boolean(), 'Automatically activate the deployment when it is finished building.', true) ->inject('request') From de8538b6222ec78e87dc9eaa81aa5d40b0b7e4cc Mon Sep 17 00:00:00 2001 From: Atharva Deosthale Date: Thu, 18 Sep 2025 12:27:24 +0530 Subject: [PATCH 06/24] use request filters for 1.8.0 to convert into and --- app/controllers/general.php | 4 +++ .../Http/Deployments/Template/Create.php | 21 ++++-------- .../Http/Deployments/Template/Create.php | 21 ++++-------- src/Appwrite/Utopia/Request/Filters/V21.php | 34 +++++++++++++++++++ 4 files changed, 50 insertions(+), 30 deletions(-) create mode 100644 src/Appwrite/Utopia/Request/Filters/V21.php diff --git a/app/controllers/general.php b/app/controllers/general.php index 8abca96742..c663091677 100644 --- a/app/controllers/general.php +++ b/app/controllers/general.php @@ -23,6 +23,7 @@ use Appwrite\Utopia\Request\Filters\V17 as RequestV17; use Appwrite\Utopia\Request\Filters\V18 as RequestV18; use Appwrite\Utopia\Request\Filters\V19 as RequestV19; use Appwrite\Utopia\Request\Filters\V20 as RequestV20; +use Appwrite\Utopia\Request\Filters\V21 as RequestV21; use Appwrite\Utopia\Response; use Appwrite\Utopia\Response\Filters\V16 as ResponseV16; use Appwrite\Utopia\Response\Filters\V17 as ResponseV17; @@ -906,6 +907,9 @@ App::init() $dbForProject = $getProjectDB($project); $request->addFilter(new RequestV20($dbForProject, $route->getPathValues($request))); } + if (version_compare($requestFormat, '1.8.1', '<')) { + $request->addFilter(new RequestV21()); + } } $domain = $request->getHostname(); diff --git a/src/Appwrite/Platform/Modules/Functions/Http/Deployments/Template/Create.php b/src/Appwrite/Platform/Modules/Functions/Http/Deployments/Template/Create.php index 6312c24d86..5e0266a09e 100644 --- a/src/Appwrite/Platform/Modules/Functions/Http/Deployments/Template/Create.php +++ b/src/Appwrite/Platform/Modules/Functions/Http/Deployments/Template/Create.php @@ -66,9 +66,8 @@ class Create extends Base ->param('repository', '', new Text(128, 0), 'Repository name of the template.') ->param('owner', '', new Text(128, 0), 'The name of the owner of the template.') ->param('rootDirectory', '', new Text(128, 0), 'Path to function code in the template repo.') - ->param('version', '', new Text(128, 0), 'Version (tag) for the repo linked to the function template.', true) - ->param('type', '', new WhiteList(['commit', 'branch', 'tag']), 'Type for the reference provided. Can be commit, branch, or version', true) - ->param('reference', '', new Text(128, 0), 'Reference value, can be a commit hash, branch name, or release tag', true) + ->param('type', '', new WhiteList(['commit', 'branch', 'tag']), 'Type for the reference provided. Can be commit, branch, or tag') + ->param('reference', '', new Text(128, 0), 'Reference value, can be a commit hash, branch name, or release tag') ->param('activate', false, new Boolean(), 'Automatically activate the deployment when it is finished building.', true) ->inject('request') ->inject('response') @@ -86,7 +85,6 @@ class Create extends Base string $repository, string $owner, string $rootDirectory, - string $version, string $type, string $reference, bool $activate, @@ -105,22 +103,15 @@ class Create extends Base throw new Exception(Exception::FUNCTION_NOT_FOUND); } - if (empty($version) && empty($type) && empty($reference)) { - throw new Exception("Either version or type & reference must be provided"); - } - - $referenceType = !empty($version) ? GitHub::CLONE_TYPE_TAG : $type; - $referenceValue = !empty($version) ? $version : $reference; - - $branchUrl = $type == GitHub::CLONE_TYPE_BRANCH ? "https://github.com/$owner/$repository/tree/$referenceValue" : ""; + $branchUrl = $type == GitHub::CLONE_TYPE_BRANCH ? "https://github.com/$owner/$repository/tree/$reference" : ""; $repositoryUrl = "https://github.com/$owner/$repository"; $template = new Document([ 'repositoryName' => $repository, 'ownerName' => $owner, 'rootDirectory' => $rootDirectory, - 'referenceType' => $referenceType, - 'referenceValue' => $referenceValue, + 'referenceType' => $type, + 'referenceValue' => $reference, ]); if (!empty($function->getAttribute('providerRepositoryId'))) { @@ -166,7 +157,7 @@ class Create extends Base 'providerRepositoryOwner' => $owner, 'providerRepositoryUrl' => $repositoryUrl, 'providerBranchUrl' => $branchUrl, - 'providerBranch' => $type == GitHub::CLONE_TYPE_BRANCH ? $referenceValue : '', + 'providerBranch' => $type == GitHub::CLONE_TYPE_BRANCH ? $reference : '', 'type' => 'vcs', 'activate' => $activate, ])); diff --git a/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Template/Create.php b/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Template/Create.php index 3721740e7f..d7196eb3d5 100644 --- a/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Template/Create.php +++ b/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Template/Create.php @@ -68,9 +68,8 @@ class Create extends Base ->param('repository', '', new Text(128, 0), 'Repository name of the template.') ->param('owner', '', new Text(128, 0), 'The name of the owner of the template.') ->param('rootDirectory', '', new Text(128, 0), 'Path to site code in the template repo.') - ->param('version', '', new Text(128, 0), 'Version (tag) for the repo linked to the function template.', true) - ->param('type', '', new WhiteList(['branch', 'commit', 'tag']), 'Type for the reference provided. Can be commit, branch, or version', true) - ->param('reference', '', new Text(128, 0), 'Reference value, can be a commit hash, branch name, or release tag', true) + ->param('type', '', new WhiteList(['branch', 'commit', 'tag']), 'Type for the reference provided. Can be commit, branch, or tag') + ->param('reference', '', new Text(128, 0), 'Reference value, can be a commit hash, branch name, or release tag') ->param('activate', false, new Boolean(), 'Automatically activate the deployment when it is finished building.', true) ->inject('request') ->inject('response') @@ -88,7 +87,6 @@ class Create extends Base string $repository, string $owner, string $rootDirectory, - string $version, string $type, string $reference, bool $activate, @@ -107,22 +105,15 @@ class Create extends Base throw new Exception(Exception::SITE_NOT_FOUND); } - if (empty($version) && empty($type) && empty($reference)) { - throw new Exception("Either version or type & reference must be provided"); - } - - $referenceType = !empty($version) ? GitHub::CLONE_TYPE_TAG : $type; - $referenceValue = !empty($version) ? $version : $reference; - - $branchUrl = $type == GitHub::CLONE_TYPE_BRANCH ? "https://github.com/$owner/$repository/tree/$referenceValue" : ""; + $branchUrl = $type == GitHub::CLONE_TYPE_BRANCH ? "https://github.com/$owner/$repository/tree/$reference" : ""; $repositoryUrl = "https://github.com/$owner/$repository"; $template = new Document([ 'repositoryName' => $repository, 'ownerName' => $owner, 'rootDirectory' => $rootDirectory, - 'referenceType' => $referenceType, - 'referenceValue' => $referenceValue + 'referenceType' => $type, + 'referenceValue' => $reference ]); if (!empty($site->getAttribute('providerRepositoryId'))) { @@ -177,7 +168,7 @@ class Create extends Base 'providerRepositoryOwner' => $owner, 'providerRepositoryUrl' => $repositoryUrl, 'providerBranchUrl' => $branchUrl, - 'providerBranch' => $type == GitHub::CLONE_TYPE_BRANCH ? $referenceValue : '', + 'providerBranch' => $type == GitHub::CLONE_TYPE_BRANCH ? $reference : '', 'adapter' => $site->getAttribute('adapter', ''), 'fallbackFile' => $site->getAttribute('fallbackFile', ''), 'type' => 'vcs', diff --git a/src/Appwrite/Utopia/Request/Filters/V21.php b/src/Appwrite/Utopia/Request/Filters/V21.php new file mode 100644 index 0000000000..3ef0becf1d --- /dev/null +++ b/src/Appwrite/Utopia/Request/Filters/V21.php @@ -0,0 +1,34 @@ +convertVersionToTypeAndReference($content); + break; + } + return $content; + } + + /** + * Convert version parameter to type and reference for backwards compatibility + * with 1.8.0 template deployment endpoints + */ + protected function convertVersionToTypeAndReference(array $content): array + { + if (!empty($content['version'])) { + $content['type'] = 'tag'; + $content['reference'] = $content['version']; + unset($content['version']); + } + return $content; + } +} From 8e32fb05d1361778e64b583f468e2cd6d7de77f1 Mon Sep 17 00:00:00 2001 From: Atharva Deosthale Date: Thu, 18 Sep 2025 12:28:08 +0530 Subject: [PATCH 07/24] specs --- .../specs/open-api3-latest-console.json | 40 +++++++++------ app/config/specs/open-api3-latest-server.json | 40 +++++++++------ app/config/specs/swagger2-latest-console.json | 50 +++++++++++-------- app/config/specs/swagger2-latest-server.json | 50 +++++++++++-------- 4 files changed, 104 insertions(+), 76 deletions(-) diff --git a/app/config/specs/open-api3-latest-console.json b/app/config/specs/open-api3-latest-console.json index 96cec5c5a6..e052f542c9 100644 --- a/app/config/specs/open-api3-latest-console.json +++ b/app/config/specs/open-api3-latest-console.json @@ -12927,15 +12927,17 @@ "description": "Path to function code in the template repo.", "x-example": "" }, - "version": { - "type": "string", - "description": "Version (tag) for the repo linked to the function template.", - "x-example": "" - }, "type": { "type": "string", - "description": "Type for the reference provided. Can be commit, branch, or version", - "x-example": "" + "description": "Type for the reference provided. Can be commit, branch, or tag", + "x-example": "commit", + "enum": [ + "commit", + "branch", + "tag" + ], + "x-enum-name": null, + "x-enum-keys": [] }, "reference": { "type": "string", @@ -12951,7 +12953,9 @@ "required": [ "repository", "owner", - "rootDirectory" + "rootDirectory", + "type", + "reference" ] } } @@ -30214,15 +30218,17 @@ "description": "Path to site code in the template repo.", "x-example": "" }, - "version": { - "type": "string", - "description": "Version (tag) for the repo linked to the function template.", - "x-example": "" - }, "type": { "type": "string", - "description": "Type for the reference provided. Can be commit, branch, or version", - "x-example": "" + "description": "Type for the reference provided. Can be commit, branch, or tag", + "x-example": "branch", + "enum": [ + "branch", + "commit", + "tag" + ], + "x-enum-name": null, + "x-enum-keys": [] }, "reference": { "type": "string", @@ -30238,7 +30244,9 @@ "required": [ "repository", "owner", - "rootDirectory" + "rootDirectory", + "type", + "reference" ] } } diff --git a/app/config/specs/open-api3-latest-server.json b/app/config/specs/open-api3-latest-server.json index 3a1afab16b..b111f8e3e8 100644 --- a/app/config/specs/open-api3-latest-server.json +++ b/app/config/specs/open-api3-latest-server.json @@ -11709,15 +11709,17 @@ "description": "Path to function code in the template repo.", "x-example": "" }, - "version": { - "type": "string", - "description": "Version (tag) for the repo linked to the function template.", - "x-example": "" - }, "type": { "type": "string", - "description": "Type for the reference provided. Can be commit, branch, or version", - "x-example": "" + "description": "Type for the reference provided. Can be commit, branch, or tag", + "x-example": "commit", + "enum": [ + "commit", + "branch", + "tag" + ], + "x-enum-name": null, + "x-enum-keys": [] }, "reference": { "type": "string", @@ -11733,7 +11735,9 @@ "required": [ "repository", "owner", - "rootDirectory" + "rootDirectory", + "type", + "reference" ] } } @@ -20921,15 +20925,17 @@ "description": "Path to site code in the template repo.", "x-example": "" }, - "version": { - "type": "string", - "description": "Version (tag) for the repo linked to the function template.", - "x-example": "" - }, "type": { "type": "string", - "description": "Type for the reference provided. Can be commit, branch, or version", - "x-example": "" + "description": "Type for the reference provided. Can be commit, branch, or tag", + "x-example": "branch", + "enum": [ + "branch", + "commit", + "tag" + ], + "x-enum-name": null, + "x-enum-keys": [] }, "reference": { "type": "string", @@ -20945,7 +20951,9 @@ "required": [ "repository", "owner", - "rootDirectory" + "rootDirectory", + "type", + "reference" ] } } diff --git a/app/config/specs/swagger2-latest-console.json b/app/config/specs/swagger2-latest-console.json index 27604767b9..b359eaf310 100644 --- a/app/config/specs/swagger2-latest-console.json +++ b/app/config/specs/swagger2-latest-console.json @@ -12925,22 +12925,23 @@ "default": null, "x-example": "" }, - "version": { - "type": "string", - "description": "Version (tag) for the repo linked to the function template.", - "default": "", - "x-example": "" - }, "type": { "type": "string", - "description": "Type for the reference provided. Can be commit, branch, or version", - "default": "", - "x-example": "" + "description": "Type for the reference provided. Can be commit, branch, or tag", + "default": null, + "x-example": "commit", + "enum": [ + "commit", + "branch", + "tag" + ], + "x-enum-name": null, + "x-enum-keys": [] }, "reference": { "type": "string", "description": "Reference value, can be a commit hash, branch name, or release tag", - "default": "", + "default": null, "x-example": "" }, "activate": { @@ -12953,7 +12954,9 @@ "required": [ "repository", "owner", - "rootDirectory" + "rootDirectory", + "type", + "reference" ] } } @@ -30394,22 +30397,23 @@ "default": null, "x-example": "" }, - "version": { - "type": "string", - "description": "Version (tag) for the repo linked to the function template.", - "default": "", - "x-example": "" - }, "type": { "type": "string", - "description": "Type for the reference provided. Can be commit, branch, or version", - "default": "", - "x-example": "" + "description": "Type for the reference provided. Can be commit, branch, or tag", + "default": null, + "x-example": "branch", + "enum": [ + "branch", + "commit", + "tag" + ], + "x-enum-name": null, + "x-enum-keys": [] }, "reference": { "type": "string", "description": "Reference value, can be a commit hash, branch name, or release tag", - "default": "", + "default": null, "x-example": "" }, "activate": { @@ -30422,7 +30426,9 @@ "required": [ "repository", "owner", - "rootDirectory" + "rootDirectory", + "type", + "reference" ] } } diff --git a/app/config/specs/swagger2-latest-server.json b/app/config/specs/swagger2-latest-server.json index a13c8324a4..b806a9e6c7 100644 --- a/app/config/specs/swagger2-latest-server.json +++ b/app/config/specs/swagger2-latest-server.json @@ -11732,22 +11732,23 @@ "default": null, "x-example": "" }, - "version": { - "type": "string", - "description": "Version (tag) for the repo linked to the function template.", - "default": "", - "x-example": "" - }, "type": { "type": "string", - "description": "Type for the reference provided. Can be commit, branch, or version", - "default": "", - "x-example": "" + "description": "Type for the reference provided. Can be commit, branch, or tag", + "default": null, + "x-example": "commit", + "enum": [ + "commit", + "branch", + "tag" + ], + "x-enum-name": null, + "x-enum-keys": [] }, "reference": { "type": "string", "description": "Reference value, can be a commit hash, branch name, or release tag", - "default": "", + "default": null, "x-example": "" }, "activate": { @@ -11760,7 +11761,9 @@ "required": [ "repository", "owner", - "rootDirectory" + "rootDirectory", + "type", + "reference" ] } } @@ -21144,22 +21147,23 @@ "default": null, "x-example": "" }, - "version": { - "type": "string", - "description": "Version (tag) for the repo linked to the function template.", - "default": "", - "x-example": "" - }, "type": { "type": "string", - "description": "Type for the reference provided. Can be commit, branch, or version", - "default": "", - "x-example": "" + "description": "Type for the reference provided. Can be commit, branch, or tag", + "default": null, + "x-example": "branch", + "enum": [ + "branch", + "commit", + "tag" + ], + "x-enum-name": null, + "x-enum-keys": [] }, "reference": { "type": "string", "description": "Reference value, can be a commit hash, branch name, or release tag", - "default": "", + "default": null, "x-example": "" }, "activate": { @@ -21172,7 +21176,9 @@ "required": [ "repository", "owner", - "rootDirectory" + "rootDirectory", + "type", + "reference" ] } } From 9fe3e94a669240e3a8669d9da28cdea51561358a Mon Sep 17 00:00:00 2001 From: Atharva Deosthale Date: Thu, 18 Sep 2025 13:12:46 +0530 Subject: [PATCH 08/24] e2e tests --- .../e2e/Services/Functions/FunctionsBase.php | 28 ++++ .../Functions/FunctionsCustomServerTest.php | 117 +++++++++++++- tests/e2e/Services/Sites/SitesBase.php | 29 ++++ .../Services/Sites/SitesCustomServerTest.php | 149 +++++++++++++++++- 4 files changed, 321 insertions(+), 2 deletions(-) diff --git a/tests/e2e/Services/Functions/FunctionsBase.php b/tests/e2e/Services/Functions/FunctionsBase.php index 27b67d851d..4eb31c08ac 100644 --- a/tests/e2e/Services/Functions/FunctionsBase.php +++ b/tests/e2e/Services/Functions/FunctionsBase.php @@ -268,6 +268,34 @@ trait FunctionsBase 'x-appwrite-project' => $this->getProject()['$id'], ])); + // Fetch latest commit from GitHub API if template has provider info + if ( + isset($template['body']['providerOwner']) && + isset($template['body']['providerRepositoryId']) + ) { + $owner = $template['body']['providerOwner']; + $repo = $template['body']['providerRepositoryId']; + + // GitHub API to get latest commit from main branch + $ch = curl_init("https://api.github.com/repos/{$owner}/{$repo}/commits/main"); + curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); + curl_setopt($ch, CURLOPT_HTTPHEADER, [ + 'User-Agent: Appwrite', + 'Accept: application/vnd.github.v3+json' + ]); + + $response = curl_exec($ch); + $httpCode = curl_getinfo($ch, CURLINFO_HTTP_CODE); + curl_close($ch); + + if ($httpCode === 200) { + $commitData = json_decode($response, true); + if (isset($commitData['sha'])) { + $template['body']['latestCommit'] = $commitData['sha']; + } + } + } + return $template; } diff --git a/tests/e2e/Services/Functions/FunctionsCustomServerTest.php b/tests/e2e/Services/Functions/FunctionsCustomServerTest.php index 0d63791151..8a774ed8bb 100644 --- a/tests/e2e/Services/Functions/FunctionsCustomServerTest.php +++ b/tests/e2e/Services/Functions/FunctionsCustomServerTest.php @@ -400,7 +400,8 @@ class FunctionsCustomServerTest extends Scope 'repository' => $starterTemplate['body']['providerRepositoryId'], 'owner' => $starterTemplate['body']['providerOwner'], 'rootDirectory' => $phpRuntime['providerRootDirectory'], - 'version' => $starterTemplate['body']['providerVersion'], + 'type' => 'tag', + 'reference' => $starterTemplate['body']['providerVersion'], ] ); @@ -502,6 +503,120 @@ class FunctionsCustomServerTest extends Scope $function = $this->cleanupFunction($functionId); } + public function testCreateFunctionAndDeploymentFromTemplateBranch() + { + $starterTemplate = $this->getTemplate('starter'); + $this->assertEquals(200, $starterTemplate['headers']['status-code']); + + $phpRuntime = array_values(array_filter($starterTemplate['body']['runtimes'], function ($runtime) { + return $runtime['name'] === 'node-22'; + }))[0]; + + // If this fails, the template has variables, and this test needs to be updated + $this->assertEmpty($starterTemplate['body']['variables']); + + $function = $this->createFunction( + [ + 'functionId' => ID::unique(), + 'name' => $starterTemplate['body']['name'] . ' - Branch Test', + 'runtime' => 'node-22', + 'execute' => $starterTemplate['body']['permissions'], + 'entrypoint' => $phpRuntime['entrypoint'], + 'events' => $starterTemplate['body']['events'], + 'schedule' => $starterTemplate['body']['cron'], + 'timeout' => $starterTemplate['body']['timeout'], + 'commands' => $phpRuntime['commands'], + 'scopes' => $starterTemplate['body']['scopes'], + ] + ); + + $this->assertEquals(201, $function['headers']['status-code']); + $this->assertNotEmpty($function['body']['$id']); + + $functionId = $function['body']['$id'] ?? ''; + + // Deploy using branch + $deployment = $this->createTemplateDeployment( + $functionId, + [ + 'resourceId' => ID::unique(), + 'activate' => true, + 'repository' => $starterTemplate['body']['providerRepositoryId'], + 'owner' => $starterTemplate['body']['providerOwner'], + 'rootDirectory' => $phpRuntime['providerRootDirectory'], + 'type' => 'branch', + 'reference' => 'main', + ] + ); + + $this->assertEquals(202, $deployment['headers']['status-code']); + $this->assertNotEmpty($deployment['body']['$id']); + + $deployment = $this->getDeployment($functionId, $deployment['body']['$id']); + $this->assertEquals(200, $deployment['headers']['status-code']); + + $function = $this->cleanupFunction($functionId); + } + + public function testCreateFunctionAndDeploymentFromTemplateCommit() + { + $starterTemplate = $this->getTemplate('starter'); + $this->assertEquals(200, $starterTemplate['headers']['status-code']); + + // Ensure we have the latest commit + $this->assertArrayHasKey('latestCommit', $starterTemplate['body']); + $latestCommit = $starterTemplate['body']['latestCommit']; + + $phpRuntime = array_values(array_filter($starterTemplate['body']['runtimes'], function ($runtime) { + return $runtime['name'] === 'node-22'; + }))[0]; + + // If this fails, the template has variables, and this test needs to be updated + $this->assertEmpty($starterTemplate['body']['variables']); + + $function = $this->createFunction( + [ + 'functionId' => ID::unique(), + 'name' => $starterTemplate['body']['name'] . ' - Commit Test', + 'runtime' => 'node-22', + 'execute' => $starterTemplate['body']['permissions'], + 'entrypoint' => $phpRuntime['entrypoint'], + 'events' => $starterTemplate['body']['events'], + 'schedule' => $starterTemplate['body']['cron'], + 'timeout' => $starterTemplate['body']['timeout'], + 'commands' => $phpRuntime['commands'], + 'scopes' => $starterTemplate['body']['scopes'], + ] + ); + + $this->assertEquals(201, $function['headers']['status-code']); + $this->assertNotEmpty($function['body']['$id']); + + $functionId = $function['body']['$id'] ?? ''; + + // Deploy using commit + $deployment = $this->createTemplateDeployment( + $functionId, + [ + 'resourceId' => ID::unique(), + 'activate' => true, + 'repository' => $starterTemplate['body']['providerRepositoryId'], + 'owner' => $starterTemplate['body']['providerOwner'], + 'rootDirectory' => $phpRuntime['providerRootDirectory'], + 'type' => 'commit', + 'reference' => $latestCommit, + ] + ); + + $this->assertEquals(202, $deployment['headers']['status-code']); + $this->assertNotEmpty($deployment['body']['$id']); + + $deployment = $this->getDeployment($functionId, $deployment['body']['$id']); + $this->assertEquals(200, $deployment['headers']['status-code']); + + $function = $this->cleanupFunction($functionId); + } + /** * @depends testUpdateFunction */ diff --git a/tests/e2e/Services/Sites/SitesBase.php b/tests/e2e/Services/Sites/SitesBase.php index 93c55b82b7..004032452b 100644 --- a/tests/e2e/Services/Sites/SitesBase.php +++ b/tests/e2e/Services/Sites/SitesBase.php @@ -329,6 +329,35 @@ trait SitesBase 'content-type' => 'application/json', 'x-appwrite-project' => $this->getProject()['$id'], ]); + + // Fetch latest commit from GitHub API if template has provider info + if ( + isset($template['body']['providerOwner']) && + isset($template['body']['providerRepositoryId']) + ) { + $owner = $template['body']['providerOwner']; + $repo = $template['body']['providerRepositoryId']; + + // GitHub API to get latest commit from main branch + $ch = curl_init("https://api.github.com/repos/{$owner}/{$repo}/commits/main"); + curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); + curl_setopt($ch, CURLOPT_HTTPHEADER, [ + 'User-Agent: Appwrite', + 'Accept: application/vnd.github.v3+json' + ]); + + $response = curl_exec($ch); + $httpCode = curl_getinfo($ch, CURLINFO_HTTP_CODE); + curl_close($ch); + + if ($httpCode === 200) { + $commitData = json_decode($response, true); + if (isset($commitData['sha'])) { + $template['body']['latestCommit'] = $commitData['sha']; + } + } + } + return $template; } diff --git a/tests/e2e/Services/Sites/SitesCustomServerTest.php b/tests/e2e/Services/Sites/SitesCustomServerTest.php index c8301b9428..524e8a09f3 100644 --- a/tests/e2e/Services/Sites/SitesCustomServerTest.php +++ b/tests/e2e/Services/Sites/SitesCustomServerTest.php @@ -1563,7 +1563,154 @@ class SitesCustomServerTest extends Scope 'repository' => $template['providerRepositoryId'], 'owner' => $template['providerOwner'], 'rootDirectory' => $template['frameworks'][0]['providerRootDirectory'], - 'version' => $template['providerVersion'], + 'type' => 'tag', + 'reference' => $template['providerVersion'], + 'activate' => true + ]); + + $this->assertEquals(202, $deployment['headers']['status-code']); + $this->assertNotEmpty($deployment['body']['$id']); + + $deployment = $this->getDeployment($siteId, $deployment['body']['$id']); + $this->assertEquals(200, $deployment['headers']['status-code']); + $this->assertEquals(0, $deployment['body']['sourceSize']); + $this->assertEquals(0, $deployment['body']['buildSize']); + $this->assertEquals(0, $deployment['body']['totalSize']); + + $this->assertEventually(function () use ($siteId) { + $site = $this->getSite($siteId); + $this->assertNotEmpty($site['body']['deploymentId']); + }, 50000, 500); + + $domain = $this->setupSiteDomain($siteId); + $proxyClient = new Client(); + $proxyClient->setEndpoint('http://' . $domain); + + $response = $proxyClient->call(Client::METHOD_GET, '/'); + + $this->assertEquals(200, $response['headers']['status-code']); + $this->assertStringContainsString("Astro Blog", $response['body']); + $this->assertStringContainsString("Hello, Astronaut!", $response['body']); + + $response = $proxyClient->call(Client::METHOD_GET, '/about'); + + $this->assertEquals(200, $response['headers']['status-code']); + $this->assertStringContainsString("Astro Blog", $response['body']); + $this->assertStringContainsString("About Me", $response['body']); + + $deployment = $this->getDeployment($siteId, $deployment['body']['$id']); + $this->assertEquals(200, $deployment['headers']['status-code']); + $this->assertGreaterThan(0, $deployment['body']['sourceSize']); + $this->assertGreaterThan(0, $deployment['body']['buildSize']); + $totalSize = $deployment['body']['sourceSize'] + $deployment['body']['buildSize']; + $this->assertEquals($totalSize, $deployment['body']['totalSize']); + + $this->cleanupSite($siteId); + } + + public function testCreateSiteFromTemplateBranch() + { + $template = $this->getTemplate('playground-for-astro'); + $this->assertEquals(200, $template['headers']['status-code']); + + $template = $template['body']; + + $siteId = $this->setupSite([ + 'siteId' => ID::unique(), + 'name' => 'Astro Blog - Branch Test', + 'framework' => $template['frameworks'][0]['key'], + 'adapter' => $template['frameworks'][0]['adapter'], + 'buildRuntime' => $template['frameworks'][0]['buildRuntime'], + 'outputDirectory' => $template['frameworks'][0]['outputDirectory'], + 'buildCommand' => $template['frameworks'][0]['buildCommand'], + 'installCommand' => $template['frameworks'][0]['installCommand'], + 'fallbackFile' => $template['frameworks'][0]['fallbackFile'], + ]); + + $this->assertNotEmpty($siteId); + + // Deploy using branch + $deployment = $this->createTemplateDeployment($siteId, [ + 'repository' => $template['providerRepositoryId'], + 'owner' => $template['providerOwner'], + 'rootDirectory' => $template['frameworks'][0]['providerRootDirectory'], + 'type' => 'branch', + 'reference' => 'main', + 'activate' => true + ]); + + $this->assertEquals(202, $deployment['headers']['status-code']); + $this->assertNotEmpty($deployment['body']['$id']); + + $deployment = $this->getDeployment($siteId, $deployment['body']['$id']); + $this->assertEquals(200, $deployment['headers']['status-code']); + $this->assertEquals(0, $deployment['body']['sourceSize']); + $this->assertEquals(0, $deployment['body']['buildSize']); + $this->assertEquals(0, $deployment['body']['totalSize']); + + $this->assertEventually(function () use ($siteId) { + $site = $this->getSite($siteId); + $this->assertNotEmpty($site['body']['deploymentId']); + }, 50000, 500); + + $domain = $this->setupSiteDomain($siteId); + $proxyClient = new Client(); + $proxyClient->setEndpoint('http://' . $domain); + + $response = $proxyClient->call(Client::METHOD_GET, '/'); + + $this->assertEquals(200, $response['headers']['status-code']); + $this->assertStringContainsString("Astro Blog", $response['body']); + $this->assertStringContainsString("Hello, Astronaut!", $response['body']); + + $response = $proxyClient->call(Client::METHOD_GET, '/about'); + + $this->assertEquals(200, $response['headers']['status-code']); + $this->assertStringContainsString("Astro Blog", $response['body']); + $this->assertStringContainsString("About Me", $response['body']); + + $deployment = $this->getDeployment($siteId, $deployment['body']['$id']); + $this->assertEquals(200, $deployment['headers']['status-code']); + $this->assertGreaterThan(0, $deployment['body']['sourceSize']); + $this->assertGreaterThan(0, $deployment['body']['buildSize']); + $totalSize = $deployment['body']['sourceSize'] + $deployment['body']['buildSize']; + $this->assertEquals($totalSize, $deployment['body']['totalSize']); + + $this->cleanupSite($siteId); + } + + public function testCreateSiteFromTemplateCommit() + { + $template = $this->getTemplate('playground-for-astro'); + $this->assertEquals(200, $template['headers']['status-code']); + + // Ensure we have the latest commit + $this->assertArrayHasKey('latestCommit', $template['body']); + $latestCommit = $template['body']['latestCommit']; + + $template = $template['body']; + + $siteId = $this->setupSite([ + 'siteId' => ID::unique(), + 'name' => 'Astro Blog - Commit Test', + 'framework' => $template['frameworks'][0]['key'], + 'adapter' => $template['frameworks'][0]['adapter'], + 'buildRuntime' => $template['frameworks'][0]['buildRuntime'], + 'outputDirectory' => $template['frameworks'][0]['outputDirectory'], + 'buildCommand' => $template['frameworks'][0]['buildCommand'], + 'installCommand' => $template['frameworks'][0]['installCommand'], + 'fallbackFile' => $template['frameworks'][0]['fallbackFile'], + ]); + + $this->assertNotEmpty($siteId); + + // Deploy using commit + $deployment = $this->createTemplateDeployment($siteId, [ + 'repository' => $template['providerRepositoryId'], + 'owner' => $template['providerOwner'], + 'rootDirectory' => $template['frameworks'][0]['providerRootDirectory'], + 'type' => 'commit', + 'reference' => $latestCommit, 'activate' => true ]); From 2a145bc284d1edff27014187b316493af85448b6 Mon Sep 17 00:00:00 2001 From: Atharva Deosthale Date: Fri, 19 Sep 2025 18:18:44 +0530 Subject: [PATCH 09/24] address reviews regarding tests --- .../e2e/Services/Functions/FunctionsBase.php | 41 ++++----- .../Functions/FunctionsCustomServerTest.php | 87 ++++++++++++------- tests/e2e/Services/Sites/SitesBase.php | 41 ++++----- .../Services/Sites/SitesCustomServerTest.php | 9 +- 4 files changed, 97 insertions(+), 81 deletions(-) diff --git a/tests/e2e/Services/Functions/FunctionsBase.php b/tests/e2e/Services/Functions/FunctionsBase.php index 4eb31c08ac..7403b23a73 100644 --- a/tests/e2e/Services/Functions/FunctionsBase.php +++ b/tests/e2e/Services/Functions/FunctionsBase.php @@ -268,35 +268,30 @@ trait FunctionsBase 'x-appwrite-project' => $this->getProject()['$id'], ])); - // Fetch latest commit from GitHub API if template has provider info - if ( - isset($template['body']['providerOwner']) && - isset($template['body']['providerRepositoryId']) - ) { - $owner = $template['body']['providerOwner']; - $repo = $template['body']['providerRepositoryId']; + return $template; + } - // GitHub API to get latest commit from main branch - $ch = curl_init("https://api.github.com/repos/{$owner}/{$repo}/commits/main"); - curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); - curl_setopt($ch, CURLOPT_HTTPHEADER, [ - 'User-Agent: Appwrite', - 'Accept: application/vnd.github.v3+json' - ]); + protected function helperGetLatestCommit(string $owner, string $repository): ?string + { + $ch = curl_init("https://api.github.com/repos/{$owner}/{$repository}/commits/main"); + curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); + curl_setopt($ch, CURLOPT_HTTPHEADER, [ + 'User-Agent: Appwrite', + 'Accept: application/vnd.github.v3+json' + ]); - $response = curl_exec($ch); - $httpCode = curl_getinfo($ch, CURLINFO_HTTP_CODE); - curl_close($ch); + $response = curl_exec($ch); + $httpCode = curl_getinfo($ch, CURLINFO_HTTP_CODE); + curl_close($ch); - if ($httpCode === 200) { - $commitData = json_decode($response, true); - if (isset($commitData['sha'])) { - $template['body']['latestCommit'] = $commitData['sha']; - } + if ($httpCode === 200) { + $commitData = json_decode($response, true); + if (isset($commitData['sha'])) { + return $commitData['sha']; } } - return $template; + return null; } protected function createExecution(string $functionId, mixed $params = []): mixed diff --git a/tests/e2e/Services/Functions/FunctionsCustomServerTest.php b/tests/e2e/Services/Functions/FunctionsCustomServerTest.php index 8a774ed8bb..5672bd9817 100644 --- a/tests/e2e/Services/Functions/FunctionsCustomServerTest.php +++ b/tests/e2e/Services/Functions/FunctionsCustomServerTest.php @@ -361,7 +361,7 @@ class FunctionsCustomServerTest extends Scope $starterTemplate = $this->getTemplate('starter'); $this->assertEquals(200, $starterTemplate['headers']['status-code']); - $phpRuntime = array_values(array_filter($starterTemplate['body']['runtimes'], function ($runtime) { + $runtime = array_values(array_filter($starterTemplate['body']['runtimes'], function ($runtime) { return $runtime['name'] === 'node-22'; }))[0]; @@ -374,15 +374,15 @@ class FunctionsCustomServerTest extends Scope 'name' => $starterTemplate['body']['name'], 'runtime' => 'node-22', 'execute' => $starterTemplate['body']['permissions'], - 'entrypoint' => $phpRuntime['entrypoint'], + 'entrypoint' => $runtime['entrypoint'], 'events' => $starterTemplate['body']['events'], 'schedule' => $starterTemplate['body']['cron'], 'timeout' => $starterTemplate['body']['timeout'], - 'commands' => $phpRuntime['commands'], + 'commands' => $runtime['commands'], 'scopes' => $starterTemplate['body']['scopes'], 'templateRepository' => $starterTemplate['body']['providerRepositoryId'], 'templateOwner' => $starterTemplate['body']['providerOwner'], - 'templateRootDirectory' => $phpRuntime['providerRootDirectory'], + 'templateRootDirectory' => $runtime['providerRootDirectory'], 'templateVersion' => $starterTemplate['body']['providerVersion'], ] ); @@ -399,7 +399,7 @@ class FunctionsCustomServerTest extends Scope 'activate' => true, 'repository' => $starterTemplate['body']['providerRepositoryId'], 'owner' => $starterTemplate['body']['providerOwner'], - 'rootDirectory' => $phpRuntime['providerRootDirectory'], + 'rootDirectory' => $runtime['providerRootDirectory'], 'type' => 'tag', 'reference' => $starterTemplate['body']['providerVersion'], ] @@ -408,11 +408,20 @@ class FunctionsCustomServerTest extends Scope $this->assertEquals(202, $deployment['headers']['status-code']); $this->assertNotEmpty($deployment['body']['$id']); - $deployment = $this->getDeployment($functionId, $deployment['body']['$id']); + // Wait for deployment to be ready + $deploymentId = $deployment['body']['$id']; + $this->assertEventually(function () use ($functionId, $deploymentId) { + $deployment = $this->getDeployment($functionId, $deploymentId); + $this->assertEquals('ready', $deployment['body']['status']); + }, 50000, 500); + + // Verify deployment sizes + $deployment = $this->getDeployment($functionId, $deploymentId); $this->assertEquals(200, $deployment['headers']['status-code']); - $this->assertEquals(0, $deployment['body']['sourceSize']); - $this->assertEquals(0, $deployment['body']['buildSize']); - $this->assertEquals(0, $deployment['body']['totalSize']); + $this->assertGreaterThan(0, $deployment['body']['sourceSize']); + $this->assertGreaterThan(0, $deployment['body']['buildSize']); + $totalSize = $deployment['body']['sourceSize'] + $deployment['body']['buildSize']; + $this->assertEquals($totalSize, $deployment['body']['totalSize']); $deployments = $this->listDeployments($functionId); @@ -422,16 +431,7 @@ class FunctionsCustomServerTest extends Scope $lastDeployment = $deployments['body']['deployments'][0]; $this->assertNotEmpty($lastDeployment['$id']); - $this->assertEquals(0, $lastDeployment['sourceSize']); - - $deploymentId = $lastDeployment['$id']; - - $this->assertEventually(function () use ($functionId, $deploymentId) { - $deployment = $this->getDeployment($functionId, $deploymentId); - - $this->assertEquals(200, $deployment['headers']['status-code']); - $this->assertEquals('ready', $deployment['body']['status']); - }, 50000, 1000); + $this->assertGreaterThan(0, $lastDeployment['sourceSize']); $function = $this->getFunction($functionId); @@ -508,7 +508,7 @@ class FunctionsCustomServerTest extends Scope $starterTemplate = $this->getTemplate('starter'); $this->assertEquals(200, $starterTemplate['headers']['status-code']); - $phpRuntime = array_values(array_filter($starterTemplate['body']['runtimes'], function ($runtime) { + $runtime = array_values(array_filter($starterTemplate['body']['runtimes'], function ($runtime) { return $runtime['name'] === 'node-22'; }))[0]; @@ -521,11 +521,11 @@ class FunctionsCustomServerTest extends Scope 'name' => $starterTemplate['body']['name'] . ' - Branch Test', 'runtime' => 'node-22', 'execute' => $starterTemplate['body']['permissions'], - 'entrypoint' => $phpRuntime['entrypoint'], + 'entrypoint' => $runtime['entrypoint'], 'events' => $starterTemplate['body']['events'], 'schedule' => $starterTemplate['body']['cron'], 'timeout' => $starterTemplate['body']['timeout'], - 'commands' => $phpRuntime['commands'], + 'commands' => $runtime['commands'], 'scopes' => $starterTemplate['body']['scopes'], ] ); @@ -543,7 +543,7 @@ class FunctionsCustomServerTest extends Scope 'activate' => true, 'repository' => $starterTemplate['body']['providerRepositoryId'], 'owner' => $starterTemplate['body']['providerOwner'], - 'rootDirectory' => $phpRuntime['providerRootDirectory'], + 'rootDirectory' => $runtime['providerRootDirectory'], 'type' => 'branch', 'reference' => 'main', ] @@ -552,8 +552,18 @@ class FunctionsCustomServerTest extends Scope $this->assertEquals(202, $deployment['headers']['status-code']); $this->assertNotEmpty($deployment['body']['$id']); - $deployment = $this->getDeployment($functionId, $deployment['body']['$id']); + $deploymentId = $deployment['body']['$id']; + $this->assertEventually(function () use ($functionId, $deploymentId) { + $deployment = $this->getDeployment($functionId, $deploymentId); + $this->assertEquals('ready', $deployment['body']['status']); + }, 50000, 500); + + $deployment = $this->getDeployment($functionId, $deploymentId); $this->assertEquals(200, $deployment['headers']['status-code']); + $this->assertGreaterThan(0, $deployment['body']['sourceSize']); + $this->assertGreaterThan(0, $deployment['body']['buildSize']); + $totalSize = $deployment['body']['sourceSize'] + $deployment['body']['buildSize']; + $this->assertEquals($totalSize, $deployment['body']['totalSize']); $function = $this->cleanupFunction($functionId); } @@ -563,11 +573,14 @@ class FunctionsCustomServerTest extends Scope $starterTemplate = $this->getTemplate('starter'); $this->assertEquals(200, $starterTemplate['headers']['status-code']); - // Ensure we have the latest commit - $this->assertArrayHasKey('latestCommit', $starterTemplate['body']); - $latestCommit = $starterTemplate['body']['latestCommit']; + // Get latest commit using helper function + $latestCommit = $this->helperGetLatestCommit( + $starterTemplate['body']['providerOwner'], + $starterTemplate['body']['providerRepositoryId'] + ); + $this->assertNotNull($latestCommit); - $phpRuntime = array_values(array_filter($starterTemplate['body']['runtimes'], function ($runtime) { + $runtime = array_values(array_filter($starterTemplate['body']['runtimes'], function ($runtime) { return $runtime['name'] === 'node-22'; }))[0]; @@ -580,11 +593,11 @@ class FunctionsCustomServerTest extends Scope 'name' => $starterTemplate['body']['name'] . ' - Commit Test', 'runtime' => 'node-22', 'execute' => $starterTemplate['body']['permissions'], - 'entrypoint' => $phpRuntime['entrypoint'], + 'entrypoint' => $runtime['entrypoint'], 'events' => $starterTemplate['body']['events'], 'schedule' => $starterTemplate['body']['cron'], 'timeout' => $starterTemplate['body']['timeout'], - 'commands' => $phpRuntime['commands'], + 'commands' => $runtime['commands'], 'scopes' => $starterTemplate['body']['scopes'], ] ); @@ -602,7 +615,7 @@ class FunctionsCustomServerTest extends Scope 'activate' => true, 'repository' => $starterTemplate['body']['providerRepositoryId'], 'owner' => $starterTemplate['body']['providerOwner'], - 'rootDirectory' => $phpRuntime['providerRootDirectory'], + 'rootDirectory' => $runtime['providerRootDirectory'], 'type' => 'commit', 'reference' => $latestCommit, ] @@ -611,8 +624,18 @@ class FunctionsCustomServerTest extends Scope $this->assertEquals(202, $deployment['headers']['status-code']); $this->assertNotEmpty($deployment['body']['$id']); - $deployment = $this->getDeployment($functionId, $deployment['body']['$id']); + $deploymentId = $deployment['body']['$id']; + $this->assertEventually(function () use ($functionId, $deploymentId) { + $deployment = $this->getDeployment($functionId, $deploymentId); + $this->assertEquals('ready', $deployment['body']['status']); + }, 50000, 500); + + $deployment = $this->getDeployment($functionId, $deploymentId); $this->assertEquals(200, $deployment['headers']['status-code']); + $this->assertGreaterThan(0, $deployment['body']['sourceSize']); + $this->assertGreaterThan(0, $deployment['body']['buildSize']); + $totalSize = $deployment['body']['sourceSize'] + $deployment['body']['buildSize']; + $this->assertEquals($totalSize, $deployment['body']['totalSize']); $function = $this->cleanupFunction($functionId); } diff --git a/tests/e2e/Services/Sites/SitesBase.php b/tests/e2e/Services/Sites/SitesBase.php index 004032452b..7eb5d9699c 100644 --- a/tests/e2e/Services/Sites/SitesBase.php +++ b/tests/e2e/Services/Sites/SitesBase.php @@ -330,35 +330,30 @@ trait SitesBase 'x-appwrite-project' => $this->getProject()['$id'], ]); - // Fetch latest commit from GitHub API if template has provider info - if ( - isset($template['body']['providerOwner']) && - isset($template['body']['providerRepositoryId']) - ) { - $owner = $template['body']['providerOwner']; - $repo = $template['body']['providerRepositoryId']; + return $template; + } - // GitHub API to get latest commit from main branch - $ch = curl_init("https://api.github.com/repos/{$owner}/{$repo}/commits/main"); - curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); - curl_setopt($ch, CURLOPT_HTTPHEADER, [ - 'User-Agent: Appwrite', - 'Accept: application/vnd.github.v3+json' - ]); + protected function helperGetLatestCommit(string $owner, string $repository): ?string + { + $ch = curl_init("https://api.github.com/repos/{$owner}/{$repository}/commits/main"); + curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); + curl_setopt($ch, CURLOPT_HTTPHEADER, [ + 'User-Agent: Appwrite', + 'Accept: application/vnd.github.v3+json' + ]); - $response = curl_exec($ch); - $httpCode = curl_getinfo($ch, CURLINFO_HTTP_CODE); - curl_close($ch); + $response = curl_exec($ch); + $httpCode = curl_getinfo($ch, CURLINFO_HTTP_CODE); + curl_close($ch); - if ($httpCode === 200) { - $commitData = json_decode($response, true); - if (isset($commitData['sha'])) { - $template['body']['latestCommit'] = $commitData['sha']; - } + if ($httpCode === 200) { + $commitData = json_decode($response, true); + if (isset($commitData['sha'])) { + return $commitData['sha']; } } - return $template; + return null; } protected function deleteSite(string $siteId): mixed diff --git a/tests/e2e/Services/Sites/SitesCustomServerTest.php b/tests/e2e/Services/Sites/SitesCustomServerTest.php index 524e8a09f3..f7015ccb48 100644 --- a/tests/e2e/Services/Sites/SitesCustomServerTest.php +++ b/tests/e2e/Services/Sites/SitesCustomServerTest.php @@ -1684,9 +1684,12 @@ class SitesCustomServerTest extends Scope $template = $this->getTemplate('playground-for-astro'); $this->assertEquals(200, $template['headers']['status-code']); - // Ensure we have the latest commit - $this->assertArrayHasKey('latestCommit', $template['body']); - $latestCommit = $template['body']['latestCommit']; + // Get latest commit using helper function + $latestCommit = $this->helperGetLatestCommit( + $template['body']['providerOwner'], + $template['body']['providerRepositoryId'] + ); + $this->assertNotNull($latestCommit); $template = $template['body']; From 1a19e01d69d563aff5942ea836cfdb8b484875ee Mon Sep 17 00:00:00 2001 From: Atharva Deosthale Date: Fri, 19 Sep 2025 18:30:42 +0530 Subject: [PATCH 10/24] attempt to fix tests --- tests/e2e/General/UsageTest.php | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/e2e/General/UsageTest.php b/tests/e2e/General/UsageTest.php index 8f5477331a..dc49d27aea 100644 --- a/tests/e2e/General/UsageTest.php +++ b/tests/e2e/General/UsageTest.php @@ -28,6 +28,7 @@ class UsageTest extends Scope FunctionsBase::createVariable insteadof SitesBase; FunctionsBase::getVariable insteadof SitesBase; FunctionsBase::listVariables insteadof SitesBase; + FunctionsBase::helperGetLatestCommit insteadof SitesBase; FunctionsBase::updateVariable insteadof SitesBase; FunctionsBase::deleteVariable insteadof SitesBase; FunctionsBase::getDeployment insteadof SitesBase; From 7d4486b9e691789bed9a68e62df2f455e18d57ce Mon Sep 17 00:00:00 2001 From: Atharva Deosthale Date: Fri, 19 Sep 2025 18:42:25 +0530 Subject: [PATCH 11/24] more fixes to tests --- tests/e2e/Services/Functions/FunctionsCustomServerTest.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/e2e/Services/Functions/FunctionsCustomServerTest.php b/tests/e2e/Services/Functions/FunctionsCustomServerTest.php index 5672bd9817..a3f8768676 100644 --- a/tests/e2e/Services/Functions/FunctionsCustomServerTest.php +++ b/tests/e2e/Services/Functions/FunctionsCustomServerTest.php @@ -500,7 +500,7 @@ class FunctionsCustomServerTest extends Scope $this->assertEquals($deployment['body']['$id'], $function['body']['deploymentId']); $this->assertEquals($deployment['body']['$createdAt'], $function['body']['deploymentCreatedAt']); - $function = $this->cleanupFunction($functionId); + $this->cleanupFunction($functionId); } public function testCreateFunctionAndDeploymentFromTemplateBranch() @@ -565,7 +565,7 @@ class FunctionsCustomServerTest extends Scope $totalSize = $deployment['body']['sourceSize'] + $deployment['body']['buildSize']; $this->assertEquals($totalSize, $deployment['body']['totalSize']); - $function = $this->cleanupFunction($functionId); + $this->cleanupFunction($functionId); } public function testCreateFunctionAndDeploymentFromTemplateCommit() @@ -637,7 +637,7 @@ class FunctionsCustomServerTest extends Scope $totalSize = $deployment['body']['sourceSize'] + $deployment['body']['buildSize']; $this->assertEquals($totalSize, $deployment['body']['totalSize']); - $function = $this->cleanupFunction($functionId); + $this->cleanupFunction($functionId); } /** From 5963b2baf799d99c5bcb7610595b5ed70fc4ef48 Mon Sep 17 00:00:00 2001 From: Atharva Deosthale Date: Tue, 23 Sep 2025 18:00:14 +0530 Subject: [PATCH 12/24] change request filter to versions below 1.9.0 --- app/controllers/general.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/general.php b/app/controllers/general.php index c663091677..f0294e9274 100644 --- a/app/controllers/general.php +++ b/app/controllers/general.php @@ -907,7 +907,7 @@ App::init() $dbForProject = $getProjectDB($project); $request->addFilter(new RequestV20($dbForProject, $route->getPathValues($request))); } - if (version_compare($requestFormat, '1.8.1', '<')) { + if (version_compare($requestFormat, '1.9.0', '<')) { $request->addFilter(new RequestV21()); } } From 458100cd69f426ba0ae43c31efb050535a14e559 Mon Sep 17 00:00:00 2001 From: Steven Nguyen <1477010+stnguyen90@users.noreply.github.com> Date: Thu, 30 Oct 2025 14:42:18 -0700 Subject: [PATCH 13/24] Upgrade base image to version 0.10.5 Ensure libwebp is installed in the base image when imagemagick is installed so that imagemagick works with webp. --- Dockerfile | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index 2a3e176838..1f5df230d9 100755 --- a/Dockerfile +++ b/Dockerfile @@ -12,7 +12,7 @@ RUN composer install --ignore-platform-reqs --optimize-autoloader \ --no-plugins --no-scripts --prefer-dist \ `if [ "$TESTING" != "true" ]; then echo "--no-dev"; fi` -FROM appwrite/base:0.10.4 AS final +FROM appwrite/base:0.10.5 AS final LABEL maintainer="team@appwrite.io" @@ -28,8 +28,6 @@ RUN \ apk add boost boost-dev; \ fi -RUN apk add libwebp - WORKDIR /usr/src/code COPY --from=composer /usr/local/src/vendor /usr/src/code/vendor From ce539972a54053ed14993c0586d393363219bfbb Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 30 Oct 2025 21:51:50 +0000 Subject: [PATCH 14/24] Initial plan From de4f473da192ed954ee734bb456a7d545c8aa974 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 30 Oct 2025 21:56:12 +0000 Subject: [PATCH 15/24] Initial plan for adding webp test cases Co-authored-by: stnguyen90 <1477010+stnguyen90@users.noreply.github.com> --- tests/resources/logo.webp | Bin 0 -> 17200 bytes 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 tests/resources/logo.webp diff --git a/tests/resources/logo.webp b/tests/resources/logo.webp new file mode 100644 index 0000000000000000000000000000000000000000..f9bde111dbbd3ff06345f7fa53a29c2013d42f9f GIT binary patch literal 17200 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 literal 0 HcmV?d00001 From 4a8651ab39bbe45293e4830da0a457f0fd4b7e73 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 30 Oct 2025 21:58:02 +0000 Subject: [PATCH 16/24] Add webp test cases for upload/view and preview Co-authored-by: stnguyen90 <1477010+stnguyen90@users.noreply.github.com> --- tests/e2e/Services/Storage/StorageBase.php | 105 +++++++++++++++++++++ 1 file changed, 105 insertions(+) diff --git a/tests/e2e/Services/Storage/StorageBase.php b/tests/e2e/Services/Storage/StorageBase.php index 6879645a22..8b7ceef45f 100644 --- a/tests/e2e/Services/Storage/StorageBase.php +++ b/tests/e2e/Services/Storage/StorageBase.php @@ -869,6 +869,111 @@ trait StorageBase return $data; } + /** + * @depends testCreateBucketFile + */ + public function testUploadWebpImage(): array + { + /** + * Test for SUCCESS - Upload and view webp image + */ + $bucket = $this->client->call(Client::METHOD_POST, '/storage/buckets', [ + 'content-type' => 'application/json', + 'x-appwrite-project' => $this->getProject()['$id'], + 'x-appwrite-key' => $this->getProject()['apiKey'], + ], [ + 'bucketId' => ID::unique(), + 'name' => 'Test Bucket Webp', + 'fileSecurity' => true, + 'maximumFileSize' => 2000000, //2MB + 'allowedFileExtensions' => ['webp'], + 'permissions' => [ + Permission::read(Role::any()), + Permission::create(Role::any()), + Permission::update(Role::any()), + Permission::delete(Role::any()), + ], + ]); + $this->assertEquals(201, $bucket['headers']['status-code']); + $this->assertNotEmpty($bucket['body']['$id']); + + $bucketId = $bucket['body']['$id']; + + // Upload webp file + $file = $this->client->call(Client::METHOD_POST, '/storage/buckets/' . $bucketId . '/files', array_merge([ + 'content-type' => 'multipart/form-data', + 'x-appwrite-project' => $this->getProject()['$id'], + ], $this->getHeaders()), [ + 'fileId' => ID::unique(), + 'file' => new CURLFile(realpath(__DIR__ . '/../../../resources/logo.webp'), 'image/webp', 'logo.webp'), + 'permissions' => [ + Permission::read(Role::any()), + Permission::update(Role::any()), + Permission::delete(Role::any()), + ], + ]); + $this->assertEquals(201, $file['headers']['status-code']); + $this->assertNotEmpty($file['body']['$id']); + $this->assertEquals('logo.webp', $file['body']['name']); + $this->assertEquals('image/webp', $file['body']['mimeType']); + + $fileId = $file['body']['$id']; + + // View webp file + $view = $this->client->call(Client::METHOD_GET, '/storage/buckets/' . $bucketId . '/files/' . $fileId . '/view', array_merge([ + 'content-type' => 'application/json', + 'x-appwrite-project' => $this->getProject()['$id'], + ], $this->getHeaders())); + + $this->assertEquals(200, $view['headers']['status-code']); + $this->assertEquals('image/webp', $view['headers']['content-type']); + $this->assertNotEmpty($view['body']); + + return ['bucketId' => $bucketId, 'fileId' => $fileId]; + } + + /** + * @depends testCreateBucketFile + */ + public function testPreviewNonWebpAsWebp(array $data): array + { + $bucketId = $data['bucketId']; + + // Upload a PNG image + $file = $this->client->call(Client::METHOD_POST, '/storage/buckets/' . $bucketId . '/files', array_merge([ + 'content-type' => 'multipart/form-data', + 'x-appwrite-project' => $this->getProject()['$id'], + ], $this->getHeaders()), [ + 'fileId' => ID::unique(), + 'file' => new CURLFile(realpath(__DIR__ . '/../../../resources/logo.png'), 'image/png', 'logo.png'), + 'permissions' => [ + Permission::read(Role::any()), + Permission::update(Role::any()), + Permission::delete(Role::any()), + ], + ]); + $this->assertEquals(201, $file['headers']['status-code']); + $this->assertNotEmpty($file['body']['$id']); + + $fileId = $file['body']['$id']; + + // Preview PNG as webp + $preview = $this->client->call(Client::METHOD_GET, '/storage/buckets/' . $bucketId . '/files/' . $fileId . '/preview', array_merge([ + 'content-type' => 'application/json', + 'x-appwrite-project' => $this->getProject()['$id'], + ], $this->getHeaders()), [ + 'width' => 300, + 'height' => 300, + 'output' => 'webp', + ]); + + $this->assertEquals(200, $preview['headers']['status-code']); + $this->assertEquals('image/webp', $preview['headers']['content-type']); + $this->assertNotEmpty($preview['body']); + + return $data; + } + /** * @depends testUpdateBucketFile */ From d1511d5ba1734a0839100c6edfd17107e49095cf Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 30 Oct 2025 22:26:30 +0000 Subject: [PATCH 17/24] Refactor webp tests per review feedback Co-authored-by: stnguyen90 <1477010+stnguyen90@users.noreply.github.com> --- tests/e2e/Services/Storage/StorageBase.php | 120 +++++++-------------- tests/resources/logo-after.webp | Bin 0 -> 6236 bytes tests/resources/logo.webp | Bin 17200 -> 0 bytes 3 files changed, 36 insertions(+), 84 deletions(-) create mode 100644 tests/resources/logo-after.webp delete mode 100644 tests/resources/logo.webp diff --git a/tests/e2e/Services/Storage/StorageBase.php b/tests/e2e/Services/Storage/StorageBase.php index 8b7ceef45f..2012be7375 100644 --- a/tests/e2e/Services/Storage/StorageBase.php +++ b/tests/e2e/Services/Storage/StorageBase.php @@ -30,7 +30,7 @@ trait StorageBase 'name' => 'Test Bucket', 'fileSecurity' => true, 'maximumFileSize' => 2000000, //2MB - 'allowedFileExtensions' => ['jpg', 'png', 'jfif'], + 'allowedFileExtensions' => ['jpg', 'png', 'jfif', 'webp'], 'permissions' => [ Permission::read(Role::any()), Permission::create(Role::any()), @@ -263,7 +263,39 @@ trait StorageBase $this->assertEquals(400, $res['headers']['status-code']); $this->assertEquals(Exception::STORAGE_INVALID_APPWRITE_ID, $res['body']['type']); - return ['bucketId' => $bucketId, 'fileId' => $file['body']['$id'], 'largeFileId' => $largeFile['body']['$id'], 'largeBucketId' => $bucket2['body']['$id']]; + /** + * Test for SUCCESS - Upload and view webp image + */ + $webpFile = $this->client->call(Client::METHOD_POST, '/storage/buckets/' . $bucketId . '/files', array_merge([ + 'content-type' => 'multipart/form-data', + 'x-appwrite-project' => $this->getProject()['$id'], + ], $this->getHeaders()), [ + 'fileId' => ID::unique(), + 'file' => new CURLFile(realpath(__DIR__ . '/../../../resources/logo-after.webp'), 'image/webp', 'logo-after.webp'), + 'permissions' => [ + Permission::read(Role::any()), + Permission::update(Role::any()), + Permission::delete(Role::any()), + ], + ]); + $this->assertEquals(201, $webpFile['headers']['status-code']); + $this->assertNotEmpty($webpFile['body']['$id']); + $this->assertEquals('logo-after.webp', $webpFile['body']['name']); + $this->assertEquals('image/webp', $webpFile['body']['mimeType']); + + $webpFileId = $webpFile['body']['$id']; + + // View webp file + $webpView = $this->client->call(Client::METHOD_GET, '/storage/buckets/' . $bucketId . '/files/' . $webpFileId . '/view', array_merge([ + 'content-type' => 'application/json', + 'x-appwrite-project' => $this->getProject()['$id'], + ], $this->getHeaders())); + + $this->assertEquals(200, $webpView['headers']['status-code']); + $this->assertEquals('image/webp', $webpView['headers']['content-type']); + $this->assertNotEmpty($webpView['body']); + + return ['bucketId' => $bucketId, 'fileId' => $file['body']['$id'], 'largeFileId' => $largeFile['body']['$id'], 'largeBucketId' => $bucket2['body']['$id'], 'webpFileId' => $webpFileId]; } public function testCreateBucketFileZstdCompression(): array @@ -872,90 +904,10 @@ trait StorageBase /** * @depends testCreateBucketFile */ - public function testUploadWebpImage(): array - { - /** - * Test for SUCCESS - Upload and view webp image - */ - $bucket = $this->client->call(Client::METHOD_POST, '/storage/buckets', [ - 'content-type' => 'application/json', - 'x-appwrite-project' => $this->getProject()['$id'], - 'x-appwrite-key' => $this->getProject()['apiKey'], - ], [ - 'bucketId' => ID::unique(), - 'name' => 'Test Bucket Webp', - 'fileSecurity' => true, - 'maximumFileSize' => 2000000, //2MB - 'allowedFileExtensions' => ['webp'], - 'permissions' => [ - Permission::read(Role::any()), - Permission::create(Role::any()), - Permission::update(Role::any()), - Permission::delete(Role::any()), - ], - ]); - $this->assertEquals(201, $bucket['headers']['status-code']); - $this->assertNotEmpty($bucket['body']['$id']); - - $bucketId = $bucket['body']['$id']; - - // Upload webp file - $file = $this->client->call(Client::METHOD_POST, '/storage/buckets/' . $bucketId . '/files', array_merge([ - 'content-type' => 'multipart/form-data', - 'x-appwrite-project' => $this->getProject()['$id'], - ], $this->getHeaders()), [ - 'fileId' => ID::unique(), - 'file' => new CURLFile(realpath(__DIR__ . '/../../../resources/logo.webp'), 'image/webp', 'logo.webp'), - 'permissions' => [ - Permission::read(Role::any()), - Permission::update(Role::any()), - Permission::delete(Role::any()), - ], - ]); - $this->assertEquals(201, $file['headers']['status-code']); - $this->assertNotEmpty($file['body']['$id']); - $this->assertEquals('logo.webp', $file['body']['name']); - $this->assertEquals('image/webp', $file['body']['mimeType']); - - $fileId = $file['body']['$id']; - - // View webp file - $view = $this->client->call(Client::METHOD_GET, '/storage/buckets/' . $bucketId . '/files/' . $fileId . '/view', array_merge([ - 'content-type' => 'application/json', - 'x-appwrite-project' => $this->getProject()['$id'], - ], $this->getHeaders())); - - $this->assertEquals(200, $view['headers']['status-code']); - $this->assertEquals('image/webp', $view['headers']['content-type']); - $this->assertNotEmpty($view['body']); - - return ['bucketId' => $bucketId, 'fileId' => $fileId]; - } - - /** - * @depends testCreateBucketFile - */ - public function testPreviewNonWebpAsWebp(array $data): array + public function testFilePreview(array $data): array { $bucketId = $data['bucketId']; - - // Upload a PNG image - $file = $this->client->call(Client::METHOD_POST, '/storage/buckets/' . $bucketId . '/files', array_merge([ - 'content-type' => 'multipart/form-data', - 'x-appwrite-project' => $this->getProject()['$id'], - ], $this->getHeaders()), [ - 'fileId' => ID::unique(), - 'file' => new CURLFile(realpath(__DIR__ . '/../../../resources/logo.png'), 'image/png', 'logo.png'), - 'permissions' => [ - Permission::read(Role::any()), - Permission::update(Role::any()), - Permission::delete(Role::any()), - ], - ]); - $this->assertEquals(201, $file['headers']['status-code']); - $this->assertNotEmpty($file['body']['$id']); - - $fileId = $file['body']['$id']; + $fileId = $data['fileId']; // Preview PNG as webp $preview = $this->client->call(Client::METHOD_GET, '/storage/buckets/' . $bucketId . '/files/' . $fileId . '/preview', array_merge([ diff --git a/tests/resources/logo-after.webp b/tests/resources/logo-after.webp new file mode 100644 index 0000000000000000000000000000000000000000..b91c5dc1fa912333d58fba3f42bbce0f8559ae73 GIT binary patch literal 6236 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 G0000WrY4pE literal 0 HcmV?d00001 diff --git a/tests/resources/logo.webp b/tests/resources/logo.webp deleted file mode 100644 index f9bde111dbbd3ff06345f7fa53a29c2013d42f9f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 17200 zcmeHtQ*bU^vu14Dwr$(Vj&1GOwr$(CZSQ!;wr#!1eCJHnslR5X=IY$c)ZbTK>!Pc> z*IM0ALs?ovf=Uz!NJCsiNnMGH2=5>M?gKa%n5F@&0ZiZ*RkB2JQDGqoDix9g477#a zmjm~~oPe?QvApKb%kH7SEg#Y04}~A-SN>J~>)f_t9<1U^{jEWPKc#@VJNlZzqrizD zeoyw(?tTB3;JE+w_urp?Xlw2{|Kx|gzZ^jMUH*OgCD>tquK50QXK>0y6a!F04Sz zTzM-ipi`Iref)2q{QE)tfBPHqzatrB7U9f=G(j_IM;KD~V3G7B#p;o|+*KrqU}8Bg z@y_>2S9r@fEMPA(8Lp2>xXNYK=I^D%B=Yo$UH&CF5E6mygd6c?%_GWx_~sE0`Ajmsfvw)!**n8I>){kE7XWQrX%O(s+B zHLoo2PUpQnZFsl?KOhlt5@aTjy8_uyRNI8oPxb~QjSV8cCyRfX8HUXOc2zs6N=O1C zKb6}eeM*UA99gqVs>rIQ&G=%JWf&TRL}s+3+rL+dzwPWe6lyzOs0SUq^!F!bQa(75 zfF!8?G?VyXSX-HEgbZIMdaOtlH@c8p=7FM~Ag`X5?0I;H7-tx6WR8Wmb=@|kyYrwN z!+xk?tj`=B{0G)EI~I3EKJkDw*^a6599>x4|69l?kfy+X-~pVKd(A7E`6}9zE+aMB_@m}VyUV-{-kBq`Np-=F>0=D`F2@xt zpJp{Tg1{P?UNdOg<1KGH94rz~_(W+4b88!I(y&`izKS9}E5xCxtU5o+9(sn&4;5uJ zGA3xm`YsF}K8!(V%oW7)3zSI+zF>RD0_cZ`tU3II#RG}3|TC&WC97_h#Kw)(~E@QNxixO&Hw~`>(vw&xF@R}?p3}fjpgmy(=n&OnX zu~uAdO^KLUY!r2+yPuHpa-kcSi?IU;S+mRt$mf7>cbTgR(yn`YOMQYiQzvY-;gq2K zFlU`Z1}ePOj+wQaq7@M;&{0o3b9eX-!$nMmXl}SR;X=#6@1mM6lYo+dDINKyESTnf zy|tB@mh6qO;*3$OFX$%Me05>h7EUWE;DNM+)HDc(=dq}>k^|mCT6CM)(pi{vhC0sT zVfxbm=7BjGrvwq0;M;=zrA&H}QNUoj`MfF794~VyL!(gapS;^s=N%k~VyBJ-NlU~# zt7_5Vp~}FjE`ypHU7A*p5@s8a^?}6PE48Avm4<3`bm>NKAco^CF}<0gQ{>ZhrMY>8?TKNOXL|xlL^?6f2 zab0R<25HOH6>CJw;mD)0l-?JiF454vZac!Q_q97|wXPRY*sHnJS*!c3_sS+@&S3sS9@%B~;qVEp4>y_&zIBFNGBrZ?s13JMsSu92)lsJ^qgn`mX~1 zce%>@BFgL;s!AtE5ny7Y>NSLx$rwmwe;`H)W?kG=>ptCNrE-7jJOy4)s~(ajeO;3#tK%L>F=|!^SY;BZ~Iq;jv#Vz{5lWVJ_9OK zm3g{QoixW)3^?(DwOte-;`OSqN?B0l+2 zGK8db#HD=84^V3ay zlJI){JvHYP8gkI`8j=^kaO^d8*t4^7A?cuy(Kb^vB{i|-vycv|&mjAXLQL%a!< z^sTIztFRZG9J1nSxX>HhuEyYS!gBSf$b66;<1><59>jm9lmB@^|Ki^vB) z#v{;|^T&(uV13l`p=Z|&Q}!1VL`W$M zW-vH^GU6XiZECE2RTx=Cw5y4?;0!|6xS*@m!hP&Sq9t9MLoQAq)1imAhD~IW02epR zKk8JjSM4hMWqSbN;q{Asck5iMY;QV*un5Jkb)wX{)F_peTbALDkB12yDTir!@}u8bHsRZ|kU zD;8OZo?S~Y8=P>}c{GuMjA%@Wg32nTaz4l7%IK8CZ?%L*^Xj+8uh)S`{7~N-T{Sf=X z?WZa1Lbs7=cMH*PyiabCPbyH~2|m}$fE9<`D)7k9IHxcXv|aH3Ca+sds- z__cY8LLIp`k{yW>iYY`qj{bSvl~!lR3M-wSQVYhv5P?(-rTGjnmu6-+gj!OK9LL~ur`+r_oInA z6^|^$0%{06new1yDN97!EJ0RQ!{W7*#>AkaA$IxCar9T z2UJd@S|`h4JDD2kPg*B9J^}j0&7*>Yl}TOX5O0S?rUo|bs750h9adW!@fmE|DGm$W zYa2%1T!wtQ+>|LcvS%=2-Cg|+@KM>B`nU8u@9`DAhTeqKn{N6jCF957^1q}iV~WH4 zAMBj`R!R5b#jcZ4*e~oR&J(q$892;;%lJ>{h3`@~`_}DYKzW)uoiUz;yK3AFsly3$ z;Lx|%y_+6ihK*kwBm!cr(*t##QrPm%K7R$uefLqoPG)?R5)<*ejz9zx*_YTPV;7)CR*pjB=TH*yUqA)5D- zqpXYvne1RdDs1#HcTLQ-1c{G3d%02v*(H^s&|d=yD4MN}4v(2;=%;4669eUk=V!6M zt^u8tFkqn0zUCKNvQz9%Ol> z=o5fS5fx_;!`(L0bGYbB3$<sj)1L6;jw1MZ``=C)lO7c4CnAQZr-+}`4Yw4y~n z)PTDwG|(6By-3EdY0}%;li!sye{}8wp_HlMkOjzUlYmRfE_N0{GuQiSqjUy{%NS5d&u5!`G(hk-oLPG(!N*D%$KL(JqlxsJzeU z{ABAg7&~{!8nF=r^;61l znNP%2<0E1&Lc@EL*6a`1O}vk#g7#FJpmt?fARk;d?$yyU0zzT0a* zJIY>DT!v%^{hgx(0Uj$+LXdwHH~b5V;S8N*AczcS=f|pneOdICMMFJnG;Q&{Bm{YV zfm3%+T<2)A4)XCwS^66&S5XByBCwtghZ zbbu2)t`#W_Ph476P<`FblM85Fx5wkfhc%%m^pDl#X#_FnZ=zB5f~ou1UgcIXK!nLnYy>iMK7rcoVJ!_q#N?eBQV0px z7(ChzoRws&xpxCc$B!>ba4Oo+wa+lftOD`i{*;ligVitNu|y4uh5bHrEqP|<$07eT zw$l=wK|Bs#FlXJ`mEz<%f8~VqObPOhU>~&yay!jquYF2GP!oQ}Vp#V_MQ#ZwwoG~N zW(!UVkA~r_Ha;QCGUtx;xs@zYMg&O~z01IV0cH&%P}L^PW~x!~tGO!d%XQ9iAEeF( zcAVe;Zqpx>4w_=iilhlV=VmO|0E z3GC>9=`s~KnYZ*+`WYW0R60S4z8eOs7#|U3Dkf@5qjOPk-@~OES}Toeg9~2Fr%|ca z!M*Bfgs+IR#sNEC4QAH?2L3ZP|e?ZRee9myb` zzP%8&3mQ9;n6!X(JI_ORKP#18r{~bXwMKbJ&K|YoDTyH$dzLU+HZ%?8Q3GeWz<;1w zv@LPNgRexYBrH>8ebSv6ITjH$ePPf5k@rZr$%kCB=%Yus_ZhAb{MA3~A%m6th$dj; zHa9XxEiw-fdm#erVC-F^Y8fRiRcK-tx|xnv=1*jdv-Bx@gf?HiSf5?2`J7$a`z$C( z0QxQa%R-EfTt6XZ5WRMav}DR#hH)QXq|lKkPCMCyB{;xas5rI${=%Z;m9|>pTT56* zn93)V_Kh&C5QF`jazi!;hRgeyLL}Fre#yE5B(YC$rHCrOSK7j&QA`Y%QfQ}AAQ)nM zQF^fEmasy>F}SB}Y@r3AU1s~Kue>0#gu=l|q3v3-c&`K^9^yuhJH(!!mkZ{~v6F^o z+V>1F@V*-JjlcM~7!OR*!TvZ%B#}2|IMA4!1oyrga?F3?r58r|b!E`NZkhliU*_l< za5Iz`3ufLdjWh-%KK7KXU8%Y6{S`~Pgd}JWbCw6Dk)0Q0+Rs^0R`B&WvBwZS^p5E` zD}r?_6{{$6t;H*-*&WMg{o!@9c!6o5nDk8G-7v0}GP80-uo31Gjk@|`tuj*vU1RMw z4X)7UqxcCv)8xX&H`33)ve@UQ7*j|=wo8HrN5R|ZBTaJ|0%QBz@$P6NnYApqMB%2x zyYd3&A$+bqRGjxiHxCS0;8ySCQDBppFDmUO#^B0fFj(2je`q)q$6Z`q?sP_M10^VC zKGh9|I<`3Kr6nJiMO`r%@9+LbQA_O0`P5Uk`!L5`^?pWD9k2NKcDN}T!%?Y2V{xDt zuW=*piGWBUrK(!c%huGYnY9&scS_Q0*RPmIitV0PwTevnoZJX9Y>~m>zpt$yhZr}9 z8Zv*h&rmM)dpd}rX9$i50x@-?a+v`Eh2iXGz46`kKgY)Y#O`c=ZsJ{@ zgaU0buDQAxXn?KkmeDnkqEbFW7q?avGsE9(3A{_H&}HG49locvwnOvA%`O$mc59QF zop{L2?ydnT<~CY|N2ny8`eB?4zEu=1Lf>6xn4ougHCK=k8h*cctxhfw+>8=hK@GM8 zULgo9^sivg^x_rt_Q@F{Te++A}CtA?1Yi13x7oKOD!Z z6wAKtQp))SX4jePOV-ra?VXV(f~st>3!m%WEEy<9a{dxiRg%eFzF{Z6{%}o`Pf5U= z3_aech5vm}Nyc;(``I-o$RbOi`ul4<^Z`nq4o0T*w!p=Ll!r>_otG6UiI}pB8x(wS z?=Qr`(yU2Lagn9t>UO1y2p`I6F4Gnhut%!bj*%o5CLT6r0_c6_|*cmOf?JGrtK zmP9_n%0@4iE?(E${a)aR$GXE7#w_^;i0NE_9u09%?`iHTms z!-Ch+!I{+3*$ai9U#KKL%K-g>`jERr)Pt(#Ke}F5^Te6iF@{wrU|?UzK_yeepN(!1vqdDL;n2iDS>`jbV_6x zh`b=goP&5!N3Z^z>NP0|EFyH=%^3-kTD<}OC00E^xp|BJ-x<$8A&_h%+Vh7NIRA_| zC5K&1vH@#s`tFpJ*I7T+nUY+02km6vZWEpF8Cl8t+faPdo_cc^FwfYatt(BM#y3RK zB|T@qX+~BAyr^cUYmG%7eKYXfpE-5r_6tk|M2V1sOPW*?AjW^)dx-E%%u*uTK3*tU zw24*-$H}pGo*Et%rhXnu>L^N*1$bd-!r%s^5+=;dJ&;Vg|9g zvw!MG*G(&ZVTo2@81=@2PyrdNfryS`9%Mbe~gFnq)i*L=@gTEMnAg z<}TkM<K!+KcRn3$~ZyDKWGHJWvtpMK*mXQ`9fL0Qegiz zohJ9odSxA!jSO(AmD&_}4MsP%W&2I^C7>xmnPGx@Q?|XhcF4M^UYl#6opR@PK?tZ) znd9y+a>u_|NWJy&*b9ot+#GYxr%@mm&!O$MyIq~JuH1-s?A1P;gSrC2gtc8^kUq#0 zY-fSTBOEXvg*~3)>fRTQmwXQt{_w(DoTLdLlVi3gFpG>U=EYGo~R2aE*N;&MBeyQq5u%>Y+PK7Vlc z_%jOC6$42sWF9cH0;OE9_n>T1nRrhgWf1+Tpw$r~CCgw3wtR$gxo|&uSxFG|y9gc` z4?ljnMfQM2Ek!F9frZ;DTqqow^7*nA;^esblSD`ShLgeT(to=(Q{@4c@DafKxP?+t zp=2Ll9-d>*-M#|IkGN~tiX%7T!?B!(3tWL;Smk5mI7zof2%d2rmw7s;%KeVR)c*b5 z{h}h(cypG--kg#b(OqCDVeliea6c~j-|kUN`~H1qW4 zwVqyPcX(i>PzlaYsxF+@rUek3VyWGc+XeKgQ_aoPK1?P$+-a$YgRR-OJL9`6Co;-`*(qf`{hz0^(NR06B zo+|60&YN5&tfPK&Pe2OGgHkI#W)REI%7Azy=k)-HAyb`ne3OHN!vU3UMNUD4fLyD1}0qv&KC(ECh= z=3lW8(&XkD*@^B0Ax!>l+oWp9a0ARchXalg_5O`yILDiMbY#7C9i#^9CoJ6c_N|5e zQ;m|Pgr2oFrH{wmk(#_03WP<~g}oLr2_rw7F7AWEzv1KXNQ&1fcGSGC(nQN770 zBU^=X&~G9xrV*3#(0fd-HzOSo;j}x{g)7H5D1hCaagJ&%)pg6S|Zj(v*Yj ze?c3UoLc?E^E>!z2q;UGXI&zLT-K#@Sz11M7i2phg=GhW!fQz?bsFFbzp=R*pr^;j z{xnO}#(pmUuzY@&cjlS#CJs%0jk@vcTa(}>JpCr^&l_n&^RdWUZzr3CY<_5+J*kpf zwzsxR8eg1`F9a0ovI>5d8G)VJLoKR1^Iz+kvIj;DoqAAguX3=u zLq3ApUyL(aXn4oWcb7CTrLbKQ(O9?%B7B9@w*18r{VjtvPT`Ig(@7YQY zK_dil!%>hMMtu#a?U@ns)IR$CZy1Alf#4#=MUqX&%gB(YrIS$kE23i)H?c3l8(Rvk6`0aJo0Fc~5jRwc#UTnF~*nieuhYkU|96;4;O#%^|OB!24%=z+bqJY|^c zrFiNP$Bo3Hmd@ns51wgUrELiLwaSzS-kdFu)~EOWd)<5Hts8Ac^FPtwY>B?)PXobT z3@hEAp} zN~7tfyD-zQ45Jwje^!(1XO6&XGd+`@u_5Hha=Cx)8r#|i!%rIo1#Ca$+~nhyse}2{ z_hQbiR0j(U?~!)SO40`&8V%2*@@G^Od4SvVK%VKU#joOIen@UCmadr;l((h>O_{rD zq|}PNjvzX%W+qfV!bcCd7Eyt*Bsd(6end!kYfE3^5Emc<`qs(WW6E{ zlh}c8qa^c-PJrlC@Q0Z4(ic_MXLD*hsSiv4b1)f2XRrtx!)HivoEjj-5sqK z)zq8fZzal_%GP2swi#MG*>vlz7dv;In4Vj_I&G{ z5UY@76Pp!fmFy6@9D_)EIZ!ipy2Ee_nyDLQHF`y4o`^COV0&Ut5mwv{f4x$Xdgt+~ z8_L@^?FeV>25Y_(rrj32cr;ck7RjNnap~u*qe@)SObzGnUpd1oYoTS-kyD@TTec)- zFAqf8xUEM0^p&W)?*n8=I#Hmv)n6@H&;&j~C&^lH^dS0=xun0AG8Vq_5v$s7^xC+& zbE+{Z$7zYez!{@a?^I?R%T8b4oSrZtuLrgM8la%MV;_CexT=#+hW@D{Dc}WY6VAAQ z+!rm{Q^9m4Msjo~#)&!0LDj{VV`7B;g~pyaC(>_GI@hNzrP_pDmOlOp)`k`(kr54_ z(ODJMtxQTESS$!&Tjn?zX?k*&=)vhOclIIWv+&w(`@ECx7OK$j|9)Wh#7&%d z_H7mGuR}oeSY!n${a3i>9NS{sBN4E_H7jc5B5AEQw~ftdd`nJEI;4<%MjFjAhvEsB zxT;Y?BG4T;2u~|@LyJLZ$2RHq5LFyQz-LO1LPjlaIxDe_w75|3z`znKb;w5uDYYO2dl&PTlv)YEF)a6Psu!`HqM z%ODzoR0}$gg#lJI~{Hkjz28Yq-4wzra6F z26=-P`0eymJ47f_7NBw=&k%t3*F;y|(JwJ&cQxvO&5`K`&x$46ray`sU6aq+s znEG8dSj_AM3m66RBmuPpk2E4yp{&{ce|!7xw!Rp(Yqg-2)c`@`M^$#*9^3l%lZdDQ z1#2)S&k~lKWEVL8z51RPMMEG=05i$qV1;VIN900e#QRLEE8g>>s=wRXmuQWT zo^K~=ivbNXm@;&Bd_8V|!#0EgUmxYh(B1P9U6m(XRjC1`E8~Tm?Bc4c6<%0}7mGX) zBu7?Q3#Klt53v5S!YW%H?$6X>CdpC@qUi!14K#4oKrbhf*Lb9E&*L#$$sM!@&!tf_ z{@Pb^o{u28pKOg0y^^HjcAyVM_cM*rd!W|g)ZFiSi*hquAXQtYGoNc9BUnFEbZBA@ zJ9zdF4IUr~HQ|C+Hxq3%-1V)TJ;$m2`oK$rJWi`bV^PE?JdC9%jVJ>em4JA)adMDt-X_43;lIC>prn$!erS3~&sC zo*NBa4*=v6Y}CM5WQF%kEgCfAMw(4xEoW1wzHFY{?#DayqFfjp`|uh&kg`fQGyKcw z0Sv<0(-;>)Bmed!!)~Ob%IcYpChJZrR;Hu~BqeS2zr3?D8%v{?NCllIDg<8Gl;Eqr zUsOV8tfbJ5F*$%ai)`9sLQedC2*xY$x=!niOW3aJ-p2YvoV~=EK%_G(9cK0+Kbe`E zSmRIeqc4RoL}pN|Nrj&g!W0ASX5bARsAUjls|F+s4EYbdu$Yv3T20rqt(U_uu;AVxX&?*vV})SVIBws*YBl=A3^FJF;QS%${od7wLMNZ*!bNw}<;tVytedAd^#NdFBRvGXX_;)2x_+0o+$+?N?+!_| zq7u$D-Yo;AeUT80MAy$HW>J@*mjcYT^cPM^CEn*N8IL*@CvU0?4M$k8M7~E#bOib*EXNj|YRpqd zW7vg;B4d06TOPt1z=!uyf`F@DaYQ~~AJlZRGU=4arwNb-7VZhVP z!wb2v(Zn}XH~&icPKq$TEo$L_!-YN8{1R+gIeg+vjkBn2H~8%mM>j4HceoY4NZJ2{ z9P`B$s}N~_4!-)fhG@3pDZQaY;9 z{Ig^jBZk35R{0fMK^w5Y(ec%&i2u6z*kVU$_-#hHD|QLvu~&pJB@R%Qs905v4>}$j z_QEq@{sHyF$>RU`P+TaEjFjUB;m$Fb(N1mi*73(9lBvw0Z3#tF*aTK*du^qpri1C{ zu{Ziydmv@lbk7MO^DL&Cj@>4KxA1s%OcpP&1G7Z#ra=kvHtJ(a%&8>{EGEE;B#h** z5nYd6d8~U+`Ou3_YraGoPm?e7rKOHSk;RL>-V6C$xwjvg~w(M!_ zE3+*(`;&fln?U^*YLQ?caul5WBT@9ZM+o_GRuARb+jjV26eT_18aD>u+-z-iT6hbg z$tmcUVC{g!vF#kd)z>|!I_2o9ClUFSoLb-$3)@^L7eHtIP0S z;)>g}nG&a>4;%i;XPJFi;Eu&dB4hh zt(6AhFT-!i?To+JEAL*Y*Gdf1`3u9#fNCK?eVOhH2_)TyNm^2Z$37)9+p0Ca;Sh!J z>6Y&~1Y3ex^J4r3zAEpAsNGO{4JgItDsxx7@r|C*B8C#s5F7;h$k!4 z4G0K3)l7-uAEZ0R}7i-8`B0vjzKNKIcV-l`9jeXQnu zB(vP)(MCog1zWQp&0DUv={0sTjHMcH8nJ~Fl|QNT1-iGS==7+lY$Dhm1gPxfO^&aq zmfEd`)a(9I4w;7$=V+w~inj;kYl)r9%O-mU4#Js|;iy9(y};R*0Ib#9-Pw<^z7Ooq z+Xl}JMi*Df_=sbVk)1|oacp|(E?^1$mJB+`Gc?3#$Na3%%Y{VyAfwb-M<-5I2^@X2 zuX4JSUPWDd=%j_Hf$ZUxcuxfz$gCLfcZ;e!hnzW=d^uK8*;pS6*!jx}b!SdAW+R}K znFk3vs&&IH{OZfFq>G%Bt^HVtGB>PPe0>bVZ*4tNk zxy`k&)8YX3fzAwF*Rz`7bOmp&U*Z-aiDW?)gY&S?>!92 zQ4nk@M*pniDo_)-m;JR0M;*u4yrIMKXPH*H< z*ny2l;nw1plH`n)HbPKe zzk}ppX!SNw*{=|1Zu;z(k=FxEQ>!J7mQ;t?kd-gy0Ug6+>RvI& z+2utn$Ur!KYJ^649C-W+r5kJdBf44pDwS7T!yKYS%K`K$XKpmB)B~R82nfCnw6ka{ zdk9#iB8xyzoK0uEldZ4Mx{In+Aw)_oA2-wtQ}AVL6KlX;Ho9G`h&Qn*9njPgv>Zqs zlLk(Veg;{Z6u*5hP5)fZZ?NVL9(A{`dK9!66acDzXz@^ox#S-#f)_P#vAh_>M+;7nFloSkW^Ju?7Uh752TQ zD;yxU-R~S&Cj#|*sxQqoy5A&naYQ1t@9w|$?129uFGx+o`l$P-@5{Z;3E4v?q?uC1 zPU^~jS@dK2n)#(#3OlpQF8w)*Cd(Yl)F!AgWVO@4Yryv2)r2owz(Q$yX-q%a6G6EA zcBr0RLhpCh2jpqb&F3?> zjVCbMdgmzS9^=FiAN=6;LTRkMxE{R`%lxI89ZP$+i_5qXLQ+s>gcOG6Rzy-#C{9GX zV&OY2Wf?aKJ6fGcR(QCAA`6qOFi00Rr$vd=4>KFTN!Tld%hS;jYVB;1uQ@-VP-GYD zo+i5}*or-v&F}x@h9kH7!V$6HOG;MNz@dZ>perjTm!KyR?;vv_ZWOa@U@4biI`i_9 zK~vsMaXmv_y(ZPZ{?7OO1}pct`t2lZ@l7AK;$Q~s-bG3L0D3AXE%Zf6GGNuMiJ?d!FEbC zUX-0IntRKH_GPj-?^uMqWFNc(CIAutSpVjnGOrQIx|sDNyk&Q~eunpC%z(Ubd#hq3hC{ z-i`-tAh3|oos{2|H_5A*4AJk?^#TDZSJB(#wt3A4-}UhgO86vb%KK|WGlhMqVVPBx z^ve1d7^E;mEhp~Zo>3r$=+e@|H1$gQ7nfeS?q#G^cusU-w0b;%jh3r?eWWb`yeGN0 zG;)NCS?8SZfTLvMoIq3f+8$AZO`UoKh8rkdJ2L_<02T*(zeDcoXRq}6=L$DcUWVNe zY)7*%x++___>Wpe)}Orh{X+VZ0#_=tBZ)F|Xjx)zJSe1dZVCQHJw)E(tv}M7?s>sHgaO_Cj`VXkRhnN<9$lducp`=`6h#;S_fx75GexIDmoah+j^ zlB0yDZt(Uo@LdLYwj<$SVrIBk;FtXW$yyyjxx*suZxWr{nTB2m>M<$3^}hy>zzLX4 zPQ^6z2*Q&f6f7z0t*i*r|Cz|i1Pd^CE{(lzx8N{#p+lQjX>!06xHl`GW`J8VJ~SH^ zPSh>US4r$msIAiVa9bitdUWBQPZa@wiwkUk>_+pvO3<8t@v20qTSdR|l_Q0RK_;9#&YQCLxze( zeQ>_#UuVl(iCfjk9s-AV^hfa3cz%qEY4^;a5;B*yd(8Kjr-bV7z+QpSk8%EV+M7!o zJSN{=p2$m8O@04<;CFgTtt-8jlePFlk0P_vKSdoZ`)-&=5SR8x&*+2tD22T*c$NU4 z+W@&lf|XqFoFhsYbdEC-T+`B;fzL_kw|9R74vBA*3+HFk6*U4Fj%VAYozZ_lLnE)` zUej^t&#Rh%=zT<;Cc3*w0>&zPHgR*?maa5zjPu*_^rr53K6kgIrvn}=0vO#`vSU*u9v%466eK7pw731)?Egy@tIV|C5VCwVZ}w{%*kcr@*6mhE#V>v zV!6vc@HrUyybcaBOGFUT^w%$1N~0}|>>j*9*;HFf5ih<&$#Q1QkCos}bD0SpqjK}( z%(eF<>jIIlITs1gxSsKR-_#d=bnAiFNoAXCFStm~+AvAKS`fMz$M=))aRyve?W@+2 zSf)~ED@dq1FN+0mTl*5$%bncIp7Er1YKSwRoaCNJfDIjy3W!WGSZj|;$ayS$xz(wi zCjqwKbs%f@Cw@17oyUP#YPPFS=LWxkLVid}7-LD2bPSSS^+!ttu?cxmoQ?D|6kY&a z=mo>c3Vk&v5ZSJQWR!vNK$JnJNkZRluX_XjQF-gR7I`fRx{e#n0N4j`3~lbd*bW7Y z)?kxRI(9~#Db(cYbnum*NOXr;f^o{r{1v`J@r6$K9^f2D`OGWspX4HLlUT{ z$ds?DMx4-oW`d+{@AeHxGjWt%SlM{EAAHvam<1fc42D?= zv6#fiB?Iy&;ps5^gNv>L)dg!TkvtXKMV>0YO{sw#b?Gd@BOXw%)qPY?nP1J%QW^ZU=;tpHUK9hIAMgnH`m=Y8Gi}diSn@8mI1@Iqv*;d zN(hpQsrOzS`52x~5WnmOuif!Ctzg(a$r%>gL*u$o-KOXJz!CSsdY20T3r7 zPMhc_VzT>RD5~l1+i$*avRp^tSOzN?l994>ft>E%Ur!hfsN}%|e%PO0}@4x`UiCfcM zJ;4OCHm&g1OXjPBUY=-i9ci;PF~@uC${H=q53BipY=MlUg(1lbKaQZ4TEtaHB=%O~RgBw3xru#GA%-_ceoVD1>7f7m0K@UXXYB~4E;$+!_)ypUH3>1azdI!tvbn>sJ9r*sP zVsD%L;d`Qy7l`}}oRWIHQengHZo2~N*Wm~(2tLou312Gh@<3Z~P`YcyIicNOHuH-VB(uiStHPbO+(EZX$qK&OY=zCk3T%Ts9Imxuzozl#(De(zqqKiONP9 u{gzu<_1;wsUQ9$|1VZE?QXN*0Z#OMu+eDgkm`#Ca2-hL}FSz~R%lr@fTw_N7 From df8fb23e75182fc20b6880b97311c634dd638390 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Mon, 3 Nov 2025 18:13:21 +0000 Subject: [PATCH 18/24] Fix test assertion for file count with offset Co-authored-by: stnguyen90 <1477010+stnguyen90@users.noreply.github.com> --- tests/e2e/Services/Storage/StorageBase.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/e2e/Services/Storage/StorageBase.php b/tests/e2e/Services/Storage/StorageBase.php index 2012be7375..a89cd711cb 100644 --- a/tests/e2e/Services/Storage/StorageBase.php +++ b/tests/e2e/Services/Storage/StorageBase.php @@ -448,7 +448,7 @@ trait StorageBase ], ]); $this->assertEquals(200, $files['headers']['status-code']); - $this->assertEquals(0, count($files['body']['files'])); + $this->assertEquals(1, count($files['body']['files'])); $files = $this->client->call(Client::METHOD_GET, '/storage/buckets/' . $data['bucketId'] . '/files', array_merge([ 'content-type' => 'application/json', From 2d332264c67f5fc8bd8bddd3213fc79c6333f2c4 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Tue, 4 Nov 2025 06:16:41 +0000 Subject: [PATCH 19/24] Replace with simple webp image for testing Co-authored-by: stnguyen90 <1477010+stnguyen90@users.noreply.github.com> --- tests/resources/logo-after.webp | Bin 6236 -> 634 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/tests/resources/logo-after.webp b/tests/resources/logo-after.webp index b91c5dc1fa912333d58fba3f42bbce0f8559ae73..4a8791784a819b23d95ba2eef1de7fde040e3c9c 100644 GIT binary patch literal 634 zcmV-=0)_ojNk&F;0ssJ4MM6+kP&goF0ssJTAOM{KDv$wW06tM7k3}P*As3mv05}B% zv$t@!kcR;P{Xpv!@<7$3@yGRF!D+xBg?^|10Q?>O0N`ix0X_lbXZ!=i8X!NQdFB3@ z`~&#M_RsE}B>&XCP&$A=RZ5Gds?ur|MJru3R+CU6nxFeN>6BHzR~aLP!2Jh-Oj)OS zUTc+*>VRhxh#-3HF#M%evvD53)-#T$_?XU21=)c35Rr>47o8+2svO*!BE4hGj)15&1k5K zJFntgTznMm4pBQ{{K^81fgBPI$P`H;&vzh z{w6)I_+NkGcJ{-!^<|Uc5C5?1{_M?}{RrUj*_4jC`&}ex`zNVj9-;_Xa7F+NT;e^Wjb`{XDmxYC z%hCkeMpiZ<3^%-y|B&b74a!C5iC1PFI4iiOYUYiA_M0~o^3%=#7Z&_J(fWPJe>iJb UFbRwZDTesrE^7?y000000F0V5`2YX_ literal 6236 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 G0000WrY4pE From 8a9d0a3f337f3230a33d16259186d48eb43dc0e6 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 5 Nov 2025 19:30:21 +0000 Subject: [PATCH 20/24] Rename logo-after.webp to image.webp Co-authored-by: stnguyen90 <1477010+stnguyen90@users.noreply.github.com> --- tests/e2e/Services/Storage/StorageBase.php | 4 ++-- tests/resources/{logo-after.webp => image.webp} | Bin 2 files changed, 2 insertions(+), 2 deletions(-) rename tests/resources/{logo-after.webp => image.webp} (100%) diff --git a/tests/e2e/Services/Storage/StorageBase.php b/tests/e2e/Services/Storage/StorageBase.php index a89cd711cb..c67cfcc99a 100644 --- a/tests/e2e/Services/Storage/StorageBase.php +++ b/tests/e2e/Services/Storage/StorageBase.php @@ -271,7 +271,7 @@ trait StorageBase 'x-appwrite-project' => $this->getProject()['$id'], ], $this->getHeaders()), [ 'fileId' => ID::unique(), - 'file' => new CURLFile(realpath(__DIR__ . '/../../../resources/logo-after.webp'), 'image/webp', 'logo-after.webp'), + 'file' => new CURLFile(realpath(__DIR__ . '/../../../resources/image.webp'), 'image/webp', 'image.webp'), 'permissions' => [ Permission::read(Role::any()), Permission::update(Role::any()), @@ -280,7 +280,7 @@ trait StorageBase ]); $this->assertEquals(201, $webpFile['headers']['status-code']); $this->assertNotEmpty($webpFile['body']['$id']); - $this->assertEquals('logo-after.webp', $webpFile['body']['name']); + $this->assertEquals('image.webp', $webpFile['body']['name']); $this->assertEquals('image/webp', $webpFile['body']['mimeType']); $webpFileId = $webpFile['body']['$id']; diff --git a/tests/resources/logo-after.webp b/tests/resources/image.webp similarity index 100% rename from tests/resources/logo-after.webp rename to tests/resources/image.webp From eb17ffd5d28f42501a677e9309fb460d257e9a7a Mon Sep 17 00:00:00 2001 From: Chirag Aggarwal Date: Mon, 10 Nov 2025 10:15:49 +0530 Subject: [PATCH 21/24] wrap all optional values with default null with nullable --- app/controllers/api/messaging.php | 141 +++++++++--------- app/controllers/api/project.php | 5 +- app/controllers/api/projects.php | 15 +- app/controllers/api/storage.php | 11 +- app/controllers/api/users.php | 5 +- .../Collections/Attributes/Boolean/Create.php | 3 +- .../Collections/Attributes/Boolean/Update.php | 2 +- .../Attributes/Datetime/Update.php | 2 +- .../Collections/Attributes/Email/Create.php | 3 +- .../Collections/Attributes/Email/Update.php | 2 +- .../Collections/Attributes/Enum/Create.php | 3 +- .../Collections/Attributes/Enum/Update.php | 2 +- .../Collections/Attributes/Float/Create.php | 7 +- .../Collections/Attributes/Float/Update.php | 6 +- .../Collections/Attributes/IP/Create.php | 3 +- .../Collections/Attributes/IP/Update.php | 2 +- .../Collections/Attributes/Integer/Create.php | 7 +- .../Collections/Attributes/Integer/Update.php | 6 +- .../Collections/Attributes/Line/Update.php | 2 +- .../Collections/Attributes/Point/Update.php | 2 +- .../Collections/Attributes/Polygon/Update.php | 2 +- .../Attributes/Relationship/Create.php | 5 +- .../Attributes/Relationship/Update.php | 7 +- .../Collections/Attributes/String/Create.php | 3 +- .../Collections/Attributes/String/Update.php | 4 +- .../Collections/Attributes/URL/Create.php | 3 +- .../Collections/Attributes/URL/Update.php | 2 +- .../Http/Databases/Collections/Create.php | 3 +- .../Documents/Attribute/Decrement.php | 5 +- .../Documents/Attribute/Increment.php | 5 +- .../Collections/Documents/Bulk/Delete.php | 3 +- .../Collections/Documents/Bulk/Update.php | 3 +- .../Collections/Documents/Bulk/Upsert.php | 3 +- .../Collections/Documents/Create.php | 5 +- .../Collections/Documents/Delete.php | 2 +- .../Databases/Collections/Documents/Get.php | 3 +- .../Collections/Documents/Update.php | 5 +- .../Collections/Documents/Upsert.php | 5 +- .../Databases/Collections/Documents/XList.php | 3 +- .../Http/Databases/Collections/Update.php | 3 +- .../Tables/Columns/Boolean/Create.php | 3 +- .../Tables/Columns/Boolean/Update.php | 2 +- .../Tables/Columns/Datetime/Update.php | 2 +- .../TablesDB/Tables/Columns/Email/Create.php | 3 +- .../TablesDB/Tables/Columns/Email/Update.php | 2 +- .../TablesDB/Tables/Columns/Enum/Create.php | 3 +- .../TablesDB/Tables/Columns/Enum/Update.php | 2 +- .../TablesDB/Tables/Columns/Float/Create.php | 7 +- .../TablesDB/Tables/Columns/Float/Update.php | 6 +- .../TablesDB/Tables/Columns/IP/Create.php | 3 +- .../TablesDB/Tables/Columns/IP/Update.php | 2 +- .../Tables/Columns/Integer/Create.php | 7 +- .../Tables/Columns/Integer/Update.php | 6 +- .../TablesDB/Tables/Columns/Line/Update.php | 2 +- .../TablesDB/Tables/Columns/Point/Update.php | 2 +- .../Tables/Columns/Polygon/Update.php | 2 +- .../Tables/Columns/Relationship/Create.php | 5 +- .../Tables/Columns/Relationship/Update.php | 7 +- .../TablesDB/Tables/Columns/String/Create.php | 3 +- .../TablesDB/Tables/Columns/String/Update.php | 4 +- .../TablesDB/Tables/Columns/URL/Create.php | 3 +- .../TablesDB/Tables/Columns/URL/Update.php | 2 +- .../Databases/Http/TablesDB/Tables/Create.php | 3 +- .../Http/TablesDB/Tables/Rows/Bulk/Delete.php | 3 +- .../Http/TablesDB/Tables/Rows/Bulk/Update.php | 3 +- .../Http/TablesDB/Tables/Rows/Bulk/Upsert.php | 3 +- .../TablesDB/Tables/Rows/Column/Decrement.php | 5 +- .../TablesDB/Tables/Rows/Column/Increment.php | 5 +- .../Http/TablesDB/Tables/Rows/Create.php | 5 +- .../Http/TablesDB/Tables/Rows/Delete.php | 2 +- .../Http/TablesDB/Tables/Rows/Get.php | 3 +- .../Http/TablesDB/Tables/Rows/Update.php | 5 +- .../Http/TablesDB/Tables/Rows/Upsert.php | 5 +- .../Http/TablesDB/Tables/Rows/XList.php | 3 +- .../Databases/Http/TablesDB/Tables/Update.php | 3 +- .../Functions/Http/Deployments/Create.php | 5 +- .../Functions/Http/Executions/Create.php | 3 +- .../Functions/Http/Variables/Update.php | 5 +- .../Modules/Sites/Http/Deployments/Create.php | 7 +- .../Modules/Sites/Http/Variables/Update.php | 5 +- 80 files changed, 254 insertions(+), 200 deletions(-) diff --git a/app/controllers/api/messaging.php b/app/controllers/api/messaging.php index 5193d0b30f..58a0ffe42f 100644 --- a/app/controllers/api/messaging.php +++ b/app/controllers/api/messaging.php @@ -49,6 +49,7 @@ use Utopia\Validator\ArrayList; use Utopia\Validator\Boolean; use Utopia\Validator\Integer; use Utopia\Validator\JSON; +use Utopia\Validator\Nullable; use Utopia\Validator\Range; use Utopia\Validator\Text; use Utopia\Validator\WhiteList; @@ -80,12 +81,12 @@ App::post('/v1/messaging/providers/mailgun') ->param('name', '', new Text(128), 'Provider name.') ->param('apiKey', '', new Text(0), 'Mailgun API Key.', true) ->param('domain', '', new Text(0), 'Mailgun Domain.', true) - ->param('isEuRegion', null, new Boolean(), 'Set as EU region.', true) + ->param('isEuRegion', null, new Nullable(new Boolean()), 'Set as EU region.', true) ->param('fromName', '', new Text(128, 0), 'Sender Name.', true) ->param('fromEmail', '', new Email(), 'Sender email address.', true) ->param('replyToName', '', new Text(128, 0), 'Name set in the reply to field for the mail. Default value is sender name. Reply to name must have reply to email as well.', true) ->param('replyToEmail', '', new Email(), 'Email set in the reply to field for the mail. Default value is sender email. Reply to email must have reply to name as well.', true) - ->param('enabled', null, new Boolean(), 'Set as enabled.', true) + ->param('enabled', null, new Nullable(new Boolean()), 'Set as enabled.', true) ->inject('queueForEvents') ->inject('dbForProject') ->inject('response') @@ -177,7 +178,7 @@ App::post('/v1/messaging/providers/sendgrid') ->param('fromEmail', '', new Email(), 'Sender email address.', true) ->param('replyToName', '', new Text(128, 0), 'Name set in the reply to field for the mail. Default value is sender name.', true) ->param('replyToEmail', '', new Email(), 'Email set in the reply to field for the mail. Default value is sender email.', true) - ->param('enabled', null, new Boolean(), 'Set as enabled.', true) + ->param('enabled', null, new Nullable(new Boolean()), 'Set as enabled.', true) ->inject('queueForEvents') ->inject('dbForProject') ->inject('response') @@ -259,7 +260,7 @@ App::post('/v1/messaging/providers/resend') ->param('fromEmail', '', new Email(), 'Sender email address.', true) ->param('replyToName', '', new Text(128, 0), 'Name set in the reply to field for the mail. Default value is sender name.', true) ->param('replyToEmail', '', new Email(), 'Email set in the reply to field for the mail. Default value is sender email.', true) - ->param('enabled', null, new Boolean(), 'Set as enabled.', true) + ->param('enabled', null, new Nullable(new Boolean()), 'Set as enabled.', true) ->inject('queueForEvents') ->inject('dbForProject') ->inject('response') @@ -366,7 +367,7 @@ App::post('/v1/messaging/providers/smtp') ->param('fromEmail', '', new Email(), 'Sender email address.', true) ->param('replyToName', '', new Text(128, 0), 'Name set in the reply to field for the mail. Default value is sender name.', true) ->param('replyToEmail', '', new Email(), 'Email set in the reply to field for the mail. Default value is sender email.', true) - ->param('enabled', null, new Boolean(), 'Set as enabled.', true) + ->param('enabled', null, new Nullable(new Boolean()), 'Set as enabled.', true) ->inject('queueForEvents') ->inject('dbForProject') ->inject('response') @@ -453,7 +454,7 @@ App::post('/v1/messaging/providers/msg91') ->param('templateId', '', new Text(0), 'Msg91 template ID', true) ->param('senderId', '', new Text(0), 'Msg91 sender ID.', true) ->param('authKey', '', new Text(0), 'Msg91 auth key.', true) - ->param('enabled', null, new Boolean(), 'Set as enabled.', true) + ->param('enabled', null, new Nullable(new Boolean()), 'Set as enabled.', true) ->inject('queueForEvents') ->inject('dbForProject') ->inject('response') @@ -536,7 +537,7 @@ App::post('/v1/messaging/providers/telesign') ->param('from', '', new Phone(), 'Sender Phone number. Format this number with a leading \'+\' and a country code, e.g., +16175551212.', true) ->param('customerId', '', new Text(0), 'Telesign customer ID.', true) ->param('apiKey', '', new Text(0), 'Telesign API key.', true) - ->param('enabled', null, new Boolean(), 'Set as enabled.', true) + ->param('enabled', null, new Nullable(new Boolean()), 'Set as enabled.', true) ->inject('queueForEvents') ->inject('dbForProject') ->inject('response') @@ -620,7 +621,7 @@ App::post('/v1/messaging/providers/textmagic') ->param('from', '', new Phone(), 'Sender Phone number. Format this number with a leading \'+\' and a country code, e.g., +16175551212.', true) ->param('username', '', new Text(0), 'Textmagic username.', true) ->param('apiKey', '', new Text(0), 'Textmagic apiKey.', true) - ->param('enabled', null, new Boolean(), 'Set as enabled.', true) + ->param('enabled', null, new Nullable(new Boolean()), 'Set as enabled.', true) ->inject('queueForEvents') ->inject('dbForProject') ->inject('response') @@ -704,7 +705,7 @@ App::post('/v1/messaging/providers/twilio') ->param('from', '', new Phone(), 'Sender Phone number. Format this number with a leading \'+\' and a country code, e.g., +16175551212.', true) ->param('accountSid', '', new Text(0), 'Twilio account secret ID.', true) ->param('authToken', '', new Text(0), 'Twilio authentication token.', true) - ->param('enabled', null, new Boolean(), 'Set as enabled.', true) + ->param('enabled', null, new Nullable(new Boolean()), 'Set as enabled.', true) ->inject('queueForEvents') ->inject('dbForProject') ->inject('response') @@ -788,7 +789,7 @@ App::post('/v1/messaging/providers/vonage') ->param('from', '', new Phone(), 'Sender Phone number. Format this number with a leading \'+\' and a country code, e.g., +16175551212.', true) ->param('apiKey', '', new Text(0), 'Vonage API key.', true) ->param('apiSecret', '', new Text(0), 'Vonage API secret.', true) - ->param('enabled', null, new Boolean(), 'Set as enabled.', true) + ->param('enabled', null, new Nullable(new Boolean()), 'Set as enabled.', true) ->inject('queueForEvents') ->inject('dbForProject') ->inject('response') @@ -888,8 +889,8 @@ App::post('/v1/messaging/providers/fcm') ]) ->param('providerId', '', new CustomId(), 'Provider ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can\'t start with a special char. Max length is 36 chars.') ->param('name', '', new Text(128), 'Provider name.') - ->param('serviceAccountJSON', null, new JSON(), 'FCM service account JSON.', true) - ->param('enabled', null, new Boolean(), 'Set as enabled.', true) + ->param('serviceAccountJSON', null, new Nullable(new JSON()), 'FCM service account JSON.', true) + ->param('enabled', null, new Nullable(new Boolean()), 'Set as enabled.', true) ->inject('queueForEvents') ->inject('dbForProject') ->inject('response') @@ -982,7 +983,7 @@ App::post('/v1/messaging/providers/apns') ->param('teamId', '', new Text(0), 'APNS team ID.', true) ->param('bundleId', '', new Text(0), 'APNS bundle ID.', true) ->param('sandbox', false, new Boolean(), 'Use APNS sandbox environment.', true) - ->param('enabled', null, new Boolean(), 'Set as enabled.', true) + ->param('enabled', null, new Nullable(new Boolean()), 'Set as enabled.', true) ->inject('queueForEvents') ->inject('dbForProject') ->inject('response') @@ -1270,8 +1271,8 @@ App::patch('/v1/messaging/providers/mailgun/:providerId') ->param('name', '', new Text(128), 'Provider name.', true) ->param('apiKey', '', new Text(0), 'Mailgun API Key.', true) ->param('domain', '', new Text(0), 'Mailgun Domain.', true) - ->param('isEuRegion', null, new Boolean(), 'Set as EU region.', true) - ->param('enabled', null, new Boolean(), 'Set as enabled.', true) + ->param('isEuRegion', null, new Nullable(new Boolean()), 'Set as EU region.', true) + ->param('enabled', null, new Nullable(new Boolean()), 'Set as enabled.', true) ->param('fromName', '', new Text(128), 'Sender Name.', true) ->param('fromEmail', '', new Email(), 'Sender email address.', true) ->param('replyToName', '', new Text(128), 'Name set in the reply to field for the mail. Default value is sender name.', true) @@ -1381,7 +1382,7 @@ App::patch('/v1/messaging/providers/sendgrid/:providerId') )) ->param('providerId', '', new UID(), 'Provider ID.') ->param('name', '', new Text(128), 'Provider name.', true) - ->param('enabled', null, new Boolean(), 'Set as enabled.', true) + ->param('enabled', null, new Nullable(new Boolean()), 'Set as enabled.', true) ->param('apiKey', '', new Text(0), 'Sendgrid API key.', true) ->param('fromName', '', new Text(128), 'Sender Name.', true) ->param('fromEmail', '', new Email(), 'Sender email address.', true) @@ -1479,7 +1480,7 @@ App::patch('/v1/messaging/providers/resend/:providerId') )) ->param('providerId', '', new UID(), 'Provider ID.') ->param('name', '', new Text(128), 'Provider name.', true) - ->param('enabled', null, new Boolean(), 'Set as enabled.', true) + ->param('enabled', null, new Nullable(new Boolean()), 'Set as enabled.', true) ->param('apiKey', '', new Text(0), 'Resend API key.', true) ->param('fromName', '', new Text(128), 'Sender Name.', true) ->param('fromEmail', '', new Email(), 'Sender email address.', true) @@ -1597,17 +1598,17 @@ App::patch('/v1/messaging/providers/smtp/:providerId') ->param('providerId', '', new UID(), 'Provider ID.') ->param('name', '', new Text(128), 'Provider name.', true) ->param('host', '', new Text(0), 'SMTP hosts. Either a single hostname or multiple semicolon-delimited hostnames. You can also specify a different port for each host such as `smtp1.example.com:25;smtp2.example.com`. You can also specify encryption type, for example: `tls://smtp1.example.com:587;ssl://smtp2.example.com:465"`. Hosts will be tried in order.', true) - ->param('port', null, new Range(1, 65535), 'SMTP port.', true) + ->param('port', null, new Nullable(new Range(1, 65535)), 'SMTP port.', true) ->param('username', '', new Text(0), 'Authentication username.', true) ->param('password', '', new Text(0), 'Authentication password.', true) ->param('encryption', '', new WhiteList(['none', 'ssl', 'tls']), 'Encryption type. Can be \'ssl\' or \'tls\'', true) - ->param('autoTLS', null, new Boolean(), 'Enable SMTP AutoTLS feature.', true) + ->param('autoTLS', null, new Nullable(new Boolean()), 'Enable SMTP AutoTLS feature.', true) ->param('mailer', '', new Text(0), 'The value to use for the X-Mailer header.', true) ->param('fromName', '', new Text(128), 'Sender Name.', true) ->param('fromEmail', '', new Email(), 'Sender email address.', true) ->param('replyToName', '', new Text(128), 'Name set in the Reply To field for the mail. Default value is Sender Name.', true) ->param('replyToEmail', '', new Text(128), 'Email set in the Reply To field for the mail. Default value is Sender Email.', true) - ->param('enabled', null, new Boolean(), 'Set as enabled.', true) + ->param('enabled', null, new Nullable(new Boolean()), 'Set as enabled.', true) ->inject('queueForEvents') ->inject('dbForProject') ->inject('response') @@ -1725,7 +1726,7 @@ App::patch('/v1/messaging/providers/msg91/:providerId') )) ->param('providerId', '', new UID(), 'Provider ID.') ->param('name', '', new Text(128), 'Provider name.', true) - ->param('enabled', null, new Boolean(), 'Set as enabled.', true) + ->param('enabled', null, new Nullable(new Boolean()), 'Set as enabled.', true) ->param('templateId', '', new Text(0), 'Msg91 template ID.', true) ->param('senderId', '', new Text(0), 'Msg91 sender ID.', true) ->param('authKey', '', new Text(0), 'Msg91 auth key.', true) @@ -1812,7 +1813,7 @@ App::patch('/v1/messaging/providers/telesign/:providerId') )) ->param('providerId', '', new UID(), 'Provider ID.') ->param('name', '', new Text(128), 'Provider name.', true) - ->param('enabled', null, new Boolean(), 'Set as enabled.', true) + ->param('enabled', null, new Nullable(new Boolean()), 'Set as enabled.', true) ->param('customerId', '', new Text(0), 'Telesign customer ID.', true) ->param('apiKey', '', new Text(0), 'Telesign API key.', true) ->param('from', '', new Text(256), 'Sender number.', true) @@ -1901,7 +1902,7 @@ App::patch('/v1/messaging/providers/textmagic/:providerId') )) ->param('providerId', '', new UID(), 'Provider ID.') ->param('name', '', new Text(128), 'Provider name.', true) - ->param('enabled', null, new Boolean(), 'Set as enabled.', true) + ->param('enabled', null, new Nullable(new Boolean()), 'Set as enabled.', true) ->param('username', '', new Text(0), 'Textmagic username.', true) ->param('apiKey', '', new Text(0), 'Textmagic apiKey.', true) ->param('from', '', new Text(256), 'Sender number.', true) @@ -1990,7 +1991,7 @@ App::patch('/v1/messaging/providers/twilio/:providerId') )) ->param('providerId', '', new UID(), 'Provider ID.') ->param('name', '', new Text(128), 'Provider name.', true) - ->param('enabled', null, new Boolean(), 'Set as enabled.', true) + ->param('enabled', null, new Nullable(new Boolean()), 'Set as enabled.', true) ->param('accountSid', '', new Text(0), 'Twilio account secret ID.', true) ->param('authToken', '', new Text(0), 'Twilio authentication token.', true) ->param('from', '', new Text(256), 'Sender number.', true) @@ -2079,7 +2080,7 @@ App::patch('/v1/messaging/providers/vonage/:providerId') )) ->param('providerId', '', new UID(), 'Provider ID.') ->param('name', '', new Text(128), 'Provider name.', true) - ->param('enabled', null, new Boolean(), 'Set as enabled.', true) + ->param('enabled', null, new Nullable(new Boolean()), 'Set as enabled.', true) ->param('apiKey', '', new Text(0), 'Vonage API key.', true) ->param('apiSecret', '', new Text(0), 'Vonage API secret.', true) ->param('from', '', new Text(256), 'Sender number.', true) @@ -2187,8 +2188,8 @@ App::patch('/v1/messaging/providers/fcm/:providerId') ]) ->param('providerId', '', new UID(), 'Provider ID.') ->param('name', '', new Text(128), 'Provider name.', true) - ->param('enabled', null, new Boolean(), 'Set as enabled.', true) - ->param('serviceAccountJSON', null, new JSON(), 'FCM service account JSON.', true) + ->param('enabled', null, new Nullable(new Boolean()), 'Set as enabled.', true) + ->param('serviceAccountJSON', null, new Nullable(new JSON()), 'FCM service account JSON.', true) ->inject('queueForEvents') ->inject('dbForProject') ->inject('response') @@ -2282,12 +2283,12 @@ App::patch('/v1/messaging/providers/apns/:providerId') ]) ->param('providerId', '', new UID(), 'Provider ID.') ->param('name', '', new Text(128), 'Provider name.', true) - ->param('enabled', null, new Boolean(), 'Set as enabled.', true) + ->param('enabled', null, new Nullable(new Boolean()), 'Set as enabled.', true) ->param('authKey', '', new Text(0), 'APNS authentication key.', true) ->param('authKeyId', '', new Text(0), 'APNS authentication key ID.', true) ->param('teamId', '', new Text(0), 'APNS team ID.', true) ->param('bundleId', '', new Text(0), 'APNS bundle ID.', true) - ->param('sandbox', null, new Boolean(), 'Use APNS sandbox environment.', true) + ->param('sandbox', null, new Nullable(new Boolean()), 'Use APNS sandbox environment.', true) ->inject('queueForEvents') ->inject('dbForProject') ->inject('response') @@ -2676,8 +2677,8 @@ App::patch('/v1/messaging/topics/:topicId') ] )) ->param('topicId', '', new UID(), 'Topic ID.') - ->param('name', null, new Text(128), 'Topic Name.', true) - ->param('subscribe', null, new Roles(APP_LIMIT_ARRAY_PARAMS_SIZE), 'An array of role strings with subscribe permission. By default all users are granted with any subscribe permission. [learn more about roles](https://appwrite.io/docs/permissions#permission-roles). Maximum of ' . APP_LIMIT_ARRAY_PARAMS_SIZE . ' roles are allowed, each 64 characters long.', true) + ->param('name', null, new Nullable(new Text(128)), 'Topic Name.', true) + ->param('subscribe', null, new Nullable(new Roles(APP_LIMIT_ARRAY_PARAMS_SIZE)), 'An array of role strings with subscribe permission. By default all users are granted with any subscribe permission. [learn more about roles](https://appwrite.io/docs/permissions#permission-roles). Maximum of ' . APP_LIMIT_ARRAY_PARAMS_SIZE . ' roles are allowed, each 64 characters long.', true) ->inject('queueForEvents') ->inject('dbForProject') ->inject('response') @@ -3190,7 +3191,7 @@ App::post('/v1/messaging/messages/email') ->param('attachments', [], new ArrayList(new CompoundUID()), 'Array of compound ID strings of bucket IDs and file IDs to be attached to the email. They should be formatted as :.', true) ->param('draft', false, new Boolean(), 'Is message a draft', true) ->param('html', false, new Boolean(), 'Is content of type HTML', true) - ->param('scheduledAt', null, new DatetimeValidator(requireDateInFuture: true), 'Scheduled delivery time for message in [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format. DateTime value must be in future.', true) + ->param('scheduledAt', null, new Nullable(new DatetimeValidator(requireDateInFuture: true)), 'Scheduled delivery time for message in [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format. DateTime value must be in future.', true) ->inject('queueForEvents') ->inject('dbForProject') ->inject('dbForPlatform') @@ -3363,7 +3364,7 @@ App::post('/v1/messaging/messages/sms') ->param('users', [], new ArrayList(new UID()), 'List of User IDs.', true) ->param('targets', [], new ArrayList(new UID()), 'List of Targets IDs.', true) ->param('draft', false, new Boolean(), 'Is message a draft', true) - ->param('scheduledAt', null, new DatetimeValidator(requireDateInFuture: true), 'Scheduled delivery time for message in [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format. DateTime value must be in future.', true) + ->param('scheduledAt', null, new Nullable(new DatetimeValidator(requireDateInFuture: true)), 'Scheduled delivery time for message in [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format. DateTime value must be in future.', true) ->inject('queueForEvents') ->inject('dbForProject') ->inject('dbForPlatform') @@ -3486,7 +3487,7 @@ App::post('/v1/messaging/messages/push') ->param('topics', [], new ArrayList(new UID()), 'List of Topic IDs.', true) ->param('users', [], new ArrayList(new UID()), 'List of User IDs.', true) ->param('targets', [], new ArrayList(new UID()), 'List of Targets IDs.', true) - ->param('data', null, new JSON(), 'Additional key-value pair data for push notification.', true) + ->param('data', null, new Nullable(new JSON()), 'Additional key-value pair data for push notification.', true) ->param('action', '', new Text(256), 'Action for push notification.', true) ->param('image', '', new CompoundUID(), 'Image for push notification. Must be a compound bucket ID to file ID of a jpeg, png, or bmp image in Appwrite Storage. It should be formatted as :.', true) ->param('icon', '', new Text(256), 'Icon for push notification. Available only for Android and Web Platform.', true) @@ -3495,7 +3496,7 @@ App::post('/v1/messaging/messages/push') ->param('tag', '', new Text(256), 'Tag for push notification. Available only for Android Platform.', true) ->param('badge', -1, new Integer(), 'Badge for push notification. Available only for iOS Platform.', true) ->param('draft', false, new Boolean(), 'Is message a draft', true) - ->param('scheduledAt', null, new DatetimeValidator(requireDateInFuture: true), 'Scheduled delivery time for message in [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format. DateTime value must be in future.', true) + ->param('scheduledAt', null, new Nullable(new DatetimeValidator(requireDateInFuture: true)), 'Scheduled delivery time for message in [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format. DateTime value must be in future.', true) ->param('contentAvailable', false, new Boolean(), 'If set to true, the notification will be delivered in the background. Available only for iOS Platform.', true) ->param('critical', false, new Boolean(), 'If set to true, the notification will be marked as critical. This requires the app to have the critical notification entitlement. Available only for iOS Platform.', true) ->param('priority', 'high', new WhiteList(['normal', 'high']), 'Set the notification priority. "normal" will consider device state and may not deliver notifications immediately. "high" will always attempt to immediately deliver the notification.', true) @@ -3981,17 +3982,17 @@ App::patch('/v1/messaging/messages/email/:messageId') ] )) ->param('messageId', '', new UID(), 'Message ID.') - ->param('topics', null, new ArrayList(new UID()), 'List of Topic IDs.', true) - ->param('users', null, new ArrayList(new UID()), 'List of User IDs.', true) - ->param('targets', null, new ArrayList(new UID()), 'List of Targets IDs.', true) - ->param('subject', null, new Text(998), 'Email Subject.', true) - ->param('content', null, new Text(64230), 'Email Content.', true) - ->param('draft', null, new Boolean(), 'Is message a draft', true) - ->param('html', null, new Boolean(), 'Is content of type HTML', true) - ->param('cc', null, new ArrayList(new UID()), 'Array of target IDs to be added as CC.', true) - ->param('bcc', null, new ArrayList(new UID()), 'Array of target IDs to be added as BCC.', true) - ->param('scheduledAt', null, new DatetimeValidator(requireDateInFuture: true), 'Scheduled delivery time for message in [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format. DateTime value must be in future.', true) - ->param('attachments', null, new ArrayList(new CompoundUID()), 'Array of compound ID strings of bucket IDs and file IDs to be attached to the email. They should be formatted as :.', true) + ->param('topics', null, new Nullable(new ArrayList(new UID())), 'List of Topic IDs.', true) + ->param('users', null, new Nullable(new ArrayList(new UID())), 'List of User IDs.', true) + ->param('targets', null, new Nullable(new ArrayList(new UID())), 'List of Targets IDs.', true) + ->param('subject', null, new Nullable(new Text(998)), 'Email Subject.', true) + ->param('content', null, new Nullable(new Text(64230)), 'Email Content.', true) + ->param('draft', null, new Nullable(new Boolean()), 'Is message a draft', true) + ->param('html', null, new Nullable(new Boolean()), 'Is content of type HTML', true) + ->param('cc', null, new Nullable(new ArrayList(new UID())), 'Array of target IDs to be added as CC.', true) + ->param('bcc', null, new Nullable(new ArrayList(new UID())), 'Array of target IDs to be added as BCC.', true) + ->param('scheduledAt', null, new Nullable(new DatetimeValidator(requireDateInFuture: true)), 'Scheduled delivery time for message in [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format. DateTime value must be in future.', true) + ->param('attachments', null, new Nullable(new ArrayList(new CompoundUID())), 'Array of compound ID strings of bucket IDs and file IDs to be attached to the email. They should be formatted as :.', true) ->inject('queueForEvents') ->inject('dbForProject') ->inject('dbForPlatform') @@ -4207,12 +4208,12 @@ App::patch('/v1/messaging/messages/sms/:messageId') ) ]) ->param('messageId', '', new UID(), 'Message ID.') - ->param('topics', null, new ArrayList(new UID()), 'List of Topic IDs.', true) - ->param('users', null, new ArrayList(new UID()), 'List of User IDs.', true) - ->param('targets', null, new ArrayList(new UID()), 'List of Targets IDs.', true) - ->param('content', null, new Text(64230), 'Email Content.', true) - ->param('draft', null, new Boolean(), 'Is message a draft', true) - ->param('scheduledAt', null, new DatetimeValidator(requireDateInFuture: true), 'Scheduled delivery time for message in [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format. DateTime value must be in future.', true) + ->param('topics', null, new Nullable(new ArrayList(new UID())), 'List of Topic IDs.', true) + ->param('users', null, new Nullable(new ArrayList(new UID())), 'List of User IDs.', true) + ->param('targets', null, new Nullable(new ArrayList(new UID())), 'List of Targets IDs.', true) + ->param('content', null, new Nullable(new Text(64230)), 'Email Content.', true) + ->param('draft', null, new Nullable(new Boolean()), 'Is message a draft', true) + ->param('scheduledAt', null, new Nullable(new DatetimeValidator(requireDateInFuture: true)), 'Scheduled delivery time for message in [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format. DateTime value must be in future.', true) ->inject('queueForEvents') ->inject('dbForProject') ->inject('dbForPlatform') @@ -4369,24 +4370,24 @@ App::patch('/v1/messaging/messages/push/:messageId') ] )) ->param('messageId', '', new UID(), 'Message ID.') - ->param('topics', null, new ArrayList(new UID()), 'List of Topic IDs.', true) - ->param('users', null, new ArrayList(new UID()), 'List of User IDs.', true) - ->param('targets', null, new ArrayList(new UID()), 'List of Targets IDs.', true) - ->param('title', null, new Text(256), 'Title for push notification.', true) - ->param('body', null, new Text(64230), 'Body for push notification.', true) - ->param('data', null, new JSON(), 'Additional Data for push notification.', true) - ->param('action', null, new Text(256), 'Action for push notification.', true) - ->param('image', null, new CompoundUID(), 'Image for push notification. Must be a compound bucket ID to file ID of a jpeg, png, or bmp image in Appwrite Storage. It should be formatted as :.', true) - ->param('icon', null, new Text(256), 'Icon for push notification. Available only for Android and Web platforms.', true) - ->param('sound', null, new Text(256), 'Sound for push notification. Available only for Android and iOS platforms.', true) - ->param('color', null, new Text(256), 'Color for push notification. Available only for Android platforms.', true) - ->param('tag', null, new Text(256), 'Tag for push notification. Available only for Android platforms.', true) - ->param('badge', null, new Integer(), 'Badge for push notification. Available only for iOS platforms.', true) - ->param('draft', null, new Boolean(), 'Is message a draft', true) - ->param('scheduledAt', null, new DatetimeValidator(requireDateInFuture: true), 'Scheduled delivery time for message in [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format. DateTime value must be in future.', true) - ->param('contentAvailable', null, new Boolean(), 'If set to true, the notification will be delivered in the background. Available only for iOS Platform.', true) - ->param('critical', null, new Boolean(), 'If set to true, the notification will be marked as critical. This requires the app to have the critical notification entitlement. Available only for iOS Platform.', true) - ->param('priority', null, new WhiteList(['normal', 'high']), 'Set the notification priority. "normal" will consider device battery state and may send notifications later. "high" will always attempt to immediately deliver the notification.', true) + ->param('topics', null, new Nullable(new ArrayList(new UID())), 'List of Topic IDs.', true) + ->param('users', null, new Nullable(new ArrayList(new UID())), 'List of User IDs.', true) + ->param('targets', null, new Nullable(new ArrayList(new UID())), 'List of Targets IDs.', true) + ->param('title', null, new Nullable(new Text(256)), 'Title for push notification.', true) + ->param('body', null, new Nullable(new Text(64230)), 'Body for push notification.', true) + ->param('data', null, new Nullable(new JSON()), 'Additional Data for push notification.', true) + ->param('action', null, new Nullable(new Text(256)), 'Action for push notification.', true) + ->param('image', null, new Nullable(new CompoundUID()), 'Image for push notification. Must be a compound bucket ID to file ID of a jpeg, png, or bmp image in Appwrite Storage. It should be formatted as :.', true) + ->param('icon', null, new Nullable(new Text(256)), 'Icon for push notification. Available only for Android and Web platforms.', true) + ->param('sound', null, new Nullable(new Text(256)), 'Sound for push notification. Available only for Android and iOS platforms.', true) + ->param('color', null, new Nullable(new Text(256)), 'Color for push notification. Available only for Android platforms.', true) + ->param('tag', null, new Nullable(new Text(256)), 'Tag for push notification. Available only for Android platforms.', true) + ->param('badge', null, new Nullable(new Integer()), 'Badge for push notification. Available only for iOS platforms.', true) + ->param('draft', null, new Nullable(new Boolean()), 'Is message a draft', true) + ->param('scheduledAt', null, new Nullable(new DatetimeValidator(requireDateInFuture: true)), 'Scheduled delivery time for message in [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format. DateTime value must be in future.', true) + ->param('contentAvailable', null, new Nullable(new Boolean()), 'If set to true, the notification will be delivered in the background. Available only for iOS Platform.', true) + ->param('critical', null, new Nullable(new Boolean()), 'If set to true, the notification will be marked as critical. This requires the app to have the critical notification entitlement. Available only for iOS Platform.', true) + ->param('priority', null, new Nullable(new WhiteList(['normal', 'high'])), 'Set the notification priority. "normal" will consider device battery state and may send notifications later. "high" will always attempt to immediately deliver the notification.', true) ->inject('queueForEvents') ->inject('dbForProject') ->inject('dbForPlatform') diff --git a/app/controllers/api/project.php b/app/controllers/api/project.php index 390e88637a..a57675d3e8 100644 --- a/app/controllers/api/project.php +++ b/app/controllers/api/project.php @@ -18,6 +18,7 @@ use Utopia\Database\Validator\Authorization; use Utopia\Database\Validator\Datetime as DateTimeValidator; use Utopia\Database\Validator\UID; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; use Utopia\Validator\Text; use Utopia\Validator\WhiteList; @@ -526,8 +527,8 @@ App::put('/v1/project/variables/:variableId') )) ->param('variableId', '', new UID(), 'Variable unique ID.', false) ->param('key', null, new Text(255), 'Variable key. Max length: 255 chars.', false) - ->param('value', null, new Text(8192, 0), 'Variable value. Max length: 8192 chars.', true) - ->param('secret', null, new Boolean(), 'Secret variables can be updated or deleted, but only projects can read them during build and runtime.', true) + ->param('value', null, new Nullable(new Text(8192, 0)), 'Variable value. Max length: 8192 chars.', true) + ->param('secret', null, new Nullable(new Boolean()), 'Secret variables can be updated or deleted, but only projects can read them during build and runtime.', true) ->inject('project') ->inject('response') ->inject('dbForProject') diff --git a/app/controllers/api/projects.php b/app/controllers/api/projects.php index 2b30b1cd08..760a4f23a6 100644 --- a/app/controllers/api/projects.php +++ b/app/controllers/api/projects.php @@ -46,6 +46,7 @@ use Utopia\Validator\Boolean; use Utopia\Validator\Hostname; use Utopia\Validator\Integer; use Utopia\Validator\Multiple; +use Utopia\Validator\Nullable; use Utopia\Validator\Range; use Utopia\Validator\Text; use Utopia\Validator\URL; @@ -678,9 +679,9 @@ App::patch('/v1/projects/:projectId/oauth2') )) ->param('projectId', '', new UID(), 'Project unique ID.') ->param('provider', '', new WhiteList(\array_keys(Config::getParam('oAuthProviders')), true), 'Provider Name') - ->param('appId', null, new Text(256), 'Provider app ID. Max length: 256 chars.', true) - ->param('secret', null, new text(512), 'Provider secret key. Max length: 512 chars.', true) - ->param('enabled', null, new Boolean(), 'Provider status. Set to \'false\' to disable new session creation.', true) + ->param('appId', null, new Nullable(new Text(256)), 'Provider app ID. Max length: 256 chars.', true) + ->param('secret', null, new Nullable(new text(512)), 'Provider secret key. Max length: 512 chars.', true) + ->param('enabled', null, new Nullable(new Boolean()), 'Provider status. Set to \'false\' to disable new session creation.', true) ->inject('response') ->inject('dbForPlatform') ->action(function (string $projectId, string $provider, ?string $appId, ?string $secret, ?bool $enabled, Response $response, Database $dbForPlatform) { @@ -1476,8 +1477,8 @@ App::post('/v1/projects/:projectId/keys') )) ->param('projectId', '', new UID(), 'Project unique ID.') ->param('name', null, new Text(128), 'Key name. Max length: 128 chars.') - ->param('scopes', null, new ArrayList(new WhiteList(array_keys(Config::getParam('scopes')), true), APP_LIMIT_ARRAY_PARAMS_SIZE), 'Key scopes list. Maximum of ' . APP_LIMIT_ARRAY_PARAMS_SIZE . ' scopes are allowed.') - ->param('expire', null, new DatetimeValidator(), 'Expiration time in [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format. Use null for unlimited expiration.', true) + ->param('scopes', null, new Nullable(new ArrayList(new WhiteList(array_keys(Config::getParam('scopes')), true), APP_LIMIT_ARRAY_PARAMS_SIZE)), 'Key scopes list. Maximum of ' . APP_LIMIT_ARRAY_PARAMS_SIZE . ' scopes are allowed.') + ->param('expire', null, new Nullable(new DatetimeValidator()), 'Expiration time in [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format. Use null for unlimited expiration.', true) ->inject('response') ->inject('dbForPlatform') ->action(function (string $projectId, string $name, array $scopes, ?string $expire, Response $response, Database $dbForPlatform) { @@ -1615,8 +1616,8 @@ App::put('/v1/projects/:projectId/keys/:keyId') ->param('projectId', '', new UID(), 'Project unique ID.') ->param('keyId', '', new UID(), 'Key unique ID.') ->param('name', null, new Text(128), 'Key name. Max length: 128 chars.') - ->param('scopes', null, new ArrayList(new WhiteList(array_keys(Config::getParam('scopes')), true), APP_LIMIT_ARRAY_PARAMS_SIZE), 'Key scopes list. Maximum of ' . APP_LIMIT_ARRAY_PARAMS_SIZE . ' events are allowed.') - ->param('expire', null, new DatetimeValidator(), 'Expiration time in [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format. Use null for unlimited expiration.', true) + ->param('scopes', null, new Nullable(new ArrayList(new WhiteList(array_keys(Config::getParam('scopes')), true), APP_LIMIT_ARRAY_PARAMS_SIZE)), 'Key scopes list. Maximum of ' . APP_LIMIT_ARRAY_PARAMS_SIZE . ' events are allowed.') + ->param('expire', null, new Nullable(new DatetimeValidator()), 'Expiration time in [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format. Use null for unlimited expiration.', true) ->inject('response') ->inject('dbForPlatform') ->action(function (string $projectId, string $keyId, string $name, array $scopes, ?string $expire, Response $response, Database $dbForPlatform) { diff --git a/app/controllers/api/storage.php b/app/controllers/api/storage.php index 72acd7b4a2..22d456c7c6 100644 --- a/app/controllers/api/storage.php +++ b/app/controllers/api/storage.php @@ -50,6 +50,7 @@ use Utopia\System\System; use Utopia\Validator\ArrayList; use Utopia\Validator\Boolean; use Utopia\Validator\HexColor; +use Utopia\Validator\Nullable; use Utopia\Validator\Range; use Utopia\Validator\Text; use Utopia\Validator\WhiteList; @@ -77,7 +78,7 @@ App::post('/v1/storage/buckets') )) ->param('bucketId', '', new CustomId(), 'Unique Id. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can\'t start with a special char. Max length is 36 chars.') ->param('name', '', new Text(128), 'Bucket name') - ->param('permissions', null, new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE), 'An array of permission strings. By default, no user is granted with any permissions. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) + ->param('permissions', null, new Nullable(new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE)), 'An array of permission strings. By default, no user is granted with any permissions. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) ->param('fileSecurity', false, new Boolean(true), 'Enables configuring permissions for individual file. A user needs one of file or bucket level permissions to access a file. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) ->param('enabled', true, new Boolean(true), 'Is bucket enabled? When set to \'disabled\', users cannot access the files in this bucket but Server SDKs with and API key can still access the bucket. No files are lost when this is toggled.', true) ->param('maximumFileSize', fn (array $plan) => empty($plan['fileSize']) ? (int) System::getEnv('_APP_STORAGE_LIMIT', 0) : $plan['fileSize'] * 1000 * 1000, fn (array $plan) => new Range(1, empty($plan['fileSize']) ? (int) System::getEnv('_APP_STORAGE_LIMIT', 0) : $plan['fileSize'] * 1000 * 1000), 'Maximum file size allowed in bytes. Maximum allowed value is ' . Storage::human(System::getEnv('_APP_STORAGE_LIMIT', 0), 0) . '.', true, ['plan']) @@ -290,7 +291,7 @@ App::put('/v1/storage/buckets/:bucketId') )) ->param('bucketId', '', new UID(), 'Bucket unique ID.') ->param('name', null, new Text(128), 'Bucket name', false) - ->param('permissions', null, new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE), 'An array of permission strings. By default, the current permissions are inherited. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) + ->param('permissions', null, new Nullable(new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE)), 'An array of permission strings. By default, the current permissions are inherited. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) ->param('fileSecurity', false, new Boolean(true), 'Enables configuring permissions for individual file. A user needs one of file or bucket level permissions to access a file. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) ->param('enabled', true, new Boolean(true), 'Is bucket enabled? When set to \'disabled\', users cannot access the files in this bucket but Server SDKs with and API key can still access the bucket. No files are lost when this is toggled.', true) ->param('maximumFileSize', fn (array $plan) => empty($plan['fileSize']) ? (int) System::getEnv('_APP_STORAGE_LIMIT', 0) : $plan['fileSize'] * 1000 * 1000, fn (array $plan) => new Range(1, empty($plan['fileSize']) ? (int) System::getEnv('_APP_STORAGE_LIMIT', 0) : $plan['fileSize'] * 1000 * 1000), 'Maximum file size allowed in bytes. Maximum allowed value is ' . Storage::human(System::getEnv('_APP_STORAGE_LIMIT', 0), 0) . '.', true, ['plan']) @@ -418,7 +419,7 @@ App::post('/v1/storage/buckets/:bucketId/files') ->param('bucketId', '', new UID(), 'Storage bucket unique ID. You can create a new storage bucket using the Storage service [server integration](https://appwrite.io/docs/server/storage#createBucket).') ->param('fileId', '', new CustomId(), 'File ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can\'t start with a special char. Max length is 36 chars.') ->param('file', [], new File(), 'Binary file. Appwrite SDKs provide helpers to handle file input. [Learn about file input](https://appwrite.io/docs/products/storage/upload-download#input-file).', skipValidation: true) - ->param('permissions', null, new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE, [Database::PERMISSION_READ, Database::PERMISSION_UPDATE, Database::PERMISSION_DELETE, Database::PERMISSION_WRITE]), 'An array of permission strings. By default, only the current user is granted all permissions. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) + ->param('permissions', null, new Nullable(new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE, [Database::PERMISSION_READ, Database::PERMISSION_UPDATE, Database::PERMISSION_DELETE, Database::PERMISSION_WRITE])), 'An array of permission strings. By default, only the current user is granted all permissions. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) ->inject('request') ->inject('response') ->inject('dbForProject') @@ -1645,8 +1646,8 @@ App::put('/v1/storage/buckets/:bucketId/files/:fileId') )) ->param('bucketId', '', new UID(), 'Storage bucket unique ID. You can create a new storage bucket using the Storage service [server integration](https://appwrite.io/docs/server/storage#createBucket).') ->param('fileId', '', new UID(), 'File unique ID.') - ->param('name', null, new Text(255), 'Name of the file', true) - ->param('permissions', null, new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE, [Database::PERMISSION_READ, Database::PERMISSION_UPDATE, Database::PERMISSION_DELETE, Database::PERMISSION_WRITE]), 'An array of permission string. By default, the current permissions are inherited. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) + ->param('name', null, new Nullable(new Text(255)), 'Name of the file', true) + ->param('permissions', null, new Nullable(new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE, [Database::PERMISSION_READ, Database::PERMISSION_UPDATE, Database::PERMISSION_DELETE, Database::PERMISSION_WRITE])), 'An array of permission string. By default, the current permissions are inherited. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) ->inject('response') ->inject('dbForProject') ->inject('user') diff --git a/app/controllers/api/users.php b/app/controllers/api/users.php index 591a22705d..582a3086a3 100644 --- a/app/controllers/api/users.php +++ b/app/controllers/api/users.php @@ -55,6 +55,7 @@ use Utopia\Validator\ArrayList; use Utopia\Validator\Assoc; use Utopia\Validator\Boolean; use Utopia\Validator\Integer; +use Utopia\Validator\Nullable; use Utopia\Validator\Range; use Utopia\Validator\Text; use Utopia\Validator\WhiteList; @@ -208,8 +209,8 @@ App::post('/v1/users') ] )) ->param('userId', '', new CustomId(), 'User ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can\'t start with a special char. Max length is 36 chars.') - ->param('email', null, new Email(), 'User email.', true) - ->param('phone', null, new Phone(), 'Phone number. Format this number with a leading \'+\' and a country code, e.g., +16175551212.', true) + ->param('email', null, new Nullable(new Email()), 'User email.', true) + ->param('phone', null, new Nullable(new Phone()), 'Phone number. Format this number with a leading \'+\' and a country code, e.g., +16175551212.', true) ->param('password', '', fn ($project, $passwordsDictionary) => new PasswordDictionary($passwordsDictionary, $project->getAttribute('auths', [])['passwordDictionary'] ?? false), 'Plain text user password. Must be at least 8 chars.', true, ['project', 'passwordsDictionary']) ->param('name', '', new Text(128), 'User name. Max length: 128 chars.', true) ->inject('response') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Boolean/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Boolean/Create.php index 6c8e5dcf3d..8dfe80a390 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Boolean/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Boolean/Create.php @@ -16,6 +16,7 @@ use Utopia\Database\Validator\Key; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; class Create extends Action { @@ -62,7 +63,7 @@ class Create extends Action ->param('collectionId', '', new UID(), 'Collection ID. You can create a new table using the Database service [server integration](https://appwrite.io/docs/server/databases#databasesCreateCollection).') ->param('key', '', new Key(), 'Attribute Key.') ->param('required', null, new Boolean(), 'Is attribute required?') - ->param('default', null, new Boolean(), 'Default value for attribute when not provided. Cannot be set when attribute is required.', true) + ->param('default', null, new Nullable(new Boolean()), 'Default value for attribute when not provided. Cannot be set when attribute is required.', true) ->param('array', false, new Boolean(), 'Is attribute an array?', true) ->inject('response') ->inject('dbForProject') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Boolean/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Boolean/Update.php index d4724ea551..ddb01ff011 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Boolean/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Boolean/Update.php @@ -64,7 +64,7 @@ class Update extends Action ->param('key', '', new Key(), 'Attribute Key.') ->param('required', null, new Boolean(), 'Is attribute required?') ->param('default', null, new Nullable(new Boolean()), 'Default value for attribute when not provided. Cannot be set when attribute is required.') - ->param('newKey', null, new Key(), 'New attribute key.', true) + ->param('newKey', null, new Nullable(new Key()), 'New attribute key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Datetime/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Datetime/Update.php index cb4d0d924b..1a30a09867 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Datetime/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Datetime/Update.php @@ -65,7 +65,7 @@ class Update extends Action ->param('key', '', new Key(), 'Attribute Key.') ->param('required', null, new Boolean(), 'Is attribute required?') ->param('default', null, fn (Database $dbForProject) => new Nullable(new DatetimeValidator($dbForProject->getAdapter()->getMinDateTime(), $dbForProject->getAdapter()->getMaxDateTime())), 'Default value for attribute when not provided. Cannot be set when attribute is required.', injections: ['dbForProject']) - ->param('newKey', null, new Key(), 'New attribute key.', true) + ->param('newKey', null, new Nullable(new Key()), 'New attribute key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Email/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Email/Create.php index cbfd66e4d9..9f4c38d490 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Email/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Email/Create.php @@ -17,6 +17,7 @@ use Utopia\Database\Validator\Key; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; class Create extends Action { @@ -63,7 +64,7 @@ class Create extends Action ->param('collectionId', '', new UID(), 'Collection ID.') ->param('key', '', new Key(), 'Attribute Key.') ->param('required', null, new Boolean(), 'Is attribute required?') - ->param('default', null, new Email(), 'Default value for attribute when not provided. Cannot be set when attribute is required.', true) + ->param('default', null, new Nullable(new Email()), 'Default value for attribute when not provided. Cannot be set when attribute is required.', true) ->param('array', false, new Boolean(), 'Is attribute an array?', true) ->inject('response') ->inject('dbForProject') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Email/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Email/Update.php index 2446722f7a..59a0490e6f 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Email/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Email/Update.php @@ -65,7 +65,7 @@ class Update extends Action ->param('key', '', new Key(), 'Attribute Key.') ->param('required', null, new Boolean(), 'Is attribute required?') ->param('default', null, new Nullable(new Email()), 'Default value for attribute when not provided. Cannot be set when attribute is required.') - ->param('newKey', null, new Key(), 'New Attribute Key.', true) + ->param('newKey', null, new Nullable(new Key()), 'New Attribute Key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Enum/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Enum/Create.php index 98ed83861d..d2ccf9f972 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Enum/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Enum/Create.php @@ -18,6 +18,7 @@ use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\ArrayList; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; use Utopia\Validator\Text; class Create extends Action @@ -66,7 +67,7 @@ class Create extends Action ->param('key', '', new Key(), 'Attribute Key.') ->param('elements', [], new ArrayList(new Text(Database::LENGTH_KEY), APP_LIMIT_ARRAY_PARAMS_SIZE), 'Array of enum values.') ->param('required', null, new Boolean(), 'Is attribute required?') - ->param('default', null, new Text(0), 'Default value for attribute when not provided. Cannot be set when attribute is required.', true) + ->param('default', null, new Nullable(new Text(0)), 'Default value for attribute when not provided. Cannot be set when attribute is required.', true) ->param('array', false, new Boolean(), 'Is attribute an array?', true) ->inject('response') ->inject('dbForProject') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Enum/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Enum/Update.php index 23dc807360..560107dd38 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Enum/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Enum/Update.php @@ -67,7 +67,7 @@ class Update extends Action ->param('elements', null, new ArrayList(new Text(Database::LENGTH_KEY), APP_LIMIT_ARRAY_PARAMS_SIZE), 'Updated list of enum values.') ->param('required', null, new Boolean(), 'Is attribute required?') ->param('default', null, new Nullable(new Text(0)), 'Default value for attribute when not provided. Cannot be set when attribute is required.') - ->param('newKey', null, new Key(), 'New Attribute Key.', true) + ->param('newKey', null, new Nullable(new Key()), 'New Attribute Key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Float/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Float/Create.php index 83deb92edc..f48348c192 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Float/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Float/Create.php @@ -18,6 +18,7 @@ use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\Boolean; use Utopia\Validator\FloatValidator; +use Utopia\Validator\Nullable; use Utopia\Validator\Range; class Create extends Action @@ -65,9 +66,9 @@ class Create extends Action ->param('collectionId', '', new UID(), 'Collection ID.') ->param('key', '', new Key(), 'Attribute Key.') ->param('required', null, new Boolean(), 'Is attribute required?') - ->param('min', null, new FloatValidator(), 'Minimum value.', true) - ->param('max', null, new FloatValidator(), 'Maximum value.', true) - ->param('default', null, new FloatValidator(), 'Default value. Cannot be set when required.', true) + ->param('min', null, new Nullable(new FloatValidator()), 'Minimum value.', true) + ->param('max', null, new Nullable(new FloatValidator()), 'Maximum value.', true) + ->param('default', null, new Nullable(new FloatValidator()), 'Default value. Cannot be set when required.', true) ->param('array', false, new Boolean(), 'Is attribute an array?', true) ->inject('response') ->inject('dbForProject') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Float/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Float/Update.php index 7f295a1a94..99ac992b9e 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Float/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Float/Update.php @@ -64,10 +64,10 @@ class Update extends Action ->param('collectionId', '', new UID(), 'Collection ID.') ->param('key', '', new Key(), 'Attribute Key.') ->param('required', null, new Boolean(), 'Is attribute required?') - ->param('min', null, new FloatValidator(), 'Minimum value.', true) - ->param('max', null, new FloatValidator(), 'Maximum value.', true) + ->param('min', null, new Nullable(new FloatValidator()), 'Minimum value.', true) + ->param('max', null, new Nullable(new FloatValidator()), 'Maximum value.', true) ->param('default', null, new Nullable(new FloatValidator()), 'Default value. Cannot be set when required.') - ->param('newKey', null, new Key(), 'New Attribute Key.', true) + ->param('newKey', null, new Nullable(new Key()), 'New Attribute Key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/IP/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/IP/Create.php index 6e6264466c..af3ed99bdf 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/IP/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/IP/Create.php @@ -17,6 +17,7 @@ use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\Boolean; use Utopia\Validator\IP; +use Utopia\Validator\Nullable; class Create extends Action { @@ -63,7 +64,7 @@ class Create extends Action ->param('collectionId', '', new UID(), 'Collection ID.') ->param('key', '', new Key(), 'Attribute Key.') ->param('required', null, new Boolean(), 'Is attribute required?') - ->param('default', null, new IP(), 'Default value. Cannot be set when attribute is required.', true) + ->param('default', null, new Nullable(new IP()), 'Default value. Cannot be set when attribute is required.', true) ->param('array', false, new Boolean(), 'Is attribute an array?', true) ->inject('response') ->inject('dbForProject') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/IP/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/IP/Update.php index 6cedf10760..a757ed47d1 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/IP/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/IP/Update.php @@ -65,7 +65,7 @@ class Update extends Action ->param('key', '', new Key(), 'Attribute Key.') ->param('required', null, new Boolean(), 'Is attribute required?') ->param('default', null, new Nullable(new IP()), 'Default value. Cannot be set when attribute is required.') - ->param('newKey', null, new Key(), 'New Attribute Key.', true) + ->param('newKey', null, new Nullable(new Key()), 'New Attribute Key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Integer/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Integer/Create.php index 090d63c403..5e147c771d 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Integer/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Integer/Create.php @@ -18,6 +18,7 @@ use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\Boolean; use Utopia\Validator\Integer; +use Utopia\Validator\Nullable; use Utopia\Validator\Range; class Create extends Action @@ -65,9 +66,9 @@ class Create extends Action ->param('collectionId', '', new UID(), 'Collection ID.') ->param('key', '', new Key(), 'Attribute Key.') ->param('required', null, new Boolean(), 'Is attribute required?') - ->param('min', null, new Integer(), 'Minimum value', true) - ->param('max', null, new Integer(), 'Maximum value', true) - ->param('default', null, new Integer(), 'Default value. Cannot be set when attribute is required.', true) + ->param('min', null, new Nullable(new Integer()), 'Minimum value', true) + ->param('max', null, new Nullable(new Integer()), 'Maximum value', true) + ->param('default', null, new Nullable(new Integer()), 'Default value. Cannot be set when attribute is required.', true) ->param('array', false, new Boolean(), 'Is attribute an array?', true) ->inject('response') ->inject('dbForProject') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Integer/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Integer/Update.php index b6ae79bd8a..6d3858992b 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Integer/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Integer/Update.php @@ -64,10 +64,10 @@ class Update extends Action ->param('collectionId', '', new UID(), 'Collection ID.') ->param('key', '', new Key(), 'Attribute Key.') ->param('required', null, new Boolean(), 'Is attribute required?') - ->param('min', null, new Integer(), 'Minimum value', true) - ->param('max', null, new Integer(), 'Maximum value', true) + ->param('min', null, new Nullable(new Integer()), 'Minimum value', true) + ->param('max', null, new Nullable(new Integer()), 'Maximum value', true) ->param('default', null, new Nullable(new Integer()), 'Default value. Cannot be set when attribute is required.') - ->param('newKey', null, new Key(), 'New Attribute Key.', true) + ->param('newKey', null, new Nullable(new Key()), 'New Attribute Key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Line/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Line/Update.php index 52f04ba5bc..8ef2f96ec2 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Line/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Line/Update.php @@ -65,7 +65,7 @@ class Update extends Action ->param('key', '', new Key(), 'Attribute Key.') ->param('required', null, new Boolean(), 'Is attribute required?') ->param('default', null, new Nullable(new Spatial(Database::VAR_LINESTRING)), 'Default value for attribute when not provided, two-dimensional array of coordinate pairs, [[longitude, latitude], [longitude, latitude], …], listing the vertices of the line in order. Cannot be set when attribute is required.', true) - ->param('newKey', null, new Key(), 'New attribute key.', true) + ->param('newKey', null, new Nullable(new Key()), 'New attribute key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Point/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Point/Update.php index 73964ab461..62f35ad2a7 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Point/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Point/Update.php @@ -65,7 +65,7 @@ class Update extends Action ->param('key', '', new Key(), 'Attribute Key.') ->param('required', null, new Boolean(), 'Is attribute required?') ->param('default', null, new Nullable(new Spatial(Database::VAR_POINT)), 'Default value for attribute when not provided, array of two numbers [longitude, latitude], representing a single coordinate. Cannot be set when attribute is required.', true) - ->param('newKey', null, new Key(), 'New attribute key.', true) + ->param('newKey', null, new Nullable(new Key()), 'New attribute key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Polygon/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Polygon/Update.php index 23eb06f45d..dba83d44d5 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Polygon/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Polygon/Update.php @@ -65,7 +65,7 @@ class Update extends Action ->param('key', '', new Key(), 'Attribute Key.') ->param('required', null, new Boolean(), 'Is attribute required?') ->param('default', null, new Nullable(new Spatial(Database::VAR_POLYGON)), 'Default value for attribute when not provided, three-dimensional array where the outer array holds one or more linear rings, [[[longitude, latitude], …], …], the first ring is the exterior boundary, any additional rings are interior holes, and each ring must start and end with the same coordinate pair. Cannot be set when attribute is required.', true) - ->param('newKey', null, new Key(), 'New attribute key.', true) + ->param('newKey', null, new Nullable(new Key()), 'New attribute key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Relationship/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Relationship/Create.php index 75471b826c..6fc27a9836 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Relationship/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Relationship/Create.php @@ -18,6 +18,7 @@ use Utopia\Database\Validator\Key; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; use Utopia\Validator\WhiteList; class Create extends Action @@ -71,8 +72,8 @@ class Create extends Action Database::RELATION_ONE_TO_MANY ], true), 'Relation type') ->param('twoWay', false, new Boolean(), 'Is Two Way?', true) - ->param('key', null, new Key(), 'Attribute Key.', true) - ->param('twoWayKey', null, new Key(), 'Two Way Attribute Key.', true) + ->param('key', null, new Nullable(new Key()), 'Attribute Key.', true) + ->param('twoWayKey', null, new Nullable(new Key()), 'Two Way Attribute Key.', true) ->param('onDelete', Database::RELATION_MUTATE_RESTRICT, new WhiteList([ Database::RELATION_MUTATE_CASCADE, Database::RELATION_MUTATE_RESTRICT, diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Relationship/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Relationship/Update.php index 897cbd434f..f9f1d6f3ab 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Relationship/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/Relationship/Update.php @@ -14,6 +14,7 @@ use Utopia\Database\Database; use Utopia\Database\Validator\Key; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; +use Utopia\Validator\Nullable; use Utopia\Validator\WhiteList; class Update extends Action @@ -61,12 +62,12 @@ class Update extends Action ->param('databaseId', '', new UID(), 'Database ID.') ->param('collectionId', '', new UID(), 'Collection ID.') ->param('key', '', new Key(), 'Attribute Key.') - ->param('onDelete', null, new WhiteList([ + ->param('onDelete', null, new Nullable(new WhiteList([ Database::RELATION_MUTATE_CASCADE, Database::RELATION_MUTATE_RESTRICT, Database::RELATION_MUTATE_SET_NULL - ], true), 'Constraints option', true) - ->param('newKey', null, new Key(), 'New Attribute Key.', true) + ], true)), 'Constraints option', true) + ->param('newKey', null, new Nullable(new Key()), 'New Attribute Key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/String/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/String/Create.php index 1527c4d1d9..88cb161505 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/String/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/String/Create.php @@ -19,6 +19,7 @@ use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; use Utopia\Validator\Range; use Utopia\Validator\Text; @@ -68,7 +69,7 @@ class Create extends Action ->param('key', '', new Key(), 'Attribute Key.') ->param('size', null, new Range(1, APP_DATABASE_ATTRIBUTE_STRING_MAX_LENGTH, Validator::TYPE_INTEGER), 'Attribute size for text attributes, in number of characters.') ->param('required', null, new Boolean(), 'Is attribute required?') - ->param('default', null, new Text(0, 0), 'Default value for attribute when not provided. Cannot be set when attribute is required.', true) + ->param('default', null, new Nullable(new Text(0, 0)), 'Default value for attribute when not provided. Cannot be set when attribute is required.', true) ->param('array', false, new Boolean(), 'Is attribute an array?', true) ->param('encrypt', false, new Boolean(), 'Toggle encryption for the attribute. Encryption enhances security by not storing any plain text values in the database. However, encrypted attributes cannot be queried.', true) ->inject('response') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/String/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/String/Update.php index 8614dfb202..6687178cb1 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/String/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/String/Update.php @@ -67,8 +67,8 @@ class Update extends Action ->param('key', '', new Key(), 'Attribute Key.') ->param('required', null, new Boolean(), 'Is attribute required?') ->param('default', null, new Nullable(new Text(0, 0)), 'Default value for attribute when not provided. Cannot be set when attribute is required.') - ->param('size', null, new Range(1, APP_DATABASE_ATTRIBUTE_STRING_MAX_LENGTH, Validator::TYPE_INTEGER), 'Maximum size of the string attribute.', true) - ->param('newKey', null, new Key(), 'New Attribute Key.', true) + ->param('size', null, new Nullable(new Range(1, APP_DATABASE_ATTRIBUTE_STRING_MAX_LENGTH, Validator::TYPE_INTEGER)), 'Maximum size of the string attribute.', true) + ->param('newKey', null, new Nullable(new Key()), 'New Attribute Key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/URL/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/URL/Create.php index ce0175966b..2d3b0c6168 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/URL/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/URL/Create.php @@ -16,6 +16,7 @@ use Utopia\Database\Validator\Key; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; use Utopia\Validator\URL; class Create extends Action @@ -63,7 +64,7 @@ class Create extends Action ->param('collectionId', '', new UID(), 'Collection ID.') ->param('key', '', new Key(), 'Attribute Key.') ->param('required', null, new Boolean(), 'Is attribute required?') - ->param('default', null, new URL(), 'Default value for attribute when not provided. Cannot be set when attribute is required.', true) + ->param('default', null, new Nullable(new URL()), 'Default value for attribute when not provided. Cannot be set when attribute is required.', true) ->param('array', false, new Boolean(), 'Is attribute an array?', true) ->inject('response') ->inject('dbForProject') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/URL/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/URL/Update.php index 7ba12ad98a..ebaea9e61d 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/URL/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Attributes/URL/Update.php @@ -65,7 +65,7 @@ class Update extends Action ->param('key', '', new Key(), 'Attribute Key.') ->param('required', null, new Boolean(), 'Is attribute required?') ->param('default', null, new Nullable(new URL()), 'Default value for attribute when not provided. Cannot be set when attribute is required.') - ->param('newKey', null, new Key(), 'New Attribute Key.', true) + ->param('newKey', null, new Nullable(new Key()), 'New Attribute Key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Create.php index b810ce602f..922cc45428 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Create.php @@ -24,6 +24,7 @@ use Utopia\Database\Validator\Permissions; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; use Utopia\Validator\Text; class Create extends Action @@ -71,7 +72,7 @@ class Create extends Action ->param('databaseId', '', new UID(), 'Database ID.') ->param('collectionId', '', new CustomId(), 'Unique Id. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can\'t start with a special char. Max length is 36 chars.') ->param('name', '', new Text(128), 'Collection name. Max length: 128 chars.') - ->param('permissions', null, new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE), 'An array of permissions strings. By default, no user is granted with any permissions. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) + ->param('permissions', null, new Nullable(new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE)), 'An array of permissions strings. By default, no user is granted with any permissions. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) ->param('documentSecurity', false, new Boolean(true), 'Enables configuring permissions for individual documents. A user needs one of document or collection level permissions to access a document. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) ->param('enabled', true, new Boolean(), 'Is collection enabled? When set to \'disabled\', users cannot access the collection but Server SDKs with and API key can still read and write to the collection. No data is lost when this is toggled.', true) ->inject('response') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Attribute/Decrement.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Attribute/Decrement.php index 0b3d0e9fb4..0ff39c4500 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Attribute/Decrement.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Attribute/Decrement.php @@ -25,6 +25,7 @@ use Utopia\Database\Validator\Authorization; use Utopia\Database\Validator\Key; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; +use Utopia\Validator\Nullable; use Utopia\Validator\Numeric; class Decrement extends Action @@ -77,8 +78,8 @@ class Decrement extends Action ->param('documentId', '', new UID(), 'Document ID.') ->param('attribute', '', new Key(), 'Attribute key.') ->param('value', 1, new Numeric(), 'Value to increment the attribute by. The value must be a number.', true) - ->param('min', null, new Numeric(), 'Minimum value for the attribute. If the current value is lesser than this value, an exception will be thrown.', true) - ->param('transactionId', null, new UID(), 'Transaction ID for staging the operation.', true) + ->param('min', null, new Nullable(new Numeric()), 'Minimum value for the attribute. If the current value is lesser than this value, an exception will be thrown.', true) + ->param('transactionId', null, new Nullable(new UID()), 'Transaction ID for staging the operation.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Attribute/Increment.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Attribute/Increment.php index ef64099fa8..67fe456550 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Attribute/Increment.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Attribute/Increment.php @@ -25,6 +25,7 @@ use Utopia\Database\Validator\Authorization; use Utopia\Database\Validator\Key; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; +use Utopia\Validator\Nullable; use Utopia\Validator\Numeric; class Increment extends Action @@ -77,8 +78,8 @@ class Increment extends Action ->param('documentId', '', new UID(), 'Document ID.') ->param('attribute', '', new Key(), 'Attribute key.') ->param('value', 1, new Numeric(), 'Value to increment the attribute by. The value must be a number.', true) - ->param('max', null, new Numeric(), 'Maximum value for the attribute. If the current value is greater than this value, an error will be thrown.', true) - ->param('transactionId', null, new UID(), 'Transaction ID for staging the operation.', true) + ->param('max', null, new Nullable(new Numeric()), 'Maximum value for the attribute. If the current value is greater than this value, an error will be thrown.', true) + ->param('transactionId', null, new Nullable(new UID()), 'Transaction ID for staging the operation.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Bulk/Delete.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Bulk/Delete.php index 4b1251e016..76acff63ab 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Bulk/Delete.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Bulk/Delete.php @@ -22,6 +22,7 @@ use Utopia\Database\Query; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\ArrayList; +use Utopia\Validator\Nullable; use Utopia\Validator\Text; class Delete extends Action @@ -71,7 +72,7 @@ class Delete extends Action ->param('databaseId', '', new UID(), 'Database ID.') ->param('collectionId', '', new UID(), 'Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#databasesCreateCollection).') ->param('queries', [], new ArrayList(new Text(APP_LIMIT_ARRAY_ELEMENT_SIZE), APP_LIMIT_ARRAY_PARAMS_SIZE), 'Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https://appwrite.io/docs/queries). Maximum of ' . APP_LIMIT_ARRAY_PARAMS_SIZE . ' queries are allowed, each ' . APP_LIMIT_ARRAY_ELEMENT_SIZE . ' characters long.', true) - ->param('transactionId', null, new UID(), 'Transaction ID for staging the operation.', true) + ->param('transactionId', null, new Nullable(new UID()), 'Transaction ID for staging the operation.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForStatsUsage') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Bulk/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Bulk/Update.php index 2152534efe..b190ddde19 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Bulk/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Bulk/Update.php @@ -25,6 +25,7 @@ use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\ArrayList; use Utopia\Validator\JSON; +use Utopia\Validator\Nullable; use Utopia\Validator\Text; class Update extends Action @@ -75,7 +76,7 @@ class Update extends Action ->param('collectionId', '', new UID(), 'Collection ID.') ->param('data', [], new JSON(), 'Document data as JSON object. Include only attribute and value pairs to be updated.', true) ->param('queries', [], new ArrayList(new Text(APP_LIMIT_ARRAY_ELEMENT_SIZE), APP_LIMIT_ARRAY_PARAMS_SIZE), 'Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https://appwrite.io/docs/queries). Maximum of ' . APP_LIMIT_ARRAY_PARAMS_SIZE . ' queries are allowed, each ' . APP_LIMIT_ARRAY_ELEMENT_SIZE . ' characters long.', true) - ->param('transactionId', null, new UID(), 'Transaction ID for staging the operation.', true) + ->param('transactionId', null, new Nullable(new UID()), 'Transaction ID for staging the operation.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForStatsUsage') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Bulk/Upsert.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Bulk/Upsert.php index 6c869723a7..5a3712cc26 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Bulk/Upsert.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Bulk/Upsert.php @@ -23,6 +23,7 @@ use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\ArrayList; use Utopia\Validator\JSON; +use Utopia\Validator\Nullable; class Upsert extends Action { @@ -73,7 +74,7 @@ class Upsert extends Action ->param('databaseId', '', new UID(), 'Database ID.') ->param('collectionId', '', new UID(), 'Collection ID.') ->param('documents', [], fn (array $plan) => new ArrayList(new JSON(), $plan['databasesBatchSize'] ?? APP_LIMIT_DATABASE_BATCH), 'Array of document data as JSON objects. May contain partial documents.', false, ['plan']) - ->param('transactionId', null, new UID(), 'Transaction ID for staging the operation.', true) + ->param('transactionId', null, new Nullable(new UID()), 'Transaction ID for staging the operation.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForStatsUsage') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Create.php index 521190d3dc..09deb5f94d 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Create.php @@ -29,6 +29,7 @@ use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\ArrayList; use Utopia\Validator\JSON; +use Utopia\Validator\Nullable; class Create extends Action { @@ -119,9 +120,9 @@ class Create extends Action ->param('documentId', '', new CustomId(), 'Document ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can\'t start with a special char. Max length is 36 chars.', true) ->param('collectionId', '', new UID(), 'Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#databasesCreateCollection). Make sure to define attributes before creating documents.') ->param('data', [], new JSON(), 'Document data as JSON object.', true, example: '{"username":"walter.obrien","email":"walter.obrien@example.com","fullName":"Walter O\'Brien","age":30,"isAdmin":false}') - ->param('permissions', null, new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE, [Database::PERMISSION_READ, Database::PERMISSION_UPDATE, Database::PERMISSION_DELETE, Database::PERMISSION_WRITE]), 'An array of permissions strings. By default, only the current user is granted all permissions. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) + ->param('permissions', null, new Nullable(new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE, [Database::PERMISSION_READ, Database::PERMISSION_UPDATE, Database::PERMISSION_DELETE, Database::PERMISSION_WRITE])), 'An array of permissions strings. By default, only the current user is granted all permissions. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) ->param('documents', [], fn (array $plan) => new ArrayList(new JSON(), $plan['databasesBatchSize'] ?? APP_LIMIT_DATABASE_BATCH), 'Array of documents data as JSON objects.', true, ['plan']) - ->param('transactionId', null, new UID(), 'Transaction ID for staging the operation.', true) + ->param('transactionId', null, new Nullable(new UID()), 'Transaction ID for staging the operation.', true) ->inject('response') ->inject('dbForProject') ->inject('user') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Delete.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Delete.php index a4cef59e5f..88f22c2594 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Delete.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Delete.php @@ -74,7 +74,7 @@ class Delete extends Action ->param('databaseId', '', new UID(), 'Database ID.') ->param('collectionId', '', new UID(), 'Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#databasesCreateCollection).') ->param('documentId', '', new UID(), 'Document ID.') - ->param('transactionId', null, new UID(), 'Transaction ID for staging the operation.', true) + ->param('transactionId', null, new Nullable(new UID()), 'Transaction ID for staging the operation.', true) ->inject('requestTimestamp') ->inject('response') ->inject('dbForProject') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Get.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Get.php index 3d8cd9198c..c92a487697 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Get.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Get.php @@ -19,6 +19,7 @@ use Utopia\Database\Validator\Authorization; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\ArrayList; +use Utopia\Validator\Nullable; use Utopia\Validator\Text; class Get extends Action @@ -64,7 +65,7 @@ class Get extends Action ->param('collectionId', '', new UID(), 'Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#databasesCreateCollection).') ->param('documentId', '', new UID(), 'Document ID.') ->param('queries', [], new ArrayList(new Text(APP_LIMIT_ARRAY_ELEMENT_SIZE), APP_LIMIT_ARRAY_PARAMS_SIZE), 'Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https://appwrite.io/docs/queries). Maximum of ' . APP_LIMIT_ARRAY_PARAMS_SIZE . ' queries are allowed, each ' . APP_LIMIT_ARRAY_ELEMENT_SIZE . ' characters long.', true) - ->param('transactionId', null, new UID(), 'Transaction ID to read uncommitted changes within the transaction.', true) + ->param('transactionId', null, new Nullable(new UID()), 'Transaction ID to read uncommitted changes within the transaction.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForStatsUsage') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Update.php index ed83f3fdd3..6be9a53992 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Update.php @@ -27,6 +27,7 @@ use Utopia\Database\Validator\Permissions; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\JSON; +use Utopia\Validator\Nullable; class Update extends Action { @@ -77,8 +78,8 @@ class Update extends Action ->param('collectionId', '', new UID(), 'Collection ID.') ->param('documentId', '', new UID(), 'Document ID.') ->param('data', [], new JSON(), 'Document data as JSON object. Include only attribute and value pairs to be updated.', true) - ->param('permissions', null, new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE, [Database::PERMISSION_READ, Database::PERMISSION_UPDATE, Database::PERMISSION_DELETE, Database::PERMISSION_WRITE]), 'An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) - ->param('transactionId', null, new UID(), 'Transaction ID for staging the operation.', true) + ->param('permissions', null, new Nullable(new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE, [Database::PERMISSION_READ, Database::PERMISSION_UPDATE, Database::PERMISSION_DELETE, Database::PERMISSION_WRITE])), 'An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) + ->param('transactionId', null, new Nullable(new UID()), 'Transaction ID for staging the operation.', true) ->inject('requestTimestamp') ->inject('response') ->inject('dbForProject') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Upsert.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Upsert.php index 8d47410649..a9d8c90a9b 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Upsert.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Upsert.php @@ -28,6 +28,7 @@ use Utopia\Database\Validator\Permissions; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\JSON; +use Utopia\Validator\Nullable; class Upsert extends Action { @@ -80,8 +81,8 @@ class Upsert extends Action ->param('collectionId', '', new UID(), 'Collection ID.') ->param('documentId', '', new CustomId(), 'Document ID.') ->param('data', [], new JSON(), 'Document data as JSON object. Include all required attributes of the document to be created or updated.') - ->param('permissions', null, new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE, [Database::PERMISSION_READ, Database::PERMISSION_UPDATE, Database::PERMISSION_DELETE, Database::PERMISSION_WRITE]), 'An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) - ->param('transactionId', null, new UID(), 'Transaction ID for staging the operation.', true) + ->param('permissions', null, new Nullable(new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE, [Database::PERMISSION_READ, Database::PERMISSION_UPDATE, Database::PERMISSION_DELETE, Database::PERMISSION_WRITE])), 'An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) + ->param('transactionId', null, new Nullable(new UID()), 'Transaction ID for staging the operation.', true) ->inject('requestTimestamp') ->inject('response') ->inject('user') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/XList.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/XList.php index f159043531..630170a031 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/XList.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/XList.php @@ -23,6 +23,7 @@ use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\ArrayList; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; use Utopia\Validator\Text; class XList extends Action @@ -67,7 +68,7 @@ class XList extends Action ->param('databaseId', '', new UID(), 'Database ID.') ->param('collectionId', '', new UID(), 'Collection ID. You can create a new collection using the Database service [server integration](https://appwrite.io/docs/server/databases#databasesCreateCollection).') ->param('queries', [], new ArrayList(new Text(APP_LIMIT_ARRAY_ELEMENT_SIZE), APP_LIMIT_ARRAY_PARAMS_SIZE), 'Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https://appwrite.io/docs/queries). Maximum of ' . APP_LIMIT_ARRAY_PARAMS_SIZE . ' queries are allowed, each ' . APP_LIMIT_ARRAY_ELEMENT_SIZE . ' characters long.', true) - ->param('transactionId', null, new UID(), 'Transaction ID to read uncommitted changes within the transaction.', true) + ->param('transactionId', null, new Nullable(new UID()), 'Transaction ID to read uncommitted changes within the transaction.', true) ->param('total', true, new Boolean(true), 'When set to false, the total count returned will be 0 and will not be calculated.', true) ->inject('response') ->inject('dbForProject') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Update.php index 49870002ce..7575c9803b 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Update.php @@ -17,6 +17,7 @@ use Utopia\Database\Validator\Permissions; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; use Utopia\Validator\Text; class Update extends Action @@ -64,7 +65,7 @@ class Update extends Action ->param('databaseId', '', new UID(), 'Database ID.') ->param('collectionId', '', new UID(), 'Collection ID.') ->param('name', null, new Text(128), 'Collection name. Max length: 128 chars.') - ->param('permissions', null, new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE), 'An array of permission strings. By default, the current permissions are inherited. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) + ->param('permissions', null, new Nullable(new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE)), 'An array of permission strings. By default, the current permissions are inherited. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) ->param('documentSecurity', false, new Boolean(true), 'Enables configuring permissions for individual documents. A user needs one of document or collection level permissions to access a document. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) ->param('enabled', true, new Boolean(), 'Is collection enabled? When set to \'disabled\', users cannot access the collection but Server SDKs with and API key can still read and write to the collection. No data is lost when this is toggled.', true) ->inject('response') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Boolean/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Boolean/Create.php index 039964b2c6..d9dfc15ca8 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Boolean/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Boolean/Create.php @@ -11,6 +11,7 @@ use Utopia\Database\Validator\Key; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; class Create extends BooleanCreate { @@ -53,7 +54,7 @@ class Create extends BooleanCreate ->param('tableId', '', new UID(), 'Table ID. You can create a new table using the Database service [server integration](https://appwrite.io/docs/references/cloud/server-dart/tablesDB#createTable).') ->param('key', '', new Key(), 'Column Key.') ->param('required', null, new Boolean(), 'Is column required?') - ->param('default', null, new Boolean(), 'Default value for column when not provided. Cannot be set when column is required.', true) + ->param('default', null, new Nullable(new Boolean()), 'Default value for column when not provided. Cannot be set when column is required.', true) ->param('array', false, new Boolean(), 'Is column an array?', true) ->inject('response') ->inject('dbForProject') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Boolean/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Boolean/Update.php index 7df901a1cc..3b83e71c12 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Boolean/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Boolean/Update.php @@ -57,7 +57,7 @@ class Update extends BooleanUpdate ->param('key', '', new Key(), 'Column Key.') ->param('required', null, new Boolean(), 'Is column required?') ->param('default', null, new Nullable(new Boolean()), 'Default value for column when not provided. Cannot be set when column is required.') - ->param('newKey', null, new Key(), 'New Column Key.', true) + ->param('newKey', null, new Nullable(new Key()), 'New Column Key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Datetime/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Datetime/Update.php index 151422af75..255abf00bf 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Datetime/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Datetime/Update.php @@ -59,7 +59,7 @@ class Update extends DatetimeUpdate ->param('key', '', new Key(), 'Column Key.') ->param('required', null, new Boolean(), 'Is column required?') ->param('default', null, fn (Database $dbForProject) => new Nullable(new DatetimeValidator($dbForProject->getAdapter()->getMinDateTime(), $dbForProject->getAdapter()->getMaxDateTime())), 'Default value for column when not provided. Cannot be set when column is required.', injections: ['dbForProject']) - ->param('newKey', null, new Key(), 'New Column Key.', true) + ->param('newKey', null, new Nullable(new Key()), 'New Column Key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Email/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Email/Create.php index 3a8d492e4e..58ea459d0f 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Email/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Email/Create.php @@ -12,6 +12,7 @@ use Utopia\Database\Validator\Key; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; class Create extends EmailCreate { @@ -54,7 +55,7 @@ class Create extends EmailCreate ->param('tableId', '', new UID(), 'Table ID.') ->param('key', '', new Key(), 'Column Key.') ->param('required', null, new Boolean(), 'Is column required?') - ->param('default', null, new Email(), 'Default value for column when not provided. Cannot be set when column is required.', true) + ->param('default', null, new Nullable(new Email()), 'Default value for column when not provided. Cannot be set when column is required.', true) ->param('array', false, new Boolean(), 'Is column an array?', true) ->inject('response') ->inject('dbForProject') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Email/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Email/Update.php index 4d32489357..0105345555 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Email/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Email/Update.php @@ -58,7 +58,7 @@ class Update extends EmailUpdate ->param('key', '', new Key(), 'Column Key.') ->param('required', null, new Boolean(), 'Is column required?') ->param('default', null, new Nullable(new Email()), 'Default value for column when not provided. Cannot be set when column is required.') - ->param('newKey', null, new Key(), 'New Column Key.', true) + ->param('newKey', null, new Nullable(new Key()), 'New Column Key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Enum/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Enum/Create.php index 68dc2f8e08..8ab8019626 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Enum/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Enum/Create.php @@ -13,6 +13,7 @@ use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\ArrayList; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; use Utopia\Validator\Text; class Create extends EnumCreate @@ -57,7 +58,7 @@ class Create extends EnumCreate ->param('key', '', new Key(), 'Column Key.') ->param('elements', [], new ArrayList(new Text(Database::LENGTH_KEY), APP_LIMIT_ARRAY_PARAMS_SIZE), 'Array of enum values.') ->param('required', null, new Boolean(), 'Is column required?') - ->param('default', null, new Text(0), 'Default value for column when not provided. Cannot be set when column is required.', true) + ->param('default', null, new Nullable(new Text(0)), 'Default value for column when not provided. Cannot be set when column is required.', true) ->param('array', false, new Boolean(), 'Is column an array?', true) ->inject('response') ->inject('dbForProject') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Enum/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Enum/Update.php index 3b611a5fde..968c84c56b 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Enum/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Enum/Update.php @@ -61,7 +61,7 @@ class Update extends EnumUpdate ->param('elements', null, new ArrayList(new Text(Database::LENGTH_KEY), APP_LIMIT_ARRAY_PARAMS_SIZE), 'Updated list of enum values.') ->param('required', null, new Boolean(), 'Is column required?') ->param('default', null, new Nullable(new Text(0)), 'Default value for column when not provided. Cannot be set when column is required.') - ->param('newKey', null, new Key(), 'New Column Key.', true) + ->param('newKey', null, new Nullable(new Key()), 'New Column Key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Float/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Float/Create.php index 9fe6987cab..21e855d912 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Float/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Float/Create.php @@ -12,6 +12,7 @@ use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\Boolean; use Utopia\Validator\FloatValidator; +use Utopia\Validator\Nullable; class Create extends FloatCreate { @@ -54,9 +55,9 @@ class Create extends FloatCreate ->param('tableId', '', new UID(), 'Table ID.') ->param('key', '', new Key(), 'Column Key.') ->param('required', null, new Boolean(), 'Is column required?') - ->param('min', null, new FloatValidator(), 'Minimum value', true) - ->param('max', null, new FloatValidator(), 'Maximum value', true) - ->param('default', null, new FloatValidator(), 'Default value. Cannot be set when required.', true) + ->param('min', null, new Nullable(new FloatValidator()), 'Minimum value', true) + ->param('max', null, new Nullable(new FloatValidator()), 'Maximum value', true) + ->param('default', null, new Nullable(new FloatValidator()), 'Default value. Cannot be set when required.', true) ->param('array', false, new Boolean(), 'Is column an array?', true) ->inject('response') ->inject('dbForProject') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Float/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Float/Update.php index 023e2e834e..6a479ea266 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Float/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Float/Update.php @@ -57,10 +57,10 @@ class Update extends FloatUpdate ->param('tableId', '', new UID(), 'Table ID.') ->param('key', '', new Key(), 'Column Key.') ->param('required', null, new Boolean(), 'Is column required?') - ->param('min', null, new FloatValidator(), 'Minimum value', true) - ->param('max', null, new FloatValidator(), 'Maximum value', true) + ->param('min', null, new Nullable(new FloatValidator()), 'Minimum value', true) + ->param('max', null, new Nullable(new FloatValidator()), 'Maximum value', true) ->param('default', null, new Nullable(new FloatValidator()), 'Default value. Cannot be set when required.') - ->param('newKey', null, new Key(), 'New Column Key.', true) + ->param('newKey', null, new Nullable(new Key()), 'New Column Key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/IP/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/IP/Create.php index 81ca8da81f..08912ebb56 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/IP/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/IP/Create.php @@ -12,6 +12,7 @@ use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\Boolean; use Utopia\Validator\IP; +use Utopia\Validator\Nullable; class Create extends IPCreate { @@ -54,7 +55,7 @@ class Create extends IPCreate ->param('tableId', '', new UID(), 'Table ID.') ->param('key', '', new Key(), 'Column Key.') ->param('required', null, new Boolean(), 'Is column required?') - ->param('default', null, new IP(), 'Default value. Cannot be set when column is required.', true) + ->param('default', null, new Nullable(new IP()), 'Default value. Cannot be set when column is required.', true) ->param('array', false, new Boolean(), 'Is column an array?', true) ->inject('response') ->inject('dbForProject') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/IP/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/IP/Update.php index 0db95b0206..9df9f573a2 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/IP/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/IP/Update.php @@ -58,7 +58,7 @@ class Update extends IPUpdate ->param('key', '', new Key(), 'Column Key.') ->param('required', null, new Boolean(), 'Is column required?') ->param('default', null, new Nullable(new IP()), 'Default value. Cannot be set when column is required.') - ->param('newKey', null, new Key(), 'New Column Key.', true) + ->param('newKey', null, new Nullable(new Key()), 'New Column Key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Integer/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Integer/Create.php index dfca51a6c5..eb9230f48f 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Integer/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Integer/Create.php @@ -12,6 +12,7 @@ use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\Boolean; use Utopia\Validator\Integer; +use Utopia\Validator\Nullable; class Create extends IntegerCreate { @@ -54,9 +55,9 @@ class Create extends IntegerCreate ->param('tableId', '', new UID(), 'Table ID.') ->param('key', '', new Key(), 'Column Key.') ->param('required', null, new Boolean(), 'Is column required?') - ->param('min', null, new Integer(), 'Minimum value', true) - ->param('max', null, new Integer(), 'Maximum value', true) - ->param('default', null, new Integer(), 'Default value. Cannot be set when column is required.', true) + ->param('min', null, new Nullable(new Integer()), 'Minimum value', true) + ->param('max', null, new Nullable(new Integer()), 'Maximum value', true) + ->param('default', null, new Nullable(new Integer()), 'Default value. Cannot be set when column is required.', true) ->param('array', false, new Boolean(), 'Is column an array?', true) ->inject('response') ->inject('dbForProject') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Integer/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Integer/Update.php index a1568d069b..6c707f1655 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Integer/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Integer/Update.php @@ -57,10 +57,10 @@ class Update extends IntegerUpdate ->param('tableId', '', new UID(), 'Table ID.') ->param('key', '', new Key(), 'Column Key.') ->param('required', null, new Boolean(), 'Is column required?') - ->param('min', null, new Integer(), 'Minimum value', true) - ->param('max', null, new Integer(), 'Maximum value', true) + ->param('min', null, new Nullable(new Integer()), 'Minimum value', true) + ->param('max', null, new Nullable(new Integer()), 'Maximum value', true) ->param('default', null, new Nullable(new Integer()), 'Default value. Cannot be set when column is required.') - ->param('newKey', null, new Key(), 'New Column Key.', true) + ->param('newKey', null, new Nullable(new Key()), 'New Column Key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Line/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Line/Update.php index d3823445a2..fd7d200eb3 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Line/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Line/Update.php @@ -59,7 +59,7 @@ class Update extends LineUpdate ->param('key', '', new Key(), 'Column Key.') ->param('required', null, new Boolean(), 'Is column required?') ->param('default', null, new Nullable(new Spatial(Database::VAR_LINESTRING)), 'Default value for column when not provided, two-dimensional array of coordinate pairs, [[longitude, latitude], [longitude, latitude], …], listing the vertices of the line in order. Cannot be set when column is required.', true) - ->param('newKey', null, new Key(), 'New Column Key.', true) + ->param('newKey', null, new Nullable(new Key()), 'New Column Key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Point/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Point/Update.php index 3c855e137c..8b8dd7b66c 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Point/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Point/Update.php @@ -59,7 +59,7 @@ class Update extends PointUpdate ->param('key', '', new Key(), 'Column Key.') ->param('required', null, new Boolean(), 'Is column required?') ->param('default', null, new Nullable(new Spatial(Database::VAR_POINT)), 'Default value for column when not provided, array of two numbers [longitude, latitude], representing a single coordinate. Cannot be set when column is required.', true) - ->param('newKey', null, new Key(), 'New Column Key.', true) + ->param('newKey', null, new Nullable(new Key()), 'New Column Key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Polygon/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Polygon/Update.php index 866bbaf8b0..c49351fc59 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Polygon/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Polygon/Update.php @@ -59,7 +59,7 @@ class Update extends PolygonUpdate ->param('key', '', new Key(), 'Column Key.') ->param('required', null, new Boolean(), 'Is column required?') ->param('default', null, new Nullable(new Spatial(Database::VAR_POLYGON)), 'Default value for column when not provided, three-dimensional array where the outer array holds one or more linear rings, [[[longitude, latitude], …], …], the first ring is the exterior boundary, any additional rings are interior holes, and each ring must start and end with the same coordinate pair. Cannot be set when column is required.', true) - ->param('newKey', null, new Key(), 'New Column Key.', true) + ->param('newKey', null, new Nullable(new Key()), 'New Column Key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Relationship/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Relationship/Create.php index 0a6c76d8c5..cccc61beaa 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Relationship/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Relationship/Create.php @@ -12,6 +12,7 @@ use Utopia\Database\Validator\Key; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; use Utopia\Validator\WhiteList; class Create extends RelationshipCreate @@ -61,8 +62,8 @@ class Create extends RelationshipCreate Database::RELATION_ONE_TO_MANY ], true), 'Relation type') ->param('twoWay', false, new Boolean(), 'Is Two Way?', true) - ->param('key', null, new Key(), 'Column Key.', true) - ->param('twoWayKey', null, new Key(), 'Two Way Column Key.', true) + ->param('key', null, new Nullable(new Key()), 'Column Key.', true) + ->param('twoWayKey', null, new Nullable(new Key()), 'Two Way Column Key.', true) ->param('onDelete', Database::RELATION_MUTATE_RESTRICT, new WhiteList([ Database::RELATION_MUTATE_CASCADE, Database::RELATION_MUTATE_RESTRICT, diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Relationship/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Relationship/Update.php index b645454be1..5953d600f8 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Relationship/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/Relationship/Update.php @@ -12,6 +12,7 @@ use Utopia\Database\Database; use Utopia\Database\Validator\Key; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; +use Utopia\Validator\Nullable; use Utopia\Validator\WhiteList; class Update extends RelationshipUpdate @@ -55,12 +56,12 @@ class Update extends RelationshipUpdate ->param('databaseId', '', new UID(), 'Database ID.') ->param('tableId', '', new UID(), 'Table ID.') ->param('key', '', new Key(), 'Column Key.') - ->param('onDelete', null, new WhiteList([ + ->param('onDelete', null, new Nullable(new WhiteList([ Database::RELATION_MUTATE_CASCADE, Database::RELATION_MUTATE_RESTRICT, Database::RELATION_MUTATE_SET_NULL - ], true), 'Constraints option', true) - ->param('newKey', null, new Key(), 'New Column Key.', true) + ], true)), 'Constraints option', true) + ->param('newKey', null, new Nullable(new Key()), 'New Column Key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/String/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/String/Create.php index 6fe9fd679c..8d37c9011b 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/String/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/String/Create.php @@ -12,6 +12,7 @@ use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; use Utopia\Validator\Range; use Utopia\Validator\Text; @@ -57,7 +58,7 @@ class Create extends StringCreate ->param('key', '', new Key(), 'Column Key.') ->param('size', null, new Range(1, APP_DATABASE_ATTRIBUTE_STRING_MAX_LENGTH, Validator::TYPE_INTEGER), 'Column size for text columns, in number of characters.') ->param('required', null, new Boolean(), 'Is column required?') - ->param('default', null, new Text(0, 0), 'Default value for column when not provided. Cannot be set when column is required.', true) + ->param('default', null, new Nullable(new Text(0, 0)), 'Default value for column when not provided. Cannot be set when column is required.', true) ->param('array', false, new Boolean(), 'Is column an array?', true) ->param('encrypt', false, new Boolean(), 'Toggle encryption for the column. Encryption enhances security by not storing any plain text values in the database. However, encrypted columns cannot be queried.', true) ->inject('response') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/String/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/String/Update.php index 5ec9b78dda..43083616ba 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/String/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/String/Update.php @@ -60,8 +60,8 @@ class Update extends StringUpdate ->param('key', '', new Key(), 'Column Key.') ->param('required', null, new Boolean(), 'Is column required?') ->param('default', null, new Nullable(new Text(0, 0)), 'Default value for column when not provided. Cannot be set when column is required.') - ->param('size', null, new Range(1, APP_DATABASE_ATTRIBUTE_STRING_MAX_LENGTH, Validator::TYPE_INTEGER), 'Maximum size of the string column.', true) - ->param('newKey', null, new Key(), 'New Column Key.', true) + ->param('size', null, new Nullable(new Range(1, APP_DATABASE_ATTRIBUTE_STRING_MAX_LENGTH, Validator::TYPE_INTEGER)), 'Maximum size of the string column.', true) + ->param('newKey', null, new Nullable(new Key()), 'New Column Key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/URL/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/URL/Create.php index 99ec36b721..3fd6f1e463 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/URL/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/URL/Create.php @@ -11,6 +11,7 @@ use Utopia\Database\Validator\Key; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; use Utopia\Validator\URL; class Create extends URLCreate @@ -54,7 +55,7 @@ class Create extends URLCreate ->param('tableId', '', new UID(), 'Table ID.') ->param('key', '', new Key(), 'Column Key.') ->param('required', null, new Boolean(), 'Is column required?') - ->param('default', null, new URL(), 'Default value for column when not provided. Cannot be set when column is required.', true) + ->param('default', null, new Nullable(new URL()), 'Default value for column when not provided. Cannot be set when column is required.', true) ->param('array', false, new Boolean(), 'Is column an array?', true) ->inject('response') ->inject('dbForProject') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/URL/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/URL/Update.php index 51168b0383..64dfdfbf69 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/URL/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Columns/URL/Update.php @@ -58,7 +58,7 @@ class Update extends URLUpdate ->param('key', '', new Key(), 'Column Key.') ->param('required', null, new Boolean(), 'Is column required?') ->param('default', null, new Nullable(new URL()), 'Default value for column when not provided. Cannot be set when column is required.') - ->param('newKey', null, new Key(), 'New Column Key.', true) + ->param('newKey', null, new Nullable(new Key()), 'New Column Key.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Create.php index 4f62200d7c..68d3e772ec 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Create.php @@ -13,6 +13,7 @@ use Utopia\Database\Validator\Permissions; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; use Utopia\Validator\Text; class Create extends CollectionCreate @@ -56,7 +57,7 @@ class Create extends CollectionCreate ->param('databaseId', '', new UID(), 'Database ID.') ->param('tableId', '', new CustomId(), 'Unique Id. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can\'t start with a special char. Max length is 36 chars.') ->param('name', '', new Text(128), 'Table name. Max length: 128 chars.') - ->param('permissions', null, new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE), 'An array of permissions strings. By default, no user is granted with any permissions. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) + ->param('permissions', null, new Nullable(new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE)), 'An array of permissions strings. By default, no user is granted with any permissions. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) ->param('rowSecurity', false, new Boolean(true), '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).', true) ->param('enabled', true, new Boolean(), 'Is table enabled? When set to \'disabled\', users cannot access the table but Server SDKs with and API key can still read and write to the table. No data is lost when this is toggled.', true) ->inject('response') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Bulk/Delete.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Bulk/Delete.php index 86e9a48f63..accb0392fe 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Bulk/Delete.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Bulk/Delete.php @@ -11,6 +11,7 @@ use Appwrite\Utopia\Response as UtopiaResponse; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\ArrayList; +use Utopia\Validator\Nullable; use Utopia\Validator\Text; class Delete extends DocumentsDelete @@ -56,7 +57,7 @@ class Delete extends DocumentsDelete ->param('databaseId', '', new UID(), 'Database ID.') ->param('tableId', '', new UID(), 'Table ID. You can create a new table using the Database service [server integration](https://appwrite.io/docs/references/cloud/server-dart/tablesDB#createTable).') ->param('queries', [], new ArrayList(new Text(APP_LIMIT_ARRAY_ELEMENT_SIZE), APP_LIMIT_ARRAY_PARAMS_SIZE), 'Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https://appwrite.io/docs/queries). Maximum of ' . APP_LIMIT_ARRAY_PARAMS_SIZE . ' queries are allowed, each ' . APP_LIMIT_ARRAY_ELEMENT_SIZE . ' characters long.', true) - ->param('transactionId', null, new UID(), 'Transaction ID for staging the operation.', true) + ->param('transactionId', null, new Nullable(new UID()), 'Transaction ID for staging the operation.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForStatsUsage') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Bulk/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Bulk/Update.php index 5005ab4f41..856f17ed10 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Bulk/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Bulk/Update.php @@ -12,6 +12,7 @@ use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\ArrayList; use Utopia\Validator\JSON; +use Utopia\Validator\Nullable; use Utopia\Validator\Text; class Update extends DocumentsUpdate @@ -58,7 +59,7 @@ class Update extends DocumentsUpdate ->param('tableId', '', new UID(), 'Table ID.') ->param('data', [], new JSON(), 'Row data as JSON object. Include only column and value pairs to be updated.', true) ->param('queries', [], new ArrayList(new Text(APP_LIMIT_ARRAY_ELEMENT_SIZE), APP_LIMIT_ARRAY_PARAMS_SIZE), 'Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https://appwrite.io/docs/queries). Maximum of ' . APP_LIMIT_ARRAY_PARAMS_SIZE . ' queries are allowed, each ' . APP_LIMIT_ARRAY_ELEMENT_SIZE . ' characters long.', true) - ->param('transactionId', null, new UID(), 'Transaction ID for staging the operation.', true) + ->param('transactionId', null, new Nullable(new UID()), 'Transaction ID for staging the operation.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForStatsUsage') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Bulk/Upsert.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Bulk/Upsert.php index d0a1f08003..492af25e9f 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Bulk/Upsert.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Bulk/Upsert.php @@ -12,6 +12,7 @@ use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\ArrayList; use Utopia\Validator\JSON; +use Utopia\Validator\Nullable; class Upsert extends DocumentsUpsert { @@ -58,7 +59,7 @@ class Upsert extends DocumentsUpsert ->param('databaseId', '', new UID(), 'Database ID.') ->param('tableId', '', new UID(), 'Table ID.') ->param('rows', [], fn (array $plan) => new ArrayList(new JSON(), $plan['databasesBatchSize'] ?? APP_LIMIT_DATABASE_BATCH), 'Array of row data as JSON objects. May contain partial rows.', false, ['plan']) - ->param('transactionId', null, new UID(), 'Transaction ID for staging the operation.', true) + ->param('transactionId', null, new Nullable(new UID()), 'Transaction ID for staging the operation.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForStatsUsage') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Column/Decrement.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Column/Decrement.php index d42cf5e9eb..42f2919ce1 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Column/Decrement.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Column/Decrement.php @@ -11,6 +11,7 @@ use Appwrite\Utopia\Response as UtopiaResponse; use Utopia\Database\Validator\Key; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; +use Utopia\Validator\Nullable; use Utopia\Validator\Numeric; class Decrement extends DecrementDocumentAttribute @@ -59,8 +60,8 @@ class Decrement extends DecrementDocumentAttribute ->param('rowId', '', new UID(), 'Row ID.') ->param('column', '', new Key(), 'Column key.') ->param('value', 1, new Numeric(), 'Value to increment the column by. The value must be a number.', true) - ->param('min', null, new Numeric(), 'Minimum value for the column. If the current value is lesser than this value, an exception will be thrown.', true) - ->param('transactionId', null, new UID(), 'Transaction ID for staging the operation.', true) + ->param('min', null, new Nullable(new Numeric()), 'Minimum value for the column. If the current value is lesser than this value, an exception will be thrown.', true) + ->param('transactionId', null, new Nullable(new UID()), 'Transaction ID for staging the operation.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Column/Increment.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Column/Increment.php index c58e16c8e3..3d04d71c26 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Column/Increment.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Column/Increment.php @@ -11,6 +11,7 @@ use Appwrite\Utopia\Response as UtopiaResponse; use Utopia\Database\Validator\Key; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; +use Utopia\Validator\Nullable; use Utopia\Validator\Numeric; class Increment extends IncrementDocumentAttribute @@ -59,8 +60,8 @@ class Increment extends IncrementDocumentAttribute ->param('rowId', '', new UID(), 'Row ID.') ->param('column', '', new Key(), 'Column key.') ->param('value', 1, new Numeric(), 'Value to increment the column by. The value must be a number.', true) - ->param('max', null, new Numeric(), 'Maximum value for the column. If the current value is greater than this value, an error will be thrown.', true) - ->param('transactionId', null, new UID(), 'Transaction ID for staging the operation.', true) + ->param('max', null, new Nullable(new Numeric()), 'Maximum value for the column. If the current value is greater than this value, an error will be thrown.', true) + ->param('transactionId', null, new Nullable(new UID()), 'Transaction ID for staging the operation.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForEvents') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Create.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Create.php index bfc832f2b5..d657e5596b 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Create.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Create.php @@ -16,6 +16,7 @@ use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\ArrayList; use Utopia\Validator\JSON; +use Utopia\Validator\Nullable; class Create extends DocumentCreate { @@ -98,9 +99,9 @@ class Create extends DocumentCreate ->param('rowId', '', new CustomId(), 'Row ID. Choose a custom ID or generate a random ID with `ID.unique()`. Valid chars are a-z, A-Z, 0-9, period, hyphen, and underscore. Can\'t start with a special char. Max length is 36 chars.', true) ->param('tableId', '', new UID(), 'Table ID. You can create a new table using the Database service [server integration](https://appwrite.io/docs/references/cloud/server-dart/tablesDB#createTable). Make sure to define columns before creating rows.') ->param('data', [], new JSON(), 'Row data as JSON object.', true, example: '{"username":"walter.obrien","email":"walter.obrien@example.com","fullName":"Walter O\'Brien","age":30,"isAdmin":false}') - ->param('permissions', null, new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE, [Database::PERMISSION_READ, Database::PERMISSION_UPDATE, Database::PERMISSION_DELETE, Database::PERMISSION_WRITE]), 'An array of permissions strings. By default, only the current user is granted all permissions. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) + ->param('permissions', null, new Nullable(new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE, [Database::PERMISSION_READ, Database::PERMISSION_UPDATE, Database::PERMISSION_DELETE, Database::PERMISSION_WRITE])), 'An array of permissions strings. By default, only the current user is granted all permissions. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) ->param('rows', [], fn (array $plan) => new ArrayList(new JSON(), $plan['databasesBatchSize'] ?? APP_LIMIT_DATABASE_BATCH), 'Array of rows data as JSON objects.', true, ['plan']) - ->param('transactionId', null, new UID(), 'Transaction ID for staging the operation.', true) + ->param('transactionId', null, new Nullable(new UID()), 'Transaction ID for staging the operation.', true) ->inject('response') ->inject('dbForProject') ->inject('user') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Delete.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Delete.php index 687b1c8c11..d18a81c1af 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Delete.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Delete.php @@ -61,7 +61,7 @@ class Delete extends DocumentDelete ->param('databaseId', '', new UID(), 'Database ID.') ->param('tableId', '', new UID(), 'Table ID. You can create a new table using the Database service [server integration](https://appwrite.io/docs/references/cloud/server-dart/tablesDB#createTable).') ->param('rowId', '', new UID(), 'Row ID.') - ->param('transactionId', null, new UID(), 'Transaction ID for staging the operation.', true) + ->param('transactionId', null, new Nullable(new UID()), 'Transaction ID for staging the operation.', true) ->inject('requestTimestamp') ->inject('response') ->inject('dbForProject') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Get.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Get.php index f8b70516b6..f355ebb9e6 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Get.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Get.php @@ -11,6 +11,7 @@ use Appwrite\Utopia\Response as UtopiaResponse; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\ArrayList; +use Utopia\Validator\Nullable; use Utopia\Validator\Text; class Get extends DocumentGet @@ -52,7 +53,7 @@ class Get extends DocumentGet ->param('tableId', '', new UID(), 'Table ID. You can create a new table using the Database service [server integration](https://appwrite.io/docs/references/cloud/server-dart/tablesDB#createTable).') ->param('rowId', '', new UID(), 'Row ID.') ->param('queries', [], new ArrayList(new Text(APP_LIMIT_ARRAY_ELEMENT_SIZE), APP_LIMIT_ARRAY_PARAMS_SIZE), 'Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https://appwrite.io/docs/queries). Maximum of ' . APP_LIMIT_ARRAY_PARAMS_SIZE . ' queries are allowed, each ' . APP_LIMIT_ARRAY_ELEMENT_SIZE . ' characters long.', true) - ->param('transactionId', null, new UID(), 'Transaction ID to read uncommitted changes within the transaction.', true) + ->param('transactionId', null, new Nullable(new UID()), 'Transaction ID to read uncommitted changes within the transaction.', true) ->inject('response') ->inject('dbForProject') ->inject('queueForStatsUsage') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Update.php index cb1d5888cf..8f3786b8cf 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Update.php @@ -13,6 +13,7 @@ use Utopia\Database\Validator\Permissions; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\JSON; +use Utopia\Validator\Nullable; class Update extends DocumentUpdate { @@ -59,8 +60,8 @@ class Update extends DocumentUpdate ->param('tableId', '', new UID(), 'Table ID.') ->param('rowId', '', new UID(), 'Row ID.') ->param('data', [], new JSON(), 'Row data as JSON object. Include only columns and value pairs to be updated.', true) - ->param('permissions', null, new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE, [Database::PERMISSION_READ, Database::PERMISSION_UPDATE, Database::PERMISSION_DELETE, Database::PERMISSION_WRITE]), 'An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) - ->param('transactionId', null, new UID(), 'Transaction ID for staging the operation.', true) + ->param('permissions', null, new Nullable(new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE, [Database::PERMISSION_READ, Database::PERMISSION_UPDATE, Database::PERMISSION_DELETE, Database::PERMISSION_WRITE])), 'An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) + ->param('transactionId', null, new Nullable(new UID()), 'Transaction ID for staging the operation.', true) ->inject('requestTimestamp') ->inject('response') ->inject('dbForProject') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Upsert.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Upsert.php index 0bc373cc93..d4cd61cfdd 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Upsert.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Upsert.php @@ -13,6 +13,7 @@ use Utopia\Database\Validator\Permissions; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\JSON; +use Utopia\Validator\Nullable; class Upsert extends DocumentUpsert { @@ -61,8 +62,8 @@ class Upsert extends DocumentUpsert ->param('tableId', '', new UID(), 'Table ID.') ->param('rowId', '', new UID(), 'Row ID.') ->param('data', [], new JSON(), 'Row data as JSON object. Include all required columns of the row to be created or updated.', true) - ->param('permissions', null, new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE, [Database::PERMISSION_READ, Database::PERMISSION_UPDATE, Database::PERMISSION_DELETE, Database::PERMISSION_WRITE]), 'An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) - ->param('transactionId', null, new UID(), 'Transaction ID for staging the operation.', true) + ->param('permissions', null, new Nullable(new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE, [Database::PERMISSION_READ, Database::PERMISSION_UPDATE, Database::PERMISSION_DELETE, Database::PERMISSION_WRITE])), 'An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) + ->param('transactionId', null, new Nullable(new UID()), 'Transaction ID for staging the operation.', true) ->inject('requestTimestamp') ->inject('response') ->inject('user') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/XList.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/XList.php index b96e84b722..cd6141a6b4 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/XList.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/XList.php @@ -12,6 +12,7 @@ use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\ArrayList; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; use Utopia\Validator\Text; class XList extends DocumentXList @@ -52,7 +53,7 @@ class XList extends DocumentXList ->param('databaseId', '', new UID(), 'Database ID.') ->param('tableId', '', new UID(), 'Table ID. You can create a new table using the TablesDB service [server integration](https://appwrite.io/docs/products/databases/tables#create-table).') ->param('queries', [], new ArrayList(new Text(APP_LIMIT_ARRAY_ELEMENT_SIZE), APP_LIMIT_ARRAY_PARAMS_SIZE), 'Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https://appwrite.io/docs/queries). Maximum of ' . APP_LIMIT_ARRAY_PARAMS_SIZE . ' queries are allowed, each ' . APP_LIMIT_ARRAY_ELEMENT_SIZE . ' characters long.', true) - ->param('transactionId', null, new UID(), 'Transaction ID to read uncommitted changes within the transaction.', true) + ->param('transactionId', null, new Nullable(new UID()), 'Transaction ID to read uncommitted changes within the transaction.', true) ->param('total', true, new Boolean(true), 'When set to false, the total count returned will be 0 and will not be calculated.', true) ->inject('response') ->inject('dbForProject') diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Update.php index 8424b37a6d..a6cb611870 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Update.php @@ -12,6 +12,7 @@ use Utopia\Database\Validator\Permissions; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; use Utopia\Validator\Text; class Update extends CollectionUpdate @@ -55,7 +56,7 @@ class Update extends CollectionUpdate ->param('databaseId', '', new UID(), 'Database ID.') ->param('tableId', '', new UID(), 'Table ID.') ->param('name', null, new Text(128), 'Table name. Max length: 128 chars.') - ->param('permissions', null, new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE), 'An array of permission strings. By default, the current permissions are inherited. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) + ->param('permissions', null, new Nullable(new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE)), 'An array of permission strings. By default, the current permissions are inherited. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) ->param('rowSecurity', false, new Boolean(true), '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).', true) ->param('enabled', true, new Boolean(), 'Is table enabled? When set to \'disabled\', users cannot access the table but Server SDKs with and API key can still read and write to the table. No data is lost when this is toggled.', true) ->inject('response') diff --git a/src/Appwrite/Platform/Modules/Functions/Http/Deployments/Create.php b/src/Appwrite/Platform/Modules/Functions/Http/Deployments/Create.php index f64a960507..d53324b27f 100644 --- a/src/Appwrite/Platform/Modules/Functions/Http/Deployments/Create.php +++ b/src/Appwrite/Platform/Modules/Functions/Http/Deployments/Create.php @@ -28,6 +28,7 @@ use Utopia\Storage\Validator\Upload; use Utopia\Swoole\Request; use Utopia\System\System; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; use Utopia\Validator\Text; class Create extends Action @@ -74,8 +75,8 @@ class Create extends Action packaging: true, )) ->param('functionId', '', new UID(), 'Function ID.') - ->param('entrypoint', null, new Text(1028), 'Entrypoint File.', true) - ->param('commands', null, new Text(8192, 0), 'Build Commands.', true) + ->param('entrypoint', null, new Nullable(new Text(1028)), 'Entrypoint File.', true) + ->param('commands', null, new Nullable(new Text(8192, 0)), 'Build Commands.', true) ->param('code', [], new File(), 'Gzip file with your code package. When used with the Appwrite CLI, pass the path to your code directory, and the CLI will automatically package your code. Use a path that is within the current directory.', skipValidation: true) ->param('activate', false, new Boolean(true), 'Automatically activate the deployment when it is finished building.') ->inject('request') diff --git a/src/Appwrite/Platform/Modules/Functions/Http/Executions/Create.php b/src/Appwrite/Platform/Modules/Functions/Http/Executions/Create.php index 69af3b7d04..a699c0f097 100644 --- a/src/Appwrite/Platform/Modules/Functions/Http/Executions/Create.php +++ b/src/Appwrite/Platform/Modules/Functions/Http/Executions/Create.php @@ -36,6 +36,7 @@ use Utopia\System\System; use Utopia\Validator\AnyOf; use Utopia\Validator\Assoc; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; use Utopia\Validator\Text; use Utopia\Validator\WhiteList; @@ -81,7 +82,7 @@ class Create extends Base ->param('path', '/', new Text(2048), 'HTTP path of execution. Path can include query params. Default value is /', true) ->param('method', 'POST', new Whitelist(['GET', 'POST', 'PUT', 'PATCH', 'DELETE', 'OPTIONS', 'HEAD'], true), 'HTTP method of execution. Default value is POST.', true) ->param('headers', [], new AnyOf([new Assoc(), new Text(65535)], AnyOf::TYPE_MIXED), 'HTTP headers of execution. Defaults to empty.', true) - ->param('scheduledAt', null, new Text(100), 'Scheduled execution time in [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.', true) + ->param('scheduledAt', null, new Nullable(new Text(100)), 'Scheduled execution time in [ISO 8601](https://www.iso.org/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.', true) ->inject('response') ->inject('request') ->inject('project') diff --git a/src/Appwrite/Platform/Modules/Functions/Http/Variables/Update.php b/src/Appwrite/Platform/Modules/Functions/Http/Variables/Update.php index 639b1c74d5..95fd235e4b 100644 --- a/src/Appwrite/Platform/Modules/Functions/Http/Variables/Update.php +++ b/src/Appwrite/Platform/Modules/Functions/Http/Variables/Update.php @@ -16,6 +16,7 @@ use Utopia\Database\Validator\UID; use Utopia\Platform\Action; use Utopia\Platform\Scope\HTTP; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; use Utopia\Validator\Text; class Update extends Base @@ -56,8 +57,8 @@ class Update extends Base ->param('functionId', '', new UID(), 'Function unique ID.', false) ->param('variableId', '', new UID(), 'Variable unique ID.', false) ->param('key', null, new Text(255), 'Variable key. Max length: 255 chars.', false) - ->param('value', null, new Text(8192, 0), 'Variable value. Max length: 8192 chars.', true) - ->param('secret', null, new Boolean(), 'Secret variables can be updated or deleted, but only functions can read them during build and runtime.', true) + ->param('value', null, new Nullable(new Text(8192, 0)), 'Variable value. Max length: 8192 chars.', true) + ->param('secret', null, new Nullable(new Boolean()), 'Secret variables can be updated or deleted, but only functions can read them during build and runtime.', true) ->inject('response') ->inject('dbForProject') ->inject('dbForPlatform') diff --git a/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Create.php b/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Create.php index 4bd3afa1f5..aa622d8d84 100644 --- a/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Create.php +++ b/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Create.php @@ -29,6 +29,7 @@ use Utopia\Storage\Validator\Upload; use Utopia\Swoole\Request; use Utopia\System\System; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; use Utopia\Validator\Text; class Create extends Action @@ -71,9 +72,9 @@ class Create extends Action packaging: true, )) ->param('siteId', '', new UID(), 'Site ID.') - ->param('installCommand', null, new Text(8192, 0), 'Install Commands.', true) - ->param('buildCommand', null, new Text(8192, 0), 'Build Commands.', true) - ->param('outputDirectory', null, new Text(8192, 0), 'Output Directory.', true) + ->param('installCommand', null, new Nullable(new Text(8192, 0)), 'Install Commands.', true) + ->param('buildCommand', null, new Nullable(new Text(8192, 0)), 'Build Commands.', true) + ->param('outputDirectory', null, new Nullable(new Text(8192, 0)), 'Output Directory.', true) ->param('code', [], new File(), 'Gzip file with your code package. When used with the Appwrite CLI, pass the path to your code directory, and the CLI will automatically package your code. Use a path that is within the current directory.', skipValidation: true) ->param('activate', false, new Boolean(true), 'Automatically activate the deployment when it is finished building.') ->inject('request') diff --git a/src/Appwrite/Platform/Modules/Sites/Http/Variables/Update.php b/src/Appwrite/Platform/Modules/Sites/Http/Variables/Update.php index 3cf2e2f85f..6f4ea35eea 100644 --- a/src/Appwrite/Platform/Modules/Sites/Http/Variables/Update.php +++ b/src/Appwrite/Platform/Modules/Sites/Http/Variables/Update.php @@ -14,6 +14,7 @@ use Utopia\Database\Validator\UID; use Utopia\Platform\Action; use Utopia\Platform\Scope\HTTP; use Utopia\Validator\Boolean; +use Utopia\Validator\Nullable; use Utopia\Validator\Text; class Update extends Base @@ -54,8 +55,8 @@ class Update extends Base ->param('siteId', '', new UID(), 'Site unique ID.', false) ->param('variableId', '', new UID(), 'Variable unique ID.', false) ->param('key', null, new Text(255), 'Variable key. Max length: 255 chars.', false) - ->param('value', null, new Text(8192, 0), 'Variable value. Max length: 8192 chars.', true) - ->param('secret', null, new Boolean(), 'Secret variables can be updated or deleted, but only sites can read them during build and runtime.', true) + ->param('value', null, new Nullable(new Text(8192, 0)), 'Variable value. Max length: 8192 chars.', true) + ->param('secret', null, new Nullable(new Boolean()), 'Secret variables can be updated or deleted, but only sites can read them during build and runtime.', true) ->inject('response') ->inject('dbForProject') ->callback($this->action(...)); From 0ed4b5dbe70dcdb3bb1ddd45a16e7f976fc90272 Mon Sep 17 00:00:00 2001 From: Chirag Aggarwal Date: Mon, 10 Nov 2025 10:16:58 +0530 Subject: [PATCH 22/24] fix imports + add spec changes --- app/config/specs/open-api3-1.8.x-client.json | 78 ++- app/config/specs/open-api3-1.8.x-console.json | 582 ++++++++++++------ app/config/specs/open-api3-1.8.x-server.json | 555 +++++++++++------ app/config/specs/open-api3-latest-client.json | 78 ++- .../specs/open-api3-latest-console.json | 582 ++++++++++++------ app/config/specs/open-api3-latest-server.json | 555 +++++++++++------ app/config/specs/swagger2-1.8.x-client.json | 61 +- app/config/specs/swagger2-1.8.x-console.json | 508 ++++++++++----- app/config/specs/swagger2-1.8.x-server.json | 485 ++++++++++----- app/config/specs/swagger2-latest-client.json | 61 +- app/config/specs/swagger2-latest-console.json | 508 ++++++++++----- app/config/specs/swagger2-latest-server.json | 485 ++++++++++----- .../Collections/Documents/Delete.php | 1 + .../Http/TablesDB/Tables/Rows/Delete.php | 1 + 14 files changed, 3068 insertions(+), 1472 deletions(-) diff --git a/app/config/specs/open-api3-1.8.x-client.json b/app/config/specs/open-api3-1.8.x-client.json index dde8390820..9adb21d960 100644 --- a/app/config/specs/open-api3-1.8.x-client.json +++ b/app/config/specs/open-api3-1.8.x-client.json @@ -6313,7 +6313,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "documents": { "type": "array", @@ -6326,7 +6327,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "" + "x-example": "", + "x-nullable": true } } } @@ -6583,12 +6585,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "" + "x-example": "", + "x-nullable": true } }, "required": [ @@ -6701,12 +6705,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "" + "x-example": "", + "x-nullable": true } } } @@ -6801,7 +6807,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "" + "x-example": "", + "x-nullable": true } } } @@ -6920,12 +6927,14 @@ "min": { "type": "number", "description": "Minimum value for the attribute. If the current value is lesser than this value, an exception will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "" + "x-example": "", + "x-nullable": true } } } @@ -7044,12 +7053,14 @@ "max": { "type": "number", "description": "Maximum value for the attribute. If the current value is greater than this value, an error will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "" + "x-example": "", + "x-nullable": true } } } @@ -7251,7 +7262,8 @@ "scheduledAt": { "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", - "x-example": "" + "x-example": "", + "x-nullable": true } } } @@ -8194,7 +8206,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true } }, "required": [ @@ -8360,7 +8373,8 @@ "name": { "type": "string", "description": "Name of the file", - "x-example": "" + "x-example": "", + "x-nullable": true }, "permissions": { "type": "array", @@ -8368,7 +8382,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true } } } @@ -9500,7 +9515,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "rows": { "type": "array", @@ -9513,7 +9529,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "" + "x-example": "", + "x-nullable": true } } } @@ -9763,12 +9780,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "" + "x-example": "", + "x-nullable": true } } } @@ -9877,12 +9896,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "" + "x-example": "", + "x-nullable": true } } } @@ -9976,7 +9997,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "" + "x-example": "", + "x-nullable": true } } } @@ -10094,12 +10116,14 @@ "min": { "type": "number", "description": "Minimum value for the column. If the current value is lesser than this value, an exception will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "" + "x-example": "", + "x-nullable": true } } } @@ -10217,12 +10241,14 @@ "max": { "type": "number", "description": "Maximum value for the column. If the current value is greater than this value, an error will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "" + "x-example": "", + "x-nullable": true } } } diff --git a/app/config/specs/open-api3-1.8.x-console.json b/app/config/specs/open-api3-1.8.x-console.json index aa1e81dbeb..d7c156cdcd 100644 --- a/app/config/specs/open-api3-1.8.x-console.json +++ b/app/config/specs/open-api3-1.8.x-console.json @@ -7059,7 +7059,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "documentSecurity": { "type": "boolean", @@ -7245,7 +7246,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "documentSecurity": { "type": "boolean", @@ -7524,7 +7526,8 @@ "default": { "type": "boolean", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", - "x-example": false + "x-example": false, + "x-nullable": true }, "array": { "type": "boolean", @@ -7644,7 +7647,8 @@ "newKey": { "type": "string", "description": "New attribute key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -7869,7 +7873,8 @@ "newKey": { "type": "string", "description": "New attribute key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -7974,7 +7979,8 @@ "default": { "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -8094,7 +8100,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8207,7 +8214,8 @@ "default": { "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", - "x-example": "" + "x-example": "", + "x-nullable": true }, "array": { "type": "boolean", @@ -8336,7 +8344,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8442,17 +8451,20 @@ "min": { "type": "number", "description": "Minimum value.", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value.", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", "description": "Default value. Cannot be set when required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -8566,12 +8578,14 @@ "min": { "type": "number", "description": "Minimum value.", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value.", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", @@ -8582,7 +8596,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8687,17 +8702,20 @@ "min": { "type": "integer", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", "description": "Default value. Cannot be set when attribute is required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -8811,12 +8829,14 @@ "min": { "type": "integer", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", @@ -8827,7 +8847,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8932,7 +8953,8 @@ "default": { "type": "string", "description": "Default value. Cannot be set when attribute is required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -9052,7 +9074,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9287,7 +9310,8 @@ "newKey": { "type": "string", "description": "New attribute key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9521,7 +9545,8 @@ "newKey": { "type": "string", "description": "New attribute key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9755,7 +9780,8 @@ "newKey": { "type": "string", "description": "New attribute key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9872,12 +9898,14 @@ "key": { "type": "string", "description": "Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true }, "twoWayKey": { "type": "string", "description": "Two Way Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true }, "onDelete": { "type": "string", @@ -9999,7 +10027,8 @@ "default": { "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", - "x-example": "" + "x-example": "", + "x-nullable": true }, "array": { "type": "boolean", @@ -10125,12 +10154,14 @@ "size": { "type": "integer", "description": "Maximum size of the string attribute.", - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -10235,7 +10266,8 @@ "default": { "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", - "x-example": "https:\/\/example.com" + "x-example": "https:\/\/example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -10355,7 +10387,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -10656,12 +10689,14 @@ "setNull" ], "x-enum-name": "RelationMutate", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true }, "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -10945,7 +10980,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "documents": { "type": "array", @@ -10958,7 +10994,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "" + "x-example": "", + "x-nullable": true } } } @@ -11089,7 +11126,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "" + "x-example": "", + "x-nullable": true } }, "required": [ @@ -11195,7 +11233,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "" + "x-example": "", + "x-nullable": true } } } @@ -11293,7 +11332,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "" + "x-example": "", + "x-nullable": true } } } @@ -11550,12 +11590,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "" + "x-example": "", + "x-nullable": true } }, "required": [ @@ -11668,12 +11710,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "" + "x-example": "", + "x-nullable": true } } } @@ -11768,7 +11812,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "" + "x-example": "", + "x-nullable": true } } } @@ -11984,12 +12029,14 @@ "min": { "type": "number", "description": "Minimum value for the attribute. If the current value is lesser than this value, an exception will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "" + "x-example": "", + "x-nullable": true } } } @@ -12108,12 +12155,14 @@ "max": { "type": "number", "description": "Maximum value for the attribute. If the current value is greater than this value, an error will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "" + "x-example": "", + "x-nullable": true } } } @@ -14166,12 +14215,14 @@ "entrypoint": { "type": "string", "description": "Entrypoint File.", - "x-example": "" + "x-example": "", + "x-nullable": true }, "commands": { "type": "string", "description": "Build Commands.", - "x-example": "" + "x-example": "", + "x-nullable": true }, "code": { "type": "string", @@ -14959,7 +15010,8 @@ "scheduledAt": { "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", - "x-example": "" + "x-example": "", + "x-nullable": true } } } @@ -15488,12 +15540,14 @@ "value": { "type": "string", "description": "Variable value. Max length: 8192 chars.", - "x-example": "" + "x-example": "", + "x-nullable": true }, "secret": { "type": "boolean", "description": "Secret variables can be updated or deleted, but only functions can read them during build and runtime.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -17599,7 +17653,8 @@ "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -17685,7 +17740,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "users": { "type": "array", @@ -17693,7 +17749,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "targets": { "type": "array", @@ -17701,27 +17758,32 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "subject": { "type": "string", "description": "Email Subject.", - "x-example": "" + "x-example": "", + "x-nullable": true }, "content": { "type": "string", "description": "Email Content.", - "x-example": "" + "x-example": "", + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", - "x-example": false + "x-example": false, + "x-nullable": true }, "html": { "type": "boolean", "description": "Is content of type HTML", - "x-example": false + "x-example": false, + "x-nullable": true }, "cc": { "type": "array", @@ -17729,7 +17791,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "bcc": { "type": "array", @@ -17737,12 +17800,14 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true }, "attachments": { "type": "array", @@ -17750,7 +17815,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true } } } @@ -17855,7 +17921,8 @@ "data": { "type": "object", "description": "Additional key-value pair data for push notification.", - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "action": { "type": "string", @@ -17900,7 +17967,8 @@ "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true }, "contentAvailable": { "type": "boolean", @@ -18005,7 +18073,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "users": { "type": "array", @@ -18013,7 +18082,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "targets": { "type": "array", @@ -18021,77 +18091,92 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "title": { "type": "string", "description": "Title for push notification.", - "x-example": "" + "x-example": "<TITLE>", + "x-nullable": true }, "body": { "type": "string", "description": "Body for push notification.", - "x-example": "<BODY>" + "x-example": "<BODY>", + "x-nullable": true }, "data": { "type": "object", "description": "Additional Data for push notification.", - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "action": { "type": "string", "description": "Action for push notification.", - "x-example": "<ACTION>" + "x-example": "<ACTION>", + "x-nullable": true }, "image": { "type": "string", "description": "Image for push notification. Must be a compound bucket ID to file ID of a jpeg, png, or bmp image in Appwrite Storage. It should be formatted as <BUCKET_ID>:<FILE_ID>.", - "x-example": "<ID1:ID2>" + "x-example": "<ID1:ID2>", + "x-nullable": true }, "icon": { "type": "string", "description": "Icon for push notification. Available only for Android and Web platforms.", - "x-example": "<ICON>" + "x-example": "<ICON>", + "x-nullable": true }, "sound": { "type": "string", "description": "Sound for push notification. Available only for Android and iOS platforms.", - "x-example": "<SOUND>" + "x-example": "<SOUND>", + "x-nullable": true }, "color": { "type": "string", "description": "Color for push notification. Available only for Android platforms.", - "x-example": "<COLOR>" + "x-example": "<COLOR>", + "x-nullable": true }, "tag": { "type": "string", "description": "Tag for push notification. Available only for Android platforms.", - "x-example": "<TAG>" + "x-example": "<TAG>", + "x-nullable": true }, "badge": { "type": "integer", "description": "Badge for push notification. Available only for iOS platforms.", - "x-example": null + "x-example": null, + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", - "x-example": false + "x-example": false, + "x-nullable": true }, "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true }, "contentAvailable": { "type": "boolean", "description": "If set to true, the notification will be delivered in the background. Available only for iOS Platform.", - "x-example": false + "x-example": false, + "x-nullable": true }, "critical": { "type": "boolean", "description": "If set to true, the notification will be marked as critical. This requires the app to have the critical notification entitlement. Available only for iOS Platform.", - "x-example": false + "x-example": false, + "x-nullable": true }, "priority": { "type": "string", @@ -18102,7 +18187,8 @@ "high" ], "x-enum-name": "MessagePriority", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true } } } @@ -18275,7 +18361,8 @@ "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -18426,7 +18513,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "users": { "type": "array", @@ -18434,7 +18522,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "targets": { "type": "array", @@ -18442,22 +18531,26 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "content": { "type": "string", "description": "Email Content.", - "x-example": "<CONTENT>" + "x-example": "<CONTENT>", + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", - "x-example": false + "x-example": false, + "x-nullable": true }, "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -19002,7 +19095,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19157,7 +19251,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "authKey": { "type": "string", @@ -19182,7 +19277,8 @@ "sandbox": { "type": "boolean", "description": "Use APNS sandbox environment.", - "x-example": false + "x-example": false, + "x-nullable": true } } } @@ -19320,12 +19416,14 @@ "serviceAccountJSON": { "type": "object", "description": "FCM service account JSON.", - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19472,12 +19570,14 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "serviceAccountJSON": { "type": "object", "description": "FCM service account JSON.", - "x-example": "{}" + "x-example": "{}", + "x-nullable": true } } } @@ -19563,7 +19663,8 @@ "isEuRegion": { "type": "boolean", "description": "Set as EU region.", - "x-example": false + "x-example": false, + "x-nullable": true }, "fromName": { "type": "string", @@ -19588,7 +19689,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19685,12 +19787,14 @@ "isEuRegion": { "type": "boolean", "description": "Set as EU region.", - "x-example": false + "x-example": false, + "x-nullable": true }, "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "fromName": { "type": "string", @@ -19801,7 +19905,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19888,7 +19993,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "templateId": { "type": "string", @@ -20004,7 +20110,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20091,7 +20198,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -20217,7 +20325,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20304,7 +20413,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -20551,7 +20661,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20724,7 +20835,8 @@ "port": { "type": "integer", "description": "SMTP port.", - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "username": { "type": "string", @@ -20751,7 +20863,8 @@ "autoTLS": { "type": "boolean", "description": "Enable SMTP AutoTLS feature.", - "x-example": false + "x-example": false, + "x-nullable": true }, "mailer": { "type": "string", @@ -20781,7 +20894,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } } } @@ -20872,7 +20986,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20959,7 +21074,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "customerId": { "type": "string", @@ -21065,7 +21181,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -21152,7 +21269,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "username": { "type": "string", @@ -21258,7 +21376,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -21345,7 +21464,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "accountSid": { "type": "string", @@ -21451,7 +21571,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -21538,7 +21659,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -22146,7 +22268,8 @@ "name": { "type": "string", "description": "Topic Name.", - "x-example": "<NAME>" + "x-example": "<NAME>", + "x-nullable": true }, "subscribe": { "type": "array", @@ -22154,7 +22277,8 @@ "x-example": "[\"any\"]", "items": { "type": "string" - } + }, + "x-nullable": true } } } @@ -24227,12 +24351,14 @@ "value": { "type": "string", "description": "Variable value. Max length: 8192 chars.", - "x-example": "<VALUE>" + "x-example": "<VALUE>", + "x-nullable": true }, "secret": { "type": "boolean", "description": "Secret variables can be updated or deleted, but only projects can read them during build and runtime.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -26552,12 +26678,14 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "expire": { "type": "string", "description": "Expiration time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Use null for unlimited expiration.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -26723,12 +26851,14 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "expire": { "type": "string", "description": "Expiration time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Use null for unlimited expiration.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -26918,17 +27048,20 @@ "appId": { "type": "string", "description": "Provider app ID. Max length: 256 chars.", - "x-example": "<APP_ID>" + "x-example": "<APP_ID>", + "x-nullable": true }, "secret": { "type": "string", "description": "Provider secret key. Max length: 512 chars.", - "x-example": "<SECRET>" + "x-example": "<SECRET>", + "x-nullable": true }, "enabled": { "type": "boolean", "description": "Provider status. Set to 'false' to disable new session creation.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -31983,17 +32116,20 @@ "installCommand": { "type": "string", "description": "Install Commands.", - "x-example": "<INSTALL_COMMAND>" + "x-example": "<INSTALL_COMMAND>", + "x-nullable": true }, "buildCommand": { "type": "string", "description": "Build Commands.", - "x-example": "<BUILD_COMMAND>" + "x-example": "<BUILD_COMMAND>", + "x-nullable": true }, "outputDirectory": { "type": "string", "description": "Output Directory.", - "x-example": "<OUTPUT_DIRECTORY>" + "x-example": "<OUTPUT_DIRECTORY>", + "x-nullable": true }, "code": { "type": "string", @@ -33186,12 +33322,14 @@ "value": { "type": "string", "description": "Variable value. Max length: 8192 chars.", - "x-example": "<VALUE>" + "x-example": "<VALUE>", + "x-nullable": true }, "secret": { "type": "boolean", "description": "Secret variables can be updated or deleted, but only sites can read them during build and runtime.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -33418,7 +33556,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "fileSecurity": { "type": "boolean", @@ -33611,7 +33750,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "fileSecurity": { "type": "boolean", @@ -33902,7 +34042,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true } }, "required": [ @@ -34068,7 +34209,8 @@ "name": { "type": "string", "description": "Name of the file", - "x-example": "<NAME>" + "x-example": "<NAME>", + "x-nullable": true }, "permissions": { "type": "array", @@ -34076,7 +34218,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true } } } @@ -35761,7 +35904,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "rowSecurity": { "type": "boolean", @@ -35945,7 +36089,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "rowSecurity": { "type": "boolean", @@ -36221,7 +36366,8 @@ "default": { "type": "boolean", "description": "Default value for column when not provided. Cannot be set when column is required.", - "x-example": false + "x-example": false, + "x-nullable": true }, "array": { "type": "boolean", @@ -36340,7 +36486,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -36563,7 +36710,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -36667,7 +36815,8 @@ "default": { "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -36786,7 +36935,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -36898,7 +37048,8 @@ "default": { "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -37026,7 +37177,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -37131,17 +37283,20 @@ "min": { "type": "number", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", "description": "Default value. Cannot be set when required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -37254,12 +37409,14 @@ "min": { "type": "number", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", @@ -37270,7 +37427,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -37374,17 +37532,20 @@ "min": { "type": "integer", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", "description": "Default value. Cannot be set when column is required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -37497,12 +37658,14 @@ "min": { "type": "integer", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", @@ -37513,7 +37676,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -37617,7 +37781,8 @@ "default": { "type": "string", "description": "Default value. Cannot be set when column is required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -37736,7 +37901,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -37969,7 +38135,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -38201,7 +38368,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -38433,7 +38601,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -38549,12 +38718,14 @@ "key": { "type": "string", "description": "Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true }, "twoWayKey": { "type": "string", "description": "Two Way Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true }, "onDelete": { "type": "string", @@ -38675,7 +38846,8 @@ "default": { "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -38800,12 +38972,14 @@ "size": { "type": "integer", "description": "Maximum size of the string column.", - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -38909,7 +39083,8 @@ "default": { "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", - "x-example": "https:\/\/example.com" + "x-example": "https:\/\/example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -39028,7 +39203,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -39326,12 +39502,14 @@ "setNull" ], "x-enum-name": "RelationMutate", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true }, "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -40076,7 +40254,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "rows": { "type": "array", @@ -40089,7 +40268,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -40215,7 +40395,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -40320,7 +40501,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -40417,7 +40599,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -40667,12 +40850,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -40781,12 +40966,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -40880,7 +41067,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -41094,12 +41282,14 @@ "min": { "type": "number", "description": "Minimum value for the column. If the current value is lesser than this value, an exception will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -41217,12 +41407,14 @@ "max": { "type": "number", "description": "Maximum value for the column. If the current value is greater than this value, an error will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -43091,12 +43283,14 @@ "email": { "type": "string", "description": "User email.", - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "phone": { "type": "string", "description": "Phone number. Format this number with a leading '+' and a country code, e.g., +16175551212.", - "x-example": "+12065550100" + "x-example": "+12065550100", + "x-nullable": true }, "password": { "type": "string", diff --git a/app/config/specs/open-api3-1.8.x-server.json b/app/config/specs/open-api3-1.8.x-server.json index c3df6ef373..64e119e68a 100644 --- a/app/config/specs/open-api3-1.8.x-server.json +++ b/app/config/specs/open-api3-1.8.x-server.json @@ -6521,7 +6521,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "documentSecurity": { "type": "boolean", @@ -6709,7 +6710,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "documentSecurity": { "type": "boolean", @@ -6991,7 +6993,8 @@ "default": { "type": "boolean", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", - "x-example": false + "x-example": false, + "x-nullable": true }, "array": { "type": "boolean", @@ -7112,7 +7115,8 @@ "newKey": { "type": "string", "description": "New attribute key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -7339,7 +7343,8 @@ "newKey": { "type": "string", "description": "New attribute key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -7445,7 +7450,8 @@ "default": { "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -7566,7 +7572,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -7680,7 +7687,8 @@ "default": { "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -7810,7 +7818,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -7917,17 +7926,20 @@ "min": { "type": "number", "description": "Minimum value.", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value.", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", "description": "Default value. Cannot be set when required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -8042,12 +8054,14 @@ "min": { "type": "number", "description": "Minimum value.", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value.", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", @@ -8058,7 +8072,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8164,17 +8179,20 @@ "min": { "type": "integer", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", "description": "Default value. Cannot be set when attribute is required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -8289,12 +8307,14 @@ "min": { "type": "integer", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", @@ -8305,7 +8325,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8411,7 +8432,8 @@ "default": { "type": "string", "description": "Default value. Cannot be set when attribute is required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -8532,7 +8554,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8769,7 +8792,8 @@ "newKey": { "type": "string", "description": "New attribute key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9005,7 +9029,8 @@ "newKey": { "type": "string", "description": "New attribute key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9241,7 +9266,8 @@ "newKey": { "type": "string", "description": "New attribute key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9359,12 +9385,14 @@ "key": { "type": "string", "description": "Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true }, "twoWayKey": { "type": "string", "description": "Two Way Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true }, "onDelete": { "type": "string", @@ -9487,7 +9515,8 @@ "default": { "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -9614,12 +9643,14 @@ "size": { "type": "integer", "description": "Maximum size of the string attribute.", - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9725,7 +9756,8 @@ "default": { "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", - "x-example": "https:\/\/example.com" + "x-example": "https:\/\/example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -9846,7 +9878,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -10150,12 +10183,14 @@ "setNull" ], "x-enum-name": "RelationMutate", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true }, "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -10445,7 +10480,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "documents": { "type": "array", @@ -10458,7 +10494,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -10591,7 +10628,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -10698,7 +10736,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -10797,7 +10836,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11059,12 +11099,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -11179,12 +11221,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11281,7 +11325,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11402,12 +11447,14 @@ "min": { "type": "number", "description": "Minimum value for the attribute. If the current value is lesser than this value, an exception will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11528,12 +11575,14 @@ "max": { "type": "number", "description": "Maximum value for the attribute. If the current value is greater than this value, an error will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -12953,12 +13002,14 @@ "entrypoint": { "type": "string", "description": "Entrypoint File.", - "x-example": "<ENTRYPOINT>" + "x-example": "<ENTRYPOINT>", + "x-nullable": true }, "commands": { "type": "string", "description": "Build Commands.", - "x-example": "<COMMANDS>" + "x-example": "<COMMANDS>", + "x-nullable": true }, "code": { "type": "string", @@ -13757,7 +13808,8 @@ "scheduledAt": { "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", - "x-example": "<SCHEDULED_AT>" + "x-example": "<SCHEDULED_AT>", + "x-nullable": true } } } @@ -14211,12 +14263,14 @@ "value": { "type": "string", "description": "Variable value. Max length: 8192 chars.", - "x-example": "<VALUE>" + "x-example": "<VALUE>", + "x-nullable": true }, "secret": { "type": "boolean", "description": "Secret variables can be updated or deleted, but only functions can read them during build and runtime.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -16367,7 +16421,8 @@ "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -16454,7 +16509,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "users": { "type": "array", @@ -16462,7 +16518,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "targets": { "type": "array", @@ -16470,27 +16527,32 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "subject": { "type": "string", "description": "Email Subject.", - "x-example": "<SUBJECT>" + "x-example": "<SUBJECT>", + "x-nullable": true }, "content": { "type": "string", "description": "Email Content.", - "x-example": "<CONTENT>" + "x-example": "<CONTENT>", + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", - "x-example": false + "x-example": false, + "x-nullable": true }, "html": { "type": "boolean", "description": "Is content of type HTML", - "x-example": false + "x-example": false, + "x-nullable": true }, "cc": { "type": "array", @@ -16498,7 +16560,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "bcc": { "type": "array", @@ -16506,12 +16569,14 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true }, "attachments": { "type": "array", @@ -16519,7 +16584,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true } } } @@ -16625,7 +16691,8 @@ "data": { "type": "object", "description": "Additional key-value pair data for push notification.", - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "action": { "type": "string", @@ -16670,7 +16737,8 @@ "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true }, "contentAvailable": { "type": "boolean", @@ -16776,7 +16844,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "users": { "type": "array", @@ -16784,7 +16853,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "targets": { "type": "array", @@ -16792,77 +16862,92 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "title": { "type": "string", "description": "Title for push notification.", - "x-example": "<TITLE>" + "x-example": "<TITLE>", + "x-nullable": true }, "body": { "type": "string", "description": "Body for push notification.", - "x-example": "<BODY>" + "x-example": "<BODY>", + "x-nullable": true }, "data": { "type": "object", "description": "Additional Data for push notification.", - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "action": { "type": "string", "description": "Action for push notification.", - "x-example": "<ACTION>" + "x-example": "<ACTION>", + "x-nullable": true }, "image": { "type": "string", "description": "Image for push notification. Must be a compound bucket ID to file ID of a jpeg, png, or bmp image in Appwrite Storage. It should be formatted as <BUCKET_ID>:<FILE_ID>.", - "x-example": "<ID1:ID2>" + "x-example": "<ID1:ID2>", + "x-nullable": true }, "icon": { "type": "string", "description": "Icon for push notification. Available only for Android and Web platforms.", - "x-example": "<ICON>" + "x-example": "<ICON>", + "x-nullable": true }, "sound": { "type": "string", "description": "Sound for push notification. Available only for Android and iOS platforms.", - "x-example": "<SOUND>" + "x-example": "<SOUND>", + "x-nullable": true }, "color": { "type": "string", "description": "Color for push notification. Available only for Android platforms.", - "x-example": "<COLOR>" + "x-example": "<COLOR>", + "x-nullable": true }, "tag": { "type": "string", "description": "Tag for push notification. Available only for Android platforms.", - "x-example": "<TAG>" + "x-example": "<TAG>", + "x-nullable": true }, "badge": { "type": "integer", "description": "Badge for push notification. Available only for iOS platforms.", - "x-example": null + "x-example": null, + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", - "x-example": false + "x-example": false, + "x-nullable": true }, "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true }, "contentAvailable": { "type": "boolean", "description": "If set to true, the notification will be delivered in the background. Available only for iOS Platform.", - "x-example": false + "x-example": false, + "x-nullable": true }, "critical": { "type": "boolean", "description": "If set to true, the notification will be marked as critical. This requires the app to have the critical notification entitlement. Available only for iOS Platform.", - "x-example": false + "x-example": false, + "x-nullable": true }, "priority": { "type": "string", @@ -16873,7 +16958,8 @@ "high" ], "x-enum-name": "MessagePriority", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true } } } @@ -17049,7 +17135,8 @@ "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -17203,7 +17290,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "users": { "type": "array", @@ -17211,7 +17299,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "targets": { "type": "array", @@ -17219,22 +17308,26 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "content": { "type": "string", "description": "Email Content.", - "x-example": "<CONTENT>" + "x-example": "<CONTENT>", + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", - "x-example": false + "x-example": false, + "x-nullable": true }, "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -17787,7 +17880,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -17945,7 +18039,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "authKey": { "type": "string", @@ -17970,7 +18065,8 @@ "sandbox": { "type": "boolean", "description": "Use APNS sandbox environment.", - "x-example": false + "x-example": false, + "x-nullable": true } } } @@ -18111,12 +18207,14 @@ "serviceAccountJSON": { "type": "object", "description": "FCM service account JSON.", - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -18266,12 +18364,14 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "serviceAccountJSON": { "type": "object", "description": "FCM service account JSON.", - "x-example": "{}" + "x-example": "{}", + "x-nullable": true } } } @@ -18358,7 +18458,8 @@ "isEuRegion": { "type": "boolean", "description": "Set as EU region.", - "x-example": false + "x-example": false, + "x-nullable": true }, "fromName": { "type": "string", @@ -18383,7 +18484,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -18481,12 +18583,14 @@ "isEuRegion": { "type": "boolean", "description": "Set as EU region.", - "x-example": false + "x-example": false, + "x-nullable": true }, "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "fromName": { "type": "string", @@ -18598,7 +18702,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -18686,7 +18791,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "templateId": { "type": "string", @@ -18803,7 +18909,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -18891,7 +18998,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -19018,7 +19126,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19106,7 +19215,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -19356,7 +19466,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19532,7 +19643,8 @@ "port": { "type": "integer", "description": "SMTP port.", - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "username": { "type": "string", @@ -19559,7 +19671,8 @@ "autoTLS": { "type": "boolean", "description": "Enable SMTP AutoTLS feature.", - "x-example": false + "x-example": false, + "x-nullable": true }, "mailer": { "type": "string", @@ -19589,7 +19702,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } } } @@ -19681,7 +19795,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19769,7 +19884,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "customerId": { "type": "string", @@ -19876,7 +19992,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19964,7 +20081,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "username": { "type": "string", @@ -20071,7 +20189,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20159,7 +20278,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "accountSid": { "type": "string", @@ -20266,7 +20386,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20354,7 +20475,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -20970,7 +21092,8 @@ "name": { "type": "string", "description": "Topic Name.", - "x-example": "<NAME>" + "x-example": "<NAME>", + "x-nullable": true }, "subscribe": { "type": "array", @@ -20978,7 +21101,8 @@ "x-example": "[\"any\"]", "items": { "type": "string" - } + }, + "x-nullable": true } } } @@ -22508,17 +22632,20 @@ "installCommand": { "type": "string", "description": "Install Commands.", - "x-example": "<INSTALL_COMMAND>" + "x-example": "<INSTALL_COMMAND>", + "x-nullable": true }, "buildCommand": { "type": "string", "description": "Build Commands.", - "x-example": "<BUILD_COMMAND>" + "x-example": "<BUILD_COMMAND>", + "x-nullable": true }, "outputDirectory": { "type": "string", "description": "Output Directory.", - "x-example": "<OUTPUT_DIRECTORY>" + "x-example": "<OUTPUT_DIRECTORY>", + "x-nullable": true }, "code": { "type": "string", @@ -23643,12 +23770,14 @@ "value": { "type": "string", "description": "Variable value. Max length: 8192 chars.", - "x-example": "<VALUE>" + "x-example": "<VALUE>", + "x-nullable": true }, "secret": { "type": "boolean", "description": "Secret variables can be updated or deleted, but only sites can read them during build and runtime.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -23878,7 +24007,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "fileSecurity": { "type": "boolean", @@ -24073,7 +24203,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "fileSecurity": { "type": "boolean", @@ -24369,7 +24500,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true } }, "required": [ @@ -24539,7 +24671,8 @@ "name": { "type": "string", "description": "Name of the file", - "x-example": "<NAME>" + "x-example": "<NAME>", + "x-nullable": true }, "permissions": { "type": "array", @@ -24547,7 +24680,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true } } } @@ -26008,7 +26142,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "rowSecurity": { "type": "boolean", @@ -26194,7 +26329,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "rowSecurity": { "type": "boolean", @@ -26473,7 +26609,8 @@ "default": { "type": "boolean", "description": "Default value for column when not provided. Cannot be set when column is required.", - "x-example": false + "x-example": false, + "x-nullable": true }, "array": { "type": "boolean", @@ -26593,7 +26730,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -26818,7 +26956,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -26923,7 +27062,8 @@ "default": { "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -27043,7 +27183,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -27156,7 +27297,8 @@ "default": { "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -27285,7 +27427,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -27391,17 +27534,20 @@ "min": { "type": "number", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", "description": "Default value. Cannot be set when required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -27515,12 +27661,14 @@ "min": { "type": "number", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", @@ -27531,7 +27679,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -27636,17 +27785,20 @@ "min": { "type": "integer", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", "description": "Default value. Cannot be set when column is required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -27760,12 +27912,14 @@ "min": { "type": "integer", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", @@ -27776,7 +27930,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -27881,7 +28036,8 @@ "default": { "type": "string", "description": "Default value. Cannot be set when column is required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -28001,7 +28157,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -28236,7 +28393,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -28470,7 +28628,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -28704,7 +28863,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -28821,12 +28981,14 @@ "key": { "type": "string", "description": "Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true }, "twoWayKey": { "type": "string", "description": "Two Way Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true }, "onDelete": { "type": "string", @@ -28948,7 +29110,8 @@ "default": { "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -29074,12 +29237,14 @@ "size": { "type": "integer", "description": "Maximum size of the string column.", - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -29184,7 +29349,8 @@ "default": { "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", - "x-example": "https:\/\/example.com" + "x-example": "https:\/\/example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -29304,7 +29470,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -29605,12 +29772,14 @@ "setNull" ], "x-enum-name": "RelationMutate", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true }, "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -30279,7 +30448,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "rows": { "type": "array", @@ -30292,7 +30462,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -30420,7 +30591,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -30526,7 +30698,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -30624,7 +30797,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -30879,12 +31053,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -30995,12 +31171,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -31096,7 +31274,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -31216,12 +31395,14 @@ "min": { "type": "number", "description": "Minimum value for the column. If the current value is lesser than this value, an exception will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -31341,12 +31522,14 @@ "max": { "type": "number", "description": "Maximum value for the column. If the current value is greater than this value, an error will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -32959,12 +33142,14 @@ "email": { "type": "string", "description": "User email.", - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "phone": { "type": "string", "description": "Phone number. Format this number with a leading '+' and a country code, e.g., +16175551212.", - "x-example": "+12065550100" + "x-example": "+12065550100", + "x-nullable": true }, "password": { "type": "string", diff --git a/app/config/specs/open-api3-latest-client.json b/app/config/specs/open-api3-latest-client.json index dde8390820..9adb21d960 100644 --- a/app/config/specs/open-api3-latest-client.json +++ b/app/config/specs/open-api3-latest-client.json @@ -6313,7 +6313,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "documents": { "type": "array", @@ -6326,7 +6327,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -6583,12 +6585,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -6701,12 +6705,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -6801,7 +6807,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -6920,12 +6927,14 @@ "min": { "type": "number", "description": "Minimum value for the attribute. If the current value is lesser than this value, an exception will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -7044,12 +7053,14 @@ "max": { "type": "number", "description": "Maximum value for the attribute. If the current value is greater than this value, an error will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -7251,7 +7262,8 @@ "scheduledAt": { "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", - "x-example": "<SCHEDULED_AT>" + "x-example": "<SCHEDULED_AT>", + "x-nullable": true } } } @@ -8194,7 +8206,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true } }, "required": [ @@ -8360,7 +8373,8 @@ "name": { "type": "string", "description": "Name of the file", - "x-example": "<NAME>" + "x-example": "<NAME>", + "x-nullable": true }, "permissions": { "type": "array", @@ -8368,7 +8382,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true } } } @@ -9500,7 +9515,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "rows": { "type": "array", @@ -9513,7 +9529,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -9763,12 +9780,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -9877,12 +9896,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -9976,7 +9997,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -10094,12 +10116,14 @@ "min": { "type": "number", "description": "Minimum value for the column. If the current value is lesser than this value, an exception will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -10217,12 +10241,14 @@ "max": { "type": "number", "description": "Maximum value for the column. If the current value is greater than this value, an error will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } diff --git a/app/config/specs/open-api3-latest-console.json b/app/config/specs/open-api3-latest-console.json index aa1e81dbeb..d7c156cdcd 100644 --- a/app/config/specs/open-api3-latest-console.json +++ b/app/config/specs/open-api3-latest-console.json @@ -7059,7 +7059,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "documentSecurity": { "type": "boolean", @@ -7245,7 +7246,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "documentSecurity": { "type": "boolean", @@ -7524,7 +7526,8 @@ "default": { "type": "boolean", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", - "x-example": false + "x-example": false, + "x-nullable": true }, "array": { "type": "boolean", @@ -7644,7 +7647,8 @@ "newKey": { "type": "string", "description": "New attribute key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -7869,7 +7873,8 @@ "newKey": { "type": "string", "description": "New attribute key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -7974,7 +7979,8 @@ "default": { "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -8094,7 +8100,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8207,7 +8214,8 @@ "default": { "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -8336,7 +8344,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8442,17 +8451,20 @@ "min": { "type": "number", "description": "Minimum value.", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value.", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", "description": "Default value. Cannot be set when required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -8566,12 +8578,14 @@ "min": { "type": "number", "description": "Minimum value.", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value.", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", @@ -8582,7 +8596,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8687,17 +8702,20 @@ "min": { "type": "integer", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", "description": "Default value. Cannot be set when attribute is required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -8811,12 +8829,14 @@ "min": { "type": "integer", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", @@ -8827,7 +8847,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8932,7 +8953,8 @@ "default": { "type": "string", "description": "Default value. Cannot be set when attribute is required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -9052,7 +9074,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9287,7 +9310,8 @@ "newKey": { "type": "string", "description": "New attribute key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9521,7 +9545,8 @@ "newKey": { "type": "string", "description": "New attribute key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9755,7 +9780,8 @@ "newKey": { "type": "string", "description": "New attribute key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9872,12 +9898,14 @@ "key": { "type": "string", "description": "Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true }, "twoWayKey": { "type": "string", "description": "Two Way Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true }, "onDelete": { "type": "string", @@ -9999,7 +10027,8 @@ "default": { "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -10125,12 +10154,14 @@ "size": { "type": "integer", "description": "Maximum size of the string attribute.", - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -10235,7 +10266,8 @@ "default": { "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", - "x-example": "https:\/\/example.com" + "x-example": "https:\/\/example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -10355,7 +10387,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -10656,12 +10689,14 @@ "setNull" ], "x-enum-name": "RelationMutate", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true }, "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -10945,7 +10980,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "documents": { "type": "array", @@ -10958,7 +10994,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11089,7 +11126,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -11195,7 +11233,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11293,7 +11332,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11550,12 +11590,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -11668,12 +11710,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11768,7 +11812,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11984,12 +12029,14 @@ "min": { "type": "number", "description": "Minimum value for the attribute. If the current value is lesser than this value, an exception will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -12108,12 +12155,14 @@ "max": { "type": "number", "description": "Maximum value for the attribute. If the current value is greater than this value, an error will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -14166,12 +14215,14 @@ "entrypoint": { "type": "string", "description": "Entrypoint File.", - "x-example": "<ENTRYPOINT>" + "x-example": "<ENTRYPOINT>", + "x-nullable": true }, "commands": { "type": "string", "description": "Build Commands.", - "x-example": "<COMMANDS>" + "x-example": "<COMMANDS>", + "x-nullable": true }, "code": { "type": "string", @@ -14959,7 +15010,8 @@ "scheduledAt": { "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", - "x-example": "<SCHEDULED_AT>" + "x-example": "<SCHEDULED_AT>", + "x-nullable": true } } } @@ -15488,12 +15540,14 @@ "value": { "type": "string", "description": "Variable value. Max length: 8192 chars.", - "x-example": "<VALUE>" + "x-example": "<VALUE>", + "x-nullable": true }, "secret": { "type": "boolean", "description": "Secret variables can be updated or deleted, but only functions can read them during build and runtime.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -17599,7 +17653,8 @@ "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -17685,7 +17740,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "users": { "type": "array", @@ -17693,7 +17749,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "targets": { "type": "array", @@ -17701,27 +17758,32 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "subject": { "type": "string", "description": "Email Subject.", - "x-example": "<SUBJECT>" + "x-example": "<SUBJECT>", + "x-nullable": true }, "content": { "type": "string", "description": "Email Content.", - "x-example": "<CONTENT>" + "x-example": "<CONTENT>", + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", - "x-example": false + "x-example": false, + "x-nullable": true }, "html": { "type": "boolean", "description": "Is content of type HTML", - "x-example": false + "x-example": false, + "x-nullable": true }, "cc": { "type": "array", @@ -17729,7 +17791,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "bcc": { "type": "array", @@ -17737,12 +17800,14 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true }, "attachments": { "type": "array", @@ -17750,7 +17815,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true } } } @@ -17855,7 +17921,8 @@ "data": { "type": "object", "description": "Additional key-value pair data for push notification.", - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "action": { "type": "string", @@ -17900,7 +17967,8 @@ "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true }, "contentAvailable": { "type": "boolean", @@ -18005,7 +18073,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "users": { "type": "array", @@ -18013,7 +18082,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "targets": { "type": "array", @@ -18021,77 +18091,92 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "title": { "type": "string", "description": "Title for push notification.", - "x-example": "<TITLE>" + "x-example": "<TITLE>", + "x-nullable": true }, "body": { "type": "string", "description": "Body for push notification.", - "x-example": "<BODY>" + "x-example": "<BODY>", + "x-nullable": true }, "data": { "type": "object", "description": "Additional Data for push notification.", - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "action": { "type": "string", "description": "Action for push notification.", - "x-example": "<ACTION>" + "x-example": "<ACTION>", + "x-nullable": true }, "image": { "type": "string", "description": "Image for push notification. Must be a compound bucket ID to file ID of a jpeg, png, or bmp image in Appwrite Storage. It should be formatted as <BUCKET_ID>:<FILE_ID>.", - "x-example": "<ID1:ID2>" + "x-example": "<ID1:ID2>", + "x-nullable": true }, "icon": { "type": "string", "description": "Icon for push notification. Available only for Android and Web platforms.", - "x-example": "<ICON>" + "x-example": "<ICON>", + "x-nullable": true }, "sound": { "type": "string", "description": "Sound for push notification. Available only for Android and iOS platforms.", - "x-example": "<SOUND>" + "x-example": "<SOUND>", + "x-nullable": true }, "color": { "type": "string", "description": "Color for push notification. Available only for Android platforms.", - "x-example": "<COLOR>" + "x-example": "<COLOR>", + "x-nullable": true }, "tag": { "type": "string", "description": "Tag for push notification. Available only for Android platforms.", - "x-example": "<TAG>" + "x-example": "<TAG>", + "x-nullable": true }, "badge": { "type": "integer", "description": "Badge for push notification. Available only for iOS platforms.", - "x-example": null + "x-example": null, + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", - "x-example": false + "x-example": false, + "x-nullable": true }, "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true }, "contentAvailable": { "type": "boolean", "description": "If set to true, the notification will be delivered in the background. Available only for iOS Platform.", - "x-example": false + "x-example": false, + "x-nullable": true }, "critical": { "type": "boolean", "description": "If set to true, the notification will be marked as critical. This requires the app to have the critical notification entitlement. Available only for iOS Platform.", - "x-example": false + "x-example": false, + "x-nullable": true }, "priority": { "type": "string", @@ -18102,7 +18187,8 @@ "high" ], "x-enum-name": "MessagePriority", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true } } } @@ -18275,7 +18361,8 @@ "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -18426,7 +18513,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "users": { "type": "array", @@ -18434,7 +18522,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "targets": { "type": "array", @@ -18442,22 +18531,26 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "content": { "type": "string", "description": "Email Content.", - "x-example": "<CONTENT>" + "x-example": "<CONTENT>", + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", - "x-example": false + "x-example": false, + "x-nullable": true }, "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -19002,7 +19095,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19157,7 +19251,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "authKey": { "type": "string", @@ -19182,7 +19277,8 @@ "sandbox": { "type": "boolean", "description": "Use APNS sandbox environment.", - "x-example": false + "x-example": false, + "x-nullable": true } } } @@ -19320,12 +19416,14 @@ "serviceAccountJSON": { "type": "object", "description": "FCM service account JSON.", - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19472,12 +19570,14 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "serviceAccountJSON": { "type": "object", "description": "FCM service account JSON.", - "x-example": "{}" + "x-example": "{}", + "x-nullable": true } } } @@ -19563,7 +19663,8 @@ "isEuRegion": { "type": "boolean", "description": "Set as EU region.", - "x-example": false + "x-example": false, + "x-nullable": true }, "fromName": { "type": "string", @@ -19588,7 +19689,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19685,12 +19787,14 @@ "isEuRegion": { "type": "boolean", "description": "Set as EU region.", - "x-example": false + "x-example": false, + "x-nullable": true }, "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "fromName": { "type": "string", @@ -19801,7 +19905,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19888,7 +19993,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "templateId": { "type": "string", @@ -20004,7 +20110,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20091,7 +20198,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -20217,7 +20325,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20304,7 +20413,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -20551,7 +20661,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20724,7 +20835,8 @@ "port": { "type": "integer", "description": "SMTP port.", - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "username": { "type": "string", @@ -20751,7 +20863,8 @@ "autoTLS": { "type": "boolean", "description": "Enable SMTP AutoTLS feature.", - "x-example": false + "x-example": false, + "x-nullable": true }, "mailer": { "type": "string", @@ -20781,7 +20894,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } } } @@ -20872,7 +20986,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20959,7 +21074,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "customerId": { "type": "string", @@ -21065,7 +21181,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -21152,7 +21269,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "username": { "type": "string", @@ -21258,7 +21376,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -21345,7 +21464,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "accountSid": { "type": "string", @@ -21451,7 +21571,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -21538,7 +21659,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -22146,7 +22268,8 @@ "name": { "type": "string", "description": "Topic Name.", - "x-example": "<NAME>" + "x-example": "<NAME>", + "x-nullable": true }, "subscribe": { "type": "array", @@ -22154,7 +22277,8 @@ "x-example": "[\"any\"]", "items": { "type": "string" - } + }, + "x-nullable": true } } } @@ -24227,12 +24351,14 @@ "value": { "type": "string", "description": "Variable value. Max length: 8192 chars.", - "x-example": "<VALUE>" + "x-example": "<VALUE>", + "x-nullable": true }, "secret": { "type": "boolean", "description": "Secret variables can be updated or deleted, but only projects can read them during build and runtime.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -26552,12 +26678,14 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "expire": { "type": "string", "description": "Expiration time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Use null for unlimited expiration.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -26723,12 +26851,14 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "expire": { "type": "string", "description": "Expiration time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Use null for unlimited expiration.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -26918,17 +27048,20 @@ "appId": { "type": "string", "description": "Provider app ID. Max length: 256 chars.", - "x-example": "<APP_ID>" + "x-example": "<APP_ID>", + "x-nullable": true }, "secret": { "type": "string", "description": "Provider secret key. Max length: 512 chars.", - "x-example": "<SECRET>" + "x-example": "<SECRET>", + "x-nullable": true }, "enabled": { "type": "boolean", "description": "Provider status. Set to 'false' to disable new session creation.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -31983,17 +32116,20 @@ "installCommand": { "type": "string", "description": "Install Commands.", - "x-example": "<INSTALL_COMMAND>" + "x-example": "<INSTALL_COMMAND>", + "x-nullable": true }, "buildCommand": { "type": "string", "description": "Build Commands.", - "x-example": "<BUILD_COMMAND>" + "x-example": "<BUILD_COMMAND>", + "x-nullable": true }, "outputDirectory": { "type": "string", "description": "Output Directory.", - "x-example": "<OUTPUT_DIRECTORY>" + "x-example": "<OUTPUT_DIRECTORY>", + "x-nullable": true }, "code": { "type": "string", @@ -33186,12 +33322,14 @@ "value": { "type": "string", "description": "Variable value. Max length: 8192 chars.", - "x-example": "<VALUE>" + "x-example": "<VALUE>", + "x-nullable": true }, "secret": { "type": "boolean", "description": "Secret variables can be updated or deleted, but only sites can read them during build and runtime.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -33418,7 +33556,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "fileSecurity": { "type": "boolean", @@ -33611,7 +33750,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "fileSecurity": { "type": "boolean", @@ -33902,7 +34042,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true } }, "required": [ @@ -34068,7 +34209,8 @@ "name": { "type": "string", "description": "Name of the file", - "x-example": "<NAME>" + "x-example": "<NAME>", + "x-nullable": true }, "permissions": { "type": "array", @@ -34076,7 +34218,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true } } } @@ -35761,7 +35904,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "rowSecurity": { "type": "boolean", @@ -35945,7 +36089,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "rowSecurity": { "type": "boolean", @@ -36221,7 +36366,8 @@ "default": { "type": "boolean", "description": "Default value for column when not provided. Cannot be set when column is required.", - "x-example": false + "x-example": false, + "x-nullable": true }, "array": { "type": "boolean", @@ -36340,7 +36486,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -36563,7 +36710,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -36667,7 +36815,8 @@ "default": { "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -36786,7 +36935,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -36898,7 +37048,8 @@ "default": { "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -37026,7 +37177,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -37131,17 +37283,20 @@ "min": { "type": "number", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", "description": "Default value. Cannot be set when required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -37254,12 +37409,14 @@ "min": { "type": "number", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", @@ -37270,7 +37427,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -37374,17 +37532,20 @@ "min": { "type": "integer", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", "description": "Default value. Cannot be set when column is required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -37497,12 +37658,14 @@ "min": { "type": "integer", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", @@ -37513,7 +37676,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -37617,7 +37781,8 @@ "default": { "type": "string", "description": "Default value. Cannot be set when column is required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -37736,7 +37901,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -37969,7 +38135,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -38201,7 +38368,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -38433,7 +38601,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -38549,12 +38718,14 @@ "key": { "type": "string", "description": "Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true }, "twoWayKey": { "type": "string", "description": "Two Way Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true }, "onDelete": { "type": "string", @@ -38675,7 +38846,8 @@ "default": { "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -38800,12 +38972,14 @@ "size": { "type": "integer", "description": "Maximum size of the string column.", - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -38909,7 +39083,8 @@ "default": { "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", - "x-example": "https:\/\/example.com" + "x-example": "https:\/\/example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -39028,7 +39203,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -39326,12 +39502,14 @@ "setNull" ], "x-enum-name": "RelationMutate", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true }, "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -40076,7 +40254,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "rows": { "type": "array", @@ -40089,7 +40268,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -40215,7 +40395,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -40320,7 +40501,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -40417,7 +40599,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -40667,12 +40850,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -40781,12 +40966,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -40880,7 +41067,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -41094,12 +41282,14 @@ "min": { "type": "number", "description": "Minimum value for the column. If the current value is lesser than this value, an exception will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -41217,12 +41407,14 @@ "max": { "type": "number", "description": "Maximum value for the column. If the current value is greater than this value, an error will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -43091,12 +43283,14 @@ "email": { "type": "string", "description": "User email.", - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "phone": { "type": "string", "description": "Phone number. Format this number with a leading '+' and a country code, e.g., +16175551212.", - "x-example": "+12065550100" + "x-example": "+12065550100", + "x-nullable": true }, "password": { "type": "string", diff --git a/app/config/specs/open-api3-latest-server.json b/app/config/specs/open-api3-latest-server.json index c3df6ef373..64e119e68a 100644 --- a/app/config/specs/open-api3-latest-server.json +++ b/app/config/specs/open-api3-latest-server.json @@ -6521,7 +6521,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "documentSecurity": { "type": "boolean", @@ -6709,7 +6710,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "documentSecurity": { "type": "boolean", @@ -6991,7 +6993,8 @@ "default": { "type": "boolean", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", - "x-example": false + "x-example": false, + "x-nullable": true }, "array": { "type": "boolean", @@ -7112,7 +7115,8 @@ "newKey": { "type": "string", "description": "New attribute key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -7339,7 +7343,8 @@ "newKey": { "type": "string", "description": "New attribute key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -7445,7 +7450,8 @@ "default": { "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -7566,7 +7572,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -7680,7 +7687,8 @@ "default": { "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -7810,7 +7818,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -7917,17 +7926,20 @@ "min": { "type": "number", "description": "Minimum value.", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value.", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", "description": "Default value. Cannot be set when required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -8042,12 +8054,14 @@ "min": { "type": "number", "description": "Minimum value.", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value.", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", @@ -8058,7 +8072,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8164,17 +8179,20 @@ "min": { "type": "integer", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", "description": "Default value. Cannot be set when attribute is required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -8289,12 +8307,14 @@ "min": { "type": "integer", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", @@ -8305,7 +8325,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8411,7 +8432,8 @@ "default": { "type": "string", "description": "Default value. Cannot be set when attribute is required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -8532,7 +8554,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8769,7 +8792,8 @@ "newKey": { "type": "string", "description": "New attribute key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9005,7 +9029,8 @@ "newKey": { "type": "string", "description": "New attribute key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9241,7 +9266,8 @@ "newKey": { "type": "string", "description": "New attribute key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9359,12 +9385,14 @@ "key": { "type": "string", "description": "Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true }, "twoWayKey": { "type": "string", "description": "Two Way Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true }, "onDelete": { "type": "string", @@ -9487,7 +9515,8 @@ "default": { "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -9614,12 +9643,14 @@ "size": { "type": "integer", "description": "Maximum size of the string attribute.", - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9725,7 +9756,8 @@ "default": { "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", - "x-example": "https:\/\/example.com" + "x-example": "https:\/\/example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -9846,7 +9878,8 @@ "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -10150,12 +10183,14 @@ "setNull" ], "x-enum-name": "RelationMutate", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true }, "newKey": { "type": "string", "description": "New Attribute Key.", - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -10445,7 +10480,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "documents": { "type": "array", @@ -10458,7 +10494,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -10591,7 +10628,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -10698,7 +10736,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -10797,7 +10836,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11059,12 +11099,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -11179,12 +11221,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11281,7 +11325,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11402,12 +11447,14 @@ "min": { "type": "number", "description": "Minimum value for the attribute. If the current value is lesser than this value, an exception will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11528,12 +11575,14 @@ "max": { "type": "number", "description": "Maximum value for the attribute. If the current value is greater than this value, an error will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -12953,12 +13002,14 @@ "entrypoint": { "type": "string", "description": "Entrypoint File.", - "x-example": "<ENTRYPOINT>" + "x-example": "<ENTRYPOINT>", + "x-nullable": true }, "commands": { "type": "string", "description": "Build Commands.", - "x-example": "<COMMANDS>" + "x-example": "<COMMANDS>", + "x-nullable": true }, "code": { "type": "string", @@ -13757,7 +13808,8 @@ "scheduledAt": { "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", - "x-example": "<SCHEDULED_AT>" + "x-example": "<SCHEDULED_AT>", + "x-nullable": true } } } @@ -14211,12 +14263,14 @@ "value": { "type": "string", "description": "Variable value. Max length: 8192 chars.", - "x-example": "<VALUE>" + "x-example": "<VALUE>", + "x-nullable": true }, "secret": { "type": "boolean", "description": "Secret variables can be updated or deleted, but only functions can read them during build and runtime.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -16367,7 +16421,8 @@ "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -16454,7 +16509,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "users": { "type": "array", @@ -16462,7 +16518,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "targets": { "type": "array", @@ -16470,27 +16527,32 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "subject": { "type": "string", "description": "Email Subject.", - "x-example": "<SUBJECT>" + "x-example": "<SUBJECT>", + "x-nullable": true }, "content": { "type": "string", "description": "Email Content.", - "x-example": "<CONTENT>" + "x-example": "<CONTENT>", + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", - "x-example": false + "x-example": false, + "x-nullable": true }, "html": { "type": "boolean", "description": "Is content of type HTML", - "x-example": false + "x-example": false, + "x-nullable": true }, "cc": { "type": "array", @@ -16498,7 +16560,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "bcc": { "type": "array", @@ -16506,12 +16569,14 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true }, "attachments": { "type": "array", @@ -16519,7 +16584,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true } } } @@ -16625,7 +16691,8 @@ "data": { "type": "object", "description": "Additional key-value pair data for push notification.", - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "action": { "type": "string", @@ -16670,7 +16737,8 @@ "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true }, "contentAvailable": { "type": "boolean", @@ -16776,7 +16844,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "users": { "type": "array", @@ -16784,7 +16853,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "targets": { "type": "array", @@ -16792,77 +16862,92 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "title": { "type": "string", "description": "Title for push notification.", - "x-example": "<TITLE>" + "x-example": "<TITLE>", + "x-nullable": true }, "body": { "type": "string", "description": "Body for push notification.", - "x-example": "<BODY>" + "x-example": "<BODY>", + "x-nullable": true }, "data": { "type": "object", "description": "Additional Data for push notification.", - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "action": { "type": "string", "description": "Action for push notification.", - "x-example": "<ACTION>" + "x-example": "<ACTION>", + "x-nullable": true }, "image": { "type": "string", "description": "Image for push notification. Must be a compound bucket ID to file ID of a jpeg, png, or bmp image in Appwrite Storage. It should be formatted as <BUCKET_ID>:<FILE_ID>.", - "x-example": "<ID1:ID2>" + "x-example": "<ID1:ID2>", + "x-nullable": true }, "icon": { "type": "string", "description": "Icon for push notification. Available only for Android and Web platforms.", - "x-example": "<ICON>" + "x-example": "<ICON>", + "x-nullable": true }, "sound": { "type": "string", "description": "Sound for push notification. Available only for Android and iOS platforms.", - "x-example": "<SOUND>" + "x-example": "<SOUND>", + "x-nullable": true }, "color": { "type": "string", "description": "Color for push notification. Available only for Android platforms.", - "x-example": "<COLOR>" + "x-example": "<COLOR>", + "x-nullable": true }, "tag": { "type": "string", "description": "Tag for push notification. Available only for Android platforms.", - "x-example": "<TAG>" + "x-example": "<TAG>", + "x-nullable": true }, "badge": { "type": "integer", "description": "Badge for push notification. Available only for iOS platforms.", - "x-example": null + "x-example": null, + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", - "x-example": false + "x-example": false, + "x-nullable": true }, "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true }, "contentAvailable": { "type": "boolean", "description": "If set to true, the notification will be delivered in the background. Available only for iOS Platform.", - "x-example": false + "x-example": false, + "x-nullable": true }, "critical": { "type": "boolean", "description": "If set to true, the notification will be marked as critical. This requires the app to have the critical notification entitlement. Available only for iOS Platform.", - "x-example": false + "x-example": false, + "x-nullable": true }, "priority": { "type": "string", @@ -16873,7 +16958,8 @@ "high" ], "x-enum-name": "MessagePriority", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true } } } @@ -17049,7 +17135,8 @@ "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -17203,7 +17290,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "users": { "type": "array", @@ -17211,7 +17299,8 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "targets": { "type": "array", @@ -17219,22 +17308,26 @@ "x-example": null, "items": { "type": "string" - } + }, + "x-nullable": true }, "content": { "type": "string", "description": "Email Content.", - "x-example": "<CONTENT>" + "x-example": "<CONTENT>", + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", - "x-example": false + "x-example": false, + "x-nullable": true }, "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -17787,7 +17880,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -17945,7 +18039,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "authKey": { "type": "string", @@ -17970,7 +18065,8 @@ "sandbox": { "type": "boolean", "description": "Use APNS sandbox environment.", - "x-example": false + "x-example": false, + "x-nullable": true } } } @@ -18111,12 +18207,14 @@ "serviceAccountJSON": { "type": "object", "description": "FCM service account JSON.", - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -18266,12 +18364,14 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "serviceAccountJSON": { "type": "object", "description": "FCM service account JSON.", - "x-example": "{}" + "x-example": "{}", + "x-nullable": true } } } @@ -18358,7 +18458,8 @@ "isEuRegion": { "type": "boolean", "description": "Set as EU region.", - "x-example": false + "x-example": false, + "x-nullable": true }, "fromName": { "type": "string", @@ -18383,7 +18484,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -18481,12 +18583,14 @@ "isEuRegion": { "type": "boolean", "description": "Set as EU region.", - "x-example": false + "x-example": false, + "x-nullable": true }, "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "fromName": { "type": "string", @@ -18598,7 +18702,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -18686,7 +18791,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "templateId": { "type": "string", @@ -18803,7 +18909,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -18891,7 +18998,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -19018,7 +19126,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19106,7 +19215,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -19356,7 +19466,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19532,7 +19643,8 @@ "port": { "type": "integer", "description": "SMTP port.", - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "username": { "type": "string", @@ -19559,7 +19671,8 @@ "autoTLS": { "type": "boolean", "description": "Enable SMTP AutoTLS feature.", - "x-example": false + "x-example": false, + "x-nullable": true }, "mailer": { "type": "string", @@ -19589,7 +19702,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } } } @@ -19681,7 +19795,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19769,7 +19884,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "customerId": { "type": "string", @@ -19876,7 +19992,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19964,7 +20081,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "username": { "type": "string", @@ -20071,7 +20189,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20159,7 +20278,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "accountSid": { "type": "string", @@ -20266,7 +20386,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20354,7 +20475,8 @@ "enabled": { "type": "boolean", "description": "Set as enabled.", - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -20970,7 +21092,8 @@ "name": { "type": "string", "description": "Topic Name.", - "x-example": "<NAME>" + "x-example": "<NAME>", + "x-nullable": true }, "subscribe": { "type": "array", @@ -20978,7 +21101,8 @@ "x-example": "[\"any\"]", "items": { "type": "string" - } + }, + "x-nullable": true } } } @@ -22508,17 +22632,20 @@ "installCommand": { "type": "string", "description": "Install Commands.", - "x-example": "<INSTALL_COMMAND>" + "x-example": "<INSTALL_COMMAND>", + "x-nullable": true }, "buildCommand": { "type": "string", "description": "Build Commands.", - "x-example": "<BUILD_COMMAND>" + "x-example": "<BUILD_COMMAND>", + "x-nullable": true }, "outputDirectory": { "type": "string", "description": "Output Directory.", - "x-example": "<OUTPUT_DIRECTORY>" + "x-example": "<OUTPUT_DIRECTORY>", + "x-nullable": true }, "code": { "type": "string", @@ -23643,12 +23770,14 @@ "value": { "type": "string", "description": "Variable value. Max length: 8192 chars.", - "x-example": "<VALUE>" + "x-example": "<VALUE>", + "x-nullable": true }, "secret": { "type": "boolean", "description": "Secret variables can be updated or deleted, but only sites can read them during build and runtime.", - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -23878,7 +24007,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "fileSecurity": { "type": "boolean", @@ -24073,7 +24203,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "fileSecurity": { "type": "boolean", @@ -24369,7 +24500,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true } }, "required": [ @@ -24539,7 +24671,8 @@ "name": { "type": "string", "description": "Name of the file", - "x-example": "<NAME>" + "x-example": "<NAME>", + "x-nullable": true }, "permissions": { "type": "array", @@ -24547,7 +24680,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true } } } @@ -26008,7 +26142,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "rowSecurity": { "type": "boolean", @@ -26194,7 +26329,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "rowSecurity": { "type": "boolean", @@ -26473,7 +26609,8 @@ "default": { "type": "boolean", "description": "Default value for column when not provided. Cannot be set when column is required.", - "x-example": false + "x-example": false, + "x-nullable": true }, "array": { "type": "boolean", @@ -26593,7 +26730,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -26818,7 +26956,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -26923,7 +27062,8 @@ "default": { "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -27043,7 +27183,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -27156,7 +27297,8 @@ "default": { "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -27285,7 +27427,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -27391,17 +27534,20 @@ "min": { "type": "number", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", "description": "Default value. Cannot be set when required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -27515,12 +27661,14 @@ "min": { "type": "number", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", @@ -27531,7 +27679,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -27636,17 +27785,20 @@ "min": { "type": "integer", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", "description": "Default value. Cannot be set when column is required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -27760,12 +27912,14 @@ "min": { "type": "integer", "description": "Minimum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", @@ -27776,7 +27930,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -27881,7 +28036,8 @@ "default": { "type": "string", "description": "Default value. Cannot be set when column is required.", - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -28001,7 +28157,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -28236,7 +28393,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -28470,7 +28628,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -28704,7 +28863,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -28821,12 +28981,14 @@ "key": { "type": "string", "description": "Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true }, "twoWayKey": { "type": "string", "description": "Two Way Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true }, "onDelete": { "type": "string", @@ -28948,7 +29110,8 @@ "default": { "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -29074,12 +29237,14 @@ "size": { "type": "integer", "description": "Maximum size of the string column.", - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -29184,7 +29349,8 @@ "default": { "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", - "x-example": "https:\/\/example.com" + "x-example": "https:\/\/example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -29304,7 +29470,8 @@ "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -29605,12 +29772,14 @@ "setNull" ], "x-enum-name": "RelationMutate", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true }, "newKey": { "type": "string", "description": "New Column Key.", - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -30279,7 +30448,8 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "rows": { "type": "array", @@ -30292,7 +30462,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -30420,7 +30591,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -30526,7 +30698,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -30624,7 +30797,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -30879,12 +31053,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -30995,12 +31171,14 @@ "x-example": "[\"read(\"any\")\"]", "items": { "type": "string" - } + }, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -31096,7 +31274,8 @@ "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -31216,12 +31395,14 @@ "min": { "type": "number", "description": "Minimum value for the column. If the current value is lesser than this value, an exception will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -31341,12 +31522,14 @@ "max": { "type": "number", "description": "Maximum value for the column. If the current value is greater than this value, an error will be thrown.", - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -32959,12 +33142,14 @@ "email": { "type": "string", "description": "User email.", - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "phone": { "type": "string", "description": "Phone number. Format this number with a leading '+' and a country code, e.g., +16175551212.", - "x-example": "+12065550100" + "x-example": "+12065550100", + "x-nullable": true }, "password": { "type": "string", diff --git a/app/config/specs/swagger2-1.8.x-client.json b/app/config/specs/swagger2-1.8.x-client.json index a304a7cb1a..1594f816ef 100644 --- a/app/config/specs/swagger2-1.8.x-client.json +++ b/app/config/specs/swagger2-1.8.x-client.json @@ -6400,6 +6400,7 @@ "description": "An array of permissions strings. By default, only the current user is granted all permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -6417,7 +6418,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -6657,6 +6659,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -6665,7 +6668,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -6771,6 +6775,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -6779,7 +6784,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -6870,7 +6876,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -6982,13 +6989,15 @@ "type": "number", "description": "Minimum value for the attribute. If the current value is lesser than this value, an exception will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -7100,13 +7109,15 @@ "type": "number", "description": "Maximum value for the attribute. If the current value is greater than this value, an error will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -7305,7 +7316,8 @@ "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", "default": null, - "x-example": "<SCHEDULED_AT>" + "x-example": "<SCHEDULED_AT>", + "x-nullable": true } } } @@ -8417,13 +8429,15 @@ "type": "string", "description": "Name of the file", "default": null, - "x-example": "<NAME>" + "x-example": "<NAME>", + "x-nullable": true }, "permissions": { "type": "array", "description": "An array of permission string. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -9516,6 +9530,7 @@ "description": "An array of permissions strings. By default, only the current user is granted all permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -9533,7 +9548,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -9766,6 +9782,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -9774,7 +9791,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -9876,6 +9894,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -9884,7 +9903,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -9974,7 +9994,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -10085,13 +10106,15 @@ "type": "number", "description": "Minimum value for the column. If the current value is lesser than this value, an exception will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -10202,13 +10225,15 @@ "type": "number", "description": "Maximum value for the column. If the current value is greater than this value, an error will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } diff --git a/app/config/specs/swagger2-1.8.x-console.json b/app/config/specs/swagger2-1.8.x-console.json index 158b308f87..5f05314818 100644 --- a/app/config/specs/swagger2-1.8.x-console.json +++ b/app/config/specs/swagger2-1.8.x-console.json @@ -7168,6 +7168,7 @@ "description": "An array of permissions strings. By default, no user is granted with any permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -7350,6 +7351,7 @@ "description": "An array of permission strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -7625,7 +7627,8 @@ "type": "boolean", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "array": { "type": "boolean", @@ -7743,7 +7746,8 @@ "type": "string", "description": "New attribute key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -7965,7 +7969,8 @@ "type": "string", "description": "New attribute key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8069,7 +8074,8 @@ "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", "default": null, - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -8187,7 +8193,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8300,7 +8307,8 @@ "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", "default": null, - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -8428,7 +8436,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8533,19 +8542,22 @@ "type": "number", "description": "Minimum value.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", "description": "Default value. Cannot be set when required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -8656,13 +8668,15 @@ "type": "number", "description": "Minimum value.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", @@ -8675,7 +8689,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8779,19 +8794,22 @@ "type": "integer", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", "description": "Default value. Cannot be set when attribute is required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -8902,13 +8920,15 @@ "type": "integer", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", @@ -8921,7 +8941,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9025,7 +9046,8 @@ "type": "string", "description": "Default value. Cannot be set when attribute is required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -9143,7 +9165,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9360,7 +9383,8 @@ "type": "string", "description": "New attribute key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9576,7 +9600,8 @@ "type": "string", "description": "New attribute key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9792,7 +9817,8 @@ "type": "string", "description": "New attribute key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9909,13 +9935,15 @@ "type": "string", "description": "Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "twoWayKey": { "type": "string", "description": "Two Way Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "onDelete": { "type": "string", @@ -10038,7 +10066,8 @@ "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", "default": null, - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -10163,13 +10192,15 @@ "type": "integer", "description": "Maximum size of the string attribute.", "default": null, - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "newKey": { "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -10273,7 +10304,8 @@ "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", "default": null, - "x-example": "https:\/\/example.com" + "x-example": "https:\/\/example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -10391,7 +10423,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -10679,13 +10712,15 @@ "setNull" ], "x-enum-name": "RelationMutate", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true }, "newKey": { "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -10955,6 +10990,7 @@ "description": "An array of permissions strings. By default, only the current user is granted all permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -10972,7 +11008,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11101,7 +11138,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -11206,7 +11244,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11302,7 +11341,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11542,6 +11582,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -11550,7 +11591,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -11656,6 +11698,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -11664,7 +11707,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11755,7 +11799,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11957,13 +12002,15 @@ "type": "number", "description": "Minimum value for the attribute. If the current value is lesser than this value, an exception will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -12075,13 +12122,15 @@ "type": "number", "description": "Maximum value for the attribute. If the current value is greater than this value, an error will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -14896,7 +14945,8 @@ "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", "default": null, - "x-example": "<SCHEDULED_AT>" + "x-example": "<SCHEDULED_AT>", + "x-nullable": true } } } @@ -15409,13 +15459,15 @@ "type": "string", "description": "Variable value. Max length: 8192 chars.", "default": null, - "x-example": "<VALUE>" + "x-example": "<VALUE>", + "x-nullable": true }, "secret": { "type": "boolean", "description": "Secret variables can be updated or deleted, but only functions can read them during build and runtime.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -17532,7 +17584,8 @@ "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -17615,6 +17668,7 @@ "description": "List of Topic IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17624,6 +17678,7 @@ "description": "List of User IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17633,6 +17688,7 @@ "description": "List of Targets IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17641,31 +17697,36 @@ "type": "string", "description": "Email Subject.", "default": null, - "x-example": "<SUBJECT>" + "x-example": "<SUBJECT>", + "x-nullable": true }, "content": { "type": "string", "description": "Email Content.", "default": null, - "x-example": "<CONTENT>" + "x-example": "<CONTENT>", + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "html": { "type": "boolean", "description": "Is content of type HTML", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "cc": { "type": "array", "description": "Array of target IDs to be added as CC.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17675,6 +17736,7 @@ "description": "Array of target IDs to be added as BCC.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17683,13 +17745,15 @@ "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "attachments": { "type": "array", "description": "Array of compound ID strings of bucket IDs and file IDs to be attached to the email. They should be formatted as <BUCKET_ID>:<FILE_ID>.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17806,7 +17870,8 @@ "type": "object", "description": "Additional key-value pair data for push notification.", "default": {}, - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "action": { "type": "string", @@ -17860,7 +17925,8 @@ "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "contentAvailable": { "type": "boolean", @@ -17965,6 +18031,7 @@ "description": "List of Topic IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17974,6 +18041,7 @@ "description": "List of User IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17983,6 +18051,7 @@ "description": "List of Targets IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17991,85 +18060,99 @@ "type": "string", "description": "Title for push notification.", "default": null, - "x-example": "<TITLE>" + "x-example": "<TITLE>", + "x-nullable": true }, "body": { "type": "string", "description": "Body for push notification.", "default": null, - "x-example": "<BODY>" + "x-example": "<BODY>", + "x-nullable": true }, "data": { "type": "object", "description": "Additional Data for push notification.", "default": {}, - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "action": { "type": "string", "description": "Action for push notification.", "default": null, - "x-example": "<ACTION>" + "x-example": "<ACTION>", + "x-nullable": true }, "image": { "type": "string", "description": "Image for push notification. Must be a compound bucket ID to file ID of a jpeg, png, or bmp image in Appwrite Storage. It should be formatted as <BUCKET_ID>:<FILE_ID>.", "default": null, - "x-example": "<ID1:ID2>" + "x-example": "<ID1:ID2>", + "x-nullable": true }, "icon": { "type": "string", "description": "Icon for push notification. Available only for Android and Web platforms.", "default": null, - "x-example": "<ICON>" + "x-example": "<ICON>", + "x-nullable": true }, "sound": { "type": "string", "description": "Sound for push notification. Available only for Android and iOS platforms.", "default": null, - "x-example": "<SOUND>" + "x-example": "<SOUND>", + "x-nullable": true }, "color": { "type": "string", "description": "Color for push notification. Available only for Android platforms.", "default": null, - "x-example": "<COLOR>" + "x-example": "<COLOR>", + "x-nullable": true }, "tag": { "type": "string", "description": "Tag for push notification. Available only for Android platforms.", "default": null, - "x-example": "<TAG>" + "x-example": "<TAG>", + "x-nullable": true }, "badge": { "type": "integer", "description": "Badge for push notification. Available only for iOS platforms.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "contentAvailable": { "type": "boolean", "description": "If set to true, the notification will be delivered in the background. Available only for iOS Platform.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "critical": { "type": "boolean", "description": "If set to true, the notification will be marked as critical. This requires the app to have the critical notification entitlement. Available only for iOS Platform.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "priority": { "type": "string", @@ -18081,7 +18164,8 @@ "high" ], "x-enum-name": "MessagePriority", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true } } } @@ -18263,7 +18347,8 @@ "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -18411,6 +18496,7 @@ "description": "List of Topic IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -18420,6 +18506,7 @@ "description": "List of User IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -18429,6 +18516,7 @@ "description": "List of Targets IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -18437,19 +18525,22 @@ "type": "string", "description": "Email Content.", "default": null, - "x-example": "<CONTENT>" + "x-example": "<CONTENT>", + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -18989,7 +19080,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19144,7 +19236,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "authKey": { "type": "string", @@ -19174,7 +19267,8 @@ "type": "boolean", "description": "Use APNS sandbox environment.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } } } @@ -19317,13 +19411,15 @@ "type": "object", "description": "FCM service account JSON.", "default": {}, - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "enabled": { "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19470,13 +19566,15 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "serviceAccountJSON": { "type": "object", "description": "FCM service account JSON.", "default": {}, - "x-example": "{}" + "x-example": "{}", + "x-nullable": true } } } @@ -19569,7 +19667,8 @@ "type": "boolean", "description": "Set as EU region.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "fromName": { "type": "string", @@ -19599,7 +19698,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19698,13 +19798,15 @@ "type": "boolean", "description": "Set as EU region.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "enabled": { "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "fromName": { "type": "string", @@ -19827,7 +19929,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19914,7 +20017,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "templateId": { "type": "string", @@ -20043,7 +20147,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20130,7 +20235,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -20271,7 +20377,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20358,7 +20465,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -20626,7 +20734,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20800,7 +20909,8 @@ "type": "integer", "description": "SMTP port.", "default": null, - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "username": { "type": "string", @@ -20831,7 +20941,8 @@ "type": "boolean", "description": "Enable SMTP AutoTLS feature.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "mailer": { "type": "string", @@ -20867,7 +20978,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } } } @@ -20966,7 +21078,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -21053,7 +21166,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "customerId": { "type": "string", @@ -21170,7 +21284,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -21257,7 +21372,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "username": { "type": "string", @@ -21374,7 +21490,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -21461,7 +21578,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "accountSid": { "type": "string", @@ -21578,7 +21696,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -21665,7 +21784,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -22265,13 +22385,15 @@ "type": "string", "description": "Topic Name.", "default": null, - "x-example": "<NAME>" + "x-example": "<NAME>", + "x-nullable": true }, "subscribe": { "type": "array", "description": "An array of role strings with subscribe permission. By default all users are granted with any subscribe permission. [learn more about roles](https:\/\/appwrite.io\/docs\/permissions#permission-roles). Maximum of 100 roles are allowed, each 64 characters long.", "default": null, "x-example": "[\"any\"]", + "x-nullable": true, "items": { "type": "string" } @@ -24332,13 +24454,15 @@ "type": "string", "description": "Variable value. Max length: 8192 chars.", "default": null, - "x-example": "<VALUE>" + "x-example": "<VALUE>", + "x-nullable": true }, "secret": { "type": "boolean", "description": "Secret variables can be updated or deleted, but only projects can read them during build and runtime.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -26651,6 +26775,7 @@ "description": "Key scopes list. Maximum of 100 scopes are allowed.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -26659,7 +26784,8 @@ "type": "string", "description": "Expiration time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Use null for unlimited expiration.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -26817,6 +26943,7 @@ "description": "Key scopes list. Maximum of 100 events are allowed.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -26825,7 +26952,8 @@ "type": "string", "description": "Expiration time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Use null for unlimited expiration.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -27015,19 +27143,22 @@ "type": "string", "description": "Provider app ID. Max length: 256 chars.", "default": null, - "x-example": "<APP_ID>" + "x-example": "<APP_ID>", + "x-nullable": true }, "secret": { "type": "string", "description": "Provider secret key. Max length: 512 chars.", "default": null, - "x-example": "<SECRET>" + "x-example": "<SECRET>", + "x-nullable": true }, "enabled": { "type": "boolean", "description": "Provider status. Set to 'false' to disable new session creation.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -33273,13 +33404,15 @@ "type": "string", "description": "Variable value. Max length: 8192 chars.", "default": null, - "x-example": "<VALUE>" + "x-example": "<VALUE>", + "x-nullable": true }, "secret": { "type": "boolean", "description": "Secret variables can be updated or deleted, but only sites can read them during build and runtime.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -33504,6 +33637,7 @@ "description": "An array of permission strings. By default, no user is granted with any permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -33702,6 +33836,7 @@ "description": "An array of permission strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -34146,13 +34281,15 @@ "type": "string", "description": "Name of the file", "default": null, - "x-example": "<NAME>" + "x-example": "<NAME>", + "x-nullable": true }, "permissions": { "type": "array", "description": "An array of permission string. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -35796,6 +35933,7 @@ "description": "An array of permissions strings. By default, no user is granted with any permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -35976,6 +36114,7 @@ "description": "An array of permission strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -36248,7 +36387,8 @@ "type": "boolean", "description": "Default value for column when not provided. Cannot be set when column is required.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "array": { "type": "boolean", @@ -36365,7 +36505,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -36585,7 +36726,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -36688,7 +36830,8 @@ "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", "default": null, - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -36805,7 +36948,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -36917,7 +37061,8 @@ "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", "default": null, - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -37044,7 +37189,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -37148,19 +37294,22 @@ "type": "number", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", "description": "Default value. Cannot be set when required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -37270,13 +37419,15 @@ "type": "number", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", @@ -37289,7 +37440,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -37392,19 +37544,22 @@ "type": "integer", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", "description": "Default value. Cannot be set when column is required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -37514,13 +37669,15 @@ "type": "integer", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", @@ -37533,7 +37690,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -37636,7 +37794,8 @@ "type": "string", "description": "Default value. Cannot be set when column is required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -37753,7 +37912,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -37968,7 +38128,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -38182,7 +38343,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -38396,7 +38558,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -38512,13 +38675,15 @@ "type": "string", "description": "Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "twoWayKey": { "type": "string", "description": "Two Way Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "onDelete": { "type": "string", @@ -38640,7 +38805,8 @@ "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", "default": null, - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -38764,13 +38930,15 @@ "type": "integer", "description": "Maximum size of the string column.", "default": null, - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "newKey": { "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -38873,7 +39041,8 @@ "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", "default": null, - "x-example": "https:\/\/example.com" + "x-example": "https:\/\/example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -38990,7 +39159,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -39275,13 +39445,15 @@ "setNull" ], "x-enum-name": "RelationMutate", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true }, "newKey": { "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -39993,6 +40165,7 @@ "description": "An array of permissions strings. By default, only the current user is granted all permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -40010,7 +40183,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -40134,7 +40308,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -40238,7 +40413,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -40333,7 +40509,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -40566,6 +40743,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -40574,7 +40752,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -40676,6 +40855,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -40684,7 +40864,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -40774,7 +40955,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -40974,13 +41156,15 @@ "type": "number", "description": "Minimum value for the column. If the current value is lesser than this value, an exception will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -41091,13 +41275,15 @@ "type": "number", "description": "Maximum value for the column. If the current value is greater than this value, an error will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -42915,13 +43101,15 @@ "type": "string", "description": "User email.", "default": null, - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "phone": { "type": "string", "description": "Phone number. Format this number with a leading '+' and a country code, e.g., +16175551212.", "default": null, - "x-example": "+12065550100" + "x-example": "+12065550100", + "x-nullable": true }, "password": { "type": "string", diff --git a/app/config/specs/swagger2-1.8.x-server.json b/app/config/specs/swagger2-1.8.x-server.json index 8b972be590..15606799ea 100644 --- a/app/config/specs/swagger2-1.8.x-server.json +++ b/app/config/specs/swagger2-1.8.x-server.json @@ -6620,6 +6620,7 @@ "description": "An array of permissions strings. By default, no user is granted with any permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -6804,6 +6805,7 @@ "description": "An array of permission strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -7082,7 +7084,8 @@ "type": "boolean", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "array": { "type": "boolean", @@ -7201,7 +7204,8 @@ "type": "string", "description": "New attribute key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -7425,7 +7429,8 @@ "type": "string", "description": "New attribute key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -7530,7 +7535,8 @@ "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", "default": null, - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -7649,7 +7655,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -7763,7 +7770,8 @@ "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", "default": null, - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -7892,7 +7900,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -7998,19 +8007,22 @@ "type": "number", "description": "Minimum value.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", "description": "Default value. Cannot be set when required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -8122,13 +8134,15 @@ "type": "number", "description": "Minimum value.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", @@ -8141,7 +8155,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8246,19 +8261,22 @@ "type": "integer", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", "description": "Default value. Cannot be set when attribute is required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -8370,13 +8388,15 @@ "type": "integer", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", @@ -8389,7 +8409,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8494,7 +8515,8 @@ "type": "string", "description": "Default value. Cannot be set when attribute is required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -8613,7 +8635,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8832,7 +8855,8 @@ "type": "string", "description": "New attribute key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9050,7 +9074,8 @@ "type": "string", "description": "New attribute key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9268,7 +9293,8 @@ "type": "string", "description": "New attribute key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9386,13 +9412,15 @@ "type": "string", "description": "Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "twoWayKey": { "type": "string", "description": "Two Way Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "onDelete": { "type": "string", @@ -9516,7 +9544,8 @@ "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", "default": null, - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -9642,13 +9671,15 @@ "type": "integer", "description": "Maximum size of the string attribute.", "default": null, - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "newKey": { "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9753,7 +9784,8 @@ "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", "default": null, - "x-example": "https:\/\/example.com" + "x-example": "https:\/\/example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -9872,7 +9904,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -10163,13 +10196,15 @@ "setNull" ], "x-enum-name": "RelationMutate", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true }, "newKey": { "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -10445,6 +10480,7 @@ "description": "An array of permissions strings. By default, only the current user is granted all permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -10462,7 +10498,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -10593,7 +10630,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -10699,7 +10737,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -10796,7 +10835,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11041,6 +11081,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -11049,7 +11090,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -11157,6 +11199,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -11165,7 +11208,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11258,7 +11302,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11372,13 +11417,15 @@ "type": "number", "description": "Minimum value for the attribute. If the current value is lesser than this value, an exception will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11492,13 +11539,15 @@ "type": "number", "description": "Maximum value for the attribute. If the current value is greater than this value, an error will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -13721,7 +13770,8 @@ "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", "default": null, - "x-example": "<SCHEDULED_AT>" + "x-example": "<SCHEDULED_AT>", + "x-nullable": true } } } @@ -14163,13 +14213,15 @@ "type": "string", "description": "Variable value. Max length: 8192 chars.", "default": null, - "x-example": "<VALUE>" + "x-example": "<VALUE>", + "x-nullable": true }, "secret": { "type": "boolean", "description": "Secret variables can be updated or deleted, but only functions can read them during build and runtime.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -16331,7 +16383,8 @@ "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -16415,6 +16468,7 @@ "description": "List of Topic IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -16424,6 +16478,7 @@ "description": "List of User IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -16433,6 +16488,7 @@ "description": "List of Targets IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -16441,31 +16497,36 @@ "type": "string", "description": "Email Subject.", "default": null, - "x-example": "<SUBJECT>" + "x-example": "<SUBJECT>", + "x-nullable": true }, "content": { "type": "string", "description": "Email Content.", "default": null, - "x-example": "<CONTENT>" + "x-example": "<CONTENT>", + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "html": { "type": "boolean", "description": "Is content of type HTML", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "cc": { "type": "array", "description": "Array of target IDs to be added as CC.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -16475,6 +16536,7 @@ "description": "Array of target IDs to be added as BCC.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -16483,13 +16545,15 @@ "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "attachments": { "type": "array", "description": "Array of compound ID strings of bucket IDs and file IDs to be attached to the email. They should be formatted as <BUCKET_ID>:<FILE_ID>.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -16607,7 +16671,8 @@ "type": "object", "description": "Additional key-value pair data for push notification.", "default": {}, - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "action": { "type": "string", @@ -16661,7 +16726,8 @@ "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "contentAvailable": { "type": "boolean", @@ -16767,6 +16833,7 @@ "description": "List of Topic IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -16776,6 +16843,7 @@ "description": "List of User IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -16785,6 +16853,7 @@ "description": "List of Targets IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -16793,85 +16862,99 @@ "type": "string", "description": "Title for push notification.", "default": null, - "x-example": "<TITLE>" + "x-example": "<TITLE>", + "x-nullable": true }, "body": { "type": "string", "description": "Body for push notification.", "default": null, - "x-example": "<BODY>" + "x-example": "<BODY>", + "x-nullable": true }, "data": { "type": "object", "description": "Additional Data for push notification.", "default": {}, - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "action": { "type": "string", "description": "Action for push notification.", "default": null, - "x-example": "<ACTION>" + "x-example": "<ACTION>", + "x-nullable": true }, "image": { "type": "string", "description": "Image for push notification. Must be a compound bucket ID to file ID of a jpeg, png, or bmp image in Appwrite Storage. It should be formatted as <BUCKET_ID>:<FILE_ID>.", "default": null, - "x-example": "<ID1:ID2>" + "x-example": "<ID1:ID2>", + "x-nullable": true }, "icon": { "type": "string", "description": "Icon for push notification. Available only for Android and Web platforms.", "default": null, - "x-example": "<ICON>" + "x-example": "<ICON>", + "x-nullable": true }, "sound": { "type": "string", "description": "Sound for push notification. Available only for Android and iOS platforms.", "default": null, - "x-example": "<SOUND>" + "x-example": "<SOUND>", + "x-nullable": true }, "color": { "type": "string", "description": "Color for push notification. Available only for Android platforms.", "default": null, - "x-example": "<COLOR>" + "x-example": "<COLOR>", + "x-nullable": true }, "tag": { "type": "string", "description": "Tag for push notification. Available only for Android platforms.", "default": null, - "x-example": "<TAG>" + "x-example": "<TAG>", + "x-nullable": true }, "badge": { "type": "integer", "description": "Badge for push notification. Available only for iOS platforms.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "contentAvailable": { "type": "boolean", "description": "If set to true, the notification will be delivered in the background. Available only for iOS Platform.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "critical": { "type": "boolean", "description": "If set to true, the notification will be marked as critical. This requires the app to have the critical notification entitlement. Available only for iOS Platform.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "priority": { "type": "string", @@ -16883,7 +16966,8 @@ "high" ], "x-enum-name": "MessagePriority", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true } } } @@ -17068,7 +17152,8 @@ "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -17219,6 +17304,7 @@ "description": "List of Topic IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17228,6 +17314,7 @@ "description": "List of User IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17237,6 +17324,7 @@ "description": "List of Targets IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17245,19 +17333,22 @@ "type": "string", "description": "Email Content.", "default": null, - "x-example": "<CONTENT>" + "x-example": "<CONTENT>", + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -17805,7 +17896,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -17963,7 +18055,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "authKey": { "type": "string", @@ -17993,7 +18086,8 @@ "type": "boolean", "description": "Use APNS sandbox environment.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } } } @@ -18139,13 +18233,15 @@ "type": "object", "description": "FCM service account JSON.", "default": {}, - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "enabled": { "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -18295,13 +18391,15 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "serviceAccountJSON": { "type": "object", "description": "FCM service account JSON.", "default": {}, - "x-example": "{}" + "x-example": "{}", + "x-nullable": true } } } @@ -18395,7 +18493,8 @@ "type": "boolean", "description": "Set as EU region.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "fromName": { "type": "string", @@ -18425,7 +18524,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -18525,13 +18625,15 @@ "type": "boolean", "description": "Set as EU region.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "enabled": { "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "fromName": { "type": "string", @@ -18655,7 +18757,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -18743,7 +18846,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "templateId": { "type": "string", @@ -18873,7 +18977,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -18961,7 +19066,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -19103,7 +19209,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19191,7 +19298,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -19462,7 +19570,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19639,7 +19748,8 @@ "type": "integer", "description": "SMTP port.", "default": null, - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "username": { "type": "string", @@ -19670,7 +19780,8 @@ "type": "boolean", "description": "Enable SMTP AutoTLS feature.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "mailer": { "type": "string", @@ -19706,7 +19817,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } } } @@ -19806,7 +19918,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19894,7 +20007,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "customerId": { "type": "string", @@ -20012,7 +20126,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20100,7 +20215,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "username": { "type": "string", @@ -20218,7 +20334,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20306,7 +20423,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "accountSid": { "type": "string", @@ -20424,7 +20542,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20512,7 +20631,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -21120,13 +21240,15 @@ "type": "string", "description": "Topic Name.", "default": null, - "x-example": "<NAME>" + "x-example": "<NAME>", + "x-nullable": true }, "subscribe": { "type": "array", "description": "An array of role strings with subscribe permission. By default all users are granted with any subscribe permission. [learn more about roles](https:\/\/appwrite.io\/docs\/permissions#permission-roles). Maximum of 100 roles are allowed, each 64 characters long.", "default": null, "x-example": "[\"any\"]", + "x-nullable": true, "items": { "type": "string" } @@ -23782,13 +23904,15 @@ "type": "string", "description": "Variable value. Max length: 8192 chars.", "default": null, - "x-example": "<VALUE>" + "x-example": "<VALUE>", + "x-nullable": true }, "secret": { "type": "boolean", "description": "Secret variables can be updated or deleted, but only sites can read them during build and runtime.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -24016,6 +24140,7 @@ "description": "An array of permission strings. By default, no user is granted with any permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -24216,6 +24341,7 @@ "description": "An array of permission strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -24669,13 +24795,15 @@ "type": "string", "description": "Name of the file", "default": null, - "x-example": "<NAME>" + "x-example": "<NAME>", + "x-nullable": true }, "permissions": { "type": "array", "description": "An array of permission string. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -26103,6 +26231,7 @@ "description": "An array of permissions strings. By default, no user is granted with any permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -26285,6 +26414,7 @@ "description": "An array of permission strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -26560,7 +26690,8 @@ "type": "boolean", "description": "Default value for column when not provided. Cannot be set when column is required.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "array": { "type": "boolean", @@ -26678,7 +26809,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -26900,7 +27032,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -27004,7 +27137,8 @@ "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", "default": null, - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -27122,7 +27256,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -27235,7 +27370,8 @@ "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", "default": null, - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -27363,7 +27499,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -27468,19 +27605,22 @@ "type": "number", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", "description": "Default value. Cannot be set when required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -27591,13 +27731,15 @@ "type": "number", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", @@ -27610,7 +27752,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -27714,19 +27857,22 @@ "type": "integer", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", "description": "Default value. Cannot be set when column is required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -27837,13 +27983,15 @@ "type": "integer", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", @@ -27856,7 +28004,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -27960,7 +28109,8 @@ "type": "string", "description": "Default value. Cannot be set when column is required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -28078,7 +28228,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -28295,7 +28446,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -28511,7 +28663,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -28727,7 +28880,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -28844,13 +28998,15 @@ "type": "string", "description": "Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "twoWayKey": { "type": "string", "description": "Two Way Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "onDelete": { "type": "string", @@ -28973,7 +29129,8 @@ "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", "default": null, - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -29098,13 +29255,15 @@ "type": "integer", "description": "Maximum size of the string column.", "default": null, - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "newKey": { "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -29208,7 +29367,8 @@ "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", "default": null, - "x-example": "https:\/\/example.com" + "x-example": "https:\/\/example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -29326,7 +29486,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -29614,13 +29775,15 @@ "setNull" ], "x-enum-name": "RelationMutate", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true }, "newKey": { "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -30261,6 +30424,7 @@ "description": "An array of permissions strings. By default, only the current user is granted all permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -30278,7 +30442,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -30404,7 +30569,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -30509,7 +30675,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -30605,7 +30772,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -30843,6 +31011,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -30851,7 +31020,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -30955,6 +31125,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -30963,7 +31134,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -31055,7 +31227,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -31168,13 +31341,15 @@ "type": "number", "description": "Minimum value for the column. If the current value is lesser than this value, an exception will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -31287,13 +31462,15 @@ "type": "number", "description": "Maximum value for the column. If the current value is greater than this value, an error will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -32870,13 +33047,15 @@ "type": "string", "description": "User email.", "default": null, - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "phone": { "type": "string", "description": "Phone number. Format this number with a leading '+' and a country code, e.g., +16175551212.", "default": null, - "x-example": "+12065550100" + "x-example": "+12065550100", + "x-nullable": true }, "password": { "type": "string", diff --git a/app/config/specs/swagger2-latest-client.json b/app/config/specs/swagger2-latest-client.json index a304a7cb1a..1594f816ef 100644 --- a/app/config/specs/swagger2-latest-client.json +++ b/app/config/specs/swagger2-latest-client.json @@ -6400,6 +6400,7 @@ "description": "An array of permissions strings. By default, only the current user is granted all permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -6417,7 +6418,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -6657,6 +6659,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -6665,7 +6668,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -6771,6 +6775,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -6779,7 +6784,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -6870,7 +6876,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -6982,13 +6989,15 @@ "type": "number", "description": "Minimum value for the attribute. If the current value is lesser than this value, an exception will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -7100,13 +7109,15 @@ "type": "number", "description": "Maximum value for the attribute. If the current value is greater than this value, an error will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -7305,7 +7316,8 @@ "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", "default": null, - "x-example": "<SCHEDULED_AT>" + "x-example": "<SCHEDULED_AT>", + "x-nullable": true } } } @@ -8417,13 +8429,15 @@ "type": "string", "description": "Name of the file", "default": null, - "x-example": "<NAME>" + "x-example": "<NAME>", + "x-nullable": true }, "permissions": { "type": "array", "description": "An array of permission string. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -9516,6 +9530,7 @@ "description": "An array of permissions strings. By default, only the current user is granted all permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -9533,7 +9548,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -9766,6 +9782,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -9774,7 +9791,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -9876,6 +9894,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -9884,7 +9903,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -9974,7 +9994,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -10085,13 +10106,15 @@ "type": "number", "description": "Minimum value for the column. If the current value is lesser than this value, an exception will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -10202,13 +10225,15 @@ "type": "number", "description": "Maximum value for the column. If the current value is greater than this value, an error will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } diff --git a/app/config/specs/swagger2-latest-console.json b/app/config/specs/swagger2-latest-console.json index 158b308f87..5f05314818 100644 --- a/app/config/specs/swagger2-latest-console.json +++ b/app/config/specs/swagger2-latest-console.json @@ -7168,6 +7168,7 @@ "description": "An array of permissions strings. By default, no user is granted with any permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -7350,6 +7351,7 @@ "description": "An array of permission strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -7625,7 +7627,8 @@ "type": "boolean", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "array": { "type": "boolean", @@ -7743,7 +7746,8 @@ "type": "string", "description": "New attribute key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -7965,7 +7969,8 @@ "type": "string", "description": "New attribute key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8069,7 +8074,8 @@ "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", "default": null, - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -8187,7 +8193,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8300,7 +8307,8 @@ "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", "default": null, - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -8428,7 +8436,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8533,19 +8542,22 @@ "type": "number", "description": "Minimum value.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", "description": "Default value. Cannot be set when required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -8656,13 +8668,15 @@ "type": "number", "description": "Minimum value.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", @@ -8675,7 +8689,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8779,19 +8794,22 @@ "type": "integer", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", "description": "Default value. Cannot be set when attribute is required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -8902,13 +8920,15 @@ "type": "integer", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", @@ -8921,7 +8941,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9025,7 +9046,8 @@ "type": "string", "description": "Default value. Cannot be set when attribute is required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -9143,7 +9165,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9360,7 +9383,8 @@ "type": "string", "description": "New attribute key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9576,7 +9600,8 @@ "type": "string", "description": "New attribute key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9792,7 +9817,8 @@ "type": "string", "description": "New attribute key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9909,13 +9935,15 @@ "type": "string", "description": "Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "twoWayKey": { "type": "string", "description": "Two Way Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "onDelete": { "type": "string", @@ -10038,7 +10066,8 @@ "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", "default": null, - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -10163,13 +10192,15 @@ "type": "integer", "description": "Maximum size of the string attribute.", "default": null, - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "newKey": { "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -10273,7 +10304,8 @@ "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", "default": null, - "x-example": "https:\/\/example.com" + "x-example": "https:\/\/example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -10391,7 +10423,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -10679,13 +10712,15 @@ "setNull" ], "x-enum-name": "RelationMutate", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true }, "newKey": { "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -10955,6 +10990,7 @@ "description": "An array of permissions strings. By default, only the current user is granted all permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -10972,7 +11008,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11101,7 +11138,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -11206,7 +11244,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11302,7 +11341,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11542,6 +11582,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -11550,7 +11591,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -11656,6 +11698,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -11664,7 +11707,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11755,7 +11799,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11957,13 +12002,15 @@ "type": "number", "description": "Minimum value for the attribute. If the current value is lesser than this value, an exception will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -12075,13 +12122,15 @@ "type": "number", "description": "Maximum value for the attribute. If the current value is greater than this value, an error will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -14896,7 +14945,8 @@ "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", "default": null, - "x-example": "<SCHEDULED_AT>" + "x-example": "<SCHEDULED_AT>", + "x-nullable": true } } } @@ -15409,13 +15459,15 @@ "type": "string", "description": "Variable value. Max length: 8192 chars.", "default": null, - "x-example": "<VALUE>" + "x-example": "<VALUE>", + "x-nullable": true }, "secret": { "type": "boolean", "description": "Secret variables can be updated or deleted, but only functions can read them during build and runtime.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -17532,7 +17584,8 @@ "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -17615,6 +17668,7 @@ "description": "List of Topic IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17624,6 +17678,7 @@ "description": "List of User IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17633,6 +17688,7 @@ "description": "List of Targets IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17641,31 +17697,36 @@ "type": "string", "description": "Email Subject.", "default": null, - "x-example": "<SUBJECT>" + "x-example": "<SUBJECT>", + "x-nullable": true }, "content": { "type": "string", "description": "Email Content.", "default": null, - "x-example": "<CONTENT>" + "x-example": "<CONTENT>", + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "html": { "type": "boolean", "description": "Is content of type HTML", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "cc": { "type": "array", "description": "Array of target IDs to be added as CC.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17675,6 +17736,7 @@ "description": "Array of target IDs to be added as BCC.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17683,13 +17745,15 @@ "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "attachments": { "type": "array", "description": "Array of compound ID strings of bucket IDs and file IDs to be attached to the email. They should be formatted as <BUCKET_ID>:<FILE_ID>.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17806,7 +17870,8 @@ "type": "object", "description": "Additional key-value pair data for push notification.", "default": {}, - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "action": { "type": "string", @@ -17860,7 +17925,8 @@ "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "contentAvailable": { "type": "boolean", @@ -17965,6 +18031,7 @@ "description": "List of Topic IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17974,6 +18041,7 @@ "description": "List of User IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17983,6 +18051,7 @@ "description": "List of Targets IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17991,85 +18060,99 @@ "type": "string", "description": "Title for push notification.", "default": null, - "x-example": "<TITLE>" + "x-example": "<TITLE>", + "x-nullable": true }, "body": { "type": "string", "description": "Body for push notification.", "default": null, - "x-example": "<BODY>" + "x-example": "<BODY>", + "x-nullable": true }, "data": { "type": "object", "description": "Additional Data for push notification.", "default": {}, - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "action": { "type": "string", "description": "Action for push notification.", "default": null, - "x-example": "<ACTION>" + "x-example": "<ACTION>", + "x-nullable": true }, "image": { "type": "string", "description": "Image for push notification. Must be a compound bucket ID to file ID of a jpeg, png, or bmp image in Appwrite Storage. It should be formatted as <BUCKET_ID>:<FILE_ID>.", "default": null, - "x-example": "<ID1:ID2>" + "x-example": "<ID1:ID2>", + "x-nullable": true }, "icon": { "type": "string", "description": "Icon for push notification. Available only for Android and Web platforms.", "default": null, - "x-example": "<ICON>" + "x-example": "<ICON>", + "x-nullable": true }, "sound": { "type": "string", "description": "Sound for push notification. Available only for Android and iOS platforms.", "default": null, - "x-example": "<SOUND>" + "x-example": "<SOUND>", + "x-nullable": true }, "color": { "type": "string", "description": "Color for push notification. Available only for Android platforms.", "default": null, - "x-example": "<COLOR>" + "x-example": "<COLOR>", + "x-nullable": true }, "tag": { "type": "string", "description": "Tag for push notification. Available only for Android platforms.", "default": null, - "x-example": "<TAG>" + "x-example": "<TAG>", + "x-nullable": true }, "badge": { "type": "integer", "description": "Badge for push notification. Available only for iOS platforms.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "contentAvailable": { "type": "boolean", "description": "If set to true, the notification will be delivered in the background. Available only for iOS Platform.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "critical": { "type": "boolean", "description": "If set to true, the notification will be marked as critical. This requires the app to have the critical notification entitlement. Available only for iOS Platform.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "priority": { "type": "string", @@ -18081,7 +18164,8 @@ "high" ], "x-enum-name": "MessagePriority", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true } } } @@ -18263,7 +18347,8 @@ "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -18411,6 +18496,7 @@ "description": "List of Topic IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -18420,6 +18506,7 @@ "description": "List of User IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -18429,6 +18516,7 @@ "description": "List of Targets IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -18437,19 +18525,22 @@ "type": "string", "description": "Email Content.", "default": null, - "x-example": "<CONTENT>" + "x-example": "<CONTENT>", + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -18989,7 +19080,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19144,7 +19236,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "authKey": { "type": "string", @@ -19174,7 +19267,8 @@ "type": "boolean", "description": "Use APNS sandbox environment.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } } } @@ -19317,13 +19411,15 @@ "type": "object", "description": "FCM service account JSON.", "default": {}, - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "enabled": { "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19470,13 +19566,15 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "serviceAccountJSON": { "type": "object", "description": "FCM service account JSON.", "default": {}, - "x-example": "{}" + "x-example": "{}", + "x-nullable": true } } } @@ -19569,7 +19667,8 @@ "type": "boolean", "description": "Set as EU region.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "fromName": { "type": "string", @@ -19599,7 +19698,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19698,13 +19798,15 @@ "type": "boolean", "description": "Set as EU region.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "enabled": { "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "fromName": { "type": "string", @@ -19827,7 +19929,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19914,7 +20017,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "templateId": { "type": "string", @@ -20043,7 +20147,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20130,7 +20235,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -20271,7 +20377,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20358,7 +20465,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -20626,7 +20734,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20800,7 +20909,8 @@ "type": "integer", "description": "SMTP port.", "default": null, - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "username": { "type": "string", @@ -20831,7 +20941,8 @@ "type": "boolean", "description": "Enable SMTP AutoTLS feature.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "mailer": { "type": "string", @@ -20867,7 +20978,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } } } @@ -20966,7 +21078,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -21053,7 +21166,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "customerId": { "type": "string", @@ -21170,7 +21284,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -21257,7 +21372,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "username": { "type": "string", @@ -21374,7 +21490,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -21461,7 +21578,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "accountSid": { "type": "string", @@ -21578,7 +21696,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -21665,7 +21784,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -22265,13 +22385,15 @@ "type": "string", "description": "Topic Name.", "default": null, - "x-example": "<NAME>" + "x-example": "<NAME>", + "x-nullable": true }, "subscribe": { "type": "array", "description": "An array of role strings with subscribe permission. By default all users are granted with any subscribe permission. [learn more about roles](https:\/\/appwrite.io\/docs\/permissions#permission-roles). Maximum of 100 roles are allowed, each 64 characters long.", "default": null, "x-example": "[\"any\"]", + "x-nullable": true, "items": { "type": "string" } @@ -24332,13 +24454,15 @@ "type": "string", "description": "Variable value. Max length: 8192 chars.", "default": null, - "x-example": "<VALUE>" + "x-example": "<VALUE>", + "x-nullable": true }, "secret": { "type": "boolean", "description": "Secret variables can be updated or deleted, but only projects can read them during build and runtime.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -26651,6 +26775,7 @@ "description": "Key scopes list. Maximum of 100 scopes are allowed.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -26659,7 +26784,8 @@ "type": "string", "description": "Expiration time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Use null for unlimited expiration.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -26817,6 +26943,7 @@ "description": "Key scopes list. Maximum of 100 events are allowed.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -26825,7 +26952,8 @@ "type": "string", "description": "Expiration time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. Use null for unlimited expiration.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -27015,19 +27143,22 @@ "type": "string", "description": "Provider app ID. Max length: 256 chars.", "default": null, - "x-example": "<APP_ID>" + "x-example": "<APP_ID>", + "x-nullable": true }, "secret": { "type": "string", "description": "Provider secret key. Max length: 512 chars.", "default": null, - "x-example": "<SECRET>" + "x-example": "<SECRET>", + "x-nullable": true }, "enabled": { "type": "boolean", "description": "Provider status. Set to 'false' to disable new session creation.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -33273,13 +33404,15 @@ "type": "string", "description": "Variable value. Max length: 8192 chars.", "default": null, - "x-example": "<VALUE>" + "x-example": "<VALUE>", + "x-nullable": true }, "secret": { "type": "boolean", "description": "Secret variables can be updated or deleted, but only sites can read them during build and runtime.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -33504,6 +33637,7 @@ "description": "An array of permission strings. By default, no user is granted with any permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -33702,6 +33836,7 @@ "description": "An array of permission strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -34146,13 +34281,15 @@ "type": "string", "description": "Name of the file", "default": null, - "x-example": "<NAME>" + "x-example": "<NAME>", + "x-nullable": true }, "permissions": { "type": "array", "description": "An array of permission string. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -35796,6 +35933,7 @@ "description": "An array of permissions strings. By default, no user is granted with any permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -35976,6 +36114,7 @@ "description": "An array of permission strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -36248,7 +36387,8 @@ "type": "boolean", "description": "Default value for column when not provided. Cannot be set when column is required.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "array": { "type": "boolean", @@ -36365,7 +36505,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -36585,7 +36726,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -36688,7 +36830,8 @@ "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", "default": null, - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -36805,7 +36948,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -36917,7 +37061,8 @@ "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", "default": null, - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -37044,7 +37189,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -37148,19 +37294,22 @@ "type": "number", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", "description": "Default value. Cannot be set when required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -37270,13 +37419,15 @@ "type": "number", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", @@ -37289,7 +37440,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -37392,19 +37544,22 @@ "type": "integer", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", "description": "Default value. Cannot be set when column is required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -37514,13 +37669,15 @@ "type": "integer", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", @@ -37533,7 +37690,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -37636,7 +37794,8 @@ "type": "string", "description": "Default value. Cannot be set when column is required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -37753,7 +37912,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -37968,7 +38128,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -38182,7 +38343,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -38396,7 +38558,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -38512,13 +38675,15 @@ "type": "string", "description": "Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "twoWayKey": { "type": "string", "description": "Two Way Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "onDelete": { "type": "string", @@ -38640,7 +38805,8 @@ "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", "default": null, - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -38764,13 +38930,15 @@ "type": "integer", "description": "Maximum size of the string column.", "default": null, - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "newKey": { "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -38873,7 +39041,8 @@ "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", "default": null, - "x-example": "https:\/\/example.com" + "x-example": "https:\/\/example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -38990,7 +39159,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -39275,13 +39445,15 @@ "setNull" ], "x-enum-name": "RelationMutate", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true }, "newKey": { "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -39993,6 +40165,7 @@ "description": "An array of permissions strings. By default, only the current user is granted all permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -40010,7 +40183,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -40134,7 +40308,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -40238,7 +40413,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -40333,7 +40509,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -40566,6 +40743,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -40574,7 +40752,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -40676,6 +40855,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -40684,7 +40864,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -40774,7 +40955,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -40974,13 +41156,15 @@ "type": "number", "description": "Minimum value for the column. If the current value is lesser than this value, an exception will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -41091,13 +41275,15 @@ "type": "number", "description": "Maximum value for the column. If the current value is greater than this value, an error will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -42915,13 +43101,15 @@ "type": "string", "description": "User email.", "default": null, - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "phone": { "type": "string", "description": "Phone number. Format this number with a leading '+' and a country code, e.g., +16175551212.", "default": null, - "x-example": "+12065550100" + "x-example": "+12065550100", + "x-nullable": true }, "password": { "type": "string", diff --git a/app/config/specs/swagger2-latest-server.json b/app/config/specs/swagger2-latest-server.json index 8b972be590..15606799ea 100644 --- a/app/config/specs/swagger2-latest-server.json +++ b/app/config/specs/swagger2-latest-server.json @@ -6620,6 +6620,7 @@ "description": "An array of permissions strings. By default, no user is granted with any permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -6804,6 +6805,7 @@ "description": "An array of permission strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -7082,7 +7084,8 @@ "type": "boolean", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "array": { "type": "boolean", @@ -7201,7 +7204,8 @@ "type": "string", "description": "New attribute key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -7425,7 +7429,8 @@ "type": "string", "description": "New attribute key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -7530,7 +7535,8 @@ "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", "default": null, - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -7649,7 +7655,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -7763,7 +7770,8 @@ "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", "default": null, - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -7892,7 +7900,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -7998,19 +8007,22 @@ "type": "number", "description": "Minimum value.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", "description": "Default value. Cannot be set when required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -8122,13 +8134,15 @@ "type": "number", "description": "Minimum value.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", @@ -8141,7 +8155,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8246,19 +8261,22 @@ "type": "integer", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", "description": "Default value. Cannot be set when attribute is required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -8370,13 +8388,15 @@ "type": "integer", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", @@ -8389,7 +8409,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8494,7 +8515,8 @@ "type": "string", "description": "Default value. Cannot be set when attribute is required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -8613,7 +8635,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -8832,7 +8855,8 @@ "type": "string", "description": "New attribute key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9050,7 +9074,8 @@ "type": "string", "description": "New attribute key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9268,7 +9293,8 @@ "type": "string", "description": "New attribute key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9386,13 +9412,15 @@ "type": "string", "description": "Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "twoWayKey": { "type": "string", "description": "Two Way Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "onDelete": { "type": "string", @@ -9516,7 +9544,8 @@ "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", "default": null, - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -9642,13 +9671,15 @@ "type": "integer", "description": "Maximum size of the string attribute.", "default": null, - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "newKey": { "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -9753,7 +9784,8 @@ "type": "string", "description": "Default value for attribute when not provided. Cannot be set when attribute is required.", "default": null, - "x-example": "https:\/\/example.com" + "x-example": "https:\/\/example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -9872,7 +9904,8 @@ "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -10163,13 +10196,15 @@ "setNull" ], "x-enum-name": "RelationMutate", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true }, "newKey": { "type": "string", "description": "New Attribute Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -10445,6 +10480,7 @@ "description": "An array of permissions strings. By default, only the current user is granted all permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -10462,7 +10498,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -10593,7 +10630,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -10699,7 +10737,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -10796,7 +10835,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11041,6 +11081,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -11049,7 +11090,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -11157,6 +11199,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -11165,7 +11208,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11258,7 +11302,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11372,13 +11417,15 @@ "type": "number", "description": "Minimum value for the attribute. If the current value is lesser than this value, an exception will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -11492,13 +11539,15 @@ "type": "number", "description": "Maximum value for the attribute. If the current value is greater than this value, an error will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -13721,7 +13770,8 @@ "type": "string", "description": "Scheduled execution time in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future with precision in minutes.", "default": null, - "x-example": "<SCHEDULED_AT>" + "x-example": "<SCHEDULED_AT>", + "x-nullable": true } } } @@ -14163,13 +14213,15 @@ "type": "string", "description": "Variable value. Max length: 8192 chars.", "default": null, - "x-example": "<VALUE>" + "x-example": "<VALUE>", + "x-nullable": true }, "secret": { "type": "boolean", "description": "Secret variables can be updated or deleted, but only functions can read them during build and runtime.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -16331,7 +16383,8 @@ "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -16415,6 +16468,7 @@ "description": "List of Topic IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -16424,6 +16478,7 @@ "description": "List of User IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -16433,6 +16488,7 @@ "description": "List of Targets IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -16441,31 +16497,36 @@ "type": "string", "description": "Email Subject.", "default": null, - "x-example": "<SUBJECT>" + "x-example": "<SUBJECT>", + "x-nullable": true }, "content": { "type": "string", "description": "Email Content.", "default": null, - "x-example": "<CONTENT>" + "x-example": "<CONTENT>", + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "html": { "type": "boolean", "description": "Is content of type HTML", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "cc": { "type": "array", "description": "Array of target IDs to be added as CC.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -16475,6 +16536,7 @@ "description": "Array of target IDs to be added as BCC.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -16483,13 +16545,15 @@ "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "attachments": { "type": "array", "description": "Array of compound ID strings of bucket IDs and file IDs to be attached to the email. They should be formatted as <BUCKET_ID>:<FILE_ID>.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -16607,7 +16671,8 @@ "type": "object", "description": "Additional key-value pair data for push notification.", "default": {}, - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "action": { "type": "string", @@ -16661,7 +16726,8 @@ "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "contentAvailable": { "type": "boolean", @@ -16767,6 +16833,7 @@ "description": "List of Topic IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -16776,6 +16843,7 @@ "description": "List of User IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -16785,6 +16853,7 @@ "description": "List of Targets IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -16793,85 +16862,99 @@ "type": "string", "description": "Title for push notification.", "default": null, - "x-example": "<TITLE>" + "x-example": "<TITLE>", + "x-nullable": true }, "body": { "type": "string", "description": "Body for push notification.", "default": null, - "x-example": "<BODY>" + "x-example": "<BODY>", + "x-nullable": true }, "data": { "type": "object", "description": "Additional Data for push notification.", "default": {}, - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "action": { "type": "string", "description": "Action for push notification.", "default": null, - "x-example": "<ACTION>" + "x-example": "<ACTION>", + "x-nullable": true }, "image": { "type": "string", "description": "Image for push notification. Must be a compound bucket ID to file ID of a jpeg, png, or bmp image in Appwrite Storage. It should be formatted as <BUCKET_ID>:<FILE_ID>.", "default": null, - "x-example": "<ID1:ID2>" + "x-example": "<ID1:ID2>", + "x-nullable": true }, "icon": { "type": "string", "description": "Icon for push notification. Available only for Android and Web platforms.", "default": null, - "x-example": "<ICON>" + "x-example": "<ICON>", + "x-nullable": true }, "sound": { "type": "string", "description": "Sound for push notification. Available only for Android and iOS platforms.", "default": null, - "x-example": "<SOUND>" + "x-example": "<SOUND>", + "x-nullable": true }, "color": { "type": "string", "description": "Color for push notification. Available only for Android platforms.", "default": null, - "x-example": "<COLOR>" + "x-example": "<COLOR>", + "x-nullable": true }, "tag": { "type": "string", "description": "Tag for push notification. Available only for Android platforms.", "default": null, - "x-example": "<TAG>" + "x-example": "<TAG>", + "x-nullable": true }, "badge": { "type": "integer", "description": "Badge for push notification. Available only for iOS platforms.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "contentAvailable": { "type": "boolean", "description": "If set to true, the notification will be delivered in the background. Available only for iOS Platform.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "critical": { "type": "boolean", "description": "If set to true, the notification will be marked as critical. This requires the app to have the critical notification entitlement. Available only for iOS Platform.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "priority": { "type": "string", @@ -16883,7 +16966,8 @@ "high" ], "x-enum-name": "MessagePriority", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true } } } @@ -17068,7 +17152,8 @@ "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -17219,6 +17304,7 @@ "description": "List of Topic IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17228,6 +17314,7 @@ "description": "List of User IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17237,6 +17324,7 @@ "description": "List of Targets IDs.", "default": null, "x-example": null, + "x-nullable": true, "items": { "type": "string" } @@ -17245,19 +17333,22 @@ "type": "string", "description": "Email Content.", "default": null, - "x-example": "<CONTENT>" + "x-example": "<CONTENT>", + "x-nullable": true }, "draft": { "type": "boolean", "description": "Is message a draft", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "scheduledAt": { "type": "string", "description": "Scheduled delivery time for message in [ISO 8601](https:\/\/www.iso.org\/iso-8601-date-and-time-format.html) format. DateTime value must be in future.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -17805,7 +17896,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -17963,7 +18055,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "authKey": { "type": "string", @@ -17993,7 +18086,8 @@ "type": "boolean", "description": "Use APNS sandbox environment.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } } } @@ -18139,13 +18233,15 @@ "type": "object", "description": "FCM service account JSON.", "default": {}, - "x-example": "{}" + "x-example": "{}", + "x-nullable": true }, "enabled": { "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -18295,13 +18391,15 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "serviceAccountJSON": { "type": "object", "description": "FCM service account JSON.", "default": {}, - "x-example": "{}" + "x-example": "{}", + "x-nullable": true } } } @@ -18395,7 +18493,8 @@ "type": "boolean", "description": "Set as EU region.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "fromName": { "type": "string", @@ -18425,7 +18524,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -18525,13 +18625,15 @@ "type": "boolean", "description": "Set as EU region.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "enabled": { "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "fromName": { "type": "string", @@ -18655,7 +18757,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -18743,7 +18846,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "templateId": { "type": "string", @@ -18873,7 +18977,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -18961,7 +19066,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -19103,7 +19209,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19191,7 +19298,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -19462,7 +19570,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19639,7 +19748,8 @@ "type": "integer", "description": "SMTP port.", "default": null, - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "username": { "type": "string", @@ -19670,7 +19780,8 @@ "type": "boolean", "description": "Enable SMTP AutoTLS feature.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "mailer": { "type": "string", @@ -19706,7 +19817,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } } } @@ -19806,7 +19918,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -19894,7 +20007,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "customerId": { "type": "string", @@ -20012,7 +20126,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20100,7 +20215,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "username": { "type": "string", @@ -20218,7 +20334,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20306,7 +20423,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "accountSid": { "type": "string", @@ -20424,7 +20542,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -20512,7 +20631,8 @@ "type": "boolean", "description": "Set as enabled.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "apiKey": { "type": "string", @@ -21120,13 +21240,15 @@ "type": "string", "description": "Topic Name.", "default": null, - "x-example": "<NAME>" + "x-example": "<NAME>", + "x-nullable": true }, "subscribe": { "type": "array", "description": "An array of role strings with subscribe permission. By default all users are granted with any subscribe permission. [learn more about roles](https:\/\/appwrite.io\/docs\/permissions#permission-roles). Maximum of 100 roles are allowed, each 64 characters long.", "default": null, "x-example": "[\"any\"]", + "x-nullable": true, "items": { "type": "string" } @@ -23782,13 +23904,15 @@ "type": "string", "description": "Variable value. Max length: 8192 chars.", "default": null, - "x-example": "<VALUE>" + "x-example": "<VALUE>", + "x-nullable": true }, "secret": { "type": "boolean", "description": "Secret variables can be updated or deleted, but only sites can read them during build and runtime.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true } }, "required": [ @@ -24016,6 +24140,7 @@ "description": "An array of permission strings. By default, no user is granted with any permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -24216,6 +24341,7 @@ "description": "An array of permission strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -24669,13 +24795,15 @@ "type": "string", "description": "Name of the file", "default": null, - "x-example": "<NAME>" + "x-example": "<NAME>", + "x-nullable": true }, "permissions": { "type": "array", "description": "An array of permission string. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -26103,6 +26231,7 @@ "description": "An array of permissions strings. By default, no user is granted with any permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -26285,6 +26414,7 @@ "description": "An array of permission strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -26560,7 +26690,8 @@ "type": "boolean", "description": "Default value for column when not provided. Cannot be set when column is required.", "default": null, - "x-example": false + "x-example": false, + "x-nullable": true }, "array": { "type": "boolean", @@ -26678,7 +26809,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -26900,7 +27032,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -27004,7 +27137,8 @@ "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", "default": null, - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -27122,7 +27256,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -27235,7 +27370,8 @@ "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", "default": null, - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -27363,7 +27499,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -27468,19 +27605,22 @@ "type": "number", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", "description": "Default value. Cannot be set when required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -27591,13 +27731,15 @@ "type": "number", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "number", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "number", @@ -27610,7 +27752,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -27714,19 +27857,22 @@ "type": "integer", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", "description": "Default value. Cannot be set when column is required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -27837,13 +27983,15 @@ "type": "integer", "description": "Minimum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "max": { "type": "integer", "description": "Maximum value", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "default": { "type": "integer", @@ -27856,7 +28004,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -27960,7 +28109,8 @@ "type": "string", "description": "Default value. Cannot be set when column is required.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "array": { "type": "boolean", @@ -28078,7 +28228,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -28295,7 +28446,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -28511,7 +28663,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -28727,7 +28880,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -28844,13 +28998,15 @@ "type": "string", "description": "Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "twoWayKey": { "type": "string", "description": "Two Way Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "onDelete": { "type": "string", @@ -28973,7 +29129,8 @@ "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", "default": null, - "x-example": "<DEFAULT>" + "x-example": "<DEFAULT>", + "x-nullable": true }, "array": { "type": "boolean", @@ -29098,13 +29255,15 @@ "type": "integer", "description": "Maximum size of the string column.", "default": null, - "x-example": 1 + "x-example": 1, + "x-nullable": true }, "newKey": { "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -29208,7 +29367,8 @@ "type": "string", "description": "Default value for column when not provided. Cannot be set when column is required.", "default": null, - "x-example": "https:\/\/example.com" + "x-example": "https:\/\/example.com", + "x-nullable": true }, "array": { "type": "boolean", @@ -29326,7 +29486,8 @@ "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } }, "required": [ @@ -29614,13 +29775,15 @@ "setNull" ], "x-enum-name": "RelationMutate", - "x-enum-keys": [] + "x-enum-keys": [], + "x-nullable": true }, "newKey": { "type": "string", "description": "New Column Key.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true } } } @@ -30261,6 +30424,7 @@ "description": "An array of permissions strings. By default, only the current user is granted all permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -30278,7 +30442,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -30404,7 +30569,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } }, "required": [ @@ -30509,7 +30675,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -30605,7 +30772,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -30843,6 +31011,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -30851,7 +31020,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -30955,6 +31125,7 @@ "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", "default": null, "x-example": "[\"read(\"any\")\"]", + "x-nullable": true, "items": { "type": "string" } @@ -30963,7 +31134,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -31055,7 +31227,8 @@ "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -31168,13 +31341,15 @@ "type": "number", "description": "Minimum value for the column. If the current value is lesser than this value, an exception will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -31287,13 +31462,15 @@ "type": "number", "description": "Maximum value for the column. If the current value is greater than this value, an error will be thrown.", "default": null, - "x-example": null + "x-example": null, + "x-nullable": true }, "transactionId": { "type": "string", "description": "Transaction ID for staging the operation.", "default": null, - "x-example": "<TRANSACTION_ID>" + "x-example": "<TRANSACTION_ID>", + "x-nullable": true } } } @@ -32870,13 +33047,15 @@ "type": "string", "description": "User email.", "default": null, - "x-example": "email@example.com" + "x-example": "email@example.com", + "x-nullable": true }, "phone": { "type": "string", "description": "Phone number. Format this number with a leading '+' and a country code, e.g., +16175551212.", "default": null, - "x-example": "+12065550100" + "x-example": "+12065550100", + "x-nullable": true }, "password": { "type": "string", diff --git a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Delete.php b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Delete.php index 88f22c2594..d8f50a5578 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Delete.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/Databases/Collections/Documents/Delete.php @@ -21,6 +21,7 @@ use Utopia\Database\Helpers\ID; use Utopia\Database\Validator\Authorization; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; +use Utopia\Validator\Nullable; class Delete extends Action { diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Delete.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Delete.php index d18a81c1af..4c8b599c8c 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Delete.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Rows/Delete.php @@ -10,6 +10,7 @@ use Appwrite\SDK\Response as SDKResponse; use Appwrite\Utopia\Response as UtopiaResponse; use Utopia\Database\Validator\UID; use Utopia\Swoole\Response as SwooleResponse; +use Utopia\Validator\Nullable; class Delete extends DocumentDelete { From 74492ded447f8eae3b66709504b02f74688477d3 Mon Sep 17 00:00:00 2001 From: Chirag Aggarwal <chiragaggarwal5k@gmail.com> Date: Mon, 10 Nov 2025 11:35:25 +0530 Subject: [PATCH 23/24] update description --- .../Platform/Modules/Databases/Http/TablesDB/Tables/Update.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Update.php b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Update.php index a6cb611870..a4bfb5bf23 100644 --- a/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Update.php +++ b/src/Appwrite/Platform/Modules/Databases/Http/TablesDB/Tables/Update.php @@ -57,7 +57,7 @@ class Update extends CollectionUpdate ->param('tableId', '', new UID(), 'Table ID.') ->param('name', null, new Text(128), 'Table name. Max length: 128 chars.') ->param('permissions', null, new Nullable(new Permissions(APP_LIMIT_ARRAY_PARAMS_SIZE)), 'An array of permission strings. By default, the current permissions are inherited. [Learn more about permissions](https://appwrite.io/docs/permissions).', true) - ->param('rowSecurity', false, new Boolean(true), '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).', true) + ->param('rowSecurity', false, new Boolean(true), '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).', true) ->param('enabled', true, new Boolean(), 'Is table enabled? When set to \'disabled\', users cannot access the table but Server SDKs with and API key can still read and write to the table. No data is lost when this is toggled.', true) ->inject('response') ->inject('dbForProject') From d411b741b32c810b02999ffc7a3c60833c49ab9f Mon Sep 17 00:00:00 2001 From: Atharva Deosthale <atharva.deosthale17@gmail.com> Date: Wed, 12 Nov 2025 23:06:18 +0530 Subject: [PATCH 24/24] address comments --- .../Modules/Functions/Http/Deployments/Template/Create.php | 3 ++- .../Modules/Sites/Http/Deployments/Template/Create.php | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/Appwrite/Platform/Modules/Functions/Http/Deployments/Template/Create.php b/src/Appwrite/Platform/Modules/Functions/Http/Deployments/Template/Create.php index 5e0266a09e..2f150dbe18 100644 --- a/src/Appwrite/Platform/Modules/Functions/Http/Deployments/Template/Create.php +++ b/src/Appwrite/Platform/Modules/Functions/Http/Deployments/Template/Create.php @@ -103,7 +103,8 @@ class Create extends Base throw new Exception(Exception::FUNCTION_NOT_FOUND); } - $branchUrl = $type == GitHub::CLONE_TYPE_BRANCH ? "https://github.com/$owner/$repository/tree/$reference" : ""; + $branchUrl = "https://github.com/$owner/$repository/blob/$reference"; + $repositoryUrl = "https://github.com/$owner/$repository"; $template = new Document([ diff --git a/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Template/Create.php b/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Template/Create.php index d7196eb3d5..d55d09584d 100644 --- a/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Template/Create.php +++ b/src/Appwrite/Platform/Modules/Sites/Http/Deployments/Template/Create.php @@ -105,7 +105,7 @@ class Create extends Base throw new Exception(Exception::SITE_NOT_FOUND); } - $branchUrl = $type == GitHub::CLONE_TYPE_BRANCH ? "https://github.com/$owner/$repository/tree/$reference" : ""; + $branchUrl = "https://github.com/$owner/$repository/blob/$reference"; $repositoryUrl = "https://github.com/$owner/$repository"; $template = new Document([