---
schema_version: "1"
id: 26f79991bc7c5a717d8c6dbc2d31dbbb2913509da3b0c8cc9b2566a340244741
title: Flex Gateway Agent Policies
collection: mulesoft
version: current
locale: en-us
portal_url: https://docs.salesforce.com/mulesoft/current/en-us/gateway/1.9/flex-agent-policies.md
canonical_url: https://docs.mulesoft.com/gateway/1.9/flex-agent-policies
source_site: docs.mulesoft.com
content_type: documentation
content_hash: 8ae17dc7b8a5b0b7c1b8a4d7fc1514ad68fed908144ce04dfa3744a77775ed1b
description: MuleSoft Documentation Site
release: "1.9"
latest: false
---
---
product: Omni Gateway
version: 1.9
---

# Flex Gateway Agent Policies

> For the full documentation index, see: https://docs.mulesoft.com/llms.txt

Policies enforce rules when Flex Gateway processes requests, enabling you to secure and govern your
server instances. Flex Gateway includes A2A and MCP specific policies that provide enhanced security
and control over agent interactions.

To apply a policy, see
[Applying Policies for Managed Flex Gateways and Connected Mode](https://docs.mulesoft.com/gateway/1.9/flex-gateway-secure-conn).

Flex Gateway MCP and A2A server instances also support other Flex Gateway policies to protect server
instances through rate limiting, authentication, authorization, threat protection, monitoring, and
logging. For more information about MuleSoft-provided policies, see the
[Inbound Policies Directory](https://docs.mulesoft.com/gateway/1.9/policies-included-directory) and
[Outbound Policies Directory](https://docs.mulesoft.com/gateway/1.9/policies-outbound-directory).

To extend existing functionality or define new functionality, create custom policies based on your
specific business requirements. For information about creating custom policies, see
[Omni Gateway Policy Development Kit (PDK) Overview](https://docs.mulesoft.com/pdk/latest/policies-pdk-overview).

> [!NOTE] All agent policies are inbound policies and are not supported as automated policies.

## SSE Policies

Both A2A and MCP support the following policies for Server-Sent Events (SSE) streaming:

<table><colgroup><col> <col></colgroup><thead><tr><th>Policy</th><th>Summary</th></tr></thead><tbody><tr><td><p><a href="https://docs.mulesoft.com/gateway/1.9/policies-included-sse-logging">SSE Logging</a></p></td><td><p>Logs every SSE event while streaming</p></td></tr></tbody></table>

## A2A Policies

<table><colgroup><col> <col></colgroup><thead><tr><th>Policy</th><th>Summary</th></tr></thead><tbody><tr><td><p><a href="https://docs.mulesoft.com/gateway/1.9/policies-included-a2a-agent-card">A2A Agent Card</a></p></td><td><p>Rewrites the Agent Card URL to match the server instance public URL</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/gateway/1.9/policies-included-a2a-pii-detector">A2A PII Detector</a></p></td><td><p>Detects personally identifiable information (PII) in requests sent to the agent</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/gateway/1.9/policies-included-a2a-prompt-decorator">A2A Prompt Decorator</a></p></td><td><p>Decorates prompts with context information</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/gateway/1.9/policies-included-a2a-schema-validation">A2A Schema Validation</a></p></td><td><p>Validates agent requests to ensure they conform to the A2A specification</p></td></tr></tbody></table>

## MCP Policies

<table><colgroup><col> <col></colgroup><thead><tr><th>Policy</th><th>Summary</th></tr></thead><tbody><tr><td><p><a href="https://docs.mulesoft.com/gateway/1.9/policies-included-mcp-attribute-access-control">MCP Attribute-Based Access Control</a></p></td><td><p>Controls access to tools, resources, and prompts based on user information such as Tiers, IP, Headers, or Claims</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/gateway/1.9/policies-included-mcp-schema-validation">MCP Schema Validation</a></p></td><td><p>Validates MCP requests to ensure they conform to the MCP specification</p></td></tr><tr><td><p><a href="https://docs.mulesoft.com/gateway/1.9/policies-included-mcp-support">MCP Support</a></p></td><td><p>Adds MCP support to a Flex Gateway MCP server instance. This policy is required for your MCP server instance to function properly.</p></td></tr></tbody></table>

## See Also

- [Ordering Policies](https://docs.mulesoft.com/gateway/1.9/policies-reorder)

- [DataWeave Support in Flex Gateway Policies](https://docs.mulesoft.com/gateway/1.9/policies-flex-dataweave-support)
