Users
Users are the humans who access a client's data — family members, advisors, accountants, external partners. Every user is attached to one or more clients via role assignments, and the platform tracks invitations through an explicit state machine so that access can be granted, renewed, and revoked with an audit trail.
Data model
User
- Name
id- Type
- string
- Description
Stable identifier (UUID).
- Name
email- Type
- string
- Description
Primary email. Used for login and invitation delivery.
- Name
name- Type
- string
- Description
Display name.
- Name
status- Type
- enum
- Description
active,invited,disabled.
- Name
created_at- Type
- timestamp
- Description
When the user first joined any client on the workspace.
Invite
Invites are a short-lived handle on a pending user. A user without an
active session counts as invited; once they complete login, the invite
is consumed and their status flips to active.
- Name
id- Type
- string
- Description
Invite identifier.
- Name
user_id- Type
- string
- Description
The user being invited.
- Name
client_id- Type
- string
- Description
The client the user is being invited to.
- Name
role- Type
- string
- Description
Role name being granted on acceptance (e.g.
viewer,advisor).
- Name
expires_at- Type
- timestamp
- Description
When the invite link stops working. Default: 7 days.
- Name
cancelled_at- Type
- timestamp | null
- Description
Set when an admin revokes the invite before acceptance.
List users
Returns every user with any role on the client, including those whose invites are still pending acceptance.
Request
curl https://api.aleta.io/v2/clients/{client_id}/users \
-H "Authorization: Bearer {token}"
Invite a user
Creates a pending invite and triggers the delivery email. The same email supplied for two clients results in two separate invites on the same underlying User — one login, many memberships.
Request
curl -X POST https://api.aleta.io/v2/clients/{client_id}/users \
-H "Authorization: Bearer {token}" \
-H "Content-Type: application/json" \
-d '{
"email": "anna@example.com",
"name": "Anna Smith",
"role": "advisor"
}'
Cancel an invite
Marks the invite as cancelled and invalidates the email link. Idempotent — re-inviting the user creates a fresh record rather than reversing the cancellation.
Request
curl -X POST \
https://api.aleta.io/v2/users/{user_id}/invites/{invite_id}/cancellation \
-H "Authorization: Bearer {token}"
Related
- Clients — the scope a user gets a role on.
- Authentication — how the user's session is issued once they accept an invite.