π The fast, Pythonic way to build MCP servers and clients.
chore: Update SDK documentation
marvin-context-protocol[bot]a53030a806e9
diff --git a/docs/python-sdk/fastmcp-server-tasks-elicitation.mdx b/docs/python-sdk/fastmcp-server-tasks-elicitation.mdxindex f30b084ca..3bdd697ef 100644--- a/docs/python-sdk/fastmcp-server-tasks-elicitation.mdx+++ b/docs/python-sdk/fastmcp-server-tasks-elicitation.mdx@@ -50,7 +50,29 @@ in a Docket worker context where there's no active MCP request.- `McpError`: If the elicitation request fails-### `handle_task_input` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/tasks/elicitation.py#L234" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>+### `relay_elicitation` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/tasks/elicitation.py#L234" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>++```python+relay_elicitation(session: ServerSession, session_id: str, task_id: str, elicitation: dict[str, Any], fastmcp: FastMCP) -> None+```+++Relay elicitation from a background task worker to the client.++Called by the notification subscriber when it detects an input_required+notification with elicitation metadata. Sends a standard elicitation/create+request to the client session, then uses handle_task_input() to push the+response to Redis so the blocked worker can resume.++**Args:**+- `session`: MCP ServerSession+- `session_id`: Session identifier+- `task_id`: Background task ID+- `elicitation`: Elicitation metadata (message, requestedSchema)+- `fastmcp`: FastMCP server instance+++### `handle_task_input` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/tasks/elicitation.py#L290" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>```pythonhandle_task_input(task_id: str, session_id: str, action: str, content: dict[str, Any] | None, fastmcp: FastMCP) -> booldiff --git a/docs/python-sdk/fastmcp-server-tasks-notifications.mdx b/docs/python-sdk/fastmcp-server-tasks-notifications.mdxindex a69f97f7b..6652d7600 100644--- a/docs/python-sdk/fastmcp-server-tasks-notifications.mdx+++ b/docs/python-sdk/fastmcp-server-tasks-notifications.mdx@@ -25,7 +25,7 @@ require reliable delivery (input_required prompts, cancel signals).## Functions-### `push_notification` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/tasks/notifications.py#L46" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>+### `push_notification` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/tasks/notifications.py#L48" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>```pythonpush_notification(session_id: str, notification: dict[str, Any], docket: Docket) -> None@@ -43,10 +43,10 @@ that need reliable delivery across distributed processes.- `docket`: Docket instance for Redis access-### `notification_subscriber_loop` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/tasks/notifications.py#L74" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>+### `notification_subscriber_loop` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/tasks/notifications.py#L76" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>```python-notification_subscriber_loop(session_id: str, session: ServerSession, docket: Docket) -> None+notification_subscriber_loop(session_id: str, session: ServerSession, docket: Docket, fastmcp: FastMCP) -> None```@@ -64,12 +64,13 @@ This loop:- `session_id`: Session identifier to subscribe to- `session`: MCP ServerSession for sending notifications- `docket`: Docket instance for Redis access+- `fastmcp`: FastMCP server instance (for elicitation relay)-### `ensure_subscriber_running` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/tasks/notifications.py#L311" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>+### `ensure_subscriber_running` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/tasks/notifications.py#L238" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>```python-ensure_subscriber_running(session_id: str, session: ServerSession, docket: Docket) -> None+ensure_subscriber_running(session_id: str, session: ServerSession, docket: Docket, fastmcp: FastMCP) -> None```@@ -82,9 +83,10 @@ Safe to call multiple times for the same session.- `session_id`: Session identifier- `session`: MCP ServerSession- `docket`: Docket instance+- `fastmcp`: FastMCP server instance (for elicitation relay)-### `stop_subscriber` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/tasks/notifications.py#L349" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>+### `stop_subscriber` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/tasks/notifications.py#L278" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>```pythonstop_subscriber(session_id: str) -> None@@ -100,7 +102,7 @@ for delivery if client reconnects (with TTL expiration).- `session_id`: Session identifier-### `get_subscriber_count` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/tasks/notifications.py#L369" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>+### `get_subscriber_count` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/tasks/notifications.py#L298" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>```pythonget_subscriber_count() -> int