AgentRail Docs
Getting Started

Introduction

What AgentRail is and who it's for.

AgentRail is the control plane that runs your coding agents. You bring an agent — Claude Code, Codex, or Cursor — and AgentRail gives it durable repo context, bounded execution, independent review, and verification gates, so its work is cheaper, inspectable, and safe to leave unattended.

AgentRail is not a coding agent. It does not write code itself. It runs the agent you already use, on rails: scoped context instead of whole files, a hard budget per issue, a second model reviewing the work, and gates that stop merges the agent can't justify.

Who it's for

  • Engineers who want to hand an issue to an agent and get a reviewed PR back without babysitting a run or watching the token meter.
  • Startups clearing a backlog overnight under a predictable spend ceiling.

How it works

The primary flow is the hosted dashboard + self-hosted runner:

  1. Sign up on the dashboard and connect your GitHub repos on the Connectors page — pick the trigger label (ready-for-agent) and poll interval.
  2. Install the CLI: npm install -g @useagentrail/cli
  3. agentrail login — links this machine to your workspace (OAuth device flow, saves ~/.agentrail/credentials.json). Login is required to use the CLI. The only exempt commands are login, logout, whoami, and --help.
  4. agentrail runner — the local worker claims queued issues over HTTP, runs them on your machine with your own LLM keys, opens PRs, and reports back.
  5. Label a GitHub issue ready-for-agent → the runner picks it up → a reviewed PR comes back.

See Quickstart for a step-by-step walkthrough and Dashboard & hosted runner for a deeper look at the console.