Update agent session status
PATCH
/agent-sessions/{runId}/statusAuthorization
AuthorizationBearer token (JWT) · headerrequiredor
AuthorizationOAuth2 access token · headerrequiredScopes:
api:writeor
AuthorizationBearer token (JWT) · headerrequiredPath parameters
runIdstringrequiredRequest body
requiredapplication/jsonidempotencyKeystringmessagestringstatusstringrequiredAllowed:
queuedrunningwaitingInputwaitingApprovaldonefailedcanceledResponses
200
401Unauthorized - Invalid or missing authentication token
403Forbidden - Insufficient API scopes or permissions
Request
curl -X PATCH "https://leadtime.app/api/public/agent-sessions/string/status" \
-H "Authorization: Bearer YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"idempotencyKey": "string",
"message": "string",
"status": "queued"
}'const response = await fetch("https://leadtime.app/api/public/agent-sessions/string/status", {
method: "PATCH",
headers: {
"Authorization": "Bearer YOUR_TOKEN",
"Content-Type": "application/json"
},
body: JSON.stringify({
"idempotencyKey": "string",
"message": "string",
"status": "queued"
})
});import requests
response = requests.patch(
"https://leadtime.app/api/public/agent-sessions/string/status",
headers={
"Authorization": "Bearer YOUR_TOKEN",
"Content-Type": "application/json"
},
json={
"idempotencyKey": "string",
"message": "string",
"status": "queued"
},
)Response
No example response.
Unauthorized - Invalid or missing authentication token
Forbidden - Insufficient API scopes or permissions