Skip to main content
Glama

broadcast

Send messages to all Claude AI instances through Inter-Process Communication for coordinated workflows and information sharing.

Instructions

Broadcast a message to all other Claude instances

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
from_idYesYour instance ID
contentYesMessage content
dataNoOptional structured data

Implementation Reference

  • Core handler for broadcast action in the MessageBroker. Loops through all instance queues (except sender), appends the message to each, persists to database, and returns the count of recipients.
    elif action == "broadcast": from_id = request["from_id"] message = request["message"] count = 0 for instance_id in self.queues: if instance_id != from_id: msg_data = { "from": from_id, "to": instance_id, "timestamp": datetime.now().isoformat(), "message": message } self.queues[instance_id].append(msg_data) # Save to SQLite self._save_message_to_db(from_id, instance_id, msg_data) count += 1 return {"status": "ok", "message": f"Broadcast to {count} instances"}
  • MCP tool handler for 'broadcast'. Validates registration, constructs message, sends 'broadcast' action to the broker via BrokerClient, returns response.
    elif name == "broadcast": if not current_session_token: return [TextContent(type="text", text="Error: Not registered. Please register first.")] message = { "content": arguments["content"], "data": arguments.get("data", {}) } response = BrokerClient.send_request({ "action": "broadcast", "from_id": arguments["from_id"], "message": message, "session_token": current_session_token }) return [TextContent(type="text", text=json.dumps(response, indent=2))]
  • MCP tool registration for 'broadcast' including name, description, and input schema definition.
    name="broadcast", description="Broadcast a message to all other Claude instances", inputSchema={ "type": "object", "properties": { "from_id": { "type": "string", "description": "Your instance ID" }, "content": { "type": "string", "description": "Message content" }, "data": { "type": "object", "description": "Optional structured data" } }, "required": ["from_id", "content"] } ),
  • Input schema for the 'broadcast' tool defining parameters: from_id (required), content (required), data (optional).
    inputSchema={ "type": "object", "properties": { "from_id": { "type": "string", "description": "Your instance ID" }, "content": { "type": "string", "description": "Message content" }, "data": { "type": "object", "description": "Optional structured data" } }, "required": ["from_id", "content"] }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/jdez427/claude-ipc-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server