using Connected.Data;
namespace Connected.Security.Identity;
///
/// Specifies the user's status.
///
public enum UserStatus
{
///
/// User is not active and cannot log into the environment.
///
Inactive = 0,
///
/// User is a valid user and can log into the environment and
/// use its identity.
///
Active = 1,
///
/// User is locked out and cannot log into the environment.
///
Locked = 2
}
///
/// Represents user entity. User is basic artifact of the identity
/// infrastructure.
///
///
/// User tipically maps to a person or a physical end user of the
/// environment.
///
public interface IUser : IPrimaryKey
{
///
/// The user's first name.
///
string? FirstName { get; init; }
///
/// The user's last name
///
string? LastName { get; init; }
///
/// The login name which can be used when authenticating the user.
///
string? LoginName { get; init; }
///
/// The email associated with the user. The email should be unique
/// across the environment.
///
string? Email { get; init; }
///
/// Timezone used when representing Date and Time values. UTC timezone
/// is used by default, if this property is not set.
///
string? TimeZone { get; init; }
///
/// Language used by the user as defined in the
/// service. If not set, default, environment wide language is used.
///
int Language { get; init; }
///
/// The status of the user indicating wether user can log into the environment or not.
///
UserStatus Status { get; init; }
}