You need to set the access control allow origin header in the API gateway. 'Options' request must have the conditions set for CORS.
Follow this article https://docs.aws.amazon.com/apigateway/latest/developerguide/how-to-cors-console.html