You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ctx: Context object containing request and session information.
281
+
282
+
Returns:
283
+
Dictionary with an echo message and the deps.
284
+
"""
285
+
await ctx.info('This is an info message')
286
+
287
+
deps: Any =getattr(ctx.request_context.meta, 'deps')
288
+
return {'echo': 'This is an echo message', 'deps': deps}
289
+
290
+
if__name__=='__main__':
291
+
mcp.run()
292
+
```
293
+
260
294
## Using Tool Prefixes to Avoid Naming Conflicts
261
295
262
296
When connecting to multiple MCP servers that might provide tools with the same name, you can use the `tool_prefix` parameter to avoid naming conflicts. This parameter adds a prefix to all tool names from a specific server.
0 commit comments