What is correct entries for the Telegram notifications.

inetsof2 years ago

Hola @vegellibert, en whatsapp, no se crea bot como en telegram, debes registrar un teléfono, whatsapp-web.js permite simular un whatsapp web sin interface, el mensaje sale del whatsapp que registres, te recomiendo que uses un segundo whatsapp con una línea exclusiva para las notificaciones.

leogeolgrva year ago

greetings anton in version 5.8 I managed to activate the notifications but I had to create a group add the father bot test in the api in telegram copy the new id and they work but all the notifications reach the telegram chat group there is a way to reach the phone each client

<entry key='notificator.types'>web,mail,firebase,telegram</entry>
<entry key='notificator.telegram.key'>614174549824:AAGyi4COSjhfgijgigigkigig7OfdM3A</entry>
<entry key='notificator.telegram.chatId'>@alertasrastreo_bot</entry>
<entry key='notificator.sms.url'>https://api.telegram.org/bot6168529024:AAGyi4COSVC_rYWhRCb_yK6LV4OP7OfdM3A/getUpdates
<entry key='notificator.sms.manager.class'>org.traccar.sms.HttpSmsClient</entry>
 chat_id={phone}&amp;text={message}</entry>
Daniel Höldera year ago

Can I try the Telegram notification on the demo server? Or doesn’t it work on that?

If yes, where can I enter the telegram.key?

Anton Tananaeva year ago

You can't because demo servers run with the default configuration.

Daniel Höldera year ago

Ok, thanks, Anton!

Daniel Höldera year ago

Hi Anton,

Meanwhile I set up my own Traccar server and activated Telegram notifications.

Unfortunately, it doesn’t work to define the ChatID in the config file:
<entry key='notificator.telegram.chatId'>-1234567890</entry> in traccar.xml

It only works if I enter the ChatID as an attribute to the user in the Traccar Manager.

I don’t understand this. Can you help me?

Anton Tananaeva year ago

It should work in the config file. Make sure you restart after changing config and also make sure you don't override the value in the user attributes. Then if still doesn't work, check logs for errors.

Daniel Höldera year ago

Thank you. It works now. Probably, I didn't delete Telegram ChatIT in all users profiles.

Hi inetsof, in this part (Whatsapp web js comment) you mentioned that you used whatsapp-web.js.

How did you manage to get the code to work? I'm struggling with the traccar <-> API connection. Can you make your code available?