Skip to main content
Glama

Unsplash API MCP Server

test_mcp_client.py772 B
import asyncio import json from mcp.client.sse import sse_client async def main(): """Test MCP client connecting to the server.""" async with sse_client("http://localhost:8000/mcp") as (read_stream, write_stream): # Initialize the client session from mcp.client.session import ClientSession async with ClientSession(read_stream, write_stream) as session: # List available tools tools = await session.list_tools() if tools: print(f"Found {len(tools)} tools:") for tool in tools: print(f"- {tool.get('name')}: {tool.get('description')}") else: print("No tools found.") if __name__ == "__main__": asyncio.run(main())

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/gzpaitch/Unsplash-MCP'

If you have feedback or need assistance with the MCP directory API, please join our Discord server