PHPackages                             yooznet/chatgenius - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [API Development](/categories/api)
4. /
5. yooznet/chatgenius

ActiveLibrary[API Development](/categories/api)

yooznet/chatgenius
==================

A PHP library for interacting with the Telegram API.

1.0.0(1y ago)19MITPHP

Since Sep 3Pushed 1y ago1 watchersCompare

[ Source](https://github.com/YoozNet/ChatGenius)[ Packagist](https://packagist.org/packages/yooznet/chatgenius)[ Docs](https://github.com/YoozNet/chatgenius)[ RSS](/packages/yooznet-chatgenius/feed)WikiDiscussions main Synced 2d ago

READMEChangelog (1)Dependencies (1)Versions (2)Used By (0)

ChatGenius
==========

[](#chatgenius)

ChatGenius is a PHP package for interacting with the Telegram API. This README provides instructions for installing, configuring, and using the package to send messages, reply to users, and create custom keyboards.

Installation
------------

[](#installation)

To install the package, use Composer:

```
composer require yooznet/chatgenius:^1.0.0
```

Setup
=====

[](#setup)

First, include the necessary classes in your project:

```
use ChatGenius\TelegramAction;
use App\Classes\user\Handler;
```

Create a new instance of TelegramAction with your bot token:

```
$telegram = new TelegramAction('Your_Token_Here');
$update = new HandleUpdate();
```

Sending Messages
================

[](#sending-messages)

To send a message, use the following code:

```
$telegram->ChatID($update->chat_id)
         ->Text('Welcome to our world!')
         ->sendMessage();
```

Replying to User Messages
=========================

[](#replying-to-user-messages)

To reply to a user's message, first check if there is a message\_id, and then use the Reply class:

```
use ChatGenius\Reply;

$reply = $update->message_id ? new Reply(message_id: $update->message_id) : null;

$telegram->ChatID($update->chat_id)
         ->Reply($reply)
         ->Text('Welcome to our world!')
         ->sendMessage();
```

Creating Buttons
================

[](#creating-buttons)

Inline Keyboard
---------------

[](#inline-keyboard)

To create an inline keyboard with buttons:

```
use ChatGenius\Keyboard;

$keyboard = new Keyboard(
    type: 'InlineKeyboardMarkup',
    inlineKeyboard: [
        [
            ['text' => 'test', 'callback_data' => 'test'],
            ['text' => 'test2', 'callback_data' => 'test2'],
        ],
    ]
);
```

Reply Keyboard
--------------

[](#reply-keyboard)

To create a regular reply keyboard:

```
$keyboard = new Keyboard(
    type: 'ReplyKeyboardMarkup',
    keyboard: [
        ['test']
    ],
    resizeKeyboard: true,
    oneTimeKeyboard: true
);
```

Removing Keyboard
-----------------

[](#removing-keyboard)

To remove the keyboard:

```
$keyboard = new Keyboard(
    type: 'ReplyKeyboardRemove',
    removeKeyboard: true
);
```

Sending Messages with Keyboard
------------------------------

[](#sending-messages-with-keyboard)

To send a message with a custom keyboard:

```
$telegram->ChatID($update->chat_id)
         ->Text('Welcome to our world!')
         ->ReplyMarkup($keyboard)
         ->sendMessage();
```

Contributing Feel free to contribute to this project by submitting issues or pull requests.

License This project is licensed under the MIT License. See the [LICENSE](LICENSE) file for more details.

Contact For any questions or feedback, please reach out to .

###  Health Score

23

—

LowBetter than 26% of packages

Maintenance33

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity40

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 60% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

669d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/139054563?v=4)[Saeed Shanaqi](/maintainers/shanaqisaeed)[@shanaqisaeed](https://github.com/shanaqisaeed)

---

Top Contributors

[![Golden-Source](https://avatars.githubusercontent.com/u/50501111?v=4)](https://github.com/Golden-Source "Golden-Source (6 commits)")[![YoozNet](https://avatars.githubusercontent.com/u/161053540?v=4)](https://github.com/YoozNet "YoozNet (4 commits)")

---

Tags

phpapilibrarytelegram

### Embed Badge

![Health badge](/badges/yooznet-chatgenius/health.svg)

```
[![Health](https://phpackages.com/badges/yooznet-chatgenius/health.svg)](https://phpackages.com/packages/yooznet-chatgenius)
```

###  Alternatives

[checkout/checkout-sdk-php

Checkout.com SDK for PHP

563.6M13](/packages/checkout-checkout-sdk-php)[tencentcloud/tencentcloud-sdk-php

TencentCloudApi php sdk

3741.3M46](/packages/tencentcloud-tencentcloud-sdk-php)[theodo-group/llphant

LLPhant is a library to help you build Generative AI applications.

1.7k409.0k6](/packages/theodo-group-llphant)[resend/resend-php

Resend PHP library.

617.2M43](/packages/resend-resend-php)[eslazarev/wildberries-sdk

Wildberries OpenAPI clients (generated).

273.0k](/packages/eslazarev-wildberries-sdk)[files.com/files-php-sdk

Files.com PHP SDK

2481.1k](/packages/filescom-files-php-sdk)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
