# API Error: You are not permitted to view the requested resource

**URL:** https://meta.discourse.org/t/api-error-you-are-not-permitted-to-view-the-requested-resource/35035
**Category:** Development
**Tags:** rest-api
**Created:** [October 28, 2015, 10:30pm UTC](https://meta.discourse.org/t/api-error-you-are-not-permitted-to-view-the-requested-resource/35035 "2015-10-28T22:30:08Z")
**Posts on this page:** 1
**Showing post:** 9

<div class="post-metadata">

### Author: ![purldator](https://avatars.discourse-cdn.com/v4/letter/p/bcef8e/32.png) [@purldator](https://meta.discourse.org/u/purldator)
#### Post date: [November 5, 2015, 5:53am UTC](https://meta.discourse.org/t/api-error-you-are-not-permitted-to-view-the-requested-resource/35035/9 "2015-11-05T05:53:58Z")

</div>

I feel some other variable exists and is causing this error; one that cannot be seen due to the limited info provided.

Be sure to check these topics in regards to setting up and using the Discourse API, if you have not yet done so.

> [@Use the Discourse API ruby gem](https://meta.discourse.org/t/using-the-discourse-api-ruby-gem/17587):
>
> So you want to use [Discourse API](https://meta.discourse.org/t/discourse-api-documentation/22706)? Great! Let’s get started. Set up Discourse development environment Set up Discourse development environment using our [Windows](https://meta.discourse.org/t/install-discourse-on-windows-for-development/75149), [macOS](https://meta.discourse.org/t/install-discourse-on-macos-for-development/15772/) or [Ubuntu](https://meta.discourse.org/t/install-discourse-on-ubuntu-or-debian-for-development/14727/) guide. Clone Discourse API Gem Now that you have set up Discourse development environment, you should already have Git and Ruby installed on your system. You can install Discourse API gem by running following command from console: git clone https://github.com/discourse/discourse\_api.git ~/discourse\_api Alternatively…

> [@Discourse REST API Documentation](https://meta.discourse.org/t/discourse-api-documentation/22706):
>
> Discourse API Please view the Discourse API Documentation site for detailed info: [https://docs.discourse.org](https://docs.discourse.org)information_source Authentication API requests must use HTTP header based authentication. Pass your Api-Key and Api-Username as HTTP headers. Authentication via query parameters or request body is not supported (this was removed in April 2020). Please see the example cURL request below. The only API endpoints that continue to support credentials in query parameters are requests to…

> [@Reverse engineer the Discourse API](https://meta.discourse.org/t/how-to-reverse-engineer-the-discourse-api/20576):
>
> Discourse is backed by a complete JSON api. Anything you can do on the site you can also do using the JSON api. The API is documented at [docs.discourse.org](https://docs.discourse.org). You can also use the [discourse\_api](https://github.com/discourse/discourse_api) Ruby gem as a client library. However, not every endpoint is documented. To determine how to do something with the JSON API here are some steps you can follow. Example: recategorize a topic. Go to a topic and start editing a category: Open Chrome dev tools, switch to the Network tab, select …

---

_[View the full topic](https://meta.discourse.org/t/api-error-you-are-not-permitted-to-view-the-requested-resource/35035)._
