Pinterest API - Authorization Code - Error Code '2'

We get the following error when trying to get an authentication code when the user is not yet registered on Pinterest:

{"status": "failure", "message": "Authentication failed.", "code": 2, "data": null}

Example URL that we use for authentication:

https://api.pinterest.com/oauth/?client_id=1234567891011121314&redirect_uri=https://www.foobar.com/app/influencers/channels/callback/pinterest&scope=read_relationships,read_public&response_type=code&catebcfecbfccbcc0bc0fbc0fbcfcbfcc

This URL works fine if the user is already registered on Pinterest, it displays the application confirmation and returns the code as expected. However, it responds with an error if the user is not logged in.

Below is the following documentation:

https://developers.pinterest.com/docs/api/overview/ ?

+5
source share
1 answer

I am having a problem with multiple accounts in my application. Turns out they had an old set of permissions related to their account that needed to be cleared. I have done the following:

  • I logged in to "problem accounts" on Pinterest and went to the settings.
  • From there, I moved to the bottom, where the "Applications" are listed and access to my application is canceled.
  • As soon as I tried to reinstall, everything was fine from now on.

Hope this is similar to your situation and may solve the problem.

0
source

Source: https://habr.com/ru/post/1269753/


All Articles