Protodantic
Protobufs meet Pydantic. Using Pydantic in Python to model Protobuf's adds the following features:
{
"title": "Uplink",
"description": "A class representing a DEV5559 Uplink message. See `DEV5559.proto` for more schema source of truth.",
"type": "object",
"properties": {
"battery_soc": {
"title": "Battery State of Charge",
"description": "Battery State of Charge: 0-100",
"minimum": 0,
"maximum": 100,
"type": "number"
},
"battery_volts": {
"title": "Battery Voltage",
"description": "Battery Voltage: Milivolts",
"type": "number"
},
"humidity": {
"title": "Humidity",
"description": "Humidity: 0-100%",
"type": "number"
},
"moisture": {
"title": "Moisture",
"description": "Moisture: 0-100%",
"type": "number"
},
"temperature": {
"title": "Temperature",
"description": "Temperature: Degrees Celsius",
"type": "number"
},
"lat": {
"title": "Latitude",
"description": "Latitude: Decimal degrees, -90 to 90",
"type": "number"
},
"lng": {
"title": "Longitude",
"description": "Longitude: Decimal degrees, -180 to 180",
"type": "number"
}
},
"required": [
"battery_soc",
"battery_volts",
"humidity",
"moisture",
"temperature"
],
"additionalProperties": false
}