Response code: 401

Dear All ,
Since updated Patreon plugin to Version 1.5.0 I’m getting following error

Response code: 401 Response :{“errors”:[{“code”:1,“code_name”:“Unauthorized”,“detail”:“The server could not verify that you are authorized to access the URL requested. You either supplied the wrong credentials (e.g. a bad password), or your browser doesn’t understand how to supply the credentials required.”,“id”:“d17a6005-b80d-4911-89e7-8158faf1d0d4”,“status”:“401”,“title”:“Unauthorized”}]}

What I tried to solve
** Deleted API in Patreon and re-created and re-connect it (Nothing Changed)
** Deleted Plugin and it’s database and re-installed in my website (Nothing Changed)

** It’s marked as V.2

Any other solution ideas please … Thanks in Advance

Here you can see some of errors

0.24 days ago

Response code: 401 Response :{“error”: “invalid_grant”}

0.24 days ago

Response code: 401 Response :{“errors”:[{“code”:1,“code_name”:“Unauthorized”,“detail”:“The server could not verify that you are authorized to access the URL requested. You either supplied the wrong credentials (e.g. a bad password), or your browser doesn’t understand how to supply the credentials required.”,“id”:“d17a6005-b80d-4911-89e7-8158faf1d0d4”,“status”:“401”,“title”:“Unauthorized”}]}

0.84 days ago

Response code: 401 Response :{“error”: “invalid_grant”}

0.84 days ago

Response code: 401 Response :{“errors”:[{“code”:1,“code_name”:“Unauthorized”,“detail”:“The server could not verify that you are authorized to access the URL requested. You either supplied the wrong credentials (e.g. a bad password), or your browser doesn’t understand how to supply the credentials required.”,“id”:“c2a84c96-69b5-4598-b595-fe03897051f7”,“status”:“401”,“title”:“Unauthorized”}]}

0.84 days ago

Response code: 401 Response :{“error”: “invalid_grant”}

0.84 days ago

Response code: 401 Response :{“errors”:[{“code”:1,“code_name”:“Unauthorized”,“detail”:“The server could not verify that you are authorized to access the URL requested. You either supplied the wrong credentials (e.g. a bad password), or your browser doesn’t understand how to supply the credentials required.”,“id”:“9c4fdcdb-d350-4984-9e53-e0cb7399887a”,“status”:“401”,“title”:“Unauthorized”}]}

0.84 days ago

Response code: 401 Response :{“error”: “invalid_grant”}

0.84 days ago

Response code: 204 Response :

0.84 days ago

Response code: 401 Response :{“error”: “invalid_grant”}

0.84 days ago

Response code: 401 Response :{“error”: “invalid_grant”}

0.84 days ago

Response code: 401 Response :{“error”: “invalid_grant”}

0.84 days ago

Response code: 401 Response :{“error”: “invalid_grant”}

0.84 days ago

Response code: 401 Response :{“error”: “invalid_grant”}

0.84 days ago

Response code: 401 Response :{“error”: “invalid_grant”}

0.84 days ago

Response code: 401 Response :{“error”: “invalid_grant”}

0.84 days ago

Response code: 401 Response :{“error”: “invalid_grant”}

When was the first time you installed Patreon WordPress? This may be a leftover v1 installation conflicting with new v2 api.

I think it was October '19 my first installation …

Lets use the forum instead so others can also read the issues and their solutions.

Where are you hosted?

Dreamhost VPS also I have Wordfence (only for your info)

Wordfence can interfere with a lot of things, including remote calls and remote responses. Can you try disabling it for a while to see if these errors will keep appearing in the log?

Ok , I am disabling wordfence and checking situation… Will report to result as soon as possible…

Good luck.

Also note that if you have a mod like mod_security with an Apache webserver at your host, that may interfere with a lot of stuff if its rules are configured aggressively. You may also want to contact your host about that.

Ok, After disabling WordFence everything is looking fine… Thanks

1 Like

@codebard I’m seeing something similar on my site, i.e. my last 50 errors are just:

Response code: 401 Response :{"error": "invalid_grant"}

All of them happening 0 days ago, so looks like a constant issue. I haven’t been updating any plugins recently so currently I’m running PW 1.4.8 and PPP 1.4.6 on WP 5.3.2.

Does it simply mean that my Patrons are forgetting their passwords and inputting wrong ones? Or it may mean something bigger?

Can you try Disconnecting your site and then reconnecting it through the buttons in plugin settings?

Also - do you also have Wordfence installed?

Nope, I don’t use Wordfence. I tried using that “Disconnect site” button on my staging environment but got this error:

BTW the “try again” link directs to http://test.codebard.com/wp-admin/admin.php?page=patreon-plugin&patreon_wordpress_action=disconnect_site_from_patreon

Which version of PW do you have as of this moment?

PW is 1.5.2, PPP is 1.4.6.

Before I couldn’t see any consequences of that, but now I’m getting a few Patrons saying that they can’t access content when they’re logged in. So I reckon there is a chance it’s connected.

Now the thing is, the faulty redirect to test.codebard.com was fixed long before 1.5.2. It is not present in PPP either. But your site has that bug still for some reason. Despite being 1.5.2.

This raises the suspicion that your site may still be keeping an old version of the code in part due to something like opcode caching.

Please try to confirm whether you have an opcode caching plugin in your site, or whether your host has opcode caching. In either case cleaning entire opcode cache and retrying would provide pointers for this. Actually, likely fix it outright.