API reference / Tasks and projects
Edit an engineering ticket's analysis or plan
Rewrites the analysis or the plan of an engineering ticket (flow in GET /tasks/{key}), in markdown. Send the version you read; if it changed since, this answers 409 stale_version. The old text stays in its history. An approved plan and its analysis are locked: move the ticket back to plan to change them. While the Engineer works on the ticket, wait until it finishes.
/api/v1/tasks/{key}/docs/{doc}Other ways to call it
troopy tasks doctroopy_update_task_docIdempotency-Key header. A retry with the same key gets the first answer back, and the operation runs one time.Path parameters
key*stringA task's key (VIR-12), its number (12) or its id
At least 1 characters · At most 40 characters
doc*enum<string>analysisplan
Body
application/jsonversion*integerThe version you read
At least 0
body*stringThe whole document, in markdown. An analysis keeps its checks under a Done when heading
At most 30000 characters
Response
200 · application/jsondata*object8 properties
kind*enum<string>analysisplan
version*integerSend it back with an edit, or with the approval of a plan
body*stringMarkdown
criteria*array<string>An analysis: its Done when checks, in order. The QA tester checks them one by one as c1, c2, ...
approved*object | nullA plan: the version a person approved
3 properties
version*integerby*objectWho wrote it
3 properties
type*enum<string>personagentapi
id*stringname*stringat*stringISO 8601 date and time
locked*booleanApproved plans and their analyses are locked; moving the ticket back to Plan unlocks them
updatedBy*objectWho wrote it
3 properties
type*enum<string>personagentapi
id*stringname*stringupdatedAt*stringISO 8601 date and time