How do I connect to my Sigfox backed

Setup the connection from Sigfox to DevicePilot

Sigfox's website allows you to create an HTTP callback, for every device on its network, sending a GET, POST or PUT to your server.

To do this, open a browser window and go to Sigfox's backend service:

After logging in, select 'Device Type' and then choose one of your devices by clicking on its 'Name' column, followed by selecting 'Callbacks' in the menu on the left. Finally, select 'New Default Callback' from the top menu.

You'll see something like the following in your browser:


We now want to add some parameters to point to the right host for the callback and send the data we need.

First fill in the Url pattern field. It'll be something like:

Next change the Use HTTP method value to POST.

Then we need to put the DevicePilot API key in the headers:

Authorization Token YOURAPIKEYHERE

set the content type

Content type application/json

and finally fill in the Body section with the following JSON:

"$id" : "{device}",
"basestation" : "{station}",
"averageSnr" : {avgSnr},
"latitude" : {lat},
"longitude" : {lng},
"rssi" : {rssi},
"seqNumber" : {seqNumber},
"snr" : {snr},
"duplicate" : {duplicate}

That completes the basic setup of the callback – once saved and enabled, you should see devices appearing in DevicePilot.

Sigfox payload

In the Sigfox system, all 9 parameters above ({device} to {duplicate}) are all standard fields that are included in all device messages. You also have a 12-byte custom payload in which to encode your specific data.

The recommended way to encode this is using Sigfox’s custom message type decoding grammar. You can see the syntax for this by the Custom payload config.

For instance, you might encode light and temperature using the following syntax:

lightAmbi::uint:16 temperature:2:int:8

Adding that as the Custom payload config creates two new fields that we can use in the JSON body:

"duplicate" : {duplicate},
"lightAmbi" : {customData#lightAmbi},
"temperate" : {customData#temperature}