This is the Phenomenons resource.
Get the phenomenon with the name name
.
{
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "http://schema.envirocar.org/phenomenon.json#",
"type": "object",
"additionalProperties": false,
"required": [
"name",
"unit"
],
"properties": {
"name": {
"type": "string"
},
"unit": {
"type": "string"
},
"created": {
"type": "string",
"format": "date-time"
},
"modified": {
"type": "string",
"format": "date-time"
}
}
}
{
"created": "2013-07-09T07:59:47Z",
"modified": "2013-07-09T07:59:47Z",
"name": "Consumption",
"unit": "l/h"
}
Get a list of all phenomenons.
{
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "http://schema.envirocar.org/phenomenons.json#",
"type": "object",
"additionalProperties": false,
"required": [
"phenomenons"
],
"properties": {
"phenomenons": {
"type": "array",
"minItems": 0,
"items": {
"$ref": "http://schema.envirocar.org/phenomenon.json#"
}
}
}
}
{
"phenomenons": [
{
"name": "Calculated MAF",
"unit": "g/s"
},
{
"name": "Consumption",
"unit": "l/h"
},
{
"name": "Intake Pressure",
"unit": "kPa"
},
{
"name": "CO2",
"unit": "kg/h"
},
{
"name": "Intake Temperature",
"unit": "c"
},
{
"name": "MAF",
"unit": "l/s"
},
{
"name": "Rpm",
"unit": "u/min"
},
{
"name": "Speed",
"unit": "km/h"
}
]
}
Create a new phenomenon
{
"$schema": "http://json-schema.org/draft-04/schema#",
"id": "http://schema.envirocar.org/phenomenon.create.json#",
"type": "object",
"additionalProperties": false,
"required": [
"name",
"unit"
],
"properties": {
"name": {
"type": "string"
},
"unit": {
"type": "string"
}
}
}
{
"name": "TestPhenomenon",
"unit": "unit"
}