This topic is a reference. To learn how to use the dimensions and metrics that are detailed in this reference, start with the Analytics Services overview.

Apigee Analytics exposes APIs for three types of dimensions:

  • Dedicated dimensions: Analytics that are computed in aggregate based on pre-defined dimensions and metrics, with no detailed drill-down available. These are used primarily to populate default dashboards and operational performance graphs in the Apigee management UI.
  • Dynamic dimensions: Analytics for a pre-defined set of dimensions that are computed only when you build custom reports. As is explained below, these require you to specify a function, for example, the average, minimum value, or maximum value, to calculate metrics against a dimension, such as the response time of an API proxy.
  • Custom dimensions: Analytics that you use to build reports for data that is specific to your business, and which is not measured by the Analytics above. Custom Analytics require the definition and population of custom variable as well as requiring a function to be defined. For instructions on building reports for custom dimensions, see Analyze API message content using custom analytics.

Dedicated dimensions

Dedicated dimensions are associated with aggregate, precomputed metrics. For speed and scale, Apigee Analytics automatically calculates these metrics. This makes them very simple to use, but limits their flexibility. For example, functions are not supported against dedicated dimensions because the dimensions have been pre-aggregated; they have 'built-in' functions. For this reason, dedicated dimensions do not appear as available options in the Management UI during report creation. Rather, dedicated dimensions are used to generate operational dashboards in the Management UI. You can access the same dedicated dimensions to build your own dashboards using the Analytics API.

The 'select' query parameter for dedicated dimensions accepts a metric name but does not support a function (since the function is already a specified for the associated pre-computed metric).

Name Description Computed Metrics
/stats/ Total traffic across all API proxies in an environment message_count
/stats/apis Metrics across all API proxies in a specific environment. message_count, error_count, total_response_time, max_response_time, min_response_time, data_exchange_size, end_point_response_time, tps, tpm, tph
/stats/apiproducts Metrics across all API products in an organization message_count, error_count, total_response_time, max_response_time, min_response_time, data_exchange_size, end_point_response_time
/stats/apps Metrics across all apps in an organization message_count, error_count, user_count total_response_time, max_response_time, min_response_time, end_point_response_time, tps, tpm, tph
/stats/devs Metrics across all developers in an organization message_count, error_count, app_count, user_count, tps, tpm, tph
/stats/envs Metrics across all environments in an organization message_count error_count api_count

Computed metrics

Computed metrics are pre-defined (metric + function) calculations that are used to generate reports for dedicated dimensions. Computed metrics enable the system to provide operational analytics in a way that is highly optimized. Computed metrics are used to populate dashboards in the API management UI.

Name Description Method of calculation
message_count Total number of request messages received by all API proxies message_count
error_count Total number of all error messages (request, response) across all API proxies message_count
app_count Total number of all apps provisioned message_count
api_count Total number of API proxies message_count
total_response_time Total traffic across all API proxies in an environment message_count
max_response_time The highest value, in milliseconds, for a complete roundtrip transaction on Apigee Edge, including network latency and processing time by the backend (target) service message_count
min_response_time The smallest value, in milliseconds, for a complete roundtrip transaction on Apigee Edge, including network latency and processing time by the backend (target) service message_count
data_exchange_size The size, in kilobytes, of the inbound request message plus the size, in kilobytes, of the outbound response message message_count
end_point_response_time The time, in milliseconds, between the TargetEndpoint response is sent and the request is received by the TargetEndpoint message_count
tps Number of transactions per second. If tps is specified, the timeUnit query parameter must be greater than one second.  message_count
tpm Number of transactions per minute. If tpm is specified, the timeUnit query parameter must be greater than one minute.  message_count
tph Number of transactions per hour. If tph is specified, the timeUnit query parameter must be greater than one hour.  message_count

Metrics

Name Description Functions
cache_hit A response served from the Cache on Apigee Edge (and which therefore did not result in a request being forwarded to the backend service) Sum, Avg
is_error Any transaction that results in a transport or application error. Sum, Avg
request_processing_latency Duration of processing, measured in milliseconds, of the request pipeline, encompassing ProxyEndpoint request and TargetEndpoint request segments. Avg, Min, Max
request_size The size, measured in kilobytes, of a request message received by a ProxyEndpoint from the client app. Sum, Avg, Min, Max
response_processing_latency Duration of processing, measured in milliseconds, of the response pipeline, encompassing ProxyEndpoint response and TargetEndpoint response segments. Avg, Min, Max
response_size The size, measured in kilobytes, of a response message sent from a ProxyEndpoint to a client app. Sum, Avg, Min, Max
target_response_size The size, measured in kilobytes, of a response message received by a TargetEndpoint from the backend service. Avg, Min, Max
total_response_time Duration of processing, measured in milliseconds, of a request message received by a ProxyEndpoint from a client, until the request message is returned by the ProxyEndpoint, encompassing both request and response Flows plus backend processing time. In other words, total processing time by an API proxy minus the network latency between client app and Apigee Edge. Avg, Min, Max
message_count Total number of request messages processed by the API proxy. Sum, Avg, Min, Max

Functions

Name Description Metrics
sum An operation that adds all values in the database for a given metric, resulting in the total of all values. cache_hit, is_error, request_size, response_size, target_response_size, total_response_time, message_count
avg An operation that adds all values in the database for a given metric, and then divides by the number of entries in the data set, resulting in a single value that characterizes the data set as a whole. cache_hit, is_error, request_processing_latency, request_size, response_processing_latency, response_size, message_count
min The lowest numerical value in a given set of metrics. request_processing_latency, request_size, response_processing_latency, response_size, message_count
max The highest numerical value in a given set of metrics. request_processing_latency, request_size, response_processing_latency, response_size, message_count
count The total number of entries in a given data set. cache_hit, is_error, message_count

