Skip to main content
Glama
jonigl

Simple MCP Server with Streamable HTTP Example

by jonigl

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.py

Or with uv:

uv run mcp-server

Related MCP server: Basic MCP Server

Custom Port

Change the port (default is 8000):

MCP_SERVER_PORT=9000 python simple_streamable_http_mcp_server.py

Debug Logging

Enable debug logs for tool calls:

MCP_DEBUG=1 python simple_streamable_http_mcp_server.py

Both Together

MCP_SERVER_PORT=9000 MCP_DEBUG=1 python simple_streamable_http_mcp_server.py

Tools

  • hello_world(name) - Say hello

  • add_numbers(a, b) - Add two numbers

  • random_number(min_val, max_val) - Generate random number

  • return_json_example() - Return example JSON

  • calculate_bmi(weight, height) - Calculate BMI

  • get_logo() - Return the OllMCP logo image

Prompts

  • BMI Calculator - Prompt for BMI calculation

Resources

  • server://info - Get server info

  • text://welcome - Get a welcome message

  • images://ollmcp-logo - Get the OllMCP logo image

  • file://{path*} - Read a local text file by path

F
license - not found
-
quality - not tested
C
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • F
    license
    -
    quality
    D
    maintenance
    A foundational template for building MCP servers in Python using Streamable HTTP transport. Provides example implementations of tools, resources, and prompts to help developers create custom MCP integrations for AI assistants.
    Last updated
  • A
    license
    -
    quality
    D
    maintenance
    A minimal demonstration server showcasing MCP protocol capabilities including tools, resources, and prompts with basic examples like hello world functionality.
    Last updated
    4
    MIT
  • A
    license
    -
    quality
    D
    maintenance
    A 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.
    Last updated
    20
    MIT

View all related MCP servers

Related MCP Connectors

  • MCP server exposing the Backtest360 engine API as tools for AI agents.

  • A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with yo…

  • AI Reasoning Cache & Consensus Layer with 11 MCP tools via Streamable HTTP.

View all MCP Connectors

Latest Blog Posts

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/jonigl/mcp-server-with-streamable-http-example'

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