Slack: Bot name in sent messages

霸气de小男生 提交于 2019-12-24 06:43:39

问题


I created a bot named "esmeralda". When I send a message to Slack with the token generated for this esmeralda, the message just appears to be from "bot", not "esmeralda".

Can I do something so that the message will be shown to be sent by "esmeralda" instead the "bot"?


回答1:


I'm guessing you're using the Web API and therefore the chat.postMessage method?

I'm further guessing that you're not passing as_user=true as one of your parameters. Try doing that.

(If my guesses are wrong, please include the actual details of what you're doing: at least tell us what API you're using, what method you're calling, and what parameters you're passing. Ideally share code.)



来源:https://stackoverflow.com/questions/37909618/slack-bot-name-in-sent-messages

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!