Skip to main content

Module transport

Module transport 

Source
Expand description

Streamable HTTP transport and server entry points.

Structs§

ClientIp
Resolved client IP of the current request.
McpServerConfig
Configuration for the MCP server.
PeerAddr
Direct socket peer address of the current HTTP/TLS connection.
ReloadHandle
Handle for hot-reloading server configuration without restart.
SecurityHeadersConfig
Per-header overrides for the OWASP security headers emitted by the global response middleware.
Validated
Marker that wraps a value proven to satisfy its validation contract.

Enums§

ForwardedHeaderMode
Which forwarding header trusted-forwarder mode reads.

Functions§

serve
Run the MCP HTTP server, binding to config.bind_addr and serving until an OS shutdown signal (Ctrl-C / SIGTERM) is received.
serve_stdio
Serve an MCP server over stdin/stdout (stdio transport).
serve_with_listener
Run the MCP HTTP server on a pre-bound TcpListener, with optional readiness signalling and external shutdown control.

Type Aliases§

ReadinessCheck
Async readiness check callback for the /readyz endpoint.