After an Open API Spec file has been loaded to the Developer Portal and the “Try It Out” functionality is used, a CORS error is returned in the browser;
Server response
TypeError: Failed to fetchThe same API works fine when using a different client such as curl or Insomnia.
Inside the browsers developer tools under “Console” you can see the CORS preflight error.
Error:
"Access to fetch at '<KONGHOSTNAME>:<KONGPROXY-PORT>/dadjokes' from origin '<KONGDEVPORTAL-HOST>:8003' 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."