Counting total API calls for your analytics service
Count the API calls for the analytics subsystem and see the total categorized by response status.
Note: If your API Connect bases costs on usage, you can use the following methods to track this information so that you can
accurately report it. If your organization did not deploy the analytics subsystem, then this feature
is not available. If you deployed analytics but offload your data and disabled local storage, then you must capture
usage information from the third-party system where you offload data.
You can see the total API calls over time for each analytics service in the consumption dashboard or report in the Cloud Manager UI.
Alternatively, the Analytics CLI can be used to get your API count:
- Login as the cloud admin
user:
apic login --server <platform api endpoint> --username admin --realm
admin/default-idp-1
- Use the following CLI command to retrieve a count of all analytics events recorded by the
analytics
service:
where <analytics service name> is the name of analytics service as configured in the Cloud Manager UI.apic -m analytics events:cloudCount --server <platform api endpoint> --analytics-service <analytics service name> --format json
- If required, additional filters can be applied to the results. For example,
--timeframe last12hours
. See thehelp
output from:apic -m analytics events:cloudCount -h
for more details.