AppDeployment
A deployment of a hosted app: list, start, read or cancel one.
Operations
Every route this entity exposes. Each route links to its own reference on this page.
| Method | Route | SDK operation | Returns |
|---|---|---|---|
POST |
/api/v1/hosting/apps/{app_id}/deployments/{id}/cancel |
create |
Updated app deployment |
POST |
/api/v1/hosting/apps/{app_id}/deployments/{id}/fail |
create |
Updated app deployment |
POST |
/api/v1/hosting/apps/{app_id}/deployments/{id}/succeed |
create |
Updated app deployment |
POST |
/api/v1/hosting/apps/{app_id}/deployments |
create |
App deployment created |
GET |
/api/v1/hosting/apps/{app_id}/deployments/{id} |
load |
Success |
GET |
/api/v1/hosting/apps/{app_id}/deployments/{deployment_id}/live |
load |
Success |
GET |
/api/v1/hosting/apps/{app_id}/deployments |
load |
Success |
PATCH |
/api/v1/hosting/apps/{app_id}/deployments/{id} |
patch |
Success |
DELETE |
/api/v1/hosting/apps/{app_id}/deployments/{id} |
remove |
Success |
PUT |
/api/v1/hosting/apps/{app_id}/deployments/{id} |
update |
Success |
Examples
One example per SDK, generated from the API model. The argument names are the parameters and fields of this entity, and the values are placeholders. The examples are not compiled or executed.
Golang
Construct client as shown in the Golang setup, then call the operations:
app_deployment, err := client.AppDeployment(nil).Load(map[string]any{"app_id": "example"}, nil)
if err != nil {
panic(err)
}
fmt.Println(app_deployment)
created, err := client.AppDeployment(nil).Create(map[string]any{"app_id": "example"}, nil)
if err != nil {
panic(err)
}
fmt.Println(created)
updated, err := client.AppDeployment(nil).Update(map[string]any{"id": "example_id", "app_id": "example"}, nil)
if err != nil {
panic(err)
}
fmt.Println(updated)
patched, err := client.AppDeployment(nil).Patch(map[string]any{"id": "example_id", "app_id": "example"}, nil)
if err != nil {
panic(err)
}
fmt.Println(patched)
removed, err := client.AppDeployment(nil).Remove(map[string]any{"app_id": "example", "id": "example_id"}, nil)
if err != nil {
panic(err)
}
fmt.Println(removed)
Lua
Construct client as shown in the Lua setup, then call the operations:
local app_deployment, err = client:AppDeployment():load({ app_id = "example" })
local created, err = client:AppDeployment():create({ app_id = "example" })
local updated, err = client:AppDeployment():update({ id = "example_id", app_id = "example" })
local patched, err = client:AppDeployment():patch({ id = "example_id", app_id = "example" })
local removed, err = client:AppDeployment():remove({ app_id = "example", id = "example_id" })
PHP
Construct client as shown in the PHP setup, then call the operations:
$app_deployment = $client->AppDeployment()->load(["app_id" => "example"]);
$created = $client->AppDeployment()->create(["app_id" => "example"]);
$updated = $client->AppDeployment()->update(["id" => "example_id", "app_id" => "example"]);
$patched = $client->AppDeployment()->patch(["id" => "example_id", "app_id" => "example"]);
$client->AppDeployment()->remove(["app_id" => "example", "id" => "example_id"]);
Python
Construct client as shown in the Python setup, then call the operations:
app_deployment = client.AppDeployment().load({"app_id": "example"})
created = client.AppDeployment().create({ "app_id": "example" })
updated = client.AppDeployment().update({"id": "example_id", "app_id": "example"})
patched = client.AppDeployment().patch({"id": "example_id", "app_id": "example"})
client.AppDeployment().remove({"app_id": "example", "id": "example_id"})
Ruby
Construct client as shown in the Ruby setup, then call the operations:
app_deployment = client.AppDeployment.load({ "app_id" => "example" })
created = client.AppDeployment.create({ "app_id" => "example" })
updated = client.AppDeployment.update({ "id" => "example_id", "app_id" => "example" })
patched = client.AppDeployment.patch({ "id" => "example_id", "app_id" => "example" })
client.AppDeployment.remove({ "app_id" => "example", "id" => "example_id" })
TypeScript
Construct client as shown in the TypeScript setup, then call the operations:
const app_deployment = await client.AppDeployment().load({ app_id: "example" })
const created = await client.AppDeployment().create({ app_id: "example" })
const updated = await client.AppDeployment().update({ id: "example_id", app_id: "example" })
const patched = await client.AppDeployment().patch({ id: "example_id", app_id: "example" })
await client.AppDeployment().remove({ app_id: "example", id: "example_id" })
Fields
| Field | Type | Required | Description |
|---|---|---|---|
app_environment_id |
string |
Yes | App Environment Id |
app_service_id |
string |
Yes | App Service Id |
app_service_placement_id |
string |
No | App Service Placement Id |
artifact_locator |
one,string,null |
Yes | Artifact Locator |
build_role |
one,string,null |
Yes | Build Role |
commit_sha |
one,string,null |
Yes | Commit Sha |
created_at |
string |
Yes | Created At |
created_at_label |
one,string,null |
Yes | Created At Label |
creator_user_id |
one,string,null |
Yes | Creator User Id |
deployed_url |
one,string,null |
Yes | Deployed Url |
display_id |
integer |
Yes | Display Id |
failure_message |
one,string,null |
Yes | Failure Message |
finished_at |
one,string,null |
Yes | Finished At |
finished_at_label |
one,string,null |
Yes | Finished At Label |
hosted_app_id |
string |
Yes | Hosted App Id |
id |
string |
Yes | Id |
idempotency_key |
one,string,null |
Yes | Idempotency Key |
is_rollback |
boolean |
Yes | Is Rollback |
location |
any |
Yes | Location |
location_id |
string |
Yes | Location Id |
number |
integer |
Yes | Number |
operation_key |
one,string,null |
Yes | Operation Key |
organization_id |
string |
Yes | Organization Id |
rollback_reason |
one,string,null |
Yes | Rollback Reason |
rollback_source_deployment_id |
one,string,null |
Yes | Rollback Source Deployment Id |
rollback_source_release_id |
one,string,null |
Yes | Rollback Source Release Id |
rollback_target_release_id |
one,string,null |
Yes | Rollback Target Release Id |
source_ref |
one,string,null |
Yes | Source Ref |
started_at |
one,string,null |
Yes | Started At |
started_at_label |
one,string,null |
Yes | Started At Label |
status |
string |
Yes | Status |
trigger_kind |
string |
Yes | Trigger Kind |
updated_at |
string |
Yes | Updated At |
updated_at_label |
one,string,null |
Yes | Updated At Label |
create
POST /api/v1/hosting/apps/{app_id}/deployments/{id}/cancel
Operation ID: cancel_api_v1_app_deployment.
Authentication: bearer token (bearerAuth).
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
app_id |
path |
string |
Yes | |
id |
path |
string |
Yes |
Request body
application/json
The request body is object.
Responses
200: Updated app deployment
application/json
| Property | Type | Required | Description |
|---|---|---|---|
deployment |
object |
Yes | |
deployment.app_environment_id |
string |
Yes | |
deployment.app_service_id |
string |
Yes | |
deployment.artifact_locator |
string |
Yes | |
deployment.build_role |
enum: leader, follower, standalone |
Yes | |
deployment.commit_sha |
string |
Yes | |
deployment.created_at |
string (date-time) |
Yes | |
deployment.created_at_label |
string |
Yes | |
deployment.creator_user_id |
string |
Yes | |
deployment.deployed_url |
string |
Yes | |
deployment.display_id |
integer |
Yes | |
deployment.failure_message |
string |
Yes | |
deployment.finished_at |
string (date-time) |
Yes | |
deployment.finished_at_label |
string |
Yes | |
deployment.hosted_app_id |
string |
Yes | |
deployment.id |
string |
Yes | |
deployment.idempotency_key |
string |
Yes | |
deployment.is_rollback |
boolean |
Yes | |
deployment.location |
object or null |
Yes | |
deployment.location_id |
string |
Yes | |
deployment.number |
integer |
Yes | |
deployment.operation_key |
string |
Yes | |
deployment.organization_id |
string |
Yes | |
deployment.rollback_reason |
string |
Yes | |
deployment.rollback_source_deployment_id |
string |
Yes | |
deployment.rollback_source_release_id |
string |
Yes | |
deployment.rollback_target_release_id |
string |
Yes | |
deployment.source_ref |
string |
Yes | |
deployment.started_at |
string (date-time) |
Yes | |
deployment.started_at_label |
string |
Yes | |
deployment.status |
enum: queued, building, deploying, active, failed, rolled_back, ... |
Yes | |
deployment.trigger_kind |
enum: manual, push, schedule, api, rollback |
Yes | |
deployment.updated_at |
string (date-time) |
Yes | |
deployment.updated_at_label |
string |
Yes |
401: Unauthorized
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway
POST /api/v1/hosting/apps/{app_id}/deployments/{id}/fail
Operation ID: fail_api_v1_app_deployment.
Authentication: bearer token (bearerAuth).
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
app_id |
path |
string |
Yes | |
id |
path |
string |
Yes |
Request body
application/json
The request body is object.
Responses
200: Updated app deployment
application/json
| Property | Type | Required | Description |
|---|---|---|---|
deployment |
object |
Yes | |
deployment.app_environment_id |
string |
Yes | |
deployment.app_service_id |
string |
Yes | |
deployment.artifact_locator |
string |
Yes | |
deployment.build_role |
enum: leader, follower, standalone |
Yes | |
deployment.commit_sha |
string |
Yes | |
deployment.created_at |
string (date-time) |
Yes | |
deployment.created_at_label |
string |
Yes | |
deployment.creator_user_id |
string |
Yes | |
deployment.deployed_url |
string |
Yes | |
deployment.display_id |
integer |
Yes | |
deployment.failure_message |
string |
Yes | |
deployment.finished_at |
string (date-time) |
Yes | |
deployment.finished_at_label |
string |
Yes | |
deployment.hosted_app_id |
string |
Yes | |
deployment.id |
string |
Yes | |
deployment.idempotency_key |
string |
Yes | |
deployment.is_rollback |
boolean |
Yes | |
deployment.location |
object or null |
Yes | |
deployment.location_id |
string |
Yes | |
deployment.number |
integer |
Yes | |
deployment.operation_key |
string |
Yes | |
deployment.organization_id |
string |
Yes | |
deployment.rollback_reason |
string |
Yes | |
deployment.rollback_source_deployment_id |
string |
Yes | |
deployment.rollback_source_release_id |
string |
Yes | |
deployment.rollback_target_release_id |
string |
Yes | |
deployment.source_ref |
string |
Yes | |
deployment.started_at |
string (date-time) |
Yes | |
deployment.started_at_label |
string |
Yes | |
deployment.status |
enum: queued, building, deploying, active, failed, rolled_back, ... |
Yes | |
deployment.trigger_kind |
enum: manual, push, schedule, api, rollback |
Yes | |
deployment.updated_at |
string (date-time) |
Yes | |
deployment.updated_at_label |
string |
Yes |
401: Unauthorized
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway
POST /api/v1/hosting/apps/{app_id}/deployments/{id}/succeed
Operation ID: succeed_api_v1_app_deployment.
Authentication: bearer token (bearerAuth).
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
app_id |
path |
string |
Yes | |
id |
path |
string |
Yes |
Request body
application/json
The request body is object.
Responses
200: Updated app deployment
application/json
| Property | Type | Required | Description |
|---|---|---|---|
deployment |
object |
Yes | |
deployment.app_environment_id |
string |
Yes | |
deployment.app_service_id |
string |
Yes | |
deployment.artifact_locator |
string |
Yes | |
deployment.build_role |
enum: leader, follower, standalone |
Yes | |
deployment.commit_sha |
string |
Yes | |
deployment.created_at |
string (date-time) |
Yes | |
deployment.created_at_label |
string |
Yes | |
deployment.creator_user_id |
string |
Yes | |
deployment.deployed_url |
string |
Yes | |
deployment.display_id |
integer |
Yes | |
deployment.failure_message |
string |
Yes | |
deployment.finished_at |
string (date-time) |
Yes | |
deployment.finished_at_label |
string |
Yes | |
deployment.hosted_app_id |
string |
Yes | |
deployment.id |
string |
Yes | |
deployment.idempotency_key |
string |
Yes | |
deployment.is_rollback |
boolean |
Yes | |
deployment.location |
object or null |
Yes | |
deployment.location_id |
string |
Yes | |
deployment.number |
integer |
Yes | |
deployment.operation_key |
string |
Yes | |
deployment.organization_id |
string |
Yes | |
deployment.rollback_reason |
string |
Yes | |
deployment.rollback_source_deployment_id |
string |
Yes | |
deployment.rollback_source_release_id |
string |
Yes | |
deployment.rollback_target_release_id |
string |
Yes | |
deployment.source_ref |
string |
Yes | |
deployment.started_at |
string (date-time) |
Yes | |
deployment.started_at_label |
string |
Yes | |
deployment.status |
enum: queued, building, deploying, active, failed, rolled_back, ... |
Yes | |
deployment.trigger_kind |
enum: manual, push, schedule, api, rollback |
Yes | |
deployment.updated_at |
string (date-time) |
Yes | |
deployment.updated_at_label |
string |
Yes |
401: Unauthorized
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway
POST /api/v1/hosting/apps/{app_id}/deployments
Operation ID: post_api_v1_hosting_apps_app_id_deployments.
Authentication: bearer token (bearerAuth).
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
app_id |
path |
string |
Yes |
Request body
application/json
| Property | Type | Required | Description |
|---|---|---|---|
app_environment_id |
string |
No | |
app_service_id |
string |
No | |
app_service_placement_id |
string |
No | |
artifact_locator |
string |
No | |
commit_sha |
string |
No | |
deployed_url |
string |
No | |
failure_message |
string |
No | |
finished_at |
string (date-time) |
No | |
location_id |
string |
No | |
source_ref |
string |
No | |
started_at |
string (date-time) |
No | |
status |
enum: queued, building, deploying, active, failed, rolled_back, ... |
No | |
trigger_kind |
enum: manual, push, schedule, api, rollback |
No |
Responses
200: App deployment created
application/json
| Property | Type | Required | Description |
|---|---|---|---|
deployment |
object |
Yes | |
deployment.app_environment_id |
string |
Yes | |
deployment.app_service_id |
string |
Yes | |
deployment.artifact_locator |
string |
Yes | |
deployment.build_role |
enum: leader, follower, standalone |
Yes | |
deployment.commit_sha |
string |
Yes | |
deployment.created_at |
string (date-time) |
Yes | |
deployment.created_at_label |
string |
Yes | |
deployment.creator_user_id |
string |
Yes | |
deployment.deployed_url |
string |
Yes | |
deployment.display_id |
integer |
Yes | |
deployment.failure_message |
string |
Yes | |
deployment.finished_at |
string (date-time) |
Yes | |
deployment.finished_at_label |
string |
Yes | |
deployment.hosted_app_id |
string |
Yes | |
deployment.id |
string |
Yes | |
deployment.idempotency_key |
string |
Yes | |
deployment.is_rollback |
boolean |
Yes | |
deployment.location |
object or null |
Yes | |
deployment.location_id |
string |
Yes | |
deployment.number |
integer |
Yes | |
deployment.operation_key |
string |
Yes | |
deployment.organization_id |
string |
Yes | |
deployment.rollback_reason |
string |
Yes | |
deployment.rollback_source_deployment_id |
string |
Yes | |
deployment.rollback_source_release_id |
string |
Yes | |
deployment.rollback_target_release_id |
string |
Yes | |
deployment.source_ref |
string |
Yes | |
deployment.started_at |
string (date-time) |
Yes | |
deployment.started_at_label |
string |
Yes | |
deployment.status |
enum: queued, building, deploying, active, failed, rolled_back, ... |
Yes | |
deployment.trigger_kind |
enum: manual, push, schedule, api, rollback |
Yes | |
deployment.updated_at |
string (date-time) |
Yes | |
deployment.updated_at_label |
string |
Yes |
201: App deployment created
application/json
| Property | Type | Required | Description |
|---|---|---|---|
deployment |
object |
Yes | |
deployment.app_environment_id |
string |
Yes | |
deployment.app_service_id |
string |
Yes | |
deployment.artifact_locator |
string |
Yes | |
deployment.build_role |
enum: leader, follower, standalone |
Yes | |
deployment.commit_sha |
string |
Yes | |
deployment.created_at |
string (date-time) |
Yes | |
deployment.created_at_label |
string |
Yes | |
deployment.creator_user_id |
string |
Yes | |
deployment.deployed_url |
string |
Yes | |
deployment.display_id |
integer |
Yes | |
deployment.failure_message |
string |
Yes | |
deployment.finished_at |
string (date-time) |
Yes | |
deployment.finished_at_label |
string |
Yes | |
deployment.hosted_app_id |
string |
Yes | |
deployment.id |
string |
Yes | |
deployment.idempotency_key |
string |
Yes | |
deployment.is_rollback |
boolean |
Yes | |
deployment.location |
object or null |
Yes | |
deployment.location_id |
string |
Yes | |
deployment.number |
integer |
Yes | |
deployment.operation_key |
string |
Yes | |
deployment.organization_id |
string |
Yes | |
deployment.rollback_reason |
string |
Yes | |
deployment.rollback_source_deployment_id |
string |
Yes | |
deployment.rollback_source_release_id |
string |
Yes | |
deployment.rollback_target_release_id |
string |
Yes | |
deployment.source_ref |
string |
Yes | |
deployment.started_at |
string (date-time) |
Yes | |
deployment.started_at_label |
string |
Yes | |
deployment.status |
enum: queued, building, deploying, active, failed, rolled_back, ... |
Yes | |
deployment.trigger_kind |
enum: manual, push, schedule, api, rollback |
Yes | |
deployment.updated_at |
string (date-time) |
Yes | |
deployment.updated_at_label |
string |
Yes |
401: Unauthorized
402: The organization's billing limit refuses this usage; see error.upgrade_path
application/json
| Property | Type | Required | Description |
|---|---|---|---|
error |
object |
Yes | |
error.code |
enum: billing_limit_exceeded |
Yes | |
error.dimension_value |
string,null |
Yes | |
error.limit |
number or string |
Yes | Decimal quantities are serialized as strings |
error.message |
string |
Yes | |
error.meter_key |
string |
Yes | A billing meter key |
error.reason |
enum: payment_required, hard_cap, allowance_exhausted, budget_exhausted, suspended, seat_limit |
Yes | |
error.requested |
number or string |
Yes | |
error.upgrade_path |
string |
Yes | Frontend path of the organization's billing page |
403: Forbidden
404: Not found
422: Deployment request failed validation
application/json
| Property | Type | Required | Description |
|---|---|---|---|
details |
array of string |
No | |
error |
string |
Yes |
502: Bad gateway
load
GET /api/v1/hosting/apps/{app_id}/deployments/{id}
Operation ID: api_v1_app_deployment.
Authentication: bearer token (bearerAuth).
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
app_id |
path |
string |
Yes | |
id |
path |
string |
Yes |
Responses
200: Success
application/json
The response is object.
401: Unauthorized
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway
GET /api/v1/hosting/apps/{app_id}/deployments/{deployment_id}/live
Operation ID: get_api_v1_hosting_apps_app_id_deployments_deployment_id_live.
Authentication: bearer token (bearerAuth).
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
app_id |
path |
string |
Yes | |
deployment_id |
path |
string |
Yes |
Responses
200: Success
application/json
The response is object.
401: Unauthorized
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway
GET /api/v1/hosting/apps/{app_id}/deployments
Operation ID: api_v1_app_deployments.
Authentication: bearer token (bearerAuth).
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
app_id |
path |
string |
Yes |
Responses
200: Success
application/json
The response is object.
401: Unauthorized
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway
patch
PATCH /api/v1/hosting/apps/{app_id}/deployments/{id}
Operation ID: patch_api_v1_hosting_apps_app_id_deployments_id_.
Authentication: bearer token (bearerAuth).
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
app_id |
path |
string |
Yes | |
id |
path |
string |
Yes |
Request body
application/json
The request body is object.
Responses
200: Success
application/json
The response is object.
401: Unauthorized
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway
remove
DELETE /api/v1/hosting/apps/{app_id}/deployments/{id}
Operation ID: delete_api_v1_hosting_apps_app_id_deployments_id_.
Authentication: bearer token (bearerAuth).
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
app_id |
path |
string |
Yes | |
id |
path |
string |
Yes |
Responses
200: Success
application/json
The response is object.
401: Unauthorized
403: Forbidden
404: Not found
422: Unprocessable entity
502: Bad gateway
update
PUT /api/v1/hosting/apps/{app_id}/deployments/{id}
Operation ID: put_api_v1_hosting_apps_app_id_deployments_id_.
Authentication: bearer token (bearerAuth).
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
app_id |
path |
string |
Yes | |
id |
path |
string |
Yes |
Request body
application/json
The request body is object.
Responses
200: Success
application/json
The response is object.