From 42c593996f3cec4396f9cd6d9250e8770c801709 Mon Sep 17 00:00:00 2001 From: Shmuel Leider Date: Tue, 26 Nov 2024 17:44:36 +0000 Subject: [PATCH 1/9] Update documentation to include hiding .env --- docs/first-server/typescript.mdx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/docs/first-server/typescript.mdx b/docs/first-server/typescript.mdx index 18354ac..e8d04c2 100644 --- a/docs/first-server/typescript.mdx +++ b/docs/first-server/typescript.mdx @@ -41,6 +41,10 @@ This guide uses the OpenWeatherMap API. You'll need a free API key from [OpenWea ```bash OPENWEATHER_API_KEY=your-api-key-here ``` + Make sure to add your environment file to `.gitignore` + ```bash + .env + ``` From a09a29acaebfc8e2d7b68d3cd0aeec54ace6eef5 Mon Sep 17 00:00:00 2001 From: yinzhidong Date: Wed, 27 Nov 2024 10:56:23 +0800 Subject: [PATCH 2/9] docs: fix method name --- docs/first-server/python.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/first-server/python.mdx b/docs/first-server/python.mdx index 7a1c42c..3ee2f80 100644 --- a/docs/first-server/python.mdx +++ b/docs/first-server/python.mdx @@ -751,7 +751,7 @@ uvicorn.run(app, host="0.0.0.0", port=8000) pass def json(self): - return nock_forecast_response + return mock_forecast_response class AsyncClient(): def __aenter__(self): From 3887a579d671c1cb5fc4353c61419e1c4a5c9798 Mon Sep 17 00:00:00 2001 From: Pierre Carion Date: Tue, 26 Nov 2024 19:05:33 -0800 Subject: [PATCH 3/9] update tool response to be compliant with spec --- docs/first-server/typescript.mdx | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/docs/first-server/typescript.mdx b/docs/first-server/typescript.mdx index 18354ac..bf52594 100644 --- a/docs/first-server/typescript.mdx +++ b/docs/first-server/typescript.mdx @@ -342,18 +342,18 @@ This guide uses the OpenWeatherMap API. You'll need a free API key from [OpenWea } return { - content: { - mimeType: "application/json", + content: [{ + type: "text", text: JSON.stringify(forecasts, null, 2) - } + }] }; } catch (error) { if (axios.isAxiosError(error)) { return { - content: { - mimeType: "text/plain", + content: [{ + type: "text", text: `Weather API error: ${error.response?.data.message ?? error.message}` - }, + }], isError: true, } } From 84efa9c3c8632608e7b382ec6d57cbe71fd248d1 Mon Sep 17 00:00:00 2001 From: Justin Spahr-Summers Date: Wed, 27 Nov 2024 10:41:18 -0600 Subject: [PATCH 4/9] Simplify/clarify TS first server `command` --- docs/first-server/typescript.mdx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/first-server/typescript.mdx b/docs/first-server/typescript.mdx index f7320d4..d499cc9 100644 --- a/docs/first-server/typescript.mdx +++ b/docs/first-server/typescript.mdx @@ -372,7 +372,6 @@ This guide uses the OpenWeatherMap API. You'll need a free API key from [OpenWea ```bash npm run build - npm link ``` @@ -387,7 +386,8 @@ This guide uses the OpenWeatherMap API. You'll need a free API key from [OpenWea { "mcpServers": { "weather": { - "command": "weather-server", + "command": "node", + "args": ["/path/to/weather-server/build/index.js"], "env": { "OPENWEATHER_API_KEY": "your-api-key", } From dcb2f90d2a0c2a60854429da6c7f792547f83bcc Mon Sep 17 00:00:00 2001 From: Michael Bleigh Date: Wed, 27 Nov 2024 13:27:52 -0800 Subject: [PATCH 5/9] Adds Firebase Genkit to client list --- clients.mdx | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/clients.mdx b/clients.mdx index 1c492d5..b2966c3 100644 --- a/clients.mdx +++ b/clients.mdx @@ -12,10 +12,12 @@ This page provides an overview of applications that support the Model Context Pr | [Claude Desktop App][Claude] | ✅ | ✅ | ✅ | ❌ | ❌ | Full support for all MCP features | | [Zed][Zed] | ❌ | ✅ | ❌ | ❌ | ❌ | Prompts appear as slash commands | | [Sourcegraph Cody][Cody] | ✅ | ❌ | ❌ | ❌ | ❌ | Supports resources through OpenCTX | +| [Firebase Genkit][Genkit] | ⚠️ | ✅ | ✅ | ❌ | ❌ | Supports resource list and lookup through tools. | [Claude]: https://claude.ai/download [Zed]: https://zed.dev [Cody]: https://sourcegraph.com/cody +[Genkit]: https://github.com/firebase/genkit [Resources]: https://modelcontextprotocol.io/docs/concepts/resources [Prompts]: https://modelcontextprotocol.io/docs/concepts/prompts @@ -53,6 +55,15 @@ The Claude desktop application provides comprehensive support for MCP, enabling - Uses OpenCTX as an abstraction layer - Future support planned for additional MCP features +### Firebase Genkit +[Genkit](https://github.com/firebase/genkit) is Firebase's SDK for building and integrating GenAI features into applications. The [genkitx-mcp](https://github.com/firebase/genkit/tree/main/js/plugins/mcp) plugin enables consuming MCP servers as a client or creating MCP servers from Genkit tools and prompts. + +**Key features:** +- Client support for tools and prompts (resources partially supported) +- Rich discovery with support in Genkit's Dev UI playground +- Seamless interoperability with Genkit's existing tools and prompts +- Works across a wide variety of GenAI models from top providers + ## Adding MCP support to your application If you've added MCP support to your application, we encourage you to submit a pull request to add it to this list. MCP integration can provide your users with powerful contextual AI capabilities and make your application part of the growing MCP ecosystem. From 08d35a04cbd5d5bb3d7481e5a14901d7972600f4 Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Wed, 27 Nov 2024 23:04:06 +0000 Subject: [PATCH 6/9] Fix docs on resource template usage --- docs/first-server/python.mdx | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/docs/first-server/python.mdx b/docs/first-server/python.mdx index 12559a1..3c78a86 100644 --- a/docs/first-server/python.mdx +++ b/docs/first-server/python.mdx @@ -638,18 +638,15 @@ uvicorn.run(app, host="0.0.0.0", port=8000) ```python - @self.list_resources() - async def list_resources(self) -> ListResourcesResult: - return ListResourcesResult( - resources=[...], - resourceTemplates=[ - ResourceTemplate( - uriTemplate="weather://{city}/current", - name="Current weather for any city", - mimeType="application/json" - ) - ] - ) + @app.list_resource_templates() + async def list_resource_templates() -> list[ResourceTemplate]: + return [ + ResourceTemplate( + uriTemplate="weather://{city}/current", + name="Current weather for any city", + mimeType="application/json" + ) + ] ``` From a561e7b8814cd4b4366f0ff516dfe5c3da385432 Mon Sep 17 00:00:00 2001 From: Alasdair Brown Date: Thu, 28 Nov 2024 09:53:57 +0000 Subject: [PATCH 7/9] update log dir Updates the log dir on MacOS in the TS quickstart --- docs/first-server/typescript.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/first-server/typescript.mdx b/docs/first-server/typescript.mdx index d499cc9..0f39531 100644 --- a/docs/first-server/typescript.mdx +++ b/docs/first-server/typescript.mdx @@ -565,7 +565,7 @@ npm run build Look for detailed error messages in the Claude Desktop logs: ```bash # Monitor logs -tail -n 20 -f ~/Library/Application\ Support/Claude/mcp*.log +tail -n 20 -f ~/Library/Logs/Claude/mcp*.log ``` ### Type errors From a95bd06455c45a33a2d8144ad15934b28371d314 Mon Sep 17 00:00:00 2001 From: Jack Smith Date: Thu, 28 Nov 2024 12:33:50 -0800 Subject: [PATCH 8/9] Clarify the resources docs --- docs/concepts/resources.mdx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/docs/concepts/resources.mdx b/docs/concepts/resources.mdx index d61722a..50eb8eb 100644 --- a/docs/concepts/resources.mdx +++ b/docs/concepts/resources.mdx @@ -7,8 +7,12 @@ Resources are a core primitive in the Model Context Protocol (MCP) that allow se Resources are designed to be **application-controlled**, meaning that the client application can decide how and when they should be used. + Different MCP clients may handle resources differently. For example: + - Claude Desktop currently requires users to explicitly select resources before they can be used + - Other clients might automatically select resources based on heuristics + - Some implementations may even allow the AI model itself to determine which resources to use - For example, one application may require users to explicitly select resources, while another could automatically select them based on heuristics or even at the discretion of the AI model itself. + Server authors should be prepared to handle any of these interaction patterns when implementing resource support. In order to expose data to models automatically, server authors should use a **model-controlled** primitive such as [Tools](./tools). ## Overview From bef628f36eb1adc7dfcd7450f33377456082cb55 Mon Sep 17 00:00:00 2001 From: Jatan Loya Date: Thu, 28 Nov 2024 20:27:21 -0500 Subject: [PATCH 9/9] fixes typo in python.mdx --- docs/first-server/python.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/first-server/python.mdx b/docs/first-server/python.mdx index 1c36727..2105ec1 100644 --- a/docs/first-server/python.mdx +++ b/docs/first-server/python.mdx @@ -477,7 +477,7 @@ Let's build your first MCP server in Python! We'll create a weather server that ## Available transports -While this guide uses stdio transport, MCP supports additonal transport options: +While this guide uses stdio transport, MCP supports additional transport options: ### SSE (Server-Sent Events)