Skip to main content
WebSocket connector for MCP implementations. This module provides a connector for communicating with MCP implementations through WebSocket connections.

WebSocketConnector

method init

Initialize a new WebSocket connector.Parameters
str
required
The WebSocket URL to connect to.
dict[str, str] | None
default:"None"
Optional additional headers.
str | dict[str, typing.Any] | httpx.Auth | None
default:"None"
Authentication method - can be:
Signature

method request

Send a raw request to the MCP implementation.Parameters
str
required
String value
dict[str, typing.Any] | None
default:"None"
Dictionary of key-value pairs
Returns
Any
Signature