# 404 error code when try to get access token

**URL:** <https://community.developer.atlassian.com/t/404-error-code-when-try-to-get-access-token/70398>\
**Category:** Confluence Cloud\
**Tags:** oauth2\
**Created:** [June 15, 2023, 3:24pm UTC](https://community.developer.atlassian.com/t/404-error-code-when-try-to-get-access-token/70398 "2023-06-15T15:24:49Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Igor\_T](https://avatars.discourse-cdn.com/v4/letter/i/f9ae1b/32.png) [@Igor\_T](https://community.developer.atlassian.com/u/Igor_T)\
**Post date:** [June 15, 2023, 3:24pm UTC](https://community.developer.atlassian.com/t/404-error-code-when-try-to-get-access-token/70398/1 "2023-06-15T15:24:49Z")

</div>

Hello, I try to connect to Jira Cloud using OAuth2 3LO approach according to this [guide](https://developer.atlassian.com/cloud/jira/platform/oauth-2-3lo-apps/#2--exchange-authorization-code-for-access-token)  
I can get authorization code but cannot exchange authorization code for access token, always get 404 error.

POST request and all params in body:

```auto
curl --location 'https://volhal.atlassian.net/oauth/token' \
--header 'Content-Type: application/json' \
--data '{
    "grant_type": "authorization_code",
    "client_id": "client_id_here",
    "client_secret": "client_secret_here",
    "code": "code_here",
    "redirect_uri": "https://localhost"
}'

```

---

<div class="post-metadata">

**Author:** ![ibuchanan](https://sea1.discourse-cdn.com/atlassiandeveloper/user_avatar/community.developer.atlassian.com/ibuchanan/32/35815_2.png) [@ibuchanan](https://community.developer.atlassian.com/u/ibuchanan)\
**Post date:** [June 15, 2023, 4:13pm UTC](https://community.developer.atlassian.com/t/404-error-code-when-try-to-get-access-token/70398/2 "2023-06-15T16:13:20Z")

</div>

@Igor_T,

The URL given in that guide is `https://auth.atlassian.com/oauth/token`. It’s not a path on your site, as you have in your curl.

---

<div class="post-metadata">

**Author:** ![Igor\_T](https://avatars.discourse-cdn.com/v4/letter/i/f9ae1b/32.png) [@Igor\_T](https://community.developer.atlassian.com/u/Igor_T)\
**Post date:** [June 16, 2023, 6:33am UTC](https://community.developer.atlassian.com/t/404-error-code-when-try-to-get-access-token/70398/3 "2023-06-16T06:33:57Z")

</div>

> [@ibuchanan](#):
>
> [https://auth.atlassian.com/oauth/token](https://auth.atlassian.com/oauth/token)

Oh, yes, thank you! I believed it was kind of example path.
