Skip to contentSkip to page list

Docs

List the organisation's agent stops

The organisation's stops, latest request first, limit at a time (default 50, at most 200). Pass next_cursor back as cursor for the next page; it is null on the last page. status=pending_approval lists the stops waiting for a decision.

GET/api/v1/governance/agent-stops
Request and response examples
request.py
import osimport requests​origin = "https://app.langwatch.ai"path = "/api/v1/governance/agent-stops"api_key = os.environ["LANGWATCH_API_KEY"]headers = {    "Authorization": "Bearer " + api_key,}​response = requests.get(    origin + path,    headers=headers,)print(response.json())

Success

application/json · Generated from schema

{  "data": [    {      "id": "string",      "agentId": "string",      "agentName": "string",      "status": "pending_approval",      "severity": "low",      "approval": "immediate",      "trigger": "user",      "reason": "string",      "requestedBy": {        "userId": "string",        "apiKeyId": "string"      },      "decidedByUserId": "string",      "restoredByUserId": "string",      "targets": [        {          "id": "string",          "label": "string",          "target": null,          "state": "pending",          "errorCode": "string",          "appliedAt": "string",          "revertedAt": "string",          "alreadyStopped": false,          "gone": false,          "keptDisabled": false,          "dropped": false,          "dropId": "string"        }      ],      "requestedAt": "string",      "decidedAt": "string",      "quarantinedAt": "string",      "restoreRequestedAt": "string",      "restoredAt": "string",      "lastRequestId": "string"    }  ],  "next_cursor": "string"}
api-reference/governance-kill-switch/list-the-organisation-s-agent-stops

Authorization

Authorizationstringheaderrequired

Admin API key for organization-level operations (managing projects, API keys). Create one in Settings > API Keys or via POST /api/api-keys. Format: sk-lw-{id}_{secret}.

Query parameters

statusstring
limitinteger
Minimum 1Maximum 200
cursorstring
At least 1 character

Responses

200

Success

application/json

dataobject[]required
idstringrequired
agentIdstringrequired
agentNamestringrequired
statusstringrequired
One of"pending_approval""denied""stopping""quarantined""stop_failed""restoring""restored""restore_failed"
severitystringrequired
One of"low""medium""high""critical"
approvalstringrequired
One of"immediate""required"
triggerstringrequired
One of"user""api_key"
reasonstringrequired
requestedByobjectrequired
decidedByUserIdstring | nullrequired
restoredByUserIdstring | nullrequired
targetsobject[]required
requestedAtstringrequired
decidedAtstring | nullrequired
quarantinedAtstring | nullrequired
restoreRequestedAtstring | nullrequired
restoredAtstring | nullrequired
lastRequestIdstring
next_cursorstring | nullrequired
400

Bad Request

application/json

typestringrequired
codestringrequired
messagestringrequired
retryablebooleanrequired
metaobject
trace_idstring
span_idstring
traceobject
traceIdstring
spanIdstring
traceUrlstring
logsUrlstring
tipsstring[]
docs_urlstring
faultstring
One of"customer""platform""provider""presumed_platform"
reasonsany[]
401

Unauthorized

application/json

typestringrequired
codestringrequired
messagestringrequired
retryablebooleanrequired
metaobject
trace_idstring
span_idstring
traceobject
traceIdstring
spanIdstring
traceUrlstring
logsUrlstring
tipsstring[]
docs_urlstring
faultstring
One of"customer""platform""provider""presumed_platform"
reasonsany[]
403

Forbidden

application/json

typestringrequired
codestringrequired
messagestringrequired
retryablebooleanrequired
metaobject
trace_idstring
span_idstring
traceobject
traceIdstring
spanIdstring
traceUrlstring
logsUrlstring
tipsstring[]
docs_urlstring
faultstring
One of"customer""platform""provider""presumed_platform"
reasonsany[]
422

Unprocessable Entity

application/json

typestringrequired
codestringrequired
messagestringrequired
retryablebooleanrequired
metaobject
trace_idstring
span_idstring
traceobject
traceIdstring
spanIdstring
traceUrlstring
logsUrlstring
tipsstring[]
docs_urlstring
faultstring
One of"customer""platform""provider""presumed_platform"
reasonsany[]
500

Internal Server Error

application/json

typestringrequired
codestringrequired
messagestringrequired
retryablebooleanrequired
metaobject
trace_idstring
span_idstring
traceobject
traceIdstring
spanIdstring
traceUrlstring
logsUrlstring
tipsstring[]
docs_urlstring
faultstring
One of"customer""platform""provider""presumed_platform"
reasonsany[]

Documentation