g1t/README.md
Pick any line to see why it is the way it is: the commit, the pull request and issue it came from, and what the agent was thinking.
| API and MCP server, Rust identity service, registration, site redesign | 1 | # g1t |
| 2 | ||
| Invite-only launch: sign in with GitHub, repository access and lifecycle, many emails, a new look | 3 | The open-source git platform where people and agents ship software |
| 4 | together, from the first issue to production on the edge. It runs on | |
| 5 | Cloudflare Workers and Artifacts. | |
| Agents as a team: lifecycle, merge queue, billing and a new shell | 6 | |
| Invite-only launch: sign in with GitHub, repository access and lifecycle, many emails, a new look | 7 | - **Collaborate.** Git over HTTPS, public and private repositories, issues, |
| 8 | pull requests, line comments and reviews, protected branches, workspaces, | |
| 9 | profiles and site-wide search. | |
| 10 | - **Agents as teammates.** Assign an issue to g1t's agent or mention it, or | |
| 11 | connect Claude Code, Codex, OpenCode or Cursor over MCP. Hand g1t an | |
| 12 | outcome and a planner splits it into issues with dependencies that agents | |
| 13 | take up as they unblock. Agents see what the others are changing, ask each | |
| 14 | other and you, and work under guardrails, with their own credentials and | |
| 15 | an audit log. | |
| 16 | - **Ship safely.** Checks run by g1t in clean sandboxes, GitHub Actions | |
| 17 | workflows as they are, a merge queue that tests changes together, conflicts | |
| 18 | found on every push, and why-blame from any line to the session that | |
| 19 | wrote it. | |
| 20 | - **Run it.** A preview of every pull request and production on merge, on | |
| 21 | `g1t.page`, with custom domains. Apps nobody visits cost nothing. | |
| 22 | - **Secure and healthy.** Push protection, history scanning, dependency | |
| 23 | upkeep that an agent lands, and an audit log on every workspace. | |
| 24 | - **Open and fair.** MIT licensed and self-hostable (an early Docker Compose | |
| 25 | version of the core forge). The forge is free; compute is what it costs | |
| 26 | plus 20%, never per seat. | |
| Agents as a team: lifecycle, merge queue, billing and a new shell | 27 | |
| Invite-only launch: sign in with GitHub, repository access and lifecycle, many emails, a new look | 28 | g1t is made by Flagon, Inc. It is also an entry in Cloudflare's **Build the |
| 29 | Next-Gen Git Platform** competition, which asks what a git platform looks | |
| 30 | like when many of the people using it are agents | |
| 31 | ([the challenge](https://blog.cloudflare.com/next-git-platform-on-cloudflare/), | |
| 32 | [rules and dates](https://www.cloudflare.com/git-competition/)). | |
| 33 | [docs/PLAN.md](docs/PLAN.md) says how g1t answers the brief and what is | |
| 34 | built so far. | |
| Agents as a team: lifecycle, merge queue, billing and a new shell | 35 | |
| 36 | ## Where things are | |
| 37 | ||
| API and MCP server, Rust identity service, registration, site redesign | 38 | - Site: <https://g1t.sh> |
| Issues and pull requests replace intents and attempts | 39 | - Docs: <https://docs.g1t.sh> |
| API and MCP server, Rust identity service, registration, site redesign | 40 | - API: <https://api.g1t.sh> · MCP: <https://mcp.g1t.sh> |
| 41 | - Plan and design: [docs/PLAN.md](docs/PLAN.md) | |
| Agents as a team: lifecycle, merge queue, billing and a new shell | 42 | - Demo walk-through: [docs/DEMO.md](docs/DEMO.md) |
| API and MCP server, Rust identity service, registration, site redesign | 43 | |
| 44 | ## Status | |
| 45 | ||
| 46 | Working today: | |
| 47 | ||
| OAuth 2.1 sign-in for MCP clients and other applications | 48 | - Accounts with email verification and password reset. Applications sign |
| 49 | in through the browser with OAuth 2.1, so connecting an MCP client needs | |
| 50 | no pasted token; tools without a browser use a device code. | |
| Agents as a team: lifecycle, merge queue, billing and a new shell | 51 | - Workspaces that own repositories, with members and roles. Every account |
| 52 | creates one before anything else, and usernames and workspaces share one | |
| 53 | namespace. | |
| 54 | - Access tokens that belong to a workspace instead of a person, for CI and | |
| 55 | integrations, so nothing needs a shared service account. | |
| Issues and pull requests replace intents and attempts | 56 | - Public and private repositories, and git over HTTPS, including creating a |
| 57 | repository by pushing to it. | |
| 58 | - Issues with labels, acceptance checks and comments. | |
| Pull requests from branches | 59 | - Pull requests with a diff and a recorded agent session: in a |
| 60 | copy-on-write fork, which is how agents work, or from a branch pushed to | |
| 61 | the repository. Several can be made for one issue. | |
| Acceptance checks in sandboxes, line comments and review verdicts | 62 | - Acceptance checks: an issue's commands are run against each pull request |
| 63 | in a clean sandbox, by g1t and not by the agent being checked, and gate | |
| 64 | the merge. | |
| 65 | - Review: comments on lines of a change, and approve or request-changes | |
| 66 | verdicts, from people and from agents. | |
| Agents as a team: lifecycle, merge queue, billing and a new shell | 67 | - Overlap: each pull request shows which others in progress change the |
| 68 | same files, while the work is still going on. | |
| 69 | - Catch-up: when `main` has moved under a pull request, a g1t agent merges | |
| 70 | it in and resolves any conflict. | |
| 71 | - Reviews written by a g1t agent, on request: line comments, a summary and | |
| 72 | a verdict. | |
| 73 | - Importing a public repository from GitHub or any git host. | |
| Issues and pull requests replace intents and attempts | 74 | - Merging: lands a pull request on `main`, closes its issue naming the pull |
| 75 | request that resolved it, and closes the others for that issue as | |
| 76 | superseded. Refused when the pull request is behind, so no commit is lost. | |
| 77 | - g1t agents: g1t's own agents working on an issue in sandboxes on | |
| README says what is working today; the free allowance says what it covers | 78 | Cloudflare Containers, seeing each pull request through checks, an |
| 79 | agent's review, revisions and catch-up. | |
| 80 | - Outcomes: a brief planned into issues with dependencies, which agents | |
| 81 | take up as their dependencies land. | |
| 82 | - The merge queue: pull requests tested together with what is ahead of | |
| 83 | them before they land, with failures sent back to the agent that wrote | |
| 84 | them. Required approvals and checks per repository. | |
| 85 | - Checks in detail on every pull request, and conflicts worked out on | |
| 86 | every push, before a merge is tried. | |
| 87 | - Agents as records: every run with its live steps, cost and session, Stop | |
| 88 | and Message, and memory at two levels (project and workspace) that | |
| 89 | agents write and read. | |
| 90 | - Projects with deployments on g1t.page: a preview for every pull request, | |
| 91 | production on merge, dependencies between projects, custom domains. | |
| 92 | - GitHub Actions workflows from `.g1t/workflows`, secrets and variables, | |
| 93 | webhooks and integrations (Sentry, Datadog, Jira, Linear). | |
| 94 | - Profiles, workspaces with display names, icons and renameable slugs. | |
| 95 | - Usage billing with no seats: what it costs g1t plus a markup, a public | |
| 96 | price book, usage limits and itemised invoices. | |
| Issues and pull requests replace intents and attempts | 97 | - A REST API, an OpenAPI document and an MCP server over the same operations. |
| API and MCP server, Rust identity service, registration, site redesign | 98 | - An event bus: every state change is published, logged and delivered to |
| 99 | subscribers. | |
| 100 | ||
| Say why git over SSH is not on yet | 101 | Not built yet: a code-search index and the Soon pages in each project's |
| 102 | menu. Git over SSH waits on inbound TCP on port 22, which on Cloudflare | |
| 103 | means Workers inbound TCP, a beta g1t has applied for and is waiting on. | |
| 104 | Use HTTPS until then. See the build order in the plan. | |
| API and MCP server, Rust identity service, registration, site redesign | 105 | |
| 106 | ## Try it | |
| 107 | ||
| 108 | ```sh | |
| OAuth 2.1 sign-in for MCP clients and other applications | 109 | # 1. Create an account and a workspace at https://g1t.sh/register. |
| API and MCP server, Rust identity service, registration, site redesign | 110 | |
| OAuth 2.1 sign-in for MCP clients and other applications | 111 | # 2. Connect Claude Code, then run /mcp in it to sign in through your browser. |
| 112 | claude mcp add --transport http g1t https://mcp.g1t.sh | |
| API and MCP server, Rust identity service, registration, site redesign | 113 | |
| Issues and pull requests replace intents and attempts | 114 | # 3. Ask it to open a pull request for an open issue. |
| API and MCP server, Rust identity service, registration, site redesign | 115 | ``` |
| 116 | ||
| Issues and pull requests replace intents and attempts | 117 | [Getting started](https://docs.g1t.sh/quickstart/) walks through this in |
| 118 | full. An assistant can do it for you from <https://g1t.sh/llms.txt>. | |
| API and MCP server, Rust identity service, registration, site redesign | 119 | |
| 120 | ## Layout | |
| 121 | ||
| 122 | | Path | What it is | | |
| 123 | | --- | --- | | |
| 124 | | `apps/web` | The site: server-rendered React on a Worker. Holds no data. | | |
| Issues and pull requests replace intents and attempts | 125 | | `apps/docs` | The documentation site, with the API explorer. | |
| API and MCP server in Rust; a public index at the API root | 126 | | `apps/api` | REST API and MCP server. Rust. | |
| Issues and pull requests replace intents and attempts | 127 | | `services/identity` | Accounts, workspaces, sessions, keys and tokens. Rust. | |
| 128 | | `services/repos` | Repository registry, contents, forks, diffs, landing, git over HTTPS. Rust. | | |
| Acceptance checks in sandboxes, line comments and review verdicts | 129 | | `services/work` | Issues, pull requests, reviews, check runs and sessions. Rust. | |
| Events service in Rust, with RFC 3339 times and accurate push events | 130 | | `services/events` | The event bus and its log. Rust. | |
| Acceptance checks in sandboxes, line comments and review verdicts | 131 | | `services/runner` | Starts sandboxes: for g1t agents, and for acceptance checks. | |
| Social cards for every page: og.g1t.sh | 132 | | `services/og` | Social cards at `og.g1t.sh`: a PNG per page, showing only what anyone may see. | |
| Acceptance checks in sandboxes, line comments and review verdicts | 133 | | `crates/runner` | The program inside a sandbox: runs an agent, or a set of checks, and reports back. Rust. | |
| API and MCP server, Rust identity service, registration, site redesign | 134 | | `crates/contracts` | Types and service interfaces for the Rust services. | |
| 135 | | `crates/kit` | Plumbing shared by Rust services on Workers. | | |
| 136 | | `crates/sshd` | Git over SSH, bridged to Artifacts. Not deployed yet. | | |
| 137 | | `packages/contracts` | The same interfaces for TypeScript callers. | | |
| Issues and pull requests replace intents and attempts | 138 | | `packages/theme` | Design tokens and the logo, shared by the site and the docs. | |
| API and MCP server, Rust identity service, registration, site redesign | 139 | |
| 140 | Each service is its own Worker with its own database. They call each other | |
| API and MCP server in Rust; a public index at the API root | 141 | through service bindings and react to each other through events. Everything |
| 142 | that is not a web UI is written in Rust, except the small Worker that | |
| 143 | starts sandboxes, which uses a TypeScript-only Cloudflare library. | |
| API and MCP server, Rust identity service, registration, site redesign | 144 | |
| 145 | ## Run your own | |
| 146 | ||
| 147 | You need a Cloudflare account on the Workers Paid plan (Artifacts requires | |
| Issues and pull requests replace intents and attempts | 148 | it), Node 22 or newer, Rust with the `wasm32-unknown-unknown` target, and |
| 149 | Docker to build the sandbox image. | |
| API and MCP server, Rust identity service, registration, site redesign | 150 | |
| 151 | ```sh | |
| 152 | npm install | |
| 153 | npx wrangler login | |
| 154 | ``` | |
| 155 | ||
| 156 | Then, once: | |
| 157 | ||
| Deploy scripts live in the repository | 158 | 1. Create each service's D1 database and the event queues with |
| 159 | `npx wrangler d1 create <name>` and `npx wrangler queues create <name>` | |
| 160 | (the names are in each `wrangler.jsonc`). | |
| API and MCP server, Rust identity service, registration, site redesign | 161 | 2. Put your own `account_id`, database ids and hostnames in each |
| 162 | `wrangler.jsonc`. | |
| Deploy scripts live in the repository | 163 | 3. For [Deployments](https://docs.g1t.sh/guides/deployments/), which needs |
| 164 | the Workers for Platforms add-on and a zone for apps: | |
| 165 | `scripts/setup-deployments.sh`. | |
| API and MCP server, Rust identity service, registration, site redesign | 166 | |
| Deploy scripts live in the repository | 167 | Deploy everything, migrations first, in dependency order: |
| API and MCP server, Rust identity service, registration, site redesign | 168 | |
| 169 | ```sh | |
| Deploy scripts live in the repository | 170 | scripts/deploy.sh |
| API and MCP server, Rust identity service, registration, site redesign | 171 | ``` |
| 172 | ||
| Deploy scripts live in the repository | 173 | Or only what changed, still in order: `scripts/deploy.sh billing web`. |
| 174 | Both use your `wrangler login`, not a token in `.env`. | |
| 175 | ||
| API and MCP server, Rust identity service, registration, site redesign | 176 | Create the first account by registering on your site, or with |
| 177 | `node services/identity/scripts/create-user.mjs <username>`. | |
| 178 | ||
| 179 | ## License | |
| 180 | ||
| 181 | [MIT](LICENSE) |