Skip to main content

I'm aware of whitelisting domains for CORS from Setup->Security->CORS, but I'm currently developing an application locally and am encountering the lack of the 'Access-Control-Allow-Origin' header in a ReST API POST response (the "pre-flight" OPTIONS response has this header). The POST request succeeds, but the response is blocked due to CORS restrictions.

I cannot add the localhost hostname to the whitelist of my sandbox org. I'm wondering if anyone has an idea of how to get around this during development without setting up a proxy inside a valid domain?

1 Antwort