Intermittent 401 when getting entitled tiers

Hi all,

A subset of users get the following response I’m trying to get info on whether they pledge to my tiers:

GET https://www.patreon.com/api/oauth2/v2/identity?include=memberships.currently_entitled_tiers

{
  "errors": [
    {
      "id": "redacted",
      "code_name": "Unauthorized",
      "code": 1,
      "title": "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.",
      "status": "401",
      "challenge_metadata": null
    }
  ]
}

It only seem to happen to some but not all users, and not all the time. I have made a fresh account, paid for my own patreon, and can still only replicate the issues rarely with no real logic in when it happens. I assume it means the way I am handling authentication is correct, otherwise it would fail all the time, right?

My requested scope is ‘identity identity.memberships identity[email]’, though I have been changing it based on forum posts I have found to no avail.

Even using postman, from what I can tell the issue is intermittent. It doesn’t seem I’m the only one with the issues, I have found many thread threads dating as far back as 2019, none of which appear to have a solution (and many are dimply the question unanswered).

Is there something I am doing wrong? I am not using any frameworks, I have checked the tokens are being passed properly… I genuinely don’t know what else I can try.

I had to disable auth entirely for now, which defeats the point of integrating Patreon in the first place. Is there maybe a debug param I could pass to know more about what’s wrong?

Thank you!

I added advanced logging. Turns out, it’s not intermittent, it’s everybody but me whose login is failing. For some reason all my attempts (regardless of account) work, but anyone else’s get a 401.