ISY Developers:API:REST Interface

From Universal Devices, Inc. Wiki
Revision as of 05:04, 1 March 2013 by JWohlers (Talk | contribs) (Programs)

Jump to: navigation, search

REST Interface

Here's the syntax for the ISY's REST interface:

METHOD = GET

Configuration

/rest/config -- returns the configuration of the system with permissible commands


Nodes

/rest/nodes -- returns nodes, scenes, types, and their status

/rest/nodes/<node> -- returns all the attributes & property values for a specific node

/rest/nodes/<node>?members=true|false -- this only works on a scene. using members=true includes all the scene members in the result


Properties

/rest/nodes/<node>/<property> -- returns the specific property value for a given node id

/rest/nodes/<node>/set/<property>/<value> -- set a value such as OL/250


Commands

/rest/nodes/<node>/cmd/<command_name>/<param1>/<param2>/.../<param5> eg:

/rest/nodes/<node>/cmd/DOF - turn off a device or a scene

/rest/nodes/<node>/cmd/DON/128 - turn on a device to 50% - valid parameters = 0 - 255

/rest/nodes/<node>/cmd/DFON - turn on a device fast

/rest/nodes/<node>/cmd/DFOF - turn off a device fast

/rest/nodes/<node>/cmd/BRT - increase brightness of a device by ~3%

/rest/nodes/<node>/cmd/DIM - decrease brightness of a device by ~3%

/rest/nodes/<node>/cmd/BMAN - begin manual dimming

/rest/nodes/<node>/cmd/SMAN - stop manual dimming


X10

/rest/X10/<Housecode>/<X10> -- UnitCode and X10 command are both optional


Status

/rest/status -- returns the status for all the nodes

/rest/status/<node> -- returns the status for the given node


Query

/rest/query -- queries all the nodes

/rest/query/<node> -- queries the given node


Programs

/rest/programs/<pgm>/<pgm> e.g. /rest/programs/0032/runThen -- Runs a command for a single program

/rest/programs/<pgm> -- returns single program, or folder with folders/programs within it

/rest/programs/<pgm>?folderContents=false -- returns single program or folder

/rest/programs/<pgm>?subfolders=true -- returns single program, or folder with folders/programs within it recursively

/rest/programs -- returns all the programs in the root folder e.g. same as /rest/programs/<root>

/rest/programs?folderContents=false -- returns root folder only (same as /rest/programs/<root>?folderContents=false)

/rest/programs?subfolders=true -- returns all programs & folders (same as /rest/programs/<root>?subfolders=true)


Defaults: folderContents=true, subfolders=false


pgm-cmd - run|runThen|runElse|stop|enable|disable|enableRunAtStartup|disableRunAtStartup

'runIf' is supported as well, but 'run' should be used instead

Modules

/rest/electricity -- returns electricity module info

/rest/climate -- returns climate module info

/rest/security -- returns security module info


The following have been disabled for security reasons

/rest/security//arm/stay

/rest/security/<code>/arm/away

/rest/security/<code>/disarm


Misc

/rest/locations -- returns the floorplan


Related Pages




ISY-99i Series INSTEON: