A common design pattern in the Internet of Things space is to have a gateway between devices and the cloud. This is often because devices communicate over short range protocols like Bluetooth and Zigbee which cannot communicate over the wide area network (WAN) to the cloud.

There are many more reasons for using gateways – they can be more sophisticated and perform additional functions like filtering and applying rules at the edge before the data is sent on up to the cloud service.

With Watson IoT Platform, gateways can authenticate with the IoT Platform and send data on behalf of their attached devices.

Until now, a gateway would connect to the IoT Platform using MQTT. ¬† With the new HTTP event support for gateways capability, gateways can connect to the platform using HTTP. ¬†A gateway can then use the new HTTP APIs to send events¬†on behalf of it’s attached devices.

An example:

Use Basic Auth to authenticate using the gateway id and token, then POST using the device id from the attached device:

Basic Auth

User name: g-myorg-mygwtype-gw45

Password: myUnguessableToken

Content-Type: application/json



In the above example the gateway connects to the ‘myorg’ organisation using a gateway id ‘gw45’ with a type of ‘mygwtype’. ¬†It sends a json event on behalf of attached device ‘12344566’ using event id ‘temperature’.

See the full documentation for details: https://console.ng.bluemix.net/docs/services/IoT/gateways/gw_intro_api.html#api

This is Beta capability and we welcome feedback on the features and usability.

Join The Discussion

Your email address will not be published. Required fields are marked *