64 lines
3.1 KiB
C#
64 lines
3.1 KiB
C#
using Furion.ConfigurableOptions;
|
|
|
|
namespace Evergreen.Health.Application.Health.Integrations.HomeAssistant;
|
|
|
|
public sealed class HomeAssistantOptions : IConfigurableOptions
|
|
{
|
|
public bool Enabled { get; set; } = true;
|
|
public string BaseUrl { get; set; } = string.Empty;
|
|
public string AccessToken { get; set; } = string.Empty;
|
|
public int TimeoutSeconds { get; set; } = 15;
|
|
public HomeAssistantEntityOptions Entities { get; set; } = new();
|
|
public HomeAssistantSleepSceneOptions SleepScene { get; set; } = new();
|
|
}
|
|
|
|
public sealed class HomeAssistantEntityOptions
|
|
{
|
|
public string Climate { get; set; } = string.Empty;
|
|
public string Curtain { get; set; } = string.Empty;
|
|
public string Outlet { get; set; } = string.Empty;
|
|
public string Dehumidifier { get; set; } = string.Empty;
|
|
public string DehumidifierFanLevel { get; set; } = string.Empty;
|
|
public string DehumidifierUv { get; set; } = string.Empty;
|
|
public string FragranceSwitch { get; set; } = string.Empty;
|
|
public string FragranceLight { get; set; } = string.Empty;
|
|
public string FragranceDuration { get; set; } = string.Empty;
|
|
public string FragranceInterval { get; set; } = string.Empty;
|
|
public string FragranceQuickRelease { get; set; } = string.Empty;
|
|
public string FragranceAutoRelease { get; set; } = string.Empty;
|
|
public string FragranceAutoLight { get; set; } = string.Empty;
|
|
public string FragranceLightAutoOff { get; set; } = string.Empty;
|
|
public string AmbientLight { get; set; } = string.Empty;
|
|
public string Speaker { get; set; } = string.Empty;
|
|
public string SpeakerSleepMode { get; set; } = string.Empty;
|
|
public string MattressLeftHeatingLevel { get; set; } = string.Empty;
|
|
public string MattressRightHeatingLevel { get; set; } = string.Empty;
|
|
public string MattressLeftMode { get; set; } = string.Empty;
|
|
public string MattressRightMode { get; set; } = string.Empty;
|
|
public Dictionary<string, string> MattressFirmness { get; set; } = new();
|
|
public string MattressLeftMassagePart { get; set; } = string.Empty;
|
|
public string MattressRightMassagePart { get; set; } = string.Empty;
|
|
public string MattressMassageLevel { get; set; } = string.Empty;
|
|
public string Temperature { get; set; } = string.Empty;
|
|
public string Humidity { get; set; } = string.Empty;
|
|
public string Pm25 { get; set; } = string.Empty;
|
|
public string Co2 { get; set; } = string.Empty;
|
|
public string Formaldehyde { get; set; } = string.Empty;
|
|
public string Tvoc { get; set; } = string.Empty;
|
|
}
|
|
|
|
public sealed class HomeAssistantSleepSceneOptions
|
|
{
|
|
public int TargetHumidity { get; set; } = 55;
|
|
public string DehumidifierMode { get; set; } = "睡眠";
|
|
public string FanLevel { get; set; } = "1挡";
|
|
public int LightBrightnessPercent { get; set; } = 20;
|
|
public int LightColorTemperatureKelvin { get; set; } = 2700;
|
|
public bool EnableFragrance { get; set; } = true;
|
|
public bool EnableSpeakerSleepMode { get; set; }
|
|
public bool EnableMattress { get; set; }
|
|
public int MattressHeatingLevel { get; set; } = 1;
|
|
public string MattressMode { get; set; } = "智能适配";
|
|
public bool EnableUv { get; set; }
|
|
}
|