Response to preflight request doesn't pass access control check - how to fix?

429 views
Skip to first unread message

jesa...@gmail.com

unread,
Feb 9, 2018, 4:25:33 PM2/9/18
to Eventbrite API
I am working on creating an app that looks for certain event types on Eventbrite and returns then as a list to the user.

I'm using my Anonymous access OAuth token since I'm not looking for specific user information, but when I try to send the request, this is the error I am receiving:

Failed to load https://www.eventbrite.com/developer/v3/endpoints/events/?q=book&location.within=30mi&location.address=11101&token=XXX: Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost:8080' is therefore not allowed access.

I also tried running this from my github address so it was an https, but still no success.

Anyone have thoughts on why I am getting this error and what I can change?


Thank you!

Chris Cummings

unread,
Feb 9, 2018, 4:51:52 PM2/9/18
to Eventbrite API
Hi there,

It sounds like you are calling this from browser side javascript code. So the error that you're seeing in your javascript console may be a browser security thing. You should search for cross-origin requests relating to whatever fetch library you're using for more information about that.

Secondly, the example url you passed there is a path to the documentation. So the actual request should look something like this
https://www.eventbriteapi.com/v3/events/search/?q=book&location.within=30mi&location.address=11101&token=YOUR-TOKEN


jesa...@gmail.com

unread,
Feb 12, 2018, 3:14:24 PM2/12/18
to Eventbrite API
I think I was able to figure out the CORS issue. Thank you for the correct request path! Very helpful :)
Reply all
Reply to author
Forward
0 new messages