Skip to main content
The CNAP API is a RESTful API that lets you manage workspaces, clusters, templates, products, and deployments programmatically. It powers the CNAP CLI and can be used to build custom integrations.

Base URL

All API requests are made to:

Authentication

Every request requires a Authorization: Bearer header with either a Personal Access Token (PAT) or a JWT.
Workspace-scoped endpoints also require the X-Workspace-Id header:

Authentication Guide

Learn how to create tokens, authenticate with the CLI, and use JWTs

Conventions

The API uses snake_case for all field names. This keeps responses consistent regardless of the client language and matches the format you see in curl, logs, and debugging tools.

Response Format

Single objects are returned directly — no wrapper:
List responses wrap results in data with pagination:
Error responses use an error envelope:

Pagination

List endpoints support cursor-based pagination with two query parameters: To paginate through results:

Error Codes

Interactive Docs

The API spec is also available as an interactive reference powered by Scalar:

Scalar API Reference

Interactive API explorer with request builder

OpenAPI Spec

Raw OpenAPI 3.1 specification (JSON)

Next Steps

Authentication

Create tokens and learn about supported auth methods

CLI

Install the CNAP CLI for terminal-based workflows

Platform MCP

Let AI agents call the API through Code Mode

AI & Agents

Connect AI tools to CNAP docs and infrastructure