RaabtaHQ
Preview a firing

Preview a firing

POST/api/v1/triggers/{id}/preview

scope assistants:readCosts 2 rate-limit units

Resolves the audience and reports what firing right now WOULD do, without starting anything and without spending. Use it before switching a trigger on — a segment that has grown can turn a helpful nudge into five hundred messages.

Path parameters

NameTypeDescription
idrequired
string (uuid)Trigger id
Request
curl -X POST "https://your-crm.example.com/api/v1/triggers/4b5c6d7e-8f9a-4b0c-8d1e-2f3a4b5c6d7e/preview" \
  -H "Authorization: Bearer $RAABTA_API_KEY"
Response · 200 OK
{
  "data": {
    "would_start": 12,
    "target_contact_ids": [
      "9d7e4c11-5a2b-4f7c-8e3d-2a1b0c9d8e7f"
    ],
    "excluded": 3
  }
}

Response

Wrapped in { data: … }
NameTypeDescription
would_startrequired
integerRuns this firing would start right now
target_contact_idsrequired
string (uuid)[]Up to 20 of the contacts it would act on, for a sanity check
excludedrequired
integerContacts skipped for quiet hours, an already-active run, or max_targets

Errors

StatusCodeWhen
400validation_errorThe body or query failed validation. `details` lists each failing field with a `path` and a `message`.
401unauthorizedNo usable API key: the Authorization header is missing or malformed, or the key is unknown, revoked or expired. The three are deliberately indistinguishable.
403forbiddenThe key is valid but lacks the scope this endpoint requires, or the request came from an address outside the key’s IP allowlist. The message says which.
403account_suspendedThe account this key belongs to is suspended. Rotating the key will not help; contact support.
404not_foundNo such resource in this account. A resource that exists in another account also returns this.
429rate_limitedThe per-key budget, or the per-IP budget for failed authentication, is exhausted. Honour `Retry-After` before retrying.
500internalSomething failed on our side. Safe to retry with the same Idempotency-Key; quote `request_id` if it persists.