Trying to drop the Genesys Messenger widget into a Next.js app (App Router). Getting a CORS error on the initial handshake when the page renders server-side.
The widget script tag loads fine in the _document, but the fetch to /api/v2/conversations/webmessaging/... gets blocked by the browser.
Access to fetch at 'https://api.mypurecloud.com/api/v2/conversations/webmessaging/v1/sessions' from origin 'http://localhost:3000' 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.
I’ve added my origin to the allowed origins in the Messaging app settings. Still getting the 403 on the OPTIONS request. What am I missing?