> For the complete documentation index, see [llms.txt](https://docs.miatel.com/api/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.miatel.com/api/sms-api/receive-sms-status.md).

# Receive SMS status

There are two ways to get SMS status:

## Refer to our link <a href="#refer-to-our-link" id="refer-to-our-link"></a>

It is required to refer to our link `https://sms-hub.miatel.com:8009/sms_status?id={{message_id}}` where `{{message_id}}` is the received message id when sending the request.

### **Response body**

| Name     | Type   | Description                                                                     |
| -------- | ------ | ------------------------------------------------------------------------------- |
| currency | string | Currency of use                                                                 |
| rate     | string | Used rate plan if set                                                           |
| segments | number | Number of short messages delivered. The value may be padded with leading zeros. |
| status   | number | The final code status of the message                                            |

### **Possible code statuses of the message**

<table><thead><tr><th width="245">Status</th><th>Status name</th><th>Description</th></tr></thead><tbody><tr><td>1</td><td>ENROUTE</td><td>The message is in enroute state</td></tr><tr><td>2</td><td>DELIVERED</td><td>Message is delivered to destination</td></tr><tr><td>3</td><td>EXPIRED</td><td>Message validity period has expired</td></tr><tr><td>4</td><td>DELETED</td><td>Message has been deleted</td></tr><tr><td>5</td><td>UNDELIVERABLE</td><td>Message is undeliverable</td></tr><tr><td>6</td><td>ACCEPTED</td><td><p>Message is in accepted state (i.e. has been manually read on behalf of the subscriber by customer service)</p><p><br></p><p>This status is not considered as final on the Miatel platform.</p></td></tr><tr><td>7</td><td>UNKNOWN</td><td>Message is in invalid state</td></tr><tr><td>8</td><td>REJECTED</td><td>Message is in a rejected state</td></tr></tbody></table>

### **Response example**

```
200400{"currency": "EUR","rate": "0.1","segments": 1,"status": 2}
```

## Provide a link <a href="#provide-a-link" id="provide-a-link"></a>

You provide a link to which we will refer to inform the status of the subscriber.

### Link example&#x20;

`https://api.client.com/miatel/res.php?id={{id}}&dlvr={{dlvrd}}&status={{status}}&{{statusname}}`

### Supported parameters

The URI string can contain these keywords to be replaced by real values.&#x20;

| Field          | Type   | Description                                                                                |
| -------------- | ------ | ------------------------------------------------------------------------------------------ |
| {{id}}         | string | The message ID allocated to the message by the SMSC when originally submitted.             |
| {{from}}       | string | Source side                                                                                |
| {{to}}         | string | Destination side                                                                           |
| {{status}}     | number | The final code status of the message.                                                      |
| {{sub}}        | number | Number of short messages originally submitted. The value may be padded with leading zeros. |
| {{dlvrd}}      | number | Number of short messages delivered. The value may be padded with leading zeros.            |
| {{statusname}} | string | The final status of the message.                                                           |


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.miatel.com/api/sms-api/receive-sms-status.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
