generated from coulomb/repo-seed
Finalize user-engine contracts and operability
This commit is contained in:
32
docs/ui-contracts.md
Normal file
32
docs/ui-contracts.md
Normal file
@@ -0,0 +1,32 @@
|
||||
# UI Handoff Contracts
|
||||
|
||||
Future self-service and scope-admin UIs should consume user-engine through a
|
||||
transport adapter that preserves the service shapes below.
|
||||
|
||||
## Self-Service Account UI
|
||||
|
||||
Required backend operations:
|
||||
|
||||
- `me` to resolve the current actor, user, account, and identity links.
|
||||
- `effective_profile` with the actor tenant and optional application id.
|
||||
- `projection` with `SELF_SERVICE` for editable user-visible fields.
|
||||
- `set_profile_value` for fields whose catalog mutability includes `USER`.
|
||||
- `audit_records` or a filtered audit transport for recent user-visible
|
||||
account activity.
|
||||
|
||||
## Scope Admin UI
|
||||
|
||||
Required backend operations:
|
||||
|
||||
- `resolve_tenant_context` before all tenant-scoped screens.
|
||||
- `set_tenant_account_status` for in-scope account state.
|
||||
- `add_membership` for tenant/team membership changes.
|
||||
- `projection` with `ADMIN` or a future admin transport projection.
|
||||
- `tenant_diagnostics` for onboarding and support readiness checks.
|
||||
|
||||
## Fixtures
|
||||
|
||||
Use `user_engine.testing.scenarios` for human, tenant admin, platform
|
||||
operator, delegated agent, invalid, expired, local issuer, and missing-tenant
|
||||
fixtures. UIs should keep fixtures at the transport boundary and avoid
|
||||
embedding identity-provider logic.
|
||||
Reference in New Issue
Block a user