Skip to main content

Examples

Complete, production-ready examples demonstrating various features of the LeanMCP SDK.

Basic MCP Server

A minimal MCP server with a simple tool.

Weather Service

MCP server that fetches weather data from an external API.

Authenticated Service with AWS Cognito

MCP server with AWS Cognito authentication for protected operations.

Service with Elicitation

MCP server using elicitation to collect input from users.

Database Service with Resources

MCP server providing both tools and resources.

Multi-Service Server

Complete server with multiple services.

Testing Your Server

Using cURL

Using TypeScript Client

Next Steps

Core Package

Learn more about decorators and schemas

Authentication

Add authentication to your server

CLI Tool

Scaffold projects quickly

GitHub Examples

More examples on GitHub