Skip to main content
npayload is launching soon.
npayloadDocs
API ReferenceChannels

Get channel statistics

Returns message throughput, delivery stats, and performance metrics.

GET/v1/channels/{channelId}/stats

Authorization

ApiKeyAuth
AuthorizationBearer <token>

API key authentication. Keys are prefixed with environment:

  • npk_live_ for production
  • npk_test_ for testing/staging

In: header

Path Parameters

channelId*string

Channel ID

Query Parameters

period?string

Time period for statistics

Default"24h"
Value in"1h" | "24h" | "7d" | "30d"

Response Body

application/json

application/json

application/json

curl -X GET "https://api.npayload.com/v1/channels/string/stats"
{
  "channelId": "string",
  "period": "string",
  "messagesPublished": 0,
  "messagesDelivered": 0,
  "messagesFailed": 0,
  "avgLatencyMs": 0,
  "p95LatencyMs": 0,
  "p99LatencyMs": 0
}
{
  "error": {
    "code": "UNAUTHORIZED",
    "message": "Invalid or missing API key"
  }
}
{
  "error": {
    "code": "NOT_FOUND",
    "message": "Resource not found"
  }
}

Was this page helpful?