3

Upon activating Oauth in Magento admin, there is no request sent to the callback URL. If I try to setup normal token authentication, there are no tokens provided.

I followed the documentation for oauth. Magento will call the URL at "Identity link URL" but it will not call the URL at "Callback URL." I setup the script at the Callback URL to send me an email when it is called. I can copy/paste the Callback URL from Magento admin into Postman to confirm the script at the URL works so I am sure the URL is correct and the script will take action when it is called. I am certain Magento is not sending anything to the Callback URL after selecting Activate, selecting Allow, getting expected redirect from Identity link URL, and selecting OK. My server never saw a request at the URL entered in Callback URL.

I also tried setting up basic token authentication following the token authentication documentation. This is basically the same process but Callback URL and Identity link URL are left blank. Again, I hit Authorize and Allow but only the Consumer Key and Consumer Secret blanks are filled in where the documentation suggests Magento should also provide tokens. What I see are the Access Token and Access Token Secret remain blank.

I have tried deleting values in oauth token table. That had no impact.

I tried using Postman to post to POST mywebsite.com/oauth/token/request using the guidance provided in this post.. I am certain I had the Oauth 1.0 fields filled out exactly as described in the post. However, Magento returned

oauth_problem=oauth_consumer_key+is+a+required+field%2C+oauth_signature+is+a+required+field%2C+oauth_signature_method+is+a+required+field%2C+oauth_nonce+is+a+required+field%2C+oauth_timestamp+is+a+required+field

There is nothing in the magento/var/log/ logfiles that reflect any of the activity associated with setting up the APIs.

I was using the API successfully in the past by requesting a token using /rest/default/V1/integration/admin/token with a username and password. At some point that stopped working and I actually don't recall where I got the username and password from as it is an odd looking username that I don't see in the list of users. I am trying to set up the Oauth process in its place but having no luck at all.

Any guidance is appreciated.

1

I found that the problem was I was attempting to use a callback URL that required basic authentication. I did not notice this when I tested the URL because my computer had already authenticated. I changed the callback URL to a valid URL that did not require authentication and everything now works as expected.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.