fix: add credentials include option for HTTP requests#2436
fix: add credentials include option for HTTP requests#2436aymenhmaidiwastaken wants to merge 2 commits intobaptisteArno:mainfrom
Conversation
|
@aymenhmaidiwastaken is attempting to deploy a commit to the Typebot Team on Vercel. A member of the Team first needs to authorize it. |
|
Thanks for the PR! I'm a bit concerned about the security implications of this change though. When Since Could you share more about your use case? What kind of setup requires cookies to be sent cross-origin? |
|
Great point — you're right that blindly setting A better approach would be to make this configurable per HTTP request block, so the bot builder can explicitly opt in when they need cross-origin cookies (e.g., hitting their own API on a different subdomain). I can update the PR to:
That way it's opt-in and the builder takes responsibility for the target URL. Would that work for you? |
|
Thanks for the suggestion! A per-block toggle is definitely better than a global Before we go down the implementation path, could you describe your actual use case? What's the setup where |
Closes #1868
Adds
credentials: 'include'to the client-side fetch calls so cookies are forwarded with HTTP requests. This is needed for setups that rely on cookie-based auth or session management.Straightforward change — just wiring up the credentials option in the fetch config.