python-sdk icon indicating copy to clipboard operation
python-sdk copied to clipboard

The official Python SDK for Model Context Protocol servers and clients

Results 229 python-sdk issues
Sort by recently updated
recently updated
newest added

## Summary This PR enables tools to access the transport-level session ID via `Context.session_id`, supporting session-level tracing and observability use cases. ## Changes - **InitializationOptions**: Add optional `session_id` field -...

needs maintainer action
enhancement

## Summary Fixes #156 - Adds support for displaying stderr output in Jupyter Notebook environments. ## Changes - Added Jupyter/IPython detection using `IPython.get_ipython()` - Implemented async stderr reader that reads...

### Initial Checks - [x] I confirm that I'm using the latest version of MCP Python SDK - [x] I confirm that I searched for my issue in https://github.com/modelcontextprotocol/python-sdk/issues before...

Updated the Dynamic Client Registration (DCR) handler to comply with RFC 7591 by making the refresh_token grant type optional. Previously, the handler incorrectly required both authorization_code and refresh_token grant types,...

Implements per-request headers functionality to enable various use cases such as multi-tenant authentication, request tracing, A/B testing, and debugging while maintaining a single persistent connection. Changes: - Add extra_headers parameter...

# FastMCP structured output improvements brief summary of changes : Improve FastMCP structured-output handling for 'dict[str, T]' return types and mixed-list tool outputs, and make the test suite/CI more robust:...

### Description ## Summary MCP tools and resources built with the Python SDK can, by default, access the full file system, network, and environment of the host process. This is...

### Description ## Summary The current tooling model assumes that tools complete within a single request/response cycle. For long-running operations (e.g. batch processing, model training, large file processing), this is...

### Description ## Summary Tools can declare `outputSchema`, and the SDK validates the returned value against this schema **after** the tool executes. If validation fails: - the tool’s side effects...

### Description ## Summary The Python SDK exposes a variety of classes and functions across packages and submodules. Some are clearly meant to be public, others are internal but not...