Dynamic dimensions

Dynamic dimensions are a set of pre-defined dimensions that are not associated with precomputed metrics. The metrics are computed at the time that you make a request for a report. This provides you with more flexibility to slice-and-dice the measurements that are recorded by Apigee Analytics.

Dynamic dimensions enable you to specify a function and a raw metric in the select parameter. Dynamic dimensions are used to generate custom reports.

For example

select=sum(message_count)

or

select=avg(total_response_time)

Note: Dynamic dimensions should not be confused with custom dimensions. Custom dimensions are derived business-specific message content that is unique to a particular API. Custom dimensions are defined using the StatisticsCollector policy policy (see Capture analytics from API traffic, or see Analyze API message content using custom analytics for a full example).

Each dynamic dimension supports a set of metrics and functions. (When using the Management UI, only the functions available for a given metric can be selected. Radio buttons for unavailable functions are disabled.)

Dynamic dimensions enable you to 'slice and dice' the metric/function combinations..

For example:

https://api.enterprise.apigee.com/v1/o/{org_name}/environments/{env_name}/stats/access_token?select={function}({metric})&timeRange={startTime~endTime}&timeUnit
https://api.enterprise.apigee.com/v1/o/{org_name}/environments/{env_name}/stats/client_id?select={function}({metric})&timeRange={startTime~endTime}&timeUnit
https://api.enterprise.apigee.com/v1/o/{org_name}/environments/{env_name}/stats/client_ip?select={function}({metric})&timeRange={startTime~endTime}&timeUnit

Dynamic dimensions

Name Description Metrics Functions
/stats/access_token App end user's OAuth access token. (OAuth policies must be enforced for this dimension to be populated.) metrics functions
/stats/api_product An API product in an organization. metrics functions
/stats/apiproxy An API proxy metrics functions
/stats/apiproxy_revision A specific revision of an API proxy metrics functions
/stats/client_host The network name of the computer hosting the client app metrics functions
/stats/client_id The API key, also known as consumer key, of the client app. metrics functions
/stats/client_ip The IP address of the client app. metrics functions
/stats/developer The developer associated with the client app, identified by internal developer ID (generated by Apigee Edge when a developer registers in an organization). metrics functions
/stats/developer_app The name of the developer app submitting the request. (Apigee Edge groups apps by developer.) metrics functions
/stats/developer_email The email address of the developer. metrics functions
/stats/environment The environment in an organization in which an API proxy is deployed. metrics functions
/stats/flow_resource The URI (defined as an API resource by a conditional Flow) metrics functions
/stats/gateway_flow_id The name of the API Proxy Flow metrics functions
/stats/organization The organization where metrics are gathered. metrics functions
/stats/proxy The name of the ProxyEndpoint metrics functions
/stats/proxy_basepath The URI path fragment defined as the base path for an API proxy in the ProxyEndpoint configuration. metrics functions
/stats/proxy_client_ip The IP address of the ProxyEndpoint. metrics functions
/stats/proxy_pathsuffix The URI fragment that follows the proxy base path. metrics functions
/stats/request_path The full URI path of the request message. metrics functions
/stats/request_uri The full URI of the request message metrics functions
/stats/request_verb The HTTP verb associated with the request message metrics functions
/stats/target The name of the TargetEndpoint metrics functions
/stats/target_host The name of the network host where the TargetEndpoint is deployed. metrics functions
/stats/target_basepath ? metrics functions
/stats/target_ip The IP address of the TargetEndpoint metrics functions
/stats/target_url The complete URL of the target service (that is, the backend service) metrics functions
/stats/virtual_host The name of the VirtualHost (that is, the named network address configuration) invoked by the client app metrics functions

Report Filters

A filter is expressed as a query parameter in an API request to build a report. Filters can be applied to any API request.

Filter on API proxies with the name books or music:

filter=(apiproxy IN 'books','music')

Filter on API proxies with names that start with "m":

filter=(apiproxy LIKE 'm%')

Filter on response codes that do not start with "m":

filter=(apiproxy NOT LIKE 'm%')

Filter on response codes between 400 and 599:

filter=(responsecode IN '4xx','5xx')

Filter on response code 500:

filter=(responsecode EQ 500)

Filter on metrics for non-error messages:

filter=(is_error EQ 0)
Token Description
IN Include in list
NOTIN Exclude from list
EQ Equals, ==
NE Not equal to, !=
GT Greater than, >
LT Less than, <
GE Greater than or equal to, >=
LE Less than or equal to, <=
LIKE Returns true if the string pattern matches the supplied pattern.
NOT LIKE Returns false if the string pattern matches the supplied pattern.
SIMILAR TO Returns true or false depending on whether its pattern matches the given string. It is similar to LIKE, except that it interprets the pattern using the SQL standard's definition of a regular expression.
NOT SIMILAR TO Returns false or true depending on whether its pattern matches the given string. It is similar to NOT LIKE, except that it interprets the pattern using the SQL standard's definition of a regular expression.

 

Help or comments?

  • Something's not working: See Apigee Support
  • Something's wrong with the docs: Click Send Feedback in the lower right.
    (Incorrect? Unclear? Broken link? Typo?)