Releases endpoints

Group scripts into releases, sign them off, and run or promote them through a pipeline. Paths are relative to the address of your Simcha DB Studio server.

Through the MCP server these endpoints are the Releases tool group, on by default.

While this group is on, the MCP server also offers the lookups its tools need: scripts_list (List migration scripts, from Migration Scripts), environments_list (List environments, from Environments and Groupings), groupings_list (List groupings, from Environments and Groupings), pipelines_list (List release pipelines, from Release Pipelines), pipelines_get (Get a release pipeline, from Release Pipelines).

MethodPathWhat it does
GET/api/db-devops/releasesList releases
GET/api/db-devops/releases/:idGet a release
GET/api/db-devops/releases/:id/scriptsList the scripts in a release
GET/api/db-devops/releases/:id/runsList the runs of a release
POST/api/db-devops/releasesCreate a release
PUT/api/db-devops/releases/:idChange a release
DELETE/api/db-devops/releases/:idDelete a release
POST/api/db-devops/releases/:id/signoffSign off a release
GET/api/db-devops/releases/:id/stagesShow the pipeline stages of a release
POST/api/db-devops/releases/:id/promotePromote a release to its next stage
GET/api/db-devops/releases/:id/rollbackShow what rolling back a release run would undo
POST/api/db-devops/releases/:id/rollbackRoll back a release run
POST/api/db-devops/releases/:id/stages/:position/retryRetry a pipeline stage

GET /api/db-devops/releases

Lists the releases the caller can see, with their sign-off status and pipeline.

Reads only · Role: Any signed-in user · MCP tool: releases_list

No inputs.

GET /api/db-devops/releases/:id

Returns one release with its sign-off status, the scripts fixed at sign-off and its pipeline.

Reads only · Role: Any signed-in user · MCP tool: releases_get

InputTypeDescription
id (path)string (uuid), requiredThe release ID

GET /api/db-devops/releases/:id/scripts

Lists the scripts in a release in run order.

Reads only · Role: Any signed-in user · MCP tool: releases_scripts

InputTypeDescription
id (path)string (uuid), requiredThe release ID

GET /api/db-devops/releases/:id/runs

Lists every run of a release. A run on several databases also shows its batch ID and how many databases it reached, failed on or did not run on.

Reads only · Role: Any signed-in user · MCP tool: releases_runs

InputTypeDescription
id (path)string (uuid), requiredThe release ID

POST /api/db-devops/releases

Creates a release that is pending sign-off. Sign-off fields cannot be set here.

Changes data · Role: Release manager or admin · MCP tool: releases_create

InputTypeDescription
name (body)string, requiredThe release name, up to 255 characters
version (body)string, optionalThe version, up to 50 characters. When creating, a date-based version is used if it is left out
description (body)string, optionalWhat the release is for
target_environment (body)string, optionalThe environment the release is for, up to 50 characters
target_grouping (body)string, optionalThe grouping the release is for, up to 100 characters
scheduled_execution_date (body)string (date-time), optionalThe planned date and time of the run
script_ids (body)list of string (uuid), optionalThe scripts in the release, in run order. Each script can be in a release once
pipeline_id (body)string (uuid) or null, optionalThe release pipeline the release follows. Send null to stop following one

PUT /api/db-devops/releases/:id

Changes the fields sent. Changing the scripts or the pipeline of a signed-off release sets it back to pending sign-off. A running release cannot be changed.

Changes data · Role: Release manager or admin · MCP tool: releases_update

InputTypeDescription
id (path)string (uuid), requiredThe release ID
name (body)string, optionalThe release name, up to 255 characters
version (body)string, optionalThe version, up to 50 characters. When creating, a date-based version is used if it is left out
description (body)string, optionalWhat the release is for
target_environment (body)string, optionalThe environment the release is for, up to 50 characters
target_grouping (body)string, optionalThe grouping the release is for, up to 100 characters
scheduled_execution_date (body)string (date-time), optionalThe planned date and time of the run
script_ids (body)list of string (uuid), optionalThe scripts in the release, in run order. Each script can be in a release once
pipeline_id (body)string (uuid) or null, optionalThe release pipeline the release follows. Send null to stop following one

