Get aggregate outbound SMS statistics
/v1/sms/stats/summaryconst summary = await bird.sms.stats.summary({
from: "2026-05-01", // both calendar days for a day window, or
to: "2026-05-31", // both RFC 3339 instants for an hour window
});
console.log(summary.delivery, summary.latency);summary = client.sms.stats.summary(from_="2026-05-01", to="2026-05-31")
print(summary.delivery, summary.latency)summary, err := client.Sms.Stats.Summary(context.Background(), bird.SmsStatsSummaryParams{
From: "2026-05-01", // a calendar day for a day-grain window (up to 365 days), or
To: "2026-05-31", // an RFC 3339 instant (e.g. "2026-05-01T00:00:00Z") for hour-grain (up to 720 hours)
})
if err != nil {
log.Fatal(err)
}
fmt.Println(*summary.Delivery.Accepted, *summary.Delivery.DeliveryRate)$summary = $bird->sms->stats->summary(['from' => '2026-05-01', 'to' => '2026-05-31']);
echo $summary->getDelivery()?->getAccepted(), ' ', $summary->getDelivery()?->getDeliveryRate();bird sms stats summarycurl -X GET "https://us1.platform.bird.com/v1/sms/stats/summary" \
-H "Authorization: Bearer $TOKEN"{
"period": {
"from": "2026-05-01",
"to": "2026-05-25",
"data_as_of": "2026-05-25T14:03:10Z"
},
"delivery": {
"accepted": 14820,
"sent": 14810,
"delivered": 14720,
"undelivered": 60,
"failed": 25,
"rejected": 10,
"expired": 5,
"delivery_rate": 0.9932,
"failure_rate": 0.0061
},
"latency": {
"processing": {
"p50_ms": 420,
"p95_ms": 1820,
"p99_ms": 4920
},
"delivery": {
"p50_ms": 420,
"p95_ms": 1820,
"p99_ms": 4920
},
"total": {
"p50_ms": 420,
"p95_ms": 1820,
"p99_ms": 4920
}
},
"comparison": {
"period": {
"from": "2026-05-01",
"to": "2026-05-25",
"data_as_of": "2026-05-25T14:03:10Z"
},
"delivery": {
"accepted": 14820,
"sent": 14810,
"delivered": 14720,
"undelivered": 60,
"failed": 25,
"rejected": 10,
"expired": 5,
"delivery_rate": 0.9932,
"failure_rate": 0.0061
},
"latency": {
"processing": {
"p50_ms": 420,
"p95_ms": 1820,
"p99_ms": 4920
},
"delivery": {
"p50_ms": 420,
"p95_ms": 1820,
"p99_ms": 4920
},
"total": {
"p50_ms": 420,
"p95_ms": 1820,
"p99_ms": 4920
}
},
"delta": {
"accepted_pct_change": 0.508,
"sent_pct_change": 0.121,
"delivered_pct_change": 0.122,
"undelivered_pct_change": -0.031,
"failed_pct_change": -0.018,
"rejected_pct_change": 0,
"expired_pct_change": 0.04,
"delivery_rate_pp": 0.004,
"failure_rate_pp": -0.0008
}
}
}
Returns one aggregate row for the requested period. It includes SMS lifecycle counts, delivery and failure rates, and processing, delivery, and total latency percentiles (p50, p95, and p99). Rows use send-time attribution, so recent periods can under-report delivered while delivery reports arrive.
Rate fields are null when their denominator is zero. For example, delivery_rate is null when no message was accepted.
from and to must both be days or RFC 3339 instants. Day windows cover up to 365 days. Instant bounds round down to the hour and may span up to 720 hours. Mixing the forms returns 422. Set timezone for local boundaries, one dimension filter at most, or compare=previous_period for the preceding equal-length window.
Query Parameters
fromstringInclusive start of the window: a calendar day (YYYY-MM-DD) or an RFC 3339 instant rounded down to the hour. The timezone parameter makes a calendar day local and rounds an instant down to the local hour. Omit timezone to use UTC. When timezone is set, a numeric UTC offset such as +05:45 is rejected; use a calendar day or a Z (UTC) instant. This value must use the same form as to. When omitted, it defaults to 30 days before to for day windows or 168 hours (7 days) before to for hour windows.
tostringInclusive end of the window: a calendar day (YYYY-MM-DD) or an RFC 3339 instant rounded down to the hour. The timezone parameter makes a calendar day local and rounds an instant down to the local hour. Omit timezone to use UTC. When timezone is set, a numeric UTC offset is rejected; use a calendar day or a Z (UTC) instant. This value must use the same form as from. When omitted, it defaults to today for day windows or the current hour for hour windows in that timezone. Day windows may not exceed 365 days; hour windows may not exceed 720 hours (30 days).
timezonestringIANA 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.
originatorstringRestrict the statistics to a single originator (the sender address messages were sent from). Mutually exclusive with the other dimension filters (country, category, carrier); only one may be set per request. Matches the message from.
countrystringRestrict the statistics to a single destination country, as an ISO 3166-1 alpha-2 code. Mutually exclusive with the other dimension filters (originator, category, carrier); only one may be set per request.
categorystringRestrict the statistics to a single category. Mutually exclusive with the other dimension filters (originator, country, carrier); only one may be set per request.
carrierstringRestrict the statistics to a single delivery carrier. Mutually exclusive with the other dimension filters (originator, country, category); only one may be set per request.
comparestringSet to previous_period to also include the same statistics for the immediately preceding window of equal length, plus the change between the two, so you can show "+X% vs last period" without a second request.
Possible values: previous_period
Response Payload
periodThe window the response covers (echoed back from the request, day or hour grain), plus data_as_of, the freshness boundary the data is current to.
Show child attributes
period.fromInclusive start of the window, as a calendar day (YYYY-MM-DD) or an RFC 3339 hour boundary.
period.toInclusive end of the window, as a calendar day (YYYY-MM-DD) or an RFC 3339 hour boundary.
period.data_as_ofLatest time reflected in the statistics. More recent events might not be included yet. Null when the freshness boundary is unavailable.
deliveryShow child attributes
delivery.acceptedDistinct messages accepted for sending after admission checks. This is the denominator for delivery_rate and failure_rate.
delivery.sentDistinct messages handed off to the carrier for delivery.
delivery.deliveredDistinct messages the carrier confirmed as delivered to the handset.
delivery.undeliveredDistinct messages the carrier reported as not delivered.
delivery.failedDistinct messages that failed during sending.
delivery.rejectedDistinct messages rejected before any send attempt, for example by sending policy or a message-generation failure.
delivery.expiredDistinct messages that could not be delivered within their validity window and expired.
delivery.delivery_rateShare of accepted messages that were delivered, computed as delivered / accepted. Null when no messages were accepted in scope.
delivery.failure_rateShare of accepted messages that ultimately failed, computed as (undelivered + failed + expired) / accepted. Null when no messages were accepted in scope.
latencyShow child attributes
latency.processingApproximate p50, p95, and p99 latency percentiles in milliseconds for one latency family. All three are null when no qualifying event contributed a measurement.
Show child attributes
latency.processing.p50_msMedian (50th percentile) latency in milliseconds. Null when no qualifying event contributed a measurement.
latency.processing.p95_ms95th percentile latency in milliseconds. Null when no qualifying event contributed a measurement.
latency.processing.p99_ms99th percentile latency in milliseconds. Null when no qualifying event contributed a measurement.
latency.deliveryApproximate p50, p95, and p99 latency percentiles in milliseconds for one latency family. All three are null when no qualifying event contributed a measurement.
Show child attributes
latency.delivery.p50_msMedian (50th percentile) latency in milliseconds. Null when no qualifying event contributed a measurement.
latency.delivery.p95_ms95th percentile latency in milliseconds. Null when no qualifying event contributed a measurement.
latency.delivery.p99_ms99th percentile latency in milliseconds. Null when no qualifying event contributed a measurement.
latency.totalApproximate p50, p95, and p99 latency percentiles in milliseconds for one latency family. All three are null when no qualifying event contributed a measurement.
Show child attributes
latency.total.p50_msMedian (50th percentile) latency in milliseconds. Null when no qualifying event contributed a measurement.
latency.total.p95_ms95th percentile latency in milliseconds. Null when no qualifying event contributed a measurement.
latency.total.p99_ms99th percentile latency in milliseconds. Null when no qualifying event contributed a measurement.
comparisonShow child attributes
comparison.periodEqual-length window ending immediately before the requested start.
Show child attributes
comparison.period.fromInclusive start of the window, as a calendar day (YYYY-MM-DD) or an RFC 3339 hour boundary.
comparison.period.toInclusive end of the window, as a calendar day (YYYY-MM-DD) or an RFC 3339 hour boundary.
comparison.period.data_as_ofLatest time reflected in the statistics. More recent events might not be included yet. Null when the freshness boundary is unavailable.
comparison.deliveryShow child attributes
comparison.delivery.acceptedDistinct messages accepted for sending after admission checks. This is the denominator for delivery_rate and failure_rate.
comparison.delivery.sentDistinct messages handed off to the carrier for delivery.
comparison.delivery.deliveredDistinct messages the carrier confirmed as delivered to the handset.
comparison.delivery.undeliveredDistinct messages the carrier reported as not delivered.
comparison.delivery.failedDistinct messages that failed during sending.
comparison.delivery.rejectedDistinct messages rejected before any send attempt, for example by sending policy or a message-generation failure.
comparison.delivery.expiredDistinct messages that could not be delivered within their validity window and expired.
comparison.delivery.delivery_rateShare of accepted messages that were delivered, computed as delivered / accepted. Null when no messages were accepted in scope.
comparison.delivery.failure_rateShare of accepted messages that ultimately failed, computed as (undelivered + failed + expired) / accepted. Null when no messages were accepted in scope.
comparison.latencyShow child attributes
comparison.latency.processingApproximate p50, p95, and p99 latency percentiles in milliseconds for one latency family. All three are null when no qualifying event contributed a measurement.
Show child attributes
comparison.latency.processing.p50_msMedian (50th percentile) latency in milliseconds. Null when no qualifying event contributed a measurement.
comparison.latency.processing.p95_ms95th percentile latency in milliseconds. Null when no qualifying event contributed a measurement.
comparison.latency.processing.p99_ms99th percentile latency in milliseconds. Null when no qualifying event contributed a measurement.
comparison.latency.deliveryApproximate p50, p95, and p99 latency percentiles in milliseconds for one latency family. All three are null when no qualifying event contributed a measurement.
Show child attributes
comparison.latency.delivery.p50_msMedian (50th percentile) latency in milliseconds. Null when no qualifying event contributed a measurement.
comparison.latency.delivery.p95_ms95th percentile latency in milliseconds. Null when no qualifying event contributed a measurement.
comparison.latency.delivery.p99_ms99th percentile latency in milliseconds. Null when no qualifying event contributed a measurement.
comparison.latency.totalApproximate p50, p95, and p99 latency percentiles in milliseconds for one latency family. All three are null when no qualifying event contributed a measurement.
Show child attributes
comparison.latency.total.p50_msMedian (50th percentile) latency in milliseconds. Null when no qualifying event contributed a measurement.
comparison.latency.total.p95_ms95th percentile latency in milliseconds. Null when no qualifying event contributed a measurement.
comparison.latency.total.p99_ms99th percentile latency in milliseconds. Null when no qualifying event contributed a measurement.
comparison.deltaShow child attributes
comparison.delta.accepted_pct_changeRelative change in accepted messages (delivery.accepted) versus the previous period, as a signed fraction. Null when the previous period accepted none.
comparison.delta.sent_pct_changeRelative change in sent messages (delivery.sent) versus the previous period, as a signed fraction. Null when the previous period had none.
comparison.delta.delivered_pct_changeRelative change in delivered messages (delivery.delivered) versus the previous period, as a signed fraction. Null when the previous period delivered none.
comparison.delta.undelivered_pct_changeRelative change in undelivered messages (delivery.undelivered) versus the previous period, as a signed fraction. Null when the previous period had none.
comparison.delta.failed_pct_changeRelative change in failed messages (delivery.failed) versus the previous period, as a signed fraction. Null when the previous period had none.
comparison.delta.rejected_pct_changeRelative change in rejected messages (delivery.rejected) versus the previous period, as a signed fraction. Null when the previous period had none.
comparison.delta.expired_pct_changeRelative change in expired messages (delivery.expired) versus the previous period, as a signed fraction. Null when the previous period had none.
comparison.delta.delivery_rate_ppSigned difference between this period's and the previous period's delivery rate, both fractions in [0,1] (multiply by 100 for percentage points). Null when either period's delivery rate is undefined.
comparison.delta.failure_rate_ppSigned difference between the current and previous failure-rate fractions. Multiply by 100 for percentage points. The value can fall outside [-1, 1] because a message can contribute to more than one failure outcome and high-volume counts are approximate. Null when either rate is undefined.
Related resources
Continue with the documentation, guides and examples for this topic.