CORS Sitecore API

This is another very important Sitecore API expose blog. Very simply, we can resolve the CORS issue. To do that, we have to do the below.

  1. Add a custom attribute called “AllowCrossSite” like the below code. I have added “ * ” in “Access-Control-Allow-Origin”. We can define the URL like
  2. Simply add this attribute in our controller like –
  3. Deploy and build.