GET Get Overall Application metrics
GET /organizations/{organizationId}/metrics/overall
Operation ID: getOverallMetrics. Tags: Overall Application. Security: AmOAuth2 (sfcc.metrics).
Retrieve time series data for all overall application performance metrics including total platform requests, storefront requests, sessions, response time, emails sent, and system workload.
Parameters
organizationId(path, OrganizationId, required) An identifier for the Salesforce Commerce Cloud organization the request is being made by. It consists of a prefix 'f_ecom_' followed by a 4-character realm identifier and a 3-character instance type identifier.Example
f_ecom_zzxy_prdfrom(query, integer (int64))Start time for the query window, expressed as a Unix epoch timestamp in seconds.
If not specified, defaults to one hour before
to.Constraints:
frommust not resolve to a time more than 30 days before the request (matches the configured retention of the underlying metrics store).tominusfrommust not exceed 1 day.
Requests violating either constraint return
400 Bad Request.
Minimum: 1. Example:1672531200.to(query, integer (int64))End time for the query window, expressed as a Unix epoch timestamp in seconds.
If not specified, defaults to the current time (now).
Constraints:
tominusfrommust not exceed 1 day.frommust not resolve to a time more than 30 days before the request.
Requests violating either constraint return
400 Bad Request.
Minimum: 1. Example:1672534800.
Responses
- 200
Successfully retrieved overall application metrics for the requested time window
Media type:
application/json. Schema:MetricsDataResponse.Example: OverallMetricsResponseExample Overall Application metrics response
{ "data": [ { "metricId": "totalCalls", "title": "Total Platform Requests", "description": "Total number of platform requests per minute.", "unit": "requests/min", "dataSeries": [ { "id": "realm1.totalCalls", "name": "realm1 Total Calls", "data": [ { "timestamp": 1640995200, "value": 1250.5 }, { "timestamp": 1640995260, "value": 1275.2 }, { "timestamp": 1640995320, "value": 1201.8 } ] } ] }, { "metricId": "sessions", "title": "Sessions", "description": "Number of active sessions across all sites per minute.", "unit": "sessions/min", "dataSeries": [ { "id": "realm1.sessions", "name": "realm1 Sessions", "data": [ { "timestamp": 1640995200, "value": 45.2 }, { "timestamp": 1640995260, "value": 47.1 }, { "timestamp": 1640995320, "value": 44.8 } ] } ] }, { "metricId": "responseTime", "title": "Response Time", "description": "Average response time across all requests.", "unit": "ms", "dataSeries": [ { "id": "realm1.responseTime", "name": "realm1 Response Time", "data": [ { "timestamp": 1640995200, "value": 156.3 }, { "timestamp": 1640995260, "value": 148.7 }, { "timestamp": 1640995320, "value": 162.1 } ] } ] } ] } - 400
Bad request — invalid time parameters
Media type:
application/problem+json. Schema:InvalidTimeParameterErrorResponse | InvalidTimeRangeErrorResponse.One of:
InvalidTimeParameterErrorResponse,InvalidTimeRangeErrorResponse.Example: InvalidTimeParameterExample
{ "type": "https://api.commercecloud.salesforce.com/documentation/error/v1/errors/bad-request", "title": "Bad Request", "detail": "Invalid time parameter 'from'. Must be a Unix epoch timestamp in seconds (e.g., 1672531200).", "parameter": "from" }Example: InvalidTimeRangeExample
{ "type": "https://api.commercecloud.salesforce.com/documentation/error/v1/errors/bad-request", "title": "Bad Request", "detail": "Invalid time range: 'from' (1672534800) must be earlier than 'to' (1672531200).", "fromValue": 1672534800, "toValue": 1672531200 }Example: InvalidTimeParameterErrorResponseExample
{ "type": "https://api.commercecloud.salesforce.com/documentation/error/v1/errors/invalid-time-parameter", "detail": "Invalid time parameter 'from'. Must be a Unix epoch timestamp in seconds (e.g., 1672531200).", "title": "Invalid Time Parameter" }Example: InvalidTimeRangeErrorResponseExample
{ "type": "https://api.commercecloud.salesforce.com/documentation/error/v1/errors/invalid-time-range", "detail": "Invalid time range: 'from' (1672534800) must be earlier than 'to' (1672531200).", "title": "Invalid Time Range" } - 401
Your access token is invalid or expired and can’t be used to identify a user.
Media type:
application/problem+json. Schema:ErrorResponse.Example: UnauthorizedExample
{ "type": "https://api.commercecloud.salesforce.com/documentation/error/v1/errors/unauthorized", "title": "Unauthorized", "detail": "Unauthorized request" } - 403
Forbidden. Your access token is valid, but you don’t have the required permissions to access the resource.
Media type:
application/problem+json. Schema:ErrorResponse.Example: ForbiddenExample
{ "type": "https://api.commercecloud.salesforce.com/documentation/error/v1/errors/forbidden", "title": "Forbidden", "detail": "Access to requested resource forbidden" } - 404
Metrics category not available for the organization
Media type:
application/problem+json. Schema:CategoryNotFoundErrorResponse.Example: CategoryNotFoundExample
{ "type": "https://api.commercecloud.salesforce.com/documentation/error/v1/errors/not-found", "title": "Not Found", "detail": "Metrics category 'unknown-category' not found or not available for organization 'f_ecom_zzxy_prd'.", "category": "unknown-category", "organizationId": "f_ecom_zzxy_prd" }Example: CategoryNotFoundErrorResponseExample
{ "type": "https://api.commercecloud.salesforce.com/documentation/error/v1/errors/category-not-found", "detail": "Metrics category 'unknown-category' not found or not available for organization 'f_ecom_zzxy_prd'.", "title": "Category Not Found" } - 503
Metrics data temporarily unavailable
Media type:
application/problem+json. Schema:MetricsNotAvailableErrorResponse.Example: MetricsUnavailableExample
{ "type": "https://api.commercecloud.salesforce.com/documentation/error/v1/errors/service-unavailable", "title": "Service Unavailable", "detail": "Metrics data is temporarily unavailable for organization 'f_ecom_zzxy_prd'. Please try again later.", "organizationId": "f_ecom_zzxy_prd" }Example: MetricsNotAvailableErrorResponseExample
{ "type": "https://api.commercecloud.salesforce.com/documentation/error/v1/errors/metrics-not-available", "detail": "Metrics data is temporarily unavailable for organization 'f_ecom_zzxy_prd'. Please try again later.", "title": "Metrics Not Available" }