Skip to main content
The Platform API exposes CodeRabbit’s existing product operations through JSON over HTTPS, coderabbit api, and hosted MCP. Use the REST base URL for your organization’s region: https://api.coderabbit.ai/v1 for the US or https://api.eu.coderabbit.ai/v1 for the EU. Examples below use the US base URL. Hosted MCP is available only in the US. Start with authentication and scope selection, then follow a practical workflow. The API reference generates request fields, response schemas, and examples directly from OpenAPI.

Availability

The shared Platform API supports GitHub Cloud organizations. Self-hosted instances are not included. Existing public REST endpoints keep their endpoint-specific provider, region, and key requirements. Product eligibility still applies. API access does not enable a feature for an organization that cannot already use it. Existing role, repository, billing, and product checks apply to every operation.

API surfaces

Operations use the existing product owners. An accepted request is not a guarantee that asynchronous work completed. Follow the relevant task, job, scan, command receipt, or review observation returned by the operation. Shared role operations use /v1/configuration/roles through REST, CLI, and MCP with existing permissions and Enterprise requirements. These operations return the shared role schemas described in the API reference.

Use any operation from the CLI

Use CodeRabbit CLI 0.9.4 or later for generic API mode. request accepts an API-relative path; omit /v1 because the CLI supplies it.
For a write, provide a JSON file. --input selects POST by default; use --method for another method.
The CLI prints the server’s JSON and sets a nonzero exit status for HTTP errors. It also provides repository commands and pull-request commands. Generic API mode does not change the authentication rules of dedicated coderabbit code or local-review commands.

Use hosted MCP

Hosted MCP exposes the shared operations as tools with the same input and output schemas for US organizations. The connection is bound to the approved organization and user. New tools require their requested read or write consent scopes; reconnect and approve the additional scopes when needed. Local code review retains the existing CLI/MCP handoff. The existing URL-based pull-request tools retain their advertised inputs. Always use the tool schema shown by your client rather than converting a REST example mechanically.

Boundaries

  • Pull-request reviews target the current head. The API does not cancel PR reviews, restart a review at an older commit, or resolve review threads. Thread reads remain available. Coding-turn cancellation is a separate supported product action.
  • Full workspace configuration replacement, budget changes, payment flows, and provider OAuth or consent steps remain browser handoffs where required by the existing product.
  • Architecture knowledge under /knowledge/architecture provides read-only access to the generated codebase knowledge used by CodeRabbit. Its organization scope aggregates architecture across repositories; it is separate from organization knowledge gathered through messaging apps. /knowledge/organization is reserved for that separate knowledge family and has no operations in this API release.
  • Architecture knowledge supports repository and document reads. It does not provide arbitrary standalone-document CRUD.
  • Triage’s latest_commit_at is currently null; do not interpret another observation timestamp as the commit time.
  • Some existing endpoints remain key-authenticated REST operations rather than shared MCP tools: review/comment/MCP metrics, legacy bug-scan findings, and user-role changes. Use their existing reference and permitted key types. coderabbit api request can call them without expanding their backend permissions. Read seat_assignment_mode from GET /users; the self-hosted mode update remains POST /users/seats/assignment.

Errors and asynchronous results

Shared operations return an error object with a stable code and a readable message. Branch on the code, not the message. Rate-limited REST requests, including CLI API mode, receive HTTP 429; use Retry-After and error.retry_after to wait before retrying. Hosted MCP returns an isError tool result with rate_limit_exceeded and retry_after; its HTTP status may remain 200. Existing legacy workspace-wide endpoints retain their documented quota scope. A 404 can mean the resource or operation is unavailable to the caller. Use each response’s documented pagination fields. For token-based pagination, continue until the continuation token is null; other operations use page numbers. Missing usage, progress, or review observations mean unknown, not zero or completion. Existing public REST endpoints can retain their own response and error formats. See their individual references.

What’s next

Authenticate to the API

Select a credential, organization, and MCP consent scopes.

Try an API workflow

Follow examples for pull-request reads, coding tasks, and product operations.