DEF STUDIO srl

Telegraph Facade

In applications that have a single bot writing on a single chat, both will be automatically inferred:

Telegraph::message('hello world')->send();

this will allow a fluent tool for interacting with Telegram:

Telegraph::message('hello world')
    ->keyboard(Keyboard::make()->buttons([
        Button::make("🗑️ Delete")->action("delete")->param('id', $notification->id),  
        Button::make("📖 Mark as Read")->action("read")->param('id', $notification->id),  
        Button::make("👀 Open")->url('https://test.it'),  
    ])->chunk(2))->send();
Note

Telegraph supports also sending emojis in messages and keyboard button labels 🚀🚀🚀

Edit this page
Last updated 26 April 2024