How can I prevent/disable Cloudflare Access redirect for preflight request?

I have 2 endpoint:

app.domain.com for the frontend and
api.domain.com for the backend

I enabled both site with cloudflare acess.
When I login into cloudflare acess from the frontend I want the backend to be authenticated too.
So perhaps I should send the cookie to the backend using xmlhttprequest.withCredentials = true

But the request have a preflight and it gets redirected.
How can I disable redirect on preflight? or there’s other method that recommended?
Thanks!

This question is reposted to the security-access category without tags, as suggested by cloonan

2 Likes

Bumping into this as well. Anything other than app leve/codel workarounds?