-
Notifications
You must be signed in to change notification settings - Fork 112
/
config.schema.json
174 lines (174 loc) · 4.97 KB
/
config.schema.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
{
"pluginAlias": "Nest",
"pluginType": "platform",
"singular": true,
"headerDisplay": "Nest plug-in for [Homebridge](https://github.com/nfarina/homebridge) using the native Nest API",
"footerDisplay": "If you are using a Nest account see the [Using a Nest Account](https://github.com/chrisjshull/homebridge-nest#using-a-nest-account) section on GitHub for help on setting this plugin up with your Nest account. If you are using a Google Account then see [Using a Google Account](https://github.com/chrisjshull/homebridge-nest#using-a-google-account) section on GitHub for help on setting this plugin up with your Google account.<p> See [Feature Options](https://github.com/chrisjshull/homebridge-nest#feature-options) section on GitHub to see additional features that can be enabled/disabled.",
"schema": {
"type": "object",
"properties": {
"name": {
"title": "Name",
"type": "string",
"default": "Nest",
"description": "The name that will appear in your homebridge log"
},
"access_token": {
"title": "Access Token",
"type": "string",
"description": "See Using a Nest Account section of project page for help.",
"placeholder": "Nest Access Token"
},
"refreshToken": {
"title": "Refresh Token",
"type": "string",
"description": "See Using a Google Account section of project page for help.",
"placeholder": "Google Refresh Token"
},
"googleAuth": {
"title": "Google Auth",
"type": "object",
"properties": {
"issueToken": {
"title": "Issue Token",
"type": "string",
"description": "See Using a Google Account section of project page for help."
},
"cookies": {
"title": "Cookies",
"type": "string"
},
"apiKey": {
"title": "API Key",
"type": "string"
}
}
},
"structureId": {
"title": "Your Structure's ID",
"type": "string",
"description": "Optional structureId to filter - Nest Structures are equivalent to HomeKit Homes (see logs on first run for each device's structureId)."
},
"fanDurationMinutes": {
"title": "Fan Duration",
"type": "integer",
"placeholder": "Optional, Default is 15",
"description": "Number of minutes to run the fan when manually turned on"
},
"options": {
"title": "Feature Options",
"type": "array",
"items": {
"type": "string",
"placeholder": "Thermostat.Disable"
}
}
},
"oneOf": [
{
"required": ["access_token"]
},
{
"required": ["refreshToken"]
},
{
"required": ["googleAuth"]
}
]
},
"layout": [
{
"type": "flex",
"flex-flow": "row wrap",
"items": [
{
"key": "name",
"type": "name"
}
]
},
{
"type": "fieldset",
"title": "Nest Account",
"description": "Expand when using a Nest Account",
"expandable": true,
"flex-flow": "row wrap",
"displayFlex": true,
"flex-direction": "row",
"items": [
{
"key": "access_token",
"type": "access_token"
}
]
},
{
"type": "fieldset",
"title": "Google Account - Refresh Token",
"description": "Expand when using the refresh token method for a Google Account",
"expandable": true,
"displayFlex": true,
"items": [
{
"type": "flex",
"flex-flow": "row wrap",
"items": [
"refreshToken"
]
}
]
},
{
"type": "fieldset",
"title": "Google Account - Cookies",
"description": "Expand when using the cookies method for a Google Account",
"expandable": true,
"displayFlex": true,
"items": [
{
"type": "flex",
"flex-flow": "row wrap",
"items": [
"googleAuth.issueToken"
]
},
{
"type": "flex",
"flex-flow": "row wrap",
"items": [
"googleAuth.cookies",
"googleAuth.apiKey"
]
}
]
},
{
"type": "fieldset",
"title": "Optional Fields",
"expandable": true,
"items": [
"structureId",
"fanDurationMinutes",
{
"key": "options",
"add": "Add Another Option",
"type": "fieldset",
"expandable": true,
"items": [
{
"type": "string",
"description": "Feature Options to Enable/Disable.",
"displayFlex": true,
"flex-direction": "row",
"items": [
{
"key": "options[]"
}
]
}
]
}
]
}
]
}