Telegram Bot Setup¶
To use PoracleNG with Telegram, you need to create a bot through BotFather.
Step 1: Create a Bot with BotFather¶
- Open Telegram and search for @BotFather
- Send
/newbot - Follow the prompts to choose a name and username for your bot
- BotFather will give you an API token — save this
Keep Your Token Secret
Never share your bot token publicly.
Step 2: Configure Bot Settings¶
Send these commands to BotFather to configure your bot:
/setprivacy— select your bot, then choose Disable- This allows the bot to read messages in groups (required for group commands)
/setjoingroups— select your bot, then choose Enable- Allows the bot to be added to groups
/setcommands— select your bot, then send the command list (optional, for autocomplete)
Step 3: Get Your IDs¶
You'll need your Telegram user ID and group IDs:
- Your User ID — send
/startto @userinfobot or use the/identifycommand after Poracle is running - Group ID — add the bot to your registration group, then use the
/identifycommand
Tip
Group IDs typically start with -100. If your group ID doesn't start with -100, it may not be a supergroup yet. Convert it to a supergroup by enabling any group admin setting.
Step 4: Configure PoracleNG¶
Add the bot token and IDs to your config/config.toml:
[telegram]
enabled = true
token = "your-bot-token-here"
admins = ["your-user-id"]
channels = ["your-registration-group-id"]
Step 5: Start the Bot¶
After starting PoracleNG, open a chat with your bot in Telegram and send /start to begin interacting with it.
Users register by sending /poracle in the registration group, then messaging the bot directly to configure tracking.
For more Telegram configuration options, see Telegram Configuration.