Update stored values for a form instance
Merges the provided values into the instance (see request body schema). Keys in values must match fields[].valueKey from GET /tasks/{identifier}/form-instances for this instance. For allowed types and select options, either read fields on that GET response or load the template definition with GET /workspace/form-templates/{templateId} using the instance templateId.
PATCH
/tasks/{identifier}/form-instances/{formInstanceId}Authorization
AuthorizationOAuth2 access token · headerrequiredScopes:
api:writeor
AuthorizationBearer token (JWT) · headerrequiredPath parameters
identifierstringrequiredTask UUID or shortNumber
formInstanceIdstring<uuid>requiredForm instance UUID from GET `/tasks/{identifier}/form-instances` (`id` on each item).
Query parameters
fieldsToReturnstringComma-separated list of top-level response fields to return. Overrides the endpoint compact default unless responseShape=full is used.
responseShapestringAdvanced override. Omit for the endpoint compact default. Use full only when you need the complete endpoint response, including nested fields that are not selectable with fieldsToReturn.
Allowed:
compactfullHeader parameters
LT-Response-ShapestringAdvanced override. Set to full only when you need the complete endpoint response, including nested fields that are not selectable with fieldsToReturn.
Allowed:
fullRequest body
requiredapplication/jsonvaluesobjectrequiredMap of field keys to submitted values. Each key must match the `valueKey` of a field on this instance (see GET `/tasks/{identifier}/form-instances` → `fields[].valueKey`). `valueKey` is the template field `key` when set, otherwise the field UUID. To learn types, required flags, and allowed options before editing, use GET `/workspace/form-templates/{templateId}` (use `templateId` from the instance) or read `fields` from the list response.
Responses
200
401Unauthorized - Invalid or missing authentication token
403Forbidden - Insufficient API scopes or permissions
Request
curl -X PATCH "https://leadtime.app/api/public/tasks/string/form-instances/%3Cuuid%3E" \
-H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"values": {}
}'const response = await fetch("https://leadtime.app/api/public/tasks/string/form-instances/%3Cuuid%3E", {
method: "PATCH",
headers: {
"Authorization": "Bearer YOUR_ACCESS_TOKEN",
"Content-Type": "application/json"
},
body: JSON.stringify({
"values": {}
})
});import requests
response = requests.patch(
"https://leadtime.app/api/public/tasks/string/form-instances/%3Cuuid%3E",
headers={
"Authorization": "Bearer YOUR_ACCESS_TOKEN",
"Content-Type": "application/json"
},
json={
"values": {}
},
)Response
No example response.
Unauthorized - Invalid or missing authentication token
Forbidden - Insufficient API scopes or permissions