HTTP Integration example


#1

I have been searching and trying to work out how the HTTP integration works. Can someone please tell me how to add a header and give me an example or even a screenshot. I want to know how to get the deviceName and altitude out of the object field. Any help would be greatly appreciated.


#2

Basically LoRa App Server will post the data to an endpoint of choice. E.g. you could create a http://mockbin.org/ endpoint and configure this endpoint as HTTP integration. You can then see in this http://mockbin.org/ endpoint how LoRa App Server sends the data :slight_smile:

How to parse this data depends on which language you’re going to use when implementing your own endpoint.


#3

I still don’t know how to send the data which is my issue. I can’t find any info anywhere on how to send anything from the HTTP Integration. If someone could give me 1 example of what to put into the header value fields on the integration page I might be able to work out something but I can’t find any documentation anywhere.


#4


Provide an url under the uplink data url. so that whatever lora packet your appication server receives it will automatically push into your server.


#5

cheers. mockbin didn’t work so i used https://requestloggerbin.herokuapp.com and managed to see how it worked. thank you


#6

Hi @Kieren_Black , plz could you give me an example about your Bin Builder? In other words what header (name and value) and body must be implemented to match with loraserver?

From loraserver side if I well understood to add http integration I have to only add endpoint url (recovered from requestloggerbin) ?

thank you


#7

Dear Sobhan Thakur,

Thanks for the help. Now i can able to receive the data as uplink in the live device data tab. However i’'m trying to HTTP integration where i need to push the data to a database in the cloud for my application process. Could you please help me in getting the integration done. i have tried with configuring the URL but i’m not getting any data over there in the link. I have also gone through the sending/receiving data page in loraserver but couldn’t understand better. Please help in providing step by step solution for the integration.

Also i would like to know how to access the internal postgre sql database or redis database to have a look on the previously stored data.

Thanks in Advance!!


#8

One question.

Does this post method send every new live data frame that application receives? - As soon as the live data frame is received by app server it is being forwarded by HTTP post to the endpoint?

I was thinking of creating my own server and posting this data to it for further processing.

How it would work: I would be receiving the data from lora app server, save the data in an array or something of the sort and process it (take the data and maybe some other information like latitude and longitude and check if all the sent data from the node(s) has actually been received by the lora app server).

I was also thinking of using gRPC for that but I got stuck setting everything up. The existing documentation of how to set protobuffers and everything else is just not good enough for me as I am a total beginner.


#9

The lora app server sends all the data in json format each time it receives data. I have it posting to my server then it processes the data then saves it into a MySQL server. I used Laravel for the framework and I used the built in api function for authentication.


#10

So basically it sends all the messages that have been saved in current session under live data?

Example if I get 1 message it sends 1 message. When I receive the second one it sends the first one and the second one and so on?


#11

hello,
in my opinion grpc method must be see as admin part to manage the loraserver.
To expose your data several integration can be implemented.

influxdb + grafana, mqtt ( see https://tago.io/), http endpoint (goto http://postb.in/ it works very well it allows to understand the post request), regarding http endpoint you can add wamp or lamp-xamp or mamp ( depending on your OS) in order to to collect and display your data but to do it you must develop some script in php for example.

You can also add mqtt client over websocket for example see https://www.eclipse.org/paho/


#12

No, it just forwards each message on arrival, not all history.