Returns prediction usage on a monthly basis for the current calendar month and future months. Each apiusage
object in the response corresponds to a calendar month in your plan. For more information about plans, see Rate Limits.
Response Body
Name | Type | Description | Available Version |
---|---|---|---|
| object | Array of | 1.0 |
| string | Object returned; in this case, | 1.0 |
apiUsage Response Body
Name | Type | Description | Available Version |
---|---|---|---|
| date | Date and time that the plan calendar month ends. Always 12 am on the first day of the following month. | 1.0 |
| long | Unique ID for the API usage plan month. | 1.0 |
| string | Unique ID of the API plan. | 1.0 |
| string | Object returned; in this case, | 1.0 |
| long | Unique ID for the user making the API call. | 1.0 |
| long | Total number of predictions for the calendar month. | 1.0 |
| long | Number of predictions left for the calendar month. | 1.0 |
| long | Number of predictions used in the calendar month. A prediction is any call to these resources:
| 1.0 |
| date | Date and time that the plan calendar month begins. Always the first of the month. | 1.0 |
planData Response Body
Name | Type | Description | Available Version |
---|---|---|---|
| string | Number of plans of the specified type. | 1.0 |
| string | Type of plan based on the
| 1.0 |
| string | Service that provisioned the plan. Valid values:
| 1.0 |
Each apiusage
object in the response contains plan information for a single calendar month for a single license. If you have a six-month paid plan and you make this call on the first month, the response contains six apiusage
objects; one for each calendar month in the plan.
- If you're using the free tier, the response contains plan information only for the current month. You see plan information only after you make your first prediction. If you call the
/apiusage
resource before you make your first prediction call, the API returns an empty array. - If you're using the paid tier, the response contains plan information for each month in your plan starting with the current month.
The planData
array contains an object for each plan type associated with the calendar month and the license. This code snippet shows the planData
if the user has two Heroku GOLD plans.
"planData": [
{
"plan": "GOLD",
"amount": 2,
"source": "HEROKU"
}
]