easy-telegram-mtproto
Advanced tools
Comparing version 1.0.0 to 1.0.1
{ | ||
"name": "easy-telegram-mtproto", | ||
"version": "1.0.0", | ||
"version": "1.0.1", | ||
"description": "Telegram Client API wrapper for telegram-mtproto", | ||
@@ -5,0 +5,0 @@ "main": "telegram-client.js", |
@@ -5,3 +5,3 @@ # Easy Telegram Mtproto | ||
### Install | ||
``nom install easy-telegram-mtproto`` | ||
```npm install easy-telegram-mtproto``` | ||
@@ -56,3 +56,3 @@ ### Examples | ||
- ``TelegramClient (apiId, apiHash, name, getPhone, getCode, getRandomMessageId, storageFolder)`` | ||
- ```TelegramClient (apiId, apiHash, name, getPhone, getCode, getRandomMessageId, storageFolder)``` | ||
- apiId and apiHash you can get from [telegram website](https://my.telegram.org/auth?to=apps). | ||
@@ -63,11 +63,11 @@ - name is needed to save login keys. | ||
- storageFolder to save login keys. | ||
- ``async asInputPeer (...args)`` converts chat object to InputPeer | ||
- ``async login ()`` logs in telegram if was not logged in before | ||
- ``async getChats ()`` returns list of all chats (max 1000) | ||
- ``async getAndSaveChatsData (jsonFileName = 'chats.json', txtFileName = 'chats.txt')`` gets short chats data and saves it to file | ||
- ``async chatHistory (chat)`` reads all history from chat | ||
- ``async forwardMessages (from, to, messages)`` forwardes messages from on chat to another | ||
- ``async deleteMessagesFromChannel (from, messages)`` deletes selected message from channel or supergroup | ||
- ``async sendMessage (target, message)`` sends message to chat | ||
- ``async call (...args)`` calls custom API method [list of methods](https://core.telegram.org/methods) | ||
- ```async asInputPeer (...args)``` converts chat object to InputPeer | ||
- ```async login ()``` logs in telegram if was not logged in before | ||
- ```async getChats ()``` returns list of all chats (max 1000) | ||
- ```async getAndSaveChatsData (jsonFileName = 'chats.json', txtFileName = 'chats.txt')``` gets short chats data and saves it to file | ||
- ```async chatHistory (chat)``` reads all history from chat | ||
- ```async forwardMessages (from, to, messages)``` forwardes messages from on chat to another | ||
- ```async deleteMessagesFromChannel (from, messages)``` deletes selected message from channel or supergroup | ||
- ```async sendMessage (target, message)``` sends message to chat | ||
- ```async call (...args)``` calls custom API method [list of methods](https://core.telegram.org/methods) | ||
```js | ||
@@ -74,0 +74,0 @@ await client.call ('messages.sendMessage', { |
17811