Calling Django server api from android phone
If I understand your question correctly, you have a Django installation on your laptop and you are able to hit a specific page/service locally using "localhost:8000/polls/link/2/" and it works fine. Now you want to access it from your mobile. Correct?
Replace the "localhost" with IP address of your laptop. For example, "10.0.0.1:8000/polls/link/2/"
You will find your IP address in System Preferences -> Network
I am developing an android app. For local testing I have created a django server on my laptop. My problem is I am not able to call django apis from app code. For example, if I want to call any django server api from desktop I write "localhost:8000/polls/link/2/". Now how to replace this "localhost part of url" if calling same api from mobile. And also my desktop is connected to internet by the same mobile hotspot. So basically both desktop and phone are on same network.
My ifconfig command on desktop shows 
And my desktop is Mac and mobile is Samsung core duo