Questions tagged [android-subscriptionmanager]

Android SubscriptionManager is the application interface to SubscriptionController and provides information about the current Telephony Subscriptions.

Filter by
Sorted by
Tagged with
6votes
5answers
10kviews

How to get the mobile number of my device programmatically?

I have tried using 2 methods for retrieving my phone number but both of them don't work. I used: TelephonyManager SubscriptionManager I do get Network name, Country iso, and IMEI but whenever I try ...
user avatar
6votes
1answer
678views

How long does a Subscription ID stick around in Android?

Starting on API Level 22, there is native support in Android for Dual-SIM devices. At the center of the APIs, there is SubscriptionInfo.getSubscriptionId(). Using these IDs, you can retrieve ...
user avatar
4votes
1answer
2kviews

SubscriptionManager.from() Deprecated

Previously we used to get instance of SubscriptionManager using SubscriptionManager subscriptionManager=SubscriptionManager.from(this); butSubscriptionManager.from(context) is deprecated in API 28 , ...
user avatar
  • 18.7k
3votes
1answer
1kviews

Unable to Send Test Notification From Real-time developer notifications in Google Play Console

I have followed these steps: Go to Google Cloud Console and create/select a project. On the header, click to open the menu and select ‘Pub/Sub’, or click https://console.cloud.google.com/cloudpubsub/...
user avatar
  • 33
2votes
0answers
64views

We are unable to change your subscription plan. Manage subscriptions in android application

Im using in-app subscription in my application. there are 3 subscription available in application i.e, monthly, 6 month and yearly. If user subscribed with monthly I'm showing upgrade subscription on ...
user avatar
  • 21
2votes
0answers
94views

Needed clarification for cancelReason from Resource: SubscriptionPurchase

We are working on back-to-back service. To obtain the sub status we leverage the standard API call (Resource: SubscriptionPurchase) to get the current sub state. The most challenge scenario we are ...
user avatar
1vote
1answer
210views

why getActiveSubscriptionInfoList is getting empty for some android 11 devices?

I need to find out device SIM card is present or not(including duel sim devices). So that I have tried Subscription Manager getActiveSubscriptionInfoList API, but it is returning empty for certain ...
user avatar
0votes
1answer
93views

telephonyManager.getAllCellInfo() and subscriptionManager.getActiveSubscriptionInfoList() both returns different mnc (mobile Network code)

I'm trying to get the signal strength of dual sims it works absolutely fine on most of the phones but for some phones (same android version [11] but different geographic location) the MNC code what we ...
user avatar
0votes
0answers
16views

How GPay android app able to manage to fetch mobile number without any permissions

I want to know how Google pay android app fetching, slot one mobile number which is not available from SubscriptionManager,TelephonyManager both api's. without any runtime permission Note: if we have ...
user avatar
0votes
0answers
45views

How to work with an Opportunistic Subscription in Android?

I want to make use of the Opportunistic Subscription as part of the SubscriptionManager in Android. Two questions: Where can I find more documentation for the Opportunistic Subscription? I only see ...
user avatar
0votes
0answers
49views

Subscriptionmanager in Android for dual SIM phone

I'm trying to write an application which works on a Phone with dual/multiple SIM cards. Depending on some characteristics I want to either use SIM1 or SIM2. I want to use Subscriptionmanager to do ...
user avatar
0votes
1answer
203views

Unable to get the all active subscriptions from Google Play

Please help me to figure out what I'm missing. I have an Android App which has a few subscriptions products, in total we have 5 subscriptions (two in use, the rest for internal purposes), all of the ...
user avatar
0votes
1answer
360views

get or set selected default sim card if the user has a dual sim

I have seen this post from 2012 and it has outdated answers. Until around 2015 Android natively supported multiple sim cards in API 22. I heard about SubscriptionManager but I am not quite familiar ...
user avatar
  • 542
0votes
1answer
335views

How to get CID and LAC for Both Sim in case of dual sim mobile Programmatically?

I am working on a project in which I have to track location using the mobile tower. When sim2 is on emergency it is giving null pointer exception in Telephony Manager. I have to get LAC, CID, MCC, ...
user avatar
  • 39