-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathapi.json
533 lines (533 loc) · 13.6 KB
/
api.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
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
{
"api" : [
{
"method" : "GET",
"path" : "/events/show",
"params" : [
],
"description" : "show all scheduled events"
},
{
"method" : "GET",
"path" : "/events/add",
"params" : [
{
"description" : "hour of the day at which to trigger the event",
"name" : "hour"
},
{
"description" : "minute of the hour at which to trigger the event",
"name" : "min"
},
{
"description" : "user defined data",
"name" : "p"
},
{
"description" : "Event name",
"name" : "name"
}
],
"description" : "add a scheduled event. This event will trigger the LUA script at the defined time"
},
{
"method" : "GET",
"path" : "/events/remove",
"params" : [
{
"description" : "event ID",
"name" : "id"
}
],
"description" : "remove a scheduled event"
},
{
"method" : "GET",
"path" : "/events/gettime",
"params" : [
],
"description" : "get current time"
},
{
"method" : "GET",
"path" : "/help",
"params" : [
],
"description" : "display API documentation"
},
{
"method" : "GET",
"path" : "/dwn/sendraw",
"params" : [
{
"description" : "raw data to be sent",
"name" : "data"
},
{
"description" : "IP address of the node",
"name" : "destination"
}
],
"description" : "send raw data to wifi node"
},
{
"method" : "GET",
"path" : "/dwn/list",
"params" : [
],
"description" : "list connected wifi nodes"
},
{
"method" : "GET",
"path" : "/weather/setip",
"params" : [
{
"description" : "IP address of weather controller",
"name" : "ip"
}
],
"description" : "set IP of weather controller"
},
{
"method" : "GET",
"path" : "/weather/getstats",
"params" : [
{
"description" : "device index",
"name" : "id"
}
],
"description" : "retrieve stats"
},
{
"method" : "GET",
"path" : "/weather/getthermostat",
"params" : [
{
"description" : "device index",
"name" : "id"
}
],
"description" : "retrieve thermostat status"
},
{
"method" : "GET",
"path" : "/weather/setpoint",
"params" : [
{
"description" : "value between 10 and 30 with 0.5 increment",
"name" : "temp"
},
{
"description" : "device index",
"name" : "id"
}
],
"description" : "Configure setpoint"
},
{
"method" : "GET",
"path" : "/weather/resetfilter",
"params" : [
{
"description" : "device index",
"name" : "id"
}
],
"description" : "Reset filter days count"
},
{
"method" : "GET",
"path" : "/weather/setmode",
"params" : [
{
"description" : "heat/cool/off",
"name" : "mode"
},
{
"description" : "device index",
"name" : "id"
}
],
"description" : "Set thermostat running mode"
},
{
"method" : "GET",
"path" : "/weather/toggleschedule",
"params" : [
{
"description" : "device index",
"name" : "id"
}
],
"description" : "Enable/disable schedule"
},
{
"method" : "GET",
"path" : "/audio/play",
"params" : [
{
"description" : "Coma separated list of files to play. digits can be used. They will be decoded and the proper sound files will be constructed. I.e: sound1,29,4,sound2 would play sound files: sound1.wav,20.wav,9.wav,4.wav,sound2.wav Note that number reconstruction only work for french grammar and only supports numbers -59..59 inclusively. For playing silence, you can use the number of seconds prefixed by a dollar sign. I.e: sound1$4,sound2. This would make a 4 second pause between sound1 and sound2",
"name" : "sound"
}
],
"description" : "plays files defined by PLAY_STRING on onboard sound device"
},
{
"method" : "GET",
"path" : "/insteon/clearmodules",
"params" : [
],
"description" : "reset list of Insteon module definition"
},
{
"method" : "GET",
"path" : "/insteon/listmodules",
"params" : [
],
"description" : "lists all Insteon modules"
},
{
"method" : "GET",
"path" : "/insteon/addmodule",
"params" : [
{
"description" : "The name of the module",
"name" : "name"
},
{
"description" : "the Insteon device ID formated as 0xNNNNNN",
"name" : "id"
}
],
"description" : "add a Insteon module definition"
},
{
"method" : "GET",
"path" : "/insteon/addezflora",
"params" : [
{
"description" : "The name of the module",
"name" : "name"
},
{
"description" : "the Insteon device ID formated as 0xNNNNNN",
"name" : "id"
}
],
"description" : "add a Insteon ezflora module definition"
},
{
"method" : "GET",
"path" : "/insteon/addiolinc",
"params" : [
{
"description" : "The name of the module",
"name" : "name"
},
{
"description" : "the Insteon device ID formated as 0xNNNNNN",
"name" : "id"
}
],
"description" : "add a Insteon iolinc module definition"
},
{
"method" : "GET",
"path" : "/insteon/setcontroller",
"params" : [
{
"description" : "the Insteon device ID formated as 0xNNNNNN",
"name" : "id"
}
],
"description" : "set Insteon controller ID (PLM)"
},
{
"method" : "GET",
"path" : "/insteon/switch",
"params" : [
{
"description" : "the Insteon device ID formated as 0xNNNNNN",
"name" : "id"
},
{
"description" : "0 to 255. This is the ramp rate",
"name" : "rate"
},
{
"description" : "on/off/toggle",
"name" : "action"
},
{
"description" : "for EZFlora, subdev is 1-7 for valves and 8-11 for programs 1-4. For switches, this is irrelevant",
"name" : "subdev"
},
{
"description" : "0 to 255. Irrelevant if action is off or toggle",
"name" : "level"
}
],
"description" : "Turn on or off a device"
},
{
"method" : "GET",
"path" : "/insteon/ezflora/setprogram",
"params" : [
{
"description" : "Zone 8 timer. 0 to 255 minutes",
"name" : "z8"
},
{
"description" : "Zone 5 timer. 0 to 255 minutes",
"name" : "z5"
},
{
"description" : "Zone 4 timer. 0 to 255 minutes",
"name" : "z4"
},
{
"description" : "Zone 3 timer. 0 to 255 minutes",
"name" : "z3"
},
{
"description" : "the Insteon device ID formated as 0xNNNNNN",
"name" : "id"
},
{
"description" : "Program number. 1 to 4",
"name" : "p"
},
{
"description" : "Zone 1 timer. 0 to 255 minutes",
"name" : "z1"
},
{
"description" : "Zone 7 timer. 0 to 255 minutes",
"name" : "z7"
},
{
"description" : "Zone 6 timer. 0 to 255 minutes",
"name" : "z6"
},
{
"description" : "Zone 2 timer. 0 to 255 minutes",
"name" : "z2"
}
],
"description" : "Sets a program on the EZFlora"
},
{
"method" : "GET",
"path" : "/insteon/ezflora/status",
"params" : [
{
"description" : "the Insteon device ID formated as 0xNNNNNN",
"name" : "id"
}
],
"description" : "Forces an update of EZFlora status"
},
{
"method" : "GET",
"path" : "/insteon/raw",
"params" : [
{
"description" : "data byte 12 for extended data",
"name" : "d12"
},
{
"description" : "data byte 10 for extended data",
"name" : "d10"
},
{
"description" : "data byte 11 for extended data",
"name" : "d11"
},
{
"description" : "data byte 9 for extended data",
"name" : "d9"
},
{
"description" : "data byte 1 for extended data",
"name" : "d1"
},
{
"description" : "command byte 2",
"name" : "cmd2"
},
{
"description" : "data byte 14 for extended data",
"name" : "d14"
},
{
"description" : "command byte 1",
"name" : "cmd1"
},
{
"description" : "the Insteon device ID formated as 0xNNNNNN",
"name" : "id"
},
{
"description" : "data byte 8 for extended data",
"name" : "d8"
},
{
"description" : "data byte 3 for extended data",
"name" : "d3"
},
{
"description" : "data byte 2 for extended data",
"name" : "d2"
},
{
"description" : "data byte 13 for extended data",
"name" : "d13"
},
{
"description" : "data byte 4 for extended data",
"name" : "d4"
},
{
"description" : "data byte 6 for extended data",
"name" : "d6"
},
{
"description" : "data byte 5 for extended data",
"name" : "d5"
},
{
"description" : "data byte 7 for extended data",
"name" : "d7"
}
],
"description" : "Send raw insteon command"
},
{
"method" : "GET",
"path" : "/insteon/refreshalllinksdatabase",
"params" : [
],
"description" : "retrieve all-link database"
},
{
"method" : "GET",
"path" : "/phone/call",
"params" : [
{
"description" : "Coma separated list of files to play. digits can be used. They will be decoded and the proper sound files will be constructed. I.e: sound1,29,4,sound2 would play sound files: sound1.wav,20.wav,9.wav,4.wav,sound2.wav Note that number reconstruction only work for french grammar and only supports numbers -59..59 inclusively. For playing silence, you can use the number of seconds prefixed by a dollar sign. I.e: sound1.wav,$4,sound2.wav. This would make a 4 second pause between sound1 and sound2",
"name" : "play"
},
{
"description" : "extention to call",
"name" : "ext"
}
],
"description" : "Will call the given extension and optionally play sound when the remote peer answers the call. Placing a call only works if the user agent was previously registered. Called extension must be know by the proxy because direct URI are not supported. To make an intercom call (where the UAS will autoanswer) this needs to be configured on the proxy. "
},
{
"method" : "GET",
"path" : "/phone/register",
"params" : [
{
"description" : "PBX IP address",
"name" : "proxy"
},
{
"description" : "pin associated to user",
"name" : "pin"
},
{
"description" : "SIP user to register",
"name" : "user"
}
],
"description" : "Will register the phone service user agent to the given PBX. This is usually done during initialization "
},
{
"method" : "GET",
"path" : "/phone/blf",
"params" : [
{
"description" : "extension",
"name" : "ext"
}
],
"description" : "Will subscribe for presence events for the given extension. The extension must be a known extension in the subscribe context of our UA (if using Asterisk). "
},
{
"method" : "GET",
"path" : "/phone/mwi",
"params" : [
{
"description" : "extension",
"name" : "ext"
}
],
"description" : "Will subscribe for mwi events for the given extension."
},
{
"method" : "GET",
"path" : "/phone/showcalls",
"params" : [
],
"description" : "Get the list of active calls in the system "
},
{
"method" : "GET",
"path" : "/phone/showblf",
"params" : [
],
"description" : "Get the list of active subscriptions to presence events in the system "
},
{
"method" : "GET",
"path" : "/phone/release",
"params" : [
{
"description" : "Call ID",
"name" : "id"
}
],
"description" : "release a call using call ID (usually provided in call events) "
},
{
"method" : "GET",
"path" : "/phone/play",
"params" : [
{
"description" : "[true/false] if you want the call to be released after sound finished playing",
"name" : "releaseaftersounds"
},
{
"description" : "call ID",
"name" : "id"
},
{
"description" : "Coma separated list of files to play. digits can be used. They will be decoded and the proper sound files will be constructed. I.e: sound1,29,4,sound2 would play sound files: sound1.wav,20.wav,9.wav,4.wav,sound2.wav Note that number reconstruction only work for french grammar and only supports numbers -59..59 inclusively. For playing silence, you can use the number of seconds prefixed by a dollar sign. I.e: sound1.wav,$4,sound2.wav. This would make a 4 second pause between sound1 and sound2",
"name" : "sound"
}
],
"description" : "Play sounds on an active call using given callID."
},
{
"method" : "GET",
"path" : "/phone/click2dial",
"params" : [
{
"description" : "Destination extension to which the source will be patched.",
"name" : "dst"
},
{
"description" : "Source extension to call",
"name" : "src"
},
{
"description" : "Sound to play when source answers, before transfering to destination. Coma separated list of files to play. digits can be used. They will be decoded and the proper sound files will be constructed. I.e: sound1,29,4,sound2 would play sound files: sound1.wav,20.wav,9.wav,4.wav,sound2.wav Note that number reconstruction only work for french grammar and only supports numbers -59..59 inclusively. For playing silence, you can use the number of seconds prefixed by a dollar sign. I.e: sound1.wav,$4,sound2.wav. This would make a 4 second pause between sound1 and sound2",
"name" : "sound"
}
],
"description" : "Click-2-Dial"
}
]
}