canonical: https://jentic.com/apis/capy.ai/capy

# Capy API

The Capy API drives Capy's background AI agents: it creates and runs automations, opens threads and sends them messages, and launches Captains whose crews and subagents carry out the work. It streams a thread, task, or subagent so you can follow the agent as it runs, starts AI code reviews and shapes them with review rules and ignore paths, and reports usage and organization users. Projects hold the environment variables agents run against, and threads can be archived, pinned, filed into folders, and handed off between the agent and a human.

## For AI agents

Create and run automations, drive AI agents in threads, start code reviews, and stream their progress across a Capy organization. Every call uses a Capy API key as a bearer token.

## Scope

Does not host, train, or fine-tune language models, and does not store files or send email. Use for running Capy automations, agent threads, and code reviews only.

## Capabilities

- Create automations and enable, disable, flush, or cancel their batches
- Open a thread and send messages that drive a Capy agent
- Stream a thread, task, or subagent to follow an agent's work in real time
- Launch Captains and inspect their crew and daily digest
- Start a code review and shape it with review rules and ignore paths
- Report usage for the billing period and list organization users

## Use cases

### Autonomous Background Agents

Through Jentic, an AI agent creates automations, opens threads, and sends messages to Capy's own background agents, then streams each thread to watch the work land. Every call authenticates with a Capy API key as a bearer token, and a rule can pin the agent to one automation or thread so it drives only the work you intend. The agent finds the operation it needs by intent and calls it directly.

Example prompt: Create an automation, open a thread against it, send the first instruction, and stream the thread until the task reports complete.

### Conversational Agent Threads

A product embeds Capy threads so users converse with an AI agent, send follow-up messages, and interrupt or regenerate a reply. Capy keeps each thread's message history, lets a human take over a thread, and supports pinning, archiving, and filing threads into folders. This runs a chat-style agent surface without building the orchestration from scratch.

Example prompt: Open a thread, send a question, stream the reply, and hand the thread off to a human if the agent cannot resolve it.

### AI Code Review Automation

Capy starts an AI code review and shapes which findings surface using review rules, filter rules, and ignore paths. A review runs in rounds you can poll by request id, and findings can be commented on and assigned. Teams wire this into their change workflow so an agent reviews code against the rules they set.

Example prompt: Start a review, poll its round by request id until it finishes, and list the findings it produced.

## Key endpoints

| Method | Path | Description |
| --- | --- | --- |
| GET | `/api/v1/automations` | List automations |
| POST | `/api/v1/automations` | Create an automation |
| GET | `/api/v1/threads` | List threads |
| POST | `/api/v1/threads` | Create a thread |
| POST | `/api/v1/threads/{threadId}/message` | Send a message to a thread |
| GET | `/api/v1/threads/{threadId}/messages` | List messages in a thread |
| POST | `/api/v1/reviews` | Start a code review |
| GET | `/api/v1/captains` | List Captains |

## Key resources

- **Automations** — Create, enable, disable, delete, and restore automations, and list, flush, or cancel their batches
- **Threads and messages** — Open threads, send and list messages, stream, interrupt, archive, pin, and file threads into folders
- **Captains and subagents** — Launch Captains, inspect their crew and digest, and read subagent messages
- **Reviews** — Start code reviews, manage review rules, filter rules, and ignore paths, and act on findings
- **Usage and users** — Report usage for the billing period and list the organization's users

## AI readiness

This API is usable in Jentic One now. Its AI-readiness score against Jentic's framework shows where it stands today and where improvements would make it even easier for agents to use.

- **Score:** 42 / 100
- **Maturity:** Foundational
- **Dimensions:**
  - Foundational Compliance: 99 / 100
  - Developer Experience & Jentic Compatibility: 63 / 100
  - AI-Readiness & Agent Experience: 19 / 100
  - Agent Usability: 89 / 100
  - Security: 60 / 100
  - AI Discoverability: 44 / 100
- **View full report:** https://jentic.com/apis/capy.ai/capy/scorecard
- **How the score is calculated:** https://docs.jentic.com/reference/api-readiness-framework/overview/
- **More about the dimensions:** https://docs.jentic.com/reference/api-readiness-framework/specification/#dimensional-model-overview

### Score it yourself

Every API in the directory is allowlisted, so you can re-score it with no key required.

- **Score your own API:** https://jentic.com/scorecard.md
- **Scoring CLI agent skill:** https://github.com/jentic/jentic-api-scorecard/blob/main/skills/jentic-api-scorecard/SKILL.md

```sh
npx @jentic/api-scorecard-cli score <openapi-url>
```

## Why Jentic

- **Setup:** Wiring the Capy API by hand means creating a Capy API key, sending it as a bearer token on every call, and tracking ids across automations, threads, tasks, and subagents. Through Jentic you install once, import Capy from the API Directory, store the key once, and your agent calls it.
- **Permission scoping:** Capy puts the automation id and thread id in the URL path, so a rule can pin your agent to one automation or thread and the operations you pick. You choose what it may call, so deleting automations or changing review rules is not included unless you add it.
- **Credential handling:** Your Capy API key is stored once, encrypted, by your own Jentic One instance and injected at execution time. It never enters the agent's prompt, logs, or context.
- **Discovery method:** Agents search Jentic by intent such as 'start a code review' or 'open a thread', and Jentic returns the matching Capy operation with its input schema so the agent calls the right endpoint without browsing the reference docs.

## Related APIs

- **OpenAI** — Chat and reasoning models you call directly for text generation.
- **Replicate** — Run and host open models for inference by version.
- **Linear** — Issue tracking where an agent files and updates the work it produces.

## FAQ

### What authentication does the Capy API use?

The Capy API authenticates with a Capy API key sent as a bearer token in the Authorization header, per its OpenAPI spec. You create the key in Capy under Settings, then every request to automations, threads, and reviews carries it. Through Jentic the key is stored encrypted by your own Jentic One instance and injected only when a call runs.

### Can I run and stream Capy agents through the API?

Yes. You create and run automations, open threads and send them messages, and launch Captains whose subagents do the work. You can stream a thread, task, or subagent to follow progress, and interrupt or hand off a thread when needed.

### What are the rate limits for the Capy API?

The OpenAPI spec does not specify rate limits for the Capy API. Check Capy's own documentation at https://docs.capy.ai for current limits before running an agent against it.

### Can I limit what my agent is allowed to do with the Capy API?

Yes. Write a rule that allows only the thread and message operations for one automation, so the agent can run and follow that work but cannot delete automations, change review rules, or read the organization's users. Every call it makes is logged, and the agent never sees the key itself.

### Is there a Capy MCP server?

You don't need an MCP server to give your agent the Capy API. Jentic connects it directly from the API Directory: import it, store your Capy API key once, and your agent calls the automation, thread, and review operations. You skip loading another server's tool definitions into the agent's context.

### How do I run a Capy agent through Jentic?

Add the Capy API from the Jentic API Directory and store your Capy API key once. Your agent then searches by intent such as 'open a thread and send a message' and Jentic returns the matching operation with its input schema, so it can create an automation and stream the thread. To run it on your own infrastructure, install Jentic One from its GitHub repo.
