homebridge-ws
Version:
Homebridge plugin for virtual weather station
134 lines (133 loc) • 3.45 kB
JSON
{
"pluginAlias": "WS",
"pluginType": "platform",
"singular": true,
"headerDisplay": "Homebridge plugin for virtual weather station",
"footerDisplay": "Get your OpenWeatherMap API key [here](https://openweathermap.org/price).<br>For a list of valid OpenWeatherMap city names and IDs, look [here](https://openweathermap.org/current).",
"schema": {
"type": "object",
"properties": {
"name": {
"title": "Name",
"description": "Plugin name as displayed in the Homebridge log.",
"type": "string",
"required": true,
"default": "Weather"
},
"apikey": {
"title": "API key",
"description": "OpenWeatherMap API key (see below).",
"type": "string",
"required": true,
"pattern": "^[0-9a-f]{32}$"
},
"cityIds": {
"title": "City ID",
"type": "array",
"required": true,
"items": {
"title": "City ID",
"description": "OpenWeatherMap city ID (see below).",
"type": "integer",
"minimum": 0
}
},
"dailyForecasts": {
"title": "Daily Forecasts",
"description": "Number of daily forecasts to expose. Default: 0.",
"type": "integer",
"minimum": 0,
"maximum": 7
},
"hourlyForecasts": {
"title": "Hourly Forecasts",
"description": "Number of hourly forecasts to expose. Default: 0.",
"type": "integer",
"minimum": 0,
"maximum": 47
},
"leakSensor": {
"title": "Expose Leak Sensor",
"description": "Expose rain (or snow) through an additional Leak Sensor. Default: false.",
"type": "boolean"
},
"locations": {
"title": "City Name",
"type": "array",
"required": true,
"items": {
"title": "City Name",
"description": "OpenWeatherMap city name (see below).",
"type": "string"
}
},
"timeout": {
"title": "Timeout",
"description": "Timeout in seconds. Default: 15.",
"type": "integer",
"minimum": 1,
"maximum": 60
}
}
},
"form": [
"name",
"apikey",
{
"type": "help",
"helpvalue": "City Names <strong class='text-danger'>*</strong>"
},
{
"nodescription": true,
"notitle": true,
"key": "locations",
"type": "array",
"items": [
{
"type": "div",
"displayFlex": true,
"flex-direction": "row",
"items": [
{
"key": "locations[]",
"required": true,
"flex": "1 1 50px"
}
]
}
]
},
{
"nodescription": true,
"notitle": true,
"key": "cityIds",
"type": "array",
"items": [
{
"type": "div",
"displayFlex": true,
"flex-direction": "row",
"items": [
{
"key": "cityIds[]",
"required": true,
"flex": "1 1 50px"
}
]
}
]
},
"dailyForecasts",
"hourlyForecasts",
"leakSensor",
{
"type": "fieldset",
"expandable": true,
"title": "Advanced Settings",
"description": "Don't change these, unless you understand what you're doing.",
"items": [
"timeout"
]
}
]
}