I am working with the Mattermost web services and have followed along with the guide located here. I have no trouble obtaining a session token and then making a GET call to the example API URL (curl -i -H 'Authorization: Bearer hyr5dmb1mbb49c44qmx4whniso' http://localhost:8065/api/v3/users/me). However, when I try to make calls to any other APIs, I receive the following error:
{"id":"api.context.404.app_error","message":"Sorry, we could not find the page.", "detailed_error":"There doesn't appear to be an api call for the url='API_URL'. Typo? are yo missing a team_id or user_id as part of the url?"...
For example, I was trying to make a call to http://localhost:8065/api/v3/channels/CHANNEL_ID/posts/0/5 and received the above error. The same occurs when I try to make a call to api/v3/posts/POST_ID. For the CHANNEL_ID and POST_ID I am retrieving the specific IDs from the postgresql database.
What am I doing wrong? Am I supposed to include a team_id or user_id when I make calls?
I tried that and got the same error. For the channel ID, do I use the name of a channel in mattermost or the auto-generated ID of a channel found in the PSQL database? I tried both and had no luck with either. I think this may be a problem with setup, but I’m not sure where to look.
{"id":"api.context.404.app_error","message":"Sorry, we could not find the page.","detailed_error":"There doesn't appear to be an api call for the url='/api/v3/channels/[CHANNEL_ID OBTAINED FROM PSQL DATABASE]/posts/page/0/5'. Typo? are you missing a team_id or user_id as part of the url?","request_id":"","status_code":404,"is_oauth":false}