AgentCore provided gateway metrics and logs - Amazon Bedrock AgentCore

Amazon Bedrock AgentCore is in preview release and is subject to change.

AgentCore provided gateway metrics and logs

The following sections describe the gateway metrics and logs output by AgentCore to Amazon CloudWatch. These metrics aren't available on the CloudWatch generative AI observability page. Gateway metrics are batched at one minute intervals. To learn more about viewing gateway metrics, see View observability data for your Amazon Bedrock AgentCore agents.

Note

To enable service-provided logs for AgentCore gateways, you need to configure the necessary CloudWatch resources. See Enable observability for AgentCore memory, gateway, and built-in tool resources to learn more.

Provided metrics

Invocations

The total number of requests made to each Data Plane API. Each API call counts as one invocation regardless of the response status.

Throttles [429]

The number of requests throttled (status code 429) by the service.

SystemErrors [5xx]

The number of requests which failed with 5xx status code.

UserErrors [4xx]

The number of requests which failed with 4xx status codes other than 429.

Latency

The time elapsed between when the service receives the request and when it begins sending the first response token.

Duration

The total time elapsed between receiving the request and sending the final response token. Represents complete end-to-end processing time of the request.

TargetExecutionTime

The total time take to execute the target over Lambda, OpenAPI, etc. This metric helps you to determine the contribution of the target to the total Latency.

TargetType

The total number of requests served by each type of target (MCP, Lambda, OpenAPI).

Provided log data

AgentCore provides logs that help you monitor and troubleshoot key AgentCore gateway resource processes. To enable this log data, you need to create a log destination.

AgentCore can output logs to CloudWatch Logs, Amazon S3, or Firehose stream. If you use a CloudWatch Logs destination, these logs are stored under the default log group /aws/vendedlogs/bedrock-agentcore/gateway/APPLICATION_LOGS/{gateway_id} or under a custom log group starting with /aws/vendedlogs/. See Enable observability for AgentCore memory, gateway, and built-in tool resources to learn more.

AgentCore logs the following information for gateway resources:

  • Start and completion of gateway requests processing

  • Error messages for Target configurations

  • MCP Requests with missing or incorrect authorization headers

  • MCP Requests with incorrect request parameters (tools, method)