What problem does it solve?
Litestar developers face manual, error-prone work when building Model Context Protocol (MCP) integrations for their web applications, requiring custom boilerplate for route exposure, transport handling, and authentication that duplicates existing Litestar functionality.
Core Features & Use Cases
- Opt-in Route Marking: Expose Litestar route handlers as MCP tools, resources, or prompts with simple decorator arguments, no extra wrapper code required.
- Multi-Transport Support: Serve MCP primitives over Streamable HTTP, stdio, or SSE transports for compatibility with all major AI coding agents and IDEs.
- Production-Ready Guardrails: Built-in pagination, OIDC auth support, tool call observability callbacks, and route filtering to secure and scale MCP deployments.
Use case example: An e-commerce team can expose product listing as an MCP resource and add-to-cart as a tool, allowing AI shopping assistants to interact with their store while keeping internal metrics routes hidden from MCP clients.
Quick Start
Use the litestar-mcp skill to configure your existing Litestar application to expose selected route handlers as MCP tools and resources for AI client access.