# 7004 error when sending message from chatbot

**URL:** <https://devforum.zoom.us/t/7004-error-when-sending-message-from-chatbot/60680>\
**Category:** API and Webhooks\
**Created:** [November 24, 2021, 7:49pm UTC](https://devforum.zoom.us/t/7004-error-when-sending-message-from-chatbot/60680 "2021-11-24T19:49:42Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![hlowso](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/hlowso/32/29114_2.png) [@hlowso](https://devforum.zoom.us/u/hlowso)\
**Post date:** [November 24, 2021, 7:49pm UTC](https://devforum.zoom.us/t/7004-error-when-sending-message-from-chatbot/60680/1 "2021-11-24T19:49:42Z")

</div>

**Description**  
Sending messages via chatbot was working fine when used with a local instance of my app, but then I uninstalled the chatbot app in the “Local test” tab, and then I couldn’t get chatbot messages to send, even after reinstalling the chatbot app. I kept getting the response { code: 7004, message: ‘Not authorized.’ }.

I noticed that neither of the call logs under the chatbot app or under the oauth app that I’ve also got installed list the POST to /im/chat/messages. This is strange because Zoom’s obviously receiving this request and responding to it.

**Error**  
{ code: 7004, message: ‘Not authorized.’ }

**Which App Type (OAuth / Chatbot / JWT / Webhook)?**  
Chatbot

**Which Endpoint/s?**  
/im/chat/messages

---

<div class="post-metadata">

**Author:** ![will.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/will.zoom/32/14417_2.png) [@will.zoom](https://devforum.zoom.us/u/will.zoom)\
**Post date:** [December 1, 2021, 11:25am UTC](https://devforum.zoom.us/t/7004-error-when-sending-message-from-chatbot/60680/2 "2021-12-01T11:25:16Z")

</div>

Hi @hlowso,

Thanks for reaching out about this. Can you double check that you have the account permissions outlined here:

> [@Not authorized to send message from a chatbot](https://devforum.zoom.us/t/not-authorized-to-send-message-from-a-chatbot/53265/2):
>
> Hi @plm, Installing a Chatbot is not a prerequisite for this endpoint. However, can you make sure that you have the following view and edit permissions enabled in your Chat settings? Thanks, Will

Let me know—thanks,  
Will

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex016/uploads/zoomdeveloper/original/3X/6/1/614bdd549b610bbaa46ff934617683a02bdaa03c.png) [@system](https://devforum.zoom.us/u/system)\
**Post date:** [December 31, 2021, 9:25pm UTC](https://devforum.zoom.us/t/7004-error-when-sending-message-from-chatbot/60680/3 "2021-12-31T21:25:44Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
