Get Characters Usage Metrics
Returns the credit usage metrics for the current user or the entire workspace they are part of. The response will return a time axis with unix timestamps for each day and daily usage along that axis. The usage will be broken down by the specified breakdown type. For example, breakdown type “voice” will return the usage of each voice along the time axis.
Headers
Your API key. This is required by most endpoints to access our API programatically. You can view your xi-api-key using the 'Profile' tab on the website.
Query Parameters
UTC Unix timestamp for the start of the usage window, in milliseconds. To include the first day of the window, the timestamp should be at 00:00:00 of that day.
UTC Unix timestamp for the end of the usage window, in milliseconds. To include the last day of the window, the timestamp should be at 23:59:59 of that day.
Whether or not to include the statistics of the entire workspace.
How to break down the information. Cannot be "user" if include_workspace_metrics is False.
none
, voice
, user
, api_keys
, all_api_keys
, product_type
, model
Was this page helpful?