---
title: "Get messaging statistics"
method: GET
path: "/api/v2/stats/messaging"
tags: ["Statistic"]
---

# Get messaging statistics

`GET /api/v2/stats/messaging`

<a class="try-sandbox-link" href="https://sandbox.textmagic.com/#/Statistics/getMessagingStat" target="_blank">Try in sandbox</a><br>

## Query parameters

- `by` 'off' | 'day' | 'month' | 'year'
- `start` integer
- `end` integer

## Response `200`

Returned when successful.

- MessagingStatItem[]
  - `replyRate` number, float, nullable, required — The number of incoming messages divided by the number of total messages.
  - `date` string, date-time, nullable, required — Time interval start: empty if the **by** parameter was set to **off**.
  - `deliveryRate` number, float, nullable, required — Message delivery rate:the number of delivered messages divided by the number of total messages.
  - `costs` number, float, nullable, required — Cost for sent messages during this period. The costs are in the [Account](https://docs.textmagic.com/#tag/User) currency.
  - `messagesReceived` integer, nullable, required — Total received messages count.
  - `messagesSentDelivered` integer, nullable, required — Delivered messages count. As messages are retried for up to 48 hours, this value could change.
  - `messagesSentAccepted` integer, nullable, required — Messages accepted for delivery (in queue) but not yet delivered.
  - `messagesSentBuffered` integer, nullable, required — Messages buffered by endpoint cell phone operators.
  - `messagesSentFailed` integer, nullable, required — Messages that have failed for whatever reason, e.g. the destination phone was switched off for 48 hours or the recipient's phone account is out of service.
  - `messagesSentRejected` integer, nullable, required — Messages that were rejected: invalid Sender ID used (e.g. you cannot use the Sender ID or your own mobile number when sending to the United States and Canada.)
  - `messagesSentParts` integer, nullable, required — Total sent messages **parts** count. Note that this is not equal to the sent messages count, because one message could consist of 1 to 6 parts and users are charged per part, not per message.

## Other responses

- `400` — Bad request.
- `401` — Unauthorized request.

---

[API](https://skmtc.net/textmagic/apis/textmagic-api.md) · [All operations](https://skmtc.net/textmagic/apis/textmagic-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/textmagic/textmagic-api/revisions/3e4029d19684/schema)
