Forge documentation
Library referencePython

forge.mcp

Python mcp package; imports are explicit from this package.

Python mcp package; imports are explicit from this package.

Package contract

FieldValue
Languagepython
Source version0.1.0
Manifestforge-py/pyproject.toml
Source files5
EvidenceSource reference; registry publication and runtime conformance are separate checks

Import boundary

import forge.mcp

Use a source checkout or your verified private registry. Manifest coordinates identify the package; they do not establish that a public registry release exists.

Source reference

Download package reference JSON. Each original source file and generated declaration artifact has its own SHA-256 digest. Function bodies and constant values are omitted from downloads. These are source declaration inventories, not compiler-resolved rustdoc, TypeDoc, DocC, or Dokka output. Private modules can contain public declarations that are not reachable through the package boundary; consult the entry point before importing.

client.py

Read declaration text · 8 declaration entries

class McpClient()

def __init__(self, transport: Transport) -> None

async def initialize(self) -> dict[str, Any]

async def list_tools(self) -> list[McpTool]

async def call_tool(self, name: str, arguments: dict[str, Any]) -> Any

async def list_resources(self) -> list[McpResource]

async def read_resource(self, uri: str) -> Any

async def close(self) -> None

server.py

Read declaration text · 5 declaration entries

class McpServer()

def __init__(self, name: str, version: str) -> None

def add_tool(self, tool: McpTool, handler: Callable[..., Awaitable[Any]]) -> None

def add_resource(self, resource: McpResource, handler: Callable[..., Awaitable[Any]]) -> None

async def serve(self, transport: Transport) -> None

transport.py

Read declaration text · 9 declaration entries

class Transport(ABC)

async def send(self, message: dict[str, Any]) -> None

async def receive(self) -> dict[str, Any] | None

async def close(self) -> None

class StdioTransport(Transport)

def __init__(self) -> None

async def send(self, message: dict[str, Any]) -> None

async def receive(self) -> dict[str, Any] | None

async def close(self) -> None

types.py

Read declaration text · 2 declaration entries

class McpTool()

class McpResource()

Continue

On this page