How to set configurable and prompt input IP address

I want to produce an APK of the application, however, the services [GET, POST…] are set to localhost… how do I configue the app so it prompts for the IP address, so the application on other devices can access localhost (in my laptop)