Table of Contents
- API Usage Guide
- API Command Reference
- add_booking
- add_client
- add_invoice
- add_resource
- add_venue_group
- approve_request
- authenticate_user
- del_booking
- del_bookings
- del_client
- del_invoice
- del_resource
- del_venue_group
- email_client
- gen_invoice
- get_activity
- get_availability
- get_booking
- get_booking_type
- get_booking_types
- get_bookings
- get_client
- get_consumable_levels
- get_invoice
- get_invoices
- get_messages
- get_reminders
- get_resource
- get_resource_availability
- get_setting
- get_template
- get_user
- get_users_logged_in
- get_venue
- get_venue_groups
- get_venues
- get_venues_in_group
- get_venues_in_use
- get_watches
- mod_booking
- mod_client
- mod_invoice
- mod_resource
- mod_venue
- mod_venue_group
- notify_user
- reject_request
- restore_booking
- set_setting
- set_template
- util_api_usage
- util_from_epoch
- util_to_epoch
- Appendix A - Activity Codes
- Appendix B - Setting Names
- Appendix C - Error Handling
- Code Samples
- Troubleshooting
- Release Notes
← Hide Table of Contents
MIDAS API: util_api_usage
Available in API 2.48+
Returns details of recent MIDAS API usage
| Required Parameters |
| This API command has no required parameters |
| Optional Parameters | Possible Values | Description |
| period | integer | comma separated list of integers | The period of time (in hours) to calculate API usage over. A comma separated list of values may be passed. For example, passing "1,24,168" will return API usage over the past hour, past day (24 hours), and past week (168 hours) |
| end | Valid date and time (Format: YYYYMMDDHHMM) | By default, API usage statistics are included up to the current time. To view API usage for a period up until a specific date/time, pass the "end" parameter |
| Example Response ↓ Show |
[
{
"previous_hours":"1",
"calls":"12",
"data_nice":"120.23 KB",
"data_raw":"120231"
},
{
"previous_hours":"24",
"calls":"288",
"data_nice":"2.89 MB",
"data_raw":"2891230"
},
{
"previous_hours":"168",
"calls":"2016",
"data_nice":"20.20 MB",
"data_raw":"20202350"
}
] |
| Variables Returned | Description |
| previous_hours | The period (in hours) up until the current time (or up until the time supplied in the "end" parameter) which the values of the "calls" and "data" variables relate to |
| calls | The number of API calls made during the "previous_hours" period |
| data_nice | The amount of data returned by the API during the "previous_hours" period, formatted in KB, MB, or GB and rounded to two decimal places |
| data_raw | The amount of data returned by the API during the "previous_hours" period in bytes |
MIDAS API: util_api_usage