Delete an Environment
Creates a job that attempts to delete the environment. Action is automatically submitted by the TS client where in the HTTP request you must submit the action as a parameter.
Requires the environments-state permission.
Parameters: token hubIdenvironment IDaction
Parameter
- actionstring
Create a task resulting in the following action:
delete
.
Returns
Returns an task resource, otherwise returns an Error.
POST /v1/environments/5b9c2a77b6393d0001eb45fd/tasks
Example Request
$ curl https://api.cycle.io/v1/environments/5b9c2a77b6393d0001eb45fd/tasks \-H"Authorization: Bearer API_KEY"\-H"X-Hub-Id: HUB_ID"\-H 'Content-Type: application/json' \-d '{"action":"delete"}' \-X POST
Example Response
{"data": {"action": "delete","job_id": "5b9c2a77b6393d0001eb45fd"}}