From ba23fe449c0327c8ac6bdb6902bc3b25d2b98204 Mon Sep 17 00:00:00 2001 From: Darshan Date: Thu, 8 Jan 2026 17:43:43 +0530 Subject: [PATCH] specs. --- app/config/specs/open-api3-latest-client.json | 1394 ++++++- .../specs/open-api3-latest-console.json | 3021 +++++++++++++-- app/config/specs/open-api3-latest-server.json | 3366 ++++++++++++++++- app/config/specs/swagger2-latest-client.json | 270 +- app/config/specs/swagger2-latest-console.json | 2960 +++++++++++++-- app/config/specs/swagger2-latest-server.json | 3284 +++++++++++++++- 6 files changed, 13351 insertions(+), 944 deletions(-) diff --git a/app/config/specs/open-api3-latest-client.json b/app/config/specs/open-api3-latest-client.json index fd35c3b73c..95f9d4c342 100644 --- a/app/config/specs/open-api3-latest-client.json +++ b/app/config/specs/open-api3-latest-client.json @@ -7294,6 +7294,1378 @@ } } }, + "\/documentsdb\/transactions": { + "get": { + "summary": "List transactions", + "operationId": "documentsDBListTransactions", + "tags": [ + "documentsDB" + ], + "description": false, + "responses": { + "200": { + "description": "Transaction List", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/transactionList" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "listTransactions", + "group": "transactions", + "weight": 463, + "cookies": false, + "type": "", + "demo": "documentsdb\/list-transactions.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.read", + "platforms": [ + "server", + "client", + "server" + ], + "packaging": false, + "public": true, + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries).", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + }, + "default": [] + }, + "in": "query" + } + ] + }, + "post": { + "summary": "Create transaction", + "operationId": "documentsDBCreateTransaction", + "tags": [ + "documentsDB" + ], + "description": false, + "responses": { + "201": { + "description": "Transaction", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/transaction" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "createTransaction", + "group": "transactions", + "weight": 459, + "cookies": false, + "type": "", + "demo": "documentsdb\/create-transaction.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.write", + "platforms": [ + "server", + "client", + "server" + ], + "packaging": false, + "public": true, + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "JWT": [] + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "ttl": { + "type": "integer", + "description": "Seconds before the transaction expires.", + "x-example": 60 + } + } + } + } + } + } + } + }, + "\/documentsdb\/transactions\/{transactionId}": { + "get": { + "summary": "Get transaction", + "operationId": "documentsDBGetTransaction", + "tags": [ + "documentsDB" + ], + "description": false, + "responses": { + "200": { + "description": "Transaction", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/transaction" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "getTransaction", + "group": "transactions", + "weight": 460, + "cookies": false, + "type": "", + "demo": "documentsdb\/get-transaction.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.read", + "platforms": [ + "server", + "client", + "server" + ], + "packaging": false, + "public": true, + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "transactionId", + "description": "Transaction ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ] + }, + "patch": { + "summary": "Update transaction", + "operationId": "documentsDBUpdateTransaction", + "tags": [ + "documentsDB" + ], + "description": false, + "responses": { + "200": { + "description": "Transaction", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/transaction" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "updateTransaction", + "group": "transactions", + "weight": 461, + "cookies": false, + "type": "", + "demo": "documentsdb\/update-transaction.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.write", + "platforms": [ + "server", + "client", + "server" + ], + "packaging": false, + "public": true, + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "transactionId", + "description": "Transaction ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "commit": { + "type": "boolean", + "description": "Commit transaction?", + "x-example": false + }, + "rollback": { + "type": "boolean", + "description": "Rollback transaction?", + "x-example": false + } + } + } + } + } + } + }, + "delete": { + "summary": "Delete transaction", + "operationId": "documentsDBDeleteTransaction", + "tags": [ + "documentsDB" + ], + "description": false, + "responses": { + "204": { + "description": "No content" + } + }, + "deprecated": false, + "x-appwrite": { + "method": "deleteTransaction", + "group": "transactions", + "weight": 462, + "cookies": false, + "type": "", + "demo": "documentsdb\/delete-transaction.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.write", + "platforms": [ + "server", + "client", + "server" + ], + "packaging": false, + "public": true, + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "transactionId", + "description": "Transaction ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ] + } + }, + "\/documentsdb\/transactions\/{transactionId}\/operations": { + "post": { + "summary": "Create operations", + "operationId": "documentsDBCreateOperations", + "tags": [ + "documentsDB" + ], + "description": false, + "responses": { + "201": { + "description": "Transaction", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/transaction" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "createOperations", + "group": "transactions", + "weight": 464, + "cookies": false, + "type": "", + "demo": "documentsdb\/create-operations.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.write", + "platforms": [ + "server", + "client", + "server" + ], + "packaging": false, + "public": true, + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "transactionId", + "description": "Transaction ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "operations": { + "type": "array", + "description": "Array of staged operations.", + "x-example": "[\n\t {\n\t \"action\": \"create\",\n\t \"databaseId\": \"\",\n\t \"collectionId\": \"\",\n\t \"documentId\": \"\",\n\t \"data\": {\n\t \"name\": \"Walter O'Brien\"\n\t }\n\t }\n\t]", + "items": { + "type": "object" + } + } + } + } + } + } + } + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/documents": { + "get": { + "summary": "List documents", + "operationId": "documentsDBListDocuments", + "tags": [ + "documentsDB" + ], + "description": "Get a list of all the user's documents in a given collection. You can use the query params to filter your results.", + "responses": { + "200": { + "description": "Documents List", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/documentList" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "listDocuments", + "group": "documents", + "weight": 455, + "cookies": false, + "type": "", + "demo": "documentsdb\/list-documents.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.read", + "platforms": [ + "client", + "server", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/list-documents.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long.", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + }, + "default": [] + }, + "in": "query" + }, + { + "name": "transactionId", + "description": "Transaction ID to read uncommitted changes within the transaction.", + "required": false, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "query" + }, + { + "name": "total", + "description": "When set to false, the total count returned will be 0 and will not be calculated.", + "required": false, + "schema": { + "type": "boolean", + "x-example": false, + "default": true + }, + "in": "query" + } + ] + }, + "post": { + "summary": "Create document", + "operationId": "documentsDBCreateDocument", + "tags": [ + "documentsDB" + ], + "description": "Create a new Document. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.", + "responses": { + "201": { + "description": "Document", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/document" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "createDocument", + "group": "documents", + "weight": 447, + "cookies": false, + "type": "", + "demo": "documentsdb\/create-document.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/create-document.md", + "methods": [ + { + "name": "createDocument", + "namespace": "documentsDB", + "desc": "Create document", + "auth": { + "Project": [] + }, + "parameters": [ + "databaseId", + "collectionId", + "documentId", + "data", + "permissions" + ], + "required": [ + "databaseId", + "collectionId", + "documentId", + "data" + ], + "responses": [ + { + "code": 201, + "model": "#\/components\/schemas\/document" + } + ], + "description": "Create a new Document. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.", + "demo": "documentsdb\/create-document.md", + "public": true + } + ], + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "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.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "documentId": { + "type": "string", + "description": "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.", + "x-example": "" + }, + "data": { + "type": "object", + "description": "Document data as JSON object.", + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" + }, + "permissions": { + "type": "array", + "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).", + "x-example": "[\"read(\"any\")\"]", + "items": { + "type": "string" + } + }, + "documents": { + "type": "array", + "description": "Array of documents data as JSON objects.", + "x-example": null, + "items": { + "type": "object" + } + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "x-example": "" + } + } + } + } + } + } + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/documents\/{documentId}": { + "get": { + "summary": "Get document", + "operationId": "documentsDBGetDocument", + "tags": [ + "documentsDB" + ], + "description": "Get a document by its unique ID. This endpoint response returns a JSON object with the document data.", + "responses": { + "200": { + "description": "Document", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/document" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "getDocument", + "group": "documents", + "weight": 448, + "cookies": false, + "type": "", + "demo": "documentsdb\/get-document.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.read", + "platforms": [ + "client", + "server", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/get-document.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long.", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + }, + "default": [] + }, + "in": "query" + }, + { + "name": "transactionId", + "description": "Transaction ID to read uncommitted changes within the transaction.", + "required": false, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "query" + } + ] + }, + "put": { + "summary": "Upsert a document", + "operationId": "documentsDBUpsertDocument", + "tags": [ + "documentsDB" + ], + "description": "Create or update a Document. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.", + "responses": { + "201": { + "description": "Document", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/document" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "upsertDocument", + "group": "documents", + "weight": 451, + "cookies": false, + "type": "", + "demo": "documentsdb\/upsert-document.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/upsert-document.md", + "methods": [ + { + "name": "upsertDocument", + "namespace": "documentsDB", + "desc": "", + "auth": { + "Project": [] + }, + "parameters": [ + "databaseId", + "collectionId", + "documentId", + "data", + "permissions", + "transactionId" + ], + "required": [ + "databaseId", + "collectionId", + "documentId" + ], + "responses": [ + { + "code": 201, + "model": "#\/components\/schemas\/document" + } + ], + "description": "Create or update a Document. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.", + "demo": "documentsdb\/upsert-document.md", + "public": true + } + ], + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "data": { + "type": "object", + "description": "Document data as JSON object. Include all required fields of the document to be created or updated.", + "x-example": "{}" + }, + "permissions": { + "type": "array", + "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", + "x-example": "[\"read(\"any\")\"]", + "items": { + "type": "string" + } + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "x-example": "" + } + } + } + } + } + } + }, + "patch": { + "summary": "Update document", + "operationId": "documentsDBUpdateDocument", + "tags": [ + "documentsDB" + ], + "description": "Update a document by its unique ID. Using the patch method you can pass only specific fields that will get updated.", + "responses": { + "200": { + "description": "Document", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/document" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "updateDocument", + "group": "documents", + "weight": 449, + "cookies": false, + "type": "", + "demo": "documentsdb\/update-document.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/update-document.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "data": { + "type": "object", + "description": "Document data as JSON object. Include only fields and value pairs to be updated.", + "x-example": "{}" + }, + "permissions": { + "type": "array", + "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", + "x-example": "[\"read(\"any\")\"]", + "items": { + "type": "string" + } + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "x-example": "" + } + } + } + } + } + } + }, + "delete": { + "summary": "Delete document", + "operationId": "documentsDBDeleteDocument", + "tags": [ + "documentsDB" + ], + "description": "Delete a document by its unique ID.", + "responses": { + "204": { + "description": "No content" + } + }, + "deprecated": false, + "x-appwrite": { + "method": "deleteDocument", + "group": "documents", + "weight": 453, + "cookies": false, + "type": "", + "demo": "documentsdb\/delete-document.md", + "rate-limit": 60, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/delete-document.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "x-example": "" + } + } + } + } + } + } + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/documents\/{documentId}\/{attribute}\/decrement": { + "patch": { + "summary": "Decrement document attribute", + "operationId": "documentsDBDecrementDocumentAttribute", + "tags": [ + "documentsDB" + ], + "description": "Decrement a specific column of a row by a given value.", + "responses": { + "200": { + "description": "Document", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/document" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "decrementDocumentAttribute", + "group": "documents", + "weight": 458, + "cookies": false, + "type": "", + "demo": "documentsdb\/decrement-document-attribute.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server", + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/decrement-document-attribute.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "attribute", + "description": "Attribute key.", + "required": true, + "schema": { + "type": "string" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "value": { + "type": "number", + "description": "Value to decrement the attribute by. The value must be a number.", + "x-example": null + }, + "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 + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "x-example": "" + } + } + } + } + } + } + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/documents\/{documentId}\/{attribute}\/increment": { + "patch": { + "summary": "Increment document attribute", + "operationId": "documentsDBIncrementDocumentAttribute", + "tags": [ + "documentsDB" + ], + "description": "Increment a specific column of a row by a given value.", + "responses": { + "200": { + "description": "Document", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/document" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "incrementDocumentAttribute", + "group": "documents", + "weight": 457, + "cookies": false, + "type": "", + "demo": "documentsdb\/increment-document-attribute.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server", + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/increment-document-attribute.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "attribute", + "description": "Attribute key.", + "required": true, + "schema": { + "type": "string" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "value": { + "type": "number", + "description": "Value to increment the attribute by. The value must be a number.", + "x-example": null + }, + "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 + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "x-example": "" + } + } + } + } + } + } + } + }, "\/functions\/{functionId}\/executions": { "get": { "summary": "List executions", @@ -7318,7 +8690,7 @@ "x-appwrite": { "method": "listExecutions", "group": "executions", - "weight": 455, + "weight": 491, "cookies": false, "type": "", "demo": "functions\/list-executions.md", @@ -7405,7 +8777,7 @@ "x-appwrite": { "method": "createExecution", "group": "executions", - "weight": 453, + "weight": 489, "cookies": false, "type": "", "demo": "functions\/create-execution.md", @@ -7523,7 +8895,7 @@ "x-appwrite": { "method": "getExecution", "group": "executions", - "weight": 454, + "weight": 490, "cookies": false, "type": "", "demo": "functions\/get-execution.md", @@ -8298,7 +9670,7 @@ "x-appwrite": { "method": "listFiles", "group": "files", - "weight": 526, + "weight": 562, "cookies": false, "type": "", "demo": "storage\/list-files.md", @@ -8397,7 +9769,7 @@ "x-appwrite": { "method": "createFile", "group": "files", - "weight": 524, + "weight": 560, "cookies": false, "type": "upload", "demo": "storage\/create-file.md", @@ -8498,7 +9870,7 @@ "x-appwrite": { "method": "getFile", "group": "files", - "weight": 525, + "weight": 561, "cookies": false, "type": "", "demo": "storage\/get-file.md", @@ -8572,7 +9944,7 @@ "x-appwrite": { "method": "updateFile", "group": "files", - "weight": 527, + "weight": 563, "cookies": false, "type": "", "demo": "storage\/update-file.md", @@ -8664,7 +10036,7 @@ "x-appwrite": { "method": "deleteFile", "group": "files", - "weight": 528, + "weight": 564, "cookies": false, "type": "", "demo": "storage\/delete-file.md", @@ -8733,7 +10105,7 @@ "x-appwrite": { "method": "getFileDownload", "group": "files", - "weight": 530, + "weight": 566, "cookies": false, "type": "location", "demo": "storage\/get-file-download.md", @@ -8813,7 +10185,7 @@ "x-appwrite": { "method": "getFilePreview", "group": "files", - "weight": 529, + "weight": 565, "cookies": false, "type": "location", "demo": "storage\/get-file-preview.md", @@ -9043,7 +10415,7 @@ "x-appwrite": { "method": "getFileView", "group": "files", - "weight": 531, + "weight": 567, "cookies": false, "type": "location", "demo": "storage\/get-file-view.md", diff --git a/app/config/specs/open-api3-latest-console.json b/app/config/specs/open-api3-latest-console.json index 952f83af6d..13b1af3af9 100644 --- a/app/config/specs/open-api3-latest-console.json +++ b/app/config/specs/open-api3-latest-console.json @@ -5862,7 +5862,7 @@ "x-appwrite": { "method": "chat", "group": "console", - "weight": 496, + "weight": 532, "cookies": false, "type": "", "demo": "assistant\/chat.md", @@ -5923,7 +5923,7 @@ "x-appwrite": { "method": "getResource", "group": null, - "weight": 497, + "weight": 533, "cookies": false, "type": "", "demo": "console\/get-resource.md", @@ -5998,7 +5998,7 @@ "x-appwrite": { "method": "variables", "group": "console", - "weight": 495, + "weight": 531, "cookies": false, "type": "", "demo": "console\/variables.md", @@ -10221,6 +10221,122 @@ } } }, + "\/databases\/{databaseId}\/collections\/{collectionId}\/attributes\/relationship\/{key}": { + "patch": { + "summary": "Update relationship attribute", + "operationId": "databasesUpdateRelationshipAttribute", + "tags": [ + "databases" + ], + "description": "Update relationship attribute. [Learn more about relationship attributes](https:\/\/appwrite.io\/docs\/databases-relationships#relationship-attributes).\n", + "responses": { + "200": { + "description": "AttributeRelationship", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/attributeRelationship" + } + } + } + } + }, + "deprecated": true, + "x-appwrite": { + "method": "updateRelationshipAttribute", + "group": "attributes", + "weight": 349, + "cookies": false, + "type": "", + "demo": "databases\/update-relationship-attribute.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/databases\/update-relationship-attribute.md", + "deprecated": { + "since": "1.8.0", + "replaceWith": "tablesDB.updateRelationshipColumn" + }, + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "key", + "description": "Attribute Key.", + "required": true, + "schema": { + "type": "string" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "onDelete": { + "type": "string", + "description": "Constraints option", + "x-example": "cascade", + "enum": [ + "cascade", + "restrict", + "setNull" + ], + "x-enum-name": "RelationMutate", + "x-enum-keys": [], + "x-nullable": true + }, + "newKey": { + "type": "string", + "description": "New Attribute Key.", + "x-example": null, + "x-nullable": true + } + } + } + } + } + } + } + }, "\/databases\/{databaseId}\/collections\/{collectionId}\/attributes\/string": { "post": { "summary": "Create string attribute", @@ -10894,122 +11010,6 @@ ] } }, - "\/databases\/{databaseId}\/collections\/{collectionId}\/attributes\/{key}\/relationship": { - "patch": { - "summary": "Update relationship attribute", - "operationId": "databasesUpdateRelationshipAttribute", - "tags": [ - "databases" - ], - "description": "Update relationship attribute. [Learn more about relationship attributes](https:\/\/appwrite.io\/docs\/databases-relationships#relationship-attributes).\n", - "responses": { - "200": { - "description": "AttributeRelationship", - "content": { - "application\/json": { - "schema": { - "$ref": "#\/components\/schemas\/attributeRelationship" - } - } - } - } - }, - "deprecated": true, - "x-appwrite": { - "method": "updateRelationshipAttribute", - "group": "attributes", - "weight": 349, - "cookies": false, - "type": "", - "demo": "databases\/update-relationship-attribute.md", - "rate-limit": 0, - "rate-time": 3600, - "rate-key": "url:{url},ip:{ip}", - "scope": "collections.write", - "platforms": [ - "console", - "server" - ], - "packaging": false, - "public": true, - "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/databases\/update-relationship-attribute.md", - "deprecated": { - "since": "1.8.0", - "replaceWith": "tablesDB.updateRelationshipColumn" - }, - "auth": { - "Project": [] - } - }, - "security": [ - { - "Project": [], - "Key": [] - } - ], - "parameters": [ - { - "name": "databaseId", - "description": "Database ID.", - "required": true, - "schema": { - "type": "string", - "x-example": "" - }, - "in": "path" - }, - { - "name": "collectionId", - "description": "Collection ID.", - "required": true, - "schema": { - "type": "string", - "x-example": "" - }, - "in": "path" - }, - { - "name": "key", - "description": "Attribute Key.", - "required": true, - "schema": { - "type": "string" - }, - "in": "path" - } - ], - "requestBody": { - "content": { - "application\/json": { - "schema": { - "type": "object", - "properties": { - "onDelete": { - "type": "string", - "description": "Constraints option", - "x-example": "cascade", - "enum": [ - "cascade", - "restrict", - "setNull" - ], - "x-enum-name": "RelationMutate", - "x-enum-keys": [], - "x-nullable": true - }, - "newKey": { - "type": "string", - "description": "New Attribute Key.", - "x-example": null, - "x-nullable": true - } - } - } - } - } - } - } - }, "\/databases\/{databaseId}\/collections\/{collectionId}\/documents": { "get": { "summary": "List documents", @@ -11214,6 +11214,7 @@ "databaseId", "collectionId", "documents", + "transactionId", "transactionId" ], "required": [ @@ -13307,6 +13308,2412 @@ ] } }, + "\/documentsdb": { + "get": { + "summary": "List databases", + "operationId": "documentsDBList", + "tags": [ + "documentsDB" + ], + "description": "Get a list of all databases from the current Appwrite project. You can use the search parameter to filter your results.", + "responses": { + "200": { + "description": "Databases List", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/databaseList" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "list", + "group": "documentsdb", + "weight": 433, + "cookies": false, + "type": "", + "demo": "documentsdb\/list.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "databases.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/list.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following columns: name", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + }, + "default": [] + }, + "in": "query" + }, + { + "name": "search", + "description": "Search term to filter your list results. Max length: 256 chars.", + "required": false, + "schema": { + "type": "string", + "x-example": "", + "default": "" + }, + "in": "query" + }, + { + "name": "total", + "description": "When set to false, the total count returned will be 0 and will not be calculated.", + "required": false, + "schema": { + "type": "boolean", + "x-example": false, + "default": true + }, + "in": "query" + } + ] + }, + "post": { + "summary": "Create database", + "operationId": "documentsDBCreate", + "tags": [ + "documentsDB" + ], + "description": "Create a new Database.\n", + "responses": { + "201": { + "description": "Database", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/database" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "create", + "group": "documentsdb", + "weight": 429, + "cookies": false, + "type": "", + "demo": "documentsdb\/create.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "databases.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/create.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "databaseId": { + "type": "string", + "description": "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.", + "x-example": "" + }, + "name": { + "type": "string", + "description": "Database name. Max length: 128 chars.", + "x-example": "" + }, + "enabled": { + "type": "boolean", + "description": "Is the database enabled? When set to 'disabled', users cannot access the database but Server SDKs with an API key can still read and write to the database. No data is lost when this is toggled.", + "x-example": false + } + }, + "required": [ + "databaseId", + "name" + ] + } + } + } + } + } + }, + "\/documentsdb\/usage": { + "get": { + "summary": "Get DocumentsDB usage stats", + "operationId": "documentsDBListUsage", + "tags": [ + "documentsDB" + ], + "description": "List usage metrics and statistics for all databases in the project. You can view the total number of databases, collections, documents, and storage usage. The response includes both current totals and historical data over time. Use the optional range parameter to specify the time window for historical data: 24h (last 24 hours), 30d (last 30 days), or 90d (last 90 days). If not specified, range defaults to 30 days.", + "responses": { + "200": { + "description": "UsageDatabases", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/usageDatabases" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "listUsage", + "group": null, + "weight": 435, + "cookies": false, + "type": "", + "demo": "documentsdb\/list-usage.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/list-usage.md", + "methods": [ + { + "name": "listUsage", + "namespace": "documentsDB", + "desc": "", + "auth": { + "Project": [] + }, + "parameters": [ + "range" + ], + "required": [], + "responses": [ + { + "code": 200, + "model": "#\/components\/schemas\/usageDatabases" + } + ], + "description": "List usage metrics and statistics for all databases in the project. You can view the total number of databases, collections, documents, and storage usage. The response includes both current totals and historical data over time. Use the optional range parameter to specify the time window for historical data: 24h (last 24 hours), 30d (last 30 days), or 90d (last 90 days). If not specified, range defaults to 30 days.", + "demo": "documentsdb\/list-usage.md", + "public": true + } + ], + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [] + } + ], + "parameters": [ + { + "name": "range", + "description": "Date range.", + "required": false, + "schema": { + "type": "string", + "x-example": "24h", + "enum": [ + "24h", + "30d", + "90d" + ], + "x-enum-name": "UsageRange", + "x-enum-keys": [ + "Twenty Four Hours", + "Thirty Days", + "Ninety Days" + ], + "default": "30d" + }, + "in": "query" + } + ] + } + }, + "\/documentsdb\/{databaseId}": { + "get": { + "summary": "Get database", + "operationId": "documentsDBGet", + "tags": [ + "documentsDB" + ], + "description": "Get a database by its unique ID. This endpoint response returns a JSON object with the database metadata.", + "responses": { + "200": { + "description": "Database", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/database" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "get", + "group": "documentsdb", + "weight": 430, + "cookies": false, + "type": "", + "demo": "documentsdb\/get.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "databases.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/get.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ] + }, + "put": { + "summary": "Update database", + "operationId": "documentsDBUpdate", + "tags": [ + "documentsDB" + ], + "description": "Update a database by its unique ID.", + "responses": { + "200": { + "description": "Database", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/database" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "update", + "group": "documentsdb", + "weight": 431, + "cookies": false, + "type": "", + "demo": "documentsdb\/update.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "databases.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/update.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "Database name. Max length: 128 chars.", + "x-example": "" + }, + "enabled": { + "type": "boolean", + "description": "Is database enabled? When set to 'disabled', users cannot access the database but Server SDKs with an API key can still read and write to the database. No data is lost when this is toggled.", + "x-example": false + } + }, + "required": [ + "name" + ] + } + } + } + } + }, + "delete": { + "summary": "Delete database", + "operationId": "documentsDBDelete", + "tags": [ + "documentsDB" + ], + "description": "Delete a database by its unique ID. Only API keys with with databases.write scope can delete a database.", + "responses": { + "204": { + "description": "No content" + } + }, + "deprecated": false, + "x-appwrite": { + "method": "delete", + "group": "documentsdb", + "weight": 432, + "cookies": false, + "type": "", + "demo": "documentsdb\/delete.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "databases.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/delete.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections": { + "get": { + "summary": "List collections", + "operationId": "documentsDBListCollections", + "tags": [ + "documentsDB" + ], + "description": "Get a list of all collections that belong to the provided databaseId. You can use the search parameter to filter your results.", + "responses": { + "200": { + "description": "Collections List", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/collectionList" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "listCollections", + "group": "collections", + "weight": 440, + "cookies": false, + "type": "", + "demo": "documentsdb\/list-collections.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/list-collections.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following attributes: name, enabled, documentSecurity", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + }, + "default": [] + }, + "in": "query" + }, + { + "name": "search", + "description": "Search term to filter your list results. Max length: 256 chars.", + "required": false, + "schema": { + "type": "string", + "x-example": "", + "default": "" + }, + "in": "query" + }, + { + "name": "total", + "description": "When set to false, the total count returned will be 0 and will not be calculated.", + "required": false, + "schema": { + "type": "boolean", + "x-example": false, + "default": true + }, + "in": "query" + } + ] + }, + "post": { + "summary": "Create collection", + "operationId": "documentsDBCreateCollection", + "tags": [ + "documentsDB" + ], + "description": "Create a new Collection. Before using this route, you should create a new database resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.", + "responses": { + "201": { + "description": "Collection", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/collection" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "createCollection", + "group": "collections", + "weight": 436, + "cookies": false, + "type": "", + "demo": "documentsdb\/create-collection.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/create-collection.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "collectionId": { + "type": "string", + "description": "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.", + "x-example": "" + }, + "name": { + "type": "string", + "description": "Collection name. Max length: 128 chars.", + "x-example": "" + }, + "permissions": { + "type": "array", + "description": "An array of permissions strings. By default, no user is granted with any permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", + "x-example": "[\"read(\"any\")\"]", + "items": { + "type": "string" + } + }, + "documentSecurity": { + "type": "boolean", + "description": "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).", + "x-example": false + }, + "enabled": { + "type": "boolean", + "description": "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.", + "x-example": false + }, + "attributes": { + "type": "array", + "description": "Array of attribute definitions to create. Each attribute should contain: key (string), type (string: string, integer, float, boolean, datetime, relationship), size (integer, required for string type), required (boolean, optional), default (mixed, optional), array (boolean, optional), and type-specific options.", + "x-example": null, + "items": { + "type": "object" + } + }, + "indexes": { + "type": "array", + "description": "Array of index definitions to create. Each index should contain: key (string), type (string: key, fulltext, unique, spatial), attributes (array of attribute keys), orders (array of ASC\/DESC, optional), and lengths (array of integers, optional).", + "x-example": null, + "items": { + "type": "object" + } + } + }, + "required": [ + "collectionId", + "name" + ] + } + } + } + } + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}": { + "get": { + "summary": "Get collection", + "operationId": "documentsDBGetCollection", + "tags": [ + "documentsDB" + ], + "description": "Get a collection by its unique ID. This endpoint response returns a JSON object with the collection metadata.", + "responses": { + "200": { + "description": "Collection", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/collection" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "getCollection", + "group": "collections", + "weight": 437, + "cookies": false, + "type": "", + "demo": "documentsdb\/get-collection.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/get-collection.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ] + }, + "put": { + "summary": "Update collection", + "operationId": "documentsDBUpdateCollection", + "tags": [ + "documentsDB" + ], + "description": "Update a collection by its unique ID.", + "responses": { + "200": { + "description": "Collection", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/collection" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "updateCollection", + "group": "collections", + "weight": 438, + "cookies": false, + "type": "", + "demo": "documentsdb\/update-collection.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/update-collection.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "Collection name. Max length: 128 chars.", + "x-example": "" + }, + "permissions": { + "type": "array", + "description": "An array of permission strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", + "x-example": "[\"read(\"any\")\"]", + "items": { + "type": "string" + } + }, + "documentSecurity": { + "type": "boolean", + "description": "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).", + "x-example": false + }, + "enabled": { + "type": "boolean", + "description": "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.", + "x-example": false + } + }, + "required": [ + "name" + ] + } + } + } + } + }, + "delete": { + "summary": "Delete collection", + "operationId": "documentsDBDeleteCollection", + "tags": [ + "documentsDB" + ], + "description": "Delete a collection by its unique ID. Only users with write permissions have access to delete this resource.", + "responses": { + "204": { + "description": "No content" + } + }, + "deprecated": false, + "x-appwrite": { + "method": "deleteCollection", + "group": "collections", + "weight": 439, + "cookies": false, + "type": "", + "demo": "documentsdb\/delete-collection.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/delete-collection.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/documents": { + "post": { + "summary": "Create document", + "operationId": "documentsDBCreateDocument", + "tags": [ + "documentsDB" + ], + "description": "Create a new Document. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.", + "responses": { + "201": { + "description": "Document", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/document" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "createDocument", + "group": "documents", + "weight": 447, + "cookies": false, + "type": "", + "demo": "documentsdb\/create-document.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/create-document.md", + "methods": [ + { + "name": "createDocuments", + "namespace": "documentsDB", + "desc": "Create documents", + "auth": { + "Project": [] + }, + "parameters": [ + "databaseId", + "collectionId", + "documents" + ], + "required": [ + "databaseId", + "collectionId", + "documents" + ], + "responses": [ + { + "code": 201, + "model": "#\/components\/schemas\/documentList" + } + ], + "description": "Create new Documents. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.", + "demo": "documentsdb\/create-documents.md", + "public": true + } + ], + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "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.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "documentId": { + "type": "string", + "description": "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.", + "x-example": "" + }, + "data": { + "type": "object", + "description": "Document data as JSON object.", + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" + }, + "permissions": { + "type": "array", + "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).", + "x-example": "[\"read(\"any\")\"]", + "items": { + "type": "string" + } + }, + "documents": { + "type": "array", + "description": "Array of documents data as JSON objects.", + "x-example": null, + "items": { + "type": "object" + } + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "x-example": "" + } + } + } + } + } + } + }, + "put": { + "summary": "Upsert documents", + "operationId": "documentsDBUpsertDocuments", + "tags": [ + "documentsDB" + ], + "description": "Create or update Documents. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.\n", + "responses": { + "201": { + "description": "Documents List", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/documentList" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "upsertDocuments", + "group": "documents", + "weight": 452, + "cookies": false, + "type": "", + "demo": "documentsdb\/upsert-documents.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/upsert-documents.md", + "methods": [ + { + "name": "upsertDocuments", + "namespace": "documentsDB", + "desc": "", + "auth": { + "Project": [] + }, + "parameters": [ + "databaseId", + "collectionId", + "documents", + "transactionId" + ], + "required": [ + "databaseId", + "collectionId", + "documents" + ], + "responses": [ + { + "code": 201, + "model": "#\/components\/schemas\/documentList" + } + ], + "description": "Create or update Documents. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.\n", + "demo": "documentsdb\/upsert-documents.md", + "public": true + } + ], + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "documents": { + "type": "array", + "description": "Array of document data as JSON objects. May contain partial documents.", + "x-example": null, + "items": { + "type": "object" + } + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "x-example": "" + } + }, + "required": [ + "documents" + ] + } + } + } + } + }, + "patch": { + "summary": "Update documents", + "operationId": "documentsDBUpdateDocuments", + "tags": [ + "documentsDB" + ], + "description": "Update all documents that match your queries, if no queries are submitted then all documents are updated. You can pass only specific fields to be updated.", + "responses": { + "200": { + "description": "Documents List", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/documentList" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "updateDocuments", + "group": "documents", + "weight": 450, + "cookies": false, + "type": "", + "demo": "documentsdb\/update-documents.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/update-documents.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "data": { + "type": "object", + "description": "Document data as JSON object. Include only attribute and value pairs to be updated.", + "x-example": "{}" + }, + "queries": { + "type": "array", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long.", + "x-example": null, + "items": { + "type": "string" + } + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "x-example": "" + } + } + } + } + } + } + }, + "delete": { + "summary": "Delete documents", + "operationId": "documentsDBDeleteDocuments", + "tags": [ + "documentsDB" + ], + "description": "Bulk delete documents using queries, if no queries are passed then all documents are deleted.", + "responses": { + "200": { + "description": "Documents List", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/documentList" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "deleteDocuments", + "group": "documents", + "weight": 454, + "cookies": false, + "type": "", + "demo": "documentsdb\/delete-documents.md", + "rate-limit": 60, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/delete-documents.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "queries": { + "type": "array", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long.", + "x-example": null, + "items": { + "type": "string" + } + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "x-example": "" + } + } + } + } + } + } + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/documents\/{documentId}\/logs": { + "get": { + "summary": "List document logs", + "operationId": "documentsDBListDocumentLogs", + "tags": [ + "documentsDB" + ], + "description": "Get the document activity logs list by its unique ID.", + "responses": { + "200": { + "description": "Logs List", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/logList" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "listDocumentLogs", + "group": "logs", + "weight": 456, + "cookies": false, + "type": "", + "demo": "documentsdb\/list-document-logs.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.read", + "platforms": [ + "console" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/get-document-logs.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Only supported methods are limit and offset", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + }, + "default": [] + }, + "in": "query" + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/documents\/{documentId}\/{attribute}\/decrement": { + "patch": { + "summary": "Decrement document attribute", + "operationId": "documentsDBDecrementDocumentAttribute", + "tags": [ + "documentsDB" + ], + "description": "Decrement a specific column of a row by a given value.", + "responses": { + "200": { + "description": "Document", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/document" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "decrementDocumentAttribute", + "group": "documents", + "weight": 458, + "cookies": false, + "type": "", + "demo": "documentsdb\/decrement-document-attribute.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server", + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/decrement-document-attribute.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "JWT": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "attribute", + "description": "Attribute key.", + "required": true, + "schema": { + "type": "string" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "value": { + "type": "number", + "description": "Value to decrement the attribute by. The value must be a number.", + "x-example": null + }, + "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 + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "x-example": "" + } + } + } + } + } + } + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/documents\/{documentId}\/{attribute}\/increment": { + "patch": { + "summary": "Increment document attribute", + "operationId": "documentsDBIncrementDocumentAttribute", + "tags": [ + "documentsDB" + ], + "description": "Increment a specific column of a row by a given value.", + "responses": { + "200": { + "description": "Document", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/document" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "incrementDocumentAttribute", + "group": "documents", + "weight": 457, + "cookies": false, + "type": "", + "demo": "documentsdb\/increment-document-attribute.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server", + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/increment-document-attribute.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "JWT": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "attribute", + "description": "Attribute key.", + "required": true, + "schema": { + "type": "string" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "value": { + "type": "number", + "description": "Value to increment the attribute by. The value must be a number.", + "x-example": null + }, + "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 + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "x-example": "" + } + } + } + } + } + } + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/indexes": { + "get": { + "summary": "List indexes", + "operationId": "documentsDBListIndexes", + "tags": [ + "documentsDB" + ], + "description": "List indexes in the collection.", + "responses": { + "200": { + "description": "Indexes List", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/indexList" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "listIndexes", + "group": "indexes", + "weight": 446, + "cookies": false, + "type": "", + "demo": "documentsdb\/list-indexes.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/list-indexes.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following attributes: key, type, status, attributes, error", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + }, + "default": [] + }, + "in": "query" + }, + { + "name": "total", + "description": "When set to false, the total count returned will be 0 and will not be calculated.", + "required": false, + "schema": { + "type": "boolean", + "x-example": false, + "default": true + }, + "in": "query" + } + ] + }, + "post": { + "summary": "Create index", + "operationId": "documentsDBCreateIndex", + "tags": [ + "documentsDB" + ], + "description": "Creates an index on the attributes listed. Your index should include all the attributes you will query in a single request.\nAttributes can be `key`, `fulltext`, and `unique`.", + "responses": { + "202": { + "description": "Index", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/index" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "createIndex", + "group": "indexes", + "weight": 443, + "cookies": false, + "type": "", + "demo": "documentsdb\/create-index.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/create-index.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "key": { + "type": "string", + "description": "Index Key.", + "x-example": null + }, + "type": { + "type": "string", + "description": "Index type.", + "x-example": "key", + "enum": [ + "key", + "fulltext", + "unique", + "spatial" + ], + "x-enum-name": "IndexType", + "x-enum-keys": [] + }, + "attributes": { + "type": "array", + "description": "Array of attributes to index. Maximum of 100 attributes are allowed, each 32 characters long.", + "x-example": null, + "items": { + "type": "string" + } + }, + "orders": { + "type": "array", + "description": "Array of index orders. Maximum of 100 orders are allowed.", + "x-example": null, + "items": { + "type": "string", + "enum": [ + "asc", + "desc" + ], + "x-enum-name": "OrderBy", + "x-enum-keys": [] + } + }, + "lengths": { + "type": "array", + "description": "Length of index. Maximum of 100", + "x-example": null, + "items": { + "type": "integer" + } + } + }, + "required": [ + "key", + "type", + "attributes" + ] + } + } + } + } + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/indexes\/{key}": { + "get": { + "summary": "Get index", + "operationId": "documentsDBGetIndex", + "tags": [ + "documentsDB" + ], + "description": "Get index by ID.", + "responses": { + "200": { + "description": "Index", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/index" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "getIndex", + "group": "indexes", + "weight": 444, + "cookies": false, + "type": "", + "demo": "documentsdb\/get-index.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/get-index.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "key", + "description": "Index Key.", + "required": true, + "schema": { + "type": "string" + }, + "in": "path" + } + ] + }, + "delete": { + "summary": "Delete index", + "operationId": "documentsDBDeleteIndex", + "tags": [ + "documentsDB" + ], + "description": "Delete an index.", + "responses": { + "204": { + "description": "No content" + } + }, + "deprecated": false, + "x-appwrite": { + "method": "deleteIndex", + "group": "indexes", + "weight": 445, + "cookies": false, + "type": "", + "demo": "documentsdb\/delete-index.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/delete-index.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "key", + "description": "Index Key.", + "required": true, + "schema": { + "type": "string" + }, + "in": "path" + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/logs": { + "get": { + "summary": "List collection logs", + "operationId": "documentsDBListCollectionLogs", + "tags": [ + "documentsDB" + ], + "description": "Get the collection activity logs list by its unique ID.", + "responses": { + "200": { + "description": "Logs List", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/logList" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "listCollectionLogs", + "group": "collections", + "weight": 441, + "cookies": false, + "type": "", + "demo": "documentsdb\/list-collection-logs.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/get-collection-logs.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Only supported methods are limit and offset", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + }, + "default": [] + }, + "in": "query" + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/usage": { + "get": { + "summary": "Get collection usage stats", + "operationId": "documentsDBGetCollectionUsage", + "tags": [ + "documentsDB" + ], + "description": "Get usage metrics and statistics for a collection. Returning the total number of documents. The response includes both current totals and historical data over time. Use the optional range parameter to specify the time window for historical data: 24h (last 24 hours), 30d (last 30 days), or 90d (last 90 days). If not specified, range defaults to 30 days.", + "responses": { + "200": { + "description": "UsageCollection", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/usageCollection" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "getCollectionUsage", + "group": null, + "weight": 442, + "cookies": false, + "type": "", + "demo": "documentsdb\/get-collection-usage.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/get-collection-usage.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "range", + "description": "Date range.", + "required": false, + "schema": { + "type": "string", + "x-example": "24h", + "enum": [ + "24h", + "30d", + "90d" + ], + "x-enum-name": "UsageRange", + "x-enum-keys": [ + "Twenty Four Hours", + "Thirty Days", + "Ninety Days" + ], + "default": "30d" + }, + "in": "query" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ] + } + }, + "\/documentsdb\/{databaseId}\/usage": { + "get": { + "summary": "Get DocumentsDB usage stats", + "operationId": "documentsDBGetUsage", + "tags": [ + "documentsDB" + ], + "description": "Get usage metrics and statistics for a database. You can view the total number of collections, documents, and storage usage. The response includes both current totals and historical data over time. Use the optional range parameter to specify the time window for historical data: 24h (last 24 hours), 30d (last 30 days), or 90d (last 90 days). If not specified, range defaults to 30 days.", + "responses": { + "200": { + "description": "UsageDocumentsDB", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/usageDocumentsDB" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "getUsage", + "group": null, + "weight": 434, + "cookies": false, + "type": "", + "demo": "documentsdb\/get-usage.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/get-database-usage.md", + "methods": [ + { + "name": "getUsage", + "namespace": "documentsDB", + "desc": "", + "auth": { + "Project": [] + }, + "parameters": [ + "databaseId", + "range" + ], + "required": [ + "databaseId" + ], + "responses": [ + { + "code": 200, + "model": "#\/components\/schemas\/usageDocumentsDB" + } + ], + "description": "Get usage metrics and statistics for a database. You can view the total number of collections, documents, and storage usage. The response includes both current totals and historical data over time. Use the optional range parameter to specify the time window for historical data: 24h (last 24 hours), 30d (last 30 days), or 90d (last 90 days). If not specified, range defaults to 30 days.", + "demo": "documentsdb\/get-usage.md", + "public": true + } + ], + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "range", + "description": "Date range.", + "required": false, + "schema": { + "type": "string", + "x-example": "24h", + "enum": [ + "24h", + "30d", + "90d" + ], + "x-enum-name": "UsageRange", + "x-enum-keys": [ + "Twenty Four Hours", + "Thirty Days", + "Ninety Days" + ], + "default": "30d" + }, + "in": "query" + } + ] + } + }, "\/functions": { "get": { "summary": "List functions", @@ -13331,7 +15738,7 @@ "x-appwrite": { "method": "list", "group": "functions", - "weight": 439, + "weight": 475, "cookies": false, "type": "", "demo": "functions\/list.md", @@ -13416,7 +15823,7 @@ "x-appwrite": { "method": "create", "group": "functions", - "weight": 436, + "weight": 472, "cookies": false, "type": "", "demo": "functions\/create.md", @@ -13711,7 +16118,7 @@ "x-appwrite": { "method": "listRuntimes", "group": "runtimes", - "weight": 441, + "weight": 477, "cookies": false, "type": "", "demo": "functions\/list-runtimes.md", @@ -13761,7 +16168,7 @@ "x-appwrite": { "method": "listSpecifications", "group": "runtimes", - "weight": 442, + "weight": 478, "cookies": false, "type": "", "demo": "functions\/list-specifications.md", @@ -13811,7 +16218,7 @@ "x-appwrite": { "method": "listTemplates", "group": "templates", - "weight": 465, + "weight": 501, "cookies": false, "type": "", "demo": "functions\/list-templates.md", @@ -14003,7 +16410,7 @@ "x-appwrite": { "method": "getTemplate", "group": "templates", - "weight": 464, + "weight": 500, "cookies": false, "type": "", "demo": "functions\/get-template.md", @@ -14063,7 +16470,7 @@ "x-appwrite": { "method": "listUsage", "group": null, - "weight": 458, + "weight": 494, "cookies": false, "type": "", "demo": "functions\/list-usage.md", @@ -14135,7 +16542,7 @@ "x-appwrite": { "method": "get", "group": "functions", - "weight": 437, + "weight": 473, "cookies": false, "type": "", "demo": "functions\/get.md", @@ -14195,7 +16602,7 @@ "x-appwrite": { "method": "update", "group": "functions", - "weight": 438, + "weight": 474, "cookies": false, "type": "", "demo": "functions\/update.md", @@ -14487,7 +16894,7 @@ "x-appwrite": { "method": "delete", "group": "functions", - "weight": 440, + "weight": 476, "cookies": false, "type": "", "demo": "functions\/delete.md", @@ -14549,7 +16956,7 @@ "x-appwrite": { "method": "updateFunctionDeployment", "group": "functions", - "weight": 445, + "weight": 481, "cookies": false, "type": "", "demo": "functions\/update-function-deployment.md", @@ -14630,7 +17037,7 @@ "x-appwrite": { "method": "listDeployments", "group": "deployments", - "weight": 446, + "weight": 482, "cookies": false, "type": "", "demo": "functions\/list-deployments.md", @@ -14725,7 +17132,7 @@ "x-appwrite": { "method": "createDeployment", "group": "deployments", - "weight": 443, + "weight": 479, "cookies": false, "type": "upload", "demo": "functions\/create-deployment.md", @@ -14824,7 +17231,7 @@ "x-appwrite": { "method": "createDuplicateDeployment", "group": "deployments", - "weight": 451, + "weight": 487, "cookies": false, "type": "", "demo": "functions\/create-duplicate-deployment.md", @@ -14910,7 +17317,7 @@ "x-appwrite": { "method": "createTemplateDeployment", "group": "deployments", - "weight": 448, + "weight": 484, "cookies": false, "type": "", "demo": "functions\/create-template-deployment.md", @@ -15027,7 +17434,7 @@ "x-appwrite": { "method": "createVcsDeployment", "group": "deployments", - "weight": 449, + "weight": 485, "cookies": false, "type": "", "demo": "functions\/create-vcs-deployment.md", @@ -15125,7 +17532,7 @@ "x-appwrite": { "method": "getDeployment", "group": "deployments", - "weight": 444, + "weight": 480, "cookies": false, "type": "", "demo": "functions\/get-deployment.md", @@ -15188,7 +17595,7 @@ "x-appwrite": { "method": "deleteDeployment", "group": "deployments", - "weight": 447, + "weight": 483, "cookies": false, "type": "", "demo": "functions\/delete-deployment.md", @@ -15253,7 +17660,7 @@ "x-appwrite": { "method": "getDeploymentDownload", "group": "deployments", - "weight": 450, + "weight": 486, "cookies": false, "type": "location", "demo": "functions\/get-deployment-download.md", @@ -15344,7 +17751,7 @@ "x-appwrite": { "method": "updateDeploymentStatus", "group": "deployments", - "weight": 452, + "weight": 488, "cookies": false, "type": "", "demo": "functions\/update-deployment-status.md", @@ -15416,7 +17823,7 @@ "x-appwrite": { "method": "listExecutions", "group": "executions", - "weight": 455, + "weight": 491, "cookies": false, "type": "", "demo": "functions\/list-executions.md", @@ -15503,7 +17910,7 @@ "x-appwrite": { "method": "createExecution", "group": "executions", - "weight": 453, + "weight": 489, "cookies": false, "type": "", "demo": "functions\/create-execution.md", @@ -15621,7 +18028,7 @@ "x-appwrite": { "method": "getExecution", "group": "executions", - "weight": 454, + "weight": 490, "cookies": false, "type": "", "demo": "functions\/get-execution.md", @@ -15687,7 +18094,7 @@ "x-appwrite": { "method": "deleteExecution", "group": "executions", - "weight": 456, + "weight": 492, "cookies": false, "type": "", "demo": "functions\/delete-execution.md", @@ -15759,7 +18166,7 @@ "x-appwrite": { "method": "getUsage", "group": null, - "weight": 457, + "weight": 493, "cookies": false, "type": "", "demo": "functions\/get-usage.md", @@ -15841,7 +18248,7 @@ "x-appwrite": { "method": "listVariables", "group": "variables", - "weight": 461, + "weight": 497, "cookies": false, "type": "", "demo": "functions\/list-variables.md", @@ -15901,7 +18308,7 @@ "x-appwrite": { "method": "createVariable", "group": "variables", - "weight": 459, + "weight": 495, "cookies": false, "type": "", "demo": "functions\/create-variable.md", @@ -15993,7 +18400,7 @@ "x-appwrite": { "method": "getVariable", "group": "variables", - "weight": 460, + "weight": 496, "cookies": false, "type": "", "demo": "functions\/get-variable.md", @@ -16063,7 +18470,7 @@ "x-appwrite": { "method": "updateVariable", "group": "variables", - "weight": 462, + "weight": 498, "cookies": false, "type": "", "demo": "functions\/update-variable.md", @@ -16157,7 +18564,7 @@ "x-appwrite": { "method": "deleteVariable", "group": "variables", - "weight": 463, + "weight": 499, "cookies": false, "type": "", "demo": "functions\/delete-variable.md", @@ -23618,6 +26025,8 @@ "document", "attribute", "collection", + "documentsdb", + "vectordb", "bucket", "file", "function", @@ -23724,6 +26133,8 @@ "document", "attribute", "collection", + "documentsdb", + "vectordb", "bucket", "file", "function", @@ -25299,7 +27710,7 @@ "x-appwrite": { "method": "list", "group": "projects", - "weight": 434, + "weight": 470, "cookies": false, "type": "", "demo": "projects\/list.md", @@ -25324,7 +27735,7 @@ "parameters": [ { "name": "queries", - "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following attributes: name, teamId, labels", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following attributes: name, teamId, labels, search", "required": false, "schema": { "type": "array", @@ -26966,7 +29377,7 @@ "x-appwrite": { "method": "listDevKeys", "group": "devKeys", - "weight": 432, + "weight": 468, "cookies": false, "type": "", "demo": "projects\/list-dev-keys.md", @@ -27037,7 +29448,7 @@ "x-appwrite": { "method": "createDevKey", "group": "devKeys", - "weight": 429, + "weight": 465, "cookies": false, "type": "", "demo": "projects\/create-dev-key.md", @@ -27122,7 +29533,7 @@ "x-appwrite": { "method": "getDevKey", "group": "devKeys", - "weight": 431, + "weight": 467, "cookies": false, "type": "", "demo": "projects\/get-dev-key.md", @@ -27190,7 +29601,7 @@ "x-appwrite": { "method": "updateDevKey", "group": "devKeys", - "weight": 430, + "weight": 466, "cookies": false, "type": "", "demo": "projects\/update-dev-key.md", @@ -27276,7 +29687,7 @@ "x-appwrite": { "method": "deleteDevKey", "group": "devKeys", - "weight": 433, + "weight": 469, "cookies": false, "type": "", "demo": "projects\/delete-dev-key.md", @@ -28014,7 +30425,7 @@ "x-appwrite": { "method": "updateLabels", "group": "projects", - "weight": 435, + "weight": 471, "cookies": false, "type": "", "demo": "projects\/update-labels.md", @@ -31449,7 +33860,7 @@ "x-appwrite": { "method": "listRules", "group": null, - "weight": 511, + "weight": 547, "cookies": false, "type": "", "demo": "proxy\/list-rules.md", @@ -31534,7 +33945,7 @@ "x-appwrite": { "method": "createAPIRule", "group": null, - "weight": 506, + "weight": 542, "cookies": false, "type": "", "demo": "proxy\/create-api-rule.md", @@ -31601,7 +34012,7 @@ "x-appwrite": { "method": "createFunctionRule", "group": null, - "weight": 508, + "weight": 544, "cookies": false, "type": "", "demo": "proxy\/create-function-rule.md", @@ -31679,7 +34090,7 @@ "x-appwrite": { "method": "createRedirectRule", "group": null, - "weight": 509, + "weight": 545, "cookies": false, "type": "", "demo": "proxy\/create-redirect-rule.md", @@ -31792,7 +34203,7 @@ "x-appwrite": { "method": "createSiteRule", "group": null, - "weight": 507, + "weight": 543, "cookies": false, "type": "", "demo": "proxy\/create-site-rule.md", @@ -31870,7 +34281,7 @@ "x-appwrite": { "method": "getRule", "group": null, - "weight": 510, + "weight": 546, "cookies": false, "type": "", "demo": "proxy\/get-rule.md", @@ -31921,7 +34332,7 @@ "x-appwrite": { "method": "deleteRule", "group": null, - "weight": 512, + "weight": 548, "cookies": false, "type": "", "demo": "proxy\/delete-rule.md", @@ -31981,7 +34392,7 @@ "x-appwrite": { "method": "updateRuleVerification", "group": null, - "weight": 513, + "weight": 549, "cookies": false, "type": "", "demo": "proxy\/update-rule-verification.md", @@ -32041,7 +34452,7 @@ "x-appwrite": { "method": "list", "group": "sites", - "weight": 468, + "weight": 504, "cookies": false, "type": "", "demo": "sites\/list.md", @@ -32126,7 +34537,7 @@ "x-appwrite": { "method": "create", "group": "sites", - "weight": 466, + "weight": 502, "cookies": false, "type": "", "demo": "sites\/create.md", @@ -32379,7 +34790,7 @@ "x-appwrite": { "method": "listFrameworks", "group": "frameworks", - "weight": 471, + "weight": 507, "cookies": false, "type": "", "demo": "sites\/list-frameworks.md", @@ -32429,7 +34840,7 @@ "x-appwrite": { "method": "listSpecifications", "group": "frameworks", - "weight": 494, + "weight": 530, "cookies": false, "type": "", "demo": "sites\/list-specifications.md", @@ -32479,7 +34890,7 @@ "x-appwrite": { "method": "listTemplates", "group": "templates", - "weight": 490, + "weight": 526, "cookies": false, "type": "", "demo": "sites\/list-templates.md", @@ -32608,7 +35019,7 @@ "x-appwrite": { "method": "getTemplate", "group": "templates", - "weight": 491, + "weight": 527, "cookies": false, "type": "", "demo": "sites\/get-template.md", @@ -32668,7 +35079,7 @@ "x-appwrite": { "method": "listUsage", "group": null, - "weight": 492, + "weight": 528, "cookies": false, "type": "", "demo": "sites\/list-usage.md", @@ -32740,7 +35151,7 @@ "x-appwrite": { "method": "get", "group": "sites", - "weight": 467, + "weight": 503, "cookies": false, "type": "", "demo": "sites\/get.md", @@ -32800,7 +35211,7 @@ "x-appwrite": { "method": "update", "group": "sites", - "weight": 469, + "weight": 505, "cookies": false, "type": "", "demo": "sites\/update.md", @@ -33049,7 +35460,7 @@ "x-appwrite": { "method": "delete", "group": "sites", - "weight": 470, + "weight": 506, "cookies": false, "type": "", "demo": "sites\/delete.md", @@ -33111,7 +35522,7 @@ "x-appwrite": { "method": "updateSiteDeployment", "group": "sites", - "weight": 477, + "weight": 513, "cookies": false, "type": "", "demo": "sites\/update-site-deployment.md", @@ -33192,7 +35603,7 @@ "x-appwrite": { "method": "listDeployments", "group": "deployments", - "weight": 476, + "weight": 512, "cookies": false, "type": "", "demo": "sites\/list-deployments.md", @@ -33287,7 +35698,7 @@ "x-appwrite": { "method": "createDeployment", "group": "deployments", - "weight": 472, + "weight": 508, "cookies": false, "type": "upload", "demo": "sites\/create-deployment.md", @@ -33392,7 +35803,7 @@ "x-appwrite": { "method": "createDuplicateDeployment", "group": "deployments", - "weight": 480, + "weight": 516, "cookies": false, "type": "", "demo": "sites\/create-duplicate-deployment.md", @@ -33473,7 +35884,7 @@ "x-appwrite": { "method": "createTemplateDeployment", "group": "deployments", - "weight": 473, + "weight": 509, "cookies": false, "type": "", "demo": "sites\/create-template-deployment.md", @@ -33590,7 +36001,7 @@ "x-appwrite": { "method": "createVcsDeployment", "group": "deployments", - "weight": 474, + "weight": 510, "cookies": false, "type": "", "demo": "sites\/create-vcs-deployment.md", @@ -33689,7 +36100,7 @@ "x-appwrite": { "method": "getDeployment", "group": "deployments", - "weight": 475, + "weight": 511, "cookies": false, "type": "", "demo": "sites\/get-deployment.md", @@ -33752,7 +36163,7 @@ "x-appwrite": { "method": "deleteDeployment", "group": "deployments", - "weight": 478, + "weight": 514, "cookies": false, "type": "", "demo": "sites\/delete-deployment.md", @@ -33817,7 +36228,7 @@ "x-appwrite": { "method": "getDeploymentDownload", "group": "deployments", - "weight": 479, + "weight": 515, "cookies": false, "type": "location", "demo": "sites\/get-deployment-download.md", @@ -33908,7 +36319,7 @@ "x-appwrite": { "method": "updateDeploymentStatus", "group": "deployments", - "weight": 481, + "weight": 517, "cookies": false, "type": "", "demo": "sites\/update-deployment-status.md", @@ -33980,7 +36391,7 @@ "x-appwrite": { "method": "listLogs", "group": "logs", - "weight": 483, + "weight": 519, "cookies": false, "type": "", "demo": "sites\/list-logs.md", @@ -34066,7 +36477,7 @@ "x-appwrite": { "method": "getLog", "group": "logs", - "weight": 482, + "weight": 518, "cookies": false, "type": "", "demo": "sites\/get-log.md", @@ -34129,7 +36540,7 @@ "x-appwrite": { "method": "deleteLog", "group": "logs", - "weight": 484, + "weight": 520, "cookies": false, "type": "", "demo": "sites\/delete-log.md", @@ -34201,7 +36612,7 @@ "x-appwrite": { "method": "getUsage", "group": null, - "weight": 493, + "weight": 529, "cookies": false, "type": "", "demo": "sites\/get-usage.md", @@ -34283,7 +36694,7 @@ "x-appwrite": { "method": "listVariables", "group": "variables", - "weight": 487, + "weight": 523, "cookies": false, "type": "", "demo": "sites\/list-variables.md", @@ -34343,7 +36754,7 @@ "x-appwrite": { "method": "createVariable", "group": "variables", - "weight": 485, + "weight": 521, "cookies": false, "type": "", "demo": "sites\/create-variable.md", @@ -34435,7 +36846,7 @@ "x-appwrite": { "method": "getVariable", "group": "variables", - "weight": 486, + "weight": 522, "cookies": false, "type": "", "demo": "sites\/get-variable.md", @@ -34505,7 +36916,7 @@ "x-appwrite": { "method": "updateVariable", "group": "variables", - "weight": 488, + "weight": 524, "cookies": false, "type": "", "demo": "sites\/update-variable.md", @@ -34599,7 +37010,7 @@ "x-appwrite": { "method": "deleteVariable", "group": "variables", - "weight": 489, + "weight": 525, "cookies": false, "type": "", "demo": "sites\/delete-variable.md", @@ -34671,7 +37082,7 @@ "x-appwrite": { "method": "listBuckets", "group": "buckets", - "weight": 521, + "weight": 557, "cookies": false, "type": "", "demo": "storage\/list-buckets.md", @@ -34757,7 +37168,7 @@ "x-appwrite": { "method": "createBucket", "group": "buckets", - "weight": 519, + "weight": 555, "cookies": false, "type": "", "demo": "storage\/create-bucket.md", @@ -34892,7 +37303,7 @@ "x-appwrite": { "method": "getBucket", "group": "buckets", - "weight": 520, + "weight": 556, "cookies": false, "type": "", "demo": "storage\/get-bucket.md", @@ -34953,7 +37364,7 @@ "x-appwrite": { "method": "updateBucket", "group": "buckets", - "weight": 522, + "weight": 558, "cookies": false, "type": "", "demo": "storage\/update-bucket.md", @@ -35085,7 +37496,7 @@ "x-appwrite": { "method": "deleteBucket", "group": "buckets", - "weight": 523, + "weight": 559, "cookies": false, "type": "", "demo": "storage\/delete-bucket.md", @@ -35148,7 +37559,7 @@ "x-appwrite": { "method": "listFiles", "group": "files", - "weight": 526, + "weight": 562, "cookies": false, "type": "", "demo": "storage\/list-files.md", @@ -35247,7 +37658,7 @@ "x-appwrite": { "method": "createFile", "group": "files", - "weight": 524, + "weight": 560, "cookies": false, "type": "upload", "demo": "storage\/create-file.md", @@ -35348,7 +37759,7 @@ "x-appwrite": { "method": "getFile", "group": "files", - "weight": 525, + "weight": 561, "cookies": false, "type": "", "demo": "storage\/get-file.md", @@ -35422,7 +37833,7 @@ "x-appwrite": { "method": "updateFile", "group": "files", - "weight": 527, + "weight": 563, "cookies": false, "type": "", "demo": "storage\/update-file.md", @@ -35514,7 +37925,7 @@ "x-appwrite": { "method": "deleteFile", "group": "files", - "weight": 528, + "weight": 564, "cookies": false, "type": "", "demo": "storage\/delete-file.md", @@ -35583,7 +37994,7 @@ "x-appwrite": { "method": "getFileDownload", "group": "files", - "weight": 530, + "weight": 566, "cookies": false, "type": "location", "demo": "storage\/get-file-download.md", @@ -35663,7 +38074,7 @@ "x-appwrite": { "method": "getFilePreview", "group": "files", - "weight": 529, + "weight": 565, "cookies": false, "type": "location", "demo": "storage\/get-file-preview.md", @@ -35893,7 +38304,7 @@ "x-appwrite": { "method": "getFileView", "group": "files", - "weight": 531, + "weight": 567, "cookies": false, "type": "location", "demo": "storage\/get-file-view.md", @@ -35980,7 +38391,7 @@ "x-appwrite": { "method": "getUsage", "group": null, - "weight": 533, + "weight": 569, "cookies": false, "type": "", "demo": "storage\/get-usage.md", @@ -36053,7 +38464,7 @@ "x-appwrite": { "method": "getBucketUsage", "group": null, - "weight": 534, + "weight": 570, "cookies": false, "type": "", "demo": "storage\/get-bucket-usage.md", @@ -44258,7 +46669,7 @@ "x-appwrite": { "method": "list", "group": "files", - "weight": 516, + "weight": 552, "cookies": false, "type": "", "demo": "tokens\/list.md", @@ -44352,7 +46763,7 @@ "x-appwrite": { "method": "createFileToken", "group": "files", - "weight": 514, + "weight": 550, "cookies": false, "type": "", "demo": "tokens\/create-file-token.md", @@ -44441,7 +46852,7 @@ "x-appwrite": { "method": "get", "group": "tokens", - "weight": 515, + "weight": 551, "cookies": false, "type": "", "demo": "tokens\/get.md", @@ -44501,7 +46912,7 @@ "x-appwrite": { "method": "update", "group": "tokens", - "weight": 517, + "weight": 553, "cookies": false, "type": "", "demo": "tokens\/update.md", @@ -44571,7 +46982,7 @@ "x-appwrite": { "method": "delete", "group": "tokens", - "weight": 518, + "weight": 554, "cookies": false, "type": "", "demo": "tokens\/delete.md", @@ -50736,7 +53147,8 @@ "x-example": "legacy", "enum": [ "legacy", - "tablesdb" + "tablesdb", + "documentsdb" ] } }, @@ -59027,6 +61439,113 @@ "databaseWrites": [] } }, + "usageDocumentsDB": { + "description": "UsageDocumentsDB", + "type": "object", + "properties": { + "range": { + "type": "string", + "description": "Time range of the usage stats.", + "x-example": "30d" + }, + "collectionsTotal": { + "type": "integer", + "description": "Total aggregated number of collections.", + "x-example": 0, + "format": "int32" + }, + "documentsTotal": { + "type": "integer", + "description": "Total aggregated number of documents.", + "x-example": 0, + "format": "int32" + }, + "storageTotal": { + "type": "integer", + "description": "Total aggregated storage used in bytes.", + "x-example": 0, + "format": "int32" + }, + "databaseReadsTotal": { + "type": "integer", + "description": "Total number of database reads.", + "x-example": 0, + "format": "int32" + }, + "databaseWritesTotal": { + "type": "integer", + "description": "Total number of database writes.", + "x-example": 0, + "format": "int32" + }, + "collections": { + "type": "array", + "description": "Aggregated number of collections per period.", + "items": { + "$ref": "#\/components\/schemas\/metric" + }, + "x-example": [] + }, + "documents": { + "type": "array", + "description": "Aggregated number of documents per period.", + "items": { + "$ref": "#\/components\/schemas\/metric" + }, + "x-example": [] + }, + "storage": { + "type": "array", + "description": "Aggregated storage used in bytes per period.", + "items": { + "$ref": "#\/components\/schemas\/metric" + }, + "x-example": [] + }, + "databaseReads": { + "type": "array", + "description": "An array of aggregated number of database reads.", + "items": { + "$ref": "#\/components\/schemas\/metric" + }, + "x-example": [] + }, + "databaseWrites": { + "type": "array", + "description": "An array of aggregated number of database writes.", + "items": { + "$ref": "#\/components\/schemas\/metric" + }, + "x-example": [] + } + }, + "required": [ + "range", + "collectionsTotal", + "documentsTotal", + "storageTotal", + "databaseReadsTotal", + "databaseWritesTotal", + "collections", + "documents", + "storage", + "databaseReads", + "databaseWrites" + ], + "example": { + "range": "30d", + "collectionsTotal": 0, + "documentsTotal": 0, + "storageTotal": 0, + "databaseReadsTotal": 0, + "databaseWritesTotal": 0, + "collections": [], + "documents": [], + "storage": [], + "databaseReads": [], + "databaseWrites": [] + } + }, "usageTable": { "description": "UsageTable", "type": "object", @@ -60324,7 +62843,13 @@ }, "documentsTotal": { "type": "integer", - "description": "Total aggregated number of documents.", + "description": "Total aggregated number of documents in legacy\/tablesdb.", + "x-example": 0, + "format": "int32" + }, + "documentsdbDocumentsTotal": { + "type": "integer", + "description": "Total aggregated number of documents in documentsdb.", "x-example": 0, "format": "int32" }, @@ -60340,12 +62865,24 @@ "x-example": 0, "format": "int32" }, + "documentsdbTotal": { + "type": "integer", + "description": "Total aggregated number of documentsdb.", + "x-example": 0, + "format": "int32" + }, "databasesStorageTotal": { "type": "integer", "description": "Total aggregated sum of databases storage size (in bytes).", "x-example": 0, "format": "int32" }, + "documentsdbDatabasesStorageTotal": { + "type": "integer", + "description": "Total aggregated sum of documentsdb databases storage size (in bytes).", + "x-example": 0, + "format": "int32" + }, "usersTotal": { "type": "integer", "description": "Total aggregated number of users.", @@ -60406,6 +62943,18 @@ "x-example": 0, "format": "int32" }, + "documentsdbDatabasesReadsTotal": { + "type": "integer", + "description": "Total number of documentsdb databases reads.", + "x-example": 0, + "format": "int32" + }, + "documentsdbDatabasesWritesTotal": { + "type": "integer", + "description": "Total number of documentsdb databases writes.", + "x-example": 0, + "format": "int32" + }, "requests": { "type": "array", "description": "Aggregated number of requests per period.", @@ -60522,6 +63071,30 @@ }, "x-example": [] }, + "documentsdbDatabasesReads": { + "type": "array", + "description": "An array of aggregated number of documentsdb database reads.", + "items": { + "$ref": "#\/components\/schemas\/metric" + }, + "x-example": [] + }, + "documentsdbDatabasesWrites": { + "type": "array", + "description": "An array of aggregated number of documentsdb database writes.", + "items": { + "$ref": "#\/components\/schemas\/metric" + }, + "x-example": [] + }, + "documentsdbDatabasesStorage": { + "type": "array", + "description": "An array of aggregated sum of documentsdb databases storage size (in bytes) per period.", + "items": { + "$ref": "#\/components\/schemas\/metric" + }, + "x-example": [] + }, "imageTransformations": { "type": "array", "description": "An array of aggregated number of image transformations.", @@ -60540,9 +63113,12 @@ "required": [ "executionsTotal", "documentsTotal", + "documentsdbDocumentsTotal", "rowsTotal", "databasesTotal", + "documentsdbTotal", "databasesStorageTotal", + "documentsdbDatabasesStorageTotal", "usersTotal", "filesStorageTotal", "functionsStorageTotal", @@ -60553,6 +63129,8 @@ "buildsMbSecondsTotal", "databasesReadsTotal", "databasesWritesTotal", + "documentsdbDatabasesReadsTotal", + "documentsdbDatabasesWritesTotal", "requests", "network", "users", @@ -60568,15 +63146,21 @@ "authPhoneCountryBreakdown", "databasesReads", "databasesWrites", + "documentsdbDatabasesReads", + "documentsdbDatabasesWrites", + "documentsdbDatabasesStorage", "imageTransformations", "imageTransformationsTotal" ], "example": { "executionsTotal": 0, "documentsTotal": 0, + "documentsdbDocumentsTotal": 0, "rowsTotal": 0, "databasesTotal": 0, + "documentsdbTotal": 0, "databasesStorageTotal": 0, + "documentsdbDatabasesStorageTotal": 0, "usersTotal": 0, "filesStorageTotal": 0, "functionsStorageTotal": 0, @@ -60587,6 +63171,8 @@ "buildsMbSecondsTotal": 0, "databasesReadsTotal": 0, "databasesWritesTotal": 0, + "documentsdbDatabasesReadsTotal": 0, + "documentsdbDatabasesWritesTotal": 0, "requests": [], "network": [], "users": [], @@ -60602,6 +63188,9 @@ "authPhoneCountryBreakdown": [], "databasesReads": [], "databasesWrites": [], + "documentsdbDatabasesReads": [], + "documentsdbDatabasesWrites": [], + "documentsdbDatabasesStorage": [], "imageTransformations": [], "imageTransformationsTotal": 0 } diff --git a/app/config/specs/open-api3-latest-server.json b/app/config/specs/open-api3-latest-server.json index 70e8b895ce..93952c9b41 100644 --- a/app/config/specs/open-api3-latest-server.json +++ b/app/config/specs/open-api3-latest-server.json @@ -9719,6 +9719,123 @@ } } }, + "\/databases\/{databaseId}\/collections\/{collectionId}\/attributes\/relationship\/{key}": { + "patch": { + "summary": "Update relationship attribute", + "operationId": "databasesUpdateRelationshipAttribute", + "tags": [ + "databases" + ], + "description": "Update relationship attribute. [Learn more about relationship attributes](https:\/\/appwrite.io\/docs\/databases-relationships#relationship-attributes).\n", + "responses": { + "200": { + "description": "AttributeRelationship", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/attributeRelationship" + } + } + } + } + }, + "deprecated": true, + "x-appwrite": { + "method": "updateRelationshipAttribute", + "group": "attributes", + "weight": 349, + "cookies": false, + "type": "", + "demo": "databases\/update-relationship-attribute.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/databases\/update-relationship-attribute.md", + "deprecated": { + "since": "1.8.0", + "replaceWith": "tablesDB.updateRelationshipColumn" + }, + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "key", + "description": "Attribute Key.", + "required": true, + "schema": { + "type": "string" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "onDelete": { + "type": "string", + "description": "Constraints option", + "x-example": "cascade", + "enum": [ + "cascade", + "restrict", + "setNull" + ], + "x-enum-name": "RelationMutate", + "x-enum-keys": [], + "x-nullable": true + }, + "newKey": { + "type": "string", + "description": "New Attribute Key.", + "x-example": null, + "x-nullable": true + } + } + } + } + } + } + } + }, "\/databases\/{databaseId}\/collections\/{collectionId}\/attributes\/string": { "post": { "summary": "Create string attribute", @@ -10398,123 +10515,6 @@ ] } }, - "\/databases\/{databaseId}\/collections\/{collectionId}\/attributes\/{key}\/relationship": { - "patch": { - "summary": "Update relationship attribute", - "operationId": "databasesUpdateRelationshipAttribute", - "tags": [ - "databases" - ], - "description": "Update relationship attribute. [Learn more about relationship attributes](https:\/\/appwrite.io\/docs\/databases-relationships#relationship-attributes).\n", - "responses": { - "200": { - "description": "AttributeRelationship", - "content": { - "application\/json": { - "schema": { - "$ref": "#\/components\/schemas\/attributeRelationship" - } - } - } - } - }, - "deprecated": true, - "x-appwrite": { - "method": "updateRelationshipAttribute", - "group": "attributes", - "weight": 349, - "cookies": false, - "type": "", - "demo": "databases\/update-relationship-attribute.md", - "rate-limit": 0, - "rate-time": 3600, - "rate-key": "url:{url},ip:{ip}", - "scope": "collections.write", - "platforms": [ - "console", - "server" - ], - "packaging": false, - "public": true, - "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/databases\/update-relationship-attribute.md", - "deprecated": { - "since": "1.8.0", - "replaceWith": "tablesDB.updateRelationshipColumn" - }, - "auth": { - "Project": [], - "Key": [] - } - }, - "security": [ - { - "Project": [], - "Key": [] - } - ], - "parameters": [ - { - "name": "databaseId", - "description": "Database ID.", - "required": true, - "schema": { - "type": "string", - "x-example": "" - }, - "in": "path" - }, - { - "name": "collectionId", - "description": "Collection ID.", - "required": true, - "schema": { - "type": "string", - "x-example": "" - }, - "in": "path" - }, - { - "name": "key", - "description": "Attribute Key.", - "required": true, - "schema": { - "type": "string" - }, - "in": "path" - } - ], - "requestBody": { - "content": { - "application\/json": { - "schema": { - "type": "object", - "properties": { - "onDelete": { - "type": "string", - "description": "Constraints option", - "x-example": "cascade", - "enum": [ - "cascade", - "restrict", - "setNull" - ], - "x-enum-name": "RelationMutate", - "x-enum-keys": [], - "x-nullable": true - }, - "newKey": { - "type": "string", - "description": "New Attribute Key.", - "x-example": null, - "x-nullable": true - } - } - } - } - } - } - } - }, "\/databases\/{databaseId}\/collections\/{collectionId}\/documents": { "get": { "summary": "List documents", @@ -10723,6 +10723,7 @@ "databaseId", "collectionId", "documents", + "transactionId", "transactionId" ], "required": [ @@ -12331,6 +12332,2996 @@ ] } }, + "\/documentsdb": { + "get": { + "summary": "List databases", + "operationId": "documentsDBList", + "tags": [ + "documentsDB" + ], + "description": "Get a list of all databases from the current Appwrite project. You can use the search parameter to filter your results.", + "responses": { + "200": { + "description": "Databases List", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/databaseList" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "list", + "group": "documentsdb", + "weight": 433, + "cookies": false, + "type": "", + "demo": "documentsdb\/list.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "databases.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/list.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following columns: name", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + }, + "default": [] + }, + "in": "query" + }, + { + "name": "search", + "description": "Search term to filter your list results. Max length: 256 chars.", + "required": false, + "schema": { + "type": "string", + "x-example": "", + "default": "" + }, + "in": "query" + }, + { + "name": "total", + "description": "When set to false, the total count returned will be 0 and will not be calculated.", + "required": false, + "schema": { + "type": "boolean", + "x-example": false, + "default": true + }, + "in": "query" + } + ] + }, + "post": { + "summary": "Create database", + "operationId": "documentsDBCreate", + "tags": [ + "documentsDB" + ], + "description": "Create a new Database.\n", + "responses": { + "201": { + "description": "Database", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/database" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "create", + "group": "documentsdb", + "weight": 429, + "cookies": false, + "type": "", + "demo": "documentsdb\/create.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "databases.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/create.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "databaseId": { + "type": "string", + "description": "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.", + "x-example": "" + }, + "name": { + "type": "string", + "description": "Database name. Max length: 128 chars.", + "x-example": "" + }, + "enabled": { + "type": "boolean", + "description": "Is the database enabled? When set to 'disabled', users cannot access the database but Server SDKs with an API key can still read and write to the database. No data is lost when this is toggled.", + "x-example": false + } + }, + "required": [ + "databaseId", + "name" + ] + } + } + } + } + } + }, + "\/documentsdb\/transactions": { + "get": { + "summary": "List transactions", + "operationId": "documentsDBListTransactions", + "tags": [ + "documentsDB" + ], + "description": false, + "responses": { + "200": { + "description": "Transaction List", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/transactionList" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "listTransactions", + "group": "transactions", + "weight": 463, + "cookies": false, + "type": "", + "demo": "documentsdb\/list-transactions.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.read", + "platforms": [ + "server", + "client", + "server" + ], + "packaging": false, + "public": true, + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries).", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + }, + "default": [] + }, + "in": "query" + } + ] + }, + "post": { + "summary": "Create transaction", + "operationId": "documentsDBCreateTransaction", + "tags": [ + "documentsDB" + ], + "description": false, + "responses": { + "201": { + "description": "Transaction", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/transaction" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "createTransaction", + "group": "transactions", + "weight": 459, + "cookies": false, + "type": "", + "demo": "documentsdb\/create-transaction.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.write", + "platforms": [ + "server", + "client", + "server" + ], + "packaging": false, + "public": true, + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [], + "Session": [], + "JWT": [] + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "ttl": { + "type": "integer", + "description": "Seconds before the transaction expires.", + "x-example": 60 + } + } + } + } + } + } + } + }, + "\/documentsdb\/transactions\/{transactionId}": { + "get": { + "summary": "Get transaction", + "operationId": "documentsDBGetTransaction", + "tags": [ + "documentsDB" + ], + "description": false, + "responses": { + "200": { + "description": "Transaction", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/transaction" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "getTransaction", + "group": "transactions", + "weight": 460, + "cookies": false, + "type": "", + "demo": "documentsdb\/get-transaction.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.read", + "platforms": [ + "server", + "client", + "server" + ], + "packaging": false, + "public": true, + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "transactionId", + "description": "Transaction ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ] + }, + "patch": { + "summary": "Update transaction", + "operationId": "documentsDBUpdateTransaction", + "tags": [ + "documentsDB" + ], + "description": false, + "responses": { + "200": { + "description": "Transaction", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/transaction" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "updateTransaction", + "group": "transactions", + "weight": 461, + "cookies": false, + "type": "", + "demo": "documentsdb\/update-transaction.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.write", + "platforms": [ + "server", + "client", + "server" + ], + "packaging": false, + "public": true, + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "transactionId", + "description": "Transaction ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "commit": { + "type": "boolean", + "description": "Commit transaction?", + "x-example": false + }, + "rollback": { + "type": "boolean", + "description": "Rollback transaction?", + "x-example": false + } + } + } + } + } + } + }, + "delete": { + "summary": "Delete transaction", + "operationId": "documentsDBDeleteTransaction", + "tags": [ + "documentsDB" + ], + "description": false, + "responses": { + "204": { + "description": "No content" + } + }, + "deprecated": false, + "x-appwrite": { + "method": "deleteTransaction", + "group": "transactions", + "weight": 462, + "cookies": false, + "type": "", + "demo": "documentsdb\/delete-transaction.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.write", + "platforms": [ + "server", + "client", + "server" + ], + "packaging": false, + "public": true, + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "transactionId", + "description": "Transaction ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ] + } + }, + "\/documentsdb\/transactions\/{transactionId}\/operations": { + "post": { + "summary": "Create operations", + "operationId": "documentsDBCreateOperations", + "tags": [ + "documentsDB" + ], + "description": false, + "responses": { + "201": { + "description": "Transaction", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/transaction" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "createOperations", + "group": "transactions", + "weight": 464, + "cookies": false, + "type": "", + "demo": "documentsdb\/create-operations.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.write", + "platforms": [ + "server", + "client", + "server" + ], + "packaging": false, + "public": true, + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "transactionId", + "description": "Transaction ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "operations": { + "type": "array", + "description": "Array of staged operations.", + "x-example": "[\n\t {\n\t \"action\": \"create\",\n\t \"databaseId\": \"\",\n\t \"collectionId\": \"\",\n\t \"documentId\": \"\",\n\t \"data\": {\n\t \"name\": \"Walter O'Brien\"\n\t }\n\t }\n\t]", + "items": { + "type": "object" + } + } + } + } + } + } + } + } + }, + "\/documentsdb\/{databaseId}": { + "get": { + "summary": "Get database", + "operationId": "documentsDBGet", + "tags": [ + "documentsDB" + ], + "description": "Get a database by its unique ID. This endpoint response returns a JSON object with the database metadata.", + "responses": { + "200": { + "description": "Database", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/database" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "get", + "group": "documentsdb", + "weight": 430, + "cookies": false, + "type": "", + "demo": "documentsdb\/get.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "databases.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/get.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ] + }, + "put": { + "summary": "Update database", + "operationId": "documentsDBUpdate", + "tags": [ + "documentsDB" + ], + "description": "Update a database by its unique ID.", + "responses": { + "200": { + "description": "Database", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/database" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "update", + "group": "documentsdb", + "weight": 431, + "cookies": false, + "type": "", + "demo": "documentsdb\/update.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "databases.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/update.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "Database name. Max length: 128 chars.", + "x-example": "" + }, + "enabled": { + "type": "boolean", + "description": "Is database enabled? When set to 'disabled', users cannot access the database but Server SDKs with an API key can still read and write to the database. No data is lost when this is toggled.", + "x-example": false + } + }, + "required": [ + "name" + ] + } + } + } + } + }, + "delete": { + "summary": "Delete database", + "operationId": "documentsDBDelete", + "tags": [ + "documentsDB" + ], + "description": "Delete a database by its unique ID. Only API keys with with databases.write scope can delete a database.", + "responses": { + "204": { + "description": "No content" + } + }, + "deprecated": false, + "x-appwrite": { + "method": "delete", + "group": "documentsdb", + "weight": 432, + "cookies": false, + "type": "", + "demo": "documentsdb\/delete.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "databases.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/delete.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections": { + "get": { + "summary": "List collections", + "operationId": "documentsDBListCollections", + "tags": [ + "documentsDB" + ], + "description": "Get a list of all collections that belong to the provided databaseId. You can use the search parameter to filter your results.", + "responses": { + "200": { + "description": "Collections List", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/collectionList" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "listCollections", + "group": "collections", + "weight": 440, + "cookies": false, + "type": "", + "demo": "documentsdb\/list-collections.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/list-collections.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following attributes: name, enabled, documentSecurity", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + }, + "default": [] + }, + "in": "query" + }, + { + "name": "search", + "description": "Search term to filter your list results. Max length: 256 chars.", + "required": false, + "schema": { + "type": "string", + "x-example": "", + "default": "" + }, + "in": "query" + }, + { + "name": "total", + "description": "When set to false, the total count returned will be 0 and will not be calculated.", + "required": false, + "schema": { + "type": "boolean", + "x-example": false, + "default": true + }, + "in": "query" + } + ] + }, + "post": { + "summary": "Create collection", + "operationId": "documentsDBCreateCollection", + "tags": [ + "documentsDB" + ], + "description": "Create a new Collection. Before using this route, you should create a new database resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.", + "responses": { + "201": { + "description": "Collection", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/collection" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "createCollection", + "group": "collections", + "weight": 436, + "cookies": false, + "type": "", + "demo": "documentsdb\/create-collection.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/create-collection.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "collectionId": { + "type": "string", + "description": "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.", + "x-example": "" + }, + "name": { + "type": "string", + "description": "Collection name. Max length: 128 chars.", + "x-example": "" + }, + "permissions": { + "type": "array", + "description": "An array of permissions strings. By default, no user is granted with any permissions. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", + "x-example": "[\"read(\"any\")\"]", + "items": { + "type": "string" + } + }, + "documentSecurity": { + "type": "boolean", + "description": "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).", + "x-example": false + }, + "enabled": { + "type": "boolean", + "description": "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.", + "x-example": false + }, + "attributes": { + "type": "array", + "description": "Array of attribute definitions to create. Each attribute should contain: key (string), type (string: string, integer, float, boolean, datetime, relationship), size (integer, required for string type), required (boolean, optional), default (mixed, optional), array (boolean, optional), and type-specific options.", + "x-example": null, + "items": { + "type": "object" + } + }, + "indexes": { + "type": "array", + "description": "Array of index definitions to create. Each index should contain: key (string), type (string: key, fulltext, unique, spatial), attributes (array of attribute keys), orders (array of ASC\/DESC, optional), and lengths (array of integers, optional).", + "x-example": null, + "items": { + "type": "object" + } + } + }, + "required": [ + "collectionId", + "name" + ] + } + } + } + } + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}": { + "get": { + "summary": "Get collection", + "operationId": "documentsDBGetCollection", + "tags": [ + "documentsDB" + ], + "description": "Get a collection by its unique ID. This endpoint response returns a JSON object with the collection metadata.", + "responses": { + "200": { + "description": "Collection", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/collection" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "getCollection", + "group": "collections", + "weight": 437, + "cookies": false, + "type": "", + "demo": "documentsdb\/get-collection.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/get-collection.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ] + }, + "put": { + "summary": "Update collection", + "operationId": "documentsDBUpdateCollection", + "tags": [ + "documentsDB" + ], + "description": "Update a collection by its unique ID.", + "responses": { + "200": { + "description": "Collection", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/collection" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "updateCollection", + "group": "collections", + "weight": 438, + "cookies": false, + "type": "", + "demo": "documentsdb\/update-collection.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/update-collection.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "Collection name. Max length: 128 chars.", + "x-example": "" + }, + "permissions": { + "type": "array", + "description": "An array of permission strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", + "x-example": "[\"read(\"any\")\"]", + "items": { + "type": "string" + } + }, + "documentSecurity": { + "type": "boolean", + "description": "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).", + "x-example": false + }, + "enabled": { + "type": "boolean", + "description": "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.", + "x-example": false + } + }, + "required": [ + "name" + ] + } + } + } + } + }, + "delete": { + "summary": "Delete collection", + "operationId": "documentsDBDeleteCollection", + "tags": [ + "documentsDB" + ], + "description": "Delete a collection by its unique ID. Only users with write permissions have access to delete this resource.", + "responses": { + "204": { + "description": "No content" + } + }, + "deprecated": false, + "x-appwrite": { + "method": "deleteCollection", + "group": "collections", + "weight": 439, + "cookies": false, + "type": "", + "demo": "documentsdb\/delete-collection.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/delete-collection.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/documents": { + "get": { + "summary": "List documents", + "operationId": "documentsDBListDocuments", + "tags": [ + "documentsDB" + ], + "description": "Get a list of all the user's documents in a given collection. You can use the query params to filter your results.", + "responses": { + "200": { + "description": "Documents List", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/documentList" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "listDocuments", + "group": "documents", + "weight": 455, + "cookies": false, + "type": "", + "demo": "documentsdb\/list-documents.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.read", + "platforms": [ + "client", + "server", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/list-documents.md", + "auth": { + "Project": [], + "Session": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "Key": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long.", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + }, + "default": [] + }, + "in": "query" + }, + { + "name": "transactionId", + "description": "Transaction ID to read uncommitted changes within the transaction.", + "required": false, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "query" + }, + { + "name": "total", + "description": "When set to false, the total count returned will be 0 and will not be calculated.", + "required": false, + "schema": { + "type": "boolean", + "x-example": false, + "default": true + }, + "in": "query" + } + ] + }, + "post": { + "summary": "Create document", + "operationId": "documentsDBCreateDocument", + "tags": [ + "documentsDB" + ], + "description": "Create a new Document. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.", + "responses": { + "201": { + "description": "Document", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/document" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "createDocument", + "group": "documents", + "weight": 447, + "cookies": false, + "type": "", + "demo": "documentsdb\/create-document.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/create-document.md", + "methods": [ + { + "name": "createDocument", + "namespace": "documentsDB", + "desc": "Create document", + "auth": { + "Project": [], + "Session": [] + }, + "parameters": [ + "databaseId", + "collectionId", + "documentId", + "data", + "permissions" + ], + "required": [ + "databaseId", + "collectionId", + "documentId", + "data" + ], + "responses": [ + { + "code": 201, + "model": "#\/components\/schemas\/document" + } + ], + "description": "Create a new Document. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.", + "demo": "documentsdb\/create-document.md", + "public": true + }, + { + "name": "createDocuments", + "namespace": "documentsDB", + "desc": "Create documents", + "auth": { + "Project": [], + "Key": [] + }, + "parameters": [ + "databaseId", + "collectionId", + "documents" + ], + "required": [ + "databaseId", + "collectionId", + "documents" + ], + "responses": [ + { + "code": 201, + "model": "#\/components\/schemas\/documentList" + } + ], + "description": "Create new Documents. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.", + "demo": "documentsdb\/create-documents.md", + "public": true + } + ], + "auth": { + "Project": [], + "Session": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "Key": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "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.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "documentId": { + "type": "string", + "description": "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.", + "x-example": "" + }, + "data": { + "type": "object", + "description": "Document data as JSON object.", + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" + }, + "permissions": { + "type": "array", + "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).", + "x-example": "[\"read(\"any\")\"]", + "items": { + "type": "string" + } + }, + "documents": { + "type": "array", + "description": "Array of documents data as JSON objects.", + "x-example": null, + "items": { + "type": "object" + } + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "x-example": "" + } + } + } + } + } + } + }, + "put": { + "summary": "Upsert documents", + "operationId": "documentsDBUpsertDocuments", + "tags": [ + "documentsDB" + ], + "description": "Create or update Documents. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.\n", + "responses": { + "201": { + "description": "Documents List", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/documentList" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "upsertDocuments", + "group": "documents", + "weight": 452, + "cookies": false, + "type": "", + "demo": "documentsdb\/upsert-documents.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/upsert-documents.md", + "methods": [ + { + "name": "upsertDocuments", + "namespace": "documentsDB", + "desc": "", + "auth": { + "Project": [], + "Key": [] + }, + "parameters": [ + "databaseId", + "collectionId", + "documents", + "transactionId" + ], + "required": [ + "databaseId", + "collectionId", + "documents" + ], + "responses": [ + { + "code": 201, + "model": "#\/components\/schemas\/documentList" + } + ], + "description": "Create or update Documents. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.\n", + "demo": "documentsdb\/upsert-documents.md", + "public": true + } + ], + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "documents": { + "type": "array", + "description": "Array of document data as JSON objects. May contain partial documents.", + "x-example": null, + "items": { + "type": "object" + } + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "x-example": "" + } + }, + "required": [ + "documents" + ] + } + } + } + } + }, + "patch": { + "summary": "Update documents", + "operationId": "documentsDBUpdateDocuments", + "tags": [ + "documentsDB" + ], + "description": "Update all documents that match your queries, if no queries are submitted then all documents are updated. You can pass only specific fields to be updated.", + "responses": { + "200": { + "description": "Documents List", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/documentList" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "updateDocuments", + "group": "documents", + "weight": 450, + "cookies": false, + "type": "", + "demo": "documentsdb\/update-documents.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/update-documents.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "data": { + "type": "object", + "description": "Document data as JSON object. Include only attribute and value pairs to be updated.", + "x-example": "{}" + }, + "queries": { + "type": "array", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long.", + "x-example": null, + "items": { + "type": "string" + } + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "x-example": "" + } + } + } + } + } + } + }, + "delete": { + "summary": "Delete documents", + "operationId": "documentsDBDeleteDocuments", + "tags": [ + "documentsDB" + ], + "description": "Bulk delete documents using queries, if no queries are passed then all documents are deleted.", + "responses": { + "200": { + "description": "Documents List", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/documentList" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "deleteDocuments", + "group": "documents", + "weight": 454, + "cookies": false, + "type": "", + "demo": "documentsdb\/delete-documents.md", + "rate-limit": 60, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/delete-documents.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "queries": { + "type": "array", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long.", + "x-example": null, + "items": { + "type": "string" + } + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "x-example": "" + } + } + } + } + } + } + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/documents\/{documentId}": { + "get": { + "summary": "Get document", + "operationId": "documentsDBGetDocument", + "tags": [ + "documentsDB" + ], + "description": "Get a document by its unique ID. This endpoint response returns a JSON object with the document data.", + "responses": { + "200": { + "description": "Document", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/document" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "getDocument", + "group": "documents", + "weight": 448, + "cookies": false, + "type": "", + "demo": "documentsdb\/get-document.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.read", + "platforms": [ + "client", + "server", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/get-document.md", + "auth": { + "Project": [], + "Session": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "Key": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long.", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + }, + "default": [] + }, + "in": "query" + }, + { + "name": "transactionId", + "description": "Transaction ID to read uncommitted changes within the transaction.", + "required": false, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "query" + } + ] + }, + "put": { + "summary": "Upsert a document", + "operationId": "documentsDBUpsertDocument", + "tags": [ + "documentsDB" + ], + "description": "Create or update a Document. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.", + "responses": { + "201": { + "description": "Document", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/document" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "upsertDocument", + "group": "documents", + "weight": 451, + "cookies": false, + "type": "", + "demo": "documentsdb\/upsert-document.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/upsert-document.md", + "methods": [ + { + "name": "upsertDocument", + "namespace": "documentsDB", + "desc": "", + "auth": { + "Project": [], + "Session": [] + }, + "parameters": [ + "databaseId", + "collectionId", + "documentId", + "data", + "permissions", + "transactionId" + ], + "required": [ + "databaseId", + "collectionId", + "documentId" + ], + "responses": [ + { + "code": 201, + "model": "#\/components\/schemas\/document" + } + ], + "description": "Create or update a Document. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.", + "demo": "documentsdb\/upsert-document.md", + "public": true + } + ], + "auth": { + "Project": [], + "Session": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "Key": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "data": { + "type": "object", + "description": "Document data as JSON object. Include all required fields of the document to be created or updated.", + "x-example": "{}" + }, + "permissions": { + "type": "array", + "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", + "x-example": "[\"read(\"any\")\"]", + "items": { + "type": "string" + } + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "x-example": "" + } + } + } + } + } + } + }, + "patch": { + "summary": "Update document", + "operationId": "documentsDBUpdateDocument", + "tags": [ + "documentsDB" + ], + "description": "Update a document by its unique ID. Using the patch method you can pass only specific fields that will get updated.", + "responses": { + "200": { + "description": "Document", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/document" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "updateDocument", + "group": "documents", + "weight": 449, + "cookies": false, + "type": "", + "demo": "documentsdb\/update-document.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/update-document.md", + "auth": { + "Project": [], + "Session": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "Key": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "data": { + "type": "object", + "description": "Document data as JSON object. Include only fields and value pairs to be updated.", + "x-example": "{}" + }, + "permissions": { + "type": "array", + "description": "An array of permissions strings. By default, the current permissions are inherited. [Learn more about permissions](https:\/\/appwrite.io\/docs\/permissions).", + "x-example": "[\"read(\"any\")\"]", + "items": { + "type": "string" + } + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "x-example": "" + } + } + } + } + } + } + }, + "delete": { + "summary": "Delete document", + "operationId": "documentsDBDeleteDocument", + "tags": [ + "documentsDB" + ], + "description": "Delete a document by its unique ID.", + "responses": { + "204": { + "description": "No content" + } + }, + "deprecated": false, + "x-appwrite": { + "method": "deleteDocument", + "group": "documents", + "weight": 453, + "cookies": false, + "type": "", + "demo": "documentsdb\/delete-document.md", + "rate-limit": 60, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/delete-document.md", + "auth": { + "Project": [], + "Session": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "Key": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "x-example": "" + } + } + } + } + } + } + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/documents\/{documentId}\/{attribute}\/decrement": { + "patch": { + "summary": "Decrement document attribute", + "operationId": "documentsDBDecrementDocumentAttribute", + "tags": [ + "documentsDB" + ], + "description": "Decrement a specific column of a row by a given value.", + "responses": { + "200": { + "description": "Document", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/document" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "decrementDocumentAttribute", + "group": "documents", + "weight": 458, + "cookies": false, + "type": "", + "demo": "documentsdb\/decrement-document-attribute.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server", + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/decrement-document-attribute.md", + "auth": { + "Project": [], + "Session": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "JWT": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "attribute", + "description": "Attribute key.", + "required": true, + "schema": { + "type": "string" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "value": { + "type": "number", + "description": "Value to decrement the attribute by. The value must be a number.", + "x-example": null + }, + "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 + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "x-example": "" + } + } + } + } + } + } + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/documents\/{documentId}\/{attribute}\/increment": { + "patch": { + "summary": "Increment document attribute", + "operationId": "documentsDBIncrementDocumentAttribute", + "tags": [ + "documentsDB" + ], + "description": "Increment a specific column of a row by a given value.", + "responses": { + "200": { + "description": "Document", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/document" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "incrementDocumentAttribute", + "group": "documents", + "weight": 457, + "cookies": false, + "type": "", + "demo": "documentsdb\/increment-document-attribute.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server", + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/increment-document-attribute.md", + "auth": { + "Project": [], + "Session": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "JWT": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "attribute", + "description": "Attribute key.", + "required": true, + "schema": { + "type": "string" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "value": { + "type": "number", + "description": "Value to increment the attribute by. The value must be a number.", + "x-example": null + }, + "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 + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "x-example": "" + } + } + } + } + } + } + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/indexes": { + "get": { + "summary": "List indexes", + "operationId": "documentsDBListIndexes", + "tags": [ + "documentsDB" + ], + "description": "List indexes in the collection.", + "responses": { + "200": { + "description": "Indexes List", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/indexList" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "listIndexes", + "group": "indexes", + "weight": 446, + "cookies": false, + "type": "", + "demo": "documentsdb\/list-indexes.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/list-indexes.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following attributes: key, type, status, attributes, error", + "required": false, + "schema": { + "type": "array", + "items": { + "type": "string" + }, + "default": [] + }, + "in": "query" + }, + { + "name": "total", + "description": "When set to false, the total count returned will be 0 and will not be calculated.", + "required": false, + "schema": { + "type": "boolean", + "x-example": false, + "default": true + }, + "in": "query" + } + ] + }, + "post": { + "summary": "Create index", + "operationId": "documentsDBCreateIndex", + "tags": [ + "documentsDB" + ], + "description": "Creates an index on the attributes listed. Your index should include all the attributes you will query in a single request.\nAttributes can be `key`, `fulltext`, and `unique`.", + "responses": { + "202": { + "description": "Index", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/index" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "createIndex", + "group": "indexes", + "weight": 443, + "cookies": false, + "type": "", + "demo": "documentsdb\/create-index.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/create-index.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + } + ], + "requestBody": { + "content": { + "application\/json": { + "schema": { + "type": "object", + "properties": { + "key": { + "type": "string", + "description": "Index Key.", + "x-example": null + }, + "type": { + "type": "string", + "description": "Index type.", + "x-example": "key", + "enum": [ + "key", + "fulltext", + "unique", + "spatial" + ], + "x-enum-name": "IndexType", + "x-enum-keys": [] + }, + "attributes": { + "type": "array", + "description": "Array of attributes to index. Maximum of 100 attributes are allowed, each 32 characters long.", + "x-example": null, + "items": { + "type": "string" + } + }, + "orders": { + "type": "array", + "description": "Array of index orders. Maximum of 100 orders are allowed.", + "x-example": null, + "items": { + "type": "string", + "enum": [ + "asc", + "desc" + ], + "x-enum-name": "OrderBy", + "x-enum-keys": [] + } + }, + "lengths": { + "type": "array", + "description": "Length of index. Maximum of 100", + "x-example": null, + "items": { + "type": "integer" + } + } + }, + "required": [ + "key", + "type", + "attributes" + ] + } + } + } + } + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/indexes\/{key}": { + "get": { + "summary": "Get index", + "operationId": "documentsDBGetIndex", + "tags": [ + "documentsDB" + ], + "description": "Get index by ID.", + "responses": { + "200": { + "description": "Index", + "content": { + "application\/json": { + "schema": { + "$ref": "#\/components\/schemas\/index" + } + } + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "getIndex", + "group": "indexes", + "weight": 444, + "cookies": false, + "type": "", + "demo": "documentsdb\/get-index.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/get-index.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "key", + "description": "Index Key.", + "required": true, + "schema": { + "type": "string" + }, + "in": "path" + } + ] + }, + "delete": { + "summary": "Delete index", + "operationId": "documentsDBDeleteIndex", + "tags": [ + "documentsDB" + ], + "description": "Delete an index.", + "responses": { + "204": { + "description": "No content" + } + }, + "deprecated": false, + "x-appwrite": { + "method": "deleteIndex", + "group": "indexes", + "weight": 445, + "cookies": false, + "type": "", + "demo": "documentsdb\/delete-index.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/delete-index.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "schema": { + "type": "string", + "x-example": "" + }, + "in": "path" + }, + { + "name": "key", + "description": "Index Key.", + "required": true, + "schema": { + "type": "string" + }, + "in": "path" + } + ] + } + }, "\/functions": { "get": { "summary": "List functions", @@ -12355,7 +15346,7 @@ "x-appwrite": { "method": "list", "group": "functions", - "weight": 439, + "weight": 475, "cookies": false, "type": "", "demo": "functions\/list.md", @@ -12441,7 +15432,7 @@ "x-appwrite": { "method": "create", "group": "functions", - "weight": 436, + "weight": 472, "cookies": false, "type": "", "demo": "functions\/create.md", @@ -12737,7 +15728,7 @@ "x-appwrite": { "method": "listRuntimes", "group": "runtimes", - "weight": 441, + "weight": 477, "cookies": false, "type": "", "demo": "functions\/list-runtimes.md", @@ -12788,7 +15779,7 @@ "x-appwrite": { "method": "listSpecifications", "group": "runtimes", - "weight": 442, + "weight": 478, "cookies": false, "type": "", "demo": "functions\/list-specifications.md", @@ -12839,7 +15830,7 @@ "x-appwrite": { "method": "get", "group": "functions", - "weight": 437, + "weight": 473, "cookies": false, "type": "", "demo": "functions\/get.md", @@ -12900,7 +15891,7 @@ "x-appwrite": { "method": "update", "group": "functions", - "weight": 438, + "weight": 474, "cookies": false, "type": "", "demo": "functions\/update.md", @@ -13193,7 +16184,7 @@ "x-appwrite": { "method": "delete", "group": "functions", - "weight": 440, + "weight": 476, "cookies": false, "type": "", "demo": "functions\/delete.md", @@ -13256,7 +16247,7 @@ "x-appwrite": { "method": "updateFunctionDeployment", "group": "functions", - "weight": 445, + "weight": 481, "cookies": false, "type": "", "demo": "functions\/update-function-deployment.md", @@ -13338,7 +16329,7 @@ "x-appwrite": { "method": "listDeployments", "group": "deployments", - "weight": 446, + "weight": 482, "cookies": false, "type": "", "demo": "functions\/list-deployments.md", @@ -13434,7 +16425,7 @@ "x-appwrite": { "method": "createDeployment", "group": "deployments", - "weight": 443, + "weight": 479, "cookies": false, "type": "upload", "demo": "functions\/create-deployment.md", @@ -13534,7 +16525,7 @@ "x-appwrite": { "method": "createDuplicateDeployment", "group": "deployments", - "weight": 451, + "weight": 487, "cookies": false, "type": "", "demo": "functions\/create-duplicate-deployment.md", @@ -13621,7 +16612,7 @@ "x-appwrite": { "method": "createTemplateDeployment", "group": "deployments", - "weight": 448, + "weight": 484, "cookies": false, "type": "", "demo": "functions\/create-template-deployment.md", @@ -13739,7 +16730,7 @@ "x-appwrite": { "method": "createVcsDeployment", "group": "deployments", - "weight": 449, + "weight": 485, "cookies": false, "type": "", "demo": "functions\/create-vcs-deployment.md", @@ -13838,7 +16829,7 @@ "x-appwrite": { "method": "getDeployment", "group": "deployments", - "weight": 444, + "weight": 480, "cookies": false, "type": "", "demo": "functions\/get-deployment.md", @@ -13902,7 +16893,7 @@ "x-appwrite": { "method": "deleteDeployment", "group": "deployments", - "weight": 447, + "weight": 483, "cookies": false, "type": "", "demo": "functions\/delete-deployment.md", @@ -13968,7 +16959,7 @@ "x-appwrite": { "method": "getDeploymentDownload", "group": "deployments", - "weight": 450, + "weight": 486, "cookies": false, "type": "location", "demo": "functions\/get-deployment-download.md", @@ -14060,7 +17051,7 @@ "x-appwrite": { "method": "updateDeploymentStatus", "group": "deployments", - "weight": 452, + "weight": 488, "cookies": false, "type": "", "demo": "functions\/update-deployment-status.md", @@ -14133,7 +17124,7 @@ "x-appwrite": { "method": "listExecutions", "group": "executions", - "weight": 455, + "weight": 491, "cookies": false, "type": "", "demo": "functions\/list-executions.md", @@ -14222,7 +17213,7 @@ "x-appwrite": { "method": "createExecution", "group": "executions", - "weight": 453, + "weight": 489, "cookies": false, "type": "", "demo": "functions\/create-execution.md", @@ -14342,7 +17333,7 @@ "x-appwrite": { "method": "getExecution", "group": "executions", - "weight": 454, + "weight": 490, "cookies": false, "type": "", "demo": "functions\/get-execution.md", @@ -14410,7 +17401,7 @@ "x-appwrite": { "method": "deleteExecution", "group": "executions", - "weight": 456, + "weight": 492, "cookies": false, "type": "", "demo": "functions\/delete-execution.md", @@ -14483,7 +17474,7 @@ "x-appwrite": { "method": "listVariables", "group": "variables", - "weight": 461, + "weight": 497, "cookies": false, "type": "", "demo": "functions\/list-variables.md", @@ -14544,7 +17535,7 @@ "x-appwrite": { "method": "createVariable", "group": "variables", - "weight": 459, + "weight": 495, "cookies": false, "type": "", "demo": "functions\/create-variable.md", @@ -14637,7 +17628,7 @@ "x-appwrite": { "method": "getVariable", "group": "variables", - "weight": 460, + "weight": 496, "cookies": false, "type": "", "demo": "functions\/get-variable.md", @@ -14708,7 +17699,7 @@ "x-appwrite": { "method": "updateVariable", "group": "variables", - "weight": 462, + "weight": 498, "cookies": false, "type": "", "demo": "functions\/update-variable.md", @@ -14803,7 +17794,7 @@ "x-appwrite": { "method": "deleteVariable", "group": "variables", - "weight": 463, + "weight": 499, "cookies": false, "type": "", "demo": "functions\/delete-variable.md", @@ -22240,7 +25231,7 @@ "x-appwrite": { "method": "list", "group": "sites", - "weight": 468, + "weight": 504, "cookies": false, "type": "", "demo": "sites\/list.md", @@ -22326,7 +25317,7 @@ "x-appwrite": { "method": "create", "group": "sites", - "weight": 466, + "weight": 502, "cookies": false, "type": "", "demo": "sites\/create.md", @@ -22580,7 +25571,7 @@ "x-appwrite": { "method": "listFrameworks", "group": "frameworks", - "weight": 471, + "weight": 507, "cookies": false, "type": "", "demo": "sites\/list-frameworks.md", @@ -22631,7 +25622,7 @@ "x-appwrite": { "method": "listSpecifications", "group": "frameworks", - "weight": 494, + "weight": 530, "cookies": false, "type": "", "demo": "sites\/list-specifications.md", @@ -22682,7 +25673,7 @@ "x-appwrite": { "method": "get", "group": "sites", - "weight": 467, + "weight": 503, "cookies": false, "type": "", "demo": "sites\/get.md", @@ -22743,7 +25734,7 @@ "x-appwrite": { "method": "update", "group": "sites", - "weight": 469, + "weight": 505, "cookies": false, "type": "", "demo": "sites\/update.md", @@ -22993,7 +25984,7 @@ "x-appwrite": { "method": "delete", "group": "sites", - "weight": 470, + "weight": 506, "cookies": false, "type": "", "demo": "sites\/delete.md", @@ -23056,7 +26047,7 @@ "x-appwrite": { "method": "updateSiteDeployment", "group": "sites", - "weight": 477, + "weight": 513, "cookies": false, "type": "", "demo": "sites\/update-site-deployment.md", @@ -23138,7 +26129,7 @@ "x-appwrite": { "method": "listDeployments", "group": "deployments", - "weight": 476, + "weight": 512, "cookies": false, "type": "", "demo": "sites\/list-deployments.md", @@ -23234,7 +26225,7 @@ "x-appwrite": { "method": "createDeployment", "group": "deployments", - "weight": 472, + "weight": 508, "cookies": false, "type": "upload", "demo": "sites\/create-deployment.md", @@ -23340,7 +26331,7 @@ "x-appwrite": { "method": "createDuplicateDeployment", "group": "deployments", - "weight": 480, + "weight": 516, "cookies": false, "type": "", "demo": "sites\/create-duplicate-deployment.md", @@ -23422,7 +26413,7 @@ "x-appwrite": { "method": "createTemplateDeployment", "group": "deployments", - "weight": 473, + "weight": 509, "cookies": false, "type": "", "demo": "sites\/create-template-deployment.md", @@ -23540,7 +26531,7 @@ "x-appwrite": { "method": "createVcsDeployment", "group": "deployments", - "weight": 474, + "weight": 510, "cookies": false, "type": "", "demo": "sites\/create-vcs-deployment.md", @@ -23640,7 +26631,7 @@ "x-appwrite": { "method": "getDeployment", "group": "deployments", - "weight": 475, + "weight": 511, "cookies": false, "type": "", "demo": "sites\/get-deployment.md", @@ -23704,7 +26695,7 @@ "x-appwrite": { "method": "deleteDeployment", "group": "deployments", - "weight": 478, + "weight": 514, "cookies": false, "type": "", "demo": "sites\/delete-deployment.md", @@ -23770,7 +26761,7 @@ "x-appwrite": { "method": "getDeploymentDownload", "group": "deployments", - "weight": 479, + "weight": 515, "cookies": false, "type": "location", "demo": "sites\/get-deployment-download.md", @@ -23862,7 +26853,7 @@ "x-appwrite": { "method": "updateDeploymentStatus", "group": "deployments", - "weight": 481, + "weight": 517, "cookies": false, "type": "", "demo": "sites\/update-deployment-status.md", @@ -23935,7 +26926,7 @@ "x-appwrite": { "method": "listLogs", "group": "logs", - "weight": 483, + "weight": 519, "cookies": false, "type": "", "demo": "sites\/list-logs.md", @@ -24022,7 +27013,7 @@ "x-appwrite": { "method": "getLog", "group": "logs", - "weight": 482, + "weight": 518, "cookies": false, "type": "", "demo": "sites\/get-log.md", @@ -24086,7 +27077,7 @@ "x-appwrite": { "method": "deleteLog", "group": "logs", - "weight": 484, + "weight": 520, "cookies": false, "type": "", "demo": "sites\/delete-log.md", @@ -24159,7 +27150,7 @@ "x-appwrite": { "method": "listVariables", "group": "variables", - "weight": 487, + "weight": 523, "cookies": false, "type": "", "demo": "sites\/list-variables.md", @@ -24220,7 +27211,7 @@ "x-appwrite": { "method": "createVariable", "group": "variables", - "weight": 485, + "weight": 521, "cookies": false, "type": "", "demo": "sites\/create-variable.md", @@ -24313,7 +27304,7 @@ "x-appwrite": { "method": "getVariable", "group": "variables", - "weight": 486, + "weight": 522, "cookies": false, "type": "", "demo": "sites\/get-variable.md", @@ -24384,7 +27375,7 @@ "x-appwrite": { "method": "updateVariable", "group": "variables", - "weight": 488, + "weight": 524, "cookies": false, "type": "", "demo": "sites\/update-variable.md", @@ -24479,7 +27470,7 @@ "x-appwrite": { "method": "deleteVariable", "group": "variables", - "weight": 489, + "weight": 525, "cookies": false, "type": "", "demo": "sites\/delete-variable.md", @@ -24552,7 +27543,7 @@ "x-appwrite": { "method": "listBuckets", "group": "buckets", - "weight": 521, + "weight": 557, "cookies": false, "type": "", "demo": "storage\/list-buckets.md", @@ -24639,7 +27630,7 @@ "x-appwrite": { "method": "createBucket", "group": "buckets", - "weight": 519, + "weight": 555, "cookies": false, "type": "", "demo": "storage\/create-bucket.md", @@ -24775,7 +27766,7 @@ "x-appwrite": { "method": "getBucket", "group": "buckets", - "weight": 520, + "weight": 556, "cookies": false, "type": "", "demo": "storage\/get-bucket.md", @@ -24837,7 +27828,7 @@ "x-appwrite": { "method": "updateBucket", "group": "buckets", - "weight": 522, + "weight": 558, "cookies": false, "type": "", "demo": "storage\/update-bucket.md", @@ -24970,7 +27961,7 @@ "x-appwrite": { "method": "deleteBucket", "group": "buckets", - "weight": 523, + "weight": 559, "cookies": false, "type": "", "demo": "storage\/delete-bucket.md", @@ -25034,7 +28025,7 @@ "x-appwrite": { "method": "listFiles", "group": "files", - "weight": 526, + "weight": 562, "cookies": false, "type": "", "demo": "storage\/list-files.md", @@ -25135,7 +28126,7 @@ "x-appwrite": { "method": "createFile", "group": "files", - "weight": 524, + "weight": 560, "cookies": false, "type": "upload", "demo": "storage\/create-file.md", @@ -25238,7 +28229,7 @@ "x-appwrite": { "method": "getFile", "group": "files", - "weight": 525, + "weight": 561, "cookies": false, "type": "", "demo": "storage\/get-file.md", @@ -25314,7 +28305,7 @@ "x-appwrite": { "method": "updateFile", "group": "files", - "weight": 527, + "weight": 563, "cookies": false, "type": "", "demo": "storage\/update-file.md", @@ -25408,7 +28399,7 @@ "x-appwrite": { "method": "deleteFile", "group": "files", - "weight": 528, + "weight": 564, "cookies": false, "type": "", "demo": "storage\/delete-file.md", @@ -25479,7 +28470,7 @@ "x-appwrite": { "method": "getFileDownload", "group": "files", - "weight": 530, + "weight": 566, "cookies": false, "type": "location", "demo": "storage\/get-file-download.md", @@ -25561,7 +28552,7 @@ "x-appwrite": { "method": "getFilePreview", "group": "files", - "weight": 529, + "weight": 565, "cookies": false, "type": "location", "demo": "storage\/get-file-preview.md", @@ -25793,7 +28784,7 @@ "x-appwrite": { "method": "getFileView", "group": "files", - "weight": 531, + "weight": 567, "cookies": false, "type": "location", "demo": "storage\/get-file-view.md", @@ -33532,7 +36523,7 @@ "x-appwrite": { "method": "list", "group": "files", - "weight": 516, + "weight": 552, "cookies": false, "type": "", "demo": "tokens\/list.md", @@ -33627,7 +36618,7 @@ "x-appwrite": { "method": "createFileToken", "group": "files", - "weight": 514, + "weight": 550, "cookies": false, "type": "", "demo": "tokens\/create-file-token.md", @@ -33717,7 +36708,7 @@ "x-appwrite": { "method": "get", "group": "tokens", - "weight": 515, + "weight": 551, "cookies": false, "type": "", "demo": "tokens\/get.md", @@ -33778,7 +36769,7 @@ "x-appwrite": { "method": "update", "group": "tokens", - "weight": 517, + "weight": 553, "cookies": false, "type": "", "demo": "tokens\/update.md", @@ -33849,7 +36840,7 @@ "x-appwrite": { "method": "delete", "group": "tokens", - "weight": 518, + "weight": 554, "cookies": false, "type": "", "demo": "tokens\/delete.md", @@ -38805,7 +41796,8 @@ "x-example": "legacy", "enum": [ "legacy", - "tablesdb" + "tablesdb", + "documentsdb" ] } }, diff --git a/app/config/specs/swagger2-latest-client.json b/app/config/specs/swagger2-latest-client.json index 4a153706ac..dffbb84102 100644 --- a/app/config/specs/swagger2-latest-client.json +++ b/app/config/specs/swagger2-latest-client.json @@ -1,7 +1,7 @@ { "swagger": "2.0", "info": { - "version": "1.8.0", + "version": "1.8.1", "title": "Appwrite", "description": "Appwrite backend as a service cuts up to 70% of the time and costs required for building a modern application. We abstract and simplify common development tasks behind a REST APIs, to help you develop your app in a fast and secure way. For full API documentation and tutorials go to [https:\/\/appwrite.io\/docs](https:\/\/appwrite.io\/docs)", "termsOfService": "https:\/\/appwrite.io\/policy\/terms", @@ -94,7 +94,7 @@ "x-appwrite": { "method": "get", "group": "account", - "weight": 10, + "weight": 9, "cookies": false, "type": "", "demo": "account\/get.md", @@ -147,7 +147,7 @@ "x-appwrite": { "method": "create", "group": "account", - "weight": 9, + "weight": 8, "cookies": false, "type": "", "demo": "account\/create.md", @@ -242,7 +242,7 @@ "x-appwrite": { "method": "updateEmail", "group": "account", - "weight": 35, + "weight": 34, "cookies": false, "type": "", "demo": "account\/update-email.md", @@ -322,7 +322,7 @@ "x-appwrite": { "method": "listIdentities", "group": "identities", - "weight": 48, + "weight": 47, "cookies": false, "type": "", "demo": "account\/list-identities.md", @@ -395,7 +395,7 @@ "x-appwrite": { "method": "deleteIdentity", "group": "identities", - "weight": 49, + "weight": 48, "cookies": false, "type": "", "demo": "account\/delete-identity.md", @@ -460,7 +460,7 @@ "x-appwrite": { "method": "createJWT", "group": "tokens", - "weight": 30, + "weight": 29, "cookies": false, "type": "", "demo": "account\/create-jwt.md", @@ -530,7 +530,7 @@ "x-appwrite": { "method": "listLogs", "group": "logs", - "weight": 32, + "weight": 31, "cookies": false, "type": "", "demo": "account\/list-logs.md", @@ -608,7 +608,7 @@ "x-appwrite": { "method": "updateMFA", "group": "mfa", - "weight": 291, + "weight": 288, "cookies": false, "type": "", "demo": "account\/update-mfa.md", @@ -683,7 +683,7 @@ "x-appwrite": { "method": "createMfaAuthenticator", "group": "mfa", - "weight": 293, + "weight": 290, "cookies": false, "type": "", "demo": "account\/create-mfa-authenticator.md", @@ -807,7 +807,7 @@ "x-appwrite": { "method": "updateMfaAuthenticator", "group": "mfa", - "weight": 294, + "weight": 291, "cookies": false, "type": "", "demo": "account\/update-mfa-authenticator.md", @@ -948,7 +948,7 @@ "x-appwrite": { "method": "deleteMfaAuthenticator", "group": "mfa", - "weight": 295, + "weight": 292, "cookies": false, "type": "", "demo": "account\/delete-mfa-authenticator.md", @@ -1072,7 +1072,7 @@ "x-appwrite": { "method": "createMfaChallenge", "group": "mfa", - "weight": 299, + "weight": 296, "cookies": false, "type": "", "demo": "account\/create-mfa-challenge.md", @@ -1209,7 +1209,7 @@ "x-appwrite": { "method": "updateMfaChallenge", "group": "mfa", - "weight": 300, + "weight": 297, "cookies": false, "type": "", "demo": "account\/update-mfa-challenge.md", @@ -1349,7 +1349,7 @@ "x-appwrite": { "method": "listMfaFactors", "group": "mfa", - "weight": 292, + "weight": 289, "cookies": false, "type": "", "demo": "account\/list-mfa-factors.md", @@ -1450,7 +1450,7 @@ "x-appwrite": { "method": "getMfaRecoveryCodes", "group": "mfa", - "weight": 298, + "weight": 295, "cookies": false, "type": "", "demo": "account\/get-mfa-recovery-codes.md", @@ -1551,7 +1551,7 @@ "x-appwrite": { "method": "createMfaRecoveryCodes", "group": "mfa", - "weight": 296, + "weight": 293, "cookies": false, "type": "", "demo": "account\/create-mfa-recovery-codes.md", @@ -1652,7 +1652,7 @@ "x-appwrite": { "method": "updateMfaRecoveryCodes", "group": "mfa", - "weight": 297, + "weight": 294, "cookies": false, "type": "", "demo": "account\/update-mfa-recovery-codes.md", @@ -1755,7 +1755,7 @@ "x-appwrite": { "method": "updateName", "group": "account", - "weight": 33, + "weight": 32, "cookies": false, "type": "", "demo": "account\/update-name.md", @@ -1830,7 +1830,7 @@ "x-appwrite": { "method": "updatePassword", "group": "account", - "weight": 34, + "weight": 33, "cookies": false, "type": "", "demo": "account\/update-password.md", @@ -1911,7 +1911,7 @@ "x-appwrite": { "method": "updatePhone", "group": "account", - "weight": 36, + "weight": 35, "cookies": false, "type": "", "demo": "account\/update-phone.md", @@ -1991,7 +1991,7 @@ "x-appwrite": { "method": "getPrefs", "group": "account", - "weight": 31, + "weight": 30, "cookies": false, "type": "", "demo": "account\/get-prefs.md", @@ -2044,7 +2044,7 @@ "x-appwrite": { "method": "updatePrefs", "group": "account", - "weight": 37, + "weight": 36, "cookies": false, "type": "", "demo": "account\/update-prefs.md", @@ -2119,7 +2119,7 @@ "x-appwrite": { "method": "createRecovery", "group": "recovery", - "weight": 39, + "weight": 38, "cookies": false, "type": "", "demo": "account\/create-recovery.md", @@ -2202,7 +2202,7 @@ "x-appwrite": { "method": "updateRecovery", "group": "recovery", - "weight": 40, + "weight": 39, "cookies": false, "type": "", "demo": "account\/update-recovery.md", @@ -2289,7 +2289,7 @@ "x-appwrite": { "method": "listSessions", "group": "sessions", - "weight": 12, + "weight": 11, "cookies": false, "type": "", "demo": "account\/list-sessions.md", @@ -2337,7 +2337,7 @@ "x-appwrite": { "method": "deleteSessions", "group": "sessions", - "weight": 13, + "weight": 12, "cookies": false, "type": "", "demo": "account\/delete-sessions.md", @@ -2392,7 +2392,7 @@ "x-appwrite": { "method": "createAnonymousSession", "group": "sessions", - "weight": 18, + "weight": 17, "cookies": false, "type": "", "demo": "account\/create-anonymous-session.md", @@ -2447,7 +2447,7 @@ "x-appwrite": { "method": "createEmailPasswordSession", "group": "sessions", - "weight": 17, + "weight": 16, "cookies": false, "type": "", "demo": "account\/create-email-password-session.md", @@ -2529,7 +2529,7 @@ "x-appwrite": { "method": "updateMagicURLSession", "group": "sessions", - "weight": 27, + "weight": 26, "cookies": false, "type": "", "demo": "account\/update-magic-url-session.md", @@ -2610,7 +2610,7 @@ "x-appwrite": { "method": "createOAuth2Session", "group": "sessions", - "weight": 20, + "weight": 19, "cookies": false, "type": "webAuth", "demo": "account\/create-o-auth-2-session.md", @@ -2752,7 +2752,7 @@ "x-appwrite": { "method": "updatePhoneSession", "group": "sessions", - "weight": 28, + "weight": 27, "cookies": false, "type": "", "demo": "account\/update-phone-session.md", @@ -2838,7 +2838,7 @@ "x-appwrite": { "method": "createSession", "group": "sessions", - "weight": 19, + "weight": 18, "cookies": false, "type": "", "demo": "account\/create-session.md", @@ -2918,7 +2918,7 @@ "x-appwrite": { "method": "getSession", "group": "sessions", - "weight": 14, + "weight": 13, "cookies": false, "type": "", "demo": "account\/get-session.md", @@ -2981,7 +2981,7 @@ "x-appwrite": { "method": "updateSession", "group": "sessions", - "weight": 16, + "weight": 15, "cookies": false, "type": "", "demo": "account\/update-session.md", @@ -3039,7 +3039,7 @@ "x-appwrite": { "method": "deleteSession", "group": "sessions", - "weight": 15, + "weight": 14, "cookies": false, "type": "", "demo": "account\/delete-session.md", @@ -3104,7 +3104,7 @@ "x-appwrite": { "method": "updateStatus", "group": "account", - "weight": 38, + "weight": 37, "cookies": false, "type": "", "demo": "account\/update-status.md", @@ -3159,7 +3159,7 @@ "x-appwrite": { "method": "createPushTarget", "group": "pushTargets", - "weight": 45, + "weight": 44, "cookies": false, "type": "", "demo": "account\/create-push-target.md", @@ -3245,7 +3245,7 @@ "x-appwrite": { "method": "updatePushTarget", "group": "pushTargets", - "weight": 46, + "weight": 45, "cookies": false, "type": "", "demo": "account\/update-push-target.md", @@ -3319,7 +3319,7 @@ "x-appwrite": { "method": "deletePushTarget", "group": "pushTargets", - "weight": 47, + "weight": 46, "cookies": false, "type": "", "demo": "account\/delete-push-target.md", @@ -3382,7 +3382,7 @@ "x-appwrite": { "method": "createEmailToken", "group": "tokens", - "weight": 26, + "weight": 25, "cookies": false, "type": "", "demo": "account\/create-email-token.md", @@ -3473,7 +3473,7 @@ "x-appwrite": { "method": "createMagicURLToken", "group": "tokens", - "weight": 25, + "weight": 24, "cookies": false, "type": "", "demo": "account\/create-magic-url-token.md", @@ -3565,7 +3565,7 @@ "x-appwrite": { "method": "createOAuth2Token", "group": "tokens", - "weight": 24, + "weight": 23, "cookies": false, "type": "webAuth", "demo": "account\/create-o-auth-2-token.md", @@ -3707,7 +3707,7 @@ "x-appwrite": { "method": "createPhoneToken", "group": "tokens", - "weight": 29, + "weight": 28, "cookies": false, "type": "", "demo": "account\/create-phone-token.md", @@ -3792,7 +3792,7 @@ "x-appwrite": { "method": "createEmailVerification", "group": "verification", - "weight": 41, + "weight": 40, "cookies": false, "type": "", "demo": "account\/create-email-verification.md", @@ -3917,7 +3917,7 @@ "x-appwrite": { "method": "updateEmailVerification", "group": "verification", - "weight": 42, + "weight": 41, "cookies": false, "type": "", "demo": "account\/update-email-verification.md", @@ -4055,7 +4055,7 @@ "x-appwrite": { "method": "createPhoneVerification", "group": "verification", - "weight": 43, + "weight": 42, "cookies": false, "type": "", "demo": "account\/create-phone-verification.md", @@ -4111,7 +4111,7 @@ "x-appwrite": { "method": "updatePhoneVerification", "group": "verification", - "weight": 44, + "weight": 43, "cookies": false, "type": "", "demo": "account\/update-phone-verification.md", @@ -4191,7 +4191,7 @@ "x-appwrite": { "method": "getBrowser", "group": null, - "weight": 51, + "weight": 50, "cookies": false, "type": "location", "demo": "avatars\/get-browser.md", @@ -4317,7 +4317,7 @@ "x-appwrite": { "method": "getCreditCard", "group": null, - "weight": 50, + "weight": 49, "cookies": false, "type": "location", "demo": "avatars\/get-credit-card.md", @@ -4449,7 +4449,7 @@ "x-appwrite": { "method": "getFavicon", "group": null, - "weight": 54, + "weight": 53, "cookies": false, "type": "location", "demo": "avatars\/get-favicon.md", @@ -4513,7 +4513,7 @@ "x-appwrite": { "method": "getFlag", "group": null, - "weight": 52, + "weight": 51, "cookies": false, "type": "location", "demo": "avatars\/get-flag.md", @@ -5001,7 +5001,7 @@ "x-appwrite": { "method": "getImage", "group": null, - "weight": 53, + "weight": 52, "cookies": false, "type": "location", "demo": "avatars\/get-image.md", @@ -5085,7 +5085,7 @@ "x-appwrite": { "method": "getInitials", "group": null, - "weight": 56, + "weight": 55, "cookies": false, "type": "location", "demo": "avatars\/get-initials.md", @@ -5177,7 +5177,7 @@ "x-appwrite": { "method": "getQR", "group": null, - "weight": 55, + "weight": 54, "cookies": false, "type": "location", "demo": "avatars\/get-qr.md", @@ -5269,7 +5269,7 @@ "x-appwrite": { "method": "getScreenshot", "group": null, - "weight": 57, + "weight": 56, "cookies": false, "type": "location", "demo": "avatars\/get-screenshot.md", @@ -5982,7 +5982,7 @@ "x-appwrite": { "method": "listTransactions", "group": "transactions", - "weight": 365, + "weight": 362, "cookies": false, "type": "", "demo": "databases\/list-transactions.md", @@ -6049,7 +6049,7 @@ "x-appwrite": { "method": "createTransaction", "group": "transactions", - "weight": 361, + "weight": 358, "cookies": false, "type": "", "demo": "databases\/create-transaction.md", @@ -6119,7 +6119,7 @@ "x-appwrite": { "method": "getTransaction", "group": "transactions", - "weight": 362, + "weight": 359, "cookies": false, "type": "", "demo": "databases\/get-transaction.md", @@ -6182,7 +6182,7 @@ "x-appwrite": { "method": "updateTransaction", "group": "transactions", - "weight": 363, + "weight": 360, "cookies": false, "type": "", "demo": "databases\/update-transaction.md", @@ -6261,7 +6261,7 @@ "x-appwrite": { "method": "deleteTransaction", "group": "transactions", - "weight": 364, + "weight": 361, "cookies": false, "type": "", "demo": "databases\/delete-transaction.md", @@ -6326,7 +6326,7 @@ "x-appwrite": { "method": "createOperations", "group": "transactions", - "weight": 366, + "weight": 363, "cookies": false, "type": "", "demo": "databases\/create-operations.md", @@ -6407,7 +6407,7 @@ "x-appwrite": { "method": "listDocuments", "group": "documents", - "weight": 324, + "weight": 321, "cookies": false, "type": "", "demo": "databases\/list-documents.md", @@ -6511,7 +6511,7 @@ "x-appwrite": { "method": "createDocument", "group": "documents", - "weight": 316, + "weight": 313, "cookies": false, "type": "", "demo": "databases\/create-document.md", @@ -6670,7 +6670,7 @@ "x-appwrite": { "method": "getDocument", "group": "documents", - "weight": 317, + "weight": 314, "cookies": false, "type": "", "demo": "databases\/get-document.md", @@ -6773,7 +6773,7 @@ "x-appwrite": { "method": "upsertDocument", "group": "documents", - "weight": 320, + "weight": 317, "cookies": false, "type": "", "demo": "databases\/upsert-document.md", @@ -6924,7 +6924,7 @@ "x-appwrite": { "method": "updateDocument", "group": "documents", - "weight": 318, + "weight": 315, "cookies": false, "type": "", "demo": "databases\/update-document.md", @@ -7034,7 +7034,7 @@ "x-appwrite": { "method": "deleteDocument", "group": "documents", - "weight": 322, + "weight": 319, "cookies": false, "type": "", "demo": "databases\/delete-document.md", @@ -7135,7 +7135,7 @@ "x-appwrite": { "method": "decrementDocumentAttribute", "group": "documents", - "weight": 327, + "weight": 324, "cookies": false, "type": "", "demo": "databases\/decrement-document-attribute.md", @@ -7256,7 +7256,7 @@ "x-appwrite": { "method": "incrementDocumentAttribute", "group": "documents", - "weight": 326, + "weight": 323, "cookies": false, "type": "", "demo": "databases\/increment-document-attribute.md", @@ -7375,7 +7375,7 @@ "x-appwrite": { "method": "listTransactions", "group": "transactions", - "weight": 466, + "weight": 463, "cookies": false, "type": "", "demo": "documentsdb\/list-transactions.md", @@ -7440,7 +7440,7 @@ "x-appwrite": { "method": "createTransaction", "group": "transactions", - "weight": 462, + "weight": 459, "cookies": false, "type": "", "demo": "documentsdb\/create-transaction.md", @@ -7508,7 +7508,7 @@ "x-appwrite": { "method": "getTransaction", "group": "transactions", - "weight": 463, + "weight": 460, "cookies": false, "type": "", "demo": "documentsdb\/get-transaction.md", @@ -7569,7 +7569,7 @@ "x-appwrite": { "method": "updateTransaction", "group": "transactions", - "weight": 464, + "weight": 461, "cookies": false, "type": "", "demo": "documentsdb\/update-transaction.md", @@ -7646,7 +7646,7 @@ "x-appwrite": { "method": "deleteTransaction", "group": "transactions", - "weight": 465, + "weight": 462, "cookies": false, "type": "", "demo": "documentsdb\/delete-transaction.md", @@ -7709,7 +7709,7 @@ "x-appwrite": { "method": "createOperations", "group": "transactions", - "weight": 467, + "weight": 464, "cookies": false, "type": "", "demo": "documentsdb\/create-operations.md", @@ -7788,7 +7788,7 @@ "x-appwrite": { "method": "listDocuments", "group": "documents", - "weight": 458, + "weight": 455, "cookies": false, "type": "", "demo": "documentsdb\/list-documents.md", @@ -7887,7 +7887,7 @@ "x-appwrite": { "method": "createDocument", "group": "documents", - "weight": 450, + "weight": 447, "cookies": false, "type": "", "demo": "documentsdb\/create-document.md", @@ -8034,7 +8034,7 @@ "x-appwrite": { "method": "getDocument", "group": "documents", - "weight": 451, + "weight": 448, "cookies": false, "type": "", "demo": "documentsdb\/get-document.md", @@ -8132,7 +8132,7 @@ "x-appwrite": { "method": "upsertDocument", "group": "documents", - "weight": 454, + "weight": 451, "cookies": false, "type": "", "demo": "documentsdb\/upsert-document.md", @@ -8272,7 +8272,7 @@ "x-appwrite": { "method": "updateDocument", "group": "documents", - "weight": 452, + "weight": 449, "cookies": false, "type": "", "demo": "documentsdb\/update-document.md", @@ -8375,7 +8375,7 @@ "x-appwrite": { "method": "deleteDocument", "group": "documents", - "weight": 456, + "weight": 453, "cookies": false, "type": "", "demo": "documentsdb\/delete-document.md", @@ -8470,7 +8470,7 @@ "x-appwrite": { "method": "decrementDocumentAttribute", "group": "documents", - "weight": 461, + "weight": 458, "cookies": false, "type": "", "demo": "documentsdb\/decrement-document-attribute.md", @@ -8585,7 +8585,7 @@ "x-appwrite": { "method": "incrementDocumentAttribute", "group": "documents", - "weight": 460, + "weight": 457, "cookies": false, "type": "", "demo": "documentsdb\/increment-document-attribute.md", @@ -8698,7 +8698,7 @@ "x-appwrite": { "method": "listExecutions", "group": "executions", - "weight": 493, + "weight": 491, "cookies": false, "type": "", "demo": "functions\/list-executions.md", @@ -8781,7 +8781,7 @@ "x-appwrite": { "method": "createExecution", "group": "executions", - "weight": 491, + "weight": 489, "cookies": false, "type": "", "demo": "functions\/create-execution.md", @@ -8900,7 +8900,7 @@ "x-appwrite": { "method": "getExecution", "group": "executions", - "weight": 492, + "weight": 490, "cookies": false, "type": "", "demo": "functions\/get-execution.md", @@ -8972,7 +8972,7 @@ "x-appwrite": { "method": "query", "group": "graphql", - "weight": 226, + "weight": 225, "cookies": false, "type": "graphql", "demo": "graphql\/query.md", @@ -9047,7 +9047,7 @@ "x-appwrite": { "method": "mutation", "group": "graphql", - "weight": 225, + "weight": 224, "cookies": false, "type": "graphql", "demo": "graphql\/mutation.md", @@ -9120,7 +9120,7 @@ "x-appwrite": { "method": "get", "group": null, - "weight": 61, + "weight": 60, "cookies": false, "type": "", "demo": "locale\/get.md", @@ -9173,7 +9173,7 @@ "x-appwrite": { "method": "listCodes", "group": null, - "weight": 62, + "weight": 61, "cookies": false, "type": "", "demo": "locale\/list-codes.md", @@ -9226,7 +9226,7 @@ "x-appwrite": { "method": "listContinents", "group": null, - "weight": 66, + "weight": 65, "cookies": false, "type": "", "demo": "locale\/list-continents.md", @@ -9279,7 +9279,7 @@ "x-appwrite": { "method": "listCountries", "group": null, - "weight": 63, + "weight": 62, "cookies": false, "type": "", "demo": "locale\/list-countries.md", @@ -9332,7 +9332,7 @@ "x-appwrite": { "method": "listCountriesEU", "group": null, - "weight": 64, + "weight": 63, "cookies": false, "type": "", "demo": "locale\/list-countries-eu.md", @@ -9385,7 +9385,7 @@ "x-appwrite": { "method": "listCountriesPhones", "group": null, - "weight": 65, + "weight": 64, "cookies": false, "type": "", "demo": "locale\/list-countries-phones.md", @@ -9438,7 +9438,7 @@ "x-appwrite": { "method": "listCurrencies", "group": null, - "weight": 67, + "weight": 66, "cookies": false, "type": "", "demo": "locale\/list-currencies.md", @@ -9491,7 +9491,7 @@ "x-appwrite": { "method": "listLanguages", "group": null, - "weight": 68, + "weight": 67, "cookies": false, "type": "", "demo": "locale\/list-languages.md", @@ -9546,7 +9546,7 @@ "x-appwrite": { "method": "createSubscriber", "group": "subscribers", - "weight": 275, + "weight": 272, "cookies": false, "type": "", "demo": "messaging\/create-subscriber.md", @@ -9631,7 +9631,7 @@ "x-appwrite": { "method": "deleteSubscriber", "group": "subscribers", - "weight": 279, + "weight": 276, "cookies": false, "type": "", "demo": "messaging\/delete-subscriber.md", @@ -9702,7 +9702,7 @@ "x-appwrite": { "method": "listFiles", "group": "files", - "weight": 554, + "weight": 562, "cookies": false, "type": "", "demo": "storage\/list-files.md", @@ -9795,7 +9795,7 @@ "x-appwrite": { "method": "createFile", "group": "files", - "weight": 552, + "weight": 560, "cookies": false, "type": "upload", "demo": "storage\/create-file.md", @@ -9886,7 +9886,7 @@ "x-appwrite": { "method": "getFile", "group": "files", - "weight": 553, + "weight": 561, "cookies": false, "type": "", "demo": "storage\/get-file.md", @@ -9957,7 +9957,7 @@ "x-appwrite": { "method": "updateFile", "group": "files", - "weight": 555, + "weight": 563, "cookies": false, "type": "", "demo": "storage\/update-file.md", @@ -10048,7 +10048,7 @@ "x-appwrite": { "method": "deleteFile", "group": "files", - "weight": 556, + "weight": 564, "cookies": false, "type": "", "demo": "storage\/delete-file.md", @@ -10119,7 +10119,7 @@ "x-appwrite": { "method": "getFileDownload", "group": "files", - "weight": 558, + "weight": 566, "cookies": false, "type": "location", "demo": "storage\/get-file-download.md", @@ -10199,7 +10199,7 @@ "x-appwrite": { "method": "getFilePreview", "group": "files", - "weight": 557, + "weight": 565, "cookies": false, "type": "location", "demo": "storage\/get-file-preview.md", @@ -10407,7 +10407,7 @@ "x-appwrite": { "method": "getFileView", "group": "files", - "weight": 559, + "weight": 567, "cookies": false, "type": "location", "demo": "storage\/get-file-view.md", @@ -10487,7 +10487,7 @@ "x-appwrite": { "method": "listTransactions", "group": "transactions", - "weight": 430, + "weight": 427, "cookies": false, "type": "", "demo": "tablesdb\/list-transactions.md", @@ -10557,7 +10557,7 @@ "x-appwrite": { "method": "createTransaction", "group": "transactions", - "weight": 426, + "weight": 423, "cookies": false, "type": "", "demo": "tablesdb\/create-transaction.md", @@ -10630,7 +10630,7 @@ "x-appwrite": { "method": "getTransaction", "group": "transactions", - "weight": 427, + "weight": 424, "cookies": false, "type": "", "demo": "tablesdb\/get-transaction.md", @@ -10696,7 +10696,7 @@ "x-appwrite": { "method": "updateTransaction", "group": "transactions", - "weight": 428, + "weight": 425, "cookies": false, "type": "", "demo": "tablesdb\/update-transaction.md", @@ -10778,7 +10778,7 @@ "x-appwrite": { "method": "deleteTransaction", "group": "transactions", - "weight": 429, + "weight": 426, "cookies": false, "type": "", "demo": "tablesdb\/delete-transaction.md", @@ -10846,7 +10846,7 @@ "x-appwrite": { "method": "createOperations", "group": "transactions", - "weight": 431, + "weight": 428, "cookies": false, "type": "", "demo": "tablesdb\/create-operations.md", @@ -10930,7 +10930,7 @@ "x-appwrite": { "method": "listRows", "group": "rows", - "weight": 422, + "weight": 419, "cookies": false, "type": "", "demo": "tablesdb\/list-rows.md", @@ -11033,7 +11033,7 @@ "x-appwrite": { "method": "createRow", "group": "rows", - "weight": 414, + "weight": 411, "cookies": false, "type": "", "demo": "tablesdb\/create-row.md", @@ -11187,7 +11187,7 @@ "x-appwrite": { "method": "getRow", "group": "rows", - "weight": 415, + "weight": 412, "cookies": false, "type": "", "demo": "tablesdb\/get-row.md", @@ -11289,7 +11289,7 @@ "x-appwrite": { "method": "upsertRow", "group": "rows", - "weight": 418, + "weight": 415, "cookies": false, "type": "", "demo": "tablesdb\/upsert-row.md", @@ -11435,7 +11435,7 @@ "x-appwrite": { "method": "updateRow", "group": "rows", - "weight": 416, + "weight": 413, "cookies": false, "type": "", "demo": "tablesdb\/update-row.md", @@ -11544,7 +11544,7 @@ "x-appwrite": { "method": "deleteRow", "group": "rows", - "weight": 420, + "weight": 417, "cookies": false, "type": "", "demo": "tablesdb\/delete-row.md", @@ -11644,7 +11644,7 @@ "x-appwrite": { "method": "decrementRowColumn", "group": "rows", - "weight": 425, + "weight": 422, "cookies": false, "type": "", "demo": "tablesdb\/decrement-row-column.md", @@ -11764,7 +11764,7 @@ "x-appwrite": { "method": "incrementRowColumn", "group": "rows", - "weight": 424, + "weight": 421, "cookies": false, "type": "", "demo": "tablesdb\/increment-row-column.md", @@ -11882,7 +11882,7 @@ "x-appwrite": { "method": "list", "group": "teams", - "weight": 146, + "weight": 145, "cookies": false, "type": "", "demo": "teams\/list.md", @@ -11967,7 +11967,7 @@ "x-appwrite": { "method": "create", "group": "teams", - "weight": 145, + "weight": 144, "cookies": false, "type": "", "demo": "teams\/create.md", @@ -12058,7 +12058,7 @@ "x-appwrite": { "method": "get", "group": "teams", - "weight": 147, + "weight": 146, "cookies": false, "type": "", "demo": "teams\/get.md", @@ -12121,7 +12121,7 @@ "x-appwrite": { "method": "updateName", "group": "teams", - "weight": 149, + "weight": 148, "cookies": false, "type": "", "demo": "teams\/update-name.md", @@ -12197,7 +12197,7 @@ "x-appwrite": { "method": "delete", "group": "teams", - "weight": 151, + "weight": 150, "cookies": false, "type": "", "demo": "teams\/delete.md", @@ -12260,7 +12260,7 @@ "x-appwrite": { "method": "listMemberships", "group": "memberships", - "weight": 153, + "weight": 152, "cookies": false, "type": "", "demo": "teams\/list-memberships.md", @@ -12353,7 +12353,7 @@ "x-appwrite": { "method": "createMembership", "group": "memberships", - "weight": 152, + "weight": 151, "cookies": false, "type": "", "demo": "teams\/create-membership.md", @@ -12474,7 +12474,7 @@ "x-appwrite": { "method": "getMembership", "group": "memberships", - "weight": 154, + "weight": 153, "cookies": false, "type": "", "demo": "teams\/get-membership.md", @@ -12545,7 +12545,7 @@ "x-appwrite": { "method": "updateMembership", "group": "memberships", - "weight": 155, + "weight": 154, "cookies": false, "type": "", "demo": "teams\/update-membership.md", @@ -12639,7 +12639,7 @@ "x-appwrite": { "method": "deleteMembership", "group": "memberships", - "weight": 157, + "weight": 156, "cookies": false, "type": "", "demo": "teams\/delete-membership.md", @@ -12712,7 +12712,7 @@ "x-appwrite": { "method": "updateMembershipStatus", "group": "memberships", - "weight": 156, + "weight": 155, "cookies": false, "type": "", "demo": "teams\/update-membership-status.md", @@ -12808,7 +12808,7 @@ "x-appwrite": { "method": "getPrefs", "group": "teams", - "weight": 148, + "weight": 147, "cookies": false, "type": "", "demo": "teams\/get-prefs.md", @@ -12871,7 +12871,7 @@ "x-appwrite": { "method": "updatePrefs", "group": "teams", - "weight": 150, + "weight": 149, "cookies": false, "type": "", "demo": "teams\/update-prefs.md", @@ -12992,7 +12992,7 @@ }, { "name": "console", - "description": "The Console service allows you to interact with console relevant informations." + "description": "The Console service allows you to interact with console relevant information." }, { "name": "migrations", diff --git a/app/config/specs/swagger2-latest-console.json b/app/config/specs/swagger2-latest-console.json index 4b384cae76..b9cc3fdc2a 100644 --- a/app/config/specs/swagger2-latest-console.json +++ b/app/config/specs/swagger2-latest-console.json @@ -5993,7 +5993,7 @@ "x-appwrite": { "method": "chat", "group": "console", - "weight": 496, + "weight": 532, "cookies": false, "type": "", "demo": "assistant\/chat.md", @@ -6057,7 +6057,7 @@ "x-appwrite": { "method": "getResource", "group": null, - "weight": 497, + "weight": 533, "cookies": false, "type": "", "demo": "console\/get-resource.md", @@ -6128,7 +6128,7 @@ "x-appwrite": { "method": "variables", "group": "console", - "weight": 495, + "weight": 531, "cookies": false, "type": "", "demo": "console\/variables.md", @@ -10268,6 +10268,118 @@ ] } }, + "\/databases\/{databaseId}\/collections\/{collectionId}\/attributes\/relationship\/{key}": { + "patch": { + "summary": "Update relationship attribute", + "operationId": "databasesUpdateRelationshipAttribute", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "databases" + ], + "description": "Update relationship attribute. [Learn more about relationship attributes](https:\/\/appwrite.io\/docs\/databases-relationships#relationship-attributes).\n", + "responses": { + "200": { + "description": "AttributeRelationship", + "schema": { + "$ref": "#\/definitions\/attributeRelationship" + } + } + }, + "deprecated": true, + "x-appwrite": { + "method": "updateRelationshipAttribute", + "group": "attributes", + "weight": 349, + "cookies": false, + "type": "", + "demo": "databases\/update-relationship-attribute.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/databases\/update-relationship-attribute.md", + "deprecated": { + "since": "1.8.0", + "replaceWith": "tablesDB.updateRelationshipColumn" + }, + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "key", + "description": "Attribute Key.", + "required": true, + "type": "string", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "onDelete": { + "type": "string", + "description": "Constraints option", + "default": null, + "x-example": "cascade", + "enum": [ + "cascade", + "restrict", + "setNull" + ], + "x-enum-name": "RelationMutate", + "x-enum-keys": [], + "x-nullable": true + }, + "newKey": { + "type": "string", + "description": "New Attribute Key.", + "default": null, + "x-example": null, + "x-nullable": true + } + } + } + } + ] + } + }, "\/databases\/{databaseId}\/collections\/{collectionId}\/attributes\/string": { "post": { "summary": "Create string attribute", @@ -10930,118 +11042,6 @@ ] } }, - "\/databases\/{databaseId}\/collections\/{collectionId}\/attributes\/{key}\/relationship": { - "patch": { - "summary": "Update relationship attribute", - "operationId": "databasesUpdateRelationshipAttribute", - "consumes": [ - "application\/json" - ], - "produces": [ - "application\/json" - ], - "tags": [ - "databases" - ], - "description": "Update relationship attribute. [Learn more about relationship attributes](https:\/\/appwrite.io\/docs\/databases-relationships#relationship-attributes).\n", - "responses": { - "200": { - "description": "AttributeRelationship", - "schema": { - "$ref": "#\/definitions\/attributeRelationship" - } - } - }, - "deprecated": true, - "x-appwrite": { - "method": "updateRelationshipAttribute", - "group": "attributes", - "weight": 349, - "cookies": false, - "type": "", - "demo": "databases\/update-relationship-attribute.md", - "rate-limit": 0, - "rate-time": 3600, - "rate-key": "url:{url},ip:{ip}", - "scope": "collections.write", - "platforms": [ - "console", - "server" - ], - "packaging": false, - "public": true, - "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/databases\/update-relationship-attribute.md", - "deprecated": { - "since": "1.8.0", - "replaceWith": "tablesDB.updateRelationshipColumn" - }, - "auth": { - "Project": [] - } - }, - "security": [ - { - "Project": [], - "Key": [] - } - ], - "parameters": [ - { - "name": "databaseId", - "description": "Database ID.", - "required": true, - "type": "string", - "x-example": "", - "in": "path" - }, - { - "name": "collectionId", - "description": "Collection ID.", - "required": true, - "type": "string", - "x-example": "", - "in": "path" - }, - { - "name": "key", - "description": "Attribute Key.", - "required": true, - "type": "string", - "in": "path" - }, - { - "name": "payload", - "in": "body", - "schema": { - "type": "object", - "properties": { - "onDelete": { - "type": "string", - "description": "Constraints option", - "default": null, - "x-example": "cascade", - "enum": [ - "cascade", - "restrict", - "setNull" - ], - "x-enum-name": "RelationMutate", - "x-enum-keys": [], - "x-nullable": true - }, - "newKey": { - "type": "string", - "description": "New Attribute Key.", - "default": null, - "x-example": null, - "x-nullable": true - } - } - } - } - ] - } - }, "\/databases\/{databaseId}\/collections\/{collectionId}\/documents": { "get": { "summary": "List documents", @@ -11237,6 +11237,7 @@ "databaseId", "collectionId", "documents", + "transactionId", "transactionId" ], "required": [ @@ -13251,6 +13252,2351 @@ ] } }, + "\/documentsdb": { + "get": { + "summary": "List databases", + "operationId": "documentsDBList", + "consumes": [], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Get a list of all databases from the current Appwrite project. You can use the search parameter to filter your results.", + "responses": { + "200": { + "description": "Databases List", + "schema": { + "$ref": "#\/definitions\/databaseList" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "list", + "group": "documentsdb", + "weight": 433, + "cookies": false, + "type": "", + "demo": "documentsdb\/list.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "databases.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/list.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following columns: name", + "required": false, + "type": "array", + "collectionFormat": "multi", + "items": { + "type": "string" + }, + "default": [], + "in": "query" + }, + { + "name": "search", + "description": "Search term to filter your list results. Max length: 256 chars.", + "required": false, + "type": "string", + "x-example": "", + "default": "", + "in": "query" + }, + { + "name": "total", + "description": "When set to false, the total count returned will be 0 and will not be calculated.", + "required": false, + "type": "boolean", + "x-example": false, + "default": true, + "in": "query" + } + ] + }, + "post": { + "summary": "Create database", + "operationId": "documentsDBCreate", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Create a new Database.\n", + "responses": { + "201": { + "description": "Database", + "schema": { + "$ref": "#\/definitions\/database" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "create", + "group": "documentsdb", + "weight": 429, + "cookies": false, + "type": "", + "demo": "documentsdb\/create.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "databases.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/create.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "databaseId": { + "type": "string", + "description": "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.", + "default": null, + "x-example": "" + }, + "name": { + "type": "string", + "description": "Database name. Max length: 128 chars.", + "default": null, + "x-example": "" + }, + "enabled": { + "type": "boolean", + "description": "Is the database enabled? When set to 'disabled', users cannot access the database but Server SDKs with an API key can still read and write to the database. No data is lost when this is toggled.", + "default": true, + "x-example": false + } + }, + "required": [ + "databaseId", + "name" + ] + } + } + ] + } + }, + "\/documentsdb\/usage": { + "get": { + "summary": "Get DocumentsDB usage stats", + "operationId": "documentsDBListUsage", + "consumes": [], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "List usage metrics and statistics for all databases in the project. You can view the total number of databases, collections, documents, and storage usage. The response includes both current totals and historical data over time. Use the optional range parameter to specify the time window for historical data: 24h (last 24 hours), 30d (last 30 days), or 90d (last 90 days). If not specified, range defaults to 30 days.", + "responses": { + "200": { + "description": "UsageDatabases", + "schema": { + "$ref": "#\/definitions\/usageDatabases" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "listUsage", + "group": null, + "weight": 435, + "cookies": false, + "type": "", + "demo": "documentsdb\/list-usage.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/list-usage.md", + "methods": [ + { + "name": "listUsage", + "namespace": "documentsDB", + "desc": "", + "auth": { + "Project": [] + }, + "parameters": [ + "range" + ], + "required": [], + "responses": [ + { + "code": 200, + "model": "#\/definitions\/usageDatabases" + } + ], + "description": "List usage metrics and statistics for all databases in the project. You can view the total number of databases, collections, documents, and storage usage. The response includes both current totals and historical data over time. Use the optional range parameter to specify the time window for historical data: 24h (last 24 hours), 30d (last 30 days), or 90d (last 90 days). If not specified, range defaults to 30 days.", + "demo": "documentsdb\/list-usage.md", + "public": true + } + ], + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [] + } + ], + "parameters": [ + { + "name": "range", + "description": "Date range.", + "required": false, + "type": "string", + "x-example": "24h", + "enum": [ + "24h", + "30d", + "90d" + ], + "x-enum-name": "UsageRange", + "x-enum-keys": [ + "Twenty Four Hours", + "Thirty Days", + "Ninety Days" + ], + "default": "30d", + "in": "query" + } + ] + } + }, + "\/documentsdb\/{databaseId}": { + "get": { + "summary": "Get database", + "operationId": "documentsDBGet", + "consumes": [], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Get a database by its unique ID. This endpoint response returns a JSON object with the database metadata.", + "responses": { + "200": { + "description": "Database", + "schema": { + "$ref": "#\/definitions\/database" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "get", + "group": "documentsdb", + "weight": 430, + "cookies": false, + "type": "", + "demo": "documentsdb\/get.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "databases.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/get.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + } + ] + }, + "put": { + "summary": "Update database", + "operationId": "documentsDBUpdate", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Update a database by its unique ID.", + "responses": { + "200": { + "description": "Database", + "schema": { + "$ref": "#\/definitions\/database" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "update", + "group": "documentsdb", + "weight": 431, + "cookies": false, + "type": "", + "demo": "documentsdb\/update.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "databases.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/update.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "Database name. Max length: 128 chars.", + "default": null, + "x-example": "" + }, + "enabled": { + "type": "boolean", + "description": "Is database enabled? When set to 'disabled', users cannot access the database but Server SDKs with an API key can still read and write to the database. No data is lost when this is toggled.", + "default": true, + "x-example": false + } + }, + "required": [ + "name" + ] + } + } + ] + }, + "delete": { + "summary": "Delete database", + "operationId": "documentsDBDelete", + "consumes": [ + "application\/json" + ], + "produces": [], + "tags": [ + "documentsDB" + ], + "description": "Delete a database by its unique ID. Only API keys with with databases.write scope can delete a database.", + "responses": { + "204": { + "description": "No content" + } + }, + "deprecated": false, + "x-appwrite": { + "method": "delete", + "group": "documentsdb", + "weight": 432, + "cookies": false, + "type": "", + "demo": "documentsdb\/delete.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "databases.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/delete.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections": { + "get": { + "summary": "List collections", + "operationId": "documentsDBListCollections", + "consumes": [], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Get a list of all collections that belong to the provided databaseId. You can use the search parameter to filter your results.", + "responses": { + "200": { + "description": "Collections List", + "schema": { + "$ref": "#\/definitions\/collectionList" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "listCollections", + "group": "collections", + "weight": 440, + "cookies": false, + "type": "", + "demo": "documentsdb\/list-collections.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/list-collections.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following attributes: name, enabled, documentSecurity", + "required": false, + "type": "array", + "collectionFormat": "multi", + "items": { + "type": "string" + }, + "default": [], + "in": "query" + }, + { + "name": "search", + "description": "Search term to filter your list results. Max length: 256 chars.", + "required": false, + "type": "string", + "x-example": "", + "default": "", + "in": "query" + }, + { + "name": "total", + "description": "When set to false, the total count returned will be 0 and will not be calculated.", + "required": false, + "type": "boolean", + "x-example": false, + "default": true, + "in": "query" + } + ] + }, + "post": { + "summary": "Create collection", + "operationId": "documentsDBCreateCollection", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Create a new Collection. Before using this route, you should create a new database resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.", + "responses": { + "201": { + "description": "Collection", + "schema": { + "$ref": "#\/definitions\/collection" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "createCollection", + "group": "collections", + "weight": 436, + "cookies": false, + "type": "", + "demo": "documentsdb\/create-collection.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/create-collection.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "collectionId": { + "type": "string", + "description": "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.", + "default": null, + "x-example": "" + }, + "name": { + "type": "string", + "description": "Collection name. Max length: 128 chars.", + "default": null, + "x-example": "" + }, + "permissions": { + "type": "array", + "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\")\"]", + "items": { + "type": "string" + } + }, + "documentSecurity": { + "type": "boolean", + "description": "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).", + "default": false, + "x-example": false + }, + "enabled": { + "type": "boolean", + "description": "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.", + "default": true, + "x-example": false + }, + "attributes": { + "type": "array", + "description": "Array of attribute definitions to create. Each attribute should contain: key (string), type (string: string, integer, float, boolean, datetime, relationship), size (integer, required for string type), required (boolean, optional), default (mixed, optional), array (boolean, optional), and type-specific options.", + "default": [], + "x-example": null, + "items": { + "type": "object" + } + }, + "indexes": { + "type": "array", + "description": "Array of index definitions to create. Each index should contain: key (string), type (string: key, fulltext, unique, spatial), attributes (array of attribute keys), orders (array of ASC\/DESC, optional), and lengths (array of integers, optional).", + "default": [], + "x-example": null, + "items": { + "type": "object" + } + } + }, + "required": [ + "collectionId", + "name" + ] + } + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}": { + "get": { + "summary": "Get collection", + "operationId": "documentsDBGetCollection", + "consumes": [], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Get a collection by its unique ID. This endpoint response returns a JSON object with the collection metadata.", + "responses": { + "200": { + "description": "Collection", + "schema": { + "$ref": "#\/definitions\/collection" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "getCollection", + "group": "collections", + "weight": 437, + "cookies": false, + "type": "", + "demo": "documentsdb\/get-collection.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/get-collection.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + } + ] + }, + "put": { + "summary": "Update collection", + "operationId": "documentsDBUpdateCollection", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Update a collection by its unique ID.", + "responses": { + "200": { + "description": "Collection", + "schema": { + "$ref": "#\/definitions\/collection" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "updateCollection", + "group": "collections", + "weight": 438, + "cookies": false, + "type": "", + "demo": "documentsdb\/update-collection.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/update-collection.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "Collection name. Max length: 128 chars.", + "default": null, + "x-example": "" + }, + "permissions": { + "type": "array", + "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\")\"]", + "items": { + "type": "string" + } + }, + "documentSecurity": { + "type": "boolean", + "description": "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).", + "default": false, + "x-example": false + }, + "enabled": { + "type": "boolean", + "description": "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.", + "default": true, + "x-example": false + } + }, + "required": [ + "name" + ] + } + } + ] + }, + "delete": { + "summary": "Delete collection", + "operationId": "documentsDBDeleteCollection", + "consumes": [ + "application\/json" + ], + "produces": [], + "tags": [ + "documentsDB" + ], + "description": "Delete a collection by its unique ID. Only users with write permissions have access to delete this resource.", + "responses": { + "204": { + "description": "No content" + } + }, + "deprecated": false, + "x-appwrite": { + "method": "deleteCollection", + "group": "collections", + "weight": 439, + "cookies": false, + "type": "", + "demo": "documentsdb\/delete-collection.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/delete-collection.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/documents": { + "post": { + "summary": "Create document", + "operationId": "documentsDBCreateDocument", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Create a new Document. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.", + "responses": { + "201": { + "description": "Document", + "schema": { + "$ref": "#\/definitions\/document" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "createDocument", + "group": "documents", + "weight": 447, + "cookies": false, + "type": "", + "demo": "documentsdb\/create-document.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/create-document.md", + "methods": [ + { + "name": "createDocuments", + "namespace": "documentsDB", + "desc": "Create documents", + "auth": { + "Project": [] + }, + "parameters": [ + "databaseId", + "collectionId", + "documents" + ], + "required": [ + "databaseId", + "collectionId", + "documents" + ], + "responses": [ + { + "code": 201, + "model": "#\/definitions\/documentList" + } + ], + "description": "Create new Documents. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.", + "demo": "documentsdb\/create-documents.md", + "public": true + } + ], + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "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.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "documentId": { + "type": "string", + "description": "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.", + "default": "", + "x-example": "" + }, + "data": { + "type": "object", + "description": "Document data as JSON object.", + "default": [], + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" + }, + "permissions": { + "type": "array", + "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\")\"]", + "items": { + "type": "string" + } + }, + "documents": { + "type": "array", + "description": "Array of documents data as JSON objects.", + "default": [], + "x-example": null, + "items": { + "type": "object" + } + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "default": null, + "x-example": "" + } + } + } + } + ] + }, + "put": { + "summary": "Upsert documents", + "operationId": "documentsDBUpsertDocuments", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Create or update Documents. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.\n", + "responses": { + "201": { + "description": "Documents List", + "schema": { + "$ref": "#\/definitions\/documentList" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "upsertDocuments", + "group": "documents", + "weight": 452, + "cookies": false, + "type": "", + "demo": "documentsdb\/upsert-documents.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/upsert-documents.md", + "methods": [ + { + "name": "upsertDocuments", + "namespace": "documentsDB", + "desc": "", + "auth": { + "Project": [] + }, + "parameters": [ + "databaseId", + "collectionId", + "documents", + "transactionId" + ], + "required": [ + "databaseId", + "collectionId", + "documents" + ], + "responses": [ + { + "code": 201, + "model": "#\/definitions\/documentList" + } + ], + "description": "Create or update Documents. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.\n", + "demo": "documentsdb\/upsert-documents.md", + "public": true + } + ], + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "documents": { + "type": "array", + "description": "Array of document data as JSON objects. May contain partial documents.", + "default": null, + "x-example": null, + "items": { + "type": "object" + } + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "default": null, + "x-example": "" + } + }, + "required": [ + "documents" + ] + } + } + ] + }, + "patch": { + "summary": "Update documents", + "operationId": "documentsDBUpdateDocuments", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Update all documents that match your queries, if no queries are submitted then all documents are updated. You can pass only specific fields to be updated.", + "responses": { + "200": { + "description": "Documents List", + "schema": { + "$ref": "#\/definitions\/documentList" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "updateDocuments", + "group": "documents", + "weight": 450, + "cookies": false, + "type": "", + "demo": "documentsdb\/update-documents.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/update-documents.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "data": { + "type": "object", + "description": "Document data as JSON object. Include only attribute and value pairs to be updated.", + "default": [], + "x-example": "{}" + }, + "queries": { + "type": "array", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long.", + "default": [], + "x-example": null, + "items": { + "type": "string" + } + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "default": null, + "x-example": "" + } + } + } + } + ] + }, + "delete": { + "summary": "Delete documents", + "operationId": "documentsDBDeleteDocuments", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Bulk delete documents using queries, if no queries are passed then all documents are deleted.", + "responses": { + "200": { + "description": "Documents List", + "schema": { + "$ref": "#\/definitions\/documentList" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "deleteDocuments", + "group": "documents", + "weight": 454, + "cookies": false, + "type": "", + "demo": "documentsdb\/delete-documents.md", + "rate-limit": 60, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/delete-documents.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "queries": { + "type": "array", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long.", + "default": [], + "x-example": null, + "items": { + "type": "string" + } + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "default": null, + "x-example": "" + } + } + } + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/documents\/{documentId}\/logs": { + "get": { + "summary": "List document logs", + "operationId": "documentsDBListDocumentLogs", + "consumes": [], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Get the document activity logs list by its unique ID.", + "responses": { + "200": { + "description": "Logs List", + "schema": { + "$ref": "#\/definitions\/logList" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "listDocumentLogs", + "group": "logs", + "weight": 456, + "cookies": false, + "type": "", + "demo": "documentsdb\/list-document-logs.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.read", + "platforms": [ + "console" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/get-document-logs.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Only supported methods are limit and offset", + "required": false, + "type": "array", + "collectionFormat": "multi", + "items": { + "type": "string" + }, + "default": [], + "in": "query" + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/documents\/{documentId}\/{attribute}\/decrement": { + "patch": { + "summary": "Decrement document attribute", + "operationId": "documentsDBDecrementDocumentAttribute", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Decrement a specific column of a row by a given value.", + "responses": { + "200": { + "description": "Document", + "schema": { + "$ref": "#\/definitions\/document" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "decrementDocumentAttribute", + "group": "documents", + "weight": 458, + "cookies": false, + "type": "", + "demo": "documentsdb\/decrement-document-attribute.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server", + "console" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/decrement-document-attribute.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "JWT": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "attribute", + "description": "Attribute key.", + "required": true, + "type": "string", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "value": { + "type": "number", + "description": "Value to decrement the attribute by. The value must be a number.", + "default": 1, + "x-example": null + }, + "min": { + "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 + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "default": null, + "x-example": "" + } + } + } + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/documents\/{documentId}\/{attribute}\/increment": { + "patch": { + "summary": "Increment document attribute", + "operationId": "documentsDBIncrementDocumentAttribute", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Increment a specific column of a row by a given value.", + "responses": { + "200": { + "description": "Document", + "schema": { + "$ref": "#\/definitions\/document" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "incrementDocumentAttribute", + "group": "documents", + "weight": 457, + "cookies": false, + "type": "", + "demo": "documentsdb\/increment-document-attribute.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server", + "console" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/increment-document-attribute.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "JWT": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "attribute", + "description": "Attribute key.", + "required": true, + "type": "string", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "value": { + "type": "number", + "description": "Value to increment the attribute by. The value must be a number.", + "default": 1, + "x-example": null + }, + "max": { + "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 + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "default": null, + "x-example": "" + } + } + } + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/indexes": { + "get": { + "summary": "List indexes", + "operationId": "documentsDBListIndexes", + "consumes": [], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "List indexes in the collection.", + "responses": { + "200": { + "description": "Indexes List", + "schema": { + "$ref": "#\/definitions\/indexList" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "listIndexes", + "group": "indexes", + "weight": 446, + "cookies": false, + "type": "", + "demo": "documentsdb\/list-indexes.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/list-indexes.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following attributes: key, type, status, attributes, error", + "required": false, + "type": "array", + "collectionFormat": "multi", + "items": { + "type": "string" + }, + "default": [], + "in": "query" + }, + { + "name": "total", + "description": "When set to false, the total count returned will be 0 and will not be calculated.", + "required": false, + "type": "boolean", + "x-example": false, + "default": true, + "in": "query" + } + ] + }, + "post": { + "summary": "Create index", + "operationId": "documentsDBCreateIndex", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Creates an index on the attributes listed. Your index should include all the attributes you will query in a single request.\nAttributes can be `key`, `fulltext`, and `unique`.", + "responses": { + "202": { + "description": "Index", + "schema": { + "$ref": "#\/definitions\/index" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "createIndex", + "group": "indexes", + "weight": 443, + "cookies": false, + "type": "", + "demo": "documentsdb\/create-index.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/create-index.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "key": { + "type": "string", + "description": "Index Key.", + "default": null, + "x-example": null + }, + "type": { + "type": "string", + "description": "Index type.", + "default": null, + "x-example": "key", + "enum": [ + "key", + "fulltext", + "unique", + "spatial" + ], + "x-enum-name": "IndexType", + "x-enum-keys": [] + }, + "attributes": { + "type": "array", + "description": "Array of attributes to index. Maximum of 100 attributes are allowed, each 32 characters long.", + "default": null, + "x-example": null, + "items": { + "type": "string" + } + }, + "orders": { + "type": "array", + "description": "Array of index orders. Maximum of 100 orders are allowed.", + "default": [], + "x-example": null, + "items": { + "type": "string", + "enum": [ + "asc", + "desc" + ], + "x-enum-name": "OrderBy", + "x-enum-keys": [] + } + }, + "lengths": { + "type": "array", + "description": "Length of index. Maximum of 100", + "default": [], + "x-example": null, + "items": { + "type": "integer" + } + } + }, + "required": [ + "key", + "type", + "attributes" + ] + } + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/indexes\/{key}": { + "get": { + "summary": "Get index", + "operationId": "documentsDBGetIndex", + "consumes": [], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Get index by ID.", + "responses": { + "200": { + "description": "Index", + "schema": { + "$ref": "#\/definitions\/index" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "getIndex", + "group": "indexes", + "weight": 444, + "cookies": false, + "type": "", + "demo": "documentsdb\/get-index.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/get-index.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "key", + "description": "Index Key.", + "required": true, + "type": "string", + "in": "path" + } + ] + }, + "delete": { + "summary": "Delete index", + "operationId": "documentsDBDeleteIndex", + "consumes": [ + "application\/json" + ], + "produces": [], + "tags": [ + "documentsDB" + ], + "description": "Delete an index.", + "responses": { + "204": { + "description": "No content" + } + }, + "deprecated": false, + "x-appwrite": { + "method": "deleteIndex", + "group": "indexes", + "weight": 445, + "cookies": false, + "type": "", + "demo": "documentsdb\/delete-index.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/delete-index.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "key", + "description": "Index Key.", + "required": true, + "type": "string", + "in": "path" + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/logs": { + "get": { + "summary": "List collection logs", + "operationId": "documentsDBListCollectionLogs", + "consumes": [], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Get the collection activity logs list by its unique ID.", + "responses": { + "200": { + "description": "Logs List", + "schema": { + "$ref": "#\/definitions\/logList" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "listCollectionLogs", + "group": "collections", + "weight": 441, + "cookies": false, + "type": "", + "demo": "documentsdb\/list-collection-logs.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/get-collection-logs.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Only supported methods are limit and offset", + "required": false, + "type": "array", + "collectionFormat": "multi", + "items": { + "type": "string" + }, + "default": [], + "in": "query" + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/usage": { + "get": { + "summary": "Get collection usage stats", + "operationId": "documentsDBGetCollectionUsage", + "consumes": [], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Get usage metrics and statistics for a collection. Returning the total number of documents. The response includes both current totals and historical data over time. Use the optional range parameter to specify the time window for historical data: 24h (last 24 hours), 30d (last 30 days), or 90d (last 90 days). If not specified, range defaults to 30 days.", + "responses": { + "200": { + "description": "UsageCollection", + "schema": { + "$ref": "#\/definitions\/usageCollection" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "getCollectionUsage", + "group": null, + "weight": 442, + "cookies": false, + "type": "", + "demo": "documentsdb\/get-collection-usage.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/get-collection-usage.md", + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "range", + "description": "Date range.", + "required": false, + "type": "string", + "x-example": "24h", + "enum": [ + "24h", + "30d", + "90d" + ], + "x-enum-name": "UsageRange", + "x-enum-keys": [ + "Twenty Four Hours", + "Thirty Days", + "Ninety Days" + ], + "default": "30d", + "in": "query" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + } + ] + } + }, + "\/documentsdb\/{databaseId}\/usage": { + "get": { + "summary": "Get DocumentsDB usage stats", + "operationId": "documentsDBGetUsage", + "consumes": [], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Get usage metrics and statistics for a database. You can view the total number of collections, documents, and storage usage. The response includes both current totals and historical data over time. Use the optional range parameter to specify the time window for historical data: 24h (last 24 hours), 30d (last 30 days), or 90d (last 90 days). If not specified, range defaults to 30 days.", + "responses": { + "200": { + "description": "UsageDocumentsDB", + "schema": { + "$ref": "#\/definitions\/usageDocumentsDB" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "getUsage", + "group": null, + "weight": 434, + "cookies": false, + "type": "", + "demo": "documentsdb\/get-usage.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/get-database-usage.md", + "methods": [ + { + "name": "getUsage", + "namespace": "documentsDB", + "desc": "", + "auth": { + "Project": [] + }, + "parameters": [ + "databaseId", + "range" + ], + "required": [ + "databaseId" + ], + "responses": [ + { + "code": 200, + "model": "#\/definitions\/usageDocumentsDB" + } + ], + "description": "Get usage metrics and statistics for a database. You can view the total number of collections, documents, and storage usage. The response includes both current totals and historical data over time. Use the optional range parameter to specify the time window for historical data: 24h (last 24 hours), 30d (last 30 days), or 90d (last 90 days). If not specified, range defaults to 30 days.", + "demo": "documentsdb\/get-usage.md", + "public": true + } + ], + "auth": { + "Project": [] + } + }, + "security": [ + { + "Project": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "range", + "description": "Date range.", + "required": false, + "type": "string", + "x-example": "24h", + "enum": [ + "24h", + "30d", + "90d" + ], + "x-enum-name": "UsageRange", + "x-enum-keys": [ + "Twenty Four Hours", + "Thirty Days", + "Ninety Days" + ], + "default": "30d", + "in": "query" + } + ] + } + }, "\/functions": { "get": { "summary": "List functions", @@ -13275,7 +15621,7 @@ "x-appwrite": { "method": "list", "group": "functions", - "weight": 439, + "weight": 475, "cookies": false, "type": "", "demo": "functions\/list.md", @@ -13357,7 +15703,7 @@ "x-appwrite": { "method": "create", "group": "functions", - "weight": 436, + "weight": 472, "cookies": false, "type": "", "demo": "functions\/create.md", @@ -13670,7 +16016,7 @@ "x-appwrite": { "method": "listRuntimes", "group": "runtimes", - "weight": 441, + "weight": 477, "cookies": false, "type": "", "demo": "functions\/list-runtimes.md", @@ -13720,7 +16066,7 @@ "x-appwrite": { "method": "listSpecifications", "group": "runtimes", - "weight": 442, + "weight": 478, "cookies": false, "type": "", "demo": "functions\/list-specifications.md", @@ -13770,7 +16116,7 @@ "x-appwrite": { "method": "listTemplates", "group": "templates", - "weight": 465, + "weight": 501, "cookies": false, "type": "", "demo": "functions\/list-templates.md", @@ -13954,7 +16300,7 @@ "x-appwrite": { "method": "getTemplate", "group": "templates", - "weight": 464, + "weight": 500, "cookies": false, "type": "", "demo": "functions\/get-template.md", @@ -14012,7 +16358,7 @@ "x-appwrite": { "method": "listUsage", "group": null, - "weight": 458, + "weight": 494, "cookies": false, "type": "", "demo": "functions\/list-usage.md", @@ -14082,7 +16428,7 @@ "x-appwrite": { "method": "get", "group": "functions", - "weight": 437, + "weight": 473, "cookies": false, "type": "", "demo": "functions\/get.md", @@ -14142,7 +16488,7 @@ "x-appwrite": { "method": "update", "group": "functions", - "weight": 438, + "weight": 474, "cookies": false, "type": "", "demo": "functions\/update.md", @@ -14451,7 +16797,7 @@ "x-appwrite": { "method": "delete", "group": "functions", - "weight": 440, + "weight": 476, "cookies": false, "type": "", "demo": "functions\/delete.md", @@ -14513,7 +16859,7 @@ "x-appwrite": { "method": "updateFunctionDeployment", "group": "functions", - "weight": 445, + "weight": 481, "cookies": false, "type": "", "demo": "functions\/update-function-deployment.md", @@ -14591,7 +16937,7 @@ "x-appwrite": { "method": "listDeployments", "group": "deployments", - "weight": 446, + "weight": 482, "cookies": false, "type": "", "demo": "functions\/list-deployments.md", @@ -14681,7 +17027,7 @@ "x-appwrite": { "method": "createDeployment", "group": "deployments", - "weight": 443, + "weight": 479, "cookies": false, "type": "upload", "demo": "functions\/create-deployment.md", @@ -14774,7 +17120,7 @@ "x-appwrite": { "method": "createDuplicateDeployment", "group": "deployments", - "weight": 451, + "weight": 487, "cookies": false, "type": "", "demo": "functions\/create-duplicate-deployment.md", @@ -14860,7 +17206,7 @@ "x-appwrite": { "method": "createTemplateDeployment", "group": "deployments", - "weight": 448, + "weight": 484, "cookies": false, "type": "", "demo": "functions\/create-template-deployment.md", @@ -14981,7 +17327,7 @@ "x-appwrite": { "method": "createVcsDeployment", "group": "deployments", - "weight": 449, + "weight": 485, "cookies": false, "type": "", "demo": "functions\/create-vcs-deployment.md", @@ -15078,7 +17424,7 @@ "x-appwrite": { "method": "getDeployment", "group": "deployments", - "weight": 444, + "weight": 480, "cookies": false, "type": "", "demo": "functions\/get-deployment.md", @@ -15141,7 +17487,7 @@ "x-appwrite": { "method": "deleteDeployment", "group": "deployments", - "weight": 447, + "weight": 483, "cookies": false, "type": "", "demo": "functions\/delete-deployment.md", @@ -15209,7 +17555,7 @@ "x-appwrite": { "method": "getDeploymentDownload", "group": "deployments", - "weight": 450, + "weight": 486, "cookies": false, "type": "location", "demo": "functions\/get-deployment-download.md", @@ -15295,7 +17641,7 @@ "x-appwrite": { "method": "updateDeploymentStatus", "group": "deployments", - "weight": 452, + "weight": 488, "cookies": false, "type": "", "demo": "functions\/update-deployment-status.md", @@ -15363,7 +17709,7 @@ "x-appwrite": { "method": "listExecutions", "group": "executions", - "weight": 455, + "weight": 491, "cookies": false, "type": "", "demo": "functions\/list-executions.md", @@ -15446,7 +17792,7 @@ "x-appwrite": { "method": "createExecution", "group": "executions", - "weight": 453, + "weight": 489, "cookies": false, "type": "", "demo": "functions\/create-execution.md", @@ -15565,7 +17911,7 @@ "x-appwrite": { "method": "getExecution", "group": "executions", - "weight": 454, + "weight": 490, "cookies": false, "type": "", "demo": "functions\/get-execution.md", @@ -15630,7 +17976,7 @@ "x-appwrite": { "method": "deleteExecution", "group": "executions", - "weight": 456, + "weight": 492, "cookies": false, "type": "", "demo": "functions\/delete-execution.md", @@ -15698,7 +18044,7 @@ "x-appwrite": { "method": "getUsage", "group": null, - "weight": 457, + "weight": 493, "cookies": false, "type": "", "demo": "functions\/get-usage.md", @@ -15776,7 +18122,7 @@ "x-appwrite": { "method": "listVariables", "group": "variables", - "weight": 461, + "weight": 497, "cookies": false, "type": "", "demo": "functions\/list-variables.md", @@ -15836,7 +18182,7 @@ "x-appwrite": { "method": "createVariable", "group": "variables", - "weight": 459, + "weight": 495, "cookies": false, "type": "", "demo": "functions\/create-variable.md", @@ -15927,7 +18273,7 @@ "x-appwrite": { "method": "getVariable", "group": "variables", - "weight": 460, + "weight": 496, "cookies": false, "type": "", "demo": "functions\/get-variable.md", @@ -15995,7 +18341,7 @@ "x-appwrite": { "method": "updateVariable", "group": "variables", - "weight": 462, + "weight": 498, "cookies": false, "type": "", "demo": "functions\/update-variable.md", @@ -16090,7 +18436,7 @@ "x-appwrite": { "method": "deleteVariable", "group": "variables", - "weight": 463, + "weight": 499, "cookies": false, "type": "", "demo": "functions\/delete-variable.md", @@ -23728,6 +26074,8 @@ "document", "attribute", "collection", + "documentsdb", + "vectordb", "bucket", "file", "function", @@ -23836,6 +26184,8 @@ "document", "attribute", "collection", + "documentsdb", + "vectordb", "bucket", "file", "function", @@ -25413,7 +27763,7 @@ "x-appwrite": { "method": "list", "group": "projects", - "weight": 434, + "weight": 470, "cookies": false, "type": "", "demo": "projects\/list.md", @@ -25438,7 +27788,7 @@ "parameters": [ { "name": "queries", - "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following attributes: name, teamId, labels", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following attributes: name, teamId, labels, search", "required": false, "type": "array", "collectionFormat": "multi", @@ -27086,7 +29436,7 @@ "x-appwrite": { "method": "listDevKeys", "group": "devKeys", - "weight": 432, + "weight": 468, "cookies": false, "type": "", "demo": "projects\/list-dev-keys.md", @@ -27156,7 +29506,7 @@ "x-appwrite": { "method": "createDevKey", "group": "devKeys", - "weight": 429, + "weight": 465, "cookies": false, "type": "", "demo": "projects\/create-dev-key.md", @@ -27239,7 +29589,7 @@ "x-appwrite": { "method": "getDevKey", "group": "devKeys", - "weight": 431, + "weight": 467, "cookies": false, "type": "", "demo": "projects\/get-dev-key.md", @@ -27305,7 +29655,7 @@ "x-appwrite": { "method": "updateDevKey", "group": "devKeys", - "weight": 430, + "weight": 466, "cookies": false, "type": "", "demo": "projects\/update-dev-key.md", @@ -27391,7 +29741,7 @@ "x-appwrite": { "method": "deleteDevKey", "group": "devKeys", - "weight": 433, + "weight": 469, "cookies": false, "type": "", "demo": "projects\/delete-dev-key.md", @@ -28119,7 +30469,7 @@ "x-appwrite": { "method": "updateLabels", "group": "projects", - "weight": 435, + "weight": 471, "cookies": false, "type": "", "demo": "projects\/update-labels.md", @@ -31536,7 +33886,7 @@ "x-appwrite": { "method": "listRules", "group": null, - "weight": 511, + "weight": 547, "cookies": false, "type": "", "demo": "proxy\/list-rules.md", @@ -31618,7 +33968,7 @@ "x-appwrite": { "method": "createAPIRule", "group": null, - "weight": 506, + "weight": 542, "cookies": false, "type": "", "demo": "proxy\/create-api-rule.md", @@ -31688,7 +34038,7 @@ "x-appwrite": { "method": "createFunctionRule", "group": null, - "weight": 508, + "weight": 544, "cookies": false, "type": "", "demo": "proxy\/create-function-rule.md", @@ -31771,7 +34121,7 @@ "x-appwrite": { "method": "createRedirectRule", "group": null, - "weight": 509, + "weight": 545, "cookies": false, "type": "", "demo": "proxy\/create-redirect-rule.md", @@ -31891,7 +34241,7 @@ "x-appwrite": { "method": "createSiteRule", "group": null, - "weight": 507, + "weight": 543, "cookies": false, "type": "", "demo": "proxy\/create-site-rule.md", @@ -31972,7 +34322,7 @@ "x-appwrite": { "method": "getRule", "group": null, - "weight": 510, + "weight": 546, "cookies": false, "type": "", "demo": "proxy\/get-rule.md", @@ -32025,7 +34375,7 @@ "x-appwrite": { "method": "deleteRule", "group": null, - "weight": 512, + "weight": 548, "cookies": false, "type": "", "demo": "proxy\/delete-rule.md", @@ -32085,7 +34435,7 @@ "x-appwrite": { "method": "updateRuleVerification", "group": null, - "weight": 513, + "weight": 549, "cookies": false, "type": "", "demo": "proxy\/update-rule-verification.md", @@ -32143,7 +34493,7 @@ "x-appwrite": { "method": "list", "group": "sites", - "weight": 468, + "weight": 504, "cookies": false, "type": "", "demo": "sites\/list.md", @@ -32225,7 +34575,7 @@ "x-appwrite": { "method": "create", "group": "sites", - "weight": 466, + "weight": 502, "cookies": false, "type": "", "demo": "sites\/create.md", @@ -32496,7 +34846,7 @@ "x-appwrite": { "method": "listFrameworks", "group": "frameworks", - "weight": 471, + "weight": 507, "cookies": false, "type": "", "demo": "sites\/list-frameworks.md", @@ -32546,7 +34896,7 @@ "x-appwrite": { "method": "listSpecifications", "group": "frameworks", - "weight": 494, + "weight": 530, "cookies": false, "type": "", "demo": "sites\/list-specifications.md", @@ -32596,7 +34946,7 @@ "x-appwrite": { "method": "listTemplates", "group": "templates", - "weight": 490, + "weight": 526, "cookies": false, "type": "", "demo": "sites\/list-templates.md", @@ -32719,7 +35069,7 @@ "x-appwrite": { "method": "getTemplate", "group": "templates", - "weight": 491, + "weight": 527, "cookies": false, "type": "", "demo": "sites\/get-template.md", @@ -32777,7 +35127,7 @@ "x-appwrite": { "method": "listUsage", "group": null, - "weight": 492, + "weight": 528, "cookies": false, "type": "", "demo": "sites\/list-usage.md", @@ -32847,7 +35197,7 @@ "x-appwrite": { "method": "get", "group": "sites", - "weight": 467, + "weight": 503, "cookies": false, "type": "", "demo": "sites\/get.md", @@ -32907,7 +35257,7 @@ "x-appwrite": { "method": "update", "group": "sites", - "weight": 469, + "weight": 505, "cookies": false, "type": "", "demo": "sites\/update.md", @@ -33173,7 +35523,7 @@ "x-appwrite": { "method": "delete", "group": "sites", - "weight": 470, + "weight": 506, "cookies": false, "type": "", "demo": "sites\/delete.md", @@ -33235,7 +35585,7 @@ "x-appwrite": { "method": "updateSiteDeployment", "group": "sites", - "weight": 477, + "weight": 513, "cookies": false, "type": "", "demo": "sites\/update-site-deployment.md", @@ -33313,7 +35663,7 @@ "x-appwrite": { "method": "listDeployments", "group": "deployments", - "weight": 476, + "weight": 512, "cookies": false, "type": "", "demo": "sites\/list-deployments.md", @@ -33403,7 +35753,7 @@ "x-appwrite": { "method": "createDeployment", "group": "deployments", - "weight": 472, + "weight": 508, "cookies": false, "type": "upload", "demo": "sites\/create-deployment.md", @@ -33504,7 +35854,7 @@ "x-appwrite": { "method": "createDuplicateDeployment", "group": "deployments", - "weight": 480, + "weight": 516, "cookies": false, "type": "", "demo": "sites\/create-duplicate-deployment.md", @@ -33584,7 +35934,7 @@ "x-appwrite": { "method": "createTemplateDeployment", "group": "deployments", - "weight": 473, + "weight": 509, "cookies": false, "type": "", "demo": "sites\/create-template-deployment.md", @@ -33705,7 +36055,7 @@ "x-appwrite": { "method": "createVcsDeployment", "group": "deployments", - "weight": 474, + "weight": 510, "cookies": false, "type": "", "demo": "sites\/create-vcs-deployment.md", @@ -33803,7 +36153,7 @@ "x-appwrite": { "method": "getDeployment", "group": "deployments", - "weight": 475, + "weight": 511, "cookies": false, "type": "", "demo": "sites\/get-deployment.md", @@ -33866,7 +36216,7 @@ "x-appwrite": { "method": "deleteDeployment", "group": "deployments", - "weight": 478, + "weight": 514, "cookies": false, "type": "", "demo": "sites\/delete-deployment.md", @@ -33934,7 +36284,7 @@ "x-appwrite": { "method": "getDeploymentDownload", "group": "deployments", - "weight": 479, + "weight": 515, "cookies": false, "type": "location", "demo": "sites\/get-deployment-download.md", @@ -34020,7 +36370,7 @@ "x-appwrite": { "method": "updateDeploymentStatus", "group": "deployments", - "weight": 481, + "weight": 517, "cookies": false, "type": "", "demo": "sites\/update-deployment-status.md", @@ -34088,7 +36438,7 @@ "x-appwrite": { "method": "listLogs", "group": "logs", - "weight": 483, + "weight": 519, "cookies": false, "type": "", "demo": "sites\/list-logs.md", @@ -34169,7 +36519,7 @@ "x-appwrite": { "method": "getLog", "group": "logs", - "weight": 482, + "weight": 518, "cookies": false, "type": "", "demo": "sites\/get-log.md", @@ -34234,7 +36584,7 @@ "x-appwrite": { "method": "deleteLog", "group": "logs", - "weight": 484, + "weight": 520, "cookies": false, "type": "", "demo": "sites\/delete-log.md", @@ -34302,7 +36652,7 @@ "x-appwrite": { "method": "getUsage", "group": null, - "weight": 493, + "weight": 529, "cookies": false, "type": "", "demo": "sites\/get-usage.md", @@ -34380,7 +36730,7 @@ "x-appwrite": { "method": "listVariables", "group": "variables", - "weight": 487, + "weight": 523, "cookies": false, "type": "", "demo": "sites\/list-variables.md", @@ -34440,7 +36790,7 @@ "x-appwrite": { "method": "createVariable", "group": "variables", - "weight": 485, + "weight": 521, "cookies": false, "type": "", "demo": "sites\/create-variable.md", @@ -34531,7 +36881,7 @@ "x-appwrite": { "method": "getVariable", "group": "variables", - "weight": 486, + "weight": 522, "cookies": false, "type": "", "demo": "sites\/get-variable.md", @@ -34599,7 +36949,7 @@ "x-appwrite": { "method": "updateVariable", "group": "variables", - "weight": 488, + "weight": 524, "cookies": false, "type": "", "demo": "sites\/update-variable.md", @@ -34694,7 +37044,7 @@ "x-appwrite": { "method": "deleteVariable", "group": "variables", - "weight": 489, + "weight": 525, "cookies": false, "type": "", "demo": "sites\/delete-variable.md", @@ -34762,7 +37112,7 @@ "x-appwrite": { "method": "listBuckets", "group": "buckets", - "weight": 521, + "weight": 557, "cookies": false, "type": "", "demo": "storage\/list-buckets.md", @@ -34845,7 +37195,7 @@ "x-appwrite": { "method": "createBucket", "group": "buckets", - "weight": 519, + "weight": 555, "cookies": false, "type": "", "demo": "storage\/create-bucket.md", @@ -34991,7 +37341,7 @@ "x-appwrite": { "method": "getBucket", "group": "buckets", - "weight": 520, + "weight": 556, "cookies": false, "type": "", "demo": "storage\/get-bucket.md", @@ -35052,7 +37402,7 @@ "x-appwrite": { "method": "updateBucket", "group": "buckets", - "weight": 522, + "weight": 558, "cookies": false, "type": "", "demo": "storage\/update-bucket.md", @@ -35194,7 +37544,7 @@ "x-appwrite": { "method": "deleteBucket", "group": "buckets", - "weight": 523, + "weight": 559, "cookies": false, "type": "", "demo": "storage\/delete-bucket.md", @@ -35255,7 +37605,7 @@ "x-appwrite": { "method": "listFiles", "group": "files", - "weight": 526, + "weight": 562, "cookies": false, "type": "", "demo": "storage\/list-files.md", @@ -35348,7 +37698,7 @@ "x-appwrite": { "method": "createFile", "group": "files", - "weight": 524, + "weight": 560, "cookies": false, "type": "upload", "demo": "storage\/create-file.md", @@ -35439,7 +37789,7 @@ "x-appwrite": { "method": "getFile", "group": "files", - "weight": 525, + "weight": 561, "cookies": false, "type": "", "demo": "storage\/get-file.md", @@ -35510,7 +37860,7 @@ "x-appwrite": { "method": "updateFile", "group": "files", - "weight": 527, + "weight": 563, "cookies": false, "type": "", "demo": "storage\/update-file.md", @@ -35601,7 +37951,7 @@ "x-appwrite": { "method": "deleteFile", "group": "files", - "weight": 528, + "weight": 564, "cookies": false, "type": "", "demo": "storage\/delete-file.md", @@ -35672,7 +38022,7 @@ "x-appwrite": { "method": "getFileDownload", "group": "files", - "weight": 530, + "weight": 566, "cookies": false, "type": "location", "demo": "storage\/get-file-download.md", @@ -35752,7 +38102,7 @@ "x-appwrite": { "method": "getFilePreview", "group": "files", - "weight": 529, + "weight": 565, "cookies": false, "type": "location", "demo": "storage\/get-file-preview.md", @@ -35960,7 +38310,7 @@ "x-appwrite": { "method": "getFileView", "group": "files", - "weight": 531, + "weight": 567, "cookies": false, "type": "location", "demo": "storage\/get-file-view.md", @@ -36040,7 +38390,7 @@ "x-appwrite": { "method": "getUsage", "group": null, - "weight": 533, + "weight": 569, "cookies": false, "type": "", "demo": "storage\/get-usage.md", @@ -36111,7 +38461,7 @@ "x-appwrite": { "method": "getBucketUsage", "group": null, - "weight": 534, + "weight": 570, "cookies": false, "type": "", "demo": "storage\/get-bucket-usage.md", @@ -44100,7 +46450,7 @@ "x-appwrite": { "method": "list", "group": "files", - "weight": 516, + "weight": 552, "cookies": false, "type": "", "demo": "tokens\/list.md", @@ -44189,7 +46539,7 @@ "x-appwrite": { "method": "createFileToken", "group": "files", - "weight": 514, + "weight": 550, "cookies": false, "type": "", "demo": "tokens\/create-file-token.md", @@ -44273,7 +46623,7 @@ "x-appwrite": { "method": "get", "group": "tokens", - "weight": 515, + "weight": 551, "cookies": false, "type": "", "demo": "tokens\/get.md", @@ -44333,7 +46683,7 @@ "x-appwrite": { "method": "update", "group": "tokens", - "weight": 517, + "weight": 553, "cookies": false, "type": "", "demo": "tokens\/update.md", @@ -44404,7 +46754,7 @@ "x-appwrite": { "method": "delete", "group": "tokens", - "weight": 518, + "weight": 554, "cookies": false, "type": "", "demo": "tokens\/delete.md", @@ -50563,7 +52913,8 @@ "x-example": "legacy", "enum": [ "legacy", - "tablesdb" + "tablesdb", + "documentsdb" ] } }, @@ -58891,6 +61242,118 @@ "databaseWrites": [] } }, + "usageDocumentsDB": { + "description": "UsageDocumentsDB", + "type": "object", + "properties": { + "range": { + "type": "string", + "description": "Time range of the usage stats.", + "x-example": "30d" + }, + "collectionsTotal": { + "type": "integer", + "description": "Total aggregated number of collections.", + "x-example": 0, + "format": "int32" + }, + "documentsTotal": { + "type": "integer", + "description": "Total aggregated number of documents.", + "x-example": 0, + "format": "int32" + }, + "storageTotal": { + "type": "integer", + "description": "Total aggregated storage used in bytes.", + "x-example": 0, + "format": "int32" + }, + "databaseReadsTotal": { + "type": "integer", + "description": "Total number of database reads.", + "x-example": 0, + "format": "int32" + }, + "databaseWritesTotal": { + "type": "integer", + "description": "Total number of database writes.", + "x-example": 0, + "format": "int32" + }, + "collections": { + "type": "array", + "description": "Aggregated number of collections per period.", + "items": { + "type": "object", + "$ref": "#\/definitions\/metric" + }, + "x-example": [] + }, + "documents": { + "type": "array", + "description": "Aggregated number of documents per period.", + "items": { + "type": "object", + "$ref": "#\/definitions\/metric" + }, + "x-example": [] + }, + "storage": { + "type": "array", + "description": "Aggregated storage used in bytes per period.", + "items": { + "type": "object", + "$ref": "#\/definitions\/metric" + }, + "x-example": [] + }, + "databaseReads": { + "type": "array", + "description": "An array of aggregated number of database reads.", + "items": { + "type": "object", + "$ref": "#\/definitions\/metric" + }, + "x-example": [] + }, + "databaseWrites": { + "type": "array", + "description": "An array of aggregated number of database writes.", + "items": { + "type": "object", + "$ref": "#\/definitions\/metric" + }, + "x-example": [] + } + }, + "required": [ + "range", + "collectionsTotal", + "documentsTotal", + "storageTotal", + "databaseReadsTotal", + "databaseWritesTotal", + "collections", + "documents", + "storage", + "databaseReads", + "databaseWrites" + ], + "example": { + "range": "30d", + "collectionsTotal": 0, + "documentsTotal": 0, + "storageTotal": 0, + "databaseReadsTotal": 0, + "databaseWritesTotal": 0, + "collections": [], + "documents": [], + "storage": [], + "databaseReads": [], + "databaseWrites": [] + } + }, "usageTable": { "description": "UsageTable", "type": "object", @@ -60250,7 +62713,13 @@ }, "documentsTotal": { "type": "integer", - "description": "Total aggregated number of documents.", + "description": "Total aggregated number of documents in legacy\/tablesdb.", + "x-example": 0, + "format": "int32" + }, + "documentsdbDocumentsTotal": { + "type": "integer", + "description": "Total aggregated number of documents in documentsdb.", "x-example": 0, "format": "int32" }, @@ -60266,12 +62735,24 @@ "x-example": 0, "format": "int32" }, + "documentsdbTotal": { + "type": "integer", + "description": "Total aggregated number of documentsdb.", + "x-example": 0, + "format": "int32" + }, "databasesStorageTotal": { "type": "integer", "description": "Total aggregated sum of databases storage size (in bytes).", "x-example": 0, "format": "int32" }, + "documentsdbDatabasesStorageTotal": { + "type": "integer", + "description": "Total aggregated sum of documentsdb databases storage size (in bytes).", + "x-example": 0, + "format": "int32" + }, "usersTotal": { "type": "integer", "description": "Total aggregated number of users.", @@ -60332,6 +62813,18 @@ "x-example": 0, "format": "int32" }, + "documentsdbDatabasesReadsTotal": { + "type": "integer", + "description": "Total number of documentsdb databases reads.", + "x-example": 0, + "format": "int32" + }, + "documentsdbDatabasesWritesTotal": { + "type": "integer", + "description": "Total number of documentsdb databases writes.", + "x-example": 0, + "format": "int32" + }, "requests": { "type": "array", "description": "Aggregated number of requests per period.", @@ -60461,6 +62954,33 @@ }, "x-example": [] }, + "documentsdbDatabasesReads": { + "type": "array", + "description": "An array of aggregated number of documentsdb database reads.", + "items": { + "type": "object", + "$ref": "#\/definitions\/metric" + }, + "x-example": [] + }, + "documentsdbDatabasesWrites": { + "type": "array", + "description": "An array of aggregated number of documentsdb database writes.", + "items": { + "type": "object", + "$ref": "#\/definitions\/metric" + }, + "x-example": [] + }, + "documentsdbDatabasesStorage": { + "type": "array", + "description": "An array of aggregated sum of documentsdb databases storage size (in bytes) per period.", + "items": { + "type": "object", + "$ref": "#\/definitions\/metric" + }, + "x-example": [] + }, "imageTransformations": { "type": "array", "description": "An array of aggregated number of image transformations.", @@ -60480,9 +63000,12 @@ "required": [ "executionsTotal", "documentsTotal", + "documentsdbDocumentsTotal", "rowsTotal", "databasesTotal", + "documentsdbTotal", "databasesStorageTotal", + "documentsdbDatabasesStorageTotal", "usersTotal", "filesStorageTotal", "functionsStorageTotal", @@ -60493,6 +63016,8 @@ "buildsMbSecondsTotal", "databasesReadsTotal", "databasesWritesTotal", + "documentsdbDatabasesReadsTotal", + "documentsdbDatabasesWritesTotal", "requests", "network", "users", @@ -60508,15 +63033,21 @@ "authPhoneCountryBreakdown", "databasesReads", "databasesWrites", + "documentsdbDatabasesReads", + "documentsdbDatabasesWrites", + "documentsdbDatabasesStorage", "imageTransformations", "imageTransformationsTotal" ], "example": { "executionsTotal": 0, "documentsTotal": 0, + "documentsdbDocumentsTotal": 0, "rowsTotal": 0, "databasesTotal": 0, + "documentsdbTotal": 0, "databasesStorageTotal": 0, + "documentsdbDatabasesStorageTotal": 0, "usersTotal": 0, "filesStorageTotal": 0, "functionsStorageTotal": 0, @@ -60527,6 +63058,8 @@ "buildsMbSecondsTotal": 0, "databasesReadsTotal": 0, "databasesWritesTotal": 0, + "documentsdbDatabasesReadsTotal": 0, + "documentsdbDatabasesWritesTotal": 0, "requests": [], "network": [], "users": [], @@ -60542,6 +63075,9 @@ "authPhoneCountryBreakdown": [], "databasesReads": [], "databasesWrites": [], + "documentsdbDatabasesReads": [], + "documentsdbDatabasesWrites": [], + "documentsdbDatabasesStorage": [], "imageTransformations": [], "imageTransformationsTotal": 0 } diff --git a/app/config/specs/swagger2-latest-server.json b/app/config/specs/swagger2-latest-server.json index 63e43dbf69..df9b827cb4 100644 --- a/app/config/specs/swagger2-latest-server.json +++ b/app/config/specs/swagger2-latest-server.json @@ -9750,6 +9750,119 @@ ] } }, + "\/databases\/{databaseId}\/collections\/{collectionId}\/attributes\/relationship\/{key}": { + "patch": { + "summary": "Update relationship attribute", + "operationId": "databasesUpdateRelationshipAttribute", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "databases" + ], + "description": "Update relationship attribute. [Learn more about relationship attributes](https:\/\/appwrite.io\/docs\/databases-relationships#relationship-attributes).\n", + "responses": { + "200": { + "description": "AttributeRelationship", + "schema": { + "$ref": "#\/definitions\/attributeRelationship" + } + } + }, + "deprecated": true, + "x-appwrite": { + "method": "updateRelationshipAttribute", + "group": "attributes", + "weight": 349, + "cookies": false, + "type": "", + "demo": "databases\/update-relationship-attribute.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/databases\/update-relationship-attribute.md", + "deprecated": { + "since": "1.8.0", + "replaceWith": "tablesDB.updateRelationshipColumn" + }, + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "key", + "description": "Attribute Key.", + "required": true, + "type": "string", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "onDelete": { + "type": "string", + "description": "Constraints option", + "default": null, + "x-example": "cascade", + "enum": [ + "cascade", + "restrict", + "setNull" + ], + "x-enum-name": "RelationMutate", + "x-enum-keys": [], + "x-nullable": true + }, + "newKey": { + "type": "string", + "description": "New Attribute Key.", + "default": null, + "x-example": null, + "x-nullable": true + } + } + } + } + ] + } + }, "\/databases\/{databaseId}\/collections\/{collectionId}\/attributes\/string": { "post": { "summary": "Create string attribute", @@ -10418,119 +10531,6 @@ ] } }, - "\/databases\/{databaseId}\/collections\/{collectionId}\/attributes\/{key}\/relationship": { - "patch": { - "summary": "Update relationship attribute", - "operationId": "databasesUpdateRelationshipAttribute", - "consumes": [ - "application\/json" - ], - "produces": [ - "application\/json" - ], - "tags": [ - "databases" - ], - "description": "Update relationship attribute. [Learn more about relationship attributes](https:\/\/appwrite.io\/docs\/databases-relationships#relationship-attributes).\n", - "responses": { - "200": { - "description": "AttributeRelationship", - "schema": { - "$ref": "#\/definitions\/attributeRelationship" - } - } - }, - "deprecated": true, - "x-appwrite": { - "method": "updateRelationshipAttribute", - "group": "attributes", - "weight": 349, - "cookies": false, - "type": "", - "demo": "databases\/update-relationship-attribute.md", - "rate-limit": 0, - "rate-time": 3600, - "rate-key": "url:{url},ip:{ip}", - "scope": "collections.write", - "platforms": [ - "console", - "server" - ], - "packaging": false, - "public": true, - "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/databases\/update-relationship-attribute.md", - "deprecated": { - "since": "1.8.0", - "replaceWith": "tablesDB.updateRelationshipColumn" - }, - "auth": { - "Project": [], - "Key": [] - } - }, - "security": [ - { - "Project": [], - "Key": [] - } - ], - "parameters": [ - { - "name": "databaseId", - "description": "Database ID.", - "required": true, - "type": "string", - "x-example": "", - "in": "path" - }, - { - "name": "collectionId", - "description": "Collection ID.", - "required": true, - "type": "string", - "x-example": "", - "in": "path" - }, - { - "name": "key", - "description": "Attribute Key.", - "required": true, - "type": "string", - "in": "path" - }, - { - "name": "payload", - "in": "body", - "schema": { - "type": "object", - "properties": { - "onDelete": { - "type": "string", - "description": "Constraints option", - "default": null, - "x-example": "cascade", - "enum": [ - "cascade", - "restrict", - "setNull" - ], - "x-enum-name": "RelationMutate", - "x-enum-keys": [], - "x-nullable": true - }, - "newKey": { - "type": "string", - "description": "New Attribute Key.", - "default": null, - "x-example": null, - "x-nullable": true - } - } - } - } - ] - } - }, "\/databases\/{databaseId}\/collections\/{collectionId}\/documents": { "get": { "summary": "List documents", @@ -10730,6 +10730,7 @@ "databaseId", "collectionId", "documents", + "transactionId", "transactionId" ], "required": [ @@ -12284,6 +12285,2922 @@ ] } }, + "\/documentsdb": { + "get": { + "summary": "List databases", + "operationId": "documentsDBList", + "consumes": [], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Get a list of all databases from the current Appwrite project. You can use the search parameter to filter your results.", + "responses": { + "200": { + "description": "Databases List", + "schema": { + "$ref": "#\/definitions\/databaseList" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "list", + "group": "documentsdb", + "weight": 433, + "cookies": false, + "type": "", + "demo": "documentsdb\/list.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "databases.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/list.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following columns: name", + "required": false, + "type": "array", + "collectionFormat": "multi", + "items": { + "type": "string" + }, + "default": [], + "in": "query" + }, + { + "name": "search", + "description": "Search term to filter your list results. Max length: 256 chars.", + "required": false, + "type": "string", + "x-example": "", + "default": "", + "in": "query" + }, + { + "name": "total", + "description": "When set to false, the total count returned will be 0 and will not be calculated.", + "required": false, + "type": "boolean", + "x-example": false, + "default": true, + "in": "query" + } + ] + }, + "post": { + "summary": "Create database", + "operationId": "documentsDBCreate", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Create a new Database.\n", + "responses": { + "201": { + "description": "Database", + "schema": { + "$ref": "#\/definitions\/database" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "create", + "group": "documentsdb", + "weight": 429, + "cookies": false, + "type": "", + "demo": "documentsdb\/create.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "databases.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/create.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "databaseId": { + "type": "string", + "description": "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.", + "default": null, + "x-example": "" + }, + "name": { + "type": "string", + "description": "Database name. Max length: 128 chars.", + "default": null, + "x-example": "" + }, + "enabled": { + "type": "boolean", + "description": "Is the database enabled? When set to 'disabled', users cannot access the database but Server SDKs with an API key can still read and write to the database. No data is lost when this is toggled.", + "default": true, + "x-example": false + } + }, + "required": [ + "databaseId", + "name" + ] + } + } + ] + } + }, + "\/documentsdb\/transactions": { + "get": { + "summary": "List transactions", + "operationId": "documentsDBListTransactions", + "consumes": [], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": false, + "responses": { + "200": { + "description": "Transaction List", + "schema": { + "$ref": "#\/definitions\/transactionList" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "listTransactions", + "group": "transactions", + "weight": 463, + "cookies": false, + "type": "", + "demo": "documentsdb\/list-transactions.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.read", + "platforms": [ + "server", + "client" + ], + "packaging": false, + "public": true, + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries).", + "required": false, + "type": "array", + "collectionFormat": "multi", + "items": { + "type": "string" + }, + "default": [], + "in": "query" + } + ] + }, + "post": { + "summary": "Create transaction", + "operationId": "documentsDBCreateTransaction", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": false, + "responses": { + "201": { + "description": "Transaction", + "schema": { + "$ref": "#\/definitions\/transaction" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "createTransaction", + "group": "transactions", + "weight": 459, + "cookies": false, + "type": "", + "demo": "documentsdb\/create-transaction.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.write", + "platforms": [ + "server", + "client" + ], + "packaging": false, + "public": true, + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "ttl": { + "type": "integer", + "description": "Seconds before the transaction expires.", + "default": 300, + "x-example": 60 + } + } + } + } + ] + } + }, + "\/documentsdb\/transactions\/{transactionId}": { + "get": { + "summary": "Get transaction", + "operationId": "documentsDBGetTransaction", + "consumes": [], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": false, + "responses": { + "200": { + "description": "Transaction", + "schema": { + "$ref": "#\/definitions\/transaction" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "getTransaction", + "group": "transactions", + "weight": 460, + "cookies": false, + "type": "", + "demo": "documentsdb\/get-transaction.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.read", + "platforms": [ + "server", + "client" + ], + "packaging": false, + "public": true, + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "transactionId", + "description": "Transaction ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + } + ] + }, + "patch": { + "summary": "Update transaction", + "operationId": "documentsDBUpdateTransaction", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": false, + "responses": { + "200": { + "description": "Transaction", + "schema": { + "$ref": "#\/definitions\/transaction" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "updateTransaction", + "group": "transactions", + "weight": 461, + "cookies": false, + "type": "", + "demo": "documentsdb\/update-transaction.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.write", + "platforms": [ + "server", + "client" + ], + "packaging": false, + "public": true, + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "transactionId", + "description": "Transaction ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "commit": { + "type": "boolean", + "description": "Commit transaction?", + "default": false, + "x-example": false + }, + "rollback": { + "type": "boolean", + "description": "Rollback transaction?", + "default": false, + "x-example": false + } + } + } + } + ] + }, + "delete": { + "summary": "Delete transaction", + "operationId": "documentsDBDeleteTransaction", + "consumes": [ + "application\/json" + ], + "produces": [], + "tags": [ + "documentsDB" + ], + "description": false, + "responses": { + "204": { + "description": "No content" + } + }, + "deprecated": false, + "x-appwrite": { + "method": "deleteTransaction", + "group": "transactions", + "weight": 462, + "cookies": false, + "type": "", + "demo": "documentsdb\/delete-transaction.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.write", + "platforms": [ + "server", + "client" + ], + "packaging": false, + "public": true, + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "transactionId", + "description": "Transaction ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + } + ] + } + }, + "\/documentsdb\/transactions\/{transactionId}\/operations": { + "post": { + "summary": "Create operations", + "operationId": "documentsDBCreateOperations", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": false, + "responses": { + "201": { + "description": "Transaction", + "schema": { + "$ref": "#\/definitions\/transaction" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "createOperations", + "group": "transactions", + "weight": 464, + "cookies": false, + "type": "", + "demo": "documentsdb\/create-operations.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.write", + "platforms": [ + "server", + "client" + ], + "packaging": false, + "public": true, + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [], + "Session": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "transactionId", + "description": "Transaction ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "operations": { + "type": "array", + "description": "Array of staged operations.", + "default": [], + "x-example": "[\n\t {\n\t \"action\": \"create\",\n\t \"databaseId\": \"\",\n\t \"collectionId\": \"\",\n\t \"documentId\": \"\",\n\t \"data\": {\n\t \"name\": \"Walter O'Brien\"\n\t }\n\t }\n\t]", + "items": { + "type": "object" + } + } + } + } + } + ] + } + }, + "\/documentsdb\/{databaseId}": { + "get": { + "summary": "Get database", + "operationId": "documentsDBGet", + "consumes": [], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Get a database by its unique ID. This endpoint response returns a JSON object with the database metadata.", + "responses": { + "200": { + "description": "Database", + "schema": { + "$ref": "#\/definitions\/database" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "get", + "group": "documentsdb", + "weight": 430, + "cookies": false, + "type": "", + "demo": "documentsdb\/get.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "databases.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/get.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + } + ] + }, + "put": { + "summary": "Update database", + "operationId": "documentsDBUpdate", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Update a database by its unique ID.", + "responses": { + "200": { + "description": "Database", + "schema": { + "$ref": "#\/definitions\/database" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "update", + "group": "documentsdb", + "weight": 431, + "cookies": false, + "type": "", + "demo": "documentsdb\/update.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "databases.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/update.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "Database name. Max length: 128 chars.", + "default": null, + "x-example": "" + }, + "enabled": { + "type": "boolean", + "description": "Is database enabled? When set to 'disabled', users cannot access the database but Server SDKs with an API key can still read and write to the database. No data is lost when this is toggled.", + "default": true, + "x-example": false + } + }, + "required": [ + "name" + ] + } + } + ] + }, + "delete": { + "summary": "Delete database", + "operationId": "documentsDBDelete", + "consumes": [ + "application\/json" + ], + "produces": [], + "tags": [ + "documentsDB" + ], + "description": "Delete a database by its unique ID. Only API keys with with databases.write scope can delete a database.", + "responses": { + "204": { + "description": "No content" + } + }, + "deprecated": false, + "x-appwrite": { + "method": "delete", + "group": "documentsdb", + "weight": 432, + "cookies": false, + "type": "", + "demo": "documentsdb\/delete.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "databases.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/delete.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections": { + "get": { + "summary": "List collections", + "operationId": "documentsDBListCollections", + "consumes": [], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Get a list of all collections that belong to the provided databaseId. You can use the search parameter to filter your results.", + "responses": { + "200": { + "description": "Collections List", + "schema": { + "$ref": "#\/definitions\/collectionList" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "listCollections", + "group": "collections", + "weight": 440, + "cookies": false, + "type": "", + "demo": "documentsdb\/list-collections.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/list-collections.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following attributes: name, enabled, documentSecurity", + "required": false, + "type": "array", + "collectionFormat": "multi", + "items": { + "type": "string" + }, + "default": [], + "in": "query" + }, + { + "name": "search", + "description": "Search term to filter your list results. Max length: 256 chars.", + "required": false, + "type": "string", + "x-example": "", + "default": "", + "in": "query" + }, + { + "name": "total", + "description": "When set to false, the total count returned will be 0 and will not be calculated.", + "required": false, + "type": "boolean", + "x-example": false, + "default": true, + "in": "query" + } + ] + }, + "post": { + "summary": "Create collection", + "operationId": "documentsDBCreateCollection", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Create a new Collection. Before using this route, you should create a new database resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.", + "responses": { + "201": { + "description": "Collection", + "schema": { + "$ref": "#\/definitions\/collection" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "createCollection", + "group": "collections", + "weight": 436, + "cookies": false, + "type": "", + "demo": "documentsdb\/create-collection.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/create-collection.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "collectionId": { + "type": "string", + "description": "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.", + "default": null, + "x-example": "" + }, + "name": { + "type": "string", + "description": "Collection name. Max length: 128 chars.", + "default": null, + "x-example": "" + }, + "permissions": { + "type": "array", + "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\")\"]", + "items": { + "type": "string" + } + }, + "documentSecurity": { + "type": "boolean", + "description": "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).", + "default": false, + "x-example": false + }, + "enabled": { + "type": "boolean", + "description": "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.", + "default": true, + "x-example": false + }, + "attributes": { + "type": "array", + "description": "Array of attribute definitions to create. Each attribute should contain: key (string), type (string: string, integer, float, boolean, datetime, relationship), size (integer, required for string type), required (boolean, optional), default (mixed, optional), array (boolean, optional), and type-specific options.", + "default": [], + "x-example": null, + "items": { + "type": "object" + } + }, + "indexes": { + "type": "array", + "description": "Array of index definitions to create. Each index should contain: key (string), type (string: key, fulltext, unique, spatial), attributes (array of attribute keys), orders (array of ASC\/DESC, optional), and lengths (array of integers, optional).", + "default": [], + "x-example": null, + "items": { + "type": "object" + } + } + }, + "required": [ + "collectionId", + "name" + ] + } + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}": { + "get": { + "summary": "Get collection", + "operationId": "documentsDBGetCollection", + "consumes": [], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Get a collection by its unique ID. This endpoint response returns a JSON object with the collection metadata.", + "responses": { + "200": { + "description": "Collection", + "schema": { + "$ref": "#\/definitions\/collection" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "getCollection", + "group": "collections", + "weight": 437, + "cookies": false, + "type": "", + "demo": "documentsdb\/get-collection.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/get-collection.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + } + ] + }, + "put": { + "summary": "Update collection", + "operationId": "documentsDBUpdateCollection", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Update a collection by its unique ID.", + "responses": { + "200": { + "description": "Collection", + "schema": { + "$ref": "#\/definitions\/collection" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "updateCollection", + "group": "collections", + "weight": 438, + "cookies": false, + "type": "", + "demo": "documentsdb\/update-collection.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/update-collection.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "Collection name. Max length: 128 chars.", + "default": null, + "x-example": "" + }, + "permissions": { + "type": "array", + "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\")\"]", + "items": { + "type": "string" + } + }, + "documentSecurity": { + "type": "boolean", + "description": "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).", + "default": false, + "x-example": false + }, + "enabled": { + "type": "boolean", + "description": "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.", + "default": true, + "x-example": false + } + }, + "required": [ + "name" + ] + } + } + ] + }, + "delete": { + "summary": "Delete collection", + "operationId": "documentsDBDeleteCollection", + "consumes": [ + "application\/json" + ], + "produces": [], + "tags": [ + "documentsDB" + ], + "description": "Delete a collection by its unique ID. Only users with write permissions have access to delete this resource.", + "responses": { + "204": { + "description": "No content" + } + }, + "deprecated": false, + "x-appwrite": { + "method": "deleteCollection", + "group": "collections", + "weight": 439, + "cookies": false, + "type": "", + "demo": "documentsdb\/delete-collection.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/delete-collection.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/documents": { + "get": { + "summary": "List documents", + "operationId": "documentsDBListDocuments", + "consumes": [], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Get a list of all the user's documents in a given collection. You can use the query params to filter your results.", + "responses": { + "200": { + "description": "Documents List", + "schema": { + "$ref": "#\/definitions\/documentList" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "listDocuments", + "group": "documents", + "weight": 455, + "cookies": false, + "type": "", + "demo": "documentsdb\/list-documents.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.read", + "platforms": [ + "client", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/list-documents.md", + "auth": { + "Project": [], + "Session": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "Key": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long.", + "required": false, + "type": "array", + "collectionFormat": "multi", + "items": { + "type": "string" + }, + "default": [], + "in": "query" + }, + { + "name": "transactionId", + "description": "Transaction ID to read uncommitted changes within the transaction.", + "required": false, + "type": "string", + "x-example": "", + "in": "query" + }, + { + "name": "total", + "description": "When set to false, the total count returned will be 0 and will not be calculated.", + "required": false, + "type": "boolean", + "x-example": false, + "default": true, + "in": "query" + } + ] + }, + "post": { + "summary": "Create document", + "operationId": "documentsDBCreateDocument", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Create a new Document. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.", + "responses": { + "201": { + "description": "Document", + "schema": { + "$ref": "#\/definitions\/document" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "createDocument", + "group": "documents", + "weight": 447, + "cookies": false, + "type": "", + "demo": "documentsdb\/create-document.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/create-document.md", + "methods": [ + { + "name": "createDocument", + "namespace": "documentsDB", + "desc": "Create document", + "auth": { + "Project": [], + "Session": [] + }, + "parameters": [ + "databaseId", + "collectionId", + "documentId", + "data", + "permissions" + ], + "required": [ + "databaseId", + "collectionId", + "documentId", + "data" + ], + "responses": [ + { + "code": 201, + "model": "#\/definitions\/document" + } + ], + "description": "Create a new Document. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.", + "demo": "documentsdb\/create-document.md", + "public": true + }, + { + "name": "createDocuments", + "namespace": "documentsDB", + "desc": "Create documents", + "auth": { + "Project": [], + "Key": [] + }, + "parameters": [ + "databaseId", + "collectionId", + "documents" + ], + "required": [ + "databaseId", + "collectionId", + "documents" + ], + "responses": [ + { + "code": 201, + "model": "#\/definitions\/documentList" + } + ], + "description": "Create new Documents. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.", + "demo": "documentsdb\/create-documents.md", + "public": true + } + ], + "auth": { + "Project": [], + "Session": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "Key": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "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.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "documentId": { + "type": "string", + "description": "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.", + "default": "", + "x-example": "" + }, + "data": { + "type": "object", + "description": "Document data as JSON object.", + "default": [], + "x-example": "{\"username\":\"walter.obrien\",\"email\":\"walter.obrien@example.com\",\"fullName\":\"Walter O'Brien\",\"age\":30,\"isAdmin\":false}" + }, + "permissions": { + "type": "array", + "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\")\"]", + "items": { + "type": "string" + } + }, + "documents": { + "type": "array", + "description": "Array of documents data as JSON objects.", + "default": [], + "x-example": null, + "items": { + "type": "object" + } + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "default": null, + "x-example": "" + } + } + } + } + ] + }, + "put": { + "summary": "Upsert documents", + "operationId": "documentsDBUpsertDocuments", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Create or update Documents. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.\n", + "responses": { + "201": { + "description": "Documents List", + "schema": { + "$ref": "#\/definitions\/documentList" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "upsertDocuments", + "group": "documents", + "weight": 452, + "cookies": false, + "type": "", + "demo": "documentsdb\/upsert-documents.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/upsert-documents.md", + "methods": [ + { + "name": "upsertDocuments", + "namespace": "documentsDB", + "desc": "", + "auth": { + "Project": [], + "Key": [] + }, + "parameters": [ + "databaseId", + "collectionId", + "documents", + "transactionId" + ], + "required": [ + "databaseId", + "collectionId", + "documents" + ], + "responses": [ + { + "code": 201, + "model": "#\/definitions\/documentList" + } + ], + "description": "Create or update Documents. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.\n", + "demo": "documentsdb\/upsert-documents.md", + "public": true + } + ], + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "documents": { + "type": "array", + "description": "Array of document data as JSON objects. May contain partial documents.", + "default": null, + "x-example": null, + "items": { + "type": "object" + } + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "default": null, + "x-example": "" + } + }, + "required": [ + "documents" + ] + } + } + ] + }, + "patch": { + "summary": "Update documents", + "operationId": "documentsDBUpdateDocuments", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Update all documents that match your queries, if no queries are submitted then all documents are updated. You can pass only specific fields to be updated.", + "responses": { + "200": { + "description": "Documents List", + "schema": { + "$ref": "#\/definitions\/documentList" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "updateDocuments", + "group": "documents", + "weight": 450, + "cookies": false, + "type": "", + "demo": "documentsdb\/update-documents.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/update-documents.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "data": { + "type": "object", + "description": "Document data as JSON object. Include only attribute and value pairs to be updated.", + "default": [], + "x-example": "{}" + }, + "queries": { + "type": "array", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long.", + "default": [], + "x-example": null, + "items": { + "type": "string" + } + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "default": null, + "x-example": "" + } + } + } + } + ] + }, + "delete": { + "summary": "Delete documents", + "operationId": "documentsDBDeleteDocuments", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Bulk delete documents using queries, if no queries are passed then all documents are deleted.", + "responses": { + "200": { + "description": "Documents List", + "schema": { + "$ref": "#\/definitions\/documentList" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "deleteDocuments", + "group": "documents", + "weight": 454, + "cookies": false, + "type": "", + "demo": "documentsdb\/delete-documents.md", + "rate-limit": 60, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/delete-documents.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "queries": { + "type": "array", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long.", + "default": [], + "x-example": null, + "items": { + "type": "string" + } + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "default": null, + "x-example": "" + } + } + } + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/documents\/{documentId}": { + "get": { + "summary": "Get document", + "operationId": "documentsDBGetDocument", + "consumes": [], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Get a document by its unique ID. This endpoint response returns a JSON object with the document data.", + "responses": { + "200": { + "description": "Document", + "schema": { + "$ref": "#\/definitions\/document" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "getDocument", + "group": "documents", + "weight": 448, + "cookies": false, + "type": "", + "demo": "documentsdb\/get-document.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "documents.read", + "platforms": [ + "client", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/get-document.md", + "auth": { + "Project": [], + "Session": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "Key": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long.", + "required": false, + "type": "array", + "collectionFormat": "multi", + "items": { + "type": "string" + }, + "default": [], + "in": "query" + }, + { + "name": "transactionId", + "description": "Transaction ID to read uncommitted changes within the transaction.", + "required": false, + "type": "string", + "x-example": "", + "in": "query" + } + ] + }, + "put": { + "summary": "Upsert a document", + "operationId": "documentsDBUpsertDocument", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Create or update a Document. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.", + "responses": { + "201": { + "description": "Document", + "schema": { + "$ref": "#\/definitions\/document" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "upsertDocument", + "group": "documents", + "weight": 451, + "cookies": false, + "type": "", + "demo": "documentsdb\/upsert-document.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/upsert-document.md", + "methods": [ + { + "name": "upsertDocument", + "namespace": "documentsDB", + "desc": "", + "auth": { + "Project": [], + "Session": [] + }, + "parameters": [ + "databaseId", + "collectionId", + "documentId", + "data", + "permissions", + "transactionId" + ], + "required": [ + "databaseId", + "collectionId", + "documentId" + ], + "responses": [ + { + "code": 201, + "model": "#\/definitions\/document" + } + ], + "description": "Create or update a Document. Before using this route, you should create a new collection resource using either a [server integration](https:\/\/appwrite.io\/docs\/server\/databases#documentsDBCreateCollection) API or directly from your database console.", + "demo": "documentsdb\/upsert-document.md", + "public": true + } + ], + "auth": { + "Project": [], + "Session": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "Key": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "data": { + "type": "object", + "description": "Document data as JSON object. Include all required fields of the document to be created or updated.", + "default": [], + "x-example": "{}" + }, + "permissions": { + "type": "array", + "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\")\"]", + "items": { + "type": "string" + } + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "default": null, + "x-example": "" + } + } + } + } + ] + }, + "patch": { + "summary": "Update document", + "operationId": "documentsDBUpdateDocument", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Update a document by its unique ID. Using the patch method you can pass only specific fields that will get updated.", + "responses": { + "200": { + "description": "Document", + "schema": { + "$ref": "#\/definitions\/document" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "updateDocument", + "group": "documents", + "weight": 449, + "cookies": false, + "type": "", + "demo": "documentsdb\/update-document.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/update-document.md", + "auth": { + "Project": [], + "Session": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "Key": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "data": { + "type": "object", + "description": "Document data as JSON object. Include only fields and value pairs to be updated.", + "default": [], + "x-example": "{}" + }, + "permissions": { + "type": "array", + "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\")\"]", + "items": { + "type": "string" + } + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "default": null, + "x-example": "" + } + } + } + } + ] + }, + "delete": { + "summary": "Delete document", + "operationId": "documentsDBDeleteDocument", + "consumes": [ + "application\/json" + ], + "produces": [], + "tags": [ + "documentsDB" + ], + "description": "Delete a document by its unique ID.", + "responses": { + "204": { + "description": "No content" + } + }, + "deprecated": false, + "x-appwrite": { + "method": "deleteDocument", + "group": "documents", + "weight": 453, + "cookies": false, + "type": "", + "demo": "documentsdb\/delete-document.md", + "rate-limit": 60, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/delete-document.md", + "auth": { + "Project": [], + "Session": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "Key": [], + "JWT": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "default": null, + "x-example": "" + } + } + } + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/documents\/{documentId}\/{attribute}\/decrement": { + "patch": { + "summary": "Decrement document attribute", + "operationId": "documentsDBDecrementDocumentAttribute", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Decrement a specific column of a row by a given value.", + "responses": { + "200": { + "description": "Document", + "schema": { + "$ref": "#\/definitions\/document" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "decrementDocumentAttribute", + "group": "documents", + "weight": 458, + "cookies": false, + "type": "", + "demo": "documentsdb\/decrement-document-attribute.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server", + "console" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/decrement-document-attribute.md", + "auth": { + "Project": [], + "Session": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "JWT": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "attribute", + "description": "Attribute key.", + "required": true, + "type": "string", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "value": { + "type": "number", + "description": "Value to decrement the attribute by. The value must be a number.", + "default": 1, + "x-example": null + }, + "min": { + "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 + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "default": null, + "x-example": "" + } + } + } + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/documents\/{documentId}\/{attribute}\/increment": { + "patch": { + "summary": "Increment document attribute", + "operationId": "documentsDBIncrementDocumentAttribute", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Increment a specific column of a row by a given value.", + "responses": { + "200": { + "description": "Document", + "schema": { + "$ref": "#\/definitions\/document" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "incrementDocumentAttribute", + "group": "documents", + "weight": 457, + "cookies": false, + "type": "", + "demo": "documentsdb\/increment-document-attribute.md", + "rate-limit": 120, + "rate-time": 60, + "rate-key": "ip:{ip},method:{method},url:{url},userId:{userId}", + "scope": "documents.write", + "platforms": [ + "client", + "server", + "console" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/increment-document-attribute.md", + "auth": { + "Project": [], + "Session": [] + } + }, + "security": [ + { + "Project": [], + "Session": [], + "JWT": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "documentId", + "description": "Document ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "attribute", + "description": "Attribute key.", + "required": true, + "type": "string", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "value": { + "type": "number", + "description": "Value to increment the attribute by. The value must be a number.", + "default": 1, + "x-example": null + }, + "max": { + "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 + }, + "transactionId": { + "type": "string", + "description": "Transaction ID for staging the operation.", + "default": null, + "x-example": "" + } + } + } + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/indexes": { + "get": { + "summary": "List indexes", + "operationId": "documentsDBListIndexes", + "consumes": [], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "List indexes in the collection.", + "responses": { + "200": { + "description": "Indexes List", + "schema": { + "$ref": "#\/definitions\/indexList" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "listIndexes", + "group": "indexes", + "weight": 446, + "cookies": false, + "type": "", + "demo": "documentsdb\/list-indexes.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/list-indexes.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "queries", + "description": "Array of query strings generated using the Query class provided by the SDK. [Learn more about queries](https:\/\/appwrite.io\/docs\/queries). Maximum of 100 queries are allowed, each 4096 characters long. You may filter on the following attributes: key, type, status, attributes, error", + "required": false, + "type": "array", + "collectionFormat": "multi", + "items": { + "type": "string" + }, + "default": [], + "in": "query" + }, + { + "name": "total", + "description": "When set to false, the total count returned will be 0 and will not be calculated.", + "required": false, + "type": "boolean", + "x-example": false, + "default": true, + "in": "query" + } + ] + }, + "post": { + "summary": "Create index", + "operationId": "documentsDBCreateIndex", + "consumes": [ + "application\/json" + ], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Creates an index on the attributes listed. Your index should include all the attributes you will query in a single request.\nAttributes can be `key`, `fulltext`, and `unique`.", + "responses": { + "202": { + "description": "Index", + "schema": { + "$ref": "#\/definitions\/index" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "createIndex", + "group": "indexes", + "weight": 443, + "cookies": false, + "type": "", + "demo": "documentsdb\/create-index.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/create-index.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "payload", + "in": "body", + "schema": { + "type": "object", + "properties": { + "key": { + "type": "string", + "description": "Index Key.", + "default": null, + "x-example": null + }, + "type": { + "type": "string", + "description": "Index type.", + "default": null, + "x-example": "key", + "enum": [ + "key", + "fulltext", + "unique", + "spatial" + ], + "x-enum-name": "IndexType", + "x-enum-keys": [] + }, + "attributes": { + "type": "array", + "description": "Array of attributes to index. Maximum of 100 attributes are allowed, each 32 characters long.", + "default": null, + "x-example": null, + "items": { + "type": "string" + } + }, + "orders": { + "type": "array", + "description": "Array of index orders. Maximum of 100 orders are allowed.", + "default": [], + "x-example": null, + "items": { + "type": "string", + "enum": [ + "asc", + "desc" + ], + "x-enum-name": "OrderBy", + "x-enum-keys": [] + } + }, + "lengths": { + "type": "array", + "description": "Length of index. Maximum of 100", + "default": [], + "x-example": null, + "items": { + "type": "integer" + } + } + }, + "required": [ + "key", + "type", + "attributes" + ] + } + } + ] + } + }, + "\/documentsdb\/{databaseId}\/collections\/{collectionId}\/indexes\/{key}": { + "get": { + "summary": "Get index", + "operationId": "documentsDBGetIndex", + "consumes": [], + "produces": [ + "application\/json" + ], + "tags": [ + "documentsDB" + ], + "description": "Get index by ID.", + "responses": { + "200": { + "description": "Index", + "schema": { + "$ref": "#\/definitions\/index" + } + } + }, + "deprecated": false, + "x-appwrite": { + "method": "getIndex", + "group": "indexes", + "weight": 444, + "cookies": false, + "type": "", + "demo": "documentsdb\/get-index.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.read", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/get-index.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "key", + "description": "Index Key.", + "required": true, + "type": "string", + "in": "path" + } + ] + }, + "delete": { + "summary": "Delete index", + "operationId": "documentsDBDeleteIndex", + "consumes": [ + "application\/json" + ], + "produces": [], + "tags": [ + "documentsDB" + ], + "description": "Delete an index.", + "responses": { + "204": { + "description": "No content" + } + }, + "deprecated": false, + "x-appwrite": { + "method": "deleteIndex", + "group": "indexes", + "weight": 445, + "cookies": false, + "type": "", + "demo": "documentsdb\/delete-index.md", + "rate-limit": 0, + "rate-time": 3600, + "rate-key": "url:{url},ip:{ip}", + "scope": "collections.write", + "platforms": [ + "console", + "server" + ], + "packaging": false, + "public": true, + "edit": "https:\/\/github.com\/appwrite\/appwrite\/edit\/master\/docs\/references\/documentsdb\/delete-index.md", + "auth": { + "Project": [], + "Key": [] + } + }, + "security": [ + { + "Project": [], + "Key": [] + } + ], + "parameters": [ + { + "name": "databaseId", + "description": "Database ID.", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "collectionId", + "description": "Collection ID. You can create a new collection using the Database service [server integration](https:\/\/appwrite.io\/docs\/server\/databases#databasesCreateCollection).", + "required": true, + "type": "string", + "x-example": "", + "in": "path" + }, + { + "name": "key", + "description": "Index Key.", + "required": true, + "type": "string", + "in": "path" + } + ] + } + }, "\/functions": { "get": { "summary": "List functions", @@ -12308,7 +15225,7 @@ "x-appwrite": { "method": "list", "group": "functions", - "weight": 439, + "weight": 475, "cookies": false, "type": "", "demo": "functions\/list.md", @@ -12391,7 +15308,7 @@ "x-appwrite": { "method": "create", "group": "functions", - "weight": 436, + "weight": 472, "cookies": false, "type": "", "demo": "functions\/create.md", @@ -12705,7 +15622,7 @@ "x-appwrite": { "method": "listRuntimes", "group": "runtimes", - "weight": 441, + "weight": 477, "cookies": false, "type": "", "demo": "functions\/list-runtimes.md", @@ -12756,7 +15673,7 @@ "x-appwrite": { "method": "listSpecifications", "group": "runtimes", - "weight": 442, + "weight": 478, "cookies": false, "type": "", "demo": "functions\/list-specifications.md", @@ -12807,7 +15724,7 @@ "x-appwrite": { "method": "get", "group": "functions", - "weight": 437, + "weight": 473, "cookies": false, "type": "", "demo": "functions\/get.md", @@ -12868,7 +15785,7 @@ "x-appwrite": { "method": "update", "group": "functions", - "weight": 438, + "weight": 474, "cookies": false, "type": "", "demo": "functions\/update.md", @@ -13178,7 +16095,7 @@ "x-appwrite": { "method": "delete", "group": "functions", - "weight": 440, + "weight": 476, "cookies": false, "type": "", "demo": "functions\/delete.md", @@ -13241,7 +16158,7 @@ "x-appwrite": { "method": "updateFunctionDeployment", "group": "functions", - "weight": 445, + "weight": 481, "cookies": false, "type": "", "demo": "functions\/update-function-deployment.md", @@ -13320,7 +16237,7 @@ "x-appwrite": { "method": "listDeployments", "group": "deployments", - "weight": 446, + "weight": 482, "cookies": false, "type": "", "demo": "functions\/list-deployments.md", @@ -13411,7 +16328,7 @@ "x-appwrite": { "method": "createDeployment", "group": "deployments", - "weight": 443, + "weight": 479, "cookies": false, "type": "upload", "demo": "functions\/create-deployment.md", @@ -13505,7 +16422,7 @@ "x-appwrite": { "method": "createDuplicateDeployment", "group": "deployments", - "weight": 451, + "weight": 487, "cookies": false, "type": "", "demo": "functions\/create-duplicate-deployment.md", @@ -13592,7 +16509,7 @@ "x-appwrite": { "method": "createTemplateDeployment", "group": "deployments", - "weight": 448, + "weight": 484, "cookies": false, "type": "", "demo": "functions\/create-template-deployment.md", @@ -13714,7 +16631,7 @@ "x-appwrite": { "method": "createVcsDeployment", "group": "deployments", - "weight": 449, + "weight": 485, "cookies": false, "type": "", "demo": "functions\/create-vcs-deployment.md", @@ -13812,7 +16729,7 @@ "x-appwrite": { "method": "getDeployment", "group": "deployments", - "weight": 444, + "weight": 480, "cookies": false, "type": "", "demo": "functions\/get-deployment.md", @@ -13876,7 +16793,7 @@ "x-appwrite": { "method": "deleteDeployment", "group": "deployments", - "weight": 447, + "weight": 483, "cookies": false, "type": "", "demo": "functions\/delete-deployment.md", @@ -13945,7 +16862,7 @@ "x-appwrite": { "method": "getDeploymentDownload", "group": "deployments", - "weight": 450, + "weight": 486, "cookies": false, "type": "location", "demo": "functions\/get-deployment-download.md", @@ -14032,7 +16949,7 @@ "x-appwrite": { "method": "updateDeploymentStatus", "group": "deployments", - "weight": 452, + "weight": 488, "cookies": false, "type": "", "demo": "functions\/update-deployment-status.md", @@ -14101,7 +17018,7 @@ "x-appwrite": { "method": "listExecutions", "group": "executions", - "weight": 455, + "weight": 491, "cookies": false, "type": "", "demo": "functions\/list-executions.md", @@ -14186,7 +17103,7 @@ "x-appwrite": { "method": "createExecution", "group": "executions", - "weight": 453, + "weight": 489, "cookies": false, "type": "", "demo": "functions\/create-execution.md", @@ -14307,7 +17224,7 @@ "x-appwrite": { "method": "getExecution", "group": "executions", - "weight": 454, + "weight": 490, "cookies": false, "type": "", "demo": "functions\/get-execution.md", @@ -14374,7 +17291,7 @@ "x-appwrite": { "method": "deleteExecution", "group": "executions", - "weight": 456, + "weight": 492, "cookies": false, "type": "", "demo": "functions\/delete-execution.md", @@ -14443,7 +17360,7 @@ "x-appwrite": { "method": "listVariables", "group": "variables", - "weight": 461, + "weight": 497, "cookies": false, "type": "", "demo": "functions\/list-variables.md", @@ -14504,7 +17421,7 @@ "x-appwrite": { "method": "createVariable", "group": "variables", - "weight": 459, + "weight": 495, "cookies": false, "type": "", "demo": "functions\/create-variable.md", @@ -14596,7 +17513,7 @@ "x-appwrite": { "method": "getVariable", "group": "variables", - "weight": 460, + "weight": 496, "cookies": false, "type": "", "demo": "functions\/get-variable.md", @@ -14665,7 +17582,7 @@ "x-appwrite": { "method": "updateVariable", "group": "variables", - "weight": 462, + "weight": 498, "cookies": false, "type": "", "demo": "functions\/update-variable.md", @@ -14761,7 +17678,7 @@ "x-appwrite": { "method": "deleteVariable", "group": "variables", - "weight": 463, + "weight": 499, "cookies": false, "type": "", "demo": "functions\/delete-variable.md", @@ -22376,7 +25293,7 @@ "x-appwrite": { "method": "list", "group": "sites", - "weight": 468, + "weight": 504, "cookies": false, "type": "", "demo": "sites\/list.md", @@ -22459,7 +25376,7 @@ "x-appwrite": { "method": "create", "group": "sites", - "weight": 466, + "weight": 502, "cookies": false, "type": "", "demo": "sites\/create.md", @@ -22731,7 +25648,7 @@ "x-appwrite": { "method": "listFrameworks", "group": "frameworks", - "weight": 471, + "weight": 507, "cookies": false, "type": "", "demo": "sites\/list-frameworks.md", @@ -22782,7 +25699,7 @@ "x-appwrite": { "method": "listSpecifications", "group": "frameworks", - "weight": 494, + "weight": 530, "cookies": false, "type": "", "demo": "sites\/list-specifications.md", @@ -22833,7 +25750,7 @@ "x-appwrite": { "method": "get", "group": "sites", - "weight": 467, + "weight": 503, "cookies": false, "type": "", "demo": "sites\/get.md", @@ -22894,7 +25811,7 @@ "x-appwrite": { "method": "update", "group": "sites", - "weight": 469, + "weight": 505, "cookies": false, "type": "", "demo": "sites\/update.md", @@ -23161,7 +26078,7 @@ "x-appwrite": { "method": "delete", "group": "sites", - "weight": 470, + "weight": 506, "cookies": false, "type": "", "demo": "sites\/delete.md", @@ -23224,7 +26141,7 @@ "x-appwrite": { "method": "updateSiteDeployment", "group": "sites", - "weight": 477, + "weight": 513, "cookies": false, "type": "", "demo": "sites\/update-site-deployment.md", @@ -23303,7 +26220,7 @@ "x-appwrite": { "method": "listDeployments", "group": "deployments", - "weight": 476, + "weight": 512, "cookies": false, "type": "", "demo": "sites\/list-deployments.md", @@ -23394,7 +26311,7 @@ "x-appwrite": { "method": "createDeployment", "group": "deployments", - "weight": 472, + "weight": 508, "cookies": false, "type": "upload", "demo": "sites\/create-deployment.md", @@ -23496,7 +26413,7 @@ "x-appwrite": { "method": "createDuplicateDeployment", "group": "deployments", - "weight": 480, + "weight": 516, "cookies": false, "type": "", "demo": "sites\/create-duplicate-deployment.md", @@ -23577,7 +26494,7 @@ "x-appwrite": { "method": "createTemplateDeployment", "group": "deployments", - "weight": 473, + "weight": 509, "cookies": false, "type": "", "demo": "sites\/create-template-deployment.md", @@ -23699,7 +26616,7 @@ "x-appwrite": { "method": "createVcsDeployment", "group": "deployments", - "weight": 474, + "weight": 510, "cookies": false, "type": "", "demo": "sites\/create-vcs-deployment.md", @@ -23798,7 +26715,7 @@ "x-appwrite": { "method": "getDeployment", "group": "deployments", - "weight": 475, + "weight": 511, "cookies": false, "type": "", "demo": "sites\/get-deployment.md", @@ -23862,7 +26779,7 @@ "x-appwrite": { "method": "deleteDeployment", "group": "deployments", - "weight": 478, + "weight": 514, "cookies": false, "type": "", "demo": "sites\/delete-deployment.md", @@ -23931,7 +26848,7 @@ "x-appwrite": { "method": "getDeploymentDownload", "group": "deployments", - "weight": 479, + "weight": 515, "cookies": false, "type": "location", "demo": "sites\/get-deployment-download.md", @@ -24018,7 +26935,7 @@ "x-appwrite": { "method": "updateDeploymentStatus", "group": "deployments", - "weight": 481, + "weight": 517, "cookies": false, "type": "", "demo": "sites\/update-deployment-status.md", @@ -24087,7 +27004,7 @@ "x-appwrite": { "method": "listLogs", "group": "logs", - "weight": 483, + "weight": 519, "cookies": false, "type": "", "demo": "sites\/list-logs.md", @@ -24169,7 +27086,7 @@ "x-appwrite": { "method": "getLog", "group": "logs", - "weight": 482, + "weight": 518, "cookies": false, "type": "", "demo": "sites\/get-log.md", @@ -24235,7 +27152,7 @@ "x-appwrite": { "method": "deleteLog", "group": "logs", - "weight": 484, + "weight": 520, "cookies": false, "type": "", "demo": "sites\/delete-log.md", @@ -24304,7 +27221,7 @@ "x-appwrite": { "method": "listVariables", "group": "variables", - "weight": 487, + "weight": 523, "cookies": false, "type": "", "demo": "sites\/list-variables.md", @@ -24365,7 +27282,7 @@ "x-appwrite": { "method": "createVariable", "group": "variables", - "weight": 485, + "weight": 521, "cookies": false, "type": "", "demo": "sites\/create-variable.md", @@ -24457,7 +27374,7 @@ "x-appwrite": { "method": "getVariable", "group": "variables", - "weight": 486, + "weight": 522, "cookies": false, "type": "", "demo": "sites\/get-variable.md", @@ -24526,7 +27443,7 @@ "x-appwrite": { "method": "updateVariable", "group": "variables", - "weight": 488, + "weight": 524, "cookies": false, "type": "", "demo": "sites\/update-variable.md", @@ -24622,7 +27539,7 @@ "x-appwrite": { "method": "deleteVariable", "group": "variables", - "weight": 489, + "weight": 525, "cookies": false, "type": "", "demo": "sites\/delete-variable.md", @@ -24691,7 +27608,7 @@ "x-appwrite": { "method": "listBuckets", "group": "buckets", - "weight": 521, + "weight": 557, "cookies": false, "type": "", "demo": "storage\/list-buckets.md", @@ -24775,7 +27692,7 @@ "x-appwrite": { "method": "createBucket", "group": "buckets", - "weight": 519, + "weight": 555, "cookies": false, "type": "", "demo": "storage\/create-bucket.md", @@ -24922,7 +27839,7 @@ "x-appwrite": { "method": "getBucket", "group": "buckets", - "weight": 520, + "weight": 556, "cookies": false, "type": "", "demo": "storage\/get-bucket.md", @@ -24984,7 +27901,7 @@ "x-appwrite": { "method": "updateBucket", "group": "buckets", - "weight": 522, + "weight": 558, "cookies": false, "type": "", "demo": "storage\/update-bucket.md", @@ -25127,7 +28044,7 @@ "x-appwrite": { "method": "deleteBucket", "group": "buckets", - "weight": 523, + "weight": 559, "cookies": false, "type": "", "demo": "storage\/delete-bucket.md", @@ -25189,7 +28106,7 @@ "x-appwrite": { "method": "listFiles", "group": "files", - "weight": 526, + "weight": 562, "cookies": false, "type": "", "demo": "storage\/list-files.md", @@ -25284,7 +28201,7 @@ "x-appwrite": { "method": "createFile", "group": "files", - "weight": 524, + "weight": 560, "cookies": false, "type": "upload", "demo": "storage\/create-file.md", @@ -25377,7 +28294,7 @@ "x-appwrite": { "method": "getFile", "group": "files", - "weight": 525, + "weight": 561, "cookies": false, "type": "", "demo": "storage\/get-file.md", @@ -25450,7 +28367,7 @@ "x-appwrite": { "method": "updateFile", "group": "files", - "weight": 527, + "weight": 563, "cookies": false, "type": "", "demo": "storage\/update-file.md", @@ -25543,7 +28460,7 @@ "x-appwrite": { "method": "deleteFile", "group": "files", - "weight": 528, + "weight": 564, "cookies": false, "type": "", "demo": "storage\/delete-file.md", @@ -25616,7 +28533,7 @@ "x-appwrite": { "method": "getFileDownload", "group": "files", - "weight": 530, + "weight": 566, "cookies": false, "type": "location", "demo": "storage\/get-file-download.md", @@ -25698,7 +28615,7 @@ "x-appwrite": { "method": "getFilePreview", "group": "files", - "weight": 529, + "weight": 565, "cookies": false, "type": "location", "demo": "storage\/get-file-preview.md", @@ -25908,7 +28825,7 @@ "x-appwrite": { "method": "getFileView", "group": "files", - "weight": 531, + "weight": 567, "cookies": false, "type": "location", "demo": "storage\/get-file-view.md", @@ -33457,7 +36374,7 @@ "x-appwrite": { "method": "list", "group": "files", - "weight": 516, + "weight": 552, "cookies": false, "type": "", "demo": "tokens\/list.md", @@ -33547,7 +36464,7 @@ "x-appwrite": { "method": "createFileToken", "group": "files", - "weight": 514, + "weight": 550, "cookies": false, "type": "", "demo": "tokens\/create-file-token.md", @@ -33632,7 +36549,7 @@ "x-appwrite": { "method": "get", "group": "tokens", - "weight": 515, + "weight": 551, "cookies": false, "type": "", "demo": "tokens\/get.md", @@ -33693,7 +36610,7 @@ "x-appwrite": { "method": "update", "group": "tokens", - "weight": 517, + "weight": 553, "cookies": false, "type": "", "demo": "tokens\/update.md", @@ -33765,7 +36682,7 @@ "x-appwrite": { "method": "delete", "group": "tokens", - "weight": 518, + "weight": 554, "cookies": false, "type": "", "demo": "tokens\/delete.md", @@ -38729,7 +41646,8 @@ "x-example": "legacy", "enum": [ "legacy", - "tablesdb" + "tablesdb", + "documentsdb" ] } },