Skip to main content
17 events
when toggle format what by license comment
May 14 at 19:54 history edited rene
edited tags
Jan 24 at 0:04 comment added Ryan @rene Thanks for the idea. But even after using 'headers' => [ 'User-Agent' => "Mozilla/5.0 (Windows NT 10.0; Win64; x64)", ], I still get the Just a moment... error response.
Jan 23 at 16:56 comment added rene How long is the UserAgent header that is send in the request by Guzzle? If it is the default one it might be too short: meta.stackexchange.com/a/328381
Jan 23 at 16:42 history edited Ryan CC BY-SA 4.0
added error response header and body
Jan 22 at 16:13 history edited rene
edited tags
Jan 22 at 16:13 answer added rene timeline score: 5
Jan 22 at 15:57 comment added Ryan @rene Ignore that I even tried application/json when using reqbin since that was a mistake, and my PHP app has always been posting form_params like stackoverflow.com/a/34411797/470749. I don't know why my PHP app would start receiving these unhelpful error messages when I haven't changed the app in probably years, and it's worked for a long time.
Jan 22 at 15:14 comment added rene So you're saying that you posted to stackoverflow.com/oauth/access_token/json with an application/json content and that is now broken, but using application/x-www-form-urlencoded on that same end-point works. I didn't assume that application/json on oauth/access_token/json was even an option because the docs don't state that. Only that the response will be a json object.
Jan 21 at 22:57 comment added Ryan api.stackexchange.com/docs/authentication hasn't been helpful. At stackapps.com/apps/oauth/view/13067 I see that my OAuth Domain and Application Website are way outdated, but I doubt it's a problem, both because I don't think those values get used anywhere and also because the values I see here are so old that my app ought to have broken much earlier if these mattered. By posting into reqbin.com/post-online in x-www-form-urlencoded mode instead of application/json, I'm able to retrieve an access_token. This still doesn't explain why my app is suddenly broken.
Jan 21 at 22:35 comment added Ryan I wonder if this relates to my problem (stackoverflow.com/q/77446750/470749). I'm getting GuzzleHttp\Exception\ClientException: Client error: `POST https://stackoverflow.com/oauth/access_token/json` resulted in a `403 Forbidden` response: <!DOCTYPE html><html lang="en-US"><head><title>Just a moment...</title><meta http-equiv="Content-Type" content="text/htm (truncated...) in /mnt/c/code/stackExchangeBackupDemo2/vendor/guzzlehttp/guzzle/src/Exception/RequestException.php:113
Jan 21 at 22:35 comment added Ryan @Makyen Thanks. Mine still isn't working, and I haven't figured it out yet. I'll post another clue I noticed though:
Jan 21 at 16:50 comment added Makyen I don't have a view of the network traffic for our project which uses the explicit flow. However, I have attempted a sequence of actions which requires the explicit flow to be functioning and was able to authorize. In other words, I don't appear to be able to reproduce the issue. IIRC, "SE API: Recent OAuth 2.0 implicit flow breaking change" doesn't affect the explicit flow, but is the last change I recall seeing. The last we had a problem with the explicit flow, the issue was that we were consistently running out of SE API quota.
Jan 21 at 16:04 comment added Makyen When was the last time this worked for you?
Jan 20 at 2:19 comment added Ryan @rene Step 4 of explicit auth. Thanks.
Jan 19 at 21:16 comment added rene I can't reproduce. You are doing the explicit OAuth 2.0 flow, right? If so, which steps fails in api.stackexchange.com/docs/authentication then? Step 1 or Step 4?
S Jan 19 at 19:35 review First questions
Jan 26 at 11:49
S Jan 19 at 19:35 history asked Ryan CC BY-SA 4.0