Using hybrid metrics APIs

Apigee hybrid records a wide variety of operational and business data that flows across APIs. The metrics derived from this data are useful for operational monitoring and business monitoring. Using hybrid analytics, you can, for example, determine which APIs are performing well or poorly, which developers are delivering the highest value traffic, and which apps are causing the most issues for your backend services.

To help access this metrics data easily, hybrid exposes a RESTful API. You can use the metrics API when you need to automate certain analytics functions, such as retrieving metrics periodically using an automation client or script. You can also use the API to build your own visualizations in the form of custom widgets that you can embed in portals or custom apps.

Analytics API

Use the hybrid API to download analytics data. For example, you can use the API to build your own visualization tools that you can embed in portals or custom apps.

Here's an example API call to retrieve analytics data for API proxies:

curl"select=sum(message_count)&timeRange=6/24/2019%2000:00~6/24/2019%2023:59&timeUnit=hour" \
-H "Authorization:Bearer $TOKEN"

This call returns:

  • The sum of requests (message count) per API proxy
  • For a 24-hour period
  • Grouped by hour

For more on using the Apigee APIs, see Get started using the Apigee APIs.

For detailed information on using the analytics APIs, see Use the metrics APIs.

Differences between the hybrid and Edge metrics APIs

API comparison lists the general differences between hybrid APIs and Edge APIs. The following table lists specific differences for the metrics APIs:

Feature Hybrid APIs Edge APIs
API endpoint
Data export No APIs supported Export data from Analytics
Daily analytics emails No APIs supported Subscribe to daily analytics emails
Async Query List API The userId property is omitted from the response. See Method: organizations.environments.queries.list. Get a list of asynchronous analytics queries
Custom report APIs The createdBy and lastModifiedBy properties have been removed from the response. See Reports API. Reports