REST API basics
Everything the dashboard does goes through the REST API, and your programs can use the same API.
Address and sign-in
Section titled “Address and sign-in”- Base address:
https://dashboard.sbx09.online/api - Send an API key with every call:
Authorization: Bearer wsla_key_... - Bodies and answers are JSON.
export WSLA_KEY="wsla_key_..."curl -H "Authorization: Bearer $WSLA_KEY" https://dashboard.sbx09.online/api/orgsGET /api/health needs no key and answers with the platform’s version.
Find your organization
Section titled “Find your organization”Almost every address starts with /api/orgs/{org_id}/. GET /api/orgs lists the organizations the key can reach, each with its id.
Common calls
Section titled “Common calls”| What | Call |
|---|---|
| List servers | GET /api/orgs/{org_id}/servers |
| List projects | GET /api/orgs/{org_id}/projects |
| List environments | GET /api/orgs/{org_id}/environments |
| One environment | GET /api/orgs/{org_id}/environments/{environment_id} |
| Deploy | POST /api/orgs/{org_id}/environments/{environment_id}/deploy |
| Back up | POST /api/orgs/{org_id}/environments/{environment_id}/backups |
| List backups | GET /api/orgs/{org_id}/backups |
| List tasks | GET /api/orgs/{org_id}/tasks |
| Monitoring | GET /api/orgs/{org_id}/monitoring |
| Alerts | GET /api/orgs/{org_id}/alerts |
Slow actions return a task
Section titled “Slow actions return a task”A deploy, a backup, a restore or a clone answers at once with status 202 and a task. Follow it:
# start a deploycurl -X POST -H "Authorization: Bearer $WSLA_KEY" -H "Content-Type: application/json" -d '{}' \ https://dashboard.sbx09.online/api/orgs/$ORG/environments/$ENV/deploy
# the task's status, then its logcurl -H "Authorization: Bearer $WSLA_KEY" https://dashboard.sbx09.online/api/tasks/$TASKcurl -H "Authorization: Bearer $WSLA_KEY" https://dashboard.sbx09.online/api/tasks/$TASK/logTo update modules during the deploy, send {"update_modules": "sale,stock"} (or "all").
POST /api/tasks/{task_id}/cancel cancels a task that is still waiting or running.
Deleting takes two calls
Section titled “Deleting takes two calls”Nothing is deleted by one call. First ask for a preview, which lists what would be removed and returns a confirm_token; then send the token:
curl -X POST -H "Authorization: Bearer $WSLA_KEY" \ https://dashboard.sbx09.online/api/orgs/$ORG/environments/$ENV/delete-preview
curl -X POST -H "Authorization: Bearer $WSLA_KEY" -H "Content-Type: application/json" \ -d '{"confirm_token": "..."}' \ https://dashboard.sbx09.online/api/orgs/$ORG/environments/$ENV/deleteProjects and backups are deleted the same way; a restore uses restore-preview and restore.
Errors
Section titled “Errors”A refused call answers with an HTTP error status and a body of this shape:
{ "error": "not_found", "message": "No such environment." }message is a sentence for a person; error is a short code for your program.
What a key may do
Section titled “What a key may do”A read-only key gets every GET; anything that changes something is refused. A key for one project reaches only that project, its environments, their backups and tasks. Every call, allowed or refused, is written to the audit log.

