Skip to main content
POST
/
v1
/
teams
/
{team_id}
/
tasks
/
{task_id}
/
executions
/
{execution_id}
/
stop
Cancel Execution
curl --request POST \
  --url https://api.dataraven.io/v1/teams/{team_id}/tasks/{task_id}/executions/{execution_id}/stop \
  --header 'Authorization: Bearer <token>'
import requests

url = "https://api.dataraven.io/v1/teams/{team_id}/tasks/{task_id}/executions/{execution_id}/stop"

headers = {"Authorization": "Bearer <token>"}

response = requests.post(url, headers=headers)

print(response.text)
const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};

fetch('https://api.dataraven.io/v1/teams/{team_id}/tasks/{task_id}/executions/{execution_id}/stop', options)
  .then(res => res.json())
  .then(res => console.log(res))
  .catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
  CURLOPT_URL => "https://api.dataraven.io/v1/teams/{team_id}/tasks/{task_id}/executions/{execution_id}/stop",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "POST",
  CURLOPT_HTTPHEADER => [
    "Authorization: Bearer <token>"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "https://api.dataraven.io/v1/teams/{team_id}/tasks/{task_id}/executions/{execution_id}/stop"

	req, _ := http.NewRequest("POST", url, nil)

	req.Header.Add("Authorization", "Bearer <token>")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.post("https://api.dataraven.io/v1/teams/{team_id}/tasks/{task_id}/executions/{execution_id}/stop")
  .header("Authorization", "Bearer <token>")
  .asString();
require 'uri'
require 'net/http'

url = URI("https://api.dataraven.io/v1/teams/{team_id}/tasks/{task_id}/executions/{execution_id}/stop")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'

response = http.request(request)
puts response.read_body
{
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "task_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "execution_number": 123,
  "is_dry_run": true,
  "queued_at": "2023-11-07T05:31:56Z",
  "started_at": "2023-11-07T05:31:56Z",
  "completed_at": "2023-11-07T05:31:56Z",
  "duration_seconds": 123,
  "stats": {},
  "error_message": "<string>",
  "rclone_exit_code": 123,
  "log_file_url": "<string>"
}
{
  "detail": [
    {
      "loc": [
        "<string>"
      ],
      "msg": "<string>",
      "type": "<string>",
      "input": "<unknown>",
      "ctx": {}
    }
  ]
}

Authorizations

Authorization
string
header
required

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

Path Parameters

task_id
string<uuid>
required
execution_id
string<uuid>
required
team_id
string<uuid>
required

Response

Successful Response

Base response schema for task execution.

id
string<uuid>
required
task_id
string<uuid>
required
execution_number
integer
required
trigger
enum<string>
required

Execution trigger types.

Available options:
manual,
scheduled,
api
status
enum<string>
required

Runtime execution status.

Available options:
pending,
running,
completed,
failed,
cancelled,
dry_run_completed
is_dry_run
boolean
required
queued_at
string<date-time>
required
started_at
string<date-time> | null
completed_at
string<date-time> | null
duration_seconds
integer | null
stats
Stats · object
error_message
string | null
rclone_exit_code
integer | null
log_file_url
string | null