Offer a better developer experience to Sigfox API

As a backend developer, the Sigfox API is not a really good experience. This for multiple reasons and it is a good example on how a really good product can get a developer push-back just because of the interaction layer.

I can’t change the API itself (and its not y role) but as I was bored to use POSTMAN tool  and the Sigfox backend documentation (who already used it will understand) I decided to spend some hours this week to rewrite most of the API endpoint into a clean open-api format into a Spring application to get benefit of the SpringFox swagger front.

This project is not fully terminated but already in place with the most used API endpoint. The next will arrive soon. Read mode to get access.

Get access to the Sigfox API with a better developer experience

So the tool to access the sigfox API with a better experience is online on the following URL : https://sigfox-api.ingeniousthings.fr/

The way it works is easy:

  • Click on the Authorize button to set your API credentials

  • Enter your Sigfox credential you obtained in the Group >> API ACCESS Menu in the sigfox backend.

  • Click on Authorize button, then on Close

Once it is done, you can use any of the API endpoint without to specify it again.

Now you can select on of the Endpoint:

Watch all the related documentation about input and output of the endpoint and click on Try it Now button to test it. Enter the input data you want and click on Execute.

Then you can see the result:

And access the associated Model:

Access the swagger file

You can directly get the swagger file from this link if you want to use some tool for generating your backend Models or use another proxy or Api Gateway.

Install your own API proxy or accelerate your backend development

The website offering the modern access to Sigfox API is acting as a proxy. I was initially looking for something pure java-script not passing through one of my server but the CORS setting at Sigfox are blocking this for I assume good security reasons. So I have made an API proxy for relaying the requests from my server.

It means your credentials are passing through this server. Nothing is logged or recorded about it but it could. So I recommend to renew them after use.

If you want to avoid this risk, the best way is to implement your own API proxy. For this I released the code used as an open-source project you can get from github:

Access the Sigfox API Proxy and Developer Portail open source project.

The installation is really easy, it just need a Java SDK to be compiled and launched. Then you get it on port http://localhost:8080/swagger-ui.html

 

This entry was posted in Sigfox and tagged , , , . Bookmark the permalink.

Leave a Reply

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.