# Get message list

{% hint style="info" %}
**Note:**

* For APIs used for Shop, the API key is: [`<api_key>`](/api-etelecom-english/api-integration/shop/account.md). The base\_url information of the [Shop](/api-etelecom-english/api-integration/shop/account.md).
* For APIs used for Partner, the API key is: [`<shop_key>`](/api-etelecom-english/api-integration/partner/usage.md#retrieve-the-shop_key-information). The base\_url information of the [Partner](/api-etelecom-english/api-integration/partner/account.md).
  {% endhint %}

{% openapi src="/files/Nl7wo7S8NL8Y65YK73qK" path="$BASE\_URL.Zalo/ListMessages" method="post" %}
[(17-03-2025)\_\_swagger.json](https://1712041776-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FzzTMjVbVjwTuSbEGC7Ya%2Fuploads%2FsaksgaDXib4BdShCVqz4%2F\(17-03-2025\)__swagger.json?alt=media\&token=43a972b1-9cb0-48bb-825d-abe6a0b1437a)
{% endopenapi %}

**Request:**

```
curl --location '$BASE_URL.Zalo/ListMessages' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer $API_KEY' \
--data '{
  "filter": {
   "date_from": "2023-08-02T14:15:22Z",
    "date_to": "2023-08-03T14:15:22Z"
      },
  "paging": {
    "limit": 50
  }
}'
```

**Response:**

```
{
  "messages": [
    {
      "campaign_id": "string",
      "created_at": "2019-08-24T14:15:22Z",
      "delivery_status": "unknown",
      "delivery_time": "2019-08-24T14:15:22Z",
      "error_code": 0,
      "error_message": "string",
      "fee_main": 0,
      "fee_token": 0,
      "feedback": [
        "string"
      ],
      "id": "string",
      "is_charged": true,
      "is_development": true,
      "journey_id": "string",
      "msg_id": "string",
      "note": "string",
      "oa_id": "string",
      "phone": "string",
      "rate": 0,
      "sent_time": "2019-08-24T14:15:22Z",
      "shop_id": "string",
      "status": "Z",
      "submit_time": "2019-08-24T14:15:22Z",
      "template_data": {
        "property1": "string",
        "property2": "string"
      },
      "template_id": 0,
      "timeout": 0,
      "tracking_id": "string",
      "type": "unknown",
      "updated_at": "2019-08-24T14:15:22Z",
      "user_id": "string"
    }
  ],
  "paging": {
    "after": "string",
    "before": "string",
    "limit": 0,
    "next": "string",
    "prev": "string",
    "sort": "string"
  }
}
```

**Request body structure**

<table><thead><tr><th width="142">Parameters</th><th width="138">Data type</th><th>Describe</th></tr></thead><tbody><tr><td>campaign_id</td><td>int64</td><td>Campaign ID</td></tr><tr><td>id</td><td>string</td><td>OA ID</td></tr><tr><td>template_id</td><td>integer</td><td>ID of the message</td></tr><tr><td>journey_id</td><td>int64</td><td>Journey ID</td></tr><tr><td>msg_id</td><td>string</td><td>ZNS message ID</td></tr><tr><td>msg_type</td><td>string</td><td><mark style="color:red;"><strong>Enum: "unknown" "template" "journey" "uid"</strong></mark></td></tr><tr><td>is_charged</td><td>bool</td><td>Charge or not</td></tr><tr><td>is_development</td><td>boolean</td><td><p><mark style="color:red;"><strong><code>True</code></strong></mark>: ZNS message in experimental development mode</p><p><mark style="color:red;"><strong><code>False</code></strong></mark>: ZNS message is not in beta development mode</p></td></tr><tr><td>delivery_status</td><td>string</td><td><mark style="color:red;"><strong>Enum: "unknown" "received" "seen"</strong></mark></td></tr><tr><td>phone</td><td>string</td><td>Recipient phone number</td></tr><tr><td>status</td><td>string</td><td>Status <br><mark style="color:red;"><strong><code>Z</code></strong></mark>: Newly created <br><mark style="color:red;"><strong><code>P</code></strong></mark>: Enable <br><mark style="color:red;"><strong><code>N</code></strong></mark>: Disable</td></tr><tr><td>date_from</td><td>string&#x3C;date-time></td><td>Start date</td></tr><tr><td>date_to</td><td>string&#x3C;date-time></td><td>End date</td></tr><tr><td>time_type</td><td>string (otTimeFilter)</td><td><p><mark style="color:red;"><strong><code>request_time</code></strong></mark>: Time to send message</p><p><mark style="color:red;"><strong><code>updated_time</code></strong></mark>: Time of news update</p><p><mark style="color:red;"><strong><code>submit_time</code></strong></mark>: Update time of the review news </p><p><strong>Note</strong> : If the parameter <code>time_type</code>is not passed, default <code>time_type</code> <strong>=</strong><code>updated_time</code></p></td></tr><tr><td>tracking_id</td><td>string</td><td>Your API call tracking number, defined by you. You can use tracking_id for reconciliation without depending on the message_id provided by eTelecom.</td></tr></tbody></table>

**Return data attribute structure**

<table><thead><tr><th width="141">Parameters</th><th width="157"> Data type</th><th>Describe</th></tr></thead><tbody><tr><td>id</td><td>int64</td><td>Message ID on eTelecom system</td></tr><tr><td>shop_id</td><td>int64</td><td>Store ID on eTelecom system</td></tr><tr><td>user_id</td><td>int64</td><td>Sender ID on eTelecom system</td></tr><tr><td>campaign_id</td><td>int64</td><td>Campaign ID</td></tr><tr><td>delivery_status</td><td>string</td><td><p><mark style="color:red;"><strong><code>Unkown</code></strong></mark>: Unknown</p><p><mark style="color:red;"><strong><code>Received</code></strong></mark>: Received </p><p><mark style="color:red;"><strong><code>Seen</code></strong></mark>: Viewed</p></td></tr><tr><td>delivery_time</td><td>string&#x3C;date-time></td><td>Time the user's device receives the ZNS notification</td></tr><tr><td>error_code</td><td>int</td><td>Error code</td></tr><tr><td>error_message</td><td>string</td><td>Error message</td></tr><tr><td>fee_main</td><td>int</td><td>Main fee</td></tr><tr><td>fee_token</td><td>int</td><td>Token Creation Fee</td></tr><tr><td>is_charged</td><td>boolean</td><td><p><mark style="color:red;"><strong><code>True</code></strong></mark>: ZNS message is charged</p><p><mark style="color:red;"><strong><code>False</code></strong></mark>: ZNS message is free of charge</p></td></tr><tr><td>is_development</td><td>boolean</td><td><p><mark style="color:red;"><strong><code>True</code></strong></mark>: ZNS message in experimental development mode</p><p><mark style="color:red;"><strong><code>False</code></strong></mark>: ZNS message is not in beta development mode</p></td></tr><tr><td>journey_id</td><td>string</td><td>Journey ID</td></tr><tr><td>msg_id</td><td>string</td><td>ZNS message ID</td></tr><tr><td>type</td><td>string</td><td><p><mark style="color:red;"><strong><code>template</code></strong></mark>: ZNS usually</p><p><mark style="color:red;"><strong><code>journey</code></strong></mark>: ZNS journey</p></td></tr><tr><td>status</td><td>string</td><td><p>Status </p><p><mark style="color:red;"><strong><code>Z</code></strong></mark>: Newly created </p><p><mark style="color:red;"><strong><code>P</code></strong></mark>: Enable </p><p><mark style="color:red;"><strong><code>N</code></strong></mark>: Disable</p></td></tr><tr><td>rate</td><td>integer</td><td>Number of stars rated by customers</td></tr><tr><td>note</td><td>string</td><td>Additional customer notes</td></tr><tr><td>feedback</td><td>array</td><td>Customer reviews section</td></tr><tr><td>submit_time</td><td>string&#x3C;date-time></td><td>When customers submit reviews</td></tr><tr><td>template_data</td><td>object</td><td>Message parameters</td></tr><tr><td>phone</td><td>string</td><td>Recipient phone number</td></tr><tr><td>sent_time</td><td>string&#x3C;date-time></td><td>ZNS notification sending time</td></tr><tr><td>template_id</td><td>integer</td><td>ID of the message</td></tr><tr><td>timeout</td><td>integer</td><td>Maximum time required by the system to process the request</td></tr><tr><td>tracking_id</td><td>string</td><td>Your API call tracking number, defined by you. You can use tracking_id for reconciliation without depending on the message_id provided by eTelecom.</td></tr><tr><td>updated_at</td><td>string&#x3C;date-time></td><td>Update date</td></tr><tr><td>created_at</td><td>string&#x3C;date-time></td><td>Date created</td></tr></tbody></table>


---

# Agent Instructions: Querying This Documentation

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

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.etelecom.vn/api-etelecom-english/api-integration/zalo-cloud/zalo-cloud-api/get-message-list.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
