Skip to content
/ Api Public
forked from TelegramBot/Api

Native PHP Wrapper for Telegram BOT API

License

Notifications You must be signed in to change notification settings

NikolayS/Api

 
 

Repository files navigation

PHP Telegram Bot Api

Latest Version on Packagist Software License Build Status Coverage Status Quality Score Total Downloads

An extended native php wrapper for Telegram Bot API without requirements. Supports all methods and types of responses.

Install

Via Composer

$ composer require telegram-bot/api

Usage

$bot = new \TelegramBot\Api\BotApi('YOUR_BOT_API_TOKEN');

$bot->sendMessage($chatId, $messageText);
$bot = new \TelegramBot\Api\BotApi('YOUR_BOT_API_TOKEN');

$document = new \CURLFile('document.txt');

$bot->sendDocument($chatId, $document);
$bot = new \TelegramBot\Api\BotApi('YOUR_BOT_API_TOKEN');

$keyboard = new \TelegramBot\Api\Types\ReplyKeyboardMarkup(array(array("one", "two", "three")), true); // true for one-time keyboard

$bot->sendMessage($chatId, $messageText, false, null, $keyboard);

Change log

Please see CHANGELOG for more information what has changed recently.

Testing

$ composer test

Contributing

Please see CONTRIBUTING for details.

Security

If you discover any security related issues, please email mail@igusev.ru instead of using the issue tracker.

Credits

License

The MIT License (MIT). Please see License File for more information.

About

Native PHP Wrapper for Telegram BOT API

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • PHP 100.0%