# bay > Run several coding agents in one codebase without stale branches, colliding merges or a broken main. Each agent submits its change once. bay checks the exact result, merges it into main and records why. It is free, MIT-licensed and runs on your machines. Your agents finish in minutes. Why do they wait hours to merge? Stale branches, colliding merges and a broken main eat the time they saved. With bay, an agent submits once and moves on, and bay merges only what passed on the latest main. Free, open source, and your code stays on your machines. ## Names - **main**: The one branch bay merges into, such as `main` or `dev`. You name it, and bay only adds to it. - **merge**: One checked change added to main. `bay merge` submits one. - **change**: One id for one intended outcome. The id stays when the agent revises the work. - **view**: A sparse checkout of the paths that one change needs. - **candidate**: The exact result that bay builds from the change and the latest main, then checks and merges. - **check**: Any command that tests a candidate and returns a result. - **evidence**: A record of what one check, review or runtime observation saw on one candidate, signed once you enrol keys. - **runner**: The process that runs the checks on a candidate and merges it into main. ## Daily commands - `bay start "fix the login page"` — open a view with only the paths this change needs - `bay merge` — submit and return; a runner checks and merges it - `bay status` — what each change does now, and why it waits - `bay status --since` — what changed that affects my work - `bay undo c7k2m4qa` — a new change that undoes one merge ## Free, open, private bay is free for any team, of any size, under the MIT licence. There is no paid tier, no account and no sign-up. bay runs on your machines and talks only to your own Git remote. So it fits the most private repositories a company has. - **Your code never leaves**: bay has no server, and it sends no telemetry. Your code goes only where your own Git remote is. Besides your remote, bay itself only downloads its releases from GitHub, at most once a day. You can turn that off. - **Read every line**: bay is one Rust program with five direct dependencies, and it forbids unsafe code. A test counts every command, flag and reason code; a new one must take a step away from someone. Ask your coding agent to read the source before you trust it. - **Checks run in a sandbox**: On macOS and Linux, a check sees only its candidate, its own files and system files. It gets no network unless your policy on main allows it. - **Signed releases**: A hardware-held key signs every new release. The install script and `bay update` refuse a release that does not verify. - **Build it anywhere**: Ready builds cover macOS and Linux, on ARM and Intel. The static Linux builds also run on ARM boards. Build it from source for Windows and other targets. - **Build bay with us**: We build bay in the open. To join the work, email the founders at hello@getbay.io. ## What you can count on Don't take our word for it. Everything below has a failure test that must pass before each release, signed in Git notes. Verify any release yourself: fetch `refs/notes/bay/*`, then run `scripts/gate.sh --verify `. - **What bay merges is what it checked.** bay first builds a candidate from the change and the latest main. It checks that exact candidate. bay merges the candidate only if main did not move. If main moved, bay builds a new candidate and checks again. bay's commit on main is the commit that passed, unless you turn on batching: then a batch's last commit passed. A check with `footprint = true` may also cover a later tree that reads the same files. - **Submit once. Walk away.** `bay merge` returns at once. While a runner runs, it does the rest: `bay runner run`, or your CI through the same contract. It checks, merges, recovers, or asks for one exact repair. If a reply gets lost, bay finds the first result and does not merge twice. - **Unknown is never a pass.** A check that crashes, times out or finds fewer tests than its minimum blocks the merge. Finished checks keep their results. A resume runs only the missing checks. - **Stale work stops. Repair stays open.** When an input of your change merges, bay tells the agent what changed. The agent can still edit. It cannot merge until it checks again. This covers the inputs the change declared, and bay states how much it could see. - **Every refusal says what to do next.** Each refusal has a fixed reason code. It also lists what the agent can still do, and when a retry can work. bay refuses an unchanged retry at once, so no agent loops. - **Git is the only store.** Changes, evidence and events are Git commits, notes and refs. There is no database and no server. You can read and recover everything with plain Git, on the host you have. - **A view costs what the task reads.** `bay start` opens only the paths that one change needs. All views on one machine share one cache. bay never reads a missing path as a deletion. This holds on a warm cache; build outputs, fixtures and wide searches can still cost more. ## Docs Every page is also markdown: add .md to its URL (https://getbay.io/docs/install.md), or send Accept: text/markdown. All pages in one file: https://getbay.io/llms-full.txt. ### Start here - [Overview](https://getbay.io/docs.md): bay merges the exact change your agents checked, and it keeps the evidence in Git. - [Several agents, one repository](https://getbay.io/docs/several-agents.md): How several coding agents share one Git repository without races, double merges or unchecked merges. - [Adopt bay step by step](https://getbay.io/docs/adopt.md): Try bay in small steps on your own repository, score the trial, and switch it off if needed. - [Run bay without a runner](https://getbay.io/docs/no-runner.md): A small team can merge with bay from its own machines, with no runner to host or keep running. - [Install](https://getbay.io/docs/install.md): Install bay with one command, then check the machine with `bay doctor`. - [Quickstart](https://getbay.io/docs/quickstart.md): Install bay, set your checks, start a runner, then start and merge a first change. - [Concepts](https://getbay.io/docs/concepts.md): bay gives each name one meaning, and these pages use each name only in that meaning. ### Merge changes - [Runners](https://getbay.io/docs/runners.md): The runner finishes each merge after the agent leaves. - [Merge more changes a day](https://getbay.io/docs/throughput.md): Let idle runners check queued changes early, carry records across unrelated merges, and check several changes as one tree. - [Undo a merge](https://getbay.io/docs/undo.md): Take one merged change back out of main with a new checked change, and keep main's history as it is. - [Configuration](https://getbay.io/docs/configuration.md): Two files configure bay: `.bay/config.toml` for the repository and `.bay/policy.toml` for the checks. - [Promote main to other branches](https://getbay.io/docs/promote.md): Move a branch such as `staging` only to a checked commit from main, and see which commit is ready. ### Coordinate agents - [Agents and hooks](https://getbay.io/docs/agents.md): How a coding agent learns bay, and what the hooks of each agent product add. - [Teach your agent bay](https://getbay.io/docs/skill.md): Install the bay skill, so any coding agent knows how to merge changes with bay. - [See what your fleet is doing](https://getbay.io/docs/fleet.md): See every machine, agent and session on a repository, and read what changed since you last looked. - [Talk to other agents](https://getbay.io/docs/talk.md): Ask an agent on another account, machine or agent product for one change, decision or check. - [Keep experiments in sandbox lanes](https://getbay.io/docs/lanes.md): Let agents try work on lane branches that run checks against main but never merge into it. - [Wire any reviewer to bay](https://getbay.io/docs/reviewers.md): Run any review tool on each merge after it merges, and keep every review out of the merge decision. - [Require a person's approval](https://getbay.io/docs/approvals.md): Hold a change to chosen paths until a person signs a yes for its exact checked candidate. ### Operate bay - [Host a main branch without a forge](https://getbay.io/docs/host.md): Keep main in a plain bare Git repository over SSH, and let the host itself refuse any rewrite of main. - [Keys and the registry](https://getbay.io/docs/keys.md): Optional signing: who may sign what, and how `bay enrol` adds and removes a key. - [Update](https://getbay.io/docs/update.md): Keep bay current with `bay update`, a daily background check, and version pins. - [Roll bay out to many machines](https://getbay.io/docs/rollout.md): Install bay on every machine, then turn on its hooks for all of them with one merge. - [Security and privacy](https://getbay.io/docs/security.md): What bay sends, where it sends it, what it guards, and how you can check every claim yourself. ### Reference - [CLI reference](https://getbay.io/docs/cli.md): Every bay command, its purpose, and the result it prints. - [Results and refusals](https://getbay.io/docs/results.md): What each field of a bay result means, and what to do after each refusal. - [Changelog](https://getbay.io/docs/changelog.md): What changed in each bay release, newest first. ## Blog - [bay 0.3.1: Git made simple for many coding agents](https://getbay.io/blog/bay-0-3-1.md) (2026-10-22): bay makes Git simple when many coding agents work in one codebase. Each agent submits once and moves on, and bay merges only what passed on the latest main. - [Hooks are sensors. The guard sits at main.](https://getbay.io/blog/hooks-are-sensors.md) (2026-10-22): Every coding agent product now has hooks, each in its own dialect. What a hook is, which moments can refuse, and why bay's promises never rest on one. - [bay 0.2.0: more merges, safer promotion](https://getbay.io/blog/bay-0-2-0.md) (2026-10-21): bay 0.2.0 is out. It merges more changes for the same checks, guards the paths to production, and finds what turned main red. Every new rule is off until you turn it on. - [bay 0.1.8: ready for every team](https://getbay.io/blog/bay-0-1-8-ready-for-every-team.md) (2026-10-12): bay 0.1.8 is out, and bay is ready for any team that runs coding agents. It is free, private, and small enough to read. - [Hooks are the new stand-up](https://getbay.io/blog/hooks-are-the-new-standup.md) (2026-10-03): Builders already wire agent hooks to their boards. No shared contract has caught on yet. What hooks can do today, and what that contract needs. - [Why we built bay](https://getbay.io/blog/why-we-built-bay.md) (2026-09-24): Our agents write code fast. Merging it became the speed limit of the whole fleet. - [How many agents can one main branch take?](https://getbay.io/blog/how-many-agents-per-trunk.md) (2026-09-15): The limit is merges per day, not machines. Here is how to estimate it, set bay up, and raise it. - [Running a dev team now means building its tools](https://getbay.io/blog/running-a-team-means-building-tools.md) (2026-09-06): With agents writing the code, the effort to run a team moves into tooling. bay is our part of that, and it will be open. ## Install `curl -fsSL https://getbay.io/install.sh | sh` (macOS and Linux, ARM and Intel). It installs the newest release with a build for the machine. On Windows and other targets, build from source with `cargo build --release`. The machine-readable contract: `bay help --json` lists every command, flag, decision and reason code with its allowed actions, and the JSON Schema of bay.result/1. The schema is also at https://github.com/gudjon/bay/blob/main/schemas/bay.result.schema.json. To teach a coding agent bay, install the bay skill: `npx skills add gudjon/bay --skill bay -g`. The skill tells the agent how to install bay when it is missing. See https://getbay.io/docs/skill.md. ## Status Launched, and ready for teams to use. Free for every team. The code is open at https://github.com/gudjon/bay under the MIT licence, with no paid tier, no account and no sign-up. bay has no server and sends no telemetry: your code goes only to your own Git remote. Version numbers are 0.x, so a minor release can still change a command, and the changelog names each change. The benchmark figures on the site are targets, not results. ## Contact and contributing hello@getbay.io · https://getbay.io. To join bay's development, email the founders at hello@getbay.io.