Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Simple Entity for Sensor Data
public class SensorTick
[JsonProperty(PropertyName = "id")]
public string Id { get; set; }
[JsonProperty(PropertyName = "temperature")]
public int Temperature { get; set; }
[JsonProperty(PropertyName = "humidity")]
public int Humidity { get; set; }
public DateTime TimeStamp { get; set; }
[JsonProperty(PropertyName = "sensorName")]
public String SensorName { get; set; }
public override string ToString()
return JsonConvert.SerializeObject(this);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.