Promote deployment to production
POST
/api/v1/projects/{id}/promote
const url = 'https://api.deploybase.eu/api/v1/api/v1/projects/example/promote';const options = { method: 'POST', headers: {Authorization: '<Authorization>', 'Content-Type': 'application/json'}, body: '{"deployment_id":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.deploybase.eu/api/v1/api/v1/projects/example/promote \ --header 'Authorization: <Authorization>' \ --header 'Content-Type: application/json' \ --data '{ "deployment_id": "example" }'Points production at a different deployment. Instant, no rebuild. Used for rollback.
Authorizations
Section titled “ Authorizations ”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “ Path Parameters ” id
required
string
Project ID (UUID)
Request Body
Section titled “ Request Body ”Deployment to promote
Media type application/json
object
deployment_id
required
string
Example generated
{ "deployment_id": "example"}Responses
Section titled “ Responses ”OK
Media type application/json
object
data
meta
object
request_id
string
timestamp
string
trace_id
string
data
object
auto_deploy_enabled
Auto-deploy (GitHub webhook) fields
boolean
build_command
string
bunny_edge_rule_guid
string
bunny_not_found_edge_rule_guid
string
bunny_pull_zone_id
integer
created_at
string
default_branch
string
framework
string
git_connection_id
Optional FK to team_git_connections; nil = manual PAT
string
git_provider
string
git_repo_url
string
id
string
live_deployment_id
string
mr_previews_enabled
MRPreviewsEnabled governs merge/pull-request previews on its own: the branch policy above never applies to an MR event.
boolean
name
string
output_dir
string
package_manager
PackageManager overrides the Node package manager used at build time. nil = auto-detect (lockfile / packageManager field); set = user override.
string
preview_branch_exclude
Array<string>
preview_branch_include
Array<string>
preview_branch_mode
Preview branch policy (DEP-287). Decides which webhook pushes auto-build a preview; see ShouldAutoBuildBranch in preview_branch_policy.go. Nothing here touches manual/API/MCP/ZIP deploys, and the default branch is never filtered.
string
production_url
string
root_directory
string
slug
string
status
string
subdomain
Production URL fields
string
team_id
string
updated_at
string
Example
{ "data": { "framework": "nextjs", "package_manager": "npm", "preview_branch_mode": "all", "status": "active" }}Bad Request
Media type application/json
object
code
string
details
error
string
meta
object
request_id
string
timestamp
string
trace_id
string
Example generated
{ "code": "example", "details": "example", "error": "example", "meta": { "request_id": "example", "timestamp": "example", "trace_id": "example" }}Not Found
Media type application/json
object
code
string
details
error
string
meta
object
request_id
string
timestamp
string
trace_id
string
Example generated
{ "code": "example", "details": "example", "error": "example", "meta": { "request_id": "example", "timestamp": "example", "trace_id": "example" }}