The OneCLI API gives you programmatic access to manage your agents, secrets, policy rules, and app connections.Documentation Index
Fetch the complete documentation index at: https://onecli.sh/docs/llms.txt
Use this file to discover all available pages before exploring further.
Base URL
Authentication
All API endpoints require authentication. Include your API key as a Bearer token in theAuthorization header:
Getting your API key
- Open the OneCLI dashboard
- Go to Settings and copy your API key
oc_ and are scoped to a single project.
Organization-scoped keys
Organization API keys start withoc_org_ and can operate across projects. Include the X-Project-Id header to specify which project:
Errors
The API returns standard HTTP status codes. Error responses include a JSON body with anerror field:
| Status | Meaning |
|---|---|
400 | Validation error or bad request |
401 | Missing or invalid authentication |
404 | Resource not found |
409 | Conflict (e.g., duplicate identifier) |