---
title: "Queue a synthetic alert through a rule's channel"
method: POST
path: "/alert-rules/{rule_id}/test"
tags: ["Alerts"]
---

# Queue a synthetic alert through a rule's channel

`POST /alert-rules/{rule_id}/test`

## Request

- Base URL: `https://adslighthouse.com/api/v1`
- URL: `https://adslighthouse.com/api/v1/alert-rules/{rule_id}/test`
- Auth: HTTP bearer

Queues a test event for a rule, like the Send a test action in the app, so you can verify the email address, Slack channel or webhook endpoint (including its signature check) without waiting for a real finding. The alert dispatcher sends it within about 15 minutes; follow it with get_alert_event. It is marked as a test and never counts as a finding. For a summary_digest rule the test carries the real summary of the latest period the schedule covered. Requires the write scope and an idempotency key; a retry with the same key returns the same event without queueing another. Limited to 5 tests per rule per hour and 20 per account per day (rate_limited with Retry-After beyond).

## Path parameters

- `rule_id` string, required: The alert rule id from list_alert_rules.

## Headers

- `Idempotency-Key` string, required: A unique value you choose for this request, such as a UUID. Repeating the same key returns the first result instead of starting paid work again.

## Request body

- object

## Response `202`

Queue a synthetic alert through a rule's channel

- object
  - `event_id` string, required
  - `created` boolean, required: False when this key already queued the event.
  - `request_id` string

## Other responses

- `400`: Invalid parameters, cursor or body.
- `401`: Missing, invalid, expired or revoked credential.
- `403`: The credential lacks the write scope, the plan does not include the API, or the allowance is used up.
- `404`: Unknown project, keyword or run in this account.
- `409`: The idempotency key was already used for a different request.
- `429`: Rate limit reached. Retry after the Retry-After seconds.
- `503`: The requested service or file is temporarily unavailable.

---

[API](https://skmtc.dev/adslighthouse/apis/ads-lighthouse-api.md) · [All operations](https://skmtc.dev/adslighthouse/apis/ads-lighthouse-api/llms.txt) · [OpenAPI document](https://skmtc.dev/adslighthouse/apis/ads-lighthouse-api/revisions/e1a4a40b11a9?raw)
