Home > Mobile >  Host endpoints inside Android application
Host endpoints inside Android application

Time:02-15

TLDR : I am looking for a way to expose a POST endpoint from an android app, is this possible ? If so how ?

Long story :

I want to receive data from arudino devices on my android app. So I want a way to get this data through wifi (that may be a wrong assumption) but without internet connection. My current idea is to post the data from the arduino to the smartphone over wifi. enter image description here

The thing I don't know and I didn't find answer yet is : can I get data send to my hotspot wifi inside my app ?

Thank you for any lead.

Regards.

CodePudding user response:

To host endpoints inside your Android application you will need a sever to serve those endpoints. You can use the NanoHttpD for this.

Check this question to check how to use NanoHttpD in Android.

  • Related