GET request with Basic Auth working from Postman but not from the browser

前端 未结 3 1422
眼角桃花
眼角桃花 2021-01-05 23:44

I\'m working with an odata api, and when I\'m using postman to do a GET request, works perfect and I get the response as I was expecting.

But when I use a fetch req

3条回答
  •  盖世英雄少女心
    2021-01-06 00:33

    Ideal way is to allow at your server to allow calls from different domain, but if you don't have access to back-end, and testing services, you can install this chrome plugin to bypass pre-flight requests. cors chrome extension

提交回复
热议问题