Agent instructions
Agent instructions teach a team's agents how to write tickets and plans: templates, writing guidance and, for tickets, default values. A workspace and each team can set their own; a team's replace the workspace's, which replace Clanker Ship's defaults.
The AgentInstructions object
The instructions of one kind that a team's agents follow, and where they come from.
Attributes
kindstringRequiredWhat the instructions shape: ticket for a ticket's summary, plan for its plan, test-cases for test cases, test-code for specs, fixtures for a product's Fixture API and test-ci for the CI that runs tests.
ticketplantest-casestest-codefixturestest-cisourcestringRequiredWhere these come from: the team's own (team), the workspace's (workspace) or Clanker Ship's defaults (default).
teamworkspacedefaultteamnullable objectRequiredThe team asked about, or null for the workspace's instructions.
templatesarray of objectsRequiredOne template for every ticket, and at most one more per tag.
guidancestringRequiredHow the agent should write, in Markdown.
defaultsnullable objectRequiredWhat new tickets from agents get; null for plan instructions.
updatedAtnullable stringRequiredWhen these were last set, as an ISO 8601 timestamp; null for Clanker Ship's defaults.
updatedBynullable objectRequiredWho last set these; null for Clanker Ship's defaults or when an account API key set them.
{ "kind": "ticket", "source": "team", "team": { "id": "Tm6PzN3kWq1J", "key": "WEB", "name": "Web" }, "templates": [ { "tag": null, "body": "## Problem\nWhat is wrong or missing, and for whom.\n\n## Outcome\nWhat is true when this ticket is done." }, { "tag": "bug", "body": "## Steps to reproduce\n\n## Expected\n\n## Actual" } ], "guidance": "- Keep the title short: what changes, and where.\n- Use the team's tags. Do not invent new ones.", "defaults": { "status": "Todo", "tags": [], "owner": "creator" }, "updatedAt": "2026-10-14T09:05:12.000Z", "updatedBy": { "person": { "id": "Us3NfP8kLq2V", "name": "Maya Patel", "email": "maya@acme.dev" }, "agent": null }}Get agent instructions
GET/Returns the instructions a team's agents follow: the team's own, else the workspace's, else Clanker Ship's defaults. Without team, returns the workspace's or Clanker Ship's. source says which.
Path parameters
slugstringRequiredThe workspace's slug or ID, such as acme.
Query parameters
kindstringRequiredWhat the instructions shape: ticket for a ticket's summary, plan for its plan, test-cases for test cases, test-code for specs, fixtures for a product's Fixture API and test-ci for the CI that runs tests.
ticketplantest-casestest-codefixturestest-citeamstringA team's key, such as WEB. Leave it out for the workspace's instructions.
Returns
Returns the AgentInstructions object. Status 200.
Errors
- 400
InvalidInputThe request is malformed, or a value is not allowed.- 401
UnauthorizedThe request has no valid API key.- 403
ForbiddenThe key's user or role may not do this.- 404
NotFoundThe workspace or object does not exist, or the caller cannot see it.- 409
ConflictThe change conflicts with current data, such as a slug that is already in use.- 500
InternalClanker Ship failed to handle the request. Retry, or report the response's x-request-id.
curl "https://api.qa.clankership.net/v1/workspaces/acme/agent-instructions?kind=ticket" \ -H "Authorization: Bearer $CLANKER_API_KEY"{ "kind": "ticket", "source": "team", "team": { "id": "Tm6PzN3kWq1J", "key": "WEB", "name": "Web" }, "templates": [ { "tag": null, "body": "## Problem\nWhat is wrong or missing, and for whom.\n\n## Outcome\nWhat is true when this ticket is done." }, { "tag": "bug", "body": "## Steps to reproduce\n\n## Expected\n\n## Actual" } ], "guidance": "- Keep the title short: what changes, and where.\n- Use the team's tags. Do not invent new ones.", "defaults": { "status": "Todo", "tags": [], "owner": "creator" }, "updatedAt": "2026-10-14T09:05:12.000Z", "updatedBy": { "person": { "id": "Us3NfP8kLq2V", "name": "Maya Patel", "email": "maya@acme.dev" }, "agent": null }}Set agent instructions
PUT/Sets the workspace's or a team's own instructions. Fields left out keep their current values, so a team's first change copies what it inherits. Owners and admins set the workspace's, and a team's members also set the team's; viewers cannot. Only ticket instructions take defaults.
Path parameters
slugstringRequiredThe workspace's slug or ID, such as acme.
Body parameters
kindstringRequiredWhat the instructions shape: ticket for a ticket's summary, plan for its plan, test-cases for test cases, test-code for specs, fixtures for a product's Fixture API and test-ci for the CI that runs tests.
ticketplantest-casestest-codefixturestest-citeamnullable stringA team's key, such as WEB. Leave it out for the workspace's instructions.
templatesarray of objectsReplaces the templates: exactly one without a tag, and at most one more per tag, up to 20 in all.
guidancestringHow the agent should write, in Markdown, up to 20,000 characters.
defaultsobjectWhat a ticket an agent creates gets for each of these fields the agent leaves out.
Returns
Returns the AgentInstructions object. Status 200.
Errors
- 400
InvalidInputThe request is malformed, or a value is not allowed.- 401
UnauthorizedThe request has no valid API key.- 403
ForbiddenThe key's user or role may not do this.- 404
NotFoundThe workspace or object does not exist, or the caller cannot see it.- 409
ConflictThe change conflicts with current data, such as a slug that is already in use.- 500
InternalClanker Ship failed to handle the request. Retry, or report the response's x-request-id.
curl -X PUT https://api.qa.clankership.net/v1/workspaces/acme/agent-instructions \ -H "Authorization: Bearer $CLANKER_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "kind": "ticket", "team": "WEB", "templates": [ { "tag": null, "body": "## Problem\nWhat is wrong or missing, and for whom.\n\n## Outcome\nWhat is true when this ticket is done." }, { "tag": "bug", "body": "## Steps to reproduce\n\n## Expected\n\n## Actual" } ], "defaults": { "status": "Todo", "tags": [], "owner": "creator" } }'{ "kind": "ticket", "source": "team", "team": { "id": "Tm6PzN3kWq1J", "key": "WEB", "name": "Web" }, "templates": [ { "tag": null, "body": "## Problem\nWhat is wrong or missing, and for whom.\n\n## Outcome\nWhat is true when this ticket is done." }, { "tag": "bug", "body": "## Steps to reproduce\n\n## Expected\n\n## Actual" } ], "guidance": "- Keep the title short: what changes, and where.\n- Use the team's tags. Do not invent new ones.", "defaults": { "status": "Todo", "tags": [], "owner": "creator" }, "updatedAt": "2026-10-14T09:05:12.000Z", "updatedBy": { "person": { "id": "Us3NfP8kLq2V", "name": "Maya Patel", "email": "maya@acme.dev" }, "agent": null }}Reset agent instructions
DELETE/Removes the workspace's or a team's own instructions, so it follows what it inherits again, and returns the instructions that now apply. The people who can set the instructions can reset them.
Path parameters
slugstringRequiredThe workspace's slug or ID, such as acme.
Query parameters
kindstringRequiredWhat the instructions shape: ticket for a ticket's summary, plan for its plan, test-cases for test cases, test-code for specs, fixtures for a product's Fixture API and test-ci for the CI that runs tests.
ticketplantest-casestest-codefixturestest-citeamstringA team's key, such as WEB. Leave it out for the workspace's instructions.
Returns
Returns the AgentInstructions object. Status 200.
Errors
- 400
InvalidInputThe request is malformed, or a value is not allowed.- 401
UnauthorizedThe request has no valid API key.- 403
ForbiddenThe key's user or role may not do this.- 404
NotFoundThe workspace or object does not exist, or the caller cannot see it.- 409
ConflictThe change conflicts with current data, such as a slug that is already in use.- 500
InternalClanker Ship failed to handle the request. Retry, or report the response's x-request-id.
curl -X DELETE "https://api.qa.clankership.net/v1/workspaces/acme/agent-instructions?kind=ticket" \ -H "Authorization: Bearer $CLANKER_API_KEY"{ "kind": "ticket", "source": "team", "team": { "id": "Tm6PzN3kWq1J", "key": "WEB", "name": "Web" }, "templates": [ { "tag": null, "body": "## Problem\nWhat is wrong or missing, and for whom.\n\n## Outcome\nWhat is true when this ticket is done." }, { "tag": "bug", "body": "## Steps to reproduce\n\n## Expected\n\n## Actual" } ], "guidance": "- Keep the title short: what changes, and where.\n- Use the team's tags. Do not invent new ones.", "defaults": { "status": "Todo", "tags": [], "owner": "creator" }, "updatedAt": "2026-10-14T09:05:12.000Z", "updatedBy": { "person": { "id": "Us3NfP8kLq2V", "name": "Maya Patel", "email": "maya@acme.dev" }, "agent": null }}