Given the circumstances:
- Alice is logged in
- Alice would like to add Bob to the organization
- Some transaction should be able to happen where Bob gets added to Alice's organization
- Bob logs in using his passkey and sees the dashboard for the organization
Considerations
- We don't have a good distinction between "user" settings and "organization" settings
- Users can belong to multiple organizations, but in practice, every API route only selects the first organization
- If we handle it as "new user registration", we could probably "just" not create a new org and add them to the existing one
Implementation Ideas
- Link Based: Alice sends a link to Bob, who can then use it to register as a user under Alice's organization
- Registration Code Based: Alice clicks a button in the dashboard that generates a registration code. When that registration code is used, instead of creating a new user, the user gets added to the existing organization
Both implementations would likely require time gating either the link or the code to probably within 5 minutes of it being created.
Given the circumstances:
* Alice is logged in
* Alice would like to add Bob to the organization
* Some transaction should be able to happen where Bob gets added to Alice's organization
* Bob logs in using his passkey and sees the dashboard for the organization
# Considerations
* We don't have a good distinction between "user" settings and "organization" settings
* Users _can_ belong to multiple organizations, but in practice, _every_ API route only selects the _first_ organization
* If we handle it as "new user registration", we could probably "just" not create a new org and add them to the existing one
# Implementation Ideas
* **Link Based:** Alice sends a link to Bob, who can then use it to register as a user under Alice's organization
* **Registration Code Based:** Alice clicks a button in the dashboard that generates a registration code. When that registration code is used, instead of creating a new user, the user gets added to the existing organization
Both implementations would likely require time gating either the link or the code to probably within 5 minutes of it being created.