cURL
curl --request POST \
--url http://api.den.local/v1/automation-runs/{id}/complete \
--header 'Content-Type: application/json' \
--data '
{
"attempt": 123,
"sessionId": "<string>",
"workspaceId": "<string>",
"resultSummary": "<string>",
"usage": {
"inputTokens": 4503599627370495,
"outputTokens": 4503599627370495,
"costMicros": 4503599627370495
},
"error": {
"message": "<string>",
"retryable": true
}
}
'import requests
url = "http://api.den.local/v1/automation-runs/{id}/complete"
payload = {
"attempt": 123,
"sessionId": "<string>",
"workspaceId": "<string>",
"resultSummary": "<string>",
"usage": {
"inputTokens": 4503599627370495,
"outputTokens": 4503599627370495,
"costMicros": 4503599627370495
},
"error": {
"message": "<string>",
"retryable": True
}
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
attempt: 123,
sessionId: '<string>',
workspaceId: '<string>',
resultSummary: '<string>',
usage: {
inputTokens: 4503599627370495,
outputTokens: 4503599627370495,
costMicros: 4503599627370495
},
error: {message: '<string>', retryable: true}
})
};
fetch('http://api.den.local/v1/automation-runs/{id}/complete', 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 => "http://api.den.local/v1/automation-runs/{id}/complete",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'attempt' => 123,
'sessionId' => '<string>',
'workspaceId' => '<string>',
'resultSummary' => '<string>',
'usage' => [
'inputTokens' => 4503599627370495,
'outputTokens' => 4503599627370495,
'costMicros' => 4503599627370495
],
'error' => [
'message' => '<string>',
'retryable' => true
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "http://api.den.local/v1/automation-runs/{id}/complete"
payload := strings.NewReader("{\n \"attempt\": 123,\n \"sessionId\": \"<string>\",\n \"workspaceId\": \"<string>\",\n \"resultSummary\": \"<string>\",\n \"usage\": {\n \"inputTokens\": 4503599627370495,\n \"outputTokens\": 4503599627370495,\n \"costMicros\": 4503599627370495\n },\n \"error\": {\n \"message\": \"<string>\",\n \"retryable\": true\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("http://api.den.local/v1/automation-runs/{id}/complete")
.header("Content-Type", "application/json")
.body("{\n \"attempt\": 123,\n \"sessionId\": \"<string>\",\n \"workspaceId\": \"<string>\",\n \"resultSummary\": \"<string>\",\n \"usage\": {\n \"inputTokens\": 4503599627370495,\n \"outputTokens\": 4503599627370495,\n \"costMicros\": 4503599627370495\n },\n \"error\": {\n \"message\": \"<string>\",\n \"retryable\": true\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("http://api.den.local/v1/automation-runs/{id}/complete")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"attempt\": 123,\n \"sessionId\": \"<string>\",\n \"workspaceId\": \"<string>\",\n \"resultSummary\": \"<string>\",\n \"usage\": {\n \"inputTokens\": 4503599627370495,\n \"outputTokens\": 4503599627370495,\n \"costMicros\": 4503599627370495\n },\n \"error\": {\n \"message\": \"<string>\",\n \"retryable\": true\n }\n}"
response = http.request(request)
puts response.read_bodyAPI Reference
Post v1automation runs complete
POST
/
v1
/
automation-runs
/
{id}
/
complete
cURL
curl --request POST \
--url http://api.den.local/v1/automation-runs/{id}/complete \
--header 'Content-Type: application/json' \
--data '
{
"attempt": 123,
"sessionId": "<string>",
"workspaceId": "<string>",
"resultSummary": "<string>",
"usage": {
"inputTokens": 4503599627370495,
"outputTokens": 4503599627370495,
"costMicros": 4503599627370495
},
"error": {
"message": "<string>",
"retryable": true
}
}
'import requests
url = "http://api.den.local/v1/automation-runs/{id}/complete"
payload = {
"attempt": 123,
"sessionId": "<string>",
"workspaceId": "<string>",
"resultSummary": "<string>",
"usage": {
"inputTokens": 4503599627370495,
"outputTokens": 4503599627370495,
"costMicros": 4503599627370495
},
"error": {
"message": "<string>",
"retryable": True
}
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
attempt: 123,
sessionId: '<string>',
workspaceId: '<string>',
resultSummary: '<string>',
usage: {
inputTokens: 4503599627370495,
outputTokens: 4503599627370495,
costMicros: 4503599627370495
},
error: {message: '<string>', retryable: true}
})
};
fetch('http://api.den.local/v1/automation-runs/{id}/complete', 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 => "http://api.den.local/v1/automation-runs/{id}/complete",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'attempt' => 123,
'sessionId' => '<string>',
'workspaceId' => '<string>',
'resultSummary' => '<string>',
'usage' => [
'inputTokens' => 4503599627370495,
'outputTokens' => 4503599627370495,
'costMicros' => 4503599627370495
],
'error' => [
'message' => '<string>',
'retryable' => true
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "http://api.den.local/v1/automation-runs/{id}/complete"
payload := strings.NewReader("{\n \"attempt\": 123,\n \"sessionId\": \"<string>\",\n \"workspaceId\": \"<string>\",\n \"resultSummary\": \"<string>\",\n \"usage\": {\n \"inputTokens\": 4503599627370495,\n \"outputTokens\": 4503599627370495,\n \"costMicros\": 4503599627370495\n },\n \"error\": {\n \"message\": \"<string>\",\n \"retryable\": true\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("http://api.den.local/v1/automation-runs/{id}/complete")
.header("Content-Type", "application/json")
.body("{\n \"attempt\": 123,\n \"sessionId\": \"<string>\",\n \"workspaceId\": \"<string>\",\n \"resultSummary\": \"<string>\",\n \"usage\": {\n \"inputTokens\": 4503599627370495,\n \"outputTokens\": 4503599627370495,\n \"costMicros\": 4503599627370495\n },\n \"error\": {\n \"message\": \"<string>\",\n \"retryable\": true\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("http://api.den.local/v1/automation-runs/{id}/complete")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"attempt\": 123,\n \"sessionId\": \"<string>\",\n \"workspaceId\": \"<string>\",\n \"resultSummary\": \"<string>\",\n \"usage\": {\n \"inputTokens\": 4503599627370495,\n \"outputTokens\": 4503599627370495,\n \"costMicros\": 4503599627370495\n },\n \"error\": {\n \"message\": \"<string>\",\n \"retryable\": true\n }\n}"
response = http.request(request)
puts response.read_bodyPath Parameters
Required string length:
1 - 160Body
application/json
Required range:
x <= 9007199254740991Available options:
succeeded, failed, cancelled Required string length:
1 - 240Required string length:
1 - 240Maximum string length:
20000Show child attributes
Show child attributes
Show child attributes
Show child attributes
Response
200
OK
Was this page helpful?
⌘I