Documentation
Sign inGet started

Get aggregate inbound SMS statistics

GET
/v1/sms/stats/inbound/summary
const summary = await bird.sms.stats.inbound.summary({ from: "2026-05-01", to: "2026-05-31" });
console.log(summary.received);
Response200
{
  "period": {
    "from": "2026-05-01T00:00:00Z",
    "to": "2026-05-25T00:00:00Z",
    "data_as_of": "2026-05-25T14:03:10Z"
  },
  "received": 4210,
  "comparison": {
    "period": {
      "from": "2026-05-01T00:00:00Z",
      "to": "2026-05-25T00:00:00Z",
      "data_as_of": "2026-05-25T14:03:10Z"
    },
    "received": 3980,
    "delta": {
      "received_pct_change": 0.058
    }
  }
}
Returns the total number of messages your numbers received over the period, using the time the carrier received each message.
The response contains only a count because a received message has one state. Use the outbound statistics endpoints for delivery rates and latency data about messages you send.
The maximum window is 365 days; a longer range returns 422. Set timezone to resolve the period against your local calendar instead of UTC.
Query Parameters
from
string
Inclusive start of the window, either a calendar day (YYYY-MM-DD) or an RFC 3339 instant rounded down to the hour. The form you use selects the grain the total is resolved at. Interpreted in timezone, or in UTC when timezone is omitted. Must use the same form as to. A numeric UTC offset (for example +05:45) is rejected when timezone is set; pass a calendar day or a Z instant instead. Defaults to 30 days before to for day windows, or 168 hours before to for hour windows.
to
string
Inclusive end of the window, in the same form as from. Defaults to today, or the current hour for an hour window. A day window may not exceed 365 days and an hour window 720 hours.
timezone
string
IANA timezone identifier used to group statistics, for example Asia/Kathmandu. The default is UTC. Day and hour boundaries, including the default window when from and to are omitted, follow this timezone. When this parameter is set, pass from and to as calendar days or Z instants instead of timestamps with explicit UTC offsets.
compare
string
Set to previous_period to include the received-message count for the immediately preceding window of equal length. The response also includes the change between the two, so you can show "+X% vs last period" without a second request.
Possible values: previous_period
Response Payload
period
object
required
The window the server actually computed against. The summary serves two window grains: calendar days (bounds are YYYY-MM-DD) and hours (bounds are RFC 3339 instants on the hour). The grain of from and to mirrors the grain of the request's bounds.
Show child attributes
period.from
string
required
Inclusive start of the window, as a calendar day (YYYY-MM-DD) or an RFC 3339 hour boundary.
period.to
string
required
Inclusive end of the window, as a calendar day (YYYY-MM-DD) or an RFC 3339 hour boundary.
period.data_as_of
nullable string
Latest time reflected in the statistics. More recent events might not be included yet. Null when the freshness boundary is unavailable.
received
integer
required
Distinct messages received in the period, counted by the time the carrier received them.
comparison
object
Show child attributes
comparison.period
object
required
Equal-length window ending immediately before the requested start.
Show child attributes
comparison.period.from
string
required
Inclusive start of the window, as a calendar day (YYYY-MM-DD) or an RFC 3339 hour boundary.
comparison.period.to
string
required
Inclusive end of the window, as a calendar day (YYYY-MM-DD) or an RFC 3339 hour boundary.
comparison.period.data_as_of
nullable string
Latest time reflected in the statistics. More recent events might not be included yet. Null when the freshness boundary is unavailable.
comparison.received
integer
required
Distinct messages received in the preceding period.
comparison.delta
object
required
Show child attributes
comparison.delta.received_pct_change
nullable number
required
Relative change in received messages versus the previous period, as a signed fraction. Null when the previous period received none.