Azure / APICenter-Portal-Starter

Reference implementation of API Center portal for a web-based API discovery and consumption experience
https://learn.microsoft.com/en-us/azure/api-center/enable-api-center-portal
MIT License
23 stars 78 forks source link

API Listing is blocked by CORS - policy #33

Open Asim-21 opened 3 months ago

Asim-21 commented 3 months ago

I am getting the same error "has been blocked by CORS policy: Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled." image

Asim-21 commented 3 months ago

the error is fixed but all the APIs are not listed, only 5 are shown I have imported APIs from API Management. the ones that are listed on Portal also throw the following errors after navigating a bit

image

Asim-21 commented 3 months ago

@pierceboggan could you have a look? :)

jeanramal commented 2 months ago

@pierceboggan could you have a look? :)

The free layer have a limitations, max 5 APIs: https://github.com/Azure/APICenter-Portal-Starter?tab=readme-ov-file#limitations

Othersise, how to solve the CORS problem? with the no-cors mode ? where you applied it?