gpt4 book ai didi

slack-api - 如何禁用 Slack URL 建议?

转载 作者:行者123 更新时间:2023-12-02 22:18:21 25 4
gpt4 key购买 nike

我想向 Slack 用户发送一条直接消息,其中文本中包含网站链接。这是正文,

var msgText="Find us on < http://www.google.com|Google>";

然后发布,

method: "POST", url: "https://slack.com/api/chat.postMessage",
body: { "token": slackBotToken, "as_user":true, "channel":"@UserId","text":msgText}

这是我在 Slack 帐户中获得的内容,

enter image description here

我想删除网址建议,知道如何操作吗?

谢谢

最佳答案

我从 Slack 支持处得到了答案,并且我已经验证他是正确的:

Thanks for getting in touch, and sorry for the troubles with unfurling. It's quite hidden in our documentation (we'll make it more clear), but in order to completely prevent link unfurling within a particular message, you'll need to set both unfurl_links and unfurl_media to false.

关于slack-api - 如何禁用 Slack URL 建议?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/38475551/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com