Answer the question
In order to leave comments, you need to log in
Zabbix 5 - what's wrong with notifications in Telegram?
The bot was set up according to the manual , the test of messages in the chat passed, even messages were sent. After that, an attempt was made to tweak the message templates, incl. insert emoji. And everything broke. And now even the message test fails.
Media type test failed.
Sending failed: Bad Request: can't parse entities: Character '{' is reserved and must be escaped with the preceding '\'.
'-'
, '('
etc. dofiga and all these messages settle in the Action Log. \xF0\x9F\x86\x97
? Markdown :sos:
doesn't work either. If you try to insert the symbol itself, it swears when you already save the Media Type page.
Answer the question
In order to leave comments, you need to log in
Emoji can be defined as Unicode Surrogates (of the form `\u01234\uABCD` )
Then in the JS script for sending a message to telegram, the 29th line of the form should
be replaced with
data = JSON.stringify(params);
var dataJSON = JSON.stringify(params);
var re = /\\u([0-9A-F]{4})/g;
data = dataJSON.replace(re, 'u$1');
> Character '{' is reserved and must be escaped with the preceding '\'.
{ is a reserved character and must be escaped with "\"
By default, the Parsemode field is empty. Try clearing the "Parsemode" field
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question