REST API · projects
POST /projects
Create a project for the authenticated user (needs an account management token with the `config` scope). Body: `{name}`. The slug is derived + validated server-side (format / reserved words / uniqueness). The project serves traffic as soon as the call returns. 201 on success; 422 with an actionable message when the account is at its plan's active-project cap — archive a project or upgrade.
post_api_projects_create
Authentication
- Bearer
Request body
application/json · required
{
"name": "Support desk"
}
Responses
201
The new project.
application/json
{
"project": {
"id": "f47ac10b-58cc-4372-a567-0e02b2c3d479",
"slug": "support-desk",
"name": "Support desk",
"apiBaseUrl": "support-desk.echorelay.cloud",
"archived": false,
"archiveProtected": false
}
}
422
Validation failed, or the account is at its plan's active-project cap.
application/json
{
"required": [
"error"
],
"properties": {
"error": {
"description": "Machine-readable error code, e.g. \"not_found\", \"forbidden\", \"validation\".",
"type": "string",
"enum": [
"bad_request",
"unauthorized",
"insufficient_credits",
"forbidden",
"web_only",
"allowlist_widens",
"not_found",
"conflict",
"draft_revision_conflict",
"rollback_confirmation_conflict",
"not_replayable",
"targets_outside_allowlist",
"gone",
"deprecated_operation",
"validation",
"rate_limited",
"payment_provider",
"verification_unavailable",
"analytics_unavailable",
"credential_vault_unavailable",
"notification_grants_unavailable"
]
},
"message": {
"description": "Human-readable explanation of what went wrong. Absent on a field-level validation failure, where `fields` carries the detail instead.",
"type": "string"
},
"object": {
"description": "The resource the error concerns, when there is one.",
"required": [
"type",
"id"
],
"properties": {
"type": {
"type": "string"
},
"id": {
"type": "string"
}
},
"type": "object"
},
"action": {
"description": "What to do next, naming the call or the panel page that does it. Absent when there is no corrective step.",
"type": "string"
},
"fields": {
"description": "Present when `error` is \"validation\" — one message per rejected field, keyed by the field name.",
"type": "object",
"additionalProperties": {
"type": "string"
}
},
"retry_after": {
"description": "An RFC 3339 timestamp, the moment the request may be retried. Not every `rate_limited` refusal carries one.",
"type": "string",
"format": "date-time"
}
},
"type": "object"
}