List alerts

Returns every alert in the current project. Optionally filter by the automated test the alert is scoped to, or by a single event type.

Query Parameters
  • automated_test_id
    Type: integerFormat: int32

    Only return alerts scoped to this automated test.

  • event
    Type: string

    Only return alerts that subscribe to this event type.

Responses
  • application/json
  • application/json
Request Example for get/v1/alerts
curl 'http://api.mailreach.co/api/v1/alerts?automated_test_id=12&event=ACCOUNT_DISCONNECTED' \
  --header 'X-Api-Key: YOUR_SECRET_TOKEN'
[
  {
    "id": 42,
    "channel": "SLACK",
    "events": [
      "ACCOUNT_DISCONNECTED",
      "SPAMCHECK_COMPLETED"
    ],
    "active": true,
    "hook_url": "https://example.com/hooks/mailreach",
    "slack_channel_id": 42,
    "automated_test_ids": [
      12,
      34
    ]
  }
]