Skip to content
Helicarrier Developers

Edit database record

Update one database record with optimistic concurrency protection. First read get_database_rows and check editing support. Send the exact original snapshot, plus SQL values (strings or null) or a MongoDB/Qdrant document. A conflict returns 409; re-read and ask before retrying changed data.

POST /api/services/{id}/db/record HTTPS
Request & response examples
Request example Server-side
curl --fail-with-body --request POST \
'https://app.helicarrier.xyz/api/services/YOUR_ID/db/record' \
-H "Authorization: Bearer $HELI_API_KEY" \
-H 'Content-Type: application/json' \
--data '{
"name": "my-service",
"original": "YOUR_ORIGINAL"
}'
Response example 200
{
"saved": true
}

Illustrative values · selected fields

Authorization

An account-wide write key with access to the database. Read-only, project and service keys cannot access database contents.

Authorization: Bearer <key> Key setup

Path parameters

id string required

Service ID.

Request body

database string optional

Database name.

group string optional

Schema or collection group.

name string required

Table or collection.

original string required

Exact opaque original snapshot from get_database_rows; never fabricate it.

values object (string or null values) optional

SQL field values as strings or null; strings preserve numeric precision.

document object optional

Replacement document for engines using document edits.

Response 200

Update one database record with optimistic concurrency protection. First read get_database_rows and check editing support. Send the exact original snapshot, plus SQL values (strings or null) or a MongoDB/Qdrant document. A conflict returns 409; re-read and ask before retrying changed data.

Examples show selected response fields with illustrative values. Your response can contain additional fields.

saved boolean

Errors

400

Invalid parameters. Check the required fields, types, and resource configuration.

401

The API key is missing, invalid, or revoked.

403

The caller or key scope does not permit this operation.

409

The current resource state prevents the operation. Inspect it before retrying.

Error handling and safe retries
ALSO AVAILABLE VIA MCP

edit_database_record

Required MCP arguments: id, name, original. Send path, query, and body fields together as tool arguments.

Connect your agent