Page 1 of 1

Send and Receive JSON Messages Over Wifi

Posted: Fri Aug 10, 2018 2:40 pm
by ee_hokie
Hello,

First off I'm pretty new to Raspberry Pi, but I've got some programming experience therefore. Therefore so far I'm not completely lost. I'm working on a project where I need a Raspberry Pi to act as a WiFi access point that will allow another device (another Pi or a computer) to connect to it and send a request, and then the PI will produce a response all using JSON through HTTP. I've been able to successfully setup the Pi as an access point and I've installed NGINX HTTP server. However it's a little fuzzy on how I should process from here. Any direction or help would be greatly appreciated!

Re: Send and Receive JSON Messages Over Wifi

Posted: Sat Aug 11, 2018 11:45 am
by topguy
Any particular programming language you know better than others. If you only want to make a simple web-service and not really show a lot of web-pages then it can be easier to skip the NGINX ( or apache ) solution and implement the HTTP as part of the program that creates the JSON response.

For example using Python..
https://projects.raspberrypi.org/en/pro ... with-flask

It is also pretty easy to make using Javascript and node.js or node-red. ( https://www.arhs-group.com/using-node-r ... bservices/ )