# Broadcast a message using TTS (/en/api-reference/api-ref/conversational-ai/speak)

> For AI agents: see the complete documentation index at [llms.txt](/llms.txt).

Broadcasts a custom message through the TTS module.

- OpenAPI: /openapi/conversational-ai/rest-api.en.yaml
- Operation ID: agent-speak
- Method: POST
- Path: /v2/projects/{appid}/agents/{agentId}/speak

## Servers

- https://api.agora.io/api/conversational-ai-agent

## Parameters

- `appid` (path, required) - The App ID of the project.
- `agentId` (path, required) - The agent instance ID you obtained after successfully calling `join` to [Start a conversational AI agent](/en/api-reference/api-ref/conversational-ai/join).

## Request body

- `text` (string, required) - The broadcast message text. The maximum length of the text content is 512 bytes.
No schema.
- `priority` (string) - Sets the priority of the message broadcast.

- `INTERRUPT`: High priority. The agent immediately interrupts the current interaction to announce the message.
- `APPEND`: Medium priority. The agent announces the message after the current interaction ends.
- `IGNORE`: Low priority. If the agent is busy interacting, it ignores and discards the broadcast; the message is only announced if the agent is not interacting.
No schema.
- `interruptable` (boolean) - Whether to allow users to interrupt the agent's broadcast by speaking:
- `true`: Allow
- `false`: Don't allow
No schema.

## Responses

### 200

The request was successful. The response body contains the result of the request.

- `agent_id` (string) - Unique id of the agent instance.
No schema.
- `channel` (integer) - The name of the channel.
No schema.
- `start_ts` (integer) - Agent creation timestamp.
No schema.
### default

The request failed. The response body includes the error details.

- `detail` (string) - Detailed error information.
No schema.
- `reason` (string) - The reason for the failure.
No schema.
