View the source code for this module on GitHub: https://github.com/mcp-use/mcp-use/blob/main/libraries/python/mcp_use/client/connectors/sandbox.py
SandboxConnector
method init
Initialize a new sandbox connector.ParametersSignatureString valueList of itemsEnvironment variables for the user’s MCP server command.Configuration options for the E2B sandbox environment.Timeout for the sandbox process in seconds.Timeout for the SSE connection in seconds.Optional sampling callback.Optional elicitation callback.Optional callback to handle messages.Optional callback to handle log messages.Optional list of middleware.Optional initial list of roots to advertise to the server.Optional custom callback to handle roots/list requests.
method wait_for_server_response
Wait for the server to respond to HTTP requests.ParametersReturnsThe base URL to check for server readinessMaximum time to wait in seconds
SignatureTrue if server is responding, raises TimeoutError otherwise