Closed ilyuxa-sw97 closed 4 years ago
you have to update the webhook with the latest version from the git repo (it replaces setProxy by SetProxy which works)
Parameters
Name Value
HTTPProxy http://IP:PORT
Change Inside JavaScript: "setProxy" TO "SetProxy"
Small Letter "s" TO Capital Letter "S"
I used two options for connecting to telegrams; the bot didn’t work. zabbix 5.0 1) the webhooks with the proxy returned the error "Sending failed: TypeError: undefined not callable (property 'setProxy' of [object Object])." input "socks5://138768417:m4GRktGl@ss-02.s5.ynvv.cc:999" 2) shell script with curl command. "/ usr / lib / zabbix / alertscripts / curl: relocation error: / usr / lib / zabbix / alertscripts / curl: symbol curl_url_set version CURL_OPENSSL_4 not defined in file libcurl.so.4 with link time reference" "
!/bin/bash
token='12197671:aaaaaaaaaaaaaa' chat="$1" subj="$2" message="$3" /usr/lib/zabbix/alertscripts/curl --socks5 ss-02.s5.ynvv.cc:999 -U 1345666:m4GRktGl -s --header 'Content-Type: applicapplication/json' --request 'POST' --data "{\"chat_id\":\"${chat}\",\"text\":\"${subj}\n${message}\"}" "https://api.telegram.org/bot${token}/sendMessage" "
sorry for my english. in my country, telegram only works through proxies