> ## Documentation Index
> Fetch the complete documentation index at: https://praison.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# broadcast • Rust AI Agent SDK

> broadcast: Broadcast an event to all connected clients.

# broadcast

<div className="flex items-center gap-2">
  <Badge color="blue">Async</Badge>
  <Badge color="purple">Method</Badge>
</div>

> This is a method of the [**GatewayProtocol**](../classes/GatewayProtocol) class in the [**gateway**](../modules/gateway) module.

Broadcast an event to all connected clients.

## Signature

```python theme={"theme":{"light":"vitesse-light","dark":"vitesse-dark"}}
async def broadcast(&self, event: GatewayEvent, exclude: Option<Vec<String>>) -> Result<()>
```

## Parameters

<ParamField query="event" type="GatewayEvent" required={true}>
  No description available.
</ParamField>

<ParamField query="exclude" type="Option<Vec<String>>" required={true}>
  No description available.
</ParamField>

### Returns

<ResponseField name="Returns" type="Result<()>">
  The result of the operation.
</ResponseField>
