https://appwrite.io/v1/database/collections/{collectionId}/documents/{documentId}Update a document by its unique ID. Using the patch method you can pass only specific fields that will get updated.
Collection unique ID. You can create a new collection with validation rules using the Database service [server integration](/docs/server/database#createCollection).
Document unique ID.
Document data as JSON object.
An array of strings with read permissions. By default inherits the existing read permissions. [learn more about permissions](/docs/permissions) and get a full list of available permissions.
An array of strings with write permissions. By default inherits the existing write permissions. [learn more about permissions](/docs/permissions) and get a full list of available permissions.
{
"success": true,
"data": {
"id": "abc123",
"created_at": "2025-01-01T00:00:00Z"
}
}{
"success": false,
"error": {
"code": "VALIDATION_ERROR",
"message": "Invalid request parameters"
}
}curl --request PATCH \
--url 'https://appwrite.io/v1/database/collections/{collectionId}/documents/{documentId}' \
--header 'accept: application/json' \
--header 'content-type: application/json'{
"success": true,
"data": {
"id": "abc123",
"created_at": "2025-01-01T00:00:00Z"
}
}https://appwrite.io/v1/database/collections/{collectionId}/documents/{documentId}Update a document by its unique ID. Using the patch method you can pass only specific fields that will get updated.
Collection unique ID. You can create a new collection with validation rules using the Database service [server integration](/docs/server/database#createCollection).
Document unique ID.
Document data as JSON object.
An array of strings with read permissions. By default inherits the existing read permissions. [learn more about permissions](/docs/permissions) and get a full list of available permissions.
An array of strings with write permissions. By default inherits the existing write permissions. [learn more about permissions](/docs/permissions) and get a full list of available permissions.
{
"success": true,
"data": {
"id": "abc123",
"created_at": "2025-01-01T00:00:00Z"
}
}{
"success": false,
"error": {
"code": "VALIDATION_ERROR",
"message": "Invalid request parameters"
}
}curl --request PATCH \
--url 'https://appwrite.io/v1/database/collections/{collectionId}/documents/{documentId}' \
--header 'accept: application/json' \
--header 'content-type: application/json'{
"success": true,
"data": {
"id": "abc123",
"created_at": "2025-01-01T00:00:00Z"
}
}