apps
Update app
Update an existing app, identified by its id.
The app name, slug, default branch, and delete protection setting can be changed. Omitted fields are left unchanged. Changing the slug affects the deployment domains generated for this app.
Important: The slug cannot collide with an existing app in the same project. A duplicate slug returns a 409 conflict.
Required Permissions
Your root key must have one of the following permissions:
- app.*.update_app (to update any app)
- app.<app_id>.update_app (to update a specific app)
post/v2/apps.updateApp
Request body
Example request
{
"project": "proj_1234abcd",
"app": "proj_1234abcd",
"name": "Payments API",
"slug": "proj_1234abcd",
"defaultBranch": "main",
"deleteProtection": true
}Response
Successfully updated the app.
Example response
{
"meta": {
"requestId": "req_123"
},
"data": {
"id": "app_1234abcd",
"name": "Payments API",
"slug": "payments-api",
"defaultBranch": "main",
"currentDeploymentId": "d_1234abcd",
"createdAt": 1704067200000,
"updatedAt": 1704153600000
}
}