Google apps script 在bot通过脚本/谷歌表单发送的电报消息中创建超链接

Google apps script 在bot通过脚本/谷歌表单发送的电报消息中创建超链接,google-apps-script,google-sheets,telegram,telegram-bot,Google Apps Script,Google Sheets,Telegram,Telegram Bot,我当前的脚本是: function EnviarTelegram(botSecret, chatId, body) { var response = UrlFetchApp.fetch("https://api.telegram.org/bot" + botSecret + "/sendMessage?text=" + encodeURIComponent(body) + "&chat_id=" + chatId + "

我当前的脚本是:

function EnviarTelegram(botSecret, chatId, body) {
var response = UrlFetchApp.fetch("https://api.telegram.org/bot" + botSecret + "/sendMessage?text=" + encodeURIComponent(body) + "&chat_id=" + chatId + "&parse_mode=HTML");
}
在谷歌表单中,我用来发送信息的公式是:

=EnviarTelegram("Code to Bot","Code to ChatId","Created Message")
我希望能够创建以下消息:

"Full list of games tomorrow

Click here to access"
中单击此处访问
我希望有一个超链接,例如:
www.google.com/test


是否有任何方法可以调整为此创建的脚本或文本?

在查询参数中,使用了
parse\u mode=HTML
。因此,我认为在本例中,HTML标记可以用于
文本
。当您想使用
=EnviarTelegram(“代码到Bot”、“代码到ChatId”、“创建的消息”)
时,下面的修改如何

发件人: 致:
=EnviarTelegram(“代码到机器人”,“代码到聊天ID”,“明天的游戏完整列表\n\n”)

Hi@Tanaike,以下错误为“异常:请求失败”https://api.telegram.org 返回代码400。截断的服务器响应:{“ok”:false,“error_code”:400,“description:“错误请求:无法分析实体:字节偏移量27处不支持的起始标记\“br\”}”@Brondby,如果感谢您的回复。给您带来不便,我深表歉意。在这种情况下,从错误消息中,将明天的
游戏完整列表

修改为明天的
游戏完整列表\n\n
?或者
明天的游戏完整列表%0A%0A
?您好@Tanaike这是完美的伴侣,只需编辑空格行:
/n/n
双击
ALT+ENTER
@Brondby,谢谢您的回复和再次测试。我很高兴你的问题解决了。从你的回复中,我更新了我的答案。
=EnviarTelegram("Code to Bot","Code to ChatId","Created Message")
=EnviarTelegram("Code to Bot","Code to ChatId","Full list of games tomorrow\n\n<a href='https://www.google.com/testtesttesttest'>Click here to access</a>")