API ReferenceapicommsGET /v1/admin/campaigns

GET /v1/admin/campaigns

Service: comms · operationId: (none)

Required scopes

(no scope declared — review service config)

Query parameters

  • brand_id (string) required
  • status (string) —

Responses

200 Campaigns listed

{
  "type": "object",
  "properties": {
    "campaigns": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "brand_id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "subject": {
            "type": "string"
          },
          "channel": {
            "type": "string"
          },
          "template_key": {
            "type": "string"
          },
          "segment_criteria": {
            "type": "object",
            "additionalProperties": {}
          },
          "variables": {
            "type": "object",
            "additionalProperties": {}
          },
          "status": {
            "type": "string"
          },
          "scheduled_at": {
            "type": [
              "string",
              "null"
            ]
          },
          "sent_at": {
            "type": [
              "string",
              "null"
            ]
          },
          "cancelled_at": {
            "type": [
              "string",
              "null"
            ]
          },
          "created_by": {
            "type": "string"
          },
          "created_at": {
            "type": "string"
          },
          "updated_at": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "brand_id",
          "name",
          "subject",
          "channel",
          "template_key",
          "segment_criteria",
          "variables",
          "status",
          "scheduled_at",
          "sent_at",
          "cancelled_at",
          "created_by",
          "created_at",
          "updated_at"
        ]
      }
    }
  },
  "required": [
    "campaigns"
  ]
}

500 Listing failed

{
  "type": "object",
  "properties": {
    "error": {
      "type": "string"
    },
    "message": {
      "type": "string"
    }
  },
  "required": [
    "error",
    "message"
  ]
}

Example

curl -X GET https://comms.platform.loop.health/v1/admin/campaigns \
  -H "Authorization: Bearer $ACCESS_TOKEN"