User

Represents a user account in the system. This is the central entity that uniquely identifies every person who has access to the application. It stores basic identity information like username and email, along with language and timezone preferences. Sensitive information like passwords are stored separately in UserAuthentication for security reasons. Each user can have multiple active sessions, multiple two-factor authentication methods, and can create API keys for programmatic access. The user entity tracks the lifecycle of an account from registration through activation, suspension, and eventual deletion. It's the main reference point for all user-related operations in the system.

20 properties
Schema

Properties

PropertyTypeModeDescriptionRequired
userIduuid
stored

Unique universal identifier for the user

Required
usernamestring
stored

Unique username for login, cannot be changed once set

Example: "john.doe"

Required
emailstring
stored

Primary email address used for account recovery and notifications

Example: "john.doe@example.com"

Required
emailVerifiedboolean
stored

Whether the email address has been verified through confirmation link

Optional
emailVerifiedAtDateTime
stored

Timestamp when the email was verified

Optional
personPerson
stored

Reference to personal information (name, date of birth, address, etc.)

Optional
statusstring
enum

Current status of the user account

Values: active, inactive, suspended, locked, pending

Example: "active"

Optional
statusReasonstring
stored

Human-readable explanation for the current status

Optional
statusChangedAtDateTime
stored

When the status was last changed

Optional
localestring
stored

User's preferred language and region for UI display

Example: "fr-FR"

Optional
timezonestring
stored

User's timezone for displaying dates and scheduling

Example: "Europe/Paris"

Optional
registeredAtDateTime
stored

When the user first signed up

Required
registrationSourcestring
enum

How the user account was created

Values: web, mobile, api, admin, import, social

Example: "web"

Optional
registrationIpstring
stored

IP address used during registration for security tracking

Optional
activatedAtDateTime
stored

When the account was activated and became usable

Optional
deactivatedAtDateTime
stored

When the account was deactivated

Optional
deletedAtDateTime
stored

Soft delete timestamp - account is hidden but not removed from database

Optional
versioninteger
stored

Version number to prevent concurrent update conflicts

Optional
createdAtDateTime
stored

When this record was created in the database

Required
updatedAtDateTime
stored

When this record was last modified

Optional

Examples

Example 1

{
  "@type": "User",
  "userId": "550e8400-e29b-41d4-a716-446655440000",
  "username": "sarah.johnson",
  "email": "sarah.johnson@techcorp.com",
  "emailVerified": true,
  "emailVerifiedAt": "2024-01-15T10:30:00Z",
  "status": "active",
  "statusReason": null,
  "locale": "en-US",
  "timezone": "America/Los_Angeles",
  "registeredAt": "2024-01-15T09:00:00Z",
  "registrationSource": "web",
  "registrationIp": "192.168.1.100",
  "activatedAt": "2024-01-15T10:30:00Z"
}

Example 2

{
  "@type": "User",
  "userId": "6ba7b810-9dad-11d1-80b4-00c04fd430c8",
  "username": "admin.system",
  "email": "admin@company.com",
  "emailVerified": true,
  "emailVerifiedAt": "2023-06-01T08:00:00Z",
  "status": "locked",
  "statusReason": "Too many failed login attempts from unknown location",
  "statusChangedAt": "2024-03-15T14:22:00Z",
  "locale": "en-GB",
  "timezone": "Europe/London",
  "registeredAt": "2023-06-01T08:00:00Z",
  "registrationSource": "admin",
  "registrationIp": "10.0.0.50",
  "activatedAt": "2023-06-01T08:00:00Z"
}