Quantcast
Channel: Mattermost Discussion Forums - Latest posts
Viewing all articles
Browse latest Browse all 25778

[SOLVED] Submitting a post via REST: You do not have the appropriate permissions

$
0
0

Hi @domrue,

I was having a similar issue earlier today, have you tried using the id for the team rather than it's name?

If I POST to:

http://localhost:8065/api/v3/teams/development/channels/8yce4jb34irc9mrkjcnj7k8p1a/posts/create
{"channel_id": "8yce4jb34irc9mrkjcnj7k8p1a", "message": "Message from API!"}

I get the same error you are reporting, however if I try:

http://localhost:8065/api/v3/teams/t8wxrxbwwtbwfbuteahkigunry/channels/8yce4jb34irc9mrkjcnj7k8p1a/posts/create
{"channel_id": "8yce4jb34irc9mrkjcnj7k8p1a", "message": "Message from API!"}

I get the expected response, and my message is posted to the channel on my Mattermost server.

As a side note, I've noticed that using the id or name of the team when returning a channel list give different results.

http://localhost:8065/api/v3/teams/t8wxrxbwwtbwfbuteahkigunry/channels/ is returning all expected channels (channels, private groups and direct messages).

While http://localhost:8065/api/v3/teams/development/channels/ is only returning a list of channels for direct messages.

Hopefully this helps, I've only been looking at the API for a couple of days but happy to help where I can.


Viewing all articles
Browse latest Browse all 25778

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>