Get or seed instructions
Fetches the active instructions, creating them first when none exist. Call this at the start of an automation run: if the doc is missing and `default` is provided, the default becomes version 1 (`source: seed`) and is returned - so a shipped template works with zero setup. When the doc exists, `default` is ignored and the stored text always wins.
Authorization
webhookToken Workspace webhook token from Settings -> Integrations.
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/api/instructions" \ -H "Content-Type: application/json" \ -d '{ "project": "string", "task": "string" }'{ "content": "string", "version": 0, "updatedAt": "2019-08-24T14:15:22Z"}{ "content": "string", "version": 0, "updatedAt": "2019-08-24T14:15:22Z"}{ "error": "string", "code": "string", "fields": { "property1": "string", "property2": "string" }}{ "error": "string", "code": "string", "fields": { "property1": "string", "property2": "string" }}Get the active instructions GET
Returns the active hosted-instructions text for a project and task. Without `project`/`task` query parameters it lists the workspace's instruction docs instead.
List instruction versions GET
Full version history for a project and task, newest first, including each version's text and what caused it.