Simple MCP Server with Streamable HTTP Example
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., "@Simple MCP Server with Streamable HTTP ExampleAdd 5 and 3"
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.
A simple MCP server with streamable HTTP transport Example
This example demonstrates how to create a simple MCP server with streamable HTTP transport, featuring several tools, prompts, and resources.
Run
By default, the server runs on port 8000.
python simple_streamable_http_mcp_server.pyOr with uv:
uv run mcp-serverRelated MCP server: hello-mcp
Custom Port
Change the port (default is 8000):
MCP_SERVER_PORT=9000 python simple_streamable_http_mcp_server.pyDebug Logging
Enable debug logs for tool calls:
MCP_DEBUG=1 python simple_streamable_http_mcp_server.pyBoth Together
MCP_SERVER_PORT=9000 MCP_DEBUG=1 python simple_streamable_http_mcp_server.pyTools
hello_world(name)- Say helloadd_numbers(a, b)- Add two numbersrandom_number(min_val, max_val)- Generate random numberreturn_json_example()- Return example JSONcalculate_bmi(weight, height)- Calculate BMIget_logo()- Return the OllMCP logo image
Prompts
BMI Calculator- Prompt for BMI calculation
Resources
server://info- Get server infotext://welcome- Get a welcome messageimages://ollmcp-logo- Get the OllMCP logo imagefile://{path*}- Read a local text file by path
This server cannot be deployed
Maintenance
Related MCP Connectors
Remote MCP server exposing SMI Aware tools, resources, and skills over Streamable HTTP.
Host your MCP tool over streamable HTTP in one command.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceA minimal demonstration server showcasing MCP protocol capabilities including tools, resources, and prompts with basic examples like hello world functionality.1 npmMIT
- AlicenseNot gradedqualityDmaintenanceA minimal learning-focused MCP server that demonstrates core primitives like tools and resources through simple greeting functions. It provides a foundational example for connecting AI models to external data using both Streamable HTTP and stdio transports.10 npmMIT
- FlicenseNot gradedqualityDmaintenanceEducational example of an MCP server built with FastMCP, demonstrating how to expose tools, resources, and prompts for AI clients.-
- FlicenseAqualityCmaintenanceA minimal MCP server that demonstrates the entire protocol using a simple in-memory todo list, including tools, resources, prompts, and elicitation.31-