curl --request POST \
--url https://api.trata.ai/v1/metrics \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"requests": [
{
"id": "<string>",
"name": "CALLS",
"fromDate": "2023-12-25",
"toDate": "2023-12-25",
"aggregationPeriod": "MONTHLY",
"aggregationFormula": "COUNT"
}
]
}'
{
"responses": [
{
"id": "<string>",
"name": "CALLS",
"datapoints": [
{
"timestamp": "2023-12-25",
"value": "<string>"
}
]
}
]
}
Get fine grained analytics data from Trata AI like call, duration stats, etc.
curl --request POST \
--url https://api.trata.ai/v1/metrics \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"requests": [
{
"id": "<string>",
"name": "CALLS",
"fromDate": "2023-12-25",
"toDate": "2023-12-25",
"aggregationPeriod": "MONTHLY",
"aggregationFormula": "COUNT"
}
]
}'
{
"responses": [
{
"id": "<string>",
"name": "CALLS",
"datapoints": [
{
"timestamp": "2023-12-25",
"value": "<string>"
}
]
}
]
}
Bearer authentication header of the form Bearer <token>
, where <token>
is your auth token.
Successful Response
The response is of type object
.