Programmatically manage your deployments, projects, and domains using the CupaDev REST API.
All API requests require authentication using an API token.
Include your token in the Authorization header:
Authorization: Bearer YOUR_API_TOKENAll API endpoints are relative to:
https://api.cupadev.com/v1/projectsList all projects
curl -X GET https://api.cupadev.com/v1/projects \ -H "Authorization: Bearer YOUR_TOKEN"
/projects/:idGet a single project
curl -X GET https://api.cupadev.com/v1/projects/abc123 \ -H "Authorization: Bearer YOUR_TOKEN"
/projectsCreate a new project
curl -X POST https://api.cupadev.com/v1/projects \
-H "Authorization: Bearer YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "my-project",
"framework": "nextjs",
"gitUrl": "https://github.com/user/repo"
}'/projects/:id/deploymentsList all deployments for a project
curl -X GET https://api.cupadev.com/v1/projects/abc123/deployments \ -H "Authorization: Bearer YOUR_TOKEN"
/projects/:id/deploymentsTrigger a new deployment
curl -X POST https://api.cupadev.com/v1/projects/abc123/deployments \
-H "Authorization: Bearer YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"branch": "main",
"target": "production"
}'/deployments/:idGet deployment status
curl -X GET https://api.cupadev.com/v1/deployments/dep_abc123 \ -H "Authorization: Bearer YOUR_TOKEN"
/projects/:id/domainsAdd a custom domain
curl -X POST https://api.cupadev.com/v1/projects/abc123/domains \
-H "Authorization: Bearer YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "example.com"
}'/domains/:idRemove a domain
curl -X DELETE https://api.cupadev.com/v1/domains/dom_abc123 \ -H "Authorization: Bearer YOUR_TOKEN"
/projects/:id/envAdd environment variable
curl -X POST https://api.cupadev.com/v1/projects/abc123/env \
-H "Authorization: Bearer YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"key": "API_KEY",
"value": "secret123",
"target": ["production", "preview"]
}'All responses are returned in JSON format:
{
"data": {
"id": "abc123",
"name": "my-project",
"status": "ready"
}
}{
"error": {
"code": "unauthorized",
"message": "Invalid API token"
}
}API requests are rate limited to prevent abuse:
Rate limit headers:
X-RateLimit-Limit: 100X-RateLimit-Remaining: 95X-RateLimit-Reset: 1640000000Use our official SDKs for easier integration:
npm install @cupadev/sdkFull TypeScript support with auto-completion
pip install cupadevPythonic API client with async support