xPlantAPI
API referenceTasks and demand

Update a task

Changes only the fields you send. Move a task along the board with workflow_status; complete it with "done".

PATCH/api/v1/tasks/{id}
Scope write:tasks

A task someone placed by hand keeps its position through automated writes. Send release: true to hand it back to automatic ordering. Send clear_entity_link: true to unlink it from its plant or explant.

See also: Sync tasks.

Path parameters

NameTypeRequiredDescription
idstring (uuid)YesThe record's id.

Request body

FieldTypeRequiredDescription
titlestringNo1–300 characters.
due_datestring (date-time)No—
is_all_daybooleanNo—
category"media_prep" | "transfer" | "contamination" | "subculture" | "sop_review" | "acclimation" | "cleaning" | "monitoring" | "other"No—
notesstringNoUp to 5000 characters.
priority"low" | "medium" | "high" | "urgent"No—
priority_ranknumber | nullNo—
releasebooleanNo—
workflow_status"backlog" | "todo" | "in_progress" | "waiting_blocked" | "review" | "done"No—
assigned_tostring (uuid)No—
genusstring | nullNo1–100 characters.
entity_type"plant" | "explant"No—
entity_idstring (uuid)No—
clear_entity_linkbooleanNo—

Example

curl -X PATCH https://app.xplantpro.com/api/v1/tasks/4e9a1c7b-2d3f-4b5a-9c8d-6e7f8a9b0c1d \
  -H "Authorization: Bearer $XPLANT_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "workflow_status": "done"
  }'

Response

200 with { "ok": true, "data": … }. data holds the result.

FieldTypeRequiredDescription
idstring (uuid)Yes—
titlestringYes—
statusstringYesBoard column: backlog, todo, in_progress, waiting_blocked, review, done.
due_datestring | nullYesISO 8601 timestamp.
assigned_tostring | nullYesUser id of the workspace member the task is assigned to.
prioritystring | nullYes—
priority_ranknumber | nullYesQueue position. Lower sorts first; null means the priority label decides.
priority_sourcestringYesWhere the current order came from: default, auto, manual. manual means a person placed the task, and automated writes leave it where it is unless they send release: true.
categorystring | nullYes—
created_atstring | nullYes—
entity_linkobject | nullNoThe plant or explant the task is about. Returned when you create, fetch or update one task; lists leave it out.
entity_link.entity_type"plant" | "explant"Yes—
entity_link.entity_idstring (uuid)Yes—
Response
{
  "ok": true,
  "data": {
    "id": "5b0f6f3e-2c1a-4d8e-9f47-0a6c3e1b7d22",
    "title": "Transfer the Alocasia line onto fresh medium",
    "status": "done",
    "due_date": "2026-10-02T09:00:00.000Z",
    "assigned_to": "0d7e4b9a-6f21-4c3e-8a5b-2e9f1c7d4a60",
    "priority": "high",
    "priority_rank": 1.5,
    "priority_source": "auto",
    "category": "transfer",
    "created_at": "2026-09-25T14:12:03.000Z",
    "entity_link": null
  }
}

The envelope can also carry meta:

FieldTypeRequiredDescription
priority_writeobjectYesSent when the update asked to change the task's order: whether it was applied, and why not if it was declined. Left out otherwise.
priority_write.appliedbooleanYesWhether the requested ordering change was written.
priority_write.reason"manual_override"NoPresent only when the change was declined.
priority_write.priority_source"default" | "auto" | "manual"YesWhere the order stands now.
priority_write.messagestringYesA plain-language explanation, safe to show in a sync log.
Response headerMeaning
X-Request-IdIdentifies this request. Include it when you contact support.

Errors

StatusCodeWhen
400VALIDATION_ERRORThe request body is not valid JSON.
401UNAUTHORIZEDThe key is missing, malformed or revoked, or its owner is no longer a member of the workspace.
402PAID_PLAN_REQUIREDThe workspace's plan does not include the API. The full API is included with xPlant+ Teams and Enterprise; on Hobby and Pro Lab, keys can connect devices only.
403FORBIDDENThe key lacks a scope this operation requires, or its owner's current role in the workspace cannot use it — a key never does more than its owner can in xPlant. error names the scope, and for a role, the role it needs.
403DEVICE_TOKEN_NOT_ACCEPTEDA device token was sent; this operation needs a workspace API key.
404NOT_FOUNDNo task with this id exists in the key's workspace, or id is not a well-formed id.
422VALIDATION_ERRORA field failed validation. error names the first one, for example title: title is required.
422VALIDATION_ERRORassigned_to is not an active member of the workspace, or the linked plant or explant is not in it.
429RATE_LIMIT_EXCEEDEDToo many requests for this key, device token or workspace. Wait Retry-After seconds.
500TASK_UPDATE_FAILEDThe change could not be saved. Retry later.

Branch on code, never on the error text. See Errors.

On this page