typebot.io
typebot.io copied to clipboard
Webhooks failing blocked by CORS policy
TypeBot webhooks are failing due to CORS policy:
Access to fetch at 'https://bot...../executeWebhook' from origin 'https://builder.......' has been blocked by CORS policy: 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.
When executing a webhook in the Typebot Builder, the request fails.
Chrome reports:
A cross-origin resource sharing (CORS) request was blocked because it contained request headers that were neither CORS-safelisted (Accept, Accept-Language, Content-Language, Content-Type) nor allowed by the Access-Control-Allow-Headers response header of the associated preflight request.
To fix this issue, include the additional request headers you want to use in the Access-Control-Allow-Headers response header of the associated preflight request.
Disallowed header: content-type
I resolved this in my environment by forcing the related CORS policy on my proxy (Traefik), but I still believe the setting should be set via Typebot and requires further investigation.
Closing this as I couldn't reproduce and nobody else seems to have this issue for now.
Feel free to reopen if we gather more information.