Channel Data Forwarding (Beta) November 26, 2018

Overview

The Channel Data Forwarding service will forward a copy of the original feed data from any UbiBot device to the given URL endpoint. This can be useful to seamlessly connect UbiBot devices to third-party platform business logic or third-party applications. This service requires activation on the UbiBot platform along with some development work on the data endpoint to correctly handle the incoming data feeds.

Activation Method

  • Please login to https://console.ubibot.io 
  • From left side menu, click “Data Factory”->”Data Forwarding”.
  • Follow the “Add new forwarding” instructions.

Data Forwarding Message Format

Data forwarding is achieved by sending POST requests to the given endpoint URL. The Content-Type header is set to “application/json”. The original feed data is contained in the request body as follows:

  • The feed data will be forwarded in JSON format to the given URL
  • The unique device channel_id: (string) can be used to distinguish the data from different devices.
  • The feeds are an array consisting of:
    • created_at:  the time when the data feed was sampled in ISO 8901 format.
    • field1..field10: sensor readings
    • status:  status information, such as SSID and ICCID

Note that you will need to send a response to the UbiBot platform within 15 seconds for each message

Example Forwarded Data:

 Requirements for Endpoint Response

  • Please ensure the endpoint’s response is made within 15 seconds, otherwise the platform will close the connection.
  • If the endpoint sends a response with the string “SUCCESS”, the platform will mark this forward request as successful. If the endpoint sends the string “ERROR” it means the request was unsuccessful. The UbiBot platform keeps track of all the response results for statistics purposes.

Simple PHP endpoint example: