stephenharris / Event-Organiser

WordPress plug-in, Event Organiser, development repository
http://wordpress.org/extend/plugins/event-organiser/
GNU General Public License v3.0
100 stars 76 forks source link

403 error posting to "wp-json/eventorg/v1/booking" #517

Open Boeeerb opened 2 years ago

Boeeerb commented 2 years ago

I've noticed that if some fields are left blank, aside from the name and email, attempting to click Book will return a 403 error to the POST, leaving the user with the spinner.

image

You can try it on https://www.jackcollisonsoccerschool.com/course/milton-keynes-half-term-camp-5/ Leave either Child Name blank, or not choose a ticket, I have been able to replicate this with being logged in or not.

I haven't been able to pinpoint if it's a server or Event Organiser issue

stephenharris commented 2 years ago

Hi @Boeeerb I've just tested this out, and I get a "403 Forbidden Access to this resource on the server is denied!" message. That's neither a WordPress nor an Event Organiser error message, so I suspect you have some configured on the server that's doing that. Possibly even a plug-in that restricts access to certain endpoints on the WP REST API.

(In case it helps I noticed curl -v https://www.jackcollisonsoccerschool.com/wp-json/eventorg/v1/event/1/availability returns the same, but curl -v https://www.jackcollisonsoccerschool.com/wp-json/wp/v2/posts returns actual posts)