Hi, first of all, great product. Very much enjoying it ![]()
This question could be a duplication of this. Tried, looked and still doesn’t work so here I leave my own question again.
The question is simple. Why am I keep getting 400 whilst I could do all other API calls?
For example, I am currently using link for authentication with callback, just as below.
https://directus.domain.com/auth/login/google?redirect=https://site.domain.com/api/users/sync
By doing so, I was able to get a cookie to be used on both sites, using Directus as a single source of truth.
And, the deployment has following configuration.
AUTH_PROVIDER: "google"
AUTH_DISABLE_DEFAULT: true
AUTH_GOOGLE_MODE: "session"
AUTH_GOOGLE_DRIVER: "openid"
...
SESSION_COOKIE_NAME: "__Secure-my-session"
SESSION_COOKIE_DOMAIN: "domain.com"
SESSION_COOKIE_SECURE: true
SESSION_COOKIE_SAME_SITE: "lax" # but also works with None atm.
Everything works just fine, until, realizing that the logout requires me to have a refresh token.
So, basically I can control how to login, but I cannot control how to logout other than deleting the cookie on the logged-in session.
One thing really confuses me is that all other APIs do work just fine with this session cookie. I can get, put, patch. It’s just that I believe no refresh, no logout that is ever working.
Is there something I have missed? or.. should I run my own authentication layer and connect with the Directus instance?