feat(auth): support tenantless provisioning and gated self-service workspace creation

Allow deployments to register users without auto-creating a personal tenant, expose creation policy via /auth/me, and guide tenantless accounts through a workspace onboarding flow.
This commit is contained in:
wizardchen
2026-07-13 18:04:14 +08:00
committed by lyingbug
parent 50b8c0a72e
commit ecf2c1fb9b
36 changed files with 1543 additions and 89 deletions
+2 -2
View File
@@ -24,8 +24,8 @@ interface LoginResponseLike {
// Password-login response uses `active_tenant`; the OIDC callback
// response uses `tenant` (legacy backward-compat name on the Go side).
// Accept either so callers don't have to normalise.
active_tenant?: { id?: number | string; name?: string }
tenant?: { id?: number | string; name?: string }
active_tenant?: { id?: number | string; name?: string } | null
tenant?: { id?: number | string; name?: string } | null
memberships?: Array<{ tenant_id?: number | string; role?: string }>
}