Repository: green-api/whatsapp-api-client-python (language: python)

Issue:
Установка пакета происходит некорректно
![image](https://user-images.githubusercontent.com/105914205/203922887-573a5379-0d73-4101-a448-1ab93b034f74.png)
Установил пакет с помощью команды pip install whatsapp-api-client-python. После установки заметил, что отсутствуют некоторые пакеты. 


Discussion / hints:
Опубликовал 0.0.27, в которой откатил все до 0.0.23. Рекомендую разобраться почему собранная либа не работает на 0.0.26
> Опубликовал 0.0.27, в которой откатил все до 0.0.23. Рекомендую разобраться почему собранная либа не работает на 0.0.26

![image](https://user-images.githubusercontent.com/105914205/203965047-01963738-c9b0-4486-b714-5e9c4856e6d4.png)
Она не работает и на 0.0.23. 
@Amele9 Возможно остались старые зависимости. Попробуйте с нуля проект сделать используя виртуальное окружение. КОгда я делаю с нуля, то на версии 0.0.27 (она же 0.0.23) работает

![image](https://user-images.githubusercontent.com/25801912/204248071-5e7dda91-01de-4b09-9497-db59f33f439b.png)

Когда я делаю на 0.0.26 с нуля проект, то он не работает

![image](https://user-images.githubusercontent.com/25801912/204249409-a54bd721-6350-404e-a4d6-9cd273063c5d.png)


Я к сожалению не сильный спец по питону и поэтому не могу чем-нибудь помочь конкретным, кроме того как протестировать. Возможно делоо в используемой IDE. Я использую блокнот, который не добавляет ничего от себя кроме как venv
> @Amele9 Возможно остались старые зависимости. Попробуйте с нуля проект сделать используя виртуальное окружение. КОгда я делаю с нуля, то на версии 0.0.27 (она же 0.0.23) работает
> 
> ![image](https://user-images.githubusercontent.com/25801912/204248071-5e7dda91-01de-4b09-9497-db59f33f439b.png)
> 
> Когда я делаю на 0.0.26 с нуля проект, то он не работает
> 
> ![image](https://user-images.githubusercontent.com/25801912/204249409-a54bd721-6350-404e-a4d6-9cd273063c5d.png)
> 
> Я к сожалению не сильный спец по питону и поэтому не могу чем-нибудь помочь конкретным, кроме того как протестировать. Возможно делоо в используемой IDE. Я использую блокнот, который не добавляет ничего от себя кроме как venv

А можете показать внутренности whatsapp-api-client-python? Я установил whatsapp-api-client-python версии 0.0.26 внутри venv. Отсутствуют некоторые директории, которые были добавлены в версии 0.0.26.

Пакет не работает, потому что у вас отсутствуют некоторые директории. Я не знаю у кого ошибка, но при выполнении команды pip install whatsapp-api-client-python==0.0.26 пакет был установлен не полностью. 

Так выглядит пакет, если устанавливать через pip
![image](https://user-images.githubusercontent.com/105914205/204722722-e83ef696-cd30-4c19-ac02-dc011018e408.png)

Примерно так должен выглядеть пакет.
![image](https://user-images.githubusercontent.com/105914205/204723770-4ac94d7b-20f6-492b-aec1-5065a7cd67a9.png)


@Amele9 Можно самостоятельно проверить как выглядит скомпилированная либа, скачанного в пакетном менеджере pip install -Iv whatsapp-api-client-python==0.0.26

![image](https://user-images.githubusercontent.com/25801912/204727978-404c4dd7-2b89-4bf6-8a1e-f2ecd4b6d2ea.png)

Нужно добавить в пулл-реквест необходимые изменения в файл setup.py в части модуля


Fix patch:
diff --git a/.github/workflows/python-publish.yml b/.github/workflows/python-publish.yml
index ec70354..0614eb5 100644
--- a/.github/workflows/python-publish.yml
+++ b/.github/workflows/python-publish.yml
@@ -11,6 +11,8 @@ name: Upload Python Package
 on:
   release:
     types: [published]
+  # Allows you to run this workflow manually from the Actions tab
+  workflow_dispatch:
 
 permissions:
   contents: read
diff --git a/README.md b/README.md
index 841ba30..9270077 100644
--- a/README.md
+++ b/README.md
@@ -3,174 +3,191 @@
 [![Python application](https://github.com/green-api/whatsapp-api-client-python/actions/workflows/python-app.yml/badge.svg)](https://github.com/green-api/whatsapp-api-client-python/actions/workflows/python-app.yml)
 [![Upload Python Package](https://github.com/green-api/whatsapp-api-client-python/actions/workflows/python-publish.yml/badge.svg)](https://github.com/green-api/whatsapp-api-client-python/actions/workflows/python-publish.yml)
 
-
 - [Документация на русском языке](README_RUS.md)
 
-Python library for intagration with WhatsAPP messanger via API of [green-api.com](https://green-api.com) service. To use the library you have to get a registration token and an account id in the [personal area](https://console.green-api.com). There is a free developer account tariff plan.
+Python library for intagration with WhatsAPP messanger via API of [green-api.com](https://green-api.com) service. To use
+the library you have to get a registration token and an account id in the [personal area](https://console.green-api.com)
+. There is a free developer account tariff plan.
 
 ## API
 
-You can find REST API documentation by [url](https://green-api.com/docs/api/). The library is a wrapper for REST API, so the documentation at the above url applies to the library as well.
+You can find REST API documentation by [url](https://green-api.com/docs/api/). The library is a wrapper for REST API, so
+the documentation at the above url applies to the library as well.
 
 ## Installation
 
-```
+```shell
 pip install whatsapp-api-client-python
 ```
 
-## Import 
-
-```
-from whatsapp_api_client_python import API
-```
 ## Authorization
 
-To send a message or to exacute some other Green-API method, you have to have the WhatsApp account in the phone application to be authorized. To authorize your account please go to the [personal area](https://console.green-api.com) and scan a QR-code using the WhatsApp application.
+To send a message or to exacute some other Green-API method, you have to have the WhatsApp account in the phone
+application to be authorized. To authorize your account please go to the [personal area](https://console.green-api.com)
+and scan a QR-code using the WhatsApp application.
 
 ## Examples
 
 ### How to initialize an object
 
-```
-greenAPI = API.GreenApi(ID_INSTANCE, API_TOKEN_INSTANCE)
+```python
+from whatsapp_api_client_python import GreenAPI
+
+greenAPI = GreenAPI(ID_INSTANCE, API_TOKEN_INSTANCE)
 ```
 
 ### Sending a text message to a WhatsApp number
 
-```
-result = greenAPI.sending.sendMessage('79001234567@g.us', 'Message text')
+```python
+response = greenAPI.sending.send_message(
+    chatId="79001234567@c.us",
+    message="Any message"
+)
 ```
 
-Example url: [sendTextMessage.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/sendTextMessage.py)
+Example
+url: [send_message.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/send_message.py)
 
 Please note that keys can be obtained from environment variables:
-```
+
+```python
 from os import environ
 
-ID_INSTANCE = environ['ID_INSTANCE']
-API_TOKEN_INSTANCE = environ['API_TOKEN_INSTANCE']
+ID_INSTANCE = environ["ID_INSTANCE"]
+API_TOKEN_INSTANCE = environ["API_TOKEN_INSTANCE"]
 ```
 
 ### Sending an image via URL
 
-```
-result = greenAPI.sending.sendFileByUrl('120363025955348359@g.us', 
-        'https://www.google.ru/images/branding/googlelogo/1x/googlelogo_color_272x92dp.png', 
-        'googlelogo_color_272x92dp.png', 'Google logo')
+```python
+response = greenAPI.sending.send_file_by_url(
+    chatId="79001234567@c.us",
+    urlFile="https://www.google.com/images/branding/googlelogo/2x/googlelogo_color_272x92dp.png",
+    fileName="googlelogo_color_272x92dp.png"
+)
 ```
 
-Example url: [sendPictureByLink.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/sendPictureByLink.py)
+Example
+url: [send_file_by_url.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/send_file_by_url.py)
 
 ### Sending an image by uploading from the disk
 
-```
-result = greenAPI.sending.sendFileByUpload('120363025955348359@g.us', 
-        'C:\Games\PicFromDisk.png', 
-        'PicFromDisk.png', 'Picture from disk')
+```python
+response = greenAPI.sending.send_file_by_upload(
+    chatId="79001234567@c.us",
+    path="C:\\Games\\PicFromDisk.png"
+)
 ```
 
-Example url: [sendPictureByUpload.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/sendPictureByUpload.py)
+Example
+url: [send_file_by_upload.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/send_file_by_upload.py)
 
 ### Group creation and sending a message to the group
 
-```
-chatIds = [
-    "79001234567@c.us"
-]
-resultCreate = greenAPI.groups.createGroup('GroupName', 
-    chatIds)
-
-if resultCreate.code == 200:
-    resultSend = greenAPI.sending.sendMessage(resultCreate.data['chatId'], 
-        'Message text')
+```python
+create_group_response = greenAPI.groups.create_group(
+    groupName="Group Name",
+    chatIds=["79001234567@c.us"]
+)
+
+chatId = create_group_response.data["chatId"]
+send_message_response = greenAPI.sending.send_message(
+    chatId=chatId,
+    message="Any message"
+)
 ```
 
-IMPORTANT: If one tries to create a group with a non-existent number, WhatsApp 
+IMPORTANT: If one tries to create a group with a non-existent number, WhatsApp
 may block the sender's number. The number in the example is non-existent.
 
-Example url: [createGroupAndSendMessage.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/createGroupAndSendMessage.py)
+Example
+url: [create_group_and_send_message.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/create_group_and_send_message.py)
 
 ### Receive incoming messages by HTTP API
 
 The general concept of receiving data in the Green API is described [here](https://green-api.com/en/docs/api/receiving/)
 To start receiving messages by the HTTP API you need to execute the library method:
 
-```
-greenAPI.webhooks.startReceivingNotifications(onEvent)
+```python
+from whatsapp_api_client_python.tools import Webhook
+
+webhook = Webhook(greenAPI)
+
+webhook.run_forever(handler)
 ```
 
-onEvent - your method which should contain parameters:
+handler - your function which should contain parameters:
 Parameter | Description
 ----- | -----
-typewebhook | received message type (string)
-body | message body (json)
+type_webhook | Received message type (string)
+body | message body (dict or list)
 
 Message body types and formats [here](https://green-api.com/en/docs/api/receiving/notifications-format/)
 
-This method will be called when an incoming message is received. Next, process messages according to the business logic of your system.
+This method will be called when an incoming message is received. Next, process messages according to the business logic
+of your system. Pass the handler to the run_forever function without brackets.
 
 ## Examples list
 
-Description |  Module
------ | ----- 
-Example of sending text | [sendTextMessage.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/sendTextMessage.py)
-Example of sending a picture by URL | [sendPictureByLink.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/sendPictureByLink.py)
-Example of sending a picture by uploading from the disk | [sendPictureByUpload.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/sendPictureByUpload.py)
-Example of a group creation and sending a message to the group | [createGroupAndSendMessage.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/createGroupAndSendMessage.py)
-Example of incoming webhooks receiving | [receiveNotification.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/receiveNotification.py)
-
+| Description                                                    | Module                                                                                                                                            |
+|----------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------|
+| Example of sending text                                        | [send_message.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/send_message.py)                                   |
+| Example of sending a picture by URL                            | [send_file_by_url.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/send_file_by_url.py)                           |
+| Example of sending a picture by uploading from the disk        | [send_file_by_upload.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/send_file_by_upload.py)                     |
+| Example of a group creation and sending a message to the group | [create_group_and_send_message.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/create_group_and_send_message.py) |
+| Example of incoming webhooks receiving                         | [webhook_example.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/webhook_example.py)                             |
 
 ## The full list of the library methods
 
-Method | Description |  Documentation
------ | ----- | ----- 
-`account.getSettings` | The method is aimed for getting the current settings of the account | [GetSettings.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/GetSettings.md)
-`account.getStateInstance` | The method is aimed for getting the account state | [GetStateInstance.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/GetStateInstance.md)
-`account.getStatusInstance` | The method is aimed for getting the status of the account instance socket connection with WhatsApp | [GetStatusInstance.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/GetStatusInstance.md)
-`account.logout` | The method is aimed for logging out an account | [Logout.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/Logout.md)
-`account.qr` | The method is aimed for getting QR code | [QR.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/QR.md)
-`account.reboot` | The method is aimed for rebooting an account | [Reboot.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/Reboot.md)
-`account.setProfilePicture` | The method is aimed for setting an account picture | [SetProfilePicture.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/SetProfilePicture.md)
-`account.setSettings` | The method is aimed for setting an account settings | [SetSettings.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/SetSettings.md)
-`account.setSystemProxy` | The method is aimed for setting a system proxy. Use the method when you need to reset custom proxy settings to system ones | [SetSystemProxy.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/SetSystemProxy.md)
-`groups.addGroupParticipant` | Метод добавляет участника в групповой чат | [AddGroupParticipant.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/AddGroupParticipant.md)
-`groups.createGroup` | The method adds a participant to a group chat. IMPORTANT: If one tries to create a group with a non-existent number, WhatsApp may block the sender's number. | [CreateGroup.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/CreateGroup.md)
-`groups.getGroupData` | The method gets group chat data | [GetGroupData.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/GetGroupData.md)
-`groups.leaveGroup` | The method makes the current account user leave the group chat | [LeaveGroup.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/LeaveGroup.md)
-`groups.removeAdmin` | he method removes a participant from group chat administartion rights | [RemoveAdmin.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/RemoveAdmin.md)
-`groups.removeGroupParticipant` | The method removes a participant from a group chat | [RemoveGroupParticipant.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/RemoveGroupParticipant.md)
-`groups.setGroupAdmin` | The method sets a group chat participant as an administrator | [SetGroupAdmin.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/SetGroupAdmin.md)
-`groups.setGroupPicture` | The method sets a group picture | [SetGroupPicture.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/SetGroupPicture.md)
-`groups.updateGroupName` | The method changes a group chat name | [UpdateGroupName.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/UpdateGroupName.md)
-`journals.getChatHistory` | The method returns the chat message history | [GetChatHistory.md](https://github.com/green-api/docs/blob/master/ru/docs/api/journals/GetChatHistory.md)
-`journals.lastIncomingMessages` | The method returns the last incoming messages of the account. In the default mode the incoming messages for 24 hours are returned | [GetChatHistory.md](https://github.com/green-api/docs/blob/master/ru/docs/api/journals/LastIncomingMessages.md)
-`journals.lastOutgoingMessages` | The method returns the last outgoing messages of the account. In the default mode the last messages for 24 hours are returned | [LastOutgoingMessages.md](https://github.com/green-api/docs/blob/master/ru/docs/api/journals/LastOutgoingMessages.md)
-`marking.readChat` | The method is aimed for marking messages in a chat as read. Either all messages or a specified message in a chat can be marked as read | [ReadChat.md](https://github.com/green-api/docs/blob/master/ru/docs/api/marks/ReadChat.md)
-`device.getDeviceInfo` | The method is aimed for getting information about the device (phone) running WhatsApp Business application | [GetDeviceInfo.md](https://github.com/green-api/docs/blob/master/ru/docs/api/phone/GetDeviceInfo.md)
-`queues.clearMessagesQueue` | The method is aimed for clearing the queue of messages to be sent | [ClearMessagesQueue.md](https://github.com/green-api/docs/blob/master/ru/docs/api/queues/ClearMessagesQueue.md)
-`queues.showMessagesQueue` | The method is aimed for getting a list of messages in the queue to be sent | [ShowMessagesQueue.md](https://github.com/green-api/docs/blob/master/ru/docs/api/queues/ShowMessagesQueue.md)
-`receiving.deleteNotification` | The method is aimed for deleting an incoming notification from the notification queue | [DeleteNotification.md](https://github.com/green-api/docs/blob/master/ru/docs/api/receiving/technology-http-api/DeleteNotification.md)
-`receiving.receiveNotification` | The method is aimed for receiving one incoming notification from the notifications queue | [ReceiveNotification.md](https://github.com/green-api/docs/blob/master/ru/docs/api/receiving/technology-http-api/ReceiveNotification.md)
-`sending.sendButtons` | The method is aimed for sending a button message to a personal or a group chat | [SendButtons.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendButtons.md)
-`sending.sendContact` | The method is aimed for sending a contact message | [SendContact.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendContact.md)
-`sending.sendFileByUpload` | The method is aimed for sending a file uploaded by form | [SendFileByUpload.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendFileByUpload.md)
-`sending.sendFileByUrl` | The method is aimed for sending a file uploaded by Url | [SendFileByUrl.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendFileByUrl.md)
-`sending.sendLink` | The method is aimed for sending a message with a link, by which an image preview, title and description will be added | [SendLink.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendLink.md)
-`sending.sendListMessage` | The method is aimed for sending a message with a select button from a list of values to a personal or a group chat | [SendListMessage.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendListMessage.md)
-`sending.sendLocation` | The method is aimed for sending a location message | [SendLocation.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendLocation.md)
-`sending.sendMessage` | The method is aimed for sending a text message to a personal or a group chat | [SendMessage.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendMessage.md)
-`sending.sendTemplateButtons` | The method is aimed for sending a message with template list interacrive buttons to a personal or a group chat | [SendTemplateButtons.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendTemplateButtons.md)
-`serviceMethods.checkWhatsapp` | The method checks WhatsApp account availability on a phone number | [CheckWhatsapp.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/CheckWhatsapp.md)
-`serviceMethods.getAvatar` | The method returns a user or a group chat avatar | [GetAvatar.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/GetAvatar.md)
-`serviceMethods.getContactInfo` | The method is aimed for getting information on a contact | [GetContactInfo.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/GetContactInfo.md)
-`serviceMethods.getContacts` | The method is aimed for getting a list of the current account contacts | [GetContacts.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/GetContacts.md)
-`serviceMethods.setDisappearingChat` | The method is aimed for changing settings of disappearing messages in chats. The standard settings of the application are to be used: 0 (off), 86400 (24 hours), 604800 (7 days), 7776000 (90 days) | [SetDisappearingChat.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/SetDisappearingChat.md)
-`serviceMethods.archiveChat` | The method archives a chat. One can archive chats that have at least one incoming message | [ArchiveChat.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/ArchiveChat.md)
-`serviceMethods.deleteMessage` | The method deletes a message from a chat | [DeleteMessage.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/deleteMessage.md)
-`serviceMethods.unarchiveChat` | The method unarchives a chat | [UnarchiveChat.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/UnarchiveChat.md)
-`serviceMethods.setDisappearingChat` | The method is aimed for changing settings of disappearing messages in chats | [SetDisappearingChat.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/SetDisappearingChat.md)
-`webhooks.startReceivingNotifications` | The method is aimed for starting to receive webhooks | <library method>
-`webhooks.stopReceivingNotifications` | The method is aimed for stopping to receive webhooks | <library method>
+| Method                                 | Description                                                                                                                                                                                         | Documentation                                                                                                                            |
+|----------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------|
+| `account.getSettings`                  | The method is aimed for getting the current settings of the account                                                                                                                                 | [GetSettings.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/GetSettings.md)                                       |
+| `account.getStateInstance`             | The method is aimed for getting the account state                                                                                                                                                   | [GetStateInstance.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/GetStateInstance.md)                             |
+| `account.getStatusInstance`            | The method is aimed for getting the status of the account instance socket connection with WhatsApp                                                                                                  | [GetStatusInstance.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/GetStatusInstance.md)                           |
+| `account.logout`                       | The method is aimed for logging out an account                                                                                                                                                      | [Logout.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/Logout.md)                                                 |
+| `account.qr`                           | The method is aimed for getting QR code                                                                                                                                                             | [QR.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/QR.md)                                                         |
+| `account.reboot`                       | The method is aimed for rebooting an account                                                                                                                                                        | [Reboot.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/Reboot.md)                                                 |
+| `account.setProfilePicture`            | The method is aimed for setting an account picture                                                                                                                                                  | [SetProfilePicture.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/SetProfilePicture.md)                           |
+| `account.setSettings`                  | The method is aimed for setting an account settings                                                                                                                                                 | [SetSettings.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/SetSettings.md)                                       |
+| `account.setSystemProxy`               | The method is aimed for setting a system proxy. Use the method when you need to reset custom proxy settings to system ones                                                                          | [SetSystemProxy.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/SetSystemProxy.md)                                 |
+| `groups.addGroupParticipant`           | Метод добавляет участника в групповой чат                                                                                                                                                           | [AddGroupParticipant.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/AddGroupParticipant.md)                        |
+| `groups.createGroup`                   | The method adds a participant to a group chat. IMPORTANT: If one tries to create a group with a non-existent number, WhatsApp may block the sender's number.                                        | [CreateGroup.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/CreateGroup.md)                                        |
+| `groups.getGroupData`                  | The method gets group chat data                                                                                                                                                                     | [GetGroupData.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/GetGroupData.md)                                     |
+| `groups.leaveGroup`                    | The method makes the current account user leave the group chat                                                                                                                                      | [LeaveGroup.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/LeaveGroup.md)                                          |
+| `groups.removeAdmin`                   | he method removes a participant from group chat administartion rights                                                                                                                               | [RemoveAdmin.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/RemoveAdmin.md)                                        |
+| `groups.removeGroupParticipant`        | The method removes a participant from a group chat                                                                                                                                                  | [RemoveGroupParticipant.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/RemoveGroupParticipant.md)                  |
+| `groups.setGroupAdmin`                 | The method sets a group chat participant as an administrator                                                                                                                                        | [SetGroupAdmin.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/SetGroupAdmin.md)                                    |
+| `groups.setGroupPicture`               | The method sets a group picture                                                                                                                                                                     | [SetGroupPicture.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/SetGroupPicture.md)                                |
+| `groups.updateGroupName`               | The method changes a group chat name                                                                                                                                                                | [UpdateGroupName.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/UpdateGroupName.md)                                |
+| `journals.getChatHistory`              | The method returns the chat message history                                                                                                                                                         | [GetChatHistory.md](https://github.com/green-api/docs/blob/master/ru/docs/api/journals/GetChatHistory.md)                                |
+| `journals.lastIncomingMessages`        | The method returns the last incoming messages of the account. In the default mode the incoming messages for 24 hours are returned                                                                   | [GetChatHistory.md](https://github.com/green-api/docs/blob/master/ru/docs/api/journals/LastIncomingMessages.md)                          |
+| `journals.lastOutgoingMessages`        | The method returns the last outgoing messages of the account. In the default mode the last messages for 24 hours are returned                                                                       | [LastOutgoingMessages.md](https://github.com/green-api/docs/blob/master/ru/docs/api/journals/LastOutgoingMessages.md)                    |
+| `marking.readChat`                     | The method is aimed for marking messages in a chat as read. Either all messages or a specified message in a chat can be marked as read                                                              | [ReadChat.md](https://github.com/green-api/docs/blob/master/ru/docs/api/marks/ReadChat.md)                                               |
+| `device.getDeviceInfo`                 | The method is aimed for getting information about the device (phone) running WhatsApp Business application                                                                                          | [GetDeviceInfo.md](https://github.com/green-api/docs/blob/master/ru/docs/api/phone/GetDeviceInfo.md)                                     |
+| `queues.clearMessagesQueue`            | The method is aimed for clearing the queue of messages to be sent                                                                                                                                   | [ClearMessagesQueue.md](https://github.com/green-api/docs/blob/master/ru/docs/api/queues/ClearMessagesQueue.md)                          |
+| `queues.showMessagesQueue`             | The method is aimed for getting a list of messages in the queue to be sent                                                                                                                          | [ShowMessagesQueue.md](https://github.com/green-api/docs/blob/master/ru/docs/api/queues/ShowMessagesQueue.md)                            |
+| `receiving.deleteNotification`         | The method is aimed for deleting an incoming notification from the notification queue                                                                                                               | [DeleteNotification.md](https://github.com/green-api/docs/blob/master/ru/docs/api/receiving/technology-http-api/DeleteNotification.md)   |
+| `receiving.receiveNotification`        | The method is aimed for receiving one incoming notification from the notifications queue                                                                                                            | [ReceiveNotification.md](https://github.com/green-api/docs/blob/master/ru/docs/api/receiving/technology-http-api/ReceiveNotification.md) |
+| `sending.sendButtons`                  | The method is aimed for sending a button message to a personal or a group chat                                                                                                                      | [SendButtons.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendButtons.md)                                       |
+| `sending.sendContact`                  | The method is aimed for sending a contact message                                                                                                                                                   | [SendContact.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendContact.md)                                       |
+| `sending.sendFileByUpload`             | The method is aimed for sending a file uploaded by form                                                                                                                                             | [SendFileByUpload.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendFileByUpload.md)                             |
+| `sending.sendFileByUrl`                | The method is aimed for sending a file uploaded by Url                                                                                                                                              | [SendFileByUrl.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendFileByUrl.md)                                   |
+| `sending.sendLink`                     | The method is aimed for sending a message with a link, by which an image preview, title and description will be added                                                                               | [SendLink.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendLink.md)                                             |
+| `sending.sendListMessage`              | The method is aimed for sending a message with a select button from a list of values to a personal or a group chat                                                                                  | [SendListMessage.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendListMessage.md)                               |
+| `sending.sendLocation`                 | The method is aimed for sending a location message                                                                                                                                                  | [SendLocation.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendLocation.md)                                     |
+| `sending.sendMessage`                  | The method is aimed for sending a text message to a personal or a group chat                                                                                                                        | [SendMessage.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendMessage.md)                                       |
+| `sending.sendTemplateButtons`          | The method is aimed for sending a message with template list interacrive buttons to a personal or a group chat                                                                                      | [SendTemplateButtons.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendTemplateButtons.md)                       |
+| `serviceMethods.checkWhatsapp`         | The method checks WhatsApp account availability on a phone number                                                                                                                                   | [CheckWhatsapp.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/CheckWhatsapp.md)                                   |
+| `serviceMethods.getAvatar`             | The method returns a user or a group chat avatar                                                                                                                                                    | [GetAvatar.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/GetAvatar.md)                                           |
+| `serviceMethods.getContactInfo`        | The method is aimed for getting information on a contact                                                                                                                                            | [GetContactInfo.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/GetContactInfo.md)                                 |
+| `serviceMethods.getContacts`           | The method is aimed for getting a list of the current account contacts                                                                                                                              | [GetContacts.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/GetContacts.md)                                       |
+| `serviceMethods.setDisappearingChat`   | The method is aimed for changing settings of disappearing messages in chats. The standard settings of the application are to be used: 0 (off), 86400 (24 hours), 604800 (7 days), 7776000 (90 days) | [SetDisappearingChat.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/SetDisappearingChat.md)                       |
+| `serviceMethods.archiveChat`           | The method archives a chat. One can archive chats that have at least one incoming message                                                                                                           | [ArchiveChat.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/ArchiveChat.md)                                       |
+| `serviceMethods.deleteMessage`         | The method deletes a message from a chat                                                                                                                                                            | [DeleteMessage.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/deleteMessage.md)                                   |
+| `serviceMethods.unarchiveChat`         | The method unarchives a chat                                                                                                                                                                        | [UnarchiveChat.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/UnarchiveChat.md)                                   |
+| `serviceMethods.setDisappearingChat`   | The method is aimed for changing settings of disappearing messages in chats                                                                                                                         | [SetDisappearingChat.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/SetDisappearingChat.md)                       |
+| `webhooks.startReceivingNotifications` | The method is aimed for starting to receive webhooks                                                                                                                                                | <library method>                                                                                                                         |
+| `webhooks.stopReceivingNotifications`  | The method is aimed for stopping to receive webhooks                                                                                                                                                | <library method>                                                                                                                         |
 
 ## Service methods documentation
 
diff --git a/README_RUS.md b/README_RUS.md
index 2f0837a..dddd26d 100644
--- a/README_RUS.md
+++ b/README_RUS.md
@@ -3,171 +3,190 @@
 [![Python application](https://github.com/green-api/whatsapp-api-client-python/actions/workflows/python-app.yml/badge.svg)](https://github.com/green-api/whatsapp-api-client-python/actions/workflows/python-app.yml)
 [![Upload Python Package](https://github.com/green-api/whatsapp-api-client-python/actions/workflows/python-publish.yml/badge.svg)](https://github.com/green-api/whatsapp-api-client-python/actions/workflows/python-publish.yml)
 
-Python библиотека для интеграции с мессенджером WhatsAPP через API сервиса [green-api.com](https://green-api.com). Чтобы воспользоваться библиотекой нужно получить регистрационный токен и id аккаунта в [личном кабинете](https://console.green-api.com). Есть бесплатный тариф аккаунта разработчика.
+Python библиотека для интеграции с мессенджером WhatsAPP через API сервиса [green-api.com](https://green-api.com). Чтобы
+воспользоваться библиотекой нужно получить регистрационный токен и id аккаунта
+в [личном кабинете](https://console.green-api.com). Есть бесплатный тариф аккаунта разработчика.
 
 ## API
 
-Документация к REST API находится по [ссылке](https://green-api.com/docs/api/). Библиотека является оберткой к REST API, поэтому документация по ссылке выше применима и к самой библиотеке.
+Документация к REST API находится по [ссылке](https://green-api.com/docs/api/). Библиотека является оберткой к REST API,
+поэтому документация по ссылке выше применима и к самой библиотеке.
 
 ## Установка
 
-```
+```shell
 pip install whatsapp-api-client-python
 ```
 
-## Import 
+## Авторизация
 
-```
-from whatsapp_api_client_python import API
-```
-## Авторизация 
-
-Чтобы отправить сообщение или выполнить другой метод Green-API, аккаунт WhatsApp в приложении телефона должен быть в авторизованном состоянии. Для авторизации аккаунта перейдите в [личный кабинет](https://console.green-api.com) и сканируйте QR-код с использованием приложения WhatsApp.
+Чтобы отправить сообщение или выполнить другой метод Green-API, аккаунт WhatsApp в приложении телефона должен быть в
+авторизованном состоянии. Для авторизации аккаунта перейдите в [личный кабинет](https://console.green-api.com) и
+сканируйте QR-код с использованием приложения WhatsApp.
 
 ## Примеры
 
 ### Как инициализировать объект
 
-```
-greenAPI = API.GreenApi(ID_INSTANCE, API_TOKEN_INSTANCE)
+```python
+from whatsapp_api_client_python import GreenAPI
+
+greenAPI = GreenAPI(ID_INSTANCE, API_TOKEN_INSTANCE)
 ```
 
 ### Отправка текстового сообщения на номер WhatsApp
 
-```
-result = greenAPI.sending.sendMessage('79001234567@g.us', 'Message text')
+```python
+response = greenAPI.sending.send_message(
+    chatId="79001234567@c.us",
+    message="Any message"
+)
 ```
 
-Ссылка на пример: [sendTextMessage.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/sendTextMessage.py)
+Ссылка на
+пример: [send_message.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/send_message.py)
 
 Обратите внимание, что ключи можно получать из переменных среды:
-```
+
+```python
 from os import environ
 
-ID_INSTANCE = environ['ID_INSTANCE']
-API_TOKEN_INSTANCE = environ['API_TOKEN_INSTANCE']
+ID_INSTANCE = environ["ID_INSTANCE"]
+API_TOKEN_INSTANCE = environ["API_TOKEN_INSTANCE"]
 ```
 
 ### Отправка картинки по URL
 
-```
-result = greenAPI.sending.sendFileByUrl('120363025955348359@g.us', 
-        'https://www.google.ru/images/branding/googlelogo/1x/googlelogo_color_272x92dp.png', 
-        'googlelogo_color_272x92dp.png', 'Google logo')
+```python
+response = greenAPI.sending.send_file_by_url(
+    chatId="79001234567@c.us",
+    urlFile="https://www.google.com/images/branding/googlelogo/2x/googlelogo_color_272x92dp.png",
+    fileName="googlelogo_color_272x92dp.png"
+)
 ```
 
-Ссылка на пример: [sendPictureByLink.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/sendPictureByLink.py)
+Ссылка на
+пример: [send_file_by_url.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/send_file_by_url.py)
 
 ### Отправка картинки загрузкой с диска
 
-```
-result = greenAPI.sending.sendFileByUpload('120363025955348359@g.us', 
-        'C:\Games\PicFromDisk.png', 
-        'PicFromDisk.png', 'Picture from disk')
+```python
+response = greenAPI.sending.send_file_by_upload(
+    chatId="79001234567@c.us",
+    path="C:\\Games\\PicFromDisk.png"
+)
 ```
 
-Ссылка на пример: [sendPictureByUpload.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/sendPictureByUpload.py)
+Ссылка на
+пример: [send_file_by_upload.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/send_file_by_upload.py)
 
 ### Создание группы и отправка сообщения в эту группу
 
-```
-chatIds = [
-    "79001234567@c.us"
-]
-resultCreate = greenAPI.groups.createGroup('GroupName', 
-    chatIds)
-
-if resultCreate.code == 200:
-    resultSend = greenAPI.sending.sendMessage(resultCreate.data['chatId'], 
-        'Message text')
+```python
+create_group_response = greenAPI.groups.create_group(
+    groupName="Group Name",
+    chatIds=["79001234567@c.us"]
+)
+
+chatId = create_group_response.data["chatId"]
+send_message_response = greenAPI.sending.send_message(
+    chatId=chatId,
+    message="Any message"
+)
 ```
 
-ВАЖНО: Если попытаться создать группу с несуществующим номером WhatsApp 
+ВАЖНО: Если попытаться создать группу с несуществующим номером WhatsApp
 может заблокировать номер отправителя. Номер в примере не существует.
 
-Ссылка на пример: [createGroupAndSendMessage.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/createGroupAndSendMessage.py)
+Ссылка на
+пример: [create_group_and_send_message.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/create_group_and_send_message.py)
 
 ### Получение входящих сообщений через HTTP API
 
 Общая концепция получения данных в Green API описана [здесь](https://green-api.com/docs/api/receiving/)
-Для старта получения сообщений через HTTP API требуется выполнить метод библиотеки:
+Для старта получения сообщений через HTTP API требуется импортировать класс Webhook и передать в его функцию run_forever
+объект функции обработчика:
 
-```
-greenAPI.webhooks.startReceivingNotifications(onEvent)
+```python
+from whatsapp_api_client_python.tools import Webhook
+
+webhook = Webhook(greenAPI)
+
+webhook.run_forever(handler)
 ```
 
-onEvent - ваш метод, который должен содержать параметры:
-Параметр |  Описание
+handler - ваша функция, которая должен содержать параметры:
+Параметр | Описание
 ----- | -----
-typeWebhook | тип полученного сообщения (строка)
-body | тело сообщения (json)
+type_webhook | Тип полученного уведомления (строка)
+body | Тело сообщения (словарь или список)
 
 Типы и форматы тел сообщений [здесь](https://green-api.com/docs/api/receiving/notifications-format/)
 
-Этот метод будет вызываться при получении входящего сообщения. Далее обрабатываете сообщения согласно бизнес-логике вашей системы.
+Эта функция будет вызываться при получении входящего уведомления. Далее обрабатываете сообщения согласно бизнес-логике
+вашей системы. Передавать handler в функцию run_forever следует без скобок.
 
 ## Список примеров
 
-Описание |  Модуль
------ | ----- 
-Пример отправки текста | [sendTextMessage.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/sendTextMessage.py)
-Пример отправки картинки по URL | [sendPictureByLink.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/sendPictureByLink.py)
-Пример отправки картинки загрузкой с диска | [sendPictureByUpload.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/sendPictureByUpload.py)
-Пример создание группы и отправка сообщения в группу | [createGroupAndSendMessage.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/createGroupAndSendMessage.py)
-Пример получения входящих уведомлений | [receiveNotification.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/receiveNotification.py)
-
+| Описание                                             | Модуль                                                                                                                                            |
+|------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------|
+| Пример отправки текста                               | [send_message.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/send_message.py)                                   |
+| Пример отправки картинки по URL                      | [send_file_by_url.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/send_file_by_url.py)                           |
+| Пример отправки картинки загрузкой с диска           | [send_file_by_upload.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/send_file_by_upload.py)                     |
+| Пример создание группы и отправка сообщения в группу | [create_group_and_send_message.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/create_group_and_send_message.py) |
+| Пример получения входящих уведомлений                | [webhook_example.py](https://github.com/green-api/whatsapp-api-client-python/blob/master/examples/webhook_example.py)                             |
 
 ## Полный список методов библиотеки
 
-Метод | Описание |  Документация
------ | ----- | ----- 
-`account.getSettings` | Метод предназначен для получения текущих настроек аккаунта | [GetSettings.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/GetSettings.md)
-`account.getStateInstance` | Метод предназначен для получения состояния аккаунта | [GetStateInstance.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/GetStateInstance.md)
-`account.getStatusInstance` | Метод предназначен для получения состояния сокета соединения инстанса аккаунта с WhatsApp | [GetStatusInstance.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/GetStatusInstance.md)
-`account.logout` | Метод предназначен для разлогинивания аккаунта | [Logout.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/Logout.md)
-`account.qr` | Метод предназначен для получения QR-кода | [QR.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/QR.md)
-`account.reboot` | Метод предназначен для перезапуска аккаунта | [Reboot.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/Reboot.md)
-`account.setProfilePicture` | Метод предназначен для установки аватара аккаунта | [SetProfilePicture.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/SetProfilePicture.md)
-`account.setSettings` | Метод предназначен для установки настроек аккаунта | [SetSettings.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/SetSettings.md)
-`account.setSystemProxy` | Метод предназначен для установки системного прокси. Нужно используйте метод, когда требуется сбросить пользовательские настройки прокси на системные | [SetSystemProxy.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/SetSystemProxy.md)
-`groups.addGroupParticipant` | Метод добавляет участника в групповой чат | [AddGroupParticipant.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/AddGroupParticipant.md)
-`groups.createGroup` | Метод добавляет участника в групповой чат. ВАЖНО: Если попытаться создать группу с несуществующим номером WhatsApp может заблокировать номер отправителя. | [CreateGroup.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/CreateGroup.md)
-`groups.getGroupData` | Метод получает данные группового чата | [GetGroupData.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/GetGroupData.md)
-`groups.leaveGroup` | Метод производит выход пользователя текущего аккаунта из группового чата | [LeaveGroup.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/LeaveGroup.md)
-`groups.removeAdmin` | Метод лишает участника прав администрирования группового чата | [RemoveAdmin.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/RemoveAdmin.md)
-`groups.removeGroupParticipant` | Метод удаляет участника из группового чата | [RemoveGroupParticipant.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/RemoveGroupParticipant.md)
-`groups.setGroupAdmin` | Метод назначает участника группового чата администратором | [SetGroupAdmin.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/SetGroupAdmin.md)
-`groups.setGroupPicture` | Метод устанавливает аватар группы | [SetGroupPicture.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/SetGroupPicture.md)
-`groups.updateGroupName` | Метод изменяет наименование группового чата | [UpdateGroupName.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/UpdateGroupName.md)
-`journals.getChatHistory` | Метод возвращает историю сообщений чата | [GetChatHistory.md](https://github.com/green-api/docs/blob/master/ru/docs/api/journals/GetChatHistory.md)
-`journals.lastIncomingMessages` | Метод возвращает крайние входящие сообщения аккаунта. По умолчанию возвращаются последние сообщения за 24 часа | [GetChatHistory.md](https://github.com/green-api/docs/blob/master/ru/docs/api/journals/LastIncomingMessages.md)
-`journals.lastOutgoingMessages` | Метод возвращает крайние отправленные сообщения аккаунта. По умолчанию возвращаются последние сообщения за 24 часа | [LastOutgoingMessages.md](https://github.com/green-api/docs/blob/master/ru/docs/api/journals/LastOutgoingMessages.md)
-`marking.readChat` | Метод предназначен для отметки сообщений в чате прочитанными. Могут быть отмечены прочитанными все сообщения в чате или только одно заданное сообщение | [ReadChat.md](https://github.com/green-api/docs/blob/master/ru/docs/api/marks/ReadChat.md)
-`device.getDeviceInfo` | Метод предназначен для получения информации об устройстве (телефоне), на котором запущено приложение WhatsApp Business | [GetDeviceInfo.md](https://github.com/green-api/docs/blob/master/ru/docs/api/phone/GetDeviceInfo.md)
-`queues.clearMessagesQueue` | Метод предназначен для очистки очереди сообщений на отправку | [ClearMessagesQueue.md](https://github.com/green-api/docs/blob/master/ru/docs/api/queues/ClearMessagesQueue.md)
-`queues.showMessagesQueue` | Метод предназначен для получения списка сообщений, находящихся в очереди на отправку | [ShowMessagesQueue.md](https://github.com/green-api/docs/blob/master/ru/docs/api/queues/ShowMessagesQueue.md)
-`receiving.deleteNotification` | Метод предназначен для удаления входящего уведомления из очереди уведомлений | [DeleteNotification.md](https://github.com/green-api/docs/blob/master/ru/docs/api/receiving/technology-http-api/DeleteNotification.md)
-`receiving.receiveNotification` | Метод предназначен для получения одного входящего уведомления из очереди уведомлений | [ReceiveNotification.md](https://github.com/green-api/docs/blob/master/ru/docs/api/receiving/technology-http-api/ReceiveNotification.md)
-`sending.sendButtons` | Метод предназначен для отправки сообщения с кнопками в личный или групповой чат | [SendButtons.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendButtons.md)
-`sending.sendContact` | Метод предназначен для отправки сообщения с контактом | [SendContact.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendContact.md)
-`sending.sendFileByUpload` | Метод предназначен для отправки файла, загружаемого через форму | [SendFileByUpload.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendFileByUpload.md)
-`sending.sendFileByUrl` | Метод предназначен для отправки файла, загружаемого по ссылке | [SendFileByUrl.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendFileByUrl.md)
-`sending.sendLink` | Метод предназначен для отправки сообщения со ссылкой, по которой будут добавлены превью изображения, заголовок и описание | [SendLink.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendLink.md)
-`sending.sendListMessage` | Метод предназначен для отправки сообщения с кнопкой выбора из списка значений в личный или групповой чат | [SendListMessage.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendListMessage.md)
-`sending.sendLocation` | Метод предназначен для отправки сообщения геолокации | [SendLocation.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendLocation.md)
-`sending.sendMessage` | Метод предназначен для отправки текстового сообщения в личный или групповой чат | [SendMessage.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendMessage.md)
-`sending.sendTemplateButtons` | Метод предназначен для отправки сообщения с интерактивными кнопками из перечня шаблонов в личный или групповой чат | [SendTemplateButtons.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendTemplateButtons.md)
-`serviceMethods.checkWhatsapp` | Метод проверяет наличие аккаунта WhatsApp на номере телефона | [CheckWhatsapp.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/CheckWhatsapp.md)
-`serviceMethods.getAvatar` | Метод возвращает аватар корреспондента или группового чата | [GetAvatar.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/GetAvatar.md)
-`serviceMethods.getContactInfo` | Метод предназначен для получения информации о контакте | [GetContactInfo.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/GetContactInfo.md)
-`serviceMethods.getContacts` | Метод предназначен для получения списка контактов текущего аккаунта | [GetContacts.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/GetContacts.md)
-`serviceMethods.setDisappearingChat` | Метод предназначен для изменения настроек исчезающих сообщений в чатах. Нужно использовать стандартные настройки приложения: 0 (выключено), 86400 (24 часа), 604800 (7 дней), 7776000 (90 дней) | [SetDisappearingChat.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/SetDisappearingChat.md)
-`serviceMethods.archiveChat` | Метод архивирует чат. Архивировать можно чаты, в которых есть хотя бы одно входящее сообщение | [ArchiveChat.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/ArchiveChat.md)
-`serviceMethods.deleteMessage` | Метод удаляет сообщение из чата | [DeleteMessage.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/deleteMessage.md)
-`serviceMethods.unarchiveChat` | Метод разархивирует чат | [UnarchiveChat.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/UnarchiveChat.md)
-`serviceMethods.setDisappearingChat` | Метод предназначен для изменения настроек исчезающих сообщений в чатах | [SetDisappearingChat.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/SetDisappearingChat.md)
-`webhooks.startReceivingNotifications` | Метод предназначен для запуска получения вебхуков | <библиотечный метод>
-`webhooks.stopReceivingNotifications` | Метод предназначен для остановки получения вебхуков | <библиотечный метод>
+| Метод                                  | Описание                                                                                                                                                                                        | Документация                                                                                                                             |
+|----------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------|
+| `account.getSettings`                  | Метод предназначен для получения текущих настроек аккаунта                                                                                                                                      | [GetSettings.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/GetSettings.md)                                       |
+| `account.getStateInstance`             | Метод предназначен для получения состояния аккаунта                                                                                                                                             | [GetStateInstance.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/GetStateInstance.md)                             |
+| `account.getStatusInstance`            | Метод предназначен для получения состояния сокета соединения инстанса аккаунта с WhatsApp                                                                                                       | [GetStatusInstance.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/GetStatusInstance.md)                           |
+| `account.logout`                       | Метод предназначен для разлогинивания аккаунта                                                                                                                                                  | [Logout.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/Logout.md)                                                 |
+| `account.qr`                           | Метод предназначен для получения QR-кода                                                                                                                                                        | [QR.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/QR.md)                                                         |
+| `account.reboot`                       | Метод предназначен для перезапуска аккаунта                                                                                                                                                     | [Reboot.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/Reboot.md)                                                 |
+| `account.setProfilePicture`            | Метод предназначен для установки аватара аккаунта                                                                                                                                               | [SetProfilePicture.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/SetProfilePicture.md)                           |
+| `account.setSettings`                  | Метод предназначен для установки настроек аккаунта                                                                                                                                              | [SetSettings.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/SetSettings.md)                                       |
+| `account.setSystemProxy`               | Метод предназначен для установки системного прокси. Нужно используйте метод, когда требуется сбросить пользовательские настройки прокси на системные                                            | [SetSystemProxy.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/SetSystemProxy.md)                                 |
+| `groups.addGroupParticipant`           | Метод добавляет участника в групповой чат                                                                                                                                                       | [AddGroupParticipant.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/AddGroupParticipant.md)                        |
+| `groups.createGroup`                   | Метод добавляет участника в групповой чат. ВАЖНО: Если попытаться создать группу с несуществующим номером WhatsApp может заблокировать номер отправителя.                                       | [CreateGroup.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/CreateGroup.md)                                        |
+| `groups.getGroupData`                  | Метод получает данные группового чата                                                                                                                                                           | [GetGroupData.md](https://github.com/green-api/docs/blob/master/ru/docs/api/account/GetGroupData.md)                                     |
+| `groups.leaveGroup`                    | Метод производит выход пользователя текущего аккаунта из группового чата                                                                                                                        | [LeaveGroup.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/LeaveGroup.md)                                          |
+| `groups.removeAdmin`                   | Метод лишает участника прав администрирования группового чата                                                                                                                                   | [RemoveAdmin.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/RemoveAdmin.md)                                        |
+| `groups.removeGroupParticipant`        | Метод удаляет участника из группового чата                                                                                                                                                      | [RemoveGroupParticipant.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/RemoveGroupParticipant.md)                  |
+| `groups.setGroupAdmin`                 | Метод назначает участника группового чата администратором                                                                                                                                       | [SetGroupAdmin.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/SetGroupAdmin.md)                                    |
+| `groups.setGroupPicture`               | Метод устанавливает аватар группы                                                                                                                                                               | [SetGroupPicture.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/SetGroupPicture.md)                                |
+| `groups.updateGroupName`               | Метод изменяет наименование группового чата                                                                                                                                                     | [UpdateGroupName.md](https://github.com/green-api/docs/blob/master/ru/docs/api/groups/UpdateGroupName.md)                                |
+| `journals.getChatHistory`              | Метод возвращает историю сообщений чата                                                                                                                                                         | [GetChatHistory.md](https://github.com/green-api/docs/blob/master/ru/docs/api/journals/GetChatHistory.md)                                |
+| `journals.lastIncomingMessages`        | Метод возвращает крайние входящие сообщения аккаунта. По умолчанию возвращаются последние сообщения за 24 часа                                                                                  | [GetChatHistory.md](https://github.com/green-api/docs/blob/master/ru/docs/api/journals/LastIncomingMessages.md)                          |
+| `journals.lastOutgoingMessages`        | Метод возвращает крайние отправленные сообщения аккаунта. По умолчанию возвращаются последние сообщения за 24 часа                                                                              | [LastOutgoingMessages.md](https://github.com/green-api/docs/blob/master/ru/docs/api/journals/LastOutgoingMessages.md)                    |
+| `marking.readChat`                     | Метод предназначен для отметки сообщений в чате прочитанными. Могут быть отмечены прочитанными все сообщения в чате или только одно заданное сообщение                                          | [ReadChat.md](https://github.com/green-api/docs/blob/master/ru/docs/api/marks/ReadChat.md)                                               |
+| `device.getDeviceInfo`                 | Метод предназначен для получения информации об устройстве (телефоне), на котором запущено приложение WhatsApp Business                                                                          | [GetDeviceInfo.md](https://github.com/green-api/docs/blob/master/ru/docs/api/phone/GetDeviceInfo.md)                                     |
+| `queues.clearMessagesQueue`            | Метод предназначен для очистки очереди сообщений на отправку                                                                                                                                    | [ClearMessagesQueue.md](https://github.com/green-api/docs/blob/master/ru/docs/api/queues/ClearMessagesQueue.md)                          |
+| `queues.showMessagesQueue`             | Метод предназначен для получения списка сообщений, находящихся в очереди на отправку                                                                                                            | [ShowMessagesQueue.md](https://github.com/green-api/docs/blob/master/ru/docs/api/queues/ShowMessagesQueue.md)                            |
+| `receiving.deleteNotification`         | Метод предназначен для удаления входящего уведомления из очереди уведомлений                                                                                                                    | [DeleteNotification.md](https://github.com/green-api/docs/blob/master/ru/docs/api/receiving/technology-http-api/DeleteNotification.md)   |
+| `receiving.receiveNotification`        | Метод предназначен для получения одного входящего уведомления из очереди уведомлений                                                                                                            | [ReceiveNotification.md](https://github.com/green-api/docs/blob/master/ru/docs/api/receiving/technology-http-api/ReceiveNotification.md) |
+| `sending.sendButtons`                  | Метод предназначен для отправки сообщения с кнопками в личный или групповой чат                                                                                                                 | [SendButtons.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendButtons.md)                                       |
+| `sending.sendContact`                  | Метод предназначен для отправки сообщения с контактом                                                                                                                                           | [SendContact.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendContact.md)                                       |
+| `sending.sendFileByUpload`             | Метод предназначен для отправки файла, загружаемого через форму                                                                                                                                 | [SendFileByUpload.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendFileByUpload.md)                             |
+| `sending.sendFileByUrl`                | Метод предназначен для отправки файла, загружаемого по ссылке                                                                                                                                   | [SendFileByUrl.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendFileByUrl.md)                                   |
+| `sending.sendLink`                     | Метод предназначен для отправки сообщения со ссылкой, по которой будут добавлены превью изображения, заголовок и описание                                                                       | [SendLink.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendLink.md)                                             |
+| `sending.sendListMessage`              | Метод предназначен для отправки сообщения с кнопкой выбора из списка значений в личный или групповой чат                                                                                        | [SendListMessage.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendListMessage.md)                               |
+| `sending.sendLocation`                 | Метод предназначен для отправки сообщения геолокации                                                                                                                                            | [SendLocation.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendLocation.md)                                     |
+| `sending.sendMessage`                  | Метод предназначен для отправки текстового сообщения в личный или групповой чат                                                                                                                 | [SendMessage.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendMessage.md)                                       |
+| `sending.sendTemplateButtons`          | Метод предназначен для отправки сообщения с интерактивными кнопками из перечня шаблонов в личный или групповой чат                                                                              | [SendTemplateButtons.md](https://github.com/green-api/docs/blob/master/ru/docs/api/sending/SendTemplateButtons.md)                       |
+| `serviceMethods.checkWhatsapp`         | Метод проверяет наличие аккаунта WhatsApp на номере телефона                                                                                                                                    | [CheckWhatsapp.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/CheckWhatsapp.md)                                   |
+| `serviceMethods.getAvatar`             | Метод возвращает аватар корреспондента или группового чата                                                                                                                                      | [GetAvatar.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/GetAvatar.md)                                           |
+| `serviceMethods.getContactInfo`        | Метод предназначен для получения информации о контакте                                                                                                                                          | [GetContactInfo.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/GetContactInfo.md)                                 |
+| `serviceMethods.getContacts`           | Метод предназначен для получения списка контактов текущего аккаунта                                                                                                                             | [GetContacts.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/GetContacts.md)                                       |
+| `serviceMethods.setDisappearingChat`   | Метод предназначен для изменения настроек исчезающих сообщений в чатах. Нужно использовать стандартные настройки приложения: 0 (выключено), 86400 (24 часа), 604800 (7 дней), 7776000 (90 дней) | [SetDisappearingChat.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/SetDisappearingChat.md)                       |
+| `serviceMethods.archiveChat`           | Метод архивирует чат. Архивировать можно чаты, в которых есть хотя бы одно входящее сообщение                                                                                                   | [ArchiveChat.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/ArchiveChat.md)                                       |
+| `serviceMethods.deleteMessage`         | Метод удаляет сообщение из чата                                                                                                                                                                 | [DeleteMessage.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/deleteMessage.md)                                   |
+| `serviceMethods.unarchiveChat`         | Метод разархивирует чат                                                                                                                                                                         | [UnarchiveChat.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/UnarchiveChat.md)                                   |
+| `serviceMethods.setDisappearingChat`   | Метод предназначен для изменения настроек исчезающих сообщений в чатах                                                                                                                          | [SetDisappearingChat.md](https://github.com/green-api/docs/blob/master/ru/docs/api/service/SetDisappearingChat.md)                       |
+| `webhooks.startReceivingNotifications` | Метод предназначен для запуска получения вебхуков                                                                                                                                               | <библиотечный метод>                                                                                                                     |
+| `webhooks.stopReceivingNotifications`  | Метод предназначен для остановки получения вебхуков                                                                                                                                             | <библиотечный метод>                                                                                                                     |
 
 ## Документация по методам сервиса
 
diff --git a/examples/createGroupAndSendMessage.py b/examples/createGroupAndSendMessage.py
deleted file mode 100644
index 12cdcde..0000000
--- a/examples/createGroupAndSendMessage.py
+++ /dev/null
@@ -1,30 +0,0 @@
-from os import environ
-
-from whatsapp_api_client_python import API as API
-
-# First you need to set the environment variables
-ID_INSTANCE = environ['ID_INSTANCE']
-API_TOKEN_INSTANCE = environ['API_TOKEN_INSTANCE']
-
-greenAPI = API.GreenApi(ID_INSTANCE, API_TOKEN_INSTANCE)
-
-def main():
-    chatIds = [
-        "79001234567@c.us"
-    ]
-    resultCreate = greenAPI.groups.createGroup('GroupName', 
-        chatIds)
-
-    if resultCreate.code == 200:
-        print(resultCreate.data)
-        resultSend = greenAPI.sending.sendMessage(resultCreate.data['chatId'], 
-            'Message text')
-        if resultSend.code == 200:
-            print(resultSend.data)
-        else:
-            print(resultSend.error)    
-    else:
-        print(resultCreate.error)
-
-if __name__ == "__main__":
-    main()
\ No newline at end of file
diff --git a/examples/create_group_and_send_message.py b/examples/create_group_and_send_message.py
new file mode 100644
index 0000000..43fb1d0
--- /dev/null
+++ b/examples/create_group_and_send_message.py
@@ -0,0 +1,30 @@
+from os import environ
+
+from whatsapp_api_client_python import GreenAPI
+
+# First you need to set the environment variables.
+ID_INSTANCE = environ["ID_INSTANCE"]
+API_TOKEN_INSTANCE = environ["API_TOKEN_INSTANCE"]
+
+greenAPI = GreenAPI(ID_INSTANCE, API_TOKEN_INSTANCE)
+
+
+def main():
+    create_group_response = greenAPI.groups.create_group(
+        groupName="Group Name",
+        chatIds=["79001234567@c.us"]
+    )
+
+    print(create_group_response.data)
+
+    chatId = create_group_response.data["chatId"]
+    send_message_response = greenAPI.sending.send_message(
+        chatId=chatId,
+        message="Any message"
+    )
+
+    print(send_message_response.data)
+
+
+if __name__ == "__main__":
+    main()
diff --git a/examples/receiveNotification.py b/examples/receiveNotification.py
deleted file mode 100644
index 5a3b763..0000000
--- a/examples/receiveNotification.py
+++ /dev/null
@@ -1,98 +0,0 @@
-from os import environ
-from datetime import datetime
-import json
-from whatsapp_api_client_python import API as API
-
-
-ID_INSTANCE = environ['ID_INSTANCE']
-API_TOKEN_INSTANCE = environ['API_TOKEN_INSTANCE']
-
-greenAPI = API.GreenApi(ID_INSTANCE, API_TOKEN_INSTANCE)
-
-def main():
-   greenAPI.webhooks.startReceivingNotifications(onEvent)
-
-def onEvent(typeWebhook, body):
-   if typeWebhook == 'incomingMessageReceived':
-      onIncomingMessageReceived(body)      
-   elif typeWebhook == 'deviceInfo':   
-      onDeviceInfo(body)              
-   elif typeWebhook == 'incomingCall':
-      onIncomingCall(body)
-   elif typeWebhook == 'outgoingAPIMessageReceived':
-      onOutgoingAPIMessageReceived(body)
-   elif typeWebhook == 'outgoingMessageReceived':
-      onOutgoingMessageReceived(body)
-   elif typeWebhook == 'outgoingMessageStatus':
-      onOutgoingMessageStatus(body)
-   elif typeWebhook == 'stateInstanceChanged':
-      onStateInstanceChanged(body)
-   elif typeWebhook == 'statusInstanceChanged':
-      onStatusInstanceChanged(body)
-
-def onIncomingMessageReceived(body):
-        idMessage = body['idMessage']
-        eventDate = datetime.fromtimestamp(body['timestamp'])
-        senderData = body['senderData']
-        messageData = body['messageData']
-        print(idMessage + ': ' 
-            + 'At ' + str(eventDate) + ' Incoming from ' \
-            + json.dumps(senderData, ensure_ascii=False) \
-            + ' message = ' + json.dumps(messageData, ensure_ascii=False))
-
-def onIncomingCall(body):
-   idMessage = body['idMessage']
-   eventDate = datetime.fromtimestamp(body['timestamp'])
-   fromWho = body['from']
-   print(idMessage + ': ' 
-      + 'Call from ' + fromWho 
-      + ' at ' + str(eventDate))
-
-def onDeviceInfo(body):
-   eventDate = datetime.fromtimestamp(body['timestamp'])
-   deviceData = body['deviceData']
-   print('At ' + str(eventDate) + ': ' \
-      + json.dumps(deviceData, ensure_ascii=False))
-
-def onOutgoingMessageReceived(body):
-   idMessage = body['idMessage']
-   eventDate = datetime.fromtimestamp(body['timestamp'])
-   senderData = body['senderData']
-   messageData = body['messageData']
-   print(idMessage + ': ' 
-      + 'At ' + str(eventDate) + ' Outgoing from ' \
-      + json.dumps(senderData, ensure_ascii=False) \
-      + ' message = ' + json.dumps(messageData, ensure_ascii=False))
-
-def onOutgoingAPIMessageReceived(body):
-   idMessage = body['idMessage']
-   eventDate = datetime.fromtimestamp(body['timestamp'])
-   senderData = body['senderData']
-   messageData = body['messageData']
-   print(idMessage + ': ' 
-      + 'At ' + str(eventDate) + ' API outgoing from ' \
-      + json.dumps(senderData, ensure_ascii=False) + \
-      ' message = ' + json.dumps(messageData, ensure_ascii=False))
-
-def onOutgoingMessageStatus(body):
-   idMessage = body['idMessage']
-   status = body['status']
-   eventDate = datetime.fromtimestamp(body['timestamp'])
-   print(idMessage + ': ' 
-      + 'At ' + str(eventDate) + ' status = ' + status)
-
-def onStateInstanceChanged(body):
-   eventDate = datetime.fromtimestamp(body['timestamp'])
-   stateInstance = body['stateInstance']
-   print('At ' + str(eventDate) + ' state instance = ' \
-      + json.dumps(stateInstance, ensure_ascii=False))
-
-def onStatusInstanceChanged(body):
-   eventDate = datetime.fromtimestamp(body['timestamp'])
-   statusInstance = body['statusInstance']
-   print('At ' + str(eventDate) + ' status instance = ' \
-      + json.dumps(statusInstance, ensure_ascii=False))
-
-
-if __name__ == "__main__":
-    main()
\ No newline at end of file
diff --git a/examples/sendPictureByLink.py b/examples/sendPictureByLink.py
deleted file mode 100644
index 7d0dae0..0000000
--- a/examples/sendPictureByLink.py
+++ /dev/null
@@ -1,17 +0,0 @@
-from os import environ
-
-from whatsapp_api_client_python import API as API
-
-ID_INSTANCE = environ['ID_INSTANCE']
-API_TOKEN_INSTANCE = environ['API_TOKEN_INSTANCE']
-
-greenAPI = API.GreenApi(ID_INSTANCE, API_TOKEN_INSTANCE)
-
-def main():
-    result = greenAPI.sending.sendFileByUrl('79001234567@c.us', 
-        'https://www.google.ru/images/branding/googlelogo/1x/googlelogo_color_272x92dp.png', 
-        'googlelogo_color_272x92dp.png', 'Google logo')
-    print(result.data)
-
-if __name__ == "__main__":
-    main()
\ No newline at end of file
diff --git a/examples/sendPictureByUpload.py b/examples/sendPictureByUpload.py
deleted file mode 100644
index 2b88564..0000000
--- a/examples/sendPictureByUpload.py
+++ /dev/null
@@ -1,17 +0,0 @@
-from os import environ
-
-from whatsapp_api_client_python import API as API
-
-ID_INSTANCE = environ['ID_INSTANCE']
-API_TOKEN_INSTANCE = environ['API_TOKEN_INSTANCE']
-
-greenAPI = API.GreenApi(ID_INSTANCE, API_TOKEN_INSTANCE)
-
-def main():
-    result = greenAPI.sending.sendFileByUpload('79001234567@c.us', 
-        'C:\Games\PicFromDisk.png', 
-        'PicFromDisk.png', 'Picture from disk')
-    print(result.data)
-
-if __name__ == "__main__":
-    main()
\ No newline at end of file
diff --git a/examples/sendTextMessage.py b/examples/sendTextMessage.py
deleted file mode 100644
index 3b6f226..0000000
--- a/examples/sendTextMessage.py
+++ /dev/null
@@ -1,15 +0,0 @@
-from os import environ
-
-from whatsapp_api_client_python import API as API
-
-ID_INSTANCE = environ['ID_INSTANCE']
-API_TOKEN_INSTANCE = environ['API_TOKEN_INSTANCE']
-
-greenAPI = API.GreenApi(ID_INSTANCE, API_TOKEN_INSTANCE)
-
-def main():
-    result = greenAPI.sending.sendMessage('79001234567@c.us', 'Message text')
-    print(result.data)
-
-if __name__ == "__main__":
-    main()
\ No newline at end of file
diff --git a/examples/send_file_by_upload.py b/examples/send_file_by_upload.py
new file mode 100644
index 0000000..8d49503
--- /dev/null
+++ b/examples/send_file_by_upload.py
@@ -0,0 +1,22 @@
+from os import environ
+
+from whatsapp_api_client_python import GreenAPI
+
+# First you need to set the environment variables.
+ID_INSTANCE = environ["ID_INSTANCE"]
+API_TOKEN_INSTANCE = environ["API_TOKEN_INSTANCE"]
+
+greenAPI = GreenAPI(ID_INSTANCE, API_TOKEN_INSTANCE)
+
+
+def main():
+    response = greenAPI.sending.send_file_by_upload(
+        chatId="79001234567@c.us",
+        path="C:\\Games\\PicFromDisk.png"
+    )
+
+    print(response.data)
+
+
+if __name__ == "__main__":
+    main()
diff --git a/examples/send_file_by_url.py b/examples/send_file_by_url.py
new file mode 100644
index 0000000..2823f00
--- /dev/null
+++ b/examples/send_file_by_url.py
@@ -0,0 +1,23 @@
+from os import environ
+
+from whatsapp_api_client_python import GreenAPI
+
+# First you need to set the environment variables.
+ID_INSTANCE = environ["ID_INSTANCE"]
+API_TOKEN_INSTANCE = environ["API_TOKEN_INSTANCE"]
+
+greenAPI = GreenAPI(ID_INSTANCE, API_TOKEN_INSTANCE)
+
+
+def main():
+    response = greenAPI.sending.send_file_by_url(
+        chatId="79001234567@c.us",
+        urlFile="https://www.google.com/images/branding/googlelogo/2x/googlelogo_color_272x92dp.png",
+        fileName="googlelogo_color_272x92dp.png"
+    )
+
+    print(response.data)
+
+
+if __name__ == "__main__":
+    main()
diff --git a/examples/send_message.py b/examples/send_message.py
new file mode 100644
index 0000000..9e7c0da
--- /dev/null
+++ b/examples/send_message.py
@@ -0,0 +1,21 @@
+from os import environ
+
+from whatsapp_api_client_python import GreenAPI
+
+ID_INSTANCE = environ["ID_INSTANCE"]
+API_TOKEN_INSTANCE = environ["API_TOKEN_INSTANCE"]
+
+greenAPI = GreenAPI(ID_INSTANCE, API_TOKEN_INSTANCE)
+
+
+def main():
+    response = greenAPI.sending.send_message(
+        chatId="79001234567@c.us",
+        message="Any message"
+    )
+
+    print(response.data)
+
+
+if __name__ == "__main__":
+    main()
diff --git a/examples/webhook_example.py b/examples/webhook_example.py
new file mode 100644
index 0000000..c14dd96
--- /dev/null
+++ b/examples/webhook_example.py
@@ -0,0 +1,36 @@
+from os import environ
+from typing import Union
+
+from whatsapp_api_client_python import GreenAPI
+from whatsapp_api_client_python.tools import Webhook
+
+# First you need to set the environment variables.
+ID_INSTANCE = environ["ID_INSTANCE"]
+API_TOKEN_INSTANCE = environ["API_TOKEN_INSTANCE"]
+
+greenAPI = GreenAPI(ID_INSTANCE, API_TOKEN_INSTANCE)
+
+
+def main():
+    webhook = Webhook(greenAPI)
+
+    webhook.run_forever(handler)
+
+
+def handler(type_webhook: str, body: Union[dict, list]):
+    if type_webhook == "incomingMessageReceived":
+        sender_data = body["senderData"]
+        message_data = body["messageData"]
+
+        type_message = message_data["typeMessage"]
+        if type_message == "textMessage":
+            text_message = message_data["textMessageData"]["textMessage"]
+
+            greenAPI.sending.send_message(
+                chatId=sender_data["chatId"],
+                message=f"You wrote: {text_message}."
+            )
+
+
+if __name__ == "__main__":
+    main()
diff --git a/setup.py b/setup.py
index da66f08..d7d3e8e 100644
--- a/setup.py
+++ b/setup.py
@@ -4,21 +4,29 @@
     read_me_description = file.read()
 
 setuptools.setup(
-    name="whatsapp-api-client-python",
-    version="0.0.27",
-    install_requires=['requests'],
+    name="whatsapp_api_client_python",
+    version="0.0.28",
+    install_requires=["requests"],
     author="Ivan Sadovy",
     author_email="sadiv@bk.ru",
-    description="This library helps you easily create a python '\
-        'application to connect the WhatsApp API using service green-api.com",
+    description=(
+        "This library helps you easily create a python "
+        "application to connect the WhatsApp API using service green-api.com"
+    ),
     long_description=read_me_description,
     long_description_content_type="text/markdown",
     url="https://github.com/green-api/whatsapp-api-client-python",
-    packages=['whatsapp_api_client_python', 'whatsapp_api_client_python.tools'],
+    packages=[
+        "whatsapp_api_client_python",
+        "whatsapp_api_client_python.api",
+        "whatsapp_api_client_python.base",
+        "whatsapp_api_client_python.methods",
+        "whatsapp_api_client_python.tools"
+    ],
     classifiers=[
         "Programming Language :: Python :: 3",
         "License :: OSI Approved :: MIT License",
         "Operating System :: OS Independent",
     ],
-    python_requires='>=3.5',
-)
\ No newline at end of file
+    python_requires='>=3.7',
+)
diff --git a/whatsapp_api_client_python/API.py b/whatsapp_api_client_python/API.py
deleted file mode 100644
index fe216ad..0000000
--- a/whatsapp_api_client_python/API.py
+++ /dev/null
@@ -1,73 +0,0 @@
-from array import array
-import requests
-import json
-from whatsapp_api_client_python.response import Response
-
-from whatsapp_api_client_python.tools.account import Account
-from whatsapp_api_client_python.tools.device import Device
-from whatsapp_api_client_python.tools.groups import Groups
-from whatsapp_api_client_python.tools.journals import Journals
-from whatsapp_api_client_python.tools.marking import Marking
-from whatsapp_api_client_python.tools.queues import Queues
-from whatsapp_api_client_python.tools.receiving import Receiving
-from whatsapp_api_client_python.tools.sending import Sending
-from whatsapp_api_client_python.tools.serviceMethods import ServiceMethods
-from whatsapp_api_client_python.tools.webhooks import Webhooks
-
-
-class GreenApi:
-    'REST API class'
-
-    host: str
-    idInstance: str
-    apiTokenInstance: str
-
-    def __init__(self, 
-                    idInstance: str, 
-                    apiTokenInstance: str,
-                    host: str = 'https://api.green-api.com') -> None:
-        self.host = host
-        self.idInstance = idInstance
-        self.apiTokenInstance = apiTokenInstance
-
-        self.account = Account(self)
-        self.device = Device(self)
-        self.groups = Groups(self)
-        self.journals = Journals(self)
-        self.marking = Marking(self)
-        self.queues = Queues(self)
-        self.receiving = Receiving(self)
-        self.sending = Sending(self)
-        self.serviceMethods = ServiceMethods(self)
-        self.webhooks = Webhooks(self)
-
-    def request(self, method: str, url: str, 
-                payload: any = None, files: array = None):
-        url = url.replace('{{host}}', self.host)
-        url = url.replace('{{idInstance}}', self.idInstance)
-        url = url.replace('{{apiTokenInstance}}', self.apiTokenInstance)
-        status_code = 0
-        text = ''
-        try:
-            headers = {}
-            payloadData = None
-            if payload != None:
-                if files == None:
-                    headers = {
-                        'Content-Type': 'application/json'
-                    }
-                    payloadData = json.dumps(payload)
-                else:
-                    payloadData = payload   
-            result = requests.request(method, url, headers = headers, 
-                                        data = payloadData, 
-                                        files = files)
-            status_code = result.status_code
-            text = result.text
-            result.raise_for_status()
-        except requests.HTTPError:
-            return Response(status_code, text)
-        except Exception as err:
-            status_code = 0
-            text = f'Other error occurred: {err}'
-        return Response(status_code, text)
\ No newline at end of file
diff --git a/whatsapp_api_client_python/__init__.py b/whatsapp_api_client_python/__init__.py
index e69de29..cb6ff0e 100644
--- a/whatsapp_api_client_python/__init__.py
+++ b/whatsapp_api_client_python/__init__.py
@@ -0,0 +1,3 @@
+from whatsapp_api_client_python.api import GreenAPI
+
+__all__ = ["GreenAPI"]
diff --git a/whatsapp_api_client_python/api/__init__.py b/whatsapp_api_client_python/api/__init__.py
new file mode 100644
index 0000000..8c758da
--- /dev/null
+++ b/whatsapp_api_client_python/api/__init__.py
@@ -0,0 +1,4 @@
+from whatsapp_api_client_python.api.abc import AbstractAPI
+from whatsapp_api_client_python.api.api import GreenAPI
+
+__all__ = ["AbstractAPI", "GreenAPI"]
diff --git a/whatsapp_api_client_python/api/abc.py b/whatsapp_api_client_python/api/abc.py
new file mode 100644
index 0000000..80003a9
--- /dev/null
+++ b/whatsapp_api_client_python/api/abc.py
@@ -0,0 +1,16 @@
+from abc import ABC, abstractmethod
+from typing import Optional
+
+from whatsapp_api_client_python.response import Response
+
+
+class AbstractAPI(ABC):
+    @abstractmethod
+    def request(
+            self,
+            http_method: str,
+            method: str,
+            data: Optional[dict] = None,
+            files: Optional[dict] = None
+    ) -> Response:
+        pass
diff --git a/whatsapp_api_client_python/api/api.py b/whatsapp_api_client_python/api/api.py
new file mode 100644
index 0000000..898b509
--- /dev/null
+++ b/whatsapp_api_client_python/api/api.py
@@ -0,0 +1,48 @@
+import json
+from typing import Optional
+
+import requests
+
+from whatsapp_api_client_python.api.abc import AbstractAPI
+from whatsapp_api_client_python.categories import APICategories
+from whatsapp_api_client_python.response import Response
+
+
+class GreenAPI(AbstractAPI, APICategories):
+    """REST API class"""
+
+    def __init__(
+            self,
+            id_instance: str,
+            api_token_instance: str,
+            host: str = "https://api.green-api.com"
+    ):
+        self.id_instance = id_instance
+        self.api_token_instance = api_token_instance
+        self.host = host
+
+        super(GreenAPI, self).__init__(self)
+
+    def request(
+            self,
+            http_method: str,
+            method: str,
+            data: Optional[dict] = None,
+            files: Optional[dict] = None
+    ) -> Response:
+        url = (
+            f"{self.host}/waInstance{self.id_instance}/"
+            f"{method}/{self.api_token_instance}"
+        )
+        headers = {}
+
+        if data and not files:
+            data = json.dumps(data)
+
+            headers = {"Content-Type": "application/json"}
+
+        response = requests.request(
+            http_method, url, headers=headers, data=data, files=files
+        )
+
+        return Response(response.status_code, response.text)
diff --git a/whatsapp_api_client_python/base/__init__.py b/whatsapp_api_client_python/base/__init__.py
new file mode 100644
index 0000000..f5ebd5a
--- /dev/null
+++ b/whatsapp_api_client_python/base/__init__.py
@@ -0,0 +1,3 @@
+from whatsapp_api_client_python.base.category import BaseCategory
+
+__all__ = ["BaseCategory"]
diff --git a/whatsapp_api_client_python/base/category.py b/whatsapp_api_client_python/base/category.py
new file mode 100644
index 0000000..bfe4191
--- /dev/null
+++ b/whatsapp_api_client_python/base/category.py
@@ -0,0 +1,18 @@
+from whatsapp_api_client_python.api import AbstractAPI
+
+
+class BaseCategory:
+    def __init__(self, api: AbstractAPI):
+        self.api = api
+
+    @classmethod
+    def handle_parameters(cls, parameters: dict):
+        new_parameters = parameters.copy()
+
+        new_parameters.pop("self")
+
+        for key, value in parameters.items():
+            if value is None:
+                new_parameters.pop(key)
+
+        return new_parameters
diff --git a/whatsapp_api_client_python/categories.py b/whatsapp_api_client_python/categories.py
new file mode 100644
index 0000000..b16569f
--- /dev/null
+++ b/whatsapp_api_client_python/categories.py
@@ -0,0 +1,56 @@
+from .api import AbstractAPI
+from .methods import (
+    account,
+    device,
+    groups,
+    journals,
+    mark_read,
+    queues,
+    receiving,
+    sending,
+    service_methods
+)
+
+
+class APICategories:
+    def __init__(self, api: AbstractAPI):
+        self.api = api
+
+    @property
+    def account(self) -> account.AccountCategory:
+        return account.AccountCategory(self.api)
+
+    @property
+    def device(self) -> device.DeviceCategory:
+        return device.DeviceCategory(self.api)
+
+    @property
+    def groups(self) -> groups.GroupCategory:
+        return groups.GroupCategory(self.api)
+
+    @property
+    def journals(self) -> journals.JournalCategory:
+        return journals.JournalCategory(self.api)
+
+    @property
+    def mark_read(self) -> mark_read.MarkReadCategory:
+        return mark_read.MarkReadCategory(self.api)
+
+    @property
+    def queues(self) -> queues.QueueCategory:
+        return queues.QueueCategory(self.api)
+
+    @property
+    def receiving(self) -> receiving.ReceivingCategory:
+        return receiving.ReceivingCategory(self.api)
+
+    @property
+    def sending(self) -> sending.SendingCategory:
+        return sending.SendingCategory(self.api)
+
+    @property
+    def service_methods(self) -> service_methods.ServiceMethodCategory:
+        return service_methods.ServiceMethodCategory(self.api)
+
+
+__all__ = ["APICategories"]
diff --git a/whatsapp_api_client_python/methods/__init__.py b/whatsapp_api_client_python/methods/__init__.py
new file mode 100644
index 0000000..a000fd0
--- /dev/null
+++ b/whatsapp_api_client_python/methods/__init__.py
@@ -0,0 +1,17 @@
+from whatsapp_api_client_python.methods.account import AccountCategory
+from whatsapp_api_client_python.methods.device import DeviceCategory
+from whatsapp_api_client_python.methods.groups import GroupCategory
+from whatsapp_api_client_python.methods.journals import JournalCategory
+from whatsapp_api_client_python.methods.mark_read import MarkReadCategory
+from whatsapp_api_client_python.methods.queues import QueueCategory
+from whatsapp_api_client_python.methods.receiving import ReceivingCategory
+
+__all__ = [
+    "AccountCategory",
+    "DeviceCategory",
+    "GroupCategory",
+    "JournalCategory",
+    "MarkReadCategory",
+    "QueueCategory",
+    "ReceivingCategory"
+]
diff --git a/whatsapp_api_client_python/methods/account.py b/whatsapp_api_client_python/methods/account.py
new file mode 100644
index 0000000..55e2b9c
--- /dev/null
+++ b/whatsapp_api_client_python/methods/account.py
@@ -0,0 +1,80 @@
+from pathlib import Path
+from typing import Optional
+
+from whatsapp_api_client_python.base import BaseCategory
+from whatsapp_api_client_python.response import Response
+
+
+class AccountCategory(BaseCategory):
+    def get_settings(self) -> Response:
+        """
+        The method is designed to get the current account settings.
+        """
+
+        return self.api.request("GET", "GetSettings")
+
+    def set_settings(
+            self,
+            countryInstance: Optional[str] = None,
+            webhookUrl: Optional[str] = None,
+            webhookUrlToken: Optional[str] = None,
+            delaySendMessagesMilliseconds: Optional[int] = None,
+            markIncomingMessagesReaded: Optional[str] = None,
+            markIncomingMessagesReadedOnReply: Optional[str] = None,
+            proxyInstance: Optional[str] = None,
+            outgoingWebhook: Optional[str] = None,
+            outgoingMessageWebhook: Optional[str] = None,
+            stateWebhook: Optional[str] = None,
+            incomingWebhook: Optional[str] = None,
+            deviceWebhook: Optional[str] = None,
+            statusInstanceWebhook: Optional[str] = None,
+            sendFromUTC: Optional[str] = None,
+            sendToUTC: Optional[str] = None,
+            sharedSession: Optional[str] = None
+    ) -> Response:
+        """The method is for setting account settings."""
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "SetSettings", data)
+
+    def set_system_proxy(self) -> Response:
+        """The method is for setting up a system proxy."""
+
+        return self.api.request("GET", "SetSystemProxy")
+
+    def get_state_instance(self) -> Response:
+        """The method is designed to get the state of the account."""
+
+        return self.api.request("GET", "getStateInstance")
+
+    def get_status_instance(self) -> Response:
+        """
+        The method is designed to get the socket connection state
+        of the account instance with WhatsApp.
+        """
+
+        return self.api.request("GET", "getStatusInstance")
+
+    def reboot(self) -> Response:
+        """The method is for restarting the account."""
+
+        return self.api.request("GET", "Reboot")
+
+    def logout(self) -> Response:
+        """The method is for logging out of the account."""
+
+        return self.api.request("GET", "Logout")
+
+    def qr(self) -> Response:
+        """The method is designed to get a QR code."""
+
+        return self.api.request("GET", "qr")
+
+    def set_profile_picture(self, file: str) -> Response:
+        """The method is for setting an account avatar."""
+
+        file_name = Path(file).name
+        files = {"file": (file_name, open(file, "rb"), "image/jpg")}
+
+        return self.api.request("POST", "setProfilePicture", files=files)
diff --git a/whatsapp_api_client_python/methods/device.py b/whatsapp_api_client_python/methods/device.py
new file mode 100644
index 0000000..3f16388
--- /dev/null
+++ b/whatsapp_api_client_python/methods/device.py
@@ -0,0 +1,12 @@
+from whatsapp_api_client_python.base import BaseCategory
+from whatsapp_api_client_python.response import Response
+
+
+class DeviceCategory(BaseCategory):
+    def get_device_info(self) -> Response:
+        """
+        The method is designed to get information
+        about the device (phone).
+        """
+
+        return self.api.request("GET", "GetDeviceInfo")
diff --git a/whatsapp_api_client_python/methods/groups.py b/whatsapp_api_client_python/methods/groups.py
new file mode 100644
index 0000000..964a485
--- /dev/null
+++ b/whatsapp_api_client_python/methods/groups.py
@@ -0,0 +1,90 @@
+from pathlib import Path
+from typing import List
+
+from whatsapp_api_client_python.base import BaseCategory
+from whatsapp_api_client_python.response import Response
+
+
+class GroupCategory(BaseCategory):
+    def create_group(self, groupName: str, chatIds: List[str]) -> Response:
+        """The method is designed to create a group chat."""
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "CreateGroup", data)
+
+    def update_group_name(self, groupId: str, groupName: str) -> Response:
+        """The method changes the name of the group chat."""
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "UpdateGroupName", data)
+
+    def get_group_data(self, groupId: str) -> Response:
+        """The method gets the group chat data."""
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "GetGroupData", data)
+
+    def add_group_participant(
+            self, groupId: str, participantChatId: str
+    ) -> Response:
+        """The method adds a participant to the group chat."""
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "AddGroupParticipant", data)
+
+    def remove_group_participant(
+            self, groupId: str, participantChatId: str
+    ) -> Response:
+        """The method removes the participant from the group chat."""
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "RemoveGroupParticipant", data)
+
+    def set_group_admin(
+            self, groupId: str, participantChatId: str
+    ) -> Response:
+        """
+        The method designates a member of a group chat
+        as an administrator.
+        """
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "SetGroupAdmin", data)
+
+    def remove_admin(self, groupId: str, participantChatId: str) -> Response:
+        """
+        The method deprives the participant of group chat
+        administration rights.
+        """
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "RemoveAdmin", data)
+
+    def set_group_picture(self, file: str, groupId: str) -> Response:
+        """The method sets the avatar of the group."""
+
+        data = self.handle_parameters(locals())
+
+        file_name = Path(file).name
+        files = {"file": (file_name, open(file, "rb"), "image/jpg")}
+
+        data.pop("file")
+
+        return self.api.request("POST", "setGroupPicture", data, files=files)
+
+    def leave_group(self, groupId: str) -> Response:
+        """
+        The method leaves the user of the current account
+        from the group chat.
+        """
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "LeaveGroup", data)
diff --git a/whatsapp_api_client_python/methods/journals.py b/whatsapp_api_client_python/methods/journals.py
new file mode 100644
index 0000000..dc20536
--- /dev/null
+++ b/whatsapp_api_client_python/methods/journals.py
@@ -0,0 +1,36 @@
+from typing import Optional
+
+from whatsapp_api_client_python.base import BaseCategory
+from whatsapp_api_client_python.response import Response
+
+
+class JournalCategory(BaseCategory):
+    def get_chat_history(
+            self, chatId: str, count: Optional[int] = None
+    ) -> Response:
+        """The method returns the chat message history."""
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "GetChatHistory", data)
+
+    def last_incoming_messages(
+            self, minutes: Optional[int] = None
+    ) -> Response:
+        """
+        The method returns the most recent incoming messages
+        of the account.
+        """
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("GET", "lastIncomingMessages", data)
+
+    def last_outgoing_messages(
+            self, minutes: Optional[int] = None
+    ) -> Response:
+        """The method returns the last sent messages of the account."""
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("GET", "LastOutgoingMessages", data)
diff --git a/whatsapp_api_client_python/methods/mark_read.py b/whatsapp_api_client_python/methods/mark_read.py
new file mode 100644
index 0000000..53c4eb2
--- /dev/null
+++ b/whatsapp_api_client_python/methods/mark_read.py
@@ -0,0 +1,15 @@
+from typing import Optional
+
+from whatsapp_api_client_python.base import BaseCategory
+from whatsapp_api_client_python.response import Response
+
+
+class MarkReadCategory(BaseCategory):
+    def read_chat(
+            self, chatId: str, idMessage: Optional[str] = None
+    ) -> Response:
+        """The method is designed to mark chat messages as read."""
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "ReadChat", data)
diff --git a/whatsapp_api_client_python/methods/queues.py b/whatsapp_api_client_python/methods/queues.py
new file mode 100644
index 0000000..023e34e
--- /dev/null
+++ b/whatsapp_api_client_python/methods/queues.py
@@ -0,0 +1,20 @@
+from whatsapp_api_client_python.base import BaseCategory
+from whatsapp_api_client_python.response import Response
+
+
+class QueueCategory(BaseCategory):
+    def show_messages_queue(self) -> Response:
+        """
+        The method is designed to get the list of messages
+        that are in the queue to be sent.
+        """
+
+        return self.api.request("GET", "ShowMessagesQueue")
+
+    def clear_messages_queue(self) -> Response:
+        """
+        The method is designed to clear the queue
+        of messages to be sent.
+        """
+
+        return self.api.request("GET", "ClearMessagesQueue")
diff --git a/whatsapp_api_client_python/methods/receiving.py b/whatsapp_api_client_python/methods/receiving.py
new file mode 100644
index 0000000..c3f56e2
--- /dev/null
+++ b/whatsapp_api_client_python/methods/receiving.py
@@ -0,0 +1,23 @@
+from whatsapp_api_client_python.base import BaseCategory
+from whatsapp_api_client_python.response import Response
+
+
+class ReceivingCategory(BaseCategory):
+    def receive_notification(self) -> Response:
+        """https://green-api.com/en/docs/api/receiving/technology-http-api/ReceiveNotification/"""
+
+        return self.api.request("GET", "ReceiveNotification")
+
+    def delete_notification(self, receiptId: int) -> Response:
+        """https://green-api.com/en/docs/api/receiving/technology-http-api/DeleteNotification/"""
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("DELETE", "DeleteNotification", data)
+
+    def download_file(self, chatId: str, idMessage: str) -> Response:
+        """https://green-api.com/en/docs/api/receiving/files/DownloadFile/"""
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("DELETE", "downloadFile", data)
diff --git a/whatsapp_api_client_python/methods/sending.py b/whatsapp_api_client_python/methods/sending.py
new file mode 100644
index 0000000..5d05aa3
--- /dev/null
+++ b/whatsapp_api_client_python/methods/sending.py
@@ -0,0 +1,163 @@
+import mimetypes
+import pathlib
+from typing import Dict, List, Optional, Union
+
+from whatsapp_api_client_python.base import BaseCategory
+from whatsapp_api_client_python.response import Response
+
+
+class SendingCategory(BaseCategory):
+    def send_message(
+            self,
+            chatId: str,
+            message: str,
+            quotedMessageId: Optional[str] = None,
+            archiveChat: Optional[bool] = None
+    ) -> Response:
+        """
+        The method is designed to send a text message
+        to a personal or group chat.
+        """
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "SendMessage", data)
+
+    def send_buttons(
+            self,
+            chatId: str,
+            message: str,
+            buttons: List[Dict[str, Union[int, str]]],
+            footer: Optional[str] = None,
+            quotedMessageId: Optional[str] = None,
+            archiveChat: Optional[bool] = None
+    ) -> Response:
+        """
+        The method is designed to send a message with buttons
+        to a personal or group chat.
+        """
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "SendButtons", data)
+
+    def send_template_buttons(
+            self,
+            chatId: str,
+            message: str,
+            templateButtons: List[Dict[str, Union[int, Dict[str, str]]]],
+            footer: Optional[str] = None,
+            quotedMessageId: Optional[str] = None,
+            archiveChat: Optional[bool] = None
+    ) -> Response:
+        """
+        The method is designed to send a message
+        with interactive buttons from the list
+        of templates to a personal or group chat.
+        """
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "sendTemplateButtons", data)
+
+    def send_list_message(
+            self,
+            chatId: str,
+            message: str,
+            sections: List[Dict[str, Union[str, List[Dict[str, str]]]]],
+            title: Optional[str] = None,
+            footer: Optional[str] = None,
+            buttonText: Optional[str] = None,
+            quotedMessageId: Optional[str] = None,
+            archiveChat: Optional[bool] = None
+    ) -> Response:
+        """
+        The method is designed to send a message
+        with a selection button from a list
+        of values to a personal or group chat.
+        """
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "SendListMessage", data)
+
+    def send_file_by_upload(
+            self,
+            chatId: str,
+            file: str,
+            fileName: Optional[str] = None,
+            caption: Optional[str] = None,
+            quotedMessageId: Optional[str] = None
+    ) -> Response:
+        """
+        The method is designed to send a file
+        loaded through a form (form-data).
+        """
+
+        data = self.handle_parameters(locals())
+
+        file_name = pathlib.Path(file).name
+        mime_type = mimetypes.guess_type(file_name)[0]
+        files = {"file": (file_name, open(file, "rb"), mime_type)}
+
+        data.pop("file")
+
+        return self.api.request("POST", "SendFileByUpload", data, files=files)
+
+    def send_file_by_url(
+            self,
+            chatId: str,
+            urlFile: str,
+            fileName: str,
+            caption: Optional[str] = None,
+            quotedMessageId: Optional[str] = None,
+            archiveChat: Optional[bool] = None
+    ) -> Response:
+        """The method is for sending a file downloaded from a link."""
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "SendFileByUrl", data)
+
+    def send_location(
+            self,
+            chatId: str,
+            latitude: float,
+            longitude: float,
+            nameLocation: Optional[str] = None,
+            address: Optional[str] = None,
+            quotedMessageId: Optional[str] = None
+    ) -> Response:
+        """The method is for sending a geolocation message."""
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "sendLocation", data)
+
+    def send_contact(
+            self,
+            chatId: str,
+            contact: Dict[str, Union[int, str]],
+            quotedMessageId: Optional[str] = None
+    ) -> Response:
+        """The method is for sending a message with a contact."""
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "sendContact", data)
+
+    def send_link(
+            self,
+            chatId: str,
+            urlLink: str,
+            quotedMessageId: Optional[str] = None
+    ) -> Response:
+        """
+        The method is designed to send a message
+        with a link that will add an image preview,
+        title and description.
+        """
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "sendLink", data)
diff --git a/whatsapp_api_client_python/methods/service_methods.py b/whatsapp_api_client_python/methods/service_methods.py
new file mode 100644
index 0000000..5391fde
--- /dev/null
+++ b/whatsapp_api_client_python/methods/service_methods.py
@@ -0,0 +1,76 @@
+from typing import Optional
+
+from whatsapp_api_client_python.base import BaseCategory
+from whatsapp_api_client_python.response import Response
+
+
+class ServiceMethodCategory(BaseCategory):
+    def check_whatsapp(self, phoneNumber: int) -> Response:
+        """
+        The method checks if there is a WhatsApp account
+        on the phone number.
+        """
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "CheckWhatsapp", data)
+
+    def get_avatar(self, chatId: str) -> Response:
+        """
+        The method returns the avatar of the correspondent or
+        group chat.
+        """
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "GetAvatar", data)
+
+    def get_contacts(self) -> Response:
+        """
+        The method is designed to get the list of contacts
+        of the current account.
+        """
+
+        return self.api.request("GET", "GetContacts")
+
+    def get_contact_info(self, chatId: str) -> Response:
+        """
+        The method is designed to get information about the contact.
+        """
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "getContactInfo", data)
+
+    def delete_message(self, chatId: str, idMessage: str) -> Response:
+        """The method deletes the message from the chat."""
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "deleteMessage", data)
+
+    def archive_chat(self, chatId: str) -> Response:
+        """The method archives the chat."""
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "archiveChat", data)
+
+    def unarchive_chat(self, chatId: str) -> Response:
+        """The method unarchives the chat."""
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "unarchiveChat", data)
+
+    def set_disappearing_chat(
+            self, chatId: str, ephemeralExpiration: Optional[int] = None
+    ) -> Response:
+        """
+        The method is designed to change the settings
+        of disappearing messages in chats.
+        """
+
+        data = self.handle_parameters(locals())
+
+        return self.api.request("POST", "setDisappearingChat", data)
diff --git a/whatsapp_api_client_python/response.py b/whatsapp_api_client_python/response.py
index 063b49d..fbc768c 100644
--- a/whatsapp_api_client_python/response.py
+++ b/whatsapp_api_client_python/response.py
@@ -1,16 +1,15 @@
 import json
+import typing
 
 
 class Response:
-    code: int
-    data: json
-    error: str
+    data: typing.Optional[typing.Union[dict, list]] = None
+    error: typing.Optional[str] = None
+    status_code: int
 
-    def __init__(self, code: int, text: str) -> None:
-        self.code = code
-        if code == 200:
+    def __init__(self, status_code: int, text: str) -> None:
+        self.status_code = status_code
+        if status_code == 200:
             self.data = json.loads(text)
-            self.error = None
         else:
             self.error = text
-            self.data = None
\ No newline at end of file
diff --git a/whatsapp_api_client_python/tools/__init__.py b/whatsapp_api_client_python/tools/__init__.py
index e69de29..9856c6f 100644
--- a/whatsapp_api_client_python/tools/__init__.py
+++ b/whatsapp_api_client_python/tools/__init__.py
@@ -0,0 +1,3 @@
+from whatsapp_api_client_python.tools.webhook import Webhook
+
+__all__ = ["Webhook"]
diff --git a/whatsapp_api_client_python/tools/account.py b/whatsapp_api_client_python/tools/account.py
deleted file mode 100644
index a987412..0000000
--- a/whatsapp_api_client_python/tools/account.py
+++ /dev/null
@@ -1,86 +0,0 @@
-import os.path
-from whatsapp_api_client_python.response import Response
-
-
-class Account:
-    def __init__(self, greenApi) -> None:
-        self.greenApi = greenApi
-        
-    def getSettings(self) -> Response:
-            'The method is aimed for getting the '\
-            'current account settings.'
-            
-            return self.greenApi.request('GET', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/getSettings/{{apiTokenInstance}}')
-            
-    def getStateInstance(self) -> Response:
-            'The method is aimed for getting the account state.'
-            
-            return self.greenApi.request('GET', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/getStateInstance/{{apiTokenInstance}}')
-
-    def getStatusInstance(self) -> Response:
-            'The method is aimed for getting the status of the account instance '\
-            'socket connection with WhatsApp.'
-            
-            return self.greenApi.request('GET', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/getStatusInstance/{{apiTokenInstance}}')
-
-    def logout(self) -> Response:
-            'The method is aimed for logging out an account.'
-            
-            return self.greenApi.request('GET', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/Logout/{{apiTokenInstance}}')
-
-    def qr(self) -> Response:
-            'The method is aimed for getting QR code. To authorize your account, '\
-            'you have to scan a QR code from application WhatsApp Business'\
-            'on your phone. You can also get a QR code and authorize your'\
-            'account in your profile.'
-            
-            return self.greenApi.request('GET', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/QR/{{apiTokenInstance}}')
-
-    def reboot(self) -> Response:
-            'The method is aimed for rebooting an account.'
-            
-            return self.greenApi.request('GET', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/Reboot/{{apiTokenInstance}}')
-
-    def setProfilePicture(self, path) -> Response:
-            'The method is aimed for setting an account picture.'
-
-            pathParts = os.path.split(path)
-            file = pathParts[1]
-
-            files = [
-                ('file',(file, open(path,'rb'),'image/jpeg'))
-            ]
-            
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/SetProfilePicture/{{apiTokenInstance}}', None, files)
-
-    def setSettings(self, requestBody) -> Response:
-            'The method is aimed for setting account settings. '\
-            'When this method is requested, the account is rebooted.'
-            
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/SetSettings/{{apiTokenInstance}}',
-                requestBody)
-
-    def setSettings(self) -> Response:
-            'The method is aimed for setting a system proxy. '\
-            'Use the method when you need to reset custom proxy '\
-            'settings to system ones.'
-            
-            return self.greenApi.request('GET', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/SetSystemProxy/{{apiTokenInstance}}')
\ No newline at end of file
diff --git a/whatsapp_api_client_python/tools/device.py b/whatsapp_api_client_python/tools/device.py
deleted file mode 100644
index ed7e960..0000000
--- a/whatsapp_api_client_python/tools/device.py
+++ /dev/null
@@ -1,14 +0,0 @@
-from whatsapp_api_client_python.response import Response
-
-
-class Device:
-    def __init__(self, greenApi) -> None:
-        self.greenApi = greenApi
-        
-    def getDeviceInfo(self) -> Response:
-            'The method is aimed for getting information about the device '\
-            '(phone) running WhatsApp Business application.'
-            
-            return self.greenApi.request('GET', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/GetDeviceInfo/{{apiTokenInstance}}')
\ No newline at end of file
diff --git a/whatsapp_api_client_python/tools/groups.py b/whatsapp_api_client_python/tools/groups.py
deleted file mode 100644
index b2532b7..0000000
--- a/whatsapp_api_client_python/tools/groups.py
+++ /dev/null
@@ -1,140 +0,0 @@
-from array import ArrayType, array
-import os.path
-from whatsapp_api_client_python.response import Response
-
-
-class Groups:
-    def __init__(self, greenApi) -> None:
-        self.greenApi = greenApi
-        
-    def addGroupParticipant(self, 
-            groupId: str, 
-            participantChatId: str) -> Response:
-            'The method adds a participant to a group chat.'
-
-            requestBody = {
-                'groupId': groupId,
-                'participantChatId': participantChatId,
-            }
-            
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/AddGroupParticipant/{{apiTokenInstance}}',
-                requestBody)
-
-    def createGroup(self, groupName: str, chatIds: array) -> Response:
-            'The method is aimed for creating a group chat.'
-            
-            requestBody = {
-                'groupName': groupName,
-                'chatIds': chatIds
-            }
-
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/CreateGroup/{{apiTokenInstance}}',
-                requestBody)
-
-    def getGroupData(self, groupId: str) -> Response:
-            'The method gets group chat data.'
-
-            requestBody = {
-                'groupId': groupId
-            }
-            
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/GetGroupData/{{apiTokenInstance}}',
-                requestBody)
-
-    def leaveGroup(self, groupId: str) -> Response:
-            'The method makes the current account user leave the group chat.'
-
-            requestBody = {
-                'groupId': groupId
-            }
-            
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/LeaveGroup/{{apiTokenInstance}}',
-                requestBody)
-
-    def removeAdmin(self, groupId: str, participantChatId: str) -> Response:
-            'The method removes a participant from group chat '\
-            'administartion rights.'
-
-            requestBody = {
-                'groupId': groupId,
-                'participantChatId': participantChatId
-            }
-            
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/RemoveAdmin/{{apiTokenInstance}}',
-                requestBody)
-
-    def removeGroupParticipant(self, 
-        groupId: str, 
-        participantChatId: str) -> Response:
-            'The method removes a participant from a group chat.'
-
-            requestBody = {
-                'groupId': groupId,
-                'participantChatId': participantChatId
-            }
-            
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/RemoveGroupParticipant/{{apiTokenInstance}}',
-                requestBody)
-
-    def setGroupAdmin(self, 
-        groupId: str, 
-        participantChatId: str) -> Response:
-            'The method sets a group chat participant as an administrator.'
-
-            requestBody = {
-                'groupId': groupId,
-                'participantChatId': participantChatId
-            }
-            
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/SetGroupAdmin/{{apiTokenInstance}}',
-                requestBody)
-
-    def setGroupPicture(self, 
-        groupId: str, 
-        path: str) -> Response:
-            'The method sets a group picture.'
-
-            requestBody = {
-                'groupId': groupId
-            }
-
-            pathParts = os.path.split(path)
-            file = pathParts[1]
-
-            files = [
-                ('file',(file, open(path,'rb'),'image/jpeg'))
-            ]
-            
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/SetGroupPicture/{{apiTokenInstance}}',
-                requestBody, files)
-
-    def updateGroupName(self, 
-        groupId: str, 
-        groupName: str) -> Response:
-            'The method changes a group chat name.'
-
-            requestBody = {
-                'groupId': groupId,
-                'groupName': groupName
-            }
-            
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/UpdateGroupName/{{apiTokenInstance}}',
-                requestBody)
\ No newline at end of file
diff --git a/whatsapp_api_client_python/tools/journals.py b/whatsapp_api_client_python/tools/journals.py
deleted file mode 100644
index 28f3afc..0000000
--- a/whatsapp_api_client_python/tools/journals.py
+++ /dev/null
@@ -1,33 +0,0 @@
-from whatsapp_api_client_python.response import Response
-
-class Journals:
-    def __init__(self, greenApi) -> None:
-        self.greenApi = greenApi
-        
-    def getChatHistory(self, chatId: str, count: str) -> Response:
-            'The method returns the chat message history.'
-
-            requestBody = {
-                'chatId': chatId,
-                'count': count,
-            }
-
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/GetChatHistory/{{apiTokenInstance}}',
-                requestBody)
-
-    def lastIncomingMessages(self) -> Response:
-            'The method returns the chat message history.'
-
-            return self.greenApi.request('GET', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/LastIncomingMessages/{{apiTokenInstance}}')
-
-    def lastOutgoingMessages(self) -> Response:
-            'The method returns the last outgoing messages of the account.'
-            'Outgoing messages are stored on the server for 24 hours.'
-
-            return self.greenApi.request('GET', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/LastOutgoingMessages/{{apiTokenInstance}}')
\ No newline at end of file
diff --git a/whatsapp_api_client_python/tools/marking.py b/whatsapp_api_client_python/tools/marking.py
deleted file mode 100644
index 20ab77f..0000000
--- a/whatsapp_api_client_python/tools/marking.py
+++ /dev/null
@@ -1,19 +0,0 @@
-from whatsapp_api_client_python.response import Response
-
-
-class Marking:
-    def __init__(self, greenApi) -> None:
-        self.greenApi = greenApi
-        
-    def readChat(self, chatId: str, idMessage: str) -> Response:
-            'The method returns the chat message history.'
-
-            requestBody = {
-                'chatId': chatId,
-                'idMessage': idMessage,
-            }
-
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/ReadChat/{{apiTokenInstance}}',
-                requestBody)
\ No newline at end of file
diff --git a/whatsapp_api_client_python/tools/queues.py b/whatsapp_api_client_python/tools/queues.py
deleted file mode 100644
index 9474a6f..0000000
--- a/whatsapp_api_client_python/tools/queues.py
+++ /dev/null
@@ -1,22 +0,0 @@
-from whatsapp_api_client_python.response import Response
-
-
-class Queues:
-    def __init__(self, greenApi) -> None:
-        self.greenApi = greenApi
-        
-    def clearMessagesQueue(self) -> Response:
-            'The method is aimed for clearing the queue of messages to be sent.'
-
-            return self.greenApi.request('GET', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/ClearMessagesQueue/{{apiTokenInstance}}')
-
-    def showMessagesQueue(self) -> Response:
-            'The method is aimed for getting a list of messages in the queue '\
-            'to be sent. Messages sending rate is managed by Messages sending '\
-            'delay parameter.'
-
-            return self.greenApi.request('GET', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/ShowMessagesQueue/{{apiTokenInstance}}')
\ No newline at end of file
diff --git a/whatsapp_api_client_python/tools/receiving.py b/whatsapp_api_client_python/tools/receiving.py
deleted file mode 100644
index 83a95c2..0000000
--- a/whatsapp_api_client_python/tools/receiving.py
+++ /dev/null
@@ -1,63 +0,0 @@
-from whatsapp_api_client_python.response import Response
-
-
-class Receiving:
-    def __init__(self, greenApi) -> None:
-        self.greenApi = greenApi
-        
-    def downloadFile(self, idMessage: str) -> Response:
-        'The method is aimed for downloading incoming and outgoing files. '\
-        'Links to incoming files are transmitted in Incoming messages, '\
-        'and you can also get them using LastIncomingMessages method. '\
-        'You can get links to outgoing files using '\
-        'LastOutgoingMessages method.'\
-        'Files storage period and, accordingly, the capability '\
-        'to download them is limited to 24 hours.'
-
-        requestBody = {
-            'idMessage': idMessage,
-        }
-
-        return self.greenApi.request('POST', 
-            '{{host}}/waInstance{{idInstance}}'
-            '/DownloadFile/{{apiTokenInstance}}',
-            requestBody)
-
-    def receiveNotification(self) -> Response:
-        'The method is aimed for receiving one incoming notification from '\
-        'the notifications queue. '\
-        'ReceiveNotification method waits for a notification receipt '\
-        'for 20 sec. The method call ends with an empty response if a timeout '\
-        'is reached. If a notification comes to the queue within 20 seconds, '\
-        'the method call is completed, and the method returns the received '\
-        'notification.'\
-        'After receiving and processing an incoming notification, you need '\
-        'to delete the notification from the queue. This requires you to run '\
-        'DeleteNotification method. After calling DeleteNotification method, '\
-        'the notification will be considered received and processed and '\
-        'will be permanently deleted from the queue. Therefore, the next call '\
-        'of ReceiveNotification method will return the next notification from '\
-        'the queue in the order in which notifications come to the queue.'\
-        'Incoming notifications are stored in the queue for 24 hours. '\
-        'Notifications are sent from the queue in FIFO order'
-
-        return self.greenApi.request('GET', 
-            '{{host}}/waInstance{{idInstance}}'
-            '/ReceiveNotification/{{apiTokenInstance}}')
-
-    def deleteNotification(self, receiptId: int) -> Response:
-        'The method is aimed for deleting an incoming notification from '\
-        'the notification queue. To specify what notification to delete, '\
-        'use receiptId parameter. After receiving and processing an incoming '\
-        'notification, you need to delete the notification from the queue. '\
-        'This requires you to run this method. After calling the method, '\
-        'the notification will be considered received and processed and '\
-        'will be permanently deleted from the queue. Therefore, the next call '\
-        'of ReceiveNotification method will return the next notification from '\
-        'the queue in the order in which notifications come to the queue.'\
-        'Incoming notifications are stored in the queue for 24 hours.'\
-        'Notifications are sent from the queue in FIFO order'
-
-        return self.greenApi.request('DELETE', 
-            '{{host}}/waInstance{{idInstance}}'
-            '/DeleteNotification/{{apiTokenInstance}}/' + str(receiptId))
\ No newline at end of file
diff --git a/whatsapp_api_client_python/tools/sending.py b/whatsapp_api_client_python/tools/sending.py
deleted file mode 100644
index 41ca953..0000000
--- a/whatsapp_api_client_python/tools/sending.py
+++ /dev/null
@@ -1,283 +0,0 @@
-from array import array
-import os.path
-import mimetypes
-from whatsapp_api_client_python.response import Response
-
-
-class Sending:
-    def __init__(self, greenApi) -> None:
-        self.greenApi = greenApi
-        
-    def sendButtons(self, chatId: str, message: str, footer: str,
-                    buttons: array, quotedMessageId: str = None, 
-                    archiveChat: bool = None) -> Response:
-            'The method is aimed for sending a button message to a personal '\
-            'or a group chat. The message will be added to the send queue. '\
-            'Checking whatsapp authorization on the phone (i.e. availability '\
-            'in linked devices) is not performed. The message will be kept '\
-            'for 24 hours in the queue and will be sent immediately after '\
-            'phone authorization. The rate at which messages are sent from '\
-            'the queue is managed by Message sending delay parameter.'
-
-            requestBody = {
-                'chatId': chatId,
-                'message': message,
-                'footer': footer,
-                'buttons': buttons,
-            }
-
-            if quotedMessageId != None:
-                requestBody['quotedMessageId'] = quotedMessageId
-            if archiveChat != None:
-                requestBody['archiveChat'] = archiveChat
-
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/SendButtons/{{apiTokenInstance}}',
-                requestBody)
-
-    def sendContact(self, chatId: str, contact: object,
-                    quotedMessageId: str = None) -> Response:
-            'The method is aimed for sending a contact message. '\
-            'Contact visit card is created and sent to a chat. '\
-            'The message will be added to the send queue. '\
-            'Linked device not required when sending. '\
-            'Messages will be kept for 24 hours in the queue until account '\
-            'will be authorized The rate at which messages are sent from '\
-            'the queue is managed by Message sending delay parameter.'
-
-            requestBody = {
-                'chatId': chatId,
-                'contact': contact
-            }
-
-            if quotedMessageId != None:
-                requestBody['quotedMessageId'] = quotedMessageId
-
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/SendContact/{{apiTokenInstance}}',
-                requestBody)
-
-    def sendFileByUpload(self, chatId: str, path: str,
-                    fileName: str = None,
-                    caption: str = None,
-                    quotedMessageId: str = None) -> Response:
-            'The method is aimed for sending a file uploaded by form '\
-            '(form-data). The message will be added to the send queue. '\
-            'The rate at which messages are sent from the queue is managed '\
-            'by Message sending delay parameter.'\
-            'Video, audio and image files available for viewing and listening '\
-            'to are sent as in native-mode WhatsApp. Documents are sent in '\
-            'the same way as in native-mode WhatsApp. Outgoing file type and '\
-            'send method is determined by the file extension. '\
-            'Description is only added to images and video.'\
-            'The maximum size of outgoing files is 37 MB.'
-
-            pathParts = os.path.split(path)
-            if fileName == None:
-                fileName = pathParts[pathParts.count - 1]
-
-            mimeType = mimetypes.guess_type(path)[0]
-
-            files = [
-                ('file', (fileName, open(path,'rb'), mimeType))
-            ]
-
-            requestBody = {
-                'chatId': chatId,
-                'fileName': fileName
-            }
-
-            if caption != None:
-                requestBody['caption'] = caption
-
-            if quotedMessageId != None:
-                requestBody['quotedMessageId'] = quotedMessageId
-
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/SendFileByUpload/{{apiTokenInstance}}',
-                requestBody, files = files)
-
-    def sendFileByUrl(self, chatId: str, urlFile: str,
-                    fileName: str = None,
-                    caption: str = None,
-                    quotedMessageId: str = None,
-                    archiveChat: bool = None) -> Response:
-            'The method is aimed for sending a file uploaded by Url '\
-            'The message will be added to the send queue. '\
-            'The rate at which messages are sent from the queue is managed '\
-            'by Message sending delay parameter.'\
-            'Video, audio and image files available for viewing and listening '\
-            'to are sent as in native-mode WhatsApp. Documents are sent in '\
-            'the same way as in native-mode WhatsApp. Outgoing file type and '\
-            'send method is determined by the file extension. '\
-            'Description is only added to images and video.'\
-            'The maximum size of outgoing files is 37 MB.'
-
-            requestBody = {
-                'chatId': chatId,
-                'urlFile': urlFile,
-                'fileName': fileName
-            }
-
-            if caption != None:
-                requestBody['caption'] = caption
-
-            if quotedMessageId != None:
-                requestBody['quotedMessageId'] = quotedMessageId
-
-            if archiveChat != None:
-                requestBody['archiveChat'] = archiveChat
-
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/SendFileByUrl/{{apiTokenInstance}}',
-                requestBody)
-
-    def sendLink(self, chatId: str, urlLink: str,
-                    quotedMessageId: str = None) -> Response:
-            'The method is aimed for sending a message with a link, by which '\
-            'an image preview, title and description will be added. '\
-            'Linked device not required when sending. Messages will be kept '\
-            'for 24 hours in the queue until account will be authorized '\
-            'Image, title and description are obtained from Open Graph page '\
-            'template being linked to. The message will be added to the send '\
-            'queue. The rate at which messages are sent from the queue is '\
-            'managed by Messages sending delay parameter.'
-
-            requestBody = {
-                'chatId': chatId,
-                'urlLink': urlLink
-            }
-
-            if quotedMessageId != None:
-                requestBody['quotedMessageId'] = quotedMessageId
-
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/SendLink/{{apiTokenInstance}}',
-                requestBody)
-
-    def sendListMessage(self, chatId: str, message: str, sections: array,
-                    title: str = None,
-                    footer: str = None,
-                    buttonText: str = None,
-                    quotedMessageId: str = None,
-                    archiveChat: str = None) -> Response:
-            'The method is aimed for sending a message with a select button '\
-            'from a list of values to a personal or a group chat. '\
-            'The message will be added to the send queue. Checking whatsapp '\
-            'authorization on the phone (i.e. availability in linked devices) '\
-            'is not performed. The message will be kept for 24 hours in the '\
-            'queue and will be sent immediately after phone authorization. '\
-            'The rate at which messages are sent from the queue is managed by '\
-            'Message sending delay parameter.'
-
-            requestBody = {
-                'chatId': chatId,
-                'message': message,
-                'sections': sections
-            }
-
-            if title != None:
-                requestBody['title'] = title
-            if footer != None:
-                requestBody['footer'] = footer
-            if buttonText != None:
-                requestBody['buttonText'] = buttonText
-            if quotedMessageId != None:
-                requestBody['quotedMessageId'] = quotedMessageId 
-            if archiveChat != None:
-                requestBody['archiveChat'] = archiveChat
-
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/SendListMessage/{{apiTokenInstance}}',
-                requestBody)
-
-    def sendLocation(self, chatId: str, latitude: float, longitude: float,
-                    nameLocation: str = None,
-                    address: str = None,
-                    quotedMessageId: str = None) -> Response:
-            'The method is aimed for sending location message. The message '\
-            'will be added to the send queue. Linked device not required '\
-            'when sending. Messages will be kept for 24 hours in the queue '\
-            'until account will be authorized The rate at which messages are '\
-            'sent from the queue is managed by Message sending delay parameter.'
-
-            requestBody = {
-                'chatId': chatId,
-                'latitude': latitude,
-                'longitude': longitude
-            }
-
-            if nameLocation != None:
-                requestBody['nameLocation'] = nameLocation
-            if address != None:
-                requestBody['address'] = address
-            if quotedMessageId != None:
-                requestBody['quotedMessageId'] = quotedMessageId 
-
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/SendLocation/{{apiTokenInstance}}',
-                requestBody)
-
-    def sendMessage(self, chatId: str, message: str,
-                    quotedMessageId: str = None,
-                    archiveChat: str = None) -> Response:
-            'The method is aimed for sending a text message to a personal or '\
-            'a group chat. The message will be added to the send queue. '\
-            'Linked device not required when sending. Messages will be kept '\
-            'for 24 hours in the queue until account will be authorized '\
-            'The rate at which messages are sent from the queue is managed '\
-            'by Message sending delay parameter.'
-
-            requestBody = {
-                'chatId': chatId,
-                'message': message
-            }
-
-            if quotedMessageId != None:
-                requestBody['quotedMessageId'] = quotedMessageId
-            if archiveChat != None:
-                requestBody['archiveChat'] = archiveChat 
-
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/SendMessage/{{apiTokenInstance}}',
-                requestBody)
-
-    def sendTemplateButtons(self, chatId: str, message: str,
-                    templateButtons: array,
-                    footer: str = None,
-                    quotedMessageId: str = None,
-                    archiveChat: str = None) -> Response:
-            'The method is aimed for sending a message with template list '\
-            'interacrive buttons to a personal or a group chat. The message '\
-            'will be added to the send queue. Checking whatsapp authorization '\
-            'on the phone (i.e. availability in linked devices) '\
-            'is not performed. The message will be kept for 24 hours in the '\
-            'queue and will be sent immediately after phone authorization. '\
-            'The rate at which messages are sent from the queue is managed '\
-            'by Message sending delay parameter.'
-
-            requestBody = {
-                'chatId': chatId,
-                'message': message,
-                'templateButtons': templateButtons
-            }
-
-            if footer != None:
-                requestBody['footer'] = footer
-            if quotedMessageId != None:
-                requestBody['quotedMessageId'] = quotedMessageId
-            if archiveChat != None:
-                requestBody['archiveChat'] = archiveChat 
-
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/SendTemplateButtons/{{apiTokenInstance}}',
-                requestBody)
\ No newline at end of file
diff --git a/whatsapp_api_client_python/tools/serviceMethods.py b/whatsapp_api_client_python/tools/serviceMethods.py
deleted file mode 100644
index 42bc101..0000000
--- a/whatsapp_api_client_python/tools/serviceMethods.py
+++ /dev/null
@@ -1,113 +0,0 @@
-from whatsapp_api_client_python.response import Response
-
-
-class ServiceMethods:
-    def __init__(self, greenApi) -> None:
-        self.greenApi = greenApi
-        
-    def checkWhatsapp(self, phoneNumber: int) -> Response:
-            'The method checks WhatsApp account availability on a phone number.'
-
-            requestBody = {
-                'phoneNumber': phoneNumber
-            }
-
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/CheckWhatsapp/{{apiTokenInstance}}',
-                requestBody)
-
-    def getAvatar(self, chatId: str) -> Response:
-            'The method returns a user or a group chat avatar.'
-
-            requestBody = {
-                'chatId': chatId
-            }
-
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/GetAvatar/{{apiTokenInstance}}',
-                requestBody)
-
-    def getContactInfo(self, chatId: str) -> Response:
-            'The method is aimed for getting information on a contact.'
-
-            requestBody = {
-                'chatId': chatId
-            }
-
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/GetContactInfo/{{apiTokenInstance}}',
-                requestBody)
-
-    def getContacts(self, chatId: str) -> Response:
-            'The method is aimed for getting a list of the current account '\
-            'contacts. Sends contacts of all recipients whom the account '\
-            'connected with. Parameter "contact name" "name" takes on '\
-            'a value based on the below criteria: '\
-            'If the account is recorded in the phonebook, then we get the '\
-            'name from the book; '\
-            'If the account is not recorded in the phonebook, then we get '\
-            'the name from WhatsApp account;'\
-            'If the account is not recorded in the phone book and WhatsApp '\
-            'account name is not assigned, then we get an empty field.'
-
-            return self.greenApi.request('GET', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/GetContacts/{{apiTokenInstance}}')
-
-    def archiveChat(self, chatId: str) -> Response:
-            'The method archives a chat. You can archive chats that have at '\
-            'least one incoming message.'
-
-            requestBody = {
-                'chatId': chatId
-            }
-
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/ArchiveChat/{{apiTokenInstance}}',
-                requestBody)
-
-    def deleteMessage(self, chatId: str, idMessage: str) -> Response:
-            'The method deletes a message from a chat.'
-
-            requestBody = {
-                'chatId': chatId,
-                'idMessage': idMessage
-            }
-
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/DeleteMessage/{{apiTokenInstance}}',
-                requestBody)
-
-    def unarchiveChat(self, chatId: str) -> Response:
-            'The method deletes a message from a chat.'
-
-            requestBody = {
-                'chatId': chatId
-            }
-
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/UnarchiveChat/{{apiTokenInstance}}',
-                requestBody)
-
-    def setDisappearingChat(self, chatId: str, 
-                            ephemeralExpiration: int) -> Response:
-            'The method is aimed for changing settings of disappearing '\
-            'messages in chats. The standard settings of the application '\
-            'are used: 0 (off), 86400 (24 hours), '\
-            '604800 (7 days), 7776000 (90 days).'
-
-            requestBody = {
-                'chatId': chatId,
-                'ephemeralExpiration': ephemeralExpiration
-            }
-
-            return self.greenApi.request('POST', 
-                '{{host}}/waInstance{{idInstance}}'
-                '/SetDisappearingChat/{{apiTokenInstance}}',
-                requestBody)
\ No newline at end of file
diff --git a/whatsapp_api_client_python/tools/webhook.py b/whatsapp_api_client_python/tools/webhook.py
new file mode 100644
index 0000000..da0527a
--- /dev/null
+++ b/whatsapp_api_client_python/tools/webhook.py
@@ -0,0 +1,31 @@
+from typing import Any, Callable, Union
+
+from whatsapp_api_client_python.api import GreenAPI
+
+
+class Webhook:
+    def __init__(self, api: GreenAPI):
+        self.api = api
+
+    def run_forever(self, handler: Callable[[str, Union[dict, list]], Any]):
+        print("Start receiving notifications. To interrupt, press Ctrl+C")
+
+        while True:
+            try:
+                response = self.api.receiving.receive_notification()
+                if response.status_code == 200:
+                    if response.data is None:
+                        continue
+
+                    body = response.data["body"]
+                    type_webhook = body["typeWebhook"]
+
+                    handler(type_webhook, body)
+
+                    self.api.receiving.delete_notification(
+                        response.data["receiptId"]
+                    )
+            except KeyboardInterrupt:
+                print("KeyboardInterrupt")
+
+                break
diff --git a/whatsapp_api_client_python/tools/webhooks.py b/whatsapp_api_client_python/tools/webhooks.py
deleted file mode 100644
index 925d0f8..0000000
--- a/whatsapp_api_client_python/tools/webhooks.py
+++ /dev/null
@@ -1,33 +0,0 @@
-class Webhooks:
-    def __init__(self, greenApi) -> None:
-        self.greenApi = greenApi
-        self.started = False
-
-    def startReceivingNotifications(self, onEvent) -> bool:
-        self.started = True
-        self.job(onEvent)
-
-    def stopReceivingNotifications(self) -> bool:
-        self.started = False
-
-    
-    def job(self, onEvent) -> None:
-        print('Incoming notifications are being received. '\
-        'To interrupt, press Ctrl+C')
-        try:
-            while self.started == True:
-                resultReceive = self.greenApi.receiving.receiveNotification()
-                if resultReceive.code == 200:
-                    if resultReceive.data == None:
-                        # There are no incoming notifications, 
-                        # we send the request again
-                        continue
-                    body = resultReceive.data['body']
-                    typeWebhook = body['typeWebhook']
-                    onEvent(typeWebhook, body)    
-                    self.greenApi.receiving.deleteNotification(
-                        resultReceive.data['receiptId'])
-            print('End receiving')
-        except KeyboardInterrupt:
-            print('End receiving')
-            pass
\ No newline at end of file


Test patch:
diff --git a/tests/test_library.py b/tests/test_library.py
new file mode 100644
index 0000000..9a15257
--- /dev/null
+++ b/tests/test_library.py
@@ -0,0 +1,25 @@
+import unittest
+from os import environ
+
+from whatsapp_api_client_python import GreenAPI
+
+ID_INSTANCE = environ["ID_INSTANCE"]
+API_TOKEN_INSTANCE = environ["API_TOKEN_INSTANCE"]
+
+greenAPI = GreenAPI(ID_INSTANCE, API_TOKEN_INSTANCE)
+
+
+class GreenAPITestCase(unittest.TestCase):
+    def test_getSettings(self):
+        response = greenAPI.account.get_settings()
+
+        self.assertEqual(response.status_code, 200, response.error)
+
+    def test_getStateInstance(self):
+        response = greenAPI.account.get_state_instance()
+
+        self.assertEqual(response.status_code, 200, response.error)
+
+
+if __name__ == '__main__':
+    unittest.main()
diff --git a/tests/test_main.py b/tests/test_main.py
deleted file mode 100644
index f360369..0000000
--- a/tests/test_main.py
+++ /dev/null
@@ -1,29 +0,0 @@
-from os import environ
-
-from whatsapp_api_client_python import API as API
-
-
-ID_INSTANCE = environ['ID_INSTANCE']
-API_TOKEN_INSTANCE = environ['API_TOKEN_INSTANCE']
-
-greenAPI = API.GreenApi(ID_INSTANCE, API_TOKEN_INSTANCE)
-
-class TestClass: 
-        def test_getSettings(self):            
-                result = greenAPI.account.getSettings()
-                if result.code != 200:
-                        print(result.error)
-                assert isinstance(result, API.Response) and result.code == 200
-
-        def test_getStateInstance(self):            
-                result = greenAPI.account.getStateInstance()
-                if result.code != 200:
-                        print(result.error)
-                assert isinstance(result, API.Response) and result.code == 200
-
-def main():
-        TestClass.test_getSettings(TestClass)
-        TestClass.test_getStateInstance(TestClass)
-
-if __name__ == "__main__":
-    main()
\ No newline at end of file