REST API

The communication between server and client is managed with rest http. When you want invoke a specific method you can use : see also In Your Application Delegate. Demo code Array You can see complete list of all REST API here.

/sendCommand

Method description End point /sendCommand Description Sends a actuator command Request method POST Bearer token Required Request RequestParam None RequestBody Array Field name Description Type command_type Command Type Integer actuatorID Actuator ID Long nonce Command Identifier (an user originated identifier for this command) Long smartgate_serial gateBee Serial String data Command Data JSONObject >>relay_value Relay Value Request [...]

Import framework in Xcode.

Import our framework is very simple, drag and drop file.framework in your project and on General tab in configuration you must drag and drop under Embedded Binaries

/getMyDataChannels

Method description End point /getMyDataChannels Description Returns the list of the user's Data channels Request method POST Bearer token Required Request RequestParam None RequestBody None Response A JSONArray representation of the user's Data channels Example Array Fields Field name Description Type sensor_id Sensor identifier Long sensor_prototype_id Sensor prototype identifier Long sensor_prototype_name Sensor prototype name String [...]

/getMyRawEnergyData

Method description End point /getMyRawEnergyData Description Returns a JSON representation of the raw stored energy data of a particular sensor Request method POST Bearer token Required Request RequestParam None RequestBody Field name Description Type minutesBack Number of minutes in the past from the current date Long sensor_id Sensor identifier Long Example Array Response A JSON [...]

/getMyEnergyData

Method description End point /getMyEnergyData Description Returns a JSON representation of the stored energy data of a particular sensor Request method POST Bearer token Required Request RequestParam None RequestBody Field name Description Type monthsBack Number of months in the past from the current date Integer sensor_id Sensor identifier Long Example Array Response A JSON representation [...]