Skip to content

feat(auth): self-service FID relink from the Profile page - #1231

Merged
scobru merged 1 commit into
devfrom
claude/dazzling-franklin-yj0co6
Oct 6, 2026
Merged

scobru merged 1 commit into
devfrom
claude/dazzling-franklin-yj0co6

Conversation

@scobru

@scobru scobru commented Oct 6, 2026

Copy link
Copy Markdown
Owner

Summary

  • A user still signed in on the instance can press Link my FID identity to this account in Profile. POST /api/auth/zen/link-code mints a single-use code (5 min, in memory); the webapp opens tunecamp.org/profile.html#linkCode=…&instance=….
  • /api/auth/zen/challenge?linkCode= and /api/auth/zen/set accept the code in place of a session; /set is CORS-open only when no credentials are sent. Success clears any pending relink request.
  • FID_KEY_CHANGED message points to the new button; docs EN/IT and CHANGELOG updated.

Test plan

  • full jest (203 suites), tsc --noEmit, webapp tsc
  • new integration tests: code needs a session, binds once, wrong key 400, spent/unknown code 401
  • needs the matching tunecamp-website profile.html change to be deployed

🤖 Generated with Claude Code

https://claude.ai/code/session_01FeCp9YZh9dCEHXtRdpVeFe


Generated by Claude Code

A signed-in user can mint a single-use link code (5 min) and bind a new FID
key through the portal, without administrator approval.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FeCp9YZh9dCEHXtRdpVeFe
@scobru
scobru marked this pull request as ready for review October 6, 2026 18:05
@scobru
scobru merged commit 0e7fecb into dev Oct 6, 2026
4 checks passed
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