Forum Discussion

MahindraManoj's avatar
MahindraManoj
Copper Contributor
Feb 18, 2022
Solved

Cannot resolve CORS error after deleting the custom domain names created for the API M endpoints

I deployed an API M instance in internal vnet mode which will host all the endpoints inside my vnet. We have an app service that acts as the API M backend. I wanted to expose the api m gateway public...
  • MahindraManoj's avatar
    Feb 22, 2022
    I found out the reason for this. When we create a custom domain name for developer portal of the API M, there is a setting/check-box that says enable CORS. When it is selected, it creates a global CORS policy (on all APIs) keeps the origin as the new custom domain name. It ignored the policy that has been applied on our specific api. After deleting the global cors policy, things started working fine.

Resources