doubts with telegram

Hello good Morning!
I made the installation of version 4.4 went okay, I did the integration with the telegram, but I get all the alerts in my channel and I can not add to users.
An example customer 1 has 1 vehicle and would like it to receive only the vehicle information in his telegram. How do I add the data to the user?

Marco Bernardi5 years ago

same question here

Marcelo Rangel5 years ago

good night..
I tried setting up but only got error

WARN: Telegram API error - javax.ws.rs.NotFoundException: HTTP 404 Not Found - ResponseProcessingException (...)

and the web works perfectly ...

https://api.telegram.org/bot<TOKEN>/sendMessage?chat_id=-1111111111111&text=Message%20end%20ap%C3%B3s%20a%20altera%C3%A3o%20do%20canal%20para % 20private.

What can be wrong?

Sumit Bajoria5 years ago

If this helps, I have this in my traccar.xml file and I successfully get realtime Telegram alerts in my group.

<entry key='notificator.types'>web,mail,telegram</entry>
<entry key='notificator.telegram.key'><apikey></entry>
<entry key='notificator.Telegram.chatid'><group chat id></entry>

My question is, is there any way in which we can set per user telegram ids and have alerts delivered to them based on which vehicles they control or are assigned?

Marco Bernardi5 years ago

Having a look to the source code i assume it's not possible to send notification for each user.

As feature or bug looks forgotten the code part where the chat id can be overridden by user's attribute.

I hope this feature can be implemented soon.

Jose B5 years ago

Hi,

In which website do I generate the 'group chat id' ?

JB

Sumit Bajoria5 years ago
Sumit Bajoria5 years ago

Please note that if you have upgraded traccar to the latest 4.5 from 4.4, you'll have to make a key change from notificator.Telegram.chatid to notificator.telegram.chatId otherwise, the notifications won't work. I learnt it the hard way.

Jose B5 years ago

Works now. Thank you @Sumit Bajoria

JB

Marcelo Rangel5 years ago

Works now. Thank you
Marcelo Rangel

Castillo5 years ago

Thanks you Sumit Bajoria

It works on version 4.5

<entry key='notificator.types'>web,mail,telegram</entry>
<entry key='notificator.telegram.key'>AAAAAAA:BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB</entry>
<entry key='notificator.telegram.chatId'>0000000</entry>
Fathi Khalid5 years ago

Hi, i tried the telegram notificator, but in my log shows telegram API error - http not found. Followed all the steps.

Chat me on telegram @fathikhalid7. Really hope that you can help me.

Macan5 years ago

Sumit Bajoria thank you very much for the help, you saved me.

Marcelo Rangel5 years ago

With this code you send notification to each user by telegram using SMS

    <entry key='notificator.types'>web,mail,sms</entry>
    <entry key='notificator.sms.manager.class'>org.traccar.sms.HttpSmsClient</entry>
    <entry key='sms.http.url'>https://api.telegram.org/botSEU-TOKEN-AQUI/sendMessage?</entry>
    <entry key='sms.http.user'>[YOUR ACCOUNT SID]</entry>
    <entry key='sms.http.password'>[YOUR AUTH TOKEN]</entry>
    <entry key='sms.http.template'>
        chat_id={phone}&amp;text={message}
    </entry>
Macan5 years ago

Very good Marcelo, is there any chance that users get notification messages per user without sms option, because sms messages cost to much ?

Regards