Control an agent run
curl --request POST \
--url https://useorgx.com/api/v1/runs/{runId}/actions/{action} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"reason": "Waiting on the pricing decision"
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({reason: 'Waiting on the pricing decision'})
};
fetch('https://useorgx.com/api/v1/runs/{runId}/actions/{action}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://useorgx.com/api/v1/runs/{runId}/actions/{action}"
payload = { "reason": "Waiting on the pricing decision" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"ok": true,
"data": {
"runId": "9c7b1d68-2c5c-4d6b-9a8e-5c4f2c0c5b4d",
"action": "pause",
"status": "paused"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": {},
"requestId": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"docsUrl": "<string>",
"retryAfter": 123
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": {},
"requestId": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"docsUrl": "<string>",
"retryAfter": 123
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": {},
"requestId": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"docsUrl": "<string>",
"retryAfter": 123
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": {},
"requestId": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"docsUrl": "<string>",
"retryAfter": 123
}
}Runs
Control an agent run
Apply one control action to an agent run: pause, resume, cancel, or rollback
(rollback takes a checkpointId). Each action is validated against the run’s current
state, so repeating an already-applied action is safe.
POST
/
runs
/
{runId}
/
actions
/
{action}
Control an agent run
curl --request POST \
--url https://useorgx.com/api/v1/runs/{runId}/actions/{action} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"reason": "Waiting on the pricing decision"
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({reason: 'Waiting on the pricing decision'})
};
fetch('https://useorgx.com/api/v1/runs/{runId}/actions/{action}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://useorgx.com/api/v1/runs/{runId}/actions/{action}"
payload = { "reason": "Waiting on the pricing decision" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"ok": true,
"data": {
"runId": "9c7b1d68-2c5c-4d6b-9a8e-5c4f2c0c5b4d",
"action": "pause",
"status": "paused"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": {},
"requestId": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"docsUrl": "<string>",
"retryAfter": 123
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": {},
"requestId": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"docsUrl": "<string>",
"retryAfter": 123
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": {},
"requestId": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"docsUrl": "<string>",
"retryAfter": 123
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": {},
"requestId": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"docsUrl": "<string>",
"retryAfter": 123
}
}Authorizations
OrgX API key, sent as Authorization: Bearer oxk_...
Headers
Accepted for forward compatibility. Replay safety for this operation comes from its own state checks, described on the operation.
Required string length:
1 - 200Pattern:
^[A-Za-z0-9][A-Za-z0-9._:/-]{0,199}$Path Parameters
Available options:
pause, resume, cancel, rollback Body
application/json
