Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development

Reply
New Developer
Posts: 10
Registered: ‎01-26-2012
My Device: Playbook 16 Go
My Carrier: Free
Accepted Solution

In App Purchase Objects

Hello,

 

I made an app with possibilities to buy new items (eg. graphics, sound, ...).

 

My questions:

 

- Items are they integrated application and unlocked when buying?
- If not, where are they stored after purchase?

 

Thanks in advance for your help.

Developer
Posts: 889
Registered: ‎08-31-2009
My Device: 9530, 9630, 9800, 8530, 9900, 9810, 9930, PlayBook, Dev Alpha
My Carrier: Verizon

Re: In App Purchase Objects

You are responsible for storing apps after purchase (especially for consumable items).

 

However there is a method to request previous purchases...


Read my thoughts on BlackBerry Development at news.ebscer.com
Developer
Posts: 108
Registered: ‎04-14-2013
My Device: BlackBerry Z30
My Carrier: Chunghwa Telecom

Re: In App Purchase Objects

Hi 

 

You can try this sample.

https://github.com/blackberry/Cascades-Community-Samples/tree/master/FreemiumSampleApp

 

Check the function getExisting(bool refresh) in the PaymentServiceControl.cpp

 

void PaymentServiceControl::getExisting(bool refresh) {
  setIsPaymentSystemBusy(true);
  qDebug() << "Get existing. refresh: " << refresh;

  if (!refresh) {
    if (m_digitalGoodsStore.contains("digitalGoods")) {
      QStringList listOfDigitalGoodSkus = m_digitalGoodsStore.value("digitalGoods").toStringList();
      if (!listOfDigitalGoodSkus.isEmpty()) {
      foreach(QString digitalGoodSku, listOfDigitalGoodSkus){
      emit skuOwned(digitalGoodSku);
    }
    setIsPaymentSystemBusy(false);
    return;
 }
}
}

 

Simon

BlackBerry Certified Cascades Developer
Developer
Posts: 262
Registered: ‎07-13-2012
My Device: PlayBook, DA B, DA C, LE Z10 #102, Q10, Z30
My Carrier: T-Mobile

Re: In App Purchase Objects

I think his question is whether or not the assets of whatever is in the "locked" items are included in the original bar file or if they are they received in some fashion via the the "unlocking" process through in app purchaes.

 

If that is the question, then the answer it is possible to do it either way but it is significantly easier to package the locked content (graphics, sounds, etc) in the orginal bar file and have the in app purchase flip a bool to unlock items rather than download assets from an external server (which you would have to run yourself) and have those loaded into the app.

---
Check out my BB10 Cascades Coding site: BBcascades.com & Cascades Blog: bbcascadescode.tumblr.com

My Built for BlackBerry app: The Dive Plan
Developer
Posts: 108
Registered: ‎04-14-2013
My Device: BlackBerry Z30
My Carrier: Chunghwa Telecom

Re: In App Purchase Objects

Oh I see.
Yes, by putting the contents inside the app assets or request download from server are the two ways to let your unlock features work.

Thanks for your explanation, bcs925. Smiley Happy
BlackBerry Certified Cascades Developer
New Developer
Posts: 10
Registered: ‎01-26-2012
My Device: Playbook 16 Go
My Carrier: Free

Re: In App Purchase Objects

Hello,

 

Thank you for that answer that satisfies me.

 

Too bad though that the current system is not more open with BAR files downloaded after purchase.

 

This forces the user of the app to download a large file and if there is an update with new items to download even the largest files. If new items (eg, a pack levels) appear later, You must repeat an update that integrates these items...

 

Yes, through an external server, but in this case it's a problem of security, hack or reverse engineering!