31

I've been reading this website : http://developer.android.com/google/play/billing/billing_subscriptions.html Because I read that "Currently, the In-app Billing API does not provide support for programatically canceling subscriptions from inside the purchasing app", I would like to redirect the user to this page to manage his own subscription.

I'm not able to find how to open the subscription page from an application. I was thinking about opening it like a external link with :

Intent browserIntent = new Intent(Intent.ACTION_VIEW, Uri.parse("http://www.google.com"));
startActivity(browserIntent);

But I don't even know the link I need to put in... -_-

Thanks in advance for your answer! :)

Prashant Jajal
  • 3,469
  • 5
  • 24
  • 38
maudem
  • 804
  • 9
  • 12
  • 5
    Can people at least explain why they down-vote my question? Sorry, but for me, no question are "stupid", so if it's so easy, just tell me the link to the answer or a piece of code! – maudem Apr 29 '16 at 18:05
  • This is from the official Android Developers website: https://developer.android.com/google/play/billing/subs#deep-link – marcouberti Oct 16 '20 at 15:55

3 Answers3

44

Ok, so I haven't received a better answer (actually... no answer at all..yet). For other that might research an answer, here is mine :

    Intent browserIntent = new Intent(Intent.ACTION_VIEW,
                   Uri.parse("https://play.google.com/store/account/subscriptions"));
    startActivity(browserIntent);

Note: It seems, that the market: syntax is deprecated and the web intent is automatically forwarded to the PlayStore app.

schlenger
  • 1,447
  • 1
  • 19
  • 40
maudem
  • 804
  • 9
  • 12
15

Thanks for the code, it helps.

Just to add a little in the URL,

https://play.google.com/store/account/subscriptions

to take you directly at the Subscriptions screen in the phone.

Amit
  • 3,422
  • 3
  • 28
  • 39
12

At google io 2018 they announced this link

https://play.google.com/store/account/subscriptions?sku=XXX&package=YYY

Just replace sku and package

svkaka
  • 3,942
  • 2
  • 31
  • 55