lynne424
Forum Replies Created
-
Hi Justin,
Yes, I do make sure that I’m logged out from WordPress site when making authenticated rest calls.
The issue still occurs for POSTs calls. My guess is the issue is caused because the initial POST call is being redirected to a second POST call without the token, which is probably a bug in the Rest API plugin that the query params are not being sent in the second POST, which occurs when the call is Cross Domain. I have a work around for now, until I have more time to figure it out. (GET calls work)
One thought… can I send the token in the body or header of the POST (vs sending via query params)?
Thanks,
LynneForum: Plugins
In reply to: [WP OAuth Server (OAuth Authentication)] CORS – Preflight Request ProblemsThanks for the quick response Justin. Your suggestion (with some modifications/tweaks for my particular app) is working.
Forum: Plugins
In reply to: [WP OAuth Server (OAuth Authentication)] CORS – Preflight Request ProblemsHi Justin,
I’m running into this same problem when issuing a POST request to get a token. The token request call is working from Postman, but when sending the request from an angular/ionic client, the browser is sending the OPTIONS request first, which the plugin returns a 405. So, without CORS support from the plugin to respond correctly to an OPTIONS request, we cannot use this for authenticating our wp rest api calls. Any advise is greatly appreciated.
Thanks,
Lynne