Add API for search event. Add CORS support