How to convert an array to a text - NodeRED read from MySQL to be sent to Telegram

Hi .. it looks ok. i dont have any experience with Telegram. Only one way to find out :wink:

By the way .. why you get a negative number for the "Remaining places" ?
Did you change the test number of 24 to your hall's maximum seat capacity ?

let remainingSeats = 24 - seats;

Thank you very much again.

Regarding with your question, you are right we should not have negative number there. The goal would be to show the occupation of one place as well as the "remaining places". The table is coming from a IP stream camera which is "counting" the number of people in a place with ml in Python, and then the output would be a table with the number of people by zone.

And we would like to send a message to Telegram showing the total number of people and also the remaining spare places to help the people to decide whether they want to go to the shop or not. :slight_smile:

Thanks again for your support. LetĀ“s wait if anyone else could help us with the txt message to be sent through a Telegram sender to a mobile phone.

At the end I found it. I mixed the two functions in only one, and changed the type of "msg.payload" type from "text" to "message".

image

Now we receive the message in two different Telegram chats (private and group):

image

Thanks all,

1 Like

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