# Receive any message that the user writes in Telegram

**URL:** https://discourse.nodered.org/t/receive-any-message-that-the-user-writes-in-telegram/50447
**Category:** General
**Tags:** telegram
**Created:** [31 August 2021 14:20 UTC](https://discourse.nodered.org/t/receive-any-message-that-the-user-writes-in-telegram/50447 "2021-08-31T14:20:11Z")
**Posts on this page:** 8
**Page:** 1

<div class="post-metadata">

### Author: ![achrafb](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/achrafb/32/45607_2.png) [@achrafb](https://discourse.nodered.org/u/achrafb)
#### Post date: [31 August 2021 14:20 UTC](https://discourse.nodered.org/t/receive-any-message-that-the-user-writes-in-telegram/50447/1 "2021-08-31T14:20:11Z")

</div>

Good afternoon, I am making a telegram message system with the nodes (`node-red-contrib-telegrambot-home`) because it has the part of displaying options (telegrambot-switch) and I like it a lot since it facilitates the interaction a lot.  
I would like to receive any message that the user writes, and I see that with these nodes that come with (node-red-contrib-telegrambot-home) I cannot:

Someone could help me how to receive any message that is written, since if I use another node I will not have the node (telegrambot-switch) that is very relevant to me.

Thank's in advance!

---

<div class="post-metadata">

### Author: ![LosinIt](https://avatars.discourse-cdn.com/v4/letter/l/439d5e/32.png) [@LosinIt](https://discourse.nodered.org/u/LosinIt)
#### Post date: [31 August 2021 16:22 UTC](https://discourse.nodered.org/t/receive-any-message-that-the-user-writes-in-telegram/50447/2 "2021-08-31T16:22:24Z")

</div>

I use node-red-contrib-telegrambot and it has a receive node that will do what you want, if I understand it right.

---

<div class="post-metadata">

### Author: ![achrafb](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/achrafb/32/45607_2.png) [@achrafb](https://discourse.nodered.org/u/achrafb)
#### Post date: [31 August 2021 16:28 UTC](https://discourse.nodered.org/t/receive-any-message-that-the-user-writes-in-telegram/50447/3 "2021-08-31T16:28:41Z")

</div>

Hi @LosinIt !  
Thanks for your answer.

This is what I have used it too and it is what I needed, the problem is that I could not use the (telegrambot-switch) which is the most useful option for the integration that I have

---

<div class="post-metadata">

### Author: ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)
#### Post date: [31 August 2021 20:14 UTC](https://discourse.nodered.org/t/receive-any-message-that-the-user-writes-in-telegram/50447/4 "2021-08-31T20:14:26Z")

</div>

Doesn't the `command` node do what you want? Though a command in Telegram is a defined msg starting with `/`, in the example given, that isn't how the example is triggered but rather uses just standard user input.

---

<div class="post-metadata">

### Author: ![achrafb](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/achrafb/32/45607_2.png) [@achrafb](https://discourse.nodered.org/u/achrafb)
#### Post date: [31 August 2021 22:20 UTC](https://discourse.nodered.org/t/receive-any-message-that-the-user-writes-in-telegram/50447/5 "2021-08-31T22:20:03Z")

</div>

Hello @TotallyInformation ,  
Thank you for your answer!

The `Command` node only lets defined words or phrases pass, in the node itself, and I have tried to leave it blank to see if it allows me to receive everything, but it does not allow it.  
 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/d/7/d7c1d297ec1ec36154bd39c66e0744e36fee0aa8.png)

It cant be blank:

![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/4/2/429502610060f5c37cc741a0d7ae6e445993cf40.png)

---

<div class="post-metadata">

### Author: ![achrafb](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/achrafb/32/45607_2.png) [@achrafb](https://discourse.nodered.org/u/achrafb)
#### Post date: [3 September 2021 18:00 UTC](https://discourse.nodered.org/t/receive-any-message-that-the-user-writes-in-telegram/50447/6 "2021-09-03T18:00:42Z")

</div>

In the end I have been able to use expressions in the `command` node, it works for what I need, thanks for the collaboration @TotallyInformation & @LosinIt

---

<div class="post-metadata">

### Author: ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)
#### Post date: [6 September 2021 12:46 UTC](https://discourse.nodered.org/t/receive-any-message-that-the-user-writes-in-telegram/50447/7 "2021-09-06T12:46:41Z")

</div>

I would suggest raising an issue against the GitHub for the author to consider either extending the command node or adding a more generic msg node.

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)
#### Post date: [20 September 2021 12:47 UTC](https://discourse.nodered.org/t/receive-any-message-that-the-user-writes-in-telegram/50447/8 "2021-09-20T12:47:36Z")

</div>

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
