This sample application demonstrates how to make outbound calls from your android application using the Plivo Android SDK.
- Clone our android sample apps repository.
git clone https://github.com/plivo/plivo-android-examples.gitor download the zip
- Setup Android with Eclipse and Launch eclipse
- Select File -> New -> Other
- Choose 'Android Project From Existing Code' and navigate to the plivo-android-examples folder and click Open
- Create an endpoint with a username and a password. Learn more on how to create an endpoint using this guide.
- Load the PlivoOutbound application in eclipse.
- Edit the source file in the PlivoOutbound application in eclipe :
- Assign your endpoint username and password to the respective variables.
public final static String PLIVO_USERNAME = ""; public final static String PLIVO_PASSWORD = "";
- Assign the mobile or the landline number you want to call to the
public final static String PHONE_NUMBER = "";
- Launch the application from eclipse. And hit the call button.
The app will place the call to the
PHONE_NUMBER added to the code. Make sure you append the country code