/v1/projects/{projectId}/usage
GET
/v1/projects/{projectId}/usage
const url = 'https://service.v2.nairon.xyz/v1/projects/example/usage?granularity=hour';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'https://service.v2.nairon.xyz/v1/projects/example/usage?granularity=hour' \ --header 'Authorization: Bearer <token>'Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”projectId
required
string format: cuid
Query Parameters
Section titled “Query Parameters”from
string format: date-time
to
string format: date-time
granularity
string
Responses
Section titled “Responses”Default Response
Media typeapplication/json
object
Example
{ "granularity": "hour", "points": [ { "service": "tts", "mode": "realtime", "metric": "seconds" } ]}