With the new bot account from Mattermost, I converted my existing hubot user to a fully fledged bot account. Doing so partially broke it.
Writing directly to the bot in a private message works perfectly but the issue is when posting in other channels. The bot has the 'System Admin' permission but is no longer monitoring the other channel and since it's a bot account it cannot be added as member since by default he's already a member of all the channels as sys admin.
A direct message to the bot to trigger a message in another room result in a 'permission denied'
Here's an exemple:
In a direct message:
hubot announce 'maintenance starting now' in tests channel
Result in the following line in the log:
{"level":"error","ts":1578947833.2254527,"caller":"mlog/log.go:174","msg":"You do not have the appropriate permissions","path":"/api/v4/posts","request_id":"ksc5t5wbjbr4tjnb15mqaj9h7e","ip_addr":"192.168.10.170","user_id":"dq3ryuzuk3dmijt6o7dhzuccne","method":"POST","err_where":"Permissions","http_code":403,"err_details":"userId=dq3ryuzuk3dmijt6o7dhzuccne, permission=create_post"}
With the new bot account from Mattermost, I converted my existing hubot user to a fully fledged bot account. Doing so partially broke it.
Writing directly to the bot in a private message works perfectly but the issue is when posting in other channels. The bot has the 'System Admin' permission but is no longer monitoring the other channel and since it's a bot account it cannot be added as member since by default he's already a member of all the channels as sys admin.
A direct message to the bot to trigger a message in another room result in a 'permission denied'
Here's an exemple:
In a direct message:
Result in the following line in the log: