Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

USSD on Android from applications

Tags:

android

Is it possible to send and receive response on USSD requests? I've googled this question and i found that this issue isn't implemented yet:

http://code.google.com/p/android/issues/detail?id=1285

Is there any ways do process USSD requests for Android applications?

like image 216
Max Avatar asked Feb 04 '11 19:02

Max


3 Answers

Currently Android is missing support for developers to interact with USSD/MMI. Sending USSD request is easy as suggested by Terence but there's no easy way to handle the incoming USSD response.

As far as i know, currently there are two approaches to follow if you want to interact with the response.

  1. Extracting it from the Logs
  2. or Using the hidden interface - 'com.android.internal.telephony.IExtendedNetworkService' .

The interface is hidden in the telephony package and you need to create aidl of it and include in your project.

here is an example to get you started ..

http://commandus.com/blog/?p=58

like image 96
Purush Pawar Avatar answered Oct 16 '22 08:10

Purush Pawar


Use this USSD Interceptor found on GitHub.

Project description states that it's:

USSD Interceptor is an Android service that allows intercepting and receiving USSD calls text results and re-broadcasting them for any listeners.

Link: github.com/alaasalman/ussdinterceptor

like image 32
King'ori Maina Avatar answered Oct 16 '22 10:10

King'ori Maina


Sending USSD is easy

startActivityForResult(new Intent("android.intent.action.CALL",
   Uri.parse("tel:*123" + Uri.encode("#"))), 1);

Here's a code snippet which should help you with the response. It reads the logs to get the response. From http://codepaste.ru/7545/#

like image 34
Terence Eden Avatar answered Oct 16 '22 09:10

Terence Eden