Analytics
Get pricing analytics
POST
/
v1
/
channels
/
{channelID}
/
analytics
/
pricing
Get pricing analytics
curl --request POST \
--url https://api.wazapin.com/v1/channels/{channelID}/analytics/pricing \
--header 'Content-Type: application/json' \
--data '
{
"end": 123,
"start": 123,
"country_codes": [
"<string>"
],
"dimensions": [
"<string>"
],
"metric_types": [
"<string>"
],
"phone_numbers": [
"<string>"
],
"pricing_categories": [
"<string>"
],
"pricing_types": [
"<string>"
]
}
'const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
end: 123,
start: 123,
country_codes: ['<string>'],
dimensions: ['<string>'],
metric_types: ['<string>'],
phone_numbers: ['<string>'],
pricing_categories: ['<string>'],
pricing_types: ['<string>']
})
};
fetch('https://api.wazapin.com/v1/channels/{channelID}/analytics/pricing', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.wazapin.com/v1/channels/{channelID}/analytics/pricing"
payload = {
"end": 123,
"start": 123,
"country_codes": ["<string>"],
"dimensions": ["<string>"],
"metric_types": ["<string>"],
"phone_numbers": ["<string>"],
"pricing_categories": ["<string>"],
"pricing_types": ["<string>"]
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"data": [
{
"data_points": [
{
"conversation": 123,
"conversation_category": "<string>",
"conversation_direction": "<string>",
"conversation_type": "<string>",
"cost": 123,
"country": "<string>",
"delivered": 123,
"end": 123,
"phone_number": "<string>",
"pricing_category": "<string>",
"pricing_type": "<string>",
"sent": 123,
"start": 123,
"volume": 123
}
]
}
]
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}Path Parameters
Channel ID
Body
application/json
End timestamp (Unix epoch)
Data granularity
Available options:
DAY, HOUR, HALF_HOUR Start timestamp (Unix epoch)
Filter by country codes
Dimensions for breakdown
Metric types
Filter by phone numbers
Pricing categories
Pricing types
Response
OK
Show child attributes
Show child attributes
⌘I
Get pricing analytics
curl --request POST \
--url https://api.wazapin.com/v1/channels/{channelID}/analytics/pricing \
--header 'Content-Type: application/json' \
--data '
{
"end": 123,
"start": 123,
"country_codes": [
"<string>"
],
"dimensions": [
"<string>"
],
"metric_types": [
"<string>"
],
"phone_numbers": [
"<string>"
],
"pricing_categories": [
"<string>"
],
"pricing_types": [
"<string>"
]
}
'const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
end: 123,
start: 123,
country_codes: ['<string>'],
dimensions: ['<string>'],
metric_types: ['<string>'],
phone_numbers: ['<string>'],
pricing_categories: ['<string>'],
pricing_types: ['<string>']
})
};
fetch('https://api.wazapin.com/v1/channels/{channelID}/analytics/pricing', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.wazapin.com/v1/channels/{channelID}/analytics/pricing"
payload = {
"end": 123,
"start": 123,
"country_codes": ["<string>"],
"dimensions": ["<string>"],
"metric_types": ["<string>"],
"phone_numbers": ["<string>"],
"pricing_categories": ["<string>"],
"pricing_types": ["<string>"]
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"data": [
{
"data_points": [
{
"conversation": 123,
"conversation_category": "<string>",
"conversation_direction": "<string>",
"conversation_type": "<string>",
"cost": 123,
"country": "<string>",
"delivered": 123,
"end": 123,
"phone_number": "<string>",
"pricing_category": "<string>",
"pricing_type": "<string>",
"sent": 123,
"start": 123,
"volume": 123
}
]
}
]
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": [
{
"message": "<string>",
"code": "<string>",
"field": "<string>",
"location": "<string>"
}
],
"request_id": "<string>"
}
}