In our self-hosted Ory environment we're trying to...
# talk-kratos
c
In our self-hosted Ory environment we're trying to logout the current Kratos session in our login-logout-consent app as part of some Hydra sign-out flows, however calling kratos'
/self-service/logout/api
URL doesn't work with the value of the user's
ory_kratos_session
cookie. As the logout is called from the login-logout-consent app and not a real browser I thought this was the correct way, rather than using
/self-service/logout/browser
am I wrong? It seems the browser session cookie/token and the app session token are different, which wasn't immediately obvious but is hinted to by https://www.ory.sh/docs/kratos/reference/api#tag/frontend/operation/listMySessions which mentions the expected session token formats.
The only alternatives I can think are to call DELETE on the
/admin/sessions/{id}
endpoint or ignore the warning an use the
/self-service/logout/browser
flow from the API. It would be helpful to know the correct direction.