namespace YaleAccess.Models
{
public class YaleUserCode
{
///
/// The ID of the user code. When making requets to ZWave.JS API, this is the value to use.
///
public int Id { get; set; }
///
/// The code / pin number for the user code. This may be null if the user code is not set or is not in use.
/// Even though its a string, it is a number and appropriate validation is required.
///
public string Code { get; set; } = string.Empty;
///
/// The current status of the user code.
///
public UserCodeStatus Status { get; set; }
///
/// Is true is this is the 'home' or normal user code for daily use.
///
public bool IsHome { get; set; }
}
public enum UserCodeStatus
{
///
/// This means the code is not being used, and can be assigned
///
AVAILABLE = 0,
///
/// This means that the code is in used, and cannot be assigned
///
ENABLED = 1,
///
/// Not sure what this means yet, perhaps it is related to schedules?
///
DISABLED = 2
}
}