Telegram Bot API PHP SDK
Published on by Eric L. Barnes
Telegram recently launched a new API to allow developers to create their bots. Once created users can interact with bots by sending command messages in private or group chats. The official release of the bot API didn’t include an official Telegram PHP SDK, but Syed Irfaq R. created a PHP version that can be used standalone or within Laravel.
Looking at the Telegram documentation you can do a lot with their bot system including:
- Integrate with other services. A bot could potentially post comments remotely or control a smart home. It could also send you notifications via Telegram when something happens somewhere. * Create custom tools. A bot may provide you with alerts, weather forecasts, translations, or other services upon request. (Example: Poll bot).
- Build single- and multiplayer games. A bot can play chess and checkers against you, act as host in quiz games, or even take up the dungeon master’s dice for an RPG. (Example: Trivia bot).
- Build social services. A bot could connect people looking for conversation partners based on common interests or proximity. (Example: Tinder-like HotOrBot).
- Do virtually anything else. Except for dishes — bots are terrible at doing the dishes.
The system seems to be pretty advanced and you can find more about what all it can do in the Telegram docs.
Eric is the creator of Laravel News and has been covering Laravel since 2012.