Skip to main content
Version: Next 🚧

Installation

Requirements​

  • PHP >=8.0
  • Telegram Bot Token - Talk to @BotFather and generate one.
  • Laravel >=9 (Optional)

Obtaining Telegram Bot Token​

  1. Open the Telegram app and message @BotFather.
  2. Follow the instructions to create a new bot.
  3. After creating the bot, the "BotFather" bot will give you a bot token. Keep this token safe, as you will need it to use the Telegram Bot API.
tip

Your bot token is its unique identifier – store it in a secure place, and avoid sharing with anyone or publishing your bot token anywhere. Everyone who has your token will have full control over your bot.

Installation​

Telegram Bot SDK utilizes Composer to manage its dependencies. So, before using the SDK, make sure you have Composer installed on your machine.

Install the Telegram Bot SDK using Composer:

composer require irazasyed/telegram-bot-sdk:^3.10

Laravel Setup​

Telegram Bot SDK will self-register its service provider and facade in Laravel.

Publish Configuration File​

Publish the configuration file by running this command in your terminal window:

php artisan vendor:publish --tag="telegram-config"