Skip to content

Get daily usage trend for a subscription

GET
/v1/subscriptions/{subscription_id}/usage_trend

Get aggregated daily usage trend data for a subscription.

Returns daily data points with usage value and event count summed across all metrics. Defaults to the last 30 days if no dates provided.

subscription_id
required
Subscription Id
string format: uuid
start_date
Any of:
string format: date

Start date (inclusive)

end_date
Any of:
string format: date

End date (inclusive)

Successful Response

UsageTrendResponse

Response schema for subscription usage trend.

object
subscription_id
required
Subscription Id
string format: uuid
start_date
required
Start Date
string format: date
end_date
required
End Date
string format: date
data_points
required
Data Points
Array<object>
UsageTrendPoint

A single data point in the usage trend.

object
date
required
Date
string format: date
value
required
Value
string
/^(?!^[-+.]*$)[+-]?0*\d*\.?\d*$/
events_count
required
Events Count
integer

Unauthorized – invalid or missing API key

Subscription not found

Validation Error

HTTPValidationError
object
detail
Detail
Array<object>
ValidationError
object
loc
required
Location
Array
msg
required
Message
string
type
required
Error Type
string
input
Input
ctx
Context
object