Why Postman and Fiddler never generate preflight r

2019-07-09 11:05发布

问题:

When ever I request to API through Postman or Fiddler never generate Preflight request. Both tool always generate Post or Get request. But when we are generating the request from file or other source then it first generate Preflight request and send HTTP OPTIONS.

Regards,

回答1:

The reason for that is because the CORS only applies to sandboxed environments, like the browser. When making a direct HTTP request with Fiddler you don't need any CORS. The pre-flight request is sent by the browser before sending the actual request to ensure that CORS is enabled.