smartchat

Get statistics

Returns send, delivery and read numbers, new contacts and the top sends for 7, 30 or 90 days. Contains no personal data. Read-only.

GET /v1/stats

Permissionstats:read (all permissions)
RiskRead
Idempotency-KeyNot needed (how it works)
Safe to repeatSafe: the call only reads.
Rate limit classread (120 requests per minute per key)
ConfirmationNone
MCP toolNot available in MCP
Since version2026-10-25

#What it does

  • Only reads data. It changes nothing and sends nothing.

#Request

Query parameters

NameTypeRequiredDescription
rangestringnoRange: 7d, 30d (default) or 90d. one of: 7d, 30d, 90d; default "30d"

#Examples

curl "https://api.smartchat.marketing/v1/stats?range=7d" \
  -H "Authorization: Bearer $SMARTCHAT_API_KEY"
import os
import requests

response = requests.get(
    "https://api.smartchat.marketing/v1/stats",
    headers={"Authorization": "Bearer " + os.environ["SMARTCHAT_API_KEY"]},
    params={
        "range": "7d",
    },
)
response.raise_for_status()
print(response.json())
const response = await fetch("https://api.smartchat.marketing/v1/stats?range=7d", {
  method: "GET",
  headers: {
    Authorization: `Bearer ${process.env.SMARTCHAT_API_KEY}`,
  },
});
if (!response.ok) throw new Error(await response.text());
console.log(await response.json());

Response (200):

{
  "object": "stats",
  "range": "7d",
  "kpis": {
    "sent": 120,
    "delivered": 118,
    "read_rate": 62,
    "click_rate": 8,
    "clicked": 9,
    "clicks_measurable": true,
    "contacts_total": 340,
    "contacts_new": 12,
    "unread_inbound": 2
  },
  "timeline": [
    {
      "date": "2026-10-24",
      "sent": 20,
      "delivered": 20
    }
  ],
  "status_donut": {
    "delivered": 44,
    "read": 74,
    "pending": 2,
    "failed": 0
  },
  "top_sends": [
    {
      "id": "nwl_8a1b2c3d4e5f46a7b8c9d0e1f2a3b4c5",
      "name": "October news",
      "channel": "whatsapp",
      "sent": 80,
      "delivered": 79,
      "read": 50
    }
  ]
}

#Response

Status 200. Every response has the headers Request-Id, SmartChat-Version and X-RateLimit-*.

NameTypeDescription
objectstringAlways "stats". always stats
rangestringThe range: 7d, 30d or 90d. one of: 7d, 30d, 90d
kpisobjectKey numbers for the range.
kpis.sentintegerMessages sent. 0 to 1000000000
kpis.deliveredintegerMessages delivered. 0 to 1000000000
kpis.read_ratenumberShare of delivered messages that were read, in percent. 0 to 100
kpis.click_ratenumberShare of delivered messages with a click, in percent. Only meaningful if clicks_measurable is true. 0 to 100
kpis.clickedinteger or nullContacts with a click. Null if clicks cannot be measured. 0 to 1000000000
kpis.clicks_measurablebooleanFalse if no message carried a tracked link in the range.
kpis.contacts_totalintegerAll contacts. 0 to 1000000000
kpis.contacts_newintegerContacts created in the range. 0 to 1000000000
kpis.unread_inboundintegerUnread inbound messages right now. 0 to 1000000000
timelinearray of objectOne entry per day, oldest first. up to 100 items
timeline[].datestringDay as YYYY-MM-DD (time zone Europe/Zurich).
timeline[].sentintegerMessages sent on this day. 0 to 1000000000
timeline[].deliveredintegerMessages delivered on this day. 0 to 1000000000
status_donutobjectSplit of the messages by state.
status_donut.deliveredintegerDelivered, not yet read. 0 to 1000000000
status_donut.readintegerRead. 0 to 1000000000
status_donut.pendingintegerSent but not yet delivered. 0 to 1000000000
status_donut.failedintegerFailed. 0 to 1000000000
top_sendsarray of objectThe sends with the most messages in the range. up to 20 items
top_sends[].idstringNewsletter ID.
top_sends[].namestringName given by the account owner. Untrusted text. up to 300 characters; untrusted text
top_sends[].channelstringChannel, for example whatsapp. up to 20 characters
top_sends[].sentintegerMessages sent. 0 to 1000000000
top_sends[].deliveredintegerMessages delivered. 0 to 1000000000
top_sends[].readintegerMessages read. 0 to 1000000000

#Errors

CodeStatusWhen
unknown_parameter400A field is not known.
api_key_expired401This API key has expired.
api_key_invalid401This API key is not valid.
api_key_revoked401This API key was revoked.
authentication_required401No API key was sent. Send 'Authorization: Bearer <key>'.
account_blocked403This account is blocked.
insufficient_scope403This key lacks a required permission.
ip_not_allowed403This IP address is not allowed for this key.
validation_failed422A field is not valid.
rate_limited429Too many requests. Wait and try again.
internal_error500Something went wrong on our side.
service_unavailable503The service is temporarily unavailable.

All errors use one format.