Deployments

List deployments

GET/api/v1/apps/{app}/deployments

Required scope: apps:read

Parameters

NameInRequiredDescription
apppathyesThe app id.
page[size]querynoItems per page (1-100, default 30).
page[cursor]querynoOpaque cursor from a previous response.

Example request

curl https://hangar.nagara.cloud/api/v1/apps/app_123/deployments?account_id=acct_123 \
  -H "Authorization: Bearer hgp_your_token"

Example response

{
  "data": [ { /* ... */ } ],
  "meta": { "per_page": 30, "next_cursor": "eyJ...", "prev_cursor": null },
  "links": { "next": "/api/v1/...?page[cursor]=eyJ...", "prev": null }
}

Trigger a deployment

POST/api/v1/apps/{app}/deployments

Required scope: deploys:write

Parameters

NameInRequiredDescription
apppathyesThe app id.

Example request

curl https://hangar.nagara.cloud/api/v1/apps/app_123/deployments \
  -X POST \
  -H "Authorization: Bearer hgp_your_token" \
  -H "Content-Type: application/json" \
  -d '{"git_sha": "..."}'

Example response

{ "data": {
  "app_id": "app_123",
  "created_at": "2026-01-01T00:00:00Z",
  "deployed_by": "...",
  "finished_at": "2026-01-01T00:00:00Z",
  "git_sha": "...",
  "id": "id_123",
  "image_tag": "...",
  "started_at": "2026-01-01T00:00:00Z",
  "status": "...",
  "version": 1
} }

Get a deployment

GET/api/v1/apps/{app}/deployments/{deployment}

Required scope: apps:read

Parameters

NameInRequiredDescription
apppathyesThe app id.
deploymentpathyesThe deployment id.

Example request

curl https://hangar.nagara.cloud/api/v1/apps/app_123/deployments/deployment_123 \
  -H "Authorization: Bearer hgp_your_token"

Example response

{ "data": {
  "app_id": "app_123",
  "created_at": "2026-01-01T00:00:00Z",
  "deployed_by": "...",
  "finished_at": "2026-01-01T00:00:00Z",
  "git_sha": "...",
  "id": "id_123",
  "image_tag": "...",
  "started_at": "2026-01-01T00:00:00Z",
  "status": "...",
  "version": 1
} }