TeamCity REST API Reference 2024.07 Help

BuildCancelRequest

Send a POST request with this object as a payload to cancel a queued (the /app/rest/buildQueue/<queuedBuildLocator> endpoint)or already running (the /app/rest/builds/<buildLocator> endpoint) build.

Properties

comment

A note that explains why this build was canceled. This note will be written to the canceled build's build.canceledInfo.text property.

readdIntoQueue

If true, a new identical build will be queued as soon as the current build is canceled. If false, a build will simply be canceled. Similarly to TeamCity UI, the option to re-queue a build is only available if this build is already running. Builds that are still queued can be only aborted.

Schema

Below, you can find a full schema of this object, in XML and JSON formats. You can choose what fields to submit depending on your current needs. Different methods might expect different fields: the best approach is to request this entity via GET and use the response as a base for the following POST request.

A link to another object implies that you can substitute it with the schema of the linked object, if it is required for your call.

<buildCancelRequest comment="Started by mistake" readdIntoQueue="false"/>
{ "comment" : "Started by mistake", "readdIntoQueue" : false }
Last modified: 04 July 2024