asyncio — no external dependencies, no SDK, no daemon. It works with public networks like Libera.Chat and any self-hosted ircd.
IRC is plain text: there is no voice, image, file, thread, reaction, typing, or streaming support — replies are sent as PRIVMSG lines, with long messages split to fit the IRC line limit.
Run mibyan gateway setup and pick IRC for a guided walk-through.
Prerequisites
- An IRC server to connect to (e.g.
irc.libera.chat) - A channel to join (e.g.
#mibyan) — comma-separate to join several - A nickname for the bot (default:
mibyan-bot) - Optional: a registered nick + NickServ password if your network requires identification
Configure Mibyan
You can configure IRC two ways — environment variables (for a quick env-only setup) or thegateway block in ~/.mibyan/config.yaml.
Option A — config.yaml
Option B — environment variables
Access control
By default, only nicks listed inallowed_users (or IRC_ALLOWED_USERS) may talk to the bot. Leave the list empty and set IRC_ALLOW_ALL_USERS=true to let anyone in the channel chat with Mibyan — useful for testing, but not recommended on public networks since IRC nicks are not authenticated unless the network enforces NickServ.
If your network registers nicks, set IRC_NICKSERV_PASSWORD (or nickserv_password) so the bot identifies to NickServ on connect and keeps its registered nick.
Channels vs. DMs
- Messages in a joined channel are treated as a group conversation.
- Private messages to the bot are treated as direct messages.
IRC_HOME_CHANNEL if set, otherwise the first IRC_CHANNEL.
Run the gateway
mibyan gateway status — IRC connection state is reported there, including for env-only setups.
Notes
- Long agent replies are automatically split into multiple
PRIVMSGlines to stay within the IRC line limit (max_message_length, default 450 bytes after protocol overhead). - The adapter acquires a scoped credential lock per server+nick, so two Mibyan profiles won’t fight over the same IRC identity.

