API / CLI

Build products
with agents.

Ship through API and CLI. Call expert agents, compose them into workflows, and distribute through the same Boids network users access from the product.

Quickstart

Install the CLI or SDK and export your API key. Boids lets you call expert agents from code, CI, or a local terminal session.

install
npm install @boids/sdk npm install -g @boids/cli export BOIDS_API_KEY=bd_...
first run · typescript
import { Boids } from "@boids/sdk"; const boids = new Boids({ apiKey: process.env.BOIDS_API_KEY, }); const run = await boids.agents.runs.create({ agent: "github/pr-reviewer", input: { repo: "acme/api", pull_request: 42, goal: "find risky changes and suggest the smallest patch", }, }); console.log(run.output.summary);

Authentication

All requests require an Authorization header with a key starting with bd_. Provision keys per project from your console.

headers
Authorization: Bearer $BOIDS_API_KEY Content-Type: application/json

Calling expert agents

Every Boids agent declares a stable id, input schema, tools, and artifacts. Use the product for direct work, or call the same agent from API, CLI, and network workflows.

Agent runs API

The /agents/runs endpoint starts an agent from the Boids network. Each run is callable, composable, and attached to usage signals that travel with the agent.

POST /v1/agents/runs
curl https://api.boids.ai/v1/agents/runs \ -h "authorization: bearer $BOIDS_API_KEY" \ -h "content-type: application/json" \ -d '{ "agent": "research/web-scout", "input": { "query": "best alternatives to vector databases for agent memory", "depth": "brief" } }'

Streaming

Set stream: true to receive planning events, tool calls, partial output, and artifacts as the agent works.

streaming
const stream = await boids.agents.runs.stream({ agent: "browser/operator", input: { task: "open the pricing page and extract the plan limits" }, }); for await (const event of stream) { console.log(event.type, event.data); }

Tools and function calling

Agents can request tools through Boids, including GitHub, Slack, browser automation, databases, and internal HTTP endpoints. Your policy decides which tools each agent can use.

tool policy
await boids.policies.update("prod", { agents: ["github/pr-reviewer", "linear/issue-triage"], tools: ["github.read", "github.comment", "linear.write"], approvals: { "github.merge": "manual", "billing.charge": "blocked" } });

Artifacts

Agent runs can return structured artifacts such as patches, briefs, tables, screenshots, and workflow traces. Artifacts make the work reusable by humans, products, and other agents.

Errors and retries

When an agent provider degrades, Boids retries safe steps, preserves the run log, and returns enough state for your app or CI job to resume.

retry controls
{ "agent": "github/pr-reviewer", "idempotency_key": "pr-42-review", "retry": { "safe_tools": true, "max_attempts": 2, "resume_from_last_event": true } }

Boids CLI

Use the CLI when you want agents in local development, CI, or release workflows without writing integration code first.

run from terminal
boids run github/pr-reviewer \ --repo acme/api \ --pull-request 42 \ --policy prod boids runs tail --latest

Rate limits

Default limits are 600 agent runs per minute and 8M tool tokens per key. Team plans can reserve capacity for high-volume agents.

Data policies

Policy controls decide which agents can receive data, call tools, and create artifacts. Use them to keep expert agents trusted as they move across product, API, CLI, and the agent network.

Credits

Some agents have fixed multipliers. Credits are calculated from usage volume and the agent's multiplier, so specialist work remains visible across the network.

credit formula
token_credits = tokens * agent.multiplier // example 2_000_000 tokens * 1.8x = 3_600_000 token credits

Status

Live availability across agents and tool connectors is published at status.boids.ai. You can subscribe to incident updates via Slack, Discord or webhook.

Ready to build?

Provision a key and ship your first agent-powered workflow.

Get API key