# Scenario event state

https://docs.sendsms.to/en/api/scenario-event-state/

`GET /v1/scenarios/{id}/events/{eventId}`

What became of an event: its state, the message ID (one number) or the run of the scenario (a list), the reason of a refusal. Another account’s event is indistinguishable from a missing one (404).

Required permission: messages.send

## Parameters

- `id` (path, required): Scenario ID from the cabinet: Scenarios → the scenario → API connection.
- `eventId` (path, required): 

## Request example

```bash
curl --max-time 30 --request GET \
  --url 'https://api.sendsms.to/v1/scenarios/SCENARIO_ID/events/EVENT_ID' \
  --header "X-API-Key: $SENDSMS_API_KEY"
```

## Responses

### HTTP 200 — Successful result

```json
{
  "eventId": "00000000-0000-0000-0000-000000000011",
  "status": "sent",
  "messageId": "00000000-0000-0000-0000-000000000012"
}
```

| Field | Type | Description |
| --- | --- | --- |
| `eventId` | string · uuid | required. Event identifier generated by SendSMS. Keep it to read the event later. |
| `status` | string | required. queued — the SMS was accepted by the same handler as POST /v1/messages (messageId); scheduled — it waits for the end of the quiet hours (sendAt); accepted — a list event that becomes a normal campaign of the scenario; refused — not sent (error explains why). |
| `messageId` | string | null · uuid | optional. Message identifier for GET /v1/messages/{id} (one-number events). |
| `sendAt` | string | null · date-time | optional. When a waiting event will be sent (the end of the quiet hours). |
| `recipients` | integer | optional. Number of distinct recipients of a list event. |
| `duplicate` | boolean | optional. true — a repeat of an event already accepted with this Idempotency-Key; nothing was sent again. |
| `campaignId` | string | null · uuid | optional. A list event: the campaign of the scenario run made from it. |
| `runState` | string | null | optional. A list event: the state of that run (preparing, review, scheduled, done, failed…). |
| `reasonCode` | string | null | optional. Why the event or its run did not go out, when it did not. |
| `dryRun` | boolean | optional. Present only in the answer to a trial request (X-Dry-Run: true): nothing was executed; identifiers in this answer are conditional. |

### HTTP 401 — Invalid or revoked API key

```json
{
  "error": "string"
}
```

| Field | Type | Description |
| --- | --- | --- |
| `error` | string | required. Error identifier or legacy human-readable text returned by SendSMS. Not every handler exposes a stable machine code here. Check HTTP status and documented identifiers; never parse translated prose as a permanent code. |
| `message` | string | optional. Optional explanation generated by SendSMS. Intended for people; wording/language may change. Absence means the handler supplied no separate explanation. |
| `code` | string | optional. Optional machine-readable code generated by SendSMS or its HTTP framework. Meaning depends on the operation; not a universal numeric provider code. |
| `statusCode` | integer | optional. Optional HTTP status number generated by the server framework for a framework-level error. The actual HTTP response status is authoritative. |

### HTTP 403 — Insufficient key permissions or account/channel policy; or the request came from an IP address not allowed for this key (ip_not_allowed)

```json
{
  "error": "string"
}
```

| Field | Type | Description |
| --- | --- | --- |
| `error` | string | required. Error identifier or legacy human-readable text returned by SendSMS. Not every handler exposes a stable machine code here. Check HTTP status and documented identifiers; never parse translated prose as a permanent code. |
| `message` | string | optional. Optional explanation generated by SendSMS. Intended for people; wording/language may change. Absence means the handler supplied no separate explanation. |
| `code` | string | optional. Optional machine-readable code generated by SendSMS or its HTTP framework. Meaning depends on the operation; not a universal numeric provider code. |
| `statusCode` | integer | optional. Optional HTTP status number generated by the server framework for a framework-level error. The actual HTTP response status is authoritative. |

### HTTP 404 — Resource unavailable to this account

```json
{
  "error": "string"
}
```

| Field | Type | Description |
| --- | --- | --- |
| `error` | string | required. Error identifier or legacy human-readable text returned by SendSMS. Not every handler exposes a stable machine code here. Check HTTP status and documented identifiers; never parse translated prose as a permanent code. |
| `message` | string | optional. Optional explanation generated by SendSMS. Intended for people; wording/language may change. Absence means the handler supplied no separate explanation. |
| `code` | string | optional. Optional machine-readable code generated by SendSMS or its HTTP framework. Meaning depends on the operation; not a universal numeric provider code. |
| `statusCode` | integer | optional. Optional HTTP status number generated by the server framework for a framework-level error. The actual HTTP response status is authoritative. |

### HTTP 429 — Rate limit

```json
{
  "error": "string"
}
```

| Field | Type | Description |
| --- | --- | --- |
| `error` | string | required. Error identifier or legacy human-readable text returned by SendSMS. Not every handler exposes a stable machine code here. Check HTTP status and documented identifiers; never parse translated prose as a permanent code. |
| `message` | string | optional. Optional explanation generated by SendSMS. Intended for people; wording/language may change. Absence means the handler supplied no separate explanation. |
| `code` | string | optional. Optional machine-readable code generated by SendSMS or its HTTP framework. Meaning depends on the operation; not a universal numeric provider code. |
| `statusCode` | integer | optional. Optional HTTP status number generated by the server framework for a framework-level error. The actual HTTP response status is authoritative. |

### HTTP 503 — Temporarily unavailable

```json
{
  "error": "string"
}
```

| Field | Type | Description |
| --- | --- | --- |
| `error` | string | required. Error identifier or legacy human-readable text returned by SendSMS. Not every handler exposes a stable machine code here. Check HTTP status and documented identifiers; never parse translated prose as a permanent code. |
| `message` | string | optional. Optional explanation generated by SendSMS. Intended for people; wording/language may change. Absence means the handler supplied no separate explanation. |
| `code` | string | optional. Optional machine-readable code generated by SendSMS or its HTTP framework. Meaning depends on the operation; not a universal numeric provider code. |
| `statusCode` | integer | optional. Optional HTTP status number generated by the server framework for a framework-level error. The actual HTTP response status is authoritative. |
