Skip to main content
POST
Roll a tool back in an environment
Its warnings, dry_run, force and acknowledge work as environments.promote’s.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

tool_id
string
required

a tool ID: tool_ and 32 lowercase hex digits

Example:

"tool_0f8e2d1c4b3a49e8a7f6e5d4c3b2a190"

key
string
required

a string matching the pattern ^a-z [blocked]?$

Body

application/json
to_version
integer
required

The version, as code.get numbers it

Required range: 1 <= x <= 1000000
dry_run
boolean

Preview: the warnings and the files that would change, writing nothing

force
boolean

Accept every warning this call finds

acknowledge
enum<string>[]

Accept only these warnings

Available options:
inputs_change,
public_tool_fork,
target_changed,
target_ahead,
no_login_in_environment,
unchecked_code,
merge_conflicts
if_target_version
integer

The target's version you saw; another refuses target_moved

Required range: 1 <= x <= 1000000

Response

What it did, or would do

published: the target serves a new version. reset: it follows production again. unchanged: it already served it. preview: what a dry_run found

status
enum<string>
required
Available options:
published
tool_id
string
required

a tool ID: tool_ and 32 lowercase hex digits

Example:

"tool_0f8e2d1c4b3a49e8a7f6e5d4c3b2a190"

environment
string
required
version
number
required
promoted_from
object
required
mode
enum<string>
required

replace: the target serves the source's version. merge: the source's changes go onto the target's newest version

Available options:
replace,
merge
warnings_accepted
enum<string>[]
required
Available options:
inputs_change,
public_tool_fork,
target_changed,
target_ahead,
no_login_in_environment,
unchecked_code,
merge_conflicts
lands_as
enum<string>
Available options:
public_update,
private_copy,
new_tool
merged
object