mirror of
https://github.com/lkeme/BiliHelper-personal.git
synced 2025-12-19 01:20:08 +08:00
[update] TgBotNotice closed#123
This commit is contained in:
parent
1eb4b692db
commit
7871198933
@ -180,8 +180,9 @@ filter_words =
|
||||
[notify.dingtalk]
|
||||
token =
|
||||
|
||||
; Tele机器人|token|chatid|依赖USE_NOTIFY
|
||||
; Tele机器人|url(可选)|token|chatid|依赖USE_NOTIFY
|
||||
[notify.telegram]
|
||||
url =
|
||||
bottoken =
|
||||
chatid =
|
||||
|
||||
|
||||
@ -189,7 +189,8 @@ class Notice
|
||||
private static function teleSend(array $info)
|
||||
{
|
||||
Log::info('使用Tele机器人推送消息');
|
||||
$url = 'https://api.telegram.org/bot' . getConf('bottoken', 'notify.telegram') . '/sendMessage';
|
||||
$base_url = getConf('url', 'notify.telegram') ?: 'https://api.telegram.org/bot';
|
||||
$url = $base_url . getConf('bottoken', 'notify.telegram') . '/sendMessage';
|
||||
$payload = [
|
||||
'chat_id' => getConf('chatid', 'notify.telegram'),
|
||||
'text' => $info['content']
|
||||
|
||||
Loading…
Reference in New Issue
Block a user