Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

URL

http://<<ip address>>/rest/cabinet

Method

PUT

Description

Stores information on the cabinet.

sides can be frontonly or frontandback:

  • frontonly is used when only the front controller is physically available. This suppresses any missing tags on the back, a missing connection of the back controller and will generate a HTTP404 when trying to write to a back tag, or to controller 2 when in tag mode.

  • frontandback should be used if two controllers are connected.

name is the name of the cabinet, this will be shown on the screen, scaled to fit, when the PTLControl is idle.

When name is an HTML snippet surrounded by <div>the HTML will be rendered where the name is, centered on screen. The client is responsible for styling, scaling and layout.

Request

Code Block
languagejson
{ 
  "planks": «numberofplanks», 
  "sections": «numberofsections»,
  "name": «nameofcabinet»,
  "sides": "frontonly|frontandback"
}

Response

HTTP204 when successful

Possible Errors

HTTP400 when request was invalid

Code Block
languagejson
{
  "message": «human readable error»
}

Remarks

modewas removed in v2.0

HTML support for name was added in v2.1

URL

http://<<ip address>>/rest/cabinet/lighttest

Method

PUT

Description

Sets the cabinet is lighttest mode: turning light on or off. The light test shows the tag’s address.

Request

Code Block
languagejson
{ 
  "mode": "on" | "off"
}

Response

HTTP204 when successful

Possible Errors

HTTP400 when request was invalid

Code Block
languagejson
{
  "message": «human readable error»
}