API Reference
The Ancla API is a REST API at https://ancla.dev/api/v1. All endpoints return JSON and require authentication via API key or session.
Base URL
Section titled “Base URL”https://ancla.dev/api/v1Authentication
Section titled “Authentication”Include your API key in the X-API-Key header:
curl -H "X-API-Key: ancla_your_key_here" https://ancla.dev/api/v1/auth/sessionOr use session-based auth via the login endpoint.
Resources
Section titled “Resources”| Resource | Endpoints | Description |
|---|---|---|
| Authentication | 6 | Session, login, logout, CLI auth, OAuth |
| Organizations | 6 | Manage orgs and members |
| Projects | 3 | Create and list projects |
| Applications | 10 | CRUD, scaling, deploy, pipeline status |
| Images | 4 | Build and inspect container images |
| Releases | 5 | Create releases and trigger deploys |
| Deployments | 2 | Inspect deployment status and logs |
| Configuration | 6 | Manage environment variables |
Error responses
Section titled “Error responses”All errors return a JSON body:
{ "status": 404, "message": "not found"}| Status | Meaning |
|---|---|
| 401 | Not authenticated — run ancla login or provide an API key |
| 403 | Permission denied — you don’t have access to this resource |
| 404 | Resource not found |
| 422 | Validation error — check the request body |
| 500 | Server error |