Closed ashar340 closed 2 years ago
Hi @ashar340 could you solve?
Hi @ashar340 :wave:
Apologies for the late reply here, we don't actively monitor the GitHub issues for support requests. The fastest way to get support is to email support@smartcar.com or contact us via the live chat on https://smartcar.com/contact/.
I was able to look into your request using the provided request ID and I believe you're running into this error because the access token request was made with a redirect URI that is different than the one that the authorization code was sent to. The OAuth 2.0 spec requires that the redirect URI that is provided when exchanging be the exact same as the one that the authorization code was sent to.^1
Based on the redirect URIs that are configured on your Smartcar account I believe you have a backend and frontend app, the simple fix for this issue would be to update the configuration for the backend application to have the same redirect URI that is used in the frontend application (e.g. the one that starts with https://javascript-sdk.smartcar.com
). This won't require any other changes on your backend.
Let me know if that works out or if you're still running into issues.
It's working. Thank you :)
Great to hear! Feel free to reach out to support@smartcar.com if you have any further questions or comments :)
The server throws the following upon making the request to the
/exchange
API endpoint:Note that I did verify that the redirect uri, secret and clientID are correct.