node-telegram-bot-api
telegraf
Our great sponsors
node-telegram-bot-api | telegraf | |
---|---|---|
11 | 14 | |
7,936 | 7,658 | |
- | 2.8% | |
6.9 | 8.9 | |
25 days ago | about 2 months ago | |
JavaScript | TypeScript | |
MIT License | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
node-telegram-bot-api
- Build a Bot with ZettaBlock GraphQL API
- Creare un BOT Telegram che posti il titolo degli articoli con il link
-
How to get chat history of Telegram using node-telegram-bot?
Hi, I am developing a telegram chatbot using node-telegram-bot - https://github.com/yagop/node-telegram-bot-api) in Node.js that requires getting the previous messages or chat history of the user and bot.
-
Telegram Bots for Begginers
Of course, it's good to write API requests yourself. It reduces the dependency on third-party libraries and allows you to control the behavior of the code more. But when there are more such methods than twenty, it already increases the size of the code. It becomes difficult to manage all the logic. This is where third-party libraries(frameworks) come to the rescue. After choosing a language, you can consider the options of different libraries from the list here, on the official Telegram page. For JavaScript I recommend using node-telegram-bot-api and telegraf. For Python you can take pyTelegramBotAPI and aiogram(highly recommended).
-
“502: Bad Gateway” from UnhandledPromiseRejection
Flow-based programming for the Internet of Things ----------------------------------------------------------- Add-on version: 12.0.2 You are running the latest version of this add-on. System: Debian GNU/Linux 11 (bullseye) (amd64 / qemux86-64) Home Assistant Core: 2022.7.0 Home Assistant Supervisor: 2022.07.0 ----------------------------------------------------------- Please, share the above information when looking for help or support in, e.g., GitHub, forums or the Discord chat. ----------------------------------------------------------- cont-init: info: /etc/cont-init.d/00-banner.sh exited 0 cont-init: info: running /etc/cont-init.d/01-log-level.sh cont-init: info: /etc/cont-init.d/01-log-level.sh exited 0 cont-init: info: running /etc/cont-init.d/customizations.sh cont-init: info: /etc/cont-init.d/customizations.sh exited 0 cont-init: info: running /etc/cont-init.d/nginx.sh cont-init: info: /etc/cont-init.d/nginx.sh exited 0 cont-init: info: running /etc/cont-init.d/node-red.sh patching file nodes/ui_base.html Hunk #1 succeeded at 1164 (offset 633 lines). up to date, audited 678 packages in 18s 36 packages are looking for funding run `npm fund` for details 47 vulnerabilities (2 low, 16 moderate, 21 high, 8 critical) To address issues that do not require attention, run: npm audit fix To address all issues possible (including breaking changes), run: npm audit fix --force Some issues need review, and may require choosing a different dependency. Run `npm audit` for details. cont-init: info: /etc/cont-init.d/node-red.sh exited 0 s6-rc: info: service legacy-cont-init successfully started s6-rc: info: service legacy-services: starting services-up: info: copying legacy longrun nginx (no readiness notification) services-up: info: copying legacy longrun nodered (no readiness notification) s6-rc: info: service legacy-services successfully started [15:47:34] INFO: Setting safe mode startup [15:47:34] INFO: Starting Node-RED... > start > node $NODE_OPTIONS node_modules/node-red/red.js "--safe" "--settings" "/etc/node-red/config.js" 7 Jul 15:47:35 - [info] Welcome to Node-RED =================== 7 Jul 15:47:35 - [info] Node-RED version: v2.2.2 7 Jul 15:47:35 - [info] Node.js version: v16.15.0 7 Jul 15:47:35 - [info] Linux 5.14.0-0.bpo.2-amd64 x64 LE 7 Jul 15:47:36 - [info] Loading palette nodes Thu, 07 Jul 2022 14:47:41 GMT node-telegram-bot-api deprecated Automatic enabling of cancellation of promises is deprecated. In the future, you will have to enable it yourself. See https://github.com/yagop/node-telegram-bot-api/issues/319. at node:internal/modules/cjs/loader:1105:14 7 Jul 15:47:41 - [info] Dashboard version 3.0.4 started at /endpoint/ui 7 Jul 15:47:42 - [warn] ------------------------------------------------------ 7 Jul 15:47:42 - [warn] [node-red-contrib-deduplicate-adv/deduplicate] 'deduplicate' already registered by module node-red-contrib-deduplicate 7 Jul 15:47:42 - [warn] ------------------------------------------------------ 7 Jul 15:47:42 - [info] Settings file : /etc/node-red/config.js 7 Jul 15:47:42 - [info] Context store : 'default' [module=memory] 7 Jul 15:47:42 - [info] User directory : /config/node-red/ 7 Jul 15:47:42 - [warn] Projects disabled : editorTheme.projects.enabled=false 7 Jul 15:47:42 - [info] Flows file : /config/node-red/flows.json 7 Jul 15:47:42 - [info] Server now running at http://127.0.0.1:46836/ 7 Jul 15:47:42 - [info] ***************************************************************** 7 Jul 15:47:42 - [info] Flows stopped in safe mode. Deploy to start. 7 Jul 15:47:42 - [info] ***************************************************************** [15:47:42] INFO: Starting NGinx... 7 Jul 16:39:07 - [info] Stopping flows 7 Jul 16:39:07 - [info] Stopped flows 7 Jul 16:39:07 - [info] Starting flows 7 Jul 16:39:07 - [info] Started flows 7 Jul 16:39:08 - [info] [mqtt-broker:HA-MQTT] Connected to broker: mqtt://192.168.1.109:1883 7 Jul 16:39:08 - [info] [mqtt-broker:omv] Connected to broker: mqtt://192.168.1.109:1883 7 Jul 16:39:08 - [red] Uncaught Exception: 7 Jul 16:39:08 - [error] UnhandledPromiseRejection: This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). The promise rejected with the reason "{"error":403,"msg":"Sign:oauthClient enable invalid"}". [16:39:08] WARNING: Node-RED crashed, halting add-on s6-rc: info: service legacy-services: stopping [16:39:08] INFO: Node-RED stoped, restarting... [16:39:08] INFO: Node-RED stoped, restarting... s6-svwait: fatal: supervisor died s6-rc: info: service legacy-services successfully stopped s6-rc: info: service legacy-cont-init: stopping s6-rc: info: service legacy-cont-init successfully stopped s6-rc: info: service fix-attrs: stopping s6-rc: info: service fix-attrs successfully stopped s6-rc: info: service s6rc-oneshot-runner: stopping s6-rc: info: service s6rc-oneshot-runner successfully stopped
-
Telegraf VS Node-Telegram-Bot-API
We checked if our text is equal to our command and responded with message. It is all main logic from this package, more sendMessage methods or params you can see here. Also we used reply_markup option in which we can use our keyboard, which will be sent with our message. And then we can check if text equal to "en" we will change our language to english and response with message. In addition, if you have a question like can you send message without getting message from user - you can do it. All that you need is to save your user to database like MongoDB with chatId field and use something like express to make CRUD methods to send your message. Here is my example of this 'bot mailer':
-
Telegram bot instead of mobile app and Connect
The Telegram bot API is pretty convenient to setup. Installing node and npm via toltec then https://github.com/yagop/node-telegram-bot-api/ makes it even easier to get a bot running in minutes. The resulting minimal app running on the reMarkable uses less than 1% CPU and 110Mb of RAM. Here the /ls example shows the last modified file by xochtil but other functions could be added to wget a PDF or ePub then add it.
-
node-telegram-bot-api and onText case insensitive
whoever might have worked with node-telegram-bot-api did you find any workaround in accepting case insensitive RegEx?
-
How to Create a Telegram Bot with Node.js and Sanity
The node package we're working with, [node-telegram-bot-api](https://github.com/yagop/node-telegram-bot-api/blob/master/doc/tutorials.md), comes with great documentation. Let's start with one of the methods from the README. We'll tell our bot to send an introduction anytime a user runs /start.
-
Group chat bot that assign points to members
Github repo for more examples and ideas
telegraf
-
Is there any telegram bot to forward any message given to an special channel?
Simply use telegraf : https://telegraf.js.org/
-
I own an advertisement group and would like two things.. a bot that prevents people from using advertisements more than a thousand characters... and a bot for English only groups. anyone?
this is pretty simple , you can create a bot yourself which simply listens for every message checks length and if exceeded deletes the message (bot must be added as admin ingroup and shows have read permission in bot settings) , I would suggest you to use https://github.com/telegraf/telegraf for the code,
-
How to create a Telegram Bot using NodeJS
In this project we will use the Telegraf library to create the bot. To install it, you can use the npm install command.
-
🥳 KaufmanBot v 3.2.0 🥳
Changed the main library for working with telegram from https://telegraf.js.org to https://grammy.dev, updated the source code for better work with typings
-
Telegram Bots for Begginers
Of course, it's good to write API requests yourself. It reduces the dependency on third-party libraries and allows you to control the behavior of the code more. But when there are more such methods than twenty, it already increases the size of the code. It becomes difficult to manage all the logic. This is where third-party libraries(frameworks) come to the rescue. After choosing a language, you can consider the options of different libraries from the list here, on the official Telegram page. For JavaScript I recommend using node-telegram-bot-api and telegraf. For Python you can take pyTelegramBotAPI and aiogram(highly recommended).
-
Show HN: We are trying to (finally) get tail-calls into the WebAssembly standard
It’s an expressive type system, but ime it allows developers to go crazy on type interdependencies and general entanglement, so you can’t just go to the “header” and quickly figure out what your method or a return value really is, despite TS has structural typing.
E.g. look at this: https://github.com/telegraf/telegraf/blob/v4/src/telegram-ty...
-
Newbie Help: Telegraf telegram bot with async/fetch, media send and async management
The bot uses telegraf framework, which is an overlay for the original telegram api, which is a nightmare in code form.
- Desarrollando un Bot para Telegram
-
Telegram celebrates 700M Users and introduces Telegram Premium
Honestly I found their API one of the worst ones I've ever used. The documentation is lacking, and they have some unintuitive quirks like posting messages with http GET requests and randomly concatenating strings in params (botNAMEOFBOT anyone?).
I didn't enjoy using it without a third party library [1].
Sending a single message is easy, but using the rest of telegram's features is "meh" when using pure API calls.
If you want to see a well designed API, you should take a look at FTX or Stripe. I love those two :)
[1] https://telegraf.js.org
-
Telegraf VS Node-Telegram-Bot-API
Today the most popular ways to build telegram chat bots in node js are Telegraf and Node-Telegram-Bot-Api. The second is more popular by weekly downloads(250.000), but in this post I don't want to equalize them by stats. I want to talk about my experience with them, in which cases I used them and show you really nice guide, especially for Telegraf, cause they haven't readable docs for newbies or people who don't use typescript.
What are some alternatives?
telegram-react - Experimental Telegram web client with tdlib, webassembly and react js under the hood
node-telegram-bot-boilerplate - 🤖 Create telegram bot with this friendly nodejs boilerplate
aiogram - aiogram is a modern and fully asynchronous framework for Telegram Bot API written in Python using asyncio
pyTelegramBotAPI - Python Telegram bot api.
mineflayer - Create Minecraft bots with a powerful, stable, and high level JavaScript API.
Express - Fast, unopinionated, minimalist web framework for node.
Lowdb - Simple and fast JSON database
telegram-bot-api - Telegram Bot API server
upm - ⠕ Universal Package Manager - Python, Node.js, Ruby, Emacs Lisp.
nodejs.dev - A redesign of Nodejs.org built using Gatsby.js with React.js, TypeScript, and Remark.
ps5-stock-alert - Be smart about hunting for a PS5