Country Explorer MCP Server
This MCP server enables intelligent country exploration and content generation through three core tools:
Web Search - Search the internet for country information, including cultural, historical, and geographic details
Unsplash Image Search - Find high-quality photos with:
Customizable results (1-30 photos, default: 10)
Orientation filtering (landscape, portrait, or squarish)
Full metadata including photographer credits and URLs
Dice Rolling - Roll dice using standard notation (e.g., "2d6") with configurable number of rolls
The server is designed to integrate with LangGraph agents to generate comprehensive country profiles: researching content via web search, finding 10 relevant images from Unsplash, and producing rich markdown documents with embedded images and photographer credits.
Utilizes LangChain MCP adapters to integrate various tools and services within the agent workflow
Uses LangGraph for agent orchestration to create intelligent workflows that combine web search, image retrieval, and content generation for country profile creation
Integrates with OpenAI's GPT-4 language model to power the LangGraph agent for intelligent country exploration and content generation
Provides tools for searching and retrieving high-quality images from Unsplash's photo library, including support for orientation filters and photographer credits
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Country Explorer MCP Server create a profile for Japan with beautiful landscape images"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
MCP Demo: Country Explorer with LangGraph
๐ Country Explorer: MCP + LangGraph Integration
This project demonstrates a complete MCP (Model Context Protocol) server integrated with LangGraph to create beautiful country profiles with embedded images.
Related MCP server: Unsplash MCP Server
โจ Features
๐ MCP Server with Unsplash Search API integration
๐ค LangGraph Agent for intelligent country exploration
๐ผ๏ธ 10 Images per Country with photographer credits
๐ Beautiful Markdown Profiles with embedded images
๐งช Comprehensive Test Suite for validation
๐ Organized Project Structure with
profiles/andtests/folders
๐๏ธ Project Structure
mcp-demo/
โโโ country_explorer.py # Main LangGraph app (10 images)
โโโ server.py # MCP server with Unsplash API
โโโ profiles/ # ๐ Generated country profiles
โ โโโ india_profile.md
โ โโโ japan_profile.md
โ โโโ uganda_profile.md
โ โโโ usa_profile.md
โโโ tests/ # ๐ Test files
โ โโโ test_country_explorer.py
โ โโโ test_unsplash.py
โ โโโ search_5_mountains.py
โโโ .env # API keys๐ Quick Start
Prerequisites
Python 3.13+
Unsplash API key
OpenAI API key
Installation
Clone the repository:
git clone https://github.com/anilsharmay/mcp-demo.git cd mcp-demoInstall dependencies:
uv syncConfigure environment variables: Create
.envfile with your API keys:UNSPLASH_API_KEY=your_unsplash_api_key_here OPENAI_API_KEY=your_openai_api_key_here TAVILY_API_KEY=your_tavily_api_key_here
Running the Country Explorer
Start the MCP server:
uv run mcp dev server.pyRun the Country Explorer:
uv run python country_explorer.pyRun tests:
cd tests && uv run python test_country_explorer.py
๐ฏ MCP Server Tools
The MCP server provides these tools:
unsplash_search: Search for beautiful images with orientation filtersweb_search: Search the web for country informationroll_dice: Roll dice with custom notation
๐ค LangGraph Agent
The Country Explorer agent:
Researches countries using web search
Finds 10 beautiful images via Unsplash
Creates rich markdown profiles with embedded images
Includes photographer credits and links
๐ธ Sample Output
Each country profile includes:
Cultural information and history
Geographic details and landmarks
10 high-quality images with credits
Clean markdown formatting for easy viewing
๐ฌ Demo GIFs
India Profile:

Switzerland Profile:

USA Profile:

๐งช Testing
Run the comprehensive test suite:
# Test MCP server
uv run python tests/test_unsplash.py
# Test Country Explorer
cd tests && uv run python test_country_explorer.py
# Test mountain search
uv run python tests/search_5_mountains.py๐ง MCP Configuration
Add to your Cursor MCP settings:
{
"mcpServers": {
"unsplash-mcp-server": {
"command": "uv",
"args": ["--directory", ".", "run", "server.py"]
}
}
}๐ Technologies Used
MCP (Model Context Protocol) - Server framework
LangGraph - Agent orchestration
LangChain MCP Adapters - Tool integration
Unsplash API - Image search
OpenAI GPT-4 - Language model
Python 3.13 - Runtime environment
๐ Showcase
This project demonstrates:
โ MCP Server Development with custom API integration
โ LangGraph Agent Creation with tool orchestration
โ Beautiful Output Generation with embedded images
โ Clean Project Organization and testing
โ Real-world Application of AI agent frameworks
Perfect for showcasing MCP + LangGraph integration! ๐โจ
Available Tools
3 toolsroll_diceC
Roll the dice with the given notation
Inputs: notation (required), num_rolls. Returns: result
unsplash_searchB
Search for photos on Unsplash using the given query.
Inputs: query (required), num_results, orientation. Returns: result
web_searchC
Search the web for information about the given query
Inputs: query (required). Returns: result
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelogโฆ
TDQS
Scored across 3 tools
Each tool has a clearly distinct purpose with no ambiguity: roll_dice is for dice rolling, unsplash_search is for photo searches, and web_search is for general web searches. The domains are completely separate, making misselection unlikely.
The naming is inconsistent with mixed conventions: roll_dice uses snake_case, unsplash_search uses snake_case, and web_search uses snake_case, but the verb styles vary (roll vs. search). There is no predictable pattern like verb_noun consistency across tools.
With only 3 tools, the set feels thin for a server named 'Country Explorer MCP Server', which suggests a domain focused on country-related exploration. The tools do not align with this purpose, indicating a significant mismatch in scope.
The tool surface is severely incomplete for the stated purpose of country exploration. There are no tools for retrieving country data, demographics, maps, or other relevant information, leaving obvious gaps that will cause agent failures in this domain.
Maintenance
Related MCP Connectors
Unblocking and fresh web data for agents: URL to Markdown, YouTube, Maps, Amazon, jobs. Pay per call
Web search, URL content extraction to Markdown, site mapping, and recursive web crawler.
Search the web, fetch any URL and map a site as clean, LLM-ready Markdown.
Web data for agents. Extract web pages, crawl websites, discover URLs, and search the web.
Related MCP Servers
- AlicenseNot gradedqualityBmaintenanceProvides access to the Unsplash API, enabling AI assistants to search and retrieve high-quality photos, browse collections, view photographer profiles, and get photo statistics with advanced filtering options.187 npmMIT
- AlicenseBqualityDmaintenanceEnables users to search for high-quality photos on Unsplash with support for advanced filtering by orientation and content safety. It provides formatted photo metadata and images in either base64-encoded format or as JSON with URLs via stdio transport.131 npmMIT
- AlicenseNot gradedqualityDmaintenanceEnables AI agents to search, recommend, and deliver professional stock photos from Unsplash with intelligent context awareness and automatic attribution management.39 npm64MIT
- AlicenseNot gradedqualityDmaintenanceEnables searching and downloading photos from Unsplash via the Unsplash API, with support for pagination, orientation filtering, and multiple resolutions.187 npm1MIT