# OAuth access token

**URL:** <https://forum.mapillary.com/t/oauth-access-token/6945>\
**Category:** Uncategorized\
**Created:** [April 16, 2023, 11:00am UTC](https://forum.mapillary.com/t/oauth-access-token/6945 "2023-04-16T11:00:37Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![journeai](https://avatars.discourse-cdn.com/v4/letter/j/e19adc/32.png) [@journeai](https://forum.mapillary.com/u/journeai)\
**Post date:** [April 16, 2023, 11:00am UTC](https://forum.mapillary.com/t/oauth-access-token/6945/1 "2023-04-16T11:00:37Z")

</div>

Trying to follow [Getting access token for uploads in v4](https://forum.mapillary.com/t/getting-access-token-for-uploads-in-v4/4993) a  
curl [https://graph.mapillary.com/token](https://graph.mapillary.com/token)   
-H “Content-Type: application/json”   
-H “Authorization: OAuth CLIENT\_SECRET” \ from dev console  
-d’  
{  
“grant\_type”: “authorization\_code”,  
“code”: “LONG\_AUTHORIZATION\_CODE”, \from url redriects  
“client\_id”: 1234  
}’

and am getting. Any idea how to debug?  
{“error”:{“message”:“Invalid OAuth access token - Cannot parse access token”,“type”:“OAuthException”,“code”:190,“fbtrace\_id”:“AXwX6YzoYvSrpS\_1Y1lUyZG”}}

LONG\_AUTHORIZATION\_CODE was correctly returned but now the final step fails.  
Feels slightly overcomplicated?

---

<div class="post-metadata">

**Author:** ![nikola](https://avatars.discourse-cdn.com/v4/letter/n/a88e57/32.png) [@nikola](https://forum.mapillary.com/u/nikola)\
**Post date:** [April 17, 2023, 11:16am UTC](https://forum.mapillary.com/t/oauth-access-token/6945/2 "2023-04-17T11:16:04Z")

</div>

Hi! I think there’s two things:

“client\_id” - it should be the “Client ID” from your app in the dev console ([https://www.mapillary.com/dashboard/developers](https://www.mapillary.com/dashboard/developers))

-H “Authorization: OAuth CLIENT\_SECRET” should be the “Client secret” from the dev console.

---

<div class="post-metadata">

**Author:** ![journeai](https://avatars.discourse-cdn.com/v4/letter/j/e19adc/32.png) [@journeai](https://forum.mapillary.com/u/journeai)\
**Post date:** [April 17, 2023, 11:55am UTC](https://forum.mapillary.com/t/oauth-access-token/6945/3 "2023-04-17T11:55:13Z")

</div>

yeah, i did not post these here but as the comment says i used dev console ones.  
What else can i try?

curl [https://graph.mapillary.com/token](https://graph.mapillary.com/token)  
-H “Content-Type: application/json”  
-H “Authorization: OAuth CLIENT\_SECRET” \ from dev console  
-d’  
{  
“grant\_type”: “authorization\_code”,  
“code”: “LONG\_AUTHORIZATION\_CODE”, \from url redirects  
“client\_id”: 1234 \ from dev console  
}’

---

<div class="post-metadata">

**Author:** ![journeai](https://avatars.discourse-cdn.com/v4/letter/j/e19adc/32.png) [@journeai](https://forum.mapillary.com/u/journeai)\
**Post date:** [April 18, 2023, 8:01pm UTC](https://forum.mapillary.com/t/oauth-access-token/6945/4 "2023-04-18T20:01:26Z")

</div>

Is there a support i can contact? Out of ideas

---

<div class="post-metadata">

**Author:** ![journeai](https://avatars.discourse-cdn.com/v4/letter/j/e19adc/32.png) [@journeai](https://forum.mapillary.com/u/journeai)\
**Post date:** [April 25, 2023, 8:04am UTC](https://forum.mapillary.com/t/oauth-access-token/6945/5 "2023-04-25T08:04:52Z")

</div>

> [@Getting access token for uploads in v4](https://forum.mapillary.com/t/getting-access-token-for-uploads-in-v4/4993/4):
>
> Seeing the same thing as everyone else. The documentation says contradicting things like /connect vs /authorize. No details on what needs to be sent to /token, and I get an unhelpful error that I can’t lookup anywhere: { "error": { "message": "Invalid OAuth 2.0 Access Token", "type": "MLYApiException", "code": 190, "error\_data": {}, "fbtrace\_id": "A9-7asFpQ0nlkaMYtAn-YNE" } } When I tried the following: const authResponse = await fetch(`https://graph.mapillary.com/toke…

---

<div class="post-metadata">

**Author:** ![journeai](https://avatars.discourse-cdn.com/v4/letter/j/e19adc/32.png) [@journeai](https://forum.mapillary.com/u/journeai)\
**Post date:** [April 25, 2023, 8:56am UTC](https://forum.mapillary.com/t/oauth-access-token/6945/6 "2023-04-25T08:56:01Z")

</div>

Finally managed with postman. Could have been less painful … no idea why curl did not work

---

<div class="post-metadata">

**Author:** ![Borovanhout](https://avatars.discourse-cdn.com/v4/letter/b/3ec8ea/32.png) [@Borovanhout](https://forum.mapillary.com/u/Borovanhout)\
**Post date:** [February 21, 2024, 10:15am UTC](https://forum.mapillary.com/t/oauth-access-token/6945/7 "2024-02-21T10:15:45Z")

</div>

Could you explain to me how you did it? I also cant figure it out
