mirror of
https://github.com/PrefectHQ/fastmcp.git
synced 2026-08-09 23:29:10 +02:00
* Update repository references from jlowin/fastmcp to prefecthq/fastmcp * Retrigger CI after repo transfer * chore: Update SDK documentation * Only run deep triage on bug issues for jlowin --------- Co-authored-by: marvin-context-protocol[bot] <225465937+marvin-context-protocol[bot]@users.noreply.github.com>
27 lines
976 B
Text
27 lines
976 B
Text
---
|
|
title: memory
|
|
sidebarTitle: memory
|
|
---
|
|
|
|
# `fastmcp.client.transports.memory`
|
|
|
|
## Classes
|
|
|
|
### `FastMCPTransport` <sup><a href="https://github.com/PrefectHQ/fastmcp/blob/main/src/fastmcp/client/transports/memory.py#L14" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
|
|
|
|
|
|
In-memory transport for FastMCP servers.
|
|
|
|
This transport connects directly to a FastMCP server instance in the same
|
|
Python process. It works with both FastMCP 2.x servers and FastMCP 1.0
|
|
servers from the low-level MCP SDK. This is particularly useful for unit
|
|
tests or scenarios where client and server run in the same runtime.
|
|
|
|
|
|
**Methods:**
|
|
|
|
#### `connect_session` <sup><a href="https://github.com/PrefectHQ/fastmcp/blob/main/src/fastmcp/client/transports/memory.py#L33" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
|
|
|
|
```python
|
|
connect_session(self, **session_kwargs: Unpack[SessionKwargs]) -> AsyncIterator[ClientSession]
|
|
```
|