Change Sensors field type in config and response to map
This commit is contained in:
parent
c3f51f2e36
commit
daac0b3b9e
|
@ -19,11 +19,8 @@ type EnvironmentSensorConfig struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
type DynamicStateConfig struct {
|
type DynamicStateConfig struct {
|
||||||
Sensors struct {
|
Sensors map[string][]EnvironmentSensorConfig `json:"sensors"`
|
||||||
Temperature []EnvironmentSensorConfig `json:"temperature"`
|
State struct {
|
||||||
Humidity []EnvironmentSensorConfig `json:"humidity"`
|
|
||||||
} `json:"sensors"`
|
|
||||||
State struct {
|
|
||||||
Open struct {
|
Open struct {
|
||||||
AllowedCredentials []HTTPBACredentialID `json:"allowed_credentials"`
|
AllowedCredentials []HTTPBACredentialID `json:"allowed_credentials"`
|
||||||
} `json:"open"`
|
} `json:"open"`
|
||||||
|
|
|
@ -23,11 +23,8 @@ type SpaceAPIResponseV14 struct {
|
||||||
ML string `json:"ml"`
|
ML string `json:"ml"`
|
||||||
Matrix string `json:"matrix"`
|
Matrix string `json:"matrix"`
|
||||||
} `json:"contact"`
|
} `json:"contact"`
|
||||||
Sensors struct {
|
Sensors map[string][]EnvironmentSensor `json:"sensors"`
|
||||||
Temperature []EnvironmentSensor `json:"temperature"`
|
Feeds struct {
|
||||||
Humidity []EnvironmentSensor `json:"humidity"`
|
|
||||||
} `json:"sensors"`
|
|
||||||
Feeds struct {
|
|
||||||
Blog struct {
|
Blog struct {
|
||||||
Type string `json:"type"`
|
Type string `json:"type"`
|
||||||
URL string `json:"url"`
|
URL string `json:"url"`
|
||||||
|
|
Loading…
Reference in a new issue