mirror of
https://github.com/PepperDash/Essentials.git
synced 2026-01-11 19:44:52 +00:00
fix: use standard C# property naming structure, jsonproperties to conform to api
This commit is contained in:
@@ -6,10 +6,10 @@ namespace PepperDash.Essentials.Core.UDMApi
|
||||
internal class CustomProperties
|
||||
{
|
||||
[JsonProperty("label")]
|
||||
public string label { get; set; }
|
||||
public string Label { get; set; }
|
||||
|
||||
[JsonProperty("value")]
|
||||
public string value { get; set; }
|
||||
public string Value { get; set; }
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -5,25 +5,25 @@ namespace PepperDash.Essentials.Core.UDMApi
|
||||
internal class DeviceStatus
|
||||
{
|
||||
[JsonProperty("label")]
|
||||
public string label { get; set; }
|
||||
public string Label { get; set; }
|
||||
|
||||
[JsonProperty("status")]
|
||||
public string status { get; set; }
|
||||
public string Status { get; set; }
|
||||
|
||||
[JsonProperty("description")]
|
||||
public string description { get; set; }
|
||||
public string Description { get; set; }
|
||||
|
||||
[JsonProperty("videoSource")]
|
||||
public string videoSource { get; set; }
|
||||
public string VideoSource { get; set; }
|
||||
|
||||
[JsonProperty("audioSource")]
|
||||
public string audioSource { get; set; }
|
||||
public string AudioSource { get; set; }
|
||||
|
||||
[JsonProperty("usage")]
|
||||
public int usage { get; set; }
|
||||
public int Usage { get; set; }
|
||||
|
||||
[JsonProperty("error")]
|
||||
public string error { get; set; }
|
||||
public string Error { get; set; }
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -12,24 +12,24 @@ namespace PepperDash.Essentials.Core.UDMApi
|
||||
/// API version string
|
||||
/// </summary>
|
||||
[JsonProperty("apiVersion")]
|
||||
public string apiVersion { get; set; }
|
||||
public string ApiVersion { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Standard room properties
|
||||
/// </summary>
|
||||
[JsonProperty("standard")]
|
||||
public StandardProperties standard { get; set; }
|
||||
public StandardProperties Standard { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Status information including devices
|
||||
/// </summary>
|
||||
[JsonProperty("status")]
|
||||
public StatusProperties status { get; set; }
|
||||
public StatusProperties Status { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Custom properties dictionary
|
||||
/// </summary>
|
||||
[JsonProperty("custom")]
|
||||
public Dictionary<string, CustomProperties> custom { get; set; }
|
||||
public Dictionary<string, CustomProperties> Custom { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5,22 +5,22 @@ namespace PepperDash.Essentials.Core.UDMApi
|
||||
internal class StandardProperties
|
||||
{
|
||||
[JsonProperty("version")]
|
||||
public string version { get; set; }
|
||||
public string Version { get; set; }
|
||||
|
||||
[JsonProperty("state")]
|
||||
public string state { get; set; }
|
||||
public string State { get; set; }
|
||||
|
||||
[JsonProperty("error")]
|
||||
public string error { get; set; }
|
||||
public string Error { get; set; }
|
||||
|
||||
[JsonProperty("occupancy")]
|
||||
public bool occupancy { get; set; }
|
||||
public bool Occupancy { get; set; }
|
||||
|
||||
[JsonProperty("helpRequest")]
|
||||
public string helpRequest { get; set; }
|
||||
public string HelpRequest { get; set; }
|
||||
|
||||
[JsonProperty("activity")]
|
||||
public string activity { get; set; }
|
||||
public string Activity { get; set; }
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -9,6 +9,6 @@ namespace PepperDash.Essentials.Core.UDMApi
|
||||
/// Dictionary of device statuses keyed by device identifier
|
||||
/// </summary>
|
||||
[JsonProperty("devices")]
|
||||
public Dictionary<string, DeviceStatus> devices { get; set; }
|
||||
public Dictionary<string, DeviceStatus> Devices { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user