joinChannel
The joinChannel
method allows the bot to join a specific IRC channel.
Syntax
Parameters
channel
(string, required) – The IRC channel the bot should join (e.g.,#channelname
).password
(string, optional) – Password to join a protected channel
Example Usage
While you can call joinChannel
directly, it is recommended to do so after receiving the connected
event to ensure the bot is properly connected before joining channels.
Notes
Ensure the channel name starts with
#
.The bot should be connected before attempting to join a channel.
If the channel is password-protected, you need to set your "password" parameter.
Last updated