Skip to content

feat: call logout endpoint for dex - #852

Open
CasLubbers wants to merge 1 commit into
mainfrom
APL-2119
Open

CasLubbers wants to merge 1 commit into
mainfrom
APL-2119

Conversation

@CasLubbers

@CasLubbers CasLubbers commented Oct 2, 2026 •

Copy link
Copy Markdown
Contributor

Signed-off-by: Cas Lubbers <clubbers@akamai.com>
Copilot AI balanced review requested due to automatic review settings October 2, 2026 08:40

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟡 Changes recommended

The global 401 interceptor can prevent the Dex logout redirect and send users back through login.

Review effort: Balanced
Findings: 1 Medium severity

Open (1)
What changed in this PR

Adds backend logout handling before redirecting users to Dex logout.

Changes:

  • Adds the /v2/user/logout mutation.
  • Calls logout before redirecting.
  • Adds logout-flow tests.
File Description
src/​redux/​otomiApi.ts Exposes the logout endpoint and hook.
src/​pages/​Logout.tsx Calls the endpoint before redirecting.
src/​pages/​Logout.test.tsx Tests success, failure, and fetch-error flows.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread src/pages/Logout.tsx
useEffect(() => {
if (fetchError) window.location.reload()
else window.location.href = '/platform-logout'
else logout().finally(() => window.location.assign('/platform-logout'))

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants