> ## 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.

# Bot Config • AI Agent SDK

> BotConfig: Configuration for messaging bots.

# BotConfig

> Defined in the [**config**](https://praison.ai/docs/sdk/reference/praisonaiagents/modules/config.md) module.

AI Agent

Configuration for messaging bots.

Attributes:
token: Bot authentication token
webhook\_url: URL for webhook mode (optional)
webhook\_path: Path for webhook endpoint
polling\_interval: Interval for polling mode (seconds)
allowed\_users: List of explicitly-allowed user IDs. When empty,
inbound access is not automatically granted — it defers to
`unknown_user_policy` (default `deny`). To open the bot to
everyone, set `unknown_user_policy="allow"`.
allowed\_channels: List of allowed channel IDs (empty = all allowed)
command\_prefix: Prefix for commands (default: "/")
mention\_required: Whether bot mention is required in groups
typing\_indicator: Whether to show typing indicator
max\_message\_length: Maximum message length before splitting
retry\_attempts: Number of retry attempts for failed operations
timeout: Request timeout in seconds
metadata: Additional platform-specific configuration

## Properties

**token** `str`

No description available.

**mode** `str`

No description available.

**webhook\_url** `Optional[str]`

No description available.

**webhook\_path** `str`

No description available.

**webhook\_port** `int`

No description available.

**polling\_interval** `float`

No description available.

**allowed\_users** `List[str]`

No description available.

**allowed\_channels** `List[str]`

No description available.

**command\_prefix** `str`

No description available.

**mention\_required** `bool`

No description available.

**typing\_indicator** `bool`

No description available.

**max\_message\_length** `int`

No description available.

**retry\_attempts** `int`

No description available.

**timeout** `int`

No description available.

**reply\_in\_thread** `bool`

No description available.

**thread\_threshold** `int`

No description available.

**group\_policy** `str`

No description available.

**default\_tools** `List[str]`

No description available.

**auto\_approve\_tools** `bool`

No description available.

**debounce\_ms** `int`

No description available.

**ack\_emoji** `str`

No description available.

**done\_emoji** `str`

No description available.

**ack\_scope** `str`

No description available.

**session\_ttl** `int`

No description available.

**busy\_mode** `str`

No description available.

**busy\_ack** `str`

No description available.

**workspace\_dir** `Optional[str]`

No description available.

**workspace\_access** `str`

No description available.

**workspace\_scope** `str`

No description available.

**unknown\_user\_policy** `UnknownUserPolicy`

No description available.

**owner\_user\_id** `Optional[str]`

No description available.

**streaming** `bool`

No description available.

**stream\_edit\_interval\_ms** `int`

No description available.

**footer** `bool`

No description available.

**allow\_silence** `bool`

No description available.

**silence\_token** `Optional[str]`

No description available.

**allow\_bots** `bool`

No description available.

**bot\_loop\_protection** `Optional`

No description available.

**metadata** `Dict[str, Any]`

No description available.

## Methods

> [card] [is\_webhook\_mode()](https://praison.ai/docs/sdk/reference/praisonaiagents/functions/BotConfig-is_webhook_mode.md)
>
> Whether bot is configured for webhook mode.

> [card] [is\_ws\_mode()](https://praison.ai/docs/sdk/reference/praisonaiagents/functions/BotConfig-is_ws_mode.md)
>
> Whether bot is configured for WebSocket mode.

> [card] [is\_hybrid\_mode()](https://praison.ai/docs/sdk/reference/praisonaiagents/functions/BotConfig-is_hybrid_mode.md)
>
> Whether bot is configured for hybrid mode (WS + slow poll).

> [card] [is\_user\_allowed()](https://praison.ai/docs/sdk/reference/praisonaiagents/functions/BotConfig-is_user_allowed.md)
>
> Check if a user is allowed to interact with the bot.

> [card] [is\_explicitly\_allowed()](https://praison.ai/docs/sdk/reference/praisonaiagents/functions/BotConfig-is_explicitly_allowed.md)
>
> Whether a user is explicitly allow-listed.

> [card] [is\_channel\_allowed()](https://praison.ai/docs/sdk/reference/praisonaiagents/functions/BotConfig-is_channel_allowed.md)
>
> Check if a channel is allowed for bot interaction.

> [accordion] Internal & Generic Methods
>
> * **to\_dict**: Convert to dictionary (hides sensitive data).

## Source

> [card] [View on GitHub](https://github.com/MervinPraison/PraisonAI/blob/main/src/praisonai-agents/praisonaiagents/bots/config.py#L14)
>
> `praisonaiagents/bots/config.py` at line 14

***

## Related Documentation

> [card] [Configuration Overview](https://praison.ai/docs/docs/configuration/index)

> [card] [Agent Config](https://praison.ai/docs/docs/configuration/agent-config)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.