Get the FREE Ultimate OpenClaw Setup Guide →

atmosphere

Stream Real Time and LLM response data over WebSocket, SSE, and the MCP protocol

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio atmosphere-atmosphere java -jar atmosphere-mcp.jar \
  --env MCP_TLS="false" \
  --env MCP_HOST="localhost" \
  --env MCP_PORT="8080" \
  --env MCP_LOG_LEVEL="info"

How to use

Atmosphere includes an MCP server module that exposes a Model Context Protocol endpoint over WebSocket, allowing clients to connect and exchange commands and streaming data via MCP sessions. The MCP server is built on top of Atmosphere's transport-agnostic framework, so clients can connect using WebSocket or other transports (SSE, long-polling, gRPC) without changing the server logic. You can define MCP tools on the server side using annotated methods (e.g., @McpTool and @McpParam) and stream results back to connected MCP sessions. This enables real-time, streaming tool calls and responses to AI assistants or other agents that rely on MCP for interoperability.

How to install

Prerequisites:

  • Java 17+ and a JDK installation
  • Maven or Gradle for building from source (optional if using pre-built jars)
  • Git to clone the repository

Install and run from source:

  1. Clone the repository git clone https://github.com/Atmosphere/atmosphere.git cd atmosphere

  2. Build the MCP module (atmosphere-mcp) mvn -pl atmosphere-mcp -am clean package

  3. Run the MCP server (example) java -jar atmosphere-mcp/target/atmosphere-mcp.jar

  4. Verify the server is running by connecting a client to ws://localhost:8080 or the configured host/port

Notes:

  • If you prefer Docker, build a container image that runs the java -jar command and expose the MCP port.
  • You can adjust host/port with environment variables MCP_HOST and MCP_PORT as shown in the mcp_config example.

Additional notes

Tips and common considerations:

  • MCP sessions are transport-agnostic; ensure your client selects a compatible transport (WebSocket is the default).
  • Use MCP tool annotations (@McpTool, @McpParam) to expose server-side capabilities to AI agents or clients. Streaming tokens from long-running tools can be broadcast to topics or sessions in real time.
  • Configure logging (MCP_LOG_LEVEL) to troubleshoot connection issues or tool execution.
  • If running in a containerized environment, map the MCP port and ensure network policies allow WebSocket traffic.
  • For production, consider securing MCP with TLS and proper authentication/authorization on your MCP endpoints.

Related MCP Servers

Sponsor this space

Reach thousands of developers