dynamic resource not working in Claude desktop
Describe the bug A clear and concise description of what the bug is.
To Reproduce use the demo server in quick start document
# server.py
from mcp.server.fastmcp import FastMCP
# Create an MCP server
mcp = FastMCP("Demo")
@mcp.resource("config://app")
def get_config() -> str:
"""Static configuration data"""
return "App configuration here"
# dynamic resource
@mcp.resource("greeting://{name}")
def get_greeting(name: str) -> str:
"""Get a personalized greeting"""
return f"Hello, {name}!"
Claude can not see the dynamic resource, only the static one works.
Expected behavior Use dynamic resource in Claude
Screenshots
Desktop (please complete the following information):
- OS: windows 10
Yes, sadly Claude Desktop does currently not support dyanmic resources.
Do you know which application can work with dynamic resources? I want to test it with my mcp server.
Not work in MacOS, too, I try bunch of time.....
Maybe a note should be added in the "Notes" of the "Feature support matrix" for Claude Desktop, spent a bunch of time wondering what was wrong.
Claude calls resources/list which is for static resources. But dynamic resources are called at resources/templates/list -- which it seems based on logs Claude does not call on.
This can be seen in the MCP Inspector > Resources tab at top
Can we prioritise this please.. need to experiment few things with resources.. currently blocked on this
I've spent more than a day trying to make it work. This is a major disappointment.
I thought I did something wrong..
+1, spent a bunch of time testing my MCP, only to discover it is not yet supported ...
+1. It isnt showing up in the inspector either
I successfully made it work in the inspector, but unfortunately couldn't get it working in Claude Desktop. The same approach doesn't seem to function properly in the desktop app.
You might have got it working for static resources .. not dynamic resources .. without resources mcp tooling feels incomplete . Please do let me know if it’s working for you. I will give it a try .
On Sat, 19 Apr 2025 at 7:34 PM, Anton Sakharov @.***> wrote:
I successfully made it work in the inspector, but unfortunately couldn't get it working in Claude Desktop. The same approach doesn't seem to function properly in the desktop app.
— Reply to this email directly, view it on GitHub https://github.com/modelcontextprotocol/python-sdk/issues/263#issuecomment-2816720861, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAGPZOJMOJP462PSO2547PD22JJYNAVCNFSM6AAAAABY2PLXM2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDQMJWG4ZDAOBWGE . You are receiving this because you commented.Message ID: @.***> qlmmlp left a comment (modelcontextprotocol/python-sdk#263) https://github.com/modelcontextprotocol/python-sdk/issues/263#issuecomment-2816720861
I successfully made it work in the inspector, but unfortunately couldn't get it working in Claude Desktop. The same approach doesn't seem to function properly in the desktop app.
— Reply to this email directly, view it on GitHub https://github.com/modelcontextprotocol/python-sdk/issues/263#issuecomment-2816720861, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAGPZOJMOJP462PSO2547PD22JJYNAVCNFSM6AAAAABY2PLXM2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDQMJWG4ZDAOBWGE . You are receiving this because you commented.Message ID: @.***>
I am also having the same issue. Can you guys make it quick ?
Me too, also the inspector doesn't support adding template params
in puppeteer the snapshot is exposed to claude desktop as an image resource (correct?) ... so somehow they are doing it correctly there ?
it doesn't work, tried many times
yeah, meatime I read more on it and looks like resources aren't support in claude desktop in windows at least (although in the Feature support matrix it suposedly suports). But I found one of the thing I was looking into, the correct way to deliver image to the mcp client (I am sure it is also how they are doing in puppeteer) below in python for example a take_screenshot, adapted from example in github examples
@mcp.tool()
def read_screen():
"""
Take a screenshot of the user's screen and return it as an image. Use
this tool anytime the user wants you to look at something they're doing.
"""
logger.info("Taking screenshot")
try:
buffer = io.BytesIO()
# if the file exceeds ~1MB, it will be rejected by Claude
screenshot = pyautogui.screenshot()
screenshot.convert("RGB").save(buffer, format="JPEG", quality=60, optimize=True)
buffer.seek(0)
logger.info("Screenshot captured successfully")
return Image(data=buffer.getvalue(), format="jpeg")
except Exception as e:
logger.error(f"Error taking screenshot: {str(e)}")
raise Exception(f"Failed to take screenshot: {str(e)}")
yeah, meatime I read more on it and looks like resources aren't support in claude desktop in windows at least (although in the Feature support matrix it suposedly suports). But I found one of the thing I was looking into, the correct way to deliver image to the mcp client (I am sure it is also how they are doing in puppeteer) below in python for example a take_screenshot, adapted from example in github examples
@mcp.tool() def read_screen(): """ Take a screenshot of the user's screen and return it as an image. Use this tool anytime the user wants you to look at something they're doing. """ logger.info("Taking screenshot") try: buffer = io.BytesIO() # if the file exceeds ~1MB, it will be rejected by Claude screenshot = pyautogui.screenshot() screenshot.convert("RGB").save(buffer, format="JPEG", quality=60, optimize=True) buffer.seek(0) logger.info("Screenshot captured successfully") return Image(data=buffer.getvalue(), format="jpeg") except Exception as e: logger.error(f"Error taking screenshot: {str(e)}") raise Exception(f"Failed to take screenshot: {str(e)}")
@ruilacerda what is exactly the type/package of Image that your are using? tried to use ktinker/PIL but seems like Claude coulndt handle the object
Hi everyone,
If you can get Claude Desktop to work with static resources, could you please help me with this issue of MCP resources Any help would be appreciated.
Thank you so much
Ping on this. Can we prioritize this? Without dynamic MCP resources, claude code is less useful.
This is not a Python SDK issue. Unfortunately, there is no Claude Desktop repo for requests such as these. Any chance that's coming @felixrieseberg ?
Also: resources in Claude Desktop
- https://github.com/modelcontextprotocol/python-sdk/issues/92
- https://github.com/modelcontextprotocol/python-sdk/issues/1016
(The Claude Code repo has issues related to Resources, list-changed notifications, and Resource Templates.)
Do you know which application can work with dynamic resources? I want to test it with my mcp server.
GitHub CoPilot in VS Code supports resource templates. Still not in Claude Desktop - just tried it.