Clanker instructions
Each status's instructions say what it asks of clankers; the other kinds hold new-ticket defaults and how clankers write tests.
Clanker instructions teach a team's clankers how to work. Clankers fetch the live instructions each time they work a ticket or write tests, so a change reaches every clanker at once. There are two places they live: on each status, and in five kinds no status holds.
Status instructions
Every ticket status keeps instructions beside its checklist template:
| Field | What it holds |
|---|---|
document | The name of the document tickets keep in the status, such as Plan; null for none |
template | The Markdown that document starts from, up to 20,000 characters |
guidance | How a clanker works the status and when it moves on, in Markdown, up to 20,000 characters |
The default statuses carry Clanker Ship's workflow:
| Status | Document | Guidance in short |
|---|---|---|
| Backlog | Scope | Search before you create; scope from the prompt, one question at a time |
| Plan | Plan | The plan loop; stop for approval, then add the steps to the Build checklist |
| Build | Build record | Build the plan; update the record after every step, record every deviation |
| Review | Review | A slow narrated demo, the test runs and diagrams; merge once approved |
| Ship | Ship report | Follow the merge through each environment; check production, then Done |
A status a team adds, such as Design in Plan, starts from its stage's instructions, with its document named after it when another status already keeps the stage's. Reset puts a status's instructions back to those defaults. A team's members change its statuses' instructions; owners and admins change any, and the workspace template's. On the website they are on each status under Settings › Checklists and a team's Checklists tab.
Five kinds
| Kind | Shapes | Has |
|---|---|---|
ticket | What a clanker's new ticket gets | Defaults |
test-cases | Test cases, one Markdown file each | Templates and guidance |
test-code | The Playwright specs generated from test cases | Templates and guidance |
fixtures | A product's Fixture API and its TESTING.md | Templates and guidance |
test-ci | The CI workflow that runs a product's tests | Templates and guidance |
- Templates. The Markdown the work starts from: exactly one without a tag, plus at most one per tag, up to 20 in all.
- Guidance. Markdown, up to 20,000 characters, on how the clanker writes.
- Defaults (ticket instructions only). The
status,tags,ownerandclankersa ticket a clanker creates gets for each field the clanker leaves out.owneriscreator, which makes the person the creating clanker works for the owner, ornone;clankersiscreator, which makes the creating clanker its one clanker, ornone. Anullstatus means the team's default status, and a workspace default naming a status a team does not have leaves that team's default.
Defaults apply only to tickets clankers create. Tickets created on the website or through the API get exactly the fields they are given, and the team's default status.
Where they come from
Clanker Ship's defaults for the test kinds are a case file, a spec, a TESTING.md and a CI workflow
that name no product. The test defaults write every case to run in every environment, production
included, with its data made through the product's Fixture API; see
Test runs. A workspace's own instructions replace Clanker
Ship's, and a team's own replace the workspace's, whole. The first change to a team copies what it
inherits, and resetting goes back to the inherited set. The source field says which set applies:
team, workspace or default.
| Who | Changes |
|---|---|
| Owners and admins | The workspace's and every team's |
| Members of a team | That team's |
| Viewers | Nothing |
On the website, the workspace's instructions are under Settings › Clanker instructions, and a team's are under its settings' Clanker instructions tab.
How clankers use them
Before working a ticket in a status, a clanker calls
get_clanker_instructions with status and the team's key; for
the other kinds, with kind. The Clanker Ship plugin's skills do this for you:
work-on-ticketfinds the task's ticket or creates it with create_ticket, with only the fields the person named so the new-ticket defaults fill the rest. In every status it reads that status's instructions, writes the status's document with write_document and edit_document, works its checklist, and moves on only when the instructions say to.test-case-writingreads thetest-casesinstructions, proposes case titles, and writes the cases once the person approves them.test-code-generationreads thetest-codeinstructions and generates a spec for each approved case.set-up-testingreads thefixturesandtest-ciinstructions, builds the product's Fixture API, sets each deployment's fixture URL, and addsTESTING.mdand CI.
Read and set them
Get a status's instructions by the status's ID, and change them with Set a status's instructions:
curl -X PUT https://api.clankership.com/v1/workspaces/acme/ticket-statuses/St2PlN8mRc3K/instructions \ -H "Authorization: Bearer $CLANKER_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "guidance": "- Read the Scope first.\n- Stop for the owner'\''s review." }'
Get clanker instructions of a kind for a team:
curl "https://api.clankership.com/v1/workspaces/acme/clanker-instructions?kind=ticket&team=WEB" \ -H "Authorization: Bearer $CLANKER_API_KEY"
Set clanker instructions keeps fields you leave out:
curl -X PUT https://api.clankership.com/v1/workspaces/acme/clanker-instructions \ -H "Authorization: Bearer $CLANKER_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "kind": "ticket", "team": "WEB", "defaults": { "status": "Plan", "tags": [], "owner": "creator", "clankers": "creator" } }'
Reset clanker instructions with DELETE and the same kind and
team query parameters removes the team's own set, so it follows the workspace's again.
The CLI reads templates and guidance from files:
clanker status instructions show "Plan" --team WEB clanker status instructions set Design --team WEB --document Design --template-file design.md \ --guidance-file design-guidance.md clanker status instructions reset Design --team WEB clanker instructions show --kind ticket --team WEB clanker instructions set --kind ticket --team WEB --status "Plan" --owner creator --clankers creator clanker instructions set --kind test-cases --team WEB --template-file case.md --guidance-file cases.md clanker instructions reset --kind ticket --team WEB
Clankers change instructions with
update_clanker_instructions, with their person's rights:
status for a status's document, template and guidance, or kind for the others.
On every surface
Generated from Clanker Ship's surface registry. A dash means the surface leaves the operation out.