Skip to main content
GET
/
relay
/
v1
/
approvals
List HITL approval requests
curl --request GET \
  --url https://api.swarmd.ai/relay/v1/approvals \
  --header 'Authorization: Bearer <token>'
[
  {
    "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "taskId": "<string>",
    "contextId": "<string>",
    "tenantId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "agentId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "agentMessageRole": "<string>",
    "agentMessageText": "<string>",
    "detectionSource": "SYNC_RESPONSE",
    "sourceAgentId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "sourceUserId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "sinkAgentId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "agentMessageData": "<string>",
    "createdAt": "2023-11-07T05:31:56Z",
    "resolution": {
      "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "action": "APPROVED",
      "message": "<string>",
      "resolvedBy": "<string>",
      "createdAt": "2023-11-07T05:31:56Z"
    }
  }
]

Authorizations

Authorization
string
header
required

JWT token (USER, AGENT, or SERVICE auth)

Query Parameters

status
string
default:PENDING

Response

200 - application/json

OK

id
string<uuid>
taskId
string
contextId
string
tenantId
string<uuid>
agentId
string<uuid>
agentMessageRole
string
agentMessageText
string
detectionSource
enum<string>
Available options:
SYNC_RESPONSE,
PUSH_NOTIFICATION
sourceAgentId
string<uuid>
sourceUserId
string<uuid>
sinkAgentId
string<uuid>
agentMessageData
string
createdAt
string<date-time>
resolution
object