Onboarding Flow¶
Trigger¶
New employee or pilot customer needs access to SmartKitten.
Flow¶
sequenceDiagram
participant U as User
participant FE as Frontend
participant ACC as Account
participant ORG as Organization
participant BIL as Billing
U->>FE: Open register
FE->>ACC: POST register
ACC-->>U: Verification email
U->>ACC: Verify email
U->>FE: Login
FE->>ACC: POST login
ACC-->>FE: JWT
alt Create org
U->>ORG: Create organisation
else Join org
U->>ORG: Join by tagline
end
FE->>BIL: Load subscription
BIL-->>FE: Plan and entitlements
FE-->>U: Workspace home
Steps¶
- User opens registration; provides credentials and organisation tagline (join) or creates new org.
- Account service stores user; sends verification email (Resend).
- User verifies email via link.
- User logs in; receives JWT with
sub,org,role. - Organization service confirms membership (or creates org + owner).
- Frontend loads subscription from Billing; displays plan on profile.
- User lands in workspace (playground / user hub).
Outcome¶
Active user inside exactly one organisation with verified email and visible entitlements.
Plan constraints¶
Free tier may limit tokens, devices, and vision from first login.
Failure modes¶
| Failure | User impact | Mitigation |
|---|---|---|
| Email not verified | Login blocked or limited | Resend verification |
| Wrong tagline | Cannot join org | Admin shares correct tagline |
| Org creation conflict | Duplicate tagline | Choose unique tagline |