# Python Examples

## Client Examples

| Example | Description |
|---------|-------------|
| [http_example.py](http_example.py) | HTTP client usage |
| [stream_example.py](stream_example.py) | Streaming responses |
| [code_mode_example.py](code_mode_example.py) | Using MCP tools via code execution |
| [direct_tool_call.py](direct_tool_call.py) | Direct tool invocation without an agent |
| [multi_server_example.py](multi_server_example.py) | Working with multiple MCP servers |
| [multimodal_input_example.py](multimodal_input_example.py) | Multimodal input (image processing) |
| [simple_oauth_example.py](simple_oauth_example.py) | OAuth with Dynamic Client Registration |

### OAuth Client Examples

| Example | Description |
|---------|-------------|
| [client/oauth_dynamic_client_registration.py](client/oauth_dynamic_client_registration.py) | OAuth with Dynamic Client Registration using Linear |
| [client/oauth_preregistered.py](client/oauth_preregistered.py) | OAuth with pre-registered credentials using GitHub |

## Server Examples

| Example | Description |
|---------|-------------|
| [server/server_example.py](server/server_example.py) | Basic server with tools, resources, prompts, and annotations |
| [server/middleware_example.py](server/middleware_example.py) | Server middleware (logging, auth, rate limiting) |
| [server/context_example.py](server/context_example.py) | Server context usage (logging, sampling, notifications) |

## Agent Examples

| Example | Description |
|---------|-------------|
| [chat_example.py](chat_example.py) | Chat agent with built-in conversation memory |
| [limited_memory_chat.py](limited_memory_chat.py) | Chat agent with limited memory window |
| [mcp_everything.py](mcp_everything.py) | Comprehensive MCP functionality testing |
| [structured_output.py](structured_output.py) | Structured output with schema validation |
| [simple_server_manager_use.py](simple_server_manager_use.py) | Dynamic server selection with ServerManager |
| [sandbox_everything.py](sandbox_everything.py) | Sandboxed execution using E2B |

## Integration Examples

| Example | Description |
|---------|-------------|
| [openai_integration_example.py](openai_integration_example.py) | OpenAI API integration |
| [anthropic_integration_example.py](anthropic_integration_example.py) | Anthropic API integration |
| [langchain_integration_example.py](langchain_integration_example.py) | LangChain integration |
| [google_integration_example.py](google_integration_example.py) | Google API integration |

## MCP Server Integrations

| Example | Description |
|---------|-------------|
| [airbnb_use.py](airbnb_use.py) | Airbnb MCP server |
| [blender_use.py](blender_use.py) | Blender MCP server |
| [browser_use.py](browser_use.py) | Browser automation MCP server |
| [filesystem_use.py](filesystem_use.py) | Filesystem operations MCP server |
