Update multiple FORM subfields by key in one request
Update several FORM subfield values by key in a single atomic request. Only DRAFT documents can have fields updated.
Use this instead of looping single-key PATCH .../fields/key:<key> calls. Because all FORM subfields share one underlying field row, concurrent single-key requests read-modify-write the same row and overwrite each other (lost updates). This endpoint applies all changes against one read per affected field, so nothing is clobbered.
Body:
PATCH /api/v1/documents/{docId}/fields
{
"updates": [
{ "key": "name", "fieldMeta": { "type": "input", "value": "Andreas" } },
{ "key": "phone", "fieldMeta": { "type": "input", "value": "070-1234567" } },
{ "key": "email", "fieldMeta": { "type": "input", "value": "[email protected]" } }
]
}
Each entry’s fieldMeta is merged into the existing subfield metadata (preserving label, placeholder, description, etc.), identical to the single-key endpoint. Max 50 updates per request.
Response: Returns a per-key result array so partial failures (e.g. an unknown key) are reported individually while valid updates still apply. success is true only when every update succeeded.
Authorizations
Personal API key, e.g. Authorization: Bearer sajn_sk_.... Not scope-limited — acts as the issuing user.
Headers
Bearer token for API authentication
Makes retries safe. A retry with the same key and the same request replays the stored response for 24 hours (header Idempotent-Replayed: true); the same key with a different request returns 400.
255Path Parameters
Body
Body
Array of field updates (max 50)
1 - 50 elements
