Download the PHP package borsaco/telegram-bot-api-bundle without Composer
On this page you can find all versions of the php package borsaco/telegram-bot-api-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package telegram-bot-api-bundle
TelegramBotApiBundle
A symfony wrapper bundle for Telegram Bot API.
Install
Via Composer
Configure the bundle
This bundle was designed to just work out of the box. The only thing you have to configure in order to get this bundle up and running is your bot token.
Usage
You can access the bot in the controller with :
Webhook
In order to receive updates via a Webhook, You first need to tell your webhook URL to Telegram. You can use setWebhook method to specify a url and receive incoming updates via an outgoing webhook or use this commands:.
for get information about webhook of bot:
for set webhook url for the bot:
for delete webhook of the bot:
Once you set the webhook using the setWebhook method, You can then use the below function to retrieve the updates that are sent to your Webhook URL. The function returns an array of Update objects.
Maintenance
If want to use maintenance of bots you can check $bot->isMaintenance('bot_name')
in your entry point controller and send response message.
Next...
Please refer to Telegram Bot API Official Document for getting information about available methods and other informations.
Troubleshooting
If you did all the configurations correctly but still getting errors (Http error 500) even on getMe() method, it might be because of SSL Verification. Please make sure you have up-to-date CA root certificate bundle to be used with cURL.
You can configure you CA root certificate bundle by:
- Downloading up-to-date cacert.pem file from cURL website and
-
Setting a path to it in your php.ini file, e.g. on Windows:
curl.cainfo=c:\php\cacert.pem
You can test your SSL-setup online with this handy webtool on: SSL Labs
License
The BSD License. Please see License File for more information.
All versions of telegram-bot-api-bundle with dependencies
symfony/framework-bundle Version ^5.1 || ^6.0
irazasyed/telegram-bot-sdk Version ^3.4