DELETE /api/db-devops/releases/:id

Deletes a release. A release with run or approval history is kept and the call is refused.

Changes data and can remove or overwrite it · Role: Admin · MCP tool: releases_delete

InputTypeDescription
id (path)string (uuid), requiredThe release ID

POST /api/db-devops/releases/:id/signoff

Signs off a pending release: fixes its scripts, their run order and its pipeline. Every script must be approved. When self-approval is turned off, the creator cannot sign it off.

Changes data · Role: Approver, release manager or admin · MCP tool: releases_sign_off

InputTypeDescription
id (path)string (uuid), requiredThe release ID

GET /api/db-devops/releases/:id/stages

For a release that follows a pipeline: each stage, the databases it runs on, how far the release got and which stage is next.

Reads only · Role: Any signed-in user · MCP tool: releases_stages

InputTypeDescription
id (path)string (uuid), requiredThe release ID

POST /api/db-devops/releases/:id/promote

Starts running a signed-off pipeline release on the databases of its next stage, or of the stage given, in the background. Returns the run batch at once; follow it with executions_batch.

Changes data and can remove or overwrite it · Role: Release manager or admin · MCP tool: releases_promote · With wait: false it answers 202 and runs in the background

InputTypeDescription
id (path)string (uuid), requiredThe release ID
stage (body)integer, 1 or more, optionalThe stage number to promote to. Leave it out for the next stage
mode (body)one of transactional, halt, continue, optionalHow the scripts run: transactional (all or nothing where the engine supports it), halt (stop at the first failing statement) or continue (run every statement)
wait (body)boolean, optionalfalse answers at once with 202 and keeps running in the background; left out or true waits for the result

GET /api/db-devops/releases/:id/rollback

For one finished run of a release (the latest run with something to undo, unless run_id names one): each database it ran on, with its script runs newest first and whether each will be rolled back, was already rolled back, is rolling back now, failed to roll back last time or cannot be rolled back and why. Also lists the release's finished runs.

Reads only · Role: Any signed-in user · MCP tool: releases_rollback_plan

InputTypeDescription
id (path)string (uuid), requiredThe release ID
run_id (query)string (uuid), optionalThe release run to look at. Leave it out for the latest run with something to undo

POST /api/db-devops/releases/:id/rollback

Rolls back every script run of one release run that can be rolled back, in the background: on each database newest first, stopping on that database at the first rollback that fails. Each rollback is recorded as its own run. When everything that can be undone is rolled back, the release run counts as rolled back, so a pipeline stage or a later environment needs it run again. Returns the plan at once; follow it with releases_rollback_plan.

Changes data and can remove or overwrite it · Role: Release manager or admin · MCP tool: releases_rollback · With wait: false it answers 202 and runs in the background

InputTypeDescription
id (path)string (uuid), requiredThe release ID
reason (body)string, requiredWhy the release run is rolled back, up to 2000 characters
run_id (body)string (uuid), optionalThe release run to roll back. Leave it out for the latest run with something to undo
wait (body)boolean, optionalfalse answers at once with 202 and keeps running in the background; left out or true waits for the result

POST /api/db-devops/releases/:id/stages/:position/retry

Runs a stage of a pipeline release again on its databases in the background. Returns the run batch at once; follow it with executions_batch.

Changes data and can remove or overwrite it · Role: Release manager or admin · MCP tool: releases_retry_stage · With wait: false it answers 202 and runs in the background

InputTypeDescription
id (path)string (uuid), requiredThe release ID
position (path)integer, 1 or more, requiredThe stage number
mode (body)one of transactional, halt, continue, optionalHow the scripts run: transactional (all or nothing where the engine supports it), halt (stop at the first failing statement) or continue (run every statement)
wait (body)boolean, optionalfalse answers at once with 202 and keeps running in the background; left out or true waits for the result