ORD-418: Return cancelled_at on the orders API
Jira tickets in,draft pull requests out
Move a ticket to In Progress and a minion picks it up. It asks the reporter when something is unclear, writes the change across your services with Claude Code, reviews its own work, and opens draft PRs linked back on the ticket.
Return cancelled_at on the orders API
-
minion
@Dana Kim minion needs answers before it can start:
- Backfill
cancelled_atfor orders cancelled before this change? - When an order isn't cancelled, return
nullor omit it?
Claude: 1 run(s), 14 turns, $0.62
- Backfill
-
Dana Kim
No backfill. Return
null. -
minion
minion opened draft PR(s):
acme/orders #88acme/api-gateway #412
Claude: 2 run(s), 41 turns, $2.80
ORD-418: Return cancelled_at on the orders API
The ticket is the whole interface
People keep working in Jira and GitHub. minions does the steps in between, and says on the ticket what it did and what it cost.
-
Trigger
Someone moves a ticket to In Progress. A Jira Automation rule pings minions, which labels the ticket
minion-workingand queues it.Jira, minions
-
Understand
It reads the title, description and every comment, and picks the repos from the ticket's labels. If anything is unclear, it asks the reporter.
minions, Claude
-
Build and review
Claude Code writes the change and tests, and runs the build. A second session with fresh context reviews the diff and fixes real bugs.
Claude
-
Deliver
minions checks protected paths, pushes
minion/KEY, opens one draft PR per repo, and comments the links and cost on the ticket.minions, GitHub, Jira
Unclear ticket? It asks first. The questions tag the reporter and add minion-needs-info. The reply starts a new run that reads the whole thread and continues the same branch.
The agent writes code but never holds a key
Ticket text is untrusted input to an agent that edits code. So the agent gets the code and a toolbox, and everything else stays behind checks written in code, not in a prompt.
Claude sandbox
Where untrusted ticket text lands.
- Read and edit code inside its workspace
- Run the Go toolchain and read-only git
- Use extra tools only if you or the repo allow them
- See any token, or read files outside its workspace
- Reach the network from the code it runs
- Commit, push or comment
minions service
Holds the keys and enforces the rules.
- Short-lived GitHub tokens, one per org, sent only to that org
- Repo names checked against your allowlist before any clone
- Refuses to push if a protected path like
.github/changed - Scans every diff for its own secrets before pushing
- Opens draft PRs only, listing everything the agent did
Your team merges. minions never merges anything. Every change goes through your normal review.
Every command the agent runs, and everything it starts, such as tests, runs in Claude Code's sandbox with no network and no credentials. Even code written from a malicious ticket has nowhere to send anything.
Built to be left running
Jira is the source of truth, so there's no database to run and nothing to lose in a restart.
Restart-proof queue
The
minion-workinglabel is the queue. A sweep re-queues labeled tickets at startup and every 10 minutes.Graceful shutdown
Interrupted tickets keep their label and resume on the next start.
Safe retries
Rate limits and transient errors are retried. A comment or PR is never created twice.
Re-runs continue
Triggering a ticket again continues its branch and updates the same PR.
Failures say why
A failed ticket gets a comment with the reason, and its label is cleared so it doesn't loop.
Work you can audit
Every PR lists the agent's commands, file edits and denials, plus runs, turns and dollars spent.
14:02:51 INFO minions listening addr=:8080 workers=2 14:03:10 INFO claude run subtype=success turns=14 cost_usd=0.62 14:03:11 INFO job done issue=ORD-418 took=1m52s 14:21:44 INFO claude run subtype=success turns=29 cost_usd=2.11 14:24:03 INFO claude run subtype=success turns=12 cost_usd=0.69 14:24:19 INFO job done issue=ORD-418 took=7m05s
One deployment across all your GitHub orgs
Install the GitHub App on each org and let its owner pick the repos. minions mints a short-lived token per org. Tickets name repos by label: a short name, an alias, or a full owner/repo.
# exact repos, by short name: label "orders"
MINION_REPOS=acme/orders,acme/api-gateway
# aliases, e.g. for same-named repos in two orgs
MINION_REPOS=api=acme/api,platform-api=acme-platform/api
# whole orgs: tickets name the repo in full
MINION_REPOS=acme/orders,acme-tools/*
Running in an afternoon
You need Jira Cloud, GitHub, an Anthropic API key and somewhere to run one container. Access to the code and full setup guide is by request for now.
Get an Anthropic API key
Create it in the Claude Console, ideally in its own workspace, and set a monthly spend limit.
Create a GitHub App
Give it read and write access to Contents and Pull requests, plus read access to Metadata. Install it on each org and pick the repos it may touch. A personal access token works for a first trial.
Add a Jira bot account
Create an API token for it. It needs to browse, comment on and edit issues in your projects.
Run it
One replica, reachable by Jira Cloud over HTTPS.
docker build -t minions . docker run -p 8080:8080 \ -e MINION_WEBHOOK_SECRET=... -e MINION_JIRA_PROJECTS=ORD \ -e MINION_REPOS=acme/orders,acme/api-gateway \ -e JIRA_BASE_URL=https://acme.atlassian.net \ -e JIRA_EMAIL=... -e JIRA_API_TOKEN=... \ -e GITHUB_APP_ID=... -e GITHUB_APP_PRIVATE_KEY="$(cat app.pem)" \ -e ANTHROPIC_API_KEY=... \ minionsAdd two Jira Automation rules
Both send
{"issue":"{{issue.key}}"}to/webhookwith your secret in theX-Minion-Secretheader. One fires when a ticket moves to In Progress. The other fires when the reporter comments on a ticket labeledminion-needs-info.
Questions teams ask first
Does it ever merge?
No. minions only opens draft pull requests. Your team reviews, edits and merges them like any other PR.
What does a ticket cost?
Each trigger makes at most two Claude runs, one to implement and one to review, each capped by MINION_MAX_BUDGET_USD (default $20). The real cost is posted on the ticket and the PR every time.
What if a ticket is unclear?
The agent makes no changes and posts specific questions, tagging the reporter. The reporter's reply starts a new run that reads the whole thread.
Which languages does it support?
Go works out of the box. For other languages, allow their commands in the repo's .minions.json, add the toolchain to the container image, and vendor or pre-install dependencies, since the agent's commands have no network.
Can it touch any repo?
Only repos on your allowlist, and with a GitHub App, only repos each org's owner selected. Paths such as .github/ can't be pushed at all.
Where does my code go?
minions runs on your infrastructure. The agent runs Claude Code with your own model access, through the Anthropic API, Amazon Bedrock or Google Vertex AI, so the code it reads goes to the provider you choose, under your organization's terms.
What happens if minions restarts mid-ticket?
The ticket keeps its minion-working label, and minions picks it up again when it starts.
Want to try it on your team?
minions is in early access. Get in touch and we can start the way it should start: one low-risk repo, a few tickets triggered by hand, and a close look at the draft PRs.