3

I am implementing Google's In-App Billing Library in my application and would like to know the best way to handle the following cases

  1. Multiple Device and Single User

Use Case:

  • User U1 with Google Play Store Account G1 subscribes to Subscription S1.
  • Now User U1 log out from the app and User U2 login the app.

Queries:

  • What will happen if User U2 tries to subscribe the Subscription S1?
  • Shall we restrict the User U2 by saying "This Subscription has already been subscribed to some other user from this Google Account"?
  1. Single Device and Multiple User

Use Case I:

  • User U1 with Google Play Store Account G1 subscribes to Subscription S1.
  • User U1 with Google Play Store Account G2 tries to subscribe Subscription S1.

Queries:

  • Shall we restrict the User U1 by saying "You have already subscribed to this subscription by some other Google Account"?

Use Case II

  • User U1 with Google Play Store Account G1 subscribes to Subscription S1.
  • User U1 with Google Play Store Account G2 tries to subscribe Subscription S2.

Queries:

  • Shall we allow the user to subscribe to different subscriptions with different Google Account?

General Queries:

I am expecting a response to my queries in terms of best practices and facts.

Navjot
  • 1,202
  • 1
  • 11
  • 24

2 Answers2

0

Both the purchase of in-app products and subscriptions are strictly linked to the Google account with which they were made.

You cannot know from a Google account the purchases made by another account, it would be a serious security problem if possible.

If two users (two google accounts) want to use the same subscription, both have to buy it separately.

from56
  • 3,976
  • 2
  • 13
  • 23
0

To answer one of your questions:

  • Can we subscribe(purchase) a subscription from 2 users using the same Google Play Account? (Say using different accountId)

Just tried it, and the answer is no. The setting and reading of our custom accountId allows us to know when to show/hide the "subscribe" button. But, when we log in with the other app user and press "subscribe", Google says:

- Error - You're already subscribed to ...

Also tried with adding profileId - same result.

Starwave
  • 2,352
  • 2
  • 23
  • 30