docs: Fix typos
This commit is contained in:
parent
b98174c7da
commit
bd94b295ac
2 changed files with 4 additions and 5 deletions
|
@ -38,16 +38,15 @@ curl -X PUT -u user:password -d true http://[::1]:8080/state/open
|
|||
|
||||
The same is true for the endpoints for sensors configured under `"dynamic"`.
|
||||
Currently only the sensors with the `value/unit/location/name/description` schema are implemented.
|
||||
At the time of writing this includes `temperature`, `barometer`, `humidity`, `beverage_supply`, `power_consumption`,
|
||||
and `account_balance`.
|
||||
Out-of-spec sensors may also be used as long as they share the same schema.
|
||||
At the time of writing this includes `temperature`, `barometer`, `humidity`, `beverage_supply`, `power_consumption`, and `account_balance`.
|
||||
Out-of-spec sensors may be used as well, as long as they share the same schema.
|
||||
|
||||
```shell
|
||||
curl -X PUT -u user:password -d 23.42 http://[::1]:8080/sensors/{temperature,humidity,...}[/location[/name]]
|
||||
```
|
||||
|
||||
As can be seen in the example, the http urls are generated from sensor type and optionally `location` and `name`.
|
||||
Depending on sensor type `location` might be required for your sensors, see the schema for details.
|
||||
Depending on sensor type, `location` might be required for your sensors, see the schema for details.
|
||||
|
||||
## Building
|
||||
|
||||
|
|
2
main.go
2
main.go
|
@ -57,7 +57,7 @@ func main() {
|
|||
http.HandleFunc("/state/open",
|
||||
handlers.StateOpen(conf.Credentials, conf.Dynamic.State.Open.AllowedCredentials, &conf.Response.State),
|
||||
)
|
||||
// Register handlers for Environmental Sensors
|
||||
// Register handlers for environmental sensors
|
||||
for sensorType, envSensorConfigs := range conf.Dynamic.Sensors {
|
||||
for i, envSensorConfig := range envSensorConfigs {
|
||||
urlPath := util.GetSensorURLPath(
|
||||
|
|
Loading…
Reference in a new issue