✈ CORS preflight requests

Guillaume edited this page Aug 2, 2018 · 3 revisions

When CORS setting is enabled for an environment, Mockoon will respond with the following headers and status 200 to all CORS preflight OPTIONS requests which are not catched by an OPTIONS route:

Access-Control-Allow-Origin: *
Access-Control-Allow-Methods: GET,POST,PUT,PATCH,DELETE,HEAD,OPTIONS
Access-Control-Allow-Headers: Content-Type, Origin, Accept, Authorization, Content-Length, X-Requested-With

If you define an OPTIONS route you must define CORS headers manually for this route.

You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.