API Reference

Description

Stop a chain run with the specified ID.

POST /v1/execute/chain_run/{chain_run_id}/stop

Parameters

ParameterInTypeRequiredDescription
chain_run_idpathstringtrueThe ID of the Chain Run.

Code Samples

curl -X POST https://h.app.wdesk.com/s/wdata/oc/api/v1/execute/chain_run/{chain_run_id}/stop  \ 
-H 'Accept: application/json' \ 
-H 'Authorization: Bearer {access-token}'
http POST https://h.app.wdesk.com/s/wdata/oc/api/v1/execute/chain_run/{chain_run_id}/stop  \ 
Accept:application/json \ 
Authorization:"Bearer {access-token}"
wget --method=POST "https://h.app.wdesk.com/s/wdata/oc/api/v1/execute/chain_run/{chain_run_id}/stop" \
 --output-document -  \ 
 --header 'Accept: application/json' \ 
 --header 'Authorization: Bearer {access-token}'
import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://h.app.wdesk.com/s/wdata/oc/api/v1/execute/chain_run/{chain_run_id}/stop', headers = headers)

print(r.json())

Returns

200 - OK

Returns a ChainRunResponse containing the stopped ChainRun object that matches the provided chain_run_id.

Example Responses


{
  "data": {
    "id": "1",
    "chainId": "37",
    "envId": "1154",
    "userId": "5",
    "userName": "dev23",
    "startAt": "2019-02-08 06:25:00",
    "endAt": "2019-02-12 06:25:00",
    "pausedAt": "2019-02-12 06:25:00",
    "resumedAt": "2019-02-12 06:25:00",
    "state": "sleeping",
    "launchType": "manual",
    "resultText": "success"
  }
}