Repository navigation
0.4.0 lets a server talk to its client while a request is running.
pip install -U easy-mcp-kitNew
- Progress updates.
report_progress(done, total, message)from any tool, resource or prompt. Throttled to one notification per 0.1 s, the last one always sent before the answer. - Ask the user a question.
elicit("For how many people?", {"guests": int})shows a form in the client and returns the answer. One tool works with stateless (2026-07-28) clients and with sessions. - Browser clients.
allowed_originsis now the CORS policy too: preflights are answered and answers are readable by pages on the origins you list. - Icons.
icons=on the server and on tools, resources and prompts.Icon.from_file("logo.png")embeds a small image. - Paged tool list.
tools/listreturns 100 tools per page withnextCursor.
from typing import Literal
from easy_mcp import MCPServer, elicit, report_progress
server = MCPServer(allowed_origins=["https://app.example.com"])
@server.tool
def book_table(restaurant: str) -> str:
"""Book a table."""
answer = elicit("For how many, and when?",
{"guests": int, "day": Literal["today", "tomorrow"]})
if not answer.accepted:
return "Nothing was booked."
report_progress(1, total=2, message="Checking availability")
...
return f"Booked {restaurant} for {answer['guests']}, {answer['day']}."Good to know before upgrading
- A page on a loopback origin (allowed by default) can now call a local server and read the answers. Pass
allowed_origins=[]to let no browser page in. - A server with more than 100 tools needs a client that follows
nextCursor. - A tool that calls
elicit()runs again from the top once the answer is in: ask first, act afterwards. - With several workers and tools that call
elicit(), setEASY_MCP_STATE_SECRETto the same value in every worker.
The README's Upgrading from 0.3.2 has the full list, and the CHANGELOG the details.
Left out on purpose
The 2026-07-28 specification deprecates sampling and removes resumable SSE streams, so 0.4.0 implements neither.
Checked against
The official MCP Python SDK client 2.3 in auto, 2026-07-28 and legacy modes, over Streamable HTTP and stdio.
What's Changed
- Keep a cancelled test call's audit event out of the next test by @Mark007-R in #54
- Replace the demo video and code snapshots for 0.3.2 by @Mark007-R in #55
- Progress updates: report_progress() by @Mark007-R in #56
- CORS for browser-based clients by @Mark007-R in #57
- Paginate tools/list by @Mark007-R in #58
- Icons for the server, tools, resources and prompts by @Mark007-R in #59
- Ask the user a question from a tool: elicit() by @Mark007-R in #60
- Release 0.4.0 by @Mark007-R in #61
Full Changelog: v0.3.2...v0.4.0