Read and write rows
Select, insert, update, upsert and delete rows.
/database/v1/databases/{database_id}/rest/{table}
Reads and writes the same rows as the other entry point for this database. Errors use PostgREST codes.
Support matrix and client setup
Full parameters, response headers and status codes
One batch POST inserts at most 500 rows. Each request is atomic: a failure in any row rolls back the entire batch. There are no transactions across requests. Put rows that must succeed together in one batch POST. For links, query first, then insert, and handle link errors caused by concurrent changes.
Rows in a batch are filled to the union of their keys with null (PostgREST behavior). Send Prefer: missing=default to use field defaults instead. Explicit null remains null; required fields without defaults must still be provided. The default return=minimal returns 201 with an empty body; send Prefer: return=representation to return rows.
Select rows
GET /database/v1/databases/{database_id}/rest/{table}
curl -X GET "https://api.deepraxis.ai/database/v1/databases/${DATABASE_ID}/rest/tasks?select=*&order=title.asc&limit=10" \
-H "Authorization: Bearer $PRAXIS_API_KEY"Response
HTTP 200
Success; write bodies require Prefer: return=representation
application/json
| Name | Type | Description |
|---|---|---|
| [].id | string | Row identifier of 1–64 characters from A-Z a-z 0-9 _ -. Generated by the service unless the insert supplied one; it cannot be changed by updates. |
application/vnd.pgrst.object+json
| Name | Type | Description |
|---|---|---|
| id | string | Row identifier of 1–64 characters from A-Z a-z 0-9 _ -. Generated by the service unless the insert supplied one; it cannot be changed by updates. |
HTTP 206
Partial range with requested count
application/json
| Name | Type | Description |
|---|---|---|
| [].id | string | Row identifier of 1–64 characters from A-Z a-z 0-9 _ -. Generated by the service unless the insert supplied one; it cannot be changed by updates. |
application/vnd.pgrst.object+json
| Name | Type | Description |
|---|---|---|
| id | string | Row identifier of 1–64 characters from A-Z a-z 0-9 _ -. Generated by the service unless the insert supplied one; it cannot be changed by updates. |
Response example — HTTP 200
| Header | Value |
|---|---|
| content-range | 0-0/* |
| etag | W/"5.1" |
| range-unit | items |
[
{
"id": "rec_3e85a292099340e3",
"version": 1,
"created_at": "2026-10-11T17:41:47.896Z",
"updated_at": "2026-10-11T17:41:47.896Z",
"title": "Write a summary",
"done": false
}
]Count rows
HEAD /database/v1/databases/{database_id}/rest/{table}
curl --head "https://api.deepraxis.ai/database/v1/databases/${DATABASE_ID}/rest/tasks?select=*" \
-H "Authorization: Bearer $PRAXIS_API_KEY" \
-H 'prefer: count=exact'Response
HTTP 200
Success; write bodies require Prefer: return=representation
No response body is declared.
HTTP 206
Partial range with requested count
No response body is declared.
Response example — HTTP 200
| Header | Value |
|---|---|
| content-range | 0-0/1 |
| preference-applied | count=exact |
| etag | W/"5.1" |
| range-unit | items |
No response body.
Insert rows
POST /database/v1/databases/{database_id}/rest/{table}
curl -X POST "https://api.deepraxis.ai/database/v1/databases/${DATABASE_ID}/rest/tasks" \
-H "Authorization: Bearer $PRAXIS_API_KEY" \
-H 'prefer: return=representation' \
-H "Content-Type: application/json" \
-d '{"title":"Write a summary","done":false}'Response
HTTP 201
Success (201). With the default return=minimal the body is empty; Prefer: return=representation returns rows.
application/json
| Name | Type | Description |
|---|---|---|
| [].id | string | Row identifier of 1–64 characters from A-Z a-z 0-9 _ -. Generated by the service unless the insert supplied one; it cannot be changed by updates. |
application/vnd.pgrst.object+json
| Name | Type | Description |
|---|---|---|
| id | string | Row identifier of 1–64 characters from A-Z a-z 0-9 _ -. Generated by the service unless the insert supplied one; it cannot be changed by updates. |
Response example — HTTP 201
| Header | Value |
|---|---|
| content-range | 0-0/* |
| preference-applied | return=representation |
| range-unit | items |
[
{
"id": "rec_3e85a292099340e3",
"version": 1,
"created_at": "2026-10-11T17:41:47.896Z",
"updated_at": "2026-10-11T17:41:47.896Z",
"title": "Write a summary",
"done": false
}
]Update rows
PATCH /database/v1/databases/{database_id}/rest/{table}
curl -X PATCH "https://api.deepraxis.ai/database/v1/databases/${DATABASE_ID}/rest/tasks?title=eq.Write%20a%20summary" \
-H "Authorization: Bearer $PRAXIS_API_KEY" \
-H 'prefer: return=representation' \
-H "Content-Type: application/json" \
-d '{"done":true}'Response
HTTP 200
Success; write bodies require Prefer: return=representation
application/json
| Name | Type | Description |
|---|---|---|
| [].id | string | Row identifier of 1–64 characters from A-Z a-z 0-9 _ -. Generated by the service unless the insert supplied one; it cannot be changed by updates. |
application/vnd.pgrst.object+json
| Name | Type | Description |
|---|---|---|
| id | string | Row identifier of 1–64 characters from A-Z a-z 0-9 _ -. Generated by the service unless the insert supplied one; it cannot be changed by updates. |
HTTP 204
Success without a body
No response body is declared.
Response example — HTTP 200
| Header | Value |
|---|---|
| content-range | 0-0/* |
| preference-applied | return=representation |
| range-unit | items |
[
{
"id": "rec_3e85a292099340e3",
"version": 2,
"created_at": "2026-10-11T17:41:47.896Z",
"updated_at": "2026-10-11T17:41:48.802Z",
"title": "Write a summary",
"done": true
}
]Upsert rows
POST /database/v1/databases/{database_id}/rest/{table}
curl -X POST "https://api.deepraxis.ai/database/v1/databases/${DATABASE_ID}/rest/tasks?on_conflict=title" \
-H "Authorization: Bearer $PRAXIS_API_KEY" \
-H 'prefer: resolution=merge-duplicates,return=representation' \
-H "Content-Type: application/json" \
-d '{"title":"Write a summary","done":true}'Response
HTTP 201
Success (201). With the default return=minimal the body is empty; Prefer: return=representation returns rows.
application/json
| Name | Type | Description |
|---|---|---|
| [].id | string | Row identifier of 1–64 characters from A-Z a-z 0-9 _ -. Generated by the service unless the insert supplied one; it cannot be changed by updates. |
application/vnd.pgrst.object+json
| Name | Type | Description |
|---|---|---|
| id | string | Row identifier of 1–64 characters from A-Z a-z 0-9 _ -. Generated by the service unless the insert supplied one; it cannot be changed by updates. |
Response example — HTTP 201
| Header | Value |
|---|---|
| content-range | 0-0/* |
| preference-applied | resolution=merge-duplicates, return=representation |
| range-unit | items |
[
{
"id": "rec_3e85a292099340e3",
"version": 3,
"created_at": "2026-10-11T17:41:47.896Z",
"updated_at": "2026-10-11T17:41:49.076Z",
"title": "Write a summary",
"done": true
}
]Delete rows
DELETE /database/v1/databases/{database_id}/rest/{table}
curl -X DELETE "https://api.deepraxis.ai/database/v1/databases/${DATABASE_ID}/rest/tasks?title=eq.Write%20a%20summary" \
-H "Authorization: Bearer $PRAXIS_API_KEY" \
-H 'prefer: return=representation'Response
HTTP 200
Success; write bodies require Prefer: return=representation
application/json
| Name | Type | Description |
|---|---|---|
| [].id | string | Row identifier of 1–64 characters from A-Z a-z 0-9 _ -. Generated by the service unless the insert supplied one; it cannot be changed by updates. |
application/vnd.pgrst.object+json
| Name | Type | Description |
|---|---|---|
| id | string | Row identifier of 1–64 characters from A-Z a-z 0-9 _ -. Generated by the service unless the insert supplied one; it cannot be changed by updates. |
HTTP 204
Success without a body
No response body is declared.
Response example — HTTP 200
| Header | Value |
|---|---|
| content-range | 0-0/* |
| preference-applied | return=representation |
| range-unit | items |
[
{
"id": "rec_3e85a292099340e3",
"version": 3,
"created_at": "2026-10-11T17:41:47.896Z",
"updated_at": "2026-10-11T17:41:49.076Z",
"title": "Write a summary",
"done": true
}
]Row
Default projections, select=, return=representation and RPC row objects return only id and user fields. Explicitly request metadata with select=,_version,_created_at,_updated_at; star does not expand it. Filter with _version=eq.3 or sort with order=_created_at.desc. Metadata is read-only. Default order remains internal creation time then id. Old filter/order names created_at/updated_at/version without same-named user fields return 400, details use _created_at (or the corresponding name), and hint system metadata moved to underscore columns. Existing underscore user fields take precedence; their same-named system metadata is inaccessible in that table. Historical response examples above were captured before this change and may still contain old metadata columns; this section defines the current row shape.
| Field | Type | Required | Description |
|---|---|---|---|
| id | string | yes | Row identifier of 1–64 characters from A-Z a-z 0-9 _ -. Generated by the service unless the insert supplied one; it cannot be changed by updates.; ^[A-Za-z0-9_-]{1,64}$ |