# Return a message's delivery status

> **GET** `https://api.us.nylas.com/v3/activity/send/messages/{message_id}`

Source: https://developer.nylas.com/docs/reference/api/send-events/get-message-send-events/

Returns the delivery timeline of one message for each of its recipients: when Nylas accepted it,
and whether it was delivered, bounced, marked as spam, or rejected. Use it to check whether a message
reached a recipient and, if it didn't, why. Covers messages sent in the last 90 days.

**Authentication:** NYLAS_API_KEY

## Parameters

### Path parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `message_id` | string, maxLength: 512 | Yes | The ID of the message. For an Agent Account send, this is the message ID the send returned. For a transactional send, it's the message's `Message-ID` header, such as `<0100019a1b2c3d4e@mail.example.com>`. Percent-encode it in the path: `%3C0100019a1b2c3d4e%40mail.example.com%3E`. |

## Responses

### 200 - Success. Returns the message and each recipient's events.

- `request_id` (string) - The request ID.
- `data` (object) - A message and what happened to it for each recipient.
  - `message` (object) - The message.
    - `message_id` (string) - The ID of the message.
    - `thread_id` (string) - The Agent Account thread the message belongs to. Empty for a transactional send.
    - `grant_id` (string) - The Agent Account grant that sent the message. Empty for a transactional send.
    - `application_id` (string) - The ID of your Nylas application.
    - `from` (string) - The email address the message was sent from.
    - `sending_domain` (string) - The domain the message was sent from.
    - `subject` (string) - The message subject.
    - `sent_at` (integer, format: int64) - When Nylas accepted the message, as a Unix timestamp in seconds.
    - `last_event_at` (integer, format: int64) - When the most recent event for any recipient happened, as a Unix timestamp in seconds.
  - `recipients` (array) - One entry per recipient, sorted by email address.
    - `recipient` (string) - The recipient's email address.
    - `recipient_domain` (string) - The recipient's domain.
    - `current_status` (string, one of: `accepted`, `delivered`, `bounced`, `complaint`, `rejected`) - The recipient's latest status.
    - `bounce_class` (string, one of: `hard`, `soft`, `undetermined`) - When `current_status` is `bounced`, whether the bounce is permanent, temporary, or unclassified.
    - `events` (array) - Everything that happened for this recipient, oldest first.
      - `id` (string) - The ID of the event.
      - `event_type` (string, one of: `accepted`, `delivered`, `bounced`, `complaint`, `rejected`) - What happened.
      - `timestamp` (integer, format: int64) - When the event happened, as a Unix timestamp in seconds.
      - `bounce_class` (string, one of: `hard`, `soft`, `undetermined`) - For a bounce, whether it's permanent, temporary, or unclassified.
      - `reason` (string) - A short summary of why the event happened. Empty for `accepted`.
      - `detail` (object) - Delivery details reported by the recipient's mail server. Only the fields that apply to the event
are included.
        - `smtp_response` (string) - The SMTP response from the recipient's mail server.
        - `processing_time_ms` (integer) - How long delivery took, in milliseconds.
        - `reporting_mta` (string) - The mail server that reported the event.
        - `remote_mta_ip` (string) - The IP address of the recipient's mail server.
        - `bounce_type` (string) - The bounce type, such as `Permanent` or `Transient`.
        - `bounce_subtype` (string) - The bounce subtype, such as `General`, `NoEmail`, `MailboxFull`, or `Suppressed`. `Suppressed`
means the address is on a suppression list because of an earlier bounce or complaint.
        - `status` (string) - The enhanced SMTP status code.
        - `action` (string) - The delivery action the mail server reported.
        - `diagnostic_code` (string) - The diagnostic message from the recipient's mail server.
        - `feedback_type` (string) - For a complaint, the type of feedback the mailbox provider reported, such as `abuse`.
        - `complaint_subtype` (string) - For a complaint, the complaint subtype, if the provider reported one.

### 401 - Unauthorized

- `request_id` (string) - The request ID.
- `error` (object) - The response error object.
  - `type` (string) - The error type.
  - `message` (string) - The error message.
  - `provider_error` (object) - The error from the provider.

### 403 - Forbidden. These endpoints need your application's API key, not a grant access token.

- `request_id` (string) - The request ID.
- `error` (object) - The response error object.
  - `type` (string) - The error type.
  - `message` (string) - The error message.

### 404 - Not found. Nylas has no send events for this ID in the last 90 days.

- `request_id` (string) - The request ID.
- `error` (object) - The response error object.
  - `type` (string) - The error type.
  - `message` (string) - The error message.

## Code samples

### cURL

```bash
curl --request GET \
  --url "https://api.us.nylas.com/v3/activity/send/messages/<MESSAGE_ID>" \
  --header 'Accept: application/json' \
  --header 'Authorization: Bearer <NYLAS_API_KEY>'
```
