Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Normalized schema additions #524

Merged
70 changes: 70 additions & 0 deletions lib/payload.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,28 @@
"description": "Speed (m/s)",
"minimum": 0
},
"depth": {
"type": "number",
"description": "Depth from the surface (cm)",
"minimum": 0
},
johanstokking marked this conversation as resolved.
Show resolved Hide resolved
pablojimpas marked this conversation as resolved.
Show resolved Hide resolved
"pH": {
"type": "number",
"description": "pH level",
"minimum": 0,
"maximum": 14
},
"concentration": {
"type": "number",
"description": "Concentration (ppm)",
"minimum": 0,
"maximum": 1000000
},
"illuminance": {
"type": "number",
"description": "Illuminance (lux)",
"minimum": 0
},
"percentage": {
"type": "number",
"description": "Percentage (%)",
Expand All @@ -34,6 +56,46 @@
"format": "date-time",
"description": "Date and time of the measurement (RFC3339)"
},
"soil": {
"type": "object",
"properties": {
"depth": {
"description": "Depth of the soil measurement (cm)",
"$ref": "#/definitions/depth"
},
"moisture": {
"description": "Soil moisture (%)",
"$ref": "#/definitions/percentage"
},
"temperature": {
"description": "Soil temperature (°C)",
"$ref": "#/definitions/temperature"
},
"ec": {
"description": "Soil electrical conductivity (dS/m)",
"type": "number",
"minimum": 0,
"maximum": 621
},
"pH": {
"description": "Soil pH level",
"$ref": "#/definitions/pH"
},
"n": {
"description": "Concentration of Nitrogen in the soil (ppm)",
"$ref": "#/definitions/concentration"
},
"p": {
"description": "Concentration of Phosphorus in the soil (ppm)",
"$ref": "#/definitions/concentration"
},
"k": {
"description": "Concentration of Potassium in the soil (ppm)",
"$ref": "#/definitions/concentration"
}
},
"additionalProperties": false
},
"air": {
"type": "object",
"properties": {
Expand All @@ -50,6 +112,14 @@
"description": "Atmospheric pressure (hPa)",
"minimum": 900,
"maximum": 1100
},
"co2": {
"description": "Concentration of CO2 in the air (ppm)",
"$ref": "#/definitions/concentration"
},
"lightIntensity": {
"description": "Light intensity (lux)",
"$ref": "#/definitions/illuminance"
}
},
"additionalProperties": false
Expand Down