Is your feature request related to a problem? Please describe.
The web frontend plans to have an invitation-only registration flow (/invite/[id]), but there is no backend support for generating or validating registration invites.
Describe the solution you'd like
Implement the following endpoints:
POST /admin/invite — Generate a new invite token (admin-only, authenticated)
GET /invite/{token} — Validate an invite token and return its details
POST /register/{token} — Register a new user using an invite token (creates user + consumes the invite)
Invite tokens should:
- Be UUID-based or similar
- Have an expiration date
- Be single-use (consumed after registration)
- Track who created the invite
Describe alternatives you've considered
- Public registration with email verification (not desired — invites only)
- Hardcoding invite codes in config (not scalable)
Additional context
Replaces the need for a public /register endpoint or email verification flow. The web frontend will have an /invite/[id] page that calls GET /invite/{token} to validate and POST /register/{token} to complete registration.
Is your feature request related to a problem? Please describe.
The web frontend plans to have an invitation-only registration flow (
/invite/[id]), but there is no backend support for generating or validating registration invites.Describe the solution you'd like
Implement the following endpoints:
POST /admin/invite— Generate a new invite token (admin-only, authenticated)GET /invite/{token}— Validate an invite token and return its detailsPOST /register/{token}— Register a new user using an invite token (creates user + consumes the invite)Invite tokens should:
Describe alternatives you've considered
Additional context
Replaces the need for a public
/registerendpoint or email verification flow. The web frontend will have an/invite/[id]page that callsGET /invite/{token}to validate andPOST /register/{token}to complete registration.