Using conch
Integrations
conch reads GitHub through gh: pull requests, their checks, and what a failed GitHub Actions run printed. An integration lets conch read another service the same way. The first kind is CI: when a pull request turns red on CircleCI, GitLab CI, Buildkite or Jenkins, conch branch fix-ci and the autopilot's auto_fix hand the failed job's output to the branch's agent, just as they do for Actions. conch branch rerun-ci re-runs what failed.
An integration is a file, not a plugin. It describes a service's HTTP API: which call lists a branch's runs, where the failed job's log is, and how the key is sent. conch's own code decides what to do with the answers. A file can't run a program. All it can do is send your key to the hosts it names, and conch shows you those hosts before anything is installed.
What ships with conch
| Integration | Key | Where the key comes from | Reads | Re-runs |
|---|---|---|---|---|
| CircleCI | $CIRCLECI_TOKEN, a personal API token | CircleCI → User Settings → Personal API Tokens | the failed steps of the failed job, from CircleCI's log host (without your key) | the workflow, from failed |
| GitLab CI | $GITLAB_TOKEN, with read_api (api to retry) | GitLab → Preferences → Access tokens | each failed job's trace | the pipeline |
| Buildkite | $BUILDKITE_TOKEN, scopes read_builds read_build_logs write_builds | Buildkite → Personal Settings → API Access Tokens | each failed job's log | the build |
| Jenkins | $JENKINS_TOKEN, with your user in $JENKINS_USER | Jenkins → your name → Security → API Token | the build's console | — (it depends on plugins) |
Each key is read from the environment of the machine where conch's server runs, then from the Keychain on a Mac (service conch-mcp, account named after the variable, where conch integration install puts it). conch never writes a key to a file.
conch finds which integration a project uses in three ways: a file in the checkout (.circleci/config.yml, .gitlab-ci.yml, .buildkite/pipeline.yml, Jenkinsfile), its remote's host (gitlab.com), or the pull request's checks (ci/circleci: …). GitHub Actions is always asked first.
A service you run yourself (Jenkins, a self-managed GitLab) needs its address in config.toml:
[integrations.base]
jenkins = "https://jenkins.example.com"
gitlab-ci = "https://gitlab.example.com/api/v4"
Ticket trackers
Linear and Jira are conch's own code ([trackers]). A tickets integration adds another tracker beside them: its open tickets in the Tickets view and conch ticket all, a task started from one, and conch ticket comment, status and link on it.
| Integration | Key | Where the key comes from | Notes |
|---|---|---|---|
| Shortcut | $SHORTCUT_API_TOKEN | Shortcut → Settings → Your Account → API Tokens | a story by its number: shortcut:123; status takes a workflow state's name (In Review); a link is added as a comment |
| GitLab issues | $GITLAB_TOKEN, with api (read_api only reads) | GitLab → Preferences → Access tokens | the issues of the project's GitLab repository, found from its remote; status takes close or reopen |
A ticket from an integration is named NAME:KEY wherever conch takes one: conch task -ticket shortcut:123, conch ticket show gitlab-issues:12. Tie a project to one and its keys alone will do:
[[trackers.projects]]
project = "app"
tracker = "shortcut"
A tracker that belongs to a repository (GitLab issues) shows in that project once its key is set. One that doesn't (Shortcut), and that no project is tied to, is a group of its own in the Tickets view.
Notifications
A notify integration is told what the desktop is: an agent started waiting, an agent finished, and a pull request the autopilot merged. conch's server sends it, so it arrives whether or not the TUI or Conch.app is open, and once however many are.
| Integration | Key |
|---|---|
| Slack | $SLACK_WEBHOOK_URL, an incoming webhook's address (https://hooks.slack.com/services/…) |
| Discord | $DISCORD_WEBHOOK_URL, a channel webhook's address (https://discord.com/api/webhooks/…); nobody is ever mentioned |
| ntfy | $NTFY_TOPIC_URL, a topic's address (https://ntfy.sh/a-topic-nobody-guesses), or one on your own server with [integrations.base] ntfy |
A webhook's address is its secret, so it is kept like a key: read from the variable or the Keychain, never written to a file, never logged or shown. It must be an https address on the service's own host; any other is refused before anything is sent. [notify]'s enabled, waiting and done apply as they do to the desktop's alerts. conch integration key slack takes the address without echo and sends a test message.
Deploy previews
A deploy integration is where a branch is built and shown: Vercel and Netlify, installed from the registry. In Conch.app, Window → Integrations has a Deploy previews section with a card for each — what its file can do, the one host your key goes to, and what was found in your projects (Found vercel.json in this repo). Install and Connect asks you to agree to that host, takes the token (kept in the Keychain, or read from $VERCEL_TOKEN / $NETLIFY_AUTH_TOKEN), and checks it once by reading a branch's deploys in a project that uses it. conch finds the Vercel project or Netlify site by the repository it builds from. From a terminal: conch integration install vercel.
Once it is connected, a branch shows its deploys:
- Conch.app's git tab. The header has the newest deploy's state as a chip (Vercel · Ready). A click opens the preview, or a failed build's page. The pull request's card has the newest ready preview's link. The overview has a Deploy previews card. With a pull request it lists the deploys at its head commit; without one, the branch's history. Each row has its state (ready, building, failed or canceled), commit, subject (from your git), the preview link or the error, and when it was built.
- A failed build has Build Log on Vercel. Netlify's API has no build log, so there it is Error Message. Both have Send to the Branch's Agent and Redeploy.
- A ready deploy has Promote to Production (Vercel) or Publish to Production (Netlify), which asks first in that service's words. Vercel builds the commit again with production's environment and shows that build as Building until it is ready. Netlify publishes the deploy as it was built, at once. Netlify can't publish a deploy preview: publish a production-branch deploy, or an earlier one to roll back.
- Its page in the Integrations window has Where it shows: each project that deploys there, with Open Its Previews, or what conch looks for when none does (
vercel.json,netlify.toml, or the service's check on a pull request). - A project Vercel links from its own side. Vercel can link a repository from its dashboard with no
vercel.json, and a branch without a pull request has no Vercel check, so conch can't tell the project deploys there. Turn it on in the project's Integrations… sheet (Vercel deploys this project), or withconch integration use vercelin its folder. It is kept inconfig.tomlunder[integrations.projects];-offturns it off. - Nothing found: when no Vercel project (team projects aren't supported yet) or Netlify site (only your first 100 are read) builds from the repository, the card says so. The connect sheet's check says so too, and keeps the key.
- The TUI's branch view. Under the checks, a line for each deploy integration shows its newest deploy's state, commit and preview address, or a failed build's error.
vopens the preview, or the failed build's page. - The agent. When no CI run failed, a failed build at the pull request's head is what
branch.ci_logreads. The autopilot's auto_fix,conch branch fix-ciand the review queue'sfsend it as they send a failed CI run: the end of its log, with a link to it.conch branch fix-ci -source vercel -deploy dpl_123sends one build. A red Vercel or Netlify check with nothing installed is named (Vercel: install its integration to read its log), as an unreadable CI check is.
Releasing is the person's. An agent can't promote, even in its own project. The server refuses branch.promote from any agent's pane, and conch integration promote run there refuses before it calls anything. The autopilot never releases. Redeploy follows a CI re-run's rule: an agent may for its own project.
By hand:
conch integration previews # this branch's deploys: state, preview link, why one failed
conch integration deploy-log dpl_123 # the end of what a deploy's build printed (-lines 0 for all)
conch integration redeploy dpl_123 # build it again
conch integration promote dpl_123 # release it to production: asks first, -y to skip
With no name, the deploy integration the project uses is taken (vercel.json, netlify.toml). -head SHA keeps the deploys of one commit, as at a pull request's head. promote asks, and anything but yes releases nothing. Netlify's API has no build log, so a failed deploy gives its error message instead, and that is what the agent is sent.
Import
An import brings another app's conversations into conch: so far Conductor, whose conversations live in its own database and go when the app is removed. Its file has no key and reaches no service. It says where the app keeps its conversations on this machine and which of conch's readers reads them, and conch's own code does the reading, from a copy, so the app is left as it was. Nothing is sent anywhere.
In Conch.app it is Integrations → Import. The card says whether the app is found on this Mac. Import… lists its conversations by workspace, ticked but for those imported already, and writes each one you keep ticked as a handoff an agent can read and carry on from. On the command line it is conch import conductor (more). An import whose reader this conch does not have, or has an older version of, says it needs a newer conch.
Hooks
A hook is an action run on events, shared: the setup a team runs in every new worktree, a message when an agent finishes. Unlike every other kind it runs something, a command on your machine with your rights. So it holds no key and reaches no service of its own. conch integration install fetches it and shows the whole command and the events it runs on before asking, and -y does not skip the showing. An update that runs another command, or on other events, is shown and asked about again even with -y. It is installed with its hash recorded like any file, and the server runs installed hooks after the ones in your config.toml.
format = 3
kind = "hook"
name = "setup-worktree"
label = "Set up a worktree"
[hook]
run = "make setup"
on = ["worktree.created"]
timeout = 600 # seconds; conch's five minutes when left out
variables = ["CONCH_WORKTREE", "CONCH_BRANCH"] # what it reads, said at install
When a check can't be read
If the failure came from a service conch recognises but has no integration for, such as Bitbucket Pipelines, fix-ci says Bitbucket Pipelines: install its integration to read its log. It doesn't stop at "no failed GitHub Actions run". If an integration is there but its key isn't, the message names the variable to set.
The branch says so too. In the TUI's changes view and Conch.app's git tab, a red check conch can't read gets an amber card: which check, that its agent wasn't sent the log, and why conch thinks the project uses that service (found .circleci/config.yml). Install CircleCI… (I in the TUI) installs the integration, Open in CircleCI (O) opens the check. Every check is listed beneath with where it ran. Once an integration reads it, the card goes. Re-run failed jobs (r) re-runs on Actions or through an integration.
The autopilot's notes name the service too: CI failed on rgw-lc-fix — CircleCI · workflow build-and-test · job unittest-rgw.
In Conch.app and the TUI
In Conch.app, Window → Integrations (or ⌘K, "Integrations") lists them by kind, with a banner when one of your projects uses a service that has no key yet. A card opens the integration's page: what it does in conch, the hosts your key goes to, and who wrote the file. Install or Connect asks you to agree to the hosts, then takes the key (and the address of a server you run yourself), keeps it in the Keychain, and checks it once against a project that uses it.
In the TUI the same list is under Settings (,) → Integrations.
A project's integrations
Right-click a project in Conch.app and choose Integrations…, or pick Integrations… on a project's row menu in the TUI. It shows a row for each kind: the code host (from the remote), every CI the project's files and pull request checks show, the tracker its tickets come from (as Settings set it), the sandboxes set up, and notifications. Each one has its state: connected, key not set with Connect…, not installed with Install…, or Browse… when the project has none of that kind. Connect and Install are offered for this computer's projects, since a key is given where the server runs.
.conch/integrations.toml
Tick Save in .conch/integrations.toml for the team to write the names of what the project uses into the repository, so everyone who clones it gets the same integrations. Commit it like any other file:
uses = ["circleci", "github-actions", "jira"]
The file holds names only. A key is never written there and never read from it; each person's key stays in their own Keychain or environment. Unticking the box deletes the file.
When a repository you open already has the file, conch asks once: This repository's .conch/integrations.toml says it uses CircleCI and Jira. Use them? It only asks again if the file adds a name. Until you say yes, the file's names aren't used. Your answer is kept per repository, outside the repository.
Commands
conch integration ls # every integration here, its key's state, and whether this project uses it
conch integration info circleci # what it does in conch, where your key goes
conch integration search ci # what the registries list
conch integration install NAME # agree to its hosts, give its key, check it against this project
conch integration update # newer versions; new hosts, or a key read from another variable, are always asked about
conch integration check ./mine.toml # what is wrong with a file, an import's too
conch integration adapt URL # an agent writes a file from the service's API docs
conch integration publish NAME # propose yours to the registry
The full list is in the command line reference.
Registries
Integrations are published to a registry: a GitHub repository whose CI publishes an index of the files, and the files themselves. Each version is pinned by its hash and never replaced. When conch knows a registry's key, its index must be signed (index.json.sig, ed25519), or nothing is read from it. An index read without a key is marked unsigned. A registry can revoke a version. conch then stops using it and conch integration ls says why.
The registry also decides what the catalog shows: its top-level folders are the kinds (Code hosts, CI, Sandboxes…, named in its kinds.json), and each integration's folder holds its icon. conch downloads an icon once, checks it against the index's hash and keeps it; conch integration icons lists them. A kind this conch has no code for is shown as needing a newer conch.
Each entry carries what it can do (capabilities, worked out from its file when the index is built): its operations, how its key is sent, what you supply (a key, a server's address, a user) and, for a CI, whether it can re-run. The cards and conch integration info show it, and conch offers Re-run only for a failing check whose integration can.
Your company can run its own registry:
[[integrations.registries]]
name = "acme"
url = "https://acme.github.io/conch-integrations"
key = "BASE64 ED25519 PUBLIC KEY"
Writing one
A file of your own goes in ~/.config/conch/integrations/NAME.toml and replaces one conch ships with the same name. conch integration guide prints the format with an example. conch integration check FILE lists everything wrong with a file, so fix what it reports until it reports nothing. In short:
format = 3
kind = "ci"
name = "acme-ci"
api = "https://api.acme.dev"
key_env = "ACME_TOKEN"
[detect]
files = [".acme.yml"]
[project]
id = "{owner}/{repo}"
[states]
ok = "pass"
broken = "fail"
[runs]
call = "GET /runs?branch={branch}&commit={head}"
items = "runs"
id = "id"
state = "status"
[failed_log]
call = "GET /runs/{run}/log"
text = "."
Adapting one from its API docs
For a service nobody has written a file for, an agent can:
conch integration adapt -kind ci -agent claude -name semaphore https://docs.semaphoreci.com/reference/api-v1alpha
conch downloads the docs into a folder of their own, with the format and the kind's contract, and starts the agent there in a pane of its own (watch it in the tree). It writes semaphore.toml and runs conch integration check until nothing is wrong. Then conch checks it with your key: one read-only call for this project's runs (-cwd names another). The file chose both the key's variable and the host it goes to, so conch says that pair and asks first. The agent never has your key: it is not in its prompt or its folder, and the variables keys usually live in are emptied in its pane.
-revise "…" NAME asks the agent for a change, -check NAME checks with your key again, and -save NAME keeps the draft as a file of your own. In Conch.app it is Integrations → ✦ Adapt from API docs…: kind, service, docs and agent, then the same steps as a list.
conch integration publish NAME proposes a file to the registry. It checks the file with your key first and opens a pull request through gh, as you, with the file, its index entry and the check's result. A maintainer reviews it before it is listed.
Not yet
These are planned but not here yet: code hosts besides GitHub, and intake from a tickets integration (intake reads GitHub issues only, as it does for Linear and Jira). For deploy previews, these are missing: what is in production now (no operation reads production's deploy, domain or commit, so there is no Production row), a Vercel project owned by a team (its calls need a teamId the file can't ask for), a preview chip on the branch's row in the tree, and releasing from the TUI (use conch integration promote). conch integration guide has the tickets, notify and deploy formats.