# Convoy > A declarative DSL, runtime and orchestrator for long-horizon multi-agent swarms. HCL files describe agents, topics and limits; convoyd runs them. ## Get started - [Introduction](https://convoyharness.com/docs/index.md): Convoy is a declarative language and a runtime for long-horizon agent swarms. You describe a team of agents in HCL; a server runs it until the goal is met or a limit is hit. - [Install](https://convoyharness.com/docs/install.md): Install the convoy CLI and the convoyd server, set a provider key, and start the server. - [Quickstart](https://convoyharness.com/docs/quickstart.md): Install Convoy, start the server with one API key, and run your first swarm, in about five minutes. - [Your first swarm](https://convoyharness.com/docs/first-swarm.md): Write the edge_chips market-report swarm by hand, one block at a time, then validate, run and watch it. ## Concepts - [Swarms and runs](https://convoyharness.com/docs/concepts/swarms.md): A swarm is a named declaration; a run is one execution of it. Files start a swarm, and the server holds its state. - [Agents and turns](https://convoyharness.com/docs/concepts/agents.md): An agent works in turns. It starts when its inputs are ready, gets more turns from the board or from continue turns, and ends by calling finish. - [Topics and the board](https://convoyharness.com/docs/concepts/board.md): Agents talk through topics on a shared message board. Messages are pulled, not pushed, and watches decide when an agent gets a turn. - [The overseer](https://convoyharness.com/docs/concepts/overseer.md): The overseer is a built-in agent that judges progress against the goal and steers the team. It cannot end the swarm or change its goal. - [Spawning agents](https://convoyharness.com/docs/concepts/spawning.md): Agents with can_spawn can create other agents at runtime, within limits on tools, models and depth. Spawning is declared in the file, not left to a prompt. - [Budgets and limits](https://convoyharness.com/docs/concepts/budgets.md): How Convoy bounds a run: a dollar budget, a runtime limit, per-agent turn limits, a process cap, and a stuck timer. ## DSL - [Language rules](https://convoyharness.com/docs/dsl.md): The rules of the Convoy language that apply to every block, including file merging, names, value types, durations, strings, and comments. - [swarm](https://convoyharness.com/docs/dsl/swarm.md): The swarm block names the swarm, states its goal, and sets the rules that end it, including done_when, max_runtime, max_cost_usd, and the overseer. - [provider](https://convoyharness.com/docs/dsl/provider.md): A provider block names a provider type with source, sets the attributes that type defines, and gives settings defaults for its agents. Keys are always environment variable names. - [topic](https://convoyharness.com/docs/dsl/topic.md): A topic block declares one channel on the message board, with a one-line description every agent sees. - [agent](https://convoyharness.com/docs/dsl/agent.md): An agent block declares one agent, or several with count or for_each, including its model, prompt, tools, dependencies, topics, output shape, and limits. - [References and functions](https://convoyharness.com/docs/dsl/expressions.md): How blocks refer to each other, which references become dependency edges, the functions the language provides, and when each kind of expression is evaluated. - [Validation rules](https://convoyharness.com/docs/dsl/validation.md): Every error and warning that convoy validate reports, with its diagnostic code, an example, and how to fix it. ## Providers - [Provider types](https://convoyharness.com/docs/providers.md): A provider type is what a provider block's source names. Three are built in; any other is a plugin that its inference provider publishes, and convoyd fetches, holds, and pins to each run. - [Using a provider type](https://convoyharness.com/docs/providers/using.md): Name a third-party provider type in a swarm, see what convoyd resolved, pin and upgrade versions, and set the variables it reads. - [Writing a provider type](https://convoyharness.com/docs/providers/writing.md): How an inference provider publishes a Convoy provider type. The convoy-provider.hcl manifest, presets over a built-in driver, driver plugins on the Python plugin SDK, and how to test and release. ## CLI - [Overview](https://convoyharness.com/docs/cli.md): The convoy CLI is a stateless Go binary. Each command reads the current folder or calls the convoyd API. This page lists the commands, global flags, environment, exit codes, and convoyd's own flags. - [convoy goal](https://convoyharness.com/docs/cli/goal.md): Turn a written goal into a validated set of .cvy and prompt files by asking a model you name, retrying with diagnostics until the files pass. It does not start anything. - [convoy validate](https://convoyharness.com/docs/cli/validate.md): Parse every .cvy file in a folder, resolve references, and check every language rule. Needs no server unless a provider names a type that is not built in. Exits 3 on errors. - [convoy run](https://convoyharness.com/docs/cli/run.md): Validate the folder, send it to convoyd as a bundle, start a new run of the swarm, and exit. The swarm keeps running on the server. - [convoy status](https://convoyharness.com/docs/cli/status.md): Print a run's status, elapsed time, spend against budget, end reason, and one row per agent. Use --json for scripts and --runs for history. - [convoy watch](https://convoyharness.com/docs/cli/watch.md): Stream a run's events and draw a live agent table above a scrolling tail of board messages. Ctrl-C closes the stream and does not affect the swarm. - [convoy say](https://convoyharness.com/docs/cli/say.md): Publish a message to a topic on the swarm's board as the sender human, optionally addressed to one agent to wake it. - [convoy stop](https://convoyharness.com/docs/cli/stop.md): Stop a whole swarm run or a single agent. Stopping a swarm ends its run as Stopped, after which convoy run can start a new one. - [convoy ui](https://convoyharness.com/docs/cli/ui.md): Open convoyd's Web UI in a browser, at the swarm list or at one swarm's latest run. The token is never put in the URL. - [convoy provider](https://convoyharness.com/docs/cli/provider.md): List, show, pull, push, remove, validate, document, and test provider types. Everything that touches installed types is an API call to convoyd; validate and docs work on a local package folder. ## Runtime - [convoyd](https://convoyharness.com/docs/runtime.md): convoyd is the Go server that holds every swarm, run, agent, topic and message. It is the only way anything changes, and it starts one runner process per agent. - [Controller](https://convoyharness.com/docs/runtime/controller.md): The controller is one loop in convoyd that keeps a run's actual state matching its declared state. This page is the full state machine, covering every state, transition, trigger and action. - [Message board](https://convoyharness.com/docs/runtime/board.md): How topics, messages, read cursors, the debounce and the wake long poll work, and what delivery guarantees an agent gets. - [Runner](https://convoyharness.com/docs/runtime/runner.md): The runner is the Python process convoyd starts for each agent. It runs one SDK session, gives it the swarm tools through MCP, and asks the server between turns what is new. - [Swarm tools (MCP)](https://convoyharness.com/docs/runtime/swarm-tools.md): The ten tools every agent gets, plus the overseer's extra one. convoyd serves them over Streamable HTTP MCP, and each is a thin wrapper over a REST handler. - [Web UI](https://convoyharness.com/docs/runtime/web-ui.md): convoyd serves a browser UI on its own port. It shows every swarm and run as a live graph of agents and topics, each agent's reasoning and tool calls, and the message board, with the same controls as the CLI. - [Durability](https://convoyharness.com/docs/runtime/durability.md): What happens when something dies today, what the post-MVP release will guarantee instead, what is stored from day one to make that possible, and the three acceptance tests. ## Architecture - [Overview](https://convoyharness.com/docs/architecture.md): The components of Convoy, what each owns, what talks to what, and the path a convoy run takes from your terminal to a running agent. - [Repository layout](https://convoyharness.com/docs/architecture/repository.md): One repository and one Go module, arranged so that any top-level component can later become its own module or move to its own repository. - [Seams and contracts](https://convoyharness.com/docs/architecture/contracts.md): Every place two Convoy components meet, how each is versioned, and the formats that cross each boundary: the bundle, start.json, check mode, tools.json, provider manifests and the process backend interface. - [HTTP API](https://convoyharness.com/docs/architecture/api.md): Every convoyd endpoint grouped by resource, with method, path, caller, body, responses and errors, plus authentication and the MCP endpoint. ## Examples - [Overview](https://convoyharness.com/docs/examples.md): Three swarms to copy and run with one API key, then five larger ones shaped after long-horizon benchmarks. - [Writer and critic](https://convoyharness.com/docs/examples/writer-critic.md): The smallest useful swarm. Two agents and one loop, in about thirty lines, done when the critic approves. - [Research team](https://convoyharness.com/docs/examples/research-team.md): Three researchers search the web in parallel, a writer turns their findings into a briefing, and an editor sends it back until it scores 8 out of 10. - [Code team](https://convoyharness.com/docs/examples/code-team.md): A planner splits a small project, two coders build their halves at the same time, and a reviewer runs the tests until the whole suite passes. - [PaperBench replication](https://convoyharness.com/docs/examples/paperbench.md): Replicate an ICML 2024 paper from scratch with a reader, four parallel builders, an experimenter, and a judge on a different model. - [Commit0 library](https://convoyharness.com/docs/examples/commit0.md): Rebuild simpy from its spec with a lead, a pool of four implementers, and an integrator, and compare it with a one-agent baseline at the same budget. - [Vending-Bench](https://convoyharness.com/docs/examples/vending-bench.md): Run a vending machine for a simulated year with three agents on three SDKs, a loop that sustains itself through the board, and week-long limits. - [SWE-Lancer bounty](https://convoyharness.com/docs/examples/swe-lancer.md): Three models from three vendors propose, a manager picks, an implementer ships, and QA runs the real end-to-end tests to earn the payout. - [τ²-bench loop](https://convoyharness.com/docs/examples/tau2.md): Improve a customer-service playbook on a train split, then prove the gain on a held-out split that the dependency graph keeps the loop away from. ## Inspiration - [What we borrowed](https://convoyharness.com/docs/inspiration.md): The ideas Convoy takes from Terraform, Kubernetes, and Exo, what it deliberately left behind, and how it relates to durable-execution engines. - [The harness landscape](https://convoyharness.com/docs/inspiration/landscape.md): A sourced summary of thirteen agent-harness products, the four shapes they fall into, and where Convoy sits among them. As of 2026-11-03. ## Optional - [Full docs in one file](https://convoyharness.com/llms-full.txt)