This commit is contained in:
Zack Lee 2024-11-20 12:24:08 -05:00
commit ba7d5b866d
No known key found for this signature in database
3 changed files with 79 additions and 1432 deletions

View file

@ -1,11 +1,11 @@
---
title: "Event Handling"
title: "Event handling"
description: "Handle events and manage state in your MCP server"
---
MCP servers process various events including requests, notifications, and connection lifecycle events. This guide explains how to implement event handlers effectively in your server.
## Request handlers
## Request handling
Request handlers process incoming requests from clients and must return a response. Each handler is associated with a specific method name.
@ -62,7 +62,7 @@ async def handle_list_tools(request: ListToolsRequest) -> ListToolsResult:
```
</CodeGroup>
## Notification handlers
## Notification handling
Notification handlers process one-way messages that don't require responses. They're useful for handling events like resource updates or logging messages.

View file

@ -1,5 +1,5 @@
---
title: "Resource Management"
title: "Resource management"
description: "How to implement resource management in your MCP server"
---

View file

@ -1,5 +1,5 @@
---
title: "Tool Implementation"
title: "Tool implementation"
description: "Learn how to implement tools in your MCP server"
---