# 404 Error on Oauth2 POST call

**URL:** <https://discuss.dev.twitch.com/t/404-error-on-oauth2-post-call/46766>\
**Category:** API\
**Created:** [August 4, 2023, 1:22pm UTC](https://discuss.dev.twitch.com/t/404-error-on-oauth2-post-call/46766 "2023-08-04T13:22:00Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![CellOrwell](https://avatars.discourse-cdn.com/v4/letter/c/85f322/32.png) [@CellOrwell](https://discuss.dev.twitch.com/u/CellOrwell)\
**Post date:** [August 4, 2023, 1:22pm UTC](https://discuss.dev.twitch.com/t/404-error-on-oauth2-post-call/46766/1 "2023-08-04T13:22:00Z")

</div>

Hi. I’m trying to get an access token, but when I make a call to the [https://id.twitch.tv/oauth2/token/](https://id.twitch.tv/oauth2/token/) website, I keep getting a 404 error.

I have tried using curl & postman, and keep getting the same error. I’m not sure exactly what I’m doing wrong. The URL below is what I am using, along with the header ‘Content-Type’: ‘application/x-www-form-urlencoded’

[https://id.twitch.tv/oauth2/token/?client\_id=](https://id.twitch.tv/oauth2/token/?client_id=)&client\_secret=&grant\_type=client\_credentials

Any help would be greatly appreciated. Thank you

---

<div class="post-metadata">

**Author:** ![BarryCarlyon](https://d3ovvz0v2ajtpu.cloudfront.net/user_avatar/discuss.dev.twitch.com/barrycarlyon/32/253_2.png) [@BarryCarlyon](https://discuss.dev.twitch.com/u/BarryCarlyon)\
**Post date:** [August 4, 2023, 1:30pm UTC](https://discuss.dev.twitch.com/t/404-error-on-oauth2-post-call/46766/2 "2023-08-04T13:30:52Z")

</div>

> [@CellOrwell](#):
>
> Hi. I’m trying to get an access token, but when I make a call to the [https://id.twitch.tv/oauth2/token/](https://id.twitch.tv/oauth2/token/) website, I keep getting a 404 error.

The documentation documents it as `https://id.twitch.tv/oauth2/token` which is a differnet URL/Resourse to what you are calling `https://id.twitch.tv/oauth2/token/`

The no slash on the end is important.

---

<div class="post-metadata">

**Author:** ![CellOrwell](https://avatars.discourse-cdn.com/v4/letter/c/85f322/32.png) [@CellOrwell](https://discuss.dev.twitch.com/u/CellOrwell)\
**Post date:** [August 4, 2023, 1:41pm UTC](https://discuss.dev.twitch.com/t/404-error-on-oauth2-post-call/46766/3 "2023-08-04T13:41:10Z")

</div>

Got it, thank you so much! I’m new to this so I guess little things like that are gonna catch me out 😂

Have a nice day!

---

<div class="post-metadata">

**Author:** ![system](https://d2opxh93rbxzdn.cloudfront.net/original/2X/0/05909729875cce3b53e59d5561c4d23bb14948fc.png) [@system](https://discuss.dev.twitch.com/u/system)\
**Post date:** [September 3, 2023, 1:41pm UTC](https://discuss.dev.twitch.com/t/404-error-on-oauth2-post-call/46766/4 "2023-09-03T13:41:41Z")

</div>

Closed on September 3, 2023, 1:41pm UTC

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