One of the most powerful aspects of Kong AI Gateway is its ability to bootstrap an MCP interface from existing RESTful APIs. Here's how the complete workflow operates:
1. Start with Your Existing API
Let's say you have a flight service API with several operations:
- GET flight data (all flights, by flight number, flight details)
- POST book new flights
- DELETE existing bookings
This API is defined in OpenAPI specification and works with standard REST clients.
2. Deploy the MCP Proxy Plugin
Kong AI Gateway's MCP Proxy Plugin transforms your RESTful API into an MCP-compatible interface. Incoming requests from AI agents, IDEs, or MCP inspectors use the MCP protocol, while Kong translates these to standard RESTful upstream requests.
3. Secure with OAuth2/OIDC
Integration with authorization servers with the MCP OAuth2 plugin provides robust authentication, identifying the developer, application, or agent attempting to access your MCP server. The MCP OAuth2 plugin acts as an extension to OpenID Connect (OIDC), allowing for seamless integration with compliant identity providers. In our implementation, we use Okta as the identity provider, generating OAuth2 tokens that authenticate each connection.
Here's where the magic happens. In your Kong configuration, you define a default ACL policy and then explicitly grant permissions:
This creates a default-deny policy where the dev-team consumer group is blocked from all tools by default. Then, for specific tools you want to expose:
This approach ensures that only explicitly permitted tools are accessible. Tools without an allow ACL—like booking and deletion operations—remain blocked by the default policy.
When an MCP client connects and executes the tools/list RPC call, Kong intercepts the response from your upstream API and filters the tool list based on the authenticated user's permissions. Clients only see the tools they're authorized to use — they never even know about restricted tools.