How can I get the data from TTN server to my website?

Hey everyone! I am able to send my sensor data to TTN but I want this information to go on to my website. I researched about this topic but I am perplexed with a lot of terms like “HTTP integration”, “MQTT client”, “NODE-RED”.I am not able to collect all this information together. I don’t have a problem learning any new language like PHP or node.js or any new concept if I have to, but I am not sure what to do? which path to follow? Can any of you please help me out with this?

Thanks.

1 Like

Each has their pros & cons and the only real way for you to know what suits you best is if you give each of them a try.

If you have an external website and can code, a PHP script that receives data from the HTTP Integration is probably the simplest. Basically it calls a URL, what you do with the data it sends is up to you.

If you have command line access to your websites server you could setup an MQTT client or write a Python script to receive data via MQTT and then, again, do as you wish with it.

Node-Red requires you to setup Node-Red as a server process - probably best to look at their tutorials on such things.

1 Like

My final plan was, however, to plot the data on a map but I am sure that would not be difficult once I get the data to website, I can use some map APIs for that. Right??

Thank you so much for the reply.
So, say, If I am able to write that PHP script, do I need to work with node.js for anything? just PHP script and HTTP integration feature of TTN would do the job? I would love if you can provide any example link.
Thanks again.

Only if you want to, but they are totally different things really, which indicates you should concentrate on the simpler of the two, PHP, otherwise, like me, you’ll start coding JavaScript when you mean PHP!

A quick search of the forum for “HTTP Integration PHP” gives this as the first result:

You can check out other results too.

Thank you so much

i am doing just what you describe -
sending my data to
1/ a php script which receives and puts everything into a file, and parsed the json input to produce the input for
2/ leaflet maps (https://leafletjs.com/) as map API

result looks somewhat like this: https://training.itu.dk/ftd/maps/