Retrieve messaging profile metrics
GET/messaging_profiles/:id/metrics
Retrieve messaging profile metrics
Request
Path Parameters
id uuidrequired
The id of the messaging profile to retrieve
Query Parameters
time_frame string
Possible values: [1h
, 3h
, 24h
, 3d
, 7d
, 30d
]
Default value: 24h
The timeframe for which you'd like to retrieve metrics.
Responses
200: Successful response with details about a messaging profile's metrics.
- application/json
default: Unexpected error
- application/json
Request samples
curl -L 'https://api.telnyx.com/v2/messaging_profiles/:id/metrics' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <TOKEN>'
Response samples
{
"data": {
"detailed": [
{
"metrics": [
{
"label": "longcode",
"sent": 1000,
"delivered": 990,
"errors": 0.01,
"received": 750
}
],
"timestamp": "2019-01-23T18:10:02.574Z"
}
],
"overview": {
"record_type": "messaging_profile_metrics",
"messaging_profile_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"phone_numbers": 250,
"outbound": {
"sent": 1000,
"delivered": 990,
"errors": 0.01
},
"inbound": {
"received": 850
}
}
}
}
{
"errors": [
{
"code": "string",
"title": "string",
"detail": "string",
"source": {
"pointer": "string",
"parameter": "string"
},
"meta": {}
}
]
}