Prune Unused Stack Builds

Delete ALLunused builds (builds that are not currently deployed to an environment), that are more than 30 minutes old.

Requires the stacks-builds-manage permission.

Returns

Returns a Task Descriptor Object, otherwise returns an Error.

POST /v1/stacks/{ID}/tasks

Example Request
$ curl https://api.cycle.io/v1/stacks/5a98710df231a500017f9aa4/tasks \
-H
"Authorization: Bearer API_KEY"
\
-H
"X-Hub-Id: HUB_ID"
\
-H 'Content-Type: application/json' \
-d '{"action":"prune"}' \
-X POST
Example Response
{
"data": {
"action": "prune",
"job_id": "5d01b9b3db2ab00001508cd8"
}
}