Access Keys:
Skip to content (Access Key - 0)

Controller 1.0 HTTP/REST/XML API

The following document describes the Controller 1.0 API.

Request Panel Layout Configuration XML

  • Request URL:
    /resources/iphone.xml
  • Request Method: GET
  • Parameters: no parameter

Example Request URL

http://localhost:8080/controller/resources/iphone.xml
  • Output: Status Code 200.

Example Response

<?xml version="1.0" encoding="UTF-8"?>
<openremote xsi:schemaLocation="http://www.openremote.org http://www.openremote.org/schemas/iphone.xsd">
  <activity id="1" name="User Customized">
    <screen id="1" name="NEC projector" row="6" col="4">
      <buttons>
        <button id="31" label="SHUT" x="3" y="0" width="1" height="1" icon="power.png" />
        <button id="32" label="Cursor_UP" x="1" y="1" width="1" height="1" icon="up.png" />
      </buttons>
    </screen>
  </activity>
</openremote>

Errors

Response code 404 not found

Send UI Button Event to Controller

  • Request URL:
    /rest/button/{button_id}/{command_type}
  • Request Method: POST(GET)
  • Parameters: button_id (Button id), commandType(one of click,press and release)

Example Request URL

    http://localhost:8080/controller/rest/button/1/press
    http://localhost:8080/controller/rest/button/1/release
    http://localhost:8080/controller/rest/button/1/click
  • Output: Status Code 200.

Example Response

HTTP 200 OK

Errors

  • Error Code: 418, Event Build Error. Happens when an event can't be built from a DOM Element.
  • Error Code: 419, No Such Button Error.
  • Error Code: 420, No Such Event Builder Error.
  • Error Code: 421, Invalid Command Type Error.
  • Error Code: 422, controller.xml Not Found Error.
  • Error Code: 423, No Such Event Error.
  • Error Code: 424, Invalid controller.xml Error.

Added by Juha Lindfors , last edit by Juha Lindfors on Aug 22, 2010 20:27

© 2008-2011 OpenRemote Inc. OpenRemote is a trademark of OpenRemote, Inc.
Adaptavist Theme Builder (3.3.3-conf210) Powered by Atlassian Confluence 2.10.3, the Enterprise Wiki.
Free theme builder license