{
  "opencollection": "1.0.0",
  "info": {
    "name": "API Reference agents customer-groups API",
    "version": "1.0.0"
  },
  "items": [
    {
      "info": {
        "name": "customer-groups",
        "type": "folder"
      },
      "items": [
        {
          "info": {
            "name": "List customer groups",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.agentpaid.io/api/v1/customer-groups/",
            "headers": [
              {
                "name": "Authorization",
                "value": ""
              }
            ],
            "params": [
              {
                "name": "limit",
                "value": "",
                "type": "query"
              },
              {
                "name": "offset",
                "value": "",
                "type": "query"
              }
            ]
          },
          "docs": "List all customer groups for the organization."
        },
        {
          "info": {
            "name": "Create customer group",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api.agentpaid.io/api/v1/customer-groups/",
            "headers": [
              {
                "name": "Authorization",
                "value": ""
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            }
          },
          "docs": "Create a new customer group. Names must be unique per org."
        },
        {
          "info": {
            "name": "Get customer group",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.agentpaid.io/api/v1/customer-groups/:id",
            "headers": [
              {
                "name": "Authorization",
                "value": ""
              }
            ],
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path"
              }
            ]
          },
          "docs": "Returns group details including member list (capped at 500)."
        },
        {
          "info": {
            "name": "Update customer group",
            "type": "http"
          },
          "http": {
            "method": "PATCH",
            "url": "https://api.agentpaid.io/api/v1/customer-groups/:id",
            "headers": [
              {
                "name": "Authorization",
                "value": ""
              }
            ],
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path"
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            }
          },
          "docs": "Update a customer group's name or description."
        },
        {
          "info": {
            "name": "Delete customer group",
            "type": "http"
          },
          "http": {
            "method": "DELETE",
            "url": "https://api.agentpaid.io/api/v1/customer-groups/:id",
            "headers": [
              {
                "name": "Authorization",
                "value": ""
              }
            ],
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path"
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            }
          },
          "docs": "Deletes the group and unbinds all members. Unbound customers fall back to the base value model config."
        },
        {
          "info": {
            "name": "Add members to group",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api.agentpaid.io/api/v1/customer-groups/:id/members",
            "headers": [
              {
                "name": "Authorization",
                "value": ""
              }
            ],
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path"
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            }
          },
          "docs": "Additive. Adds customers to the group without removing existing members."
        },
        {
          "info": {
            "name": "Set group members",
            "type": "http"
          },
          "http": {
            "method": "PUT",
            "url": "https://api.agentpaid.io/api/v1/customer-groups/:id/members",
            "headers": [
              {
                "name": "Authorization",
                "value": ""
              }
            ],
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path"
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            }
          },
          "docs": "Reconcile membership. The provided list is the complete desired membership. Customers not in the list are removed. Customers in the list but not currently in the group are added."
        },
        {
          "info": {
            "name": "Remove members from group",
            "type": "http"
          },
          "http": {
            "method": "DELETE",
            "url": "https://api.agentpaid.io/api/v1/customer-groups/:id/members",
            "headers": [
              {
                "name": "Authorization",
                "value": ""
              }
            ],
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path"
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            }
          },
          "docs": "Removes specific customers from the group."
        }
      ]
    }
  ],
  "bundled": true
}