Stop a still-active cron job
curl --request POST \
--url https://api.atako.ai/agents/{agentId}/cron-jobs/{jobId}/stop \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.atako.ai/agents/{agentId}/cron-jobs/{jobId}/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.atako.ai/agents/{agentId}/cron-jobs/{jobId}/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.atako.ai/agents/{agentId}/cron-jobs/{jobId}/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.atako.ai/agents/{agentId}/cron-jobs/{jobId}/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.atako.ai/agents/{agentId}/cron-jobs/{jobId}/stop")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.atako.ai/agents/{agentId}/cron-jobs/{jobId}/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{
"job": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"agentId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"title": "<string>",
"prompt": "<string>",
"schedule": "<string>",
"enabled": true,
"createdAt": "2023-11-07T05:31:56Z",
"description": "<string>",
"nextRunAt": "2023-11-07T05:31:56Z",
"lastRunAt": "2023-11-07T05:31:56Z",
"lastRunState": "running",
"timezone": "<string>",
"repeatTimes": 123,
"paused": true,
"pausedReason": "<string>",
"mode": "agent",
"continuity": true,
"reasoningEffort": "<string>",
"archivedAt": "2023-11-07T05:31:56Z",
"stoppedAt": "2023-11-07T05:31:56Z",
"stoppedBy": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"updatedAt": "2023-11-07T05:31:56Z",
"executions": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"cronJobId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"state": "running",
"startedAt": "2023-11-07T05:31:56Z",
"finishedAt": "2023-11-07T05:31:56Z",
"durationMs": 123,
"error": "<string>",
"output": "<string>",
"outputPreview": "<string>",
"summary": "<string>",
"businessState": "ok",
"noChange": true,
"createdAt": "2023-11-07T05:31:56Z"
}
]
}
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}Cron Jobs
Stop a still-active cron job
Owner or company admin. Archives and disables the job, then asks the agent’s bridge to remove it from its engine (cron_control frame, re-sent on each sync that still reports it). Later syncs cannot revive it; runs the engine still fires are recorded, never delivered.
POST
/
agents
/
{agentId}
/
cron-jobs
/
{jobId}
/
stop
Stop a still-active cron job
curl --request POST \
--url https://api.atako.ai/agents/{agentId}/cron-jobs/{jobId}/stop \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.atako.ai/agents/{agentId}/cron-jobs/{jobId}/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.atako.ai/agents/{agentId}/cron-jobs/{jobId}/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.atako.ai/agents/{agentId}/cron-jobs/{jobId}/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.atako.ai/agents/{agentId}/cron-jobs/{jobId}/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.atako.ai/agents/{agentId}/cron-jobs/{jobId}/stop")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.atako.ai/agents/{agentId}/cron-jobs/{jobId}/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{
"job": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"agentId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"title": "<string>",
"prompt": "<string>",
"schedule": "<string>",
"enabled": true,
"createdAt": "2023-11-07T05:31:56Z",
"description": "<string>",
"nextRunAt": "2023-11-07T05:31:56Z",
"lastRunAt": "2023-11-07T05:31:56Z",
"lastRunState": "running",
"timezone": "<string>",
"repeatTimes": 123,
"paused": true,
"pausedReason": "<string>",
"mode": "agent",
"continuity": true,
"reasoningEffort": "<string>",
"archivedAt": "2023-11-07T05:31:56Z",
"stoppedAt": "2023-11-07T05:31:56Z",
"stoppedBy": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"updatedAt": "2023-11-07T05:31:56Z",
"executions": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"cronJobId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"state": "running",
"startedAt": "2023-11-07T05:31:56Z",
"finishedAt": "2023-11-07T05:31:56Z",
"durationMs": 123,
"error": "<string>",
"output": "<string>",
"outputPreview": "<string>",
"summary": "<string>",
"businessState": "ok",
"noChange": true,
"createdAt": "2023-11-07T05:31:56Z"
}
]
}
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}{
"error": "<string>",
"code": "<string>"
}