Skip to main content
GET
/
relay
/
v1
/
policy-groups
List active policy groups with policies and bindings
curl --request GET \
  --url https://api.swarmd.ai/relay/v1/policy-groups \
  --header 'Authorization: Bearer <token>'
[
  {
    "groupId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "version": "<string>",
    "name": "<string>",
    "description": "<string>",
    "policies": [
      {
        "orderIndex": 123,
        "policy": {
          "policyId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
          "version": "<string>",
          "name": "<string>",
          "description": "<string>",
          "config": {
            "enabledLegs": {
              "requestFromSource": true,
              "requestToSink": true,
              "responseFromSink": true,
              "responseToSource": true
            },
            "entity": {
              "type": "BANK_ACCOUNT_NUMBER",
              "scoreThreshold": 0.5,
              "action": "LOG"
            },
            "type": "COMMUNICATION_AUDIT"
          },
          "validFrom": "2023-11-07T05:31:56Z",
          "validTo": "2023-11-07T05:31:56Z",
          "createdAt": "2023-11-07T05:31:56Z"
        }
      }
    ],
    "bindings": [
      {
        "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "groupId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "bindingLevel": "TENANT",
        "agentId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "sourceAgentId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "sinkAgentId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "priority": 123,
        "validFrom": "2023-11-07T05:31:56Z",
        "validTo": "2023-11-07T05:31:56Z",
        "createdAt": "2023-11-07T05:31:56Z"
      }
    ],
    "validFrom": "2023-11-07T05:31:56Z",
    "validTo": "2023-11-07T05:31:56Z",
    "createdAt": "2023-11-07T05:31:56Z"
  }
]

Authorizations

Authorization
string
header
required

JWT token (USER, AGENT, or SERVICE auth)

Response

200 - application/json

OK

groupId
string<uuid>
version
string
name
string
description
string
policies
object[]
bindings
object[]
validFrom
string<date-time>
validTo
string<date-time>
createdAt
string<date-time>