*This page
applies to **Apigee** and **Apigee hybrid**.*


API insights offers a unified view of your API traffic and performance across all connected gateways (or plugin instances) in API hub. You can use this view to gain a holistic understanding of your API ecosystem health and quickly analyze areas for optimization. Expanding on [API analytics in Apigee](https://docs.cloud.google.com/apigee/docs/api-platform/analytics/analytics-services-overview.md.txt), API insights enables proactive identification and mitigation of any issues across your API ecosystem.

> [!IMPORTANT]
> **Key Points:**
>
> - This feature includes GeoLite Data created by MaxMind, available from [https://www.maxmind.com](https://www.maxmind.com/).
> - The terms *gateways* and *plugin instances* are used interchangeably in this document.

## Enable API insights


API insights collects and analyzes API data from your attached gateways in API hub.
To start viewing your API data in API insights, depending on your gateway type, you must first either [attach a runtime project](https://docs.cloud.google.com/apigee/docs/apihub/auto-register-apigee-proxies#attach-a-runtime-project) or [create a plugin instance](https://docs.cloud.google.com/apigee/docs/apihub/create-plugin-instances.md.txt) in API hub.


If you have an existing runtime project attached, but are unable to see any API data in API insights, then you may need to edit the project settings to import the necessary API assets into API hub. For more information, see [Edit project association settings](https://docs.cloud.google.com/apigee/docs/apihub/auto-register-apigee-proxies#edit-project-association-settings).

> [!NOTE]
> **Note:** When you provision API hub as part of Apigee provisioning, it automatically identifies and attaches any associated Apigee runtime projects. API insights for such attached projects are collected and analyzed automatically.


For more information about configuring API insights in API hub, see [Configure API insights](https://docs.cloud.google.com/apigee/docs/apihub/configure-api-insights.md.txt).

## View API insights


To view API insights, go to the **API hub** page in the Google Cloud console and click **API insights** from the left navigation menu. The API insights page appears, displaying the following dashboards:

- **Gateway performance:** provides insights into the traffic and performance of your gateways.
- **API performance:** provides insights into the traffic and performance of your APIs.
- **API error analysis:** provides insights about the errors encountered while using your APIs.
- **Latency analysis:** provides insights into the latency of your APIs across multiple percentiles.
- **Target performance:** provides insights into the traffic and performance of your targets.
- **AI performance:** provides insights into the token usage and performance of the large language models (LLMs) called through your gateways.
- **Tool performance:** provides insights into the traffic and performance of your Model Context Protocol (MCP) tools.


For detailed information about each dashboard, see [API insights dashboards](https://docs.cloud.google.com/apigee/docs/apihub/api-insights-dashboard.md.txt).

## IAM roles and permissions


To view API insights in API hub, you need the following IAM roles and permissions:

| IAM role | Permissions |
|---|---|
| **API hub API Insights Viewer** (`roles/apihub.apiInsightsViewer`) | - apihub.locations.getApiInsights - apihub.apis.list - apihub.apis.get - apihub.plugininstances.list - apihub.plugininstances.get - apihub.deployments.list - apihub.deployments.get - apihub.apiHubInstances.get - apihub.apiHubInstances.list - monitoring.dashboards.get - monitoring.dashboards.list - monitoring.monitoredResourceDescriptors.list - monitoring.monitoredResourceDescriptors.get - monitoring.metricDescriptors.list - monitoring.metricDescriptors.get - apigee.projectorganizations.get |

> [!NOTE]
> **Note:** IAM roles for API insights provide broad access, applying across all configured gateways rather than offering gateway-specific permissions. This means that once a user is granted the required IAM permissions, they can view data from all your gateways within the API insights page in API hub.


For information on granting roles to principals, see [Granting, changing, and revoking access](https://docs.cloud.google.com/iam/docs/granting-changing-revoking-access.md.txt).

## Limitations

- API insights doesn't support data ingestion for [custom plugins](https://docs.cloud.google.com/apigee/docs/apihub/plugins.md.txt#plugin-types) and [API observations](https://docs.cloud.google.com/apigee/docs/apihub/api-observation-overview.md.txt).
- API insights is supported only for Apigee, Apigee hybrid, Apigee Edge Public Cloud, and Apigee Edge Private Cloud (OPDK).
- API insights data is not accessible through API calls.
- API insights doesn't support exporting metric data to other Google Cloud services such as BigQuery, Cloud Storage, or Data Studio.

## What's next

- Learn about [configuring API insights](https://docs.cloud.google.com/apigee/docs/apihub/configure-api-insights.md.txt).
- Learn about [API insights dashboards](https://docs.cloud.google.com/apigee/docs/apihub/api-insights-dashboard.md.txt).
- Learn about [attaching a runtime project](https://docs.cloud.google.com/apigee/docs/apihub/auto-register-apigee-proxies#attach-a-runtime-project) or [creating a plugin instance](https://docs.cloud.google.com/apigee/docs/apihub/create-plugin-instances.md.txt) in API hub.