# How to create an api key on the admin panel

**URL:** <https://meta.discourse.org/t/how-to-create-an-api-key-on-the-admin-panel/87383>\
**Category:** Development\
**Tags:** rest-api\
**Created:** [13.Май.2018 23:15:50 UTC](https://meta.discourse.org/t/how-to-create-an-api-key-on-the-admin-panel/87383 "2018-05-13T23:15:50Z")\
**Posts on this page:** 1\
**Showing post:** 7

<div class="post-metadata">

**Author:** ![riking](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/riking/32/170938_2.png) [@riking](https://meta.discourse.org/u/riking)\
**Post date:** [15.Май.2018 02:29:16 UTC](https://meta.discourse.org/t/how-to-create-an-api-key-on-the-admin-panel/87383/7 "2018-05-15T02:29:16Z")

</div>

> [@mattman](#):
>
> If I just included an api\_key then I got an error that either the key or username was wrong, which makes sense. If I include an api\_key and an api\_username then I get an error 422 “unprocessable entity” or an error 400 “invalid access” depending on what I put in the api\_username field.

You want the 422 - that means there’s some other problem with the data you’re sending, other than the authentication.

---

_[View the full topic](https://meta.discourse.org/t/how-to-create-an-api-key-on-the-admin-panel/87383)._
