diff --git a/gateway/1.11/modules/ROOT/nav.adoc b/gateway/1.11/modules/ROOT/nav.adoc index c48ba3d6b..606cb4d07 100644 --- a/gateway/1.11/modules/ROOT/nav.adoc +++ b/gateway/1.11/modules/ROOT/nav.adoc @@ -86,6 +86,7 @@ *** xref:policies-included-a2a-pii-detector.adoc[A2A PII Detector] *** xref:policies-included-a2a-prompt-decorator.adoc[A2A Prompt Decorator] *** xref:policies-included-a2a-schema-validation.adoc[A2A Schema Validation] +*** xref:policies-included-agent-connection-telemetry.adoc[Agent Connection Telemetry Policy] *** xref:policies-included-basic-auth-ldap.adoc[Basic Authentication: LDAP] *** xref:policies-included-basic-auth-simple.adoc[Basic Authentication: Simple] *** xref:policies-included-client-id-enforcement.adoc[Client ID Enforcement] diff --git a/gateway/1.11/modules/ROOT/pages/policies-included-agent-connection-telemetry.adoc b/gateway/1.11/modules/ROOT/pages/policies-included-agent-connection-telemetry.adoc new file mode 100644 index 000000000..e913641af --- /dev/null +++ b/gateway/1.11/modules/ROOT/pages/policies-included-agent-connection-telemetry.adoc @@ -0,0 +1,42 @@ += Agent Connection Telemetry Policy +ifndef::env-site,env-github[] +include::_attributes.adoc[] +endif::[] +:imagesdir: ../assets/images +:keywords: api gateway, flex gateway, gateway, policy, agent, telemetry, agent connection, A2A, MCP + +[width="100%", cols="5,15"] +|=== +>s| Policy Name | Agent Connection Telemetry +>s|Summary | Tracks the number of requests made to agent or MCP server instances +>s|Category | A2A and MCP +>s|First Flex Gateway version available | 1.11.0 +^s| Returned Status Codes | No return codes exist for this policy. +|=== + +== Summary + +The Agent Connection Telemetry policy tracks the number of requests and what source makes the request to agent or MCP server instance. + +To track the source of the request, the policy uses a DataWeave expression to extract an identification value from a request header. By default, the policy extracts the `X-AGENT-ID` header. The `X-AGENT-ID` header contains the Mulesoft instance ID. + +To track the requests, the policy uses the `mulesoft_agent_connection_count(source, destination)` metric. Where `source` is the identification value extracted from the request header and `destination` is the agent or MCP server instance ID. Use Anypoint Monitoring to view the metric. + +If the policy can't extract the identification header, the policy doesn't block or track the request. + +NOTE: The Agent Connection Telemetry policy is applied by default to all agent and MCP server instances created using Agent Fabric. + +== Configure Policy Parameters + +include::partial$policy-title-headers.adoc[tag=configFileTitleOnly] + +The Agent Connection Telemetry policy isn't supported in Local Mode. + +include::partial$policy-title-headers.adoc[tag=ui] + +[%header%autowidth.spread,cols="a,a"] +|=== +| Element | Description +| Source Agent ID | DataWeave expression to extract the source identification value from the request header. By default, the `#[attributes.headers['X-AGENT-ID']]` expression extracts the Mulesoft instance ID. +|=== + diff --git a/gateway/1.11/modules/ROOT/pages/policies-included-directory.adoc b/gateway/1.11/modules/ROOT/pages/policies-included-directory.adoc index b805b2f41..4b7befcee 100644 --- a/gateway/1.11/modules/ROOT/pages/policies-included-directory.adoc +++ b/gateway/1.11/modules/ROOT/pages/policies-included-directory.adoc @@ -13,6 +13,7 @@ endif::[] | xref:policies-included-a2a-pii-detector.adoc[A2A PII Detector] | A2A | Detects personally identifiable information (PII) in requests sent to the agent | xref:policies-included-a2a-prompt-decorator.adoc[A2A Prompt Decorator] | A2A | Decorates prompts with context information | xref:policies-included-a2a-schema-validation.adoc[A2A Schema Validation] | A2A | Validates Agent requests to ensure they conform to the A2A specification +| xref:policies-included-agent-connection-telemetry.adoc[Agent Connection Telemetry] | A2A and MCP | Tracks the number of requests made to agent or MCP server instances | xref:policies-included-basic-auth-ldap.adoc[Basic Authentication: LDAP] | Security | Allows access based on the basic authorization mechanism, with user-password defined on LDAP | xref:policies-included-basic-auth-simple.adoc[Basic Authentication: Simple] | Security | Allows access based on the basic authorization mechanism, with a single user-password | xref:policies-included-client-id-enforcement.adoc[Client ID Enforcement] | Compliance | Allows access only to authorized client applications diff --git a/policies/modules/ROOT/pages/policies-availability-by-gateway.adoc b/policies/modules/ROOT/pages/policies-availability-by-gateway.adoc index b229b3c37..d99aef21c 100644 --- a/policies/modules/ROOT/pages/policies-availability-by-gateway.adoc +++ b/policies/modules/ROOT/pages/policies-availability-by-gateway.adoc @@ -19,6 +19,8 @@ endif::[] | A2A Schema Validation ^| xref:gateway::policies-included-a2a-schema-validation.adoc[✓] ^| | Validates Agent requests to ensure they conform to the A2A specification +| Agent Connection Telemetry ^| xref:gateway::policies-included-agent-connection-telemetry.adoc[✓] ^| | Tracks the number of requests made to agent or MCP server instances + | AWS Lambda ^| xref:gateway::policies-outbound-aws-lambda.adoc[✓] ^| | Allows access based on the basic authorization mechanism, with user-password defined on LDAP | AWS Request Signature ^| xref:gateway::policies-outbound-aws-signature.adoc[✓] ^| | Signs outgoing requests with AWS Signature Version 4 (SigV4) or Signature Version 4A (SigV4A)