Usage API
This API offers an insight into credit usage an historical credit spend pr. endpoint.
Get Current Usage
GET https://api.theorg.com/v1/usage
Parameter | Value |
---|---|
Url | https://api.theorg.com/v1/usage |
Method | GET |
Cost | Free |
Example
Get information about the usage within the current billing period.
Current billing period usage
curl --location 'https://api.theorg.com/v1/usage' \
--header 'X-Api-Key: **********************a02e'
Show response
{
"data": {
"resetDate": "2025-04-19",
"unlimited": false,
"availableMonthlyCredits": 80,
"extraCredits": 0
}
}
Get Historical Usage
GET /usage/history
Parameter | Value |
---|---|
Url | https://api.theorg.com/v1/usage/history |
Method | GET |
Parameters | Parameters |
Cost | Free |
Get historical usage data for a specific API endpoint.
Parameters
Parameter | Type | Description | Required |
---|---|---|---|
api | query | The endpoint to check (prospecting_api , manager_api , org_chart_api ) | true |
from | query | Start date in YYYY-MM-DD format | true |
to | query | End date in YYYY-MM-DD format | true |
interval | query | Data interval (daily , monthly ), default is daily | false |
Example
Historical daily usage
curl --location 'https://api.theorg.com/v1/usage/history?api=prospecting_api&from=2025-04-01&to=2025-04-04' \
--header 'X-Api-Key: **********************a02e'
Show response
{
"data": {
"api": "prospecting_api",
"stats": [
{
"date": "2025-04-04",
"count": 10
},
{
"date": "2025-04-03",
"count": 3
},
{
"date": "2025-04-02",
"count": 23
},
{
"date": "2025-04-01",
"count": 2
}
]
}
}
Last updated on