feat(discord): add Discord channel support

- Implement Discord channel functionality with websocket integration.
- Update configuration schema to include Discord settings.
- Enhance README with setup instructions for Discord integration.
- Modify channel manager to initialize Discord channel if enabled.
- Update CLI status command to display Discord channel status.
This commit is contained in:
Anunay Aatipamula
2026-02-02 18:41:17 +05:30
parent 1865ecda8f
commit ba6c4b748f
5 changed files with 334 additions and 1 deletions

View File

@@ -19,10 +19,20 @@ class TelegramConfig(BaseModel):
allow_from: list[str] = Field(default_factory=list) # Allowed user IDs or usernames
class DiscordConfig(BaseModel):
"""Discord channel configuration."""
enabled: bool = False
token: str = "" # Bot token from Discord Developer Portal
allow_from: list[str] = Field(default_factory=list) # Allowed user IDs
gateway_url: str = "wss://gateway.discord.gg/?v=10&encoding=json"
intents: int = 37377 # GUILDS + GUILD_MESSAGES + DIRECT_MESSAGES + MESSAGE_CONTENT
class ChannelsConfig(BaseModel):
"""Configuration for chat channels."""
whatsapp: WhatsAppConfig = Field(default_factory=WhatsAppConfig)
telegram: TelegramConfig = Field(default_factory=TelegramConfig)
discord: DiscordConfig = Field(default_factory=DiscordConfig)
class AgentDefaults(BaseModel):