SlideServe
Menu
Préférences
© SlideServe · v2026

Implementing In-App Purchases on iOS

yaron avatar
13 diapositives · 330 Views · Jul 27, 2014

Implementing In-App Purchases on iOS. Christina Moulton Teak Mobile Inc Teakmobile.com @ ChristinaMltn. How?. App Store Set up App Add items In App Purchase Restore S erver? MKStoreKit. Decisions. Price? Business Model Consumable Non-Consumable Subscription (auto-renew?)

Implementing In-App Purchases on iOS - slide 1
01 / 13Implementing In-App Purchases on iOS
1 / 17

Télécharger la présentation

Implementing In-App Purchases on iOS
Une image / un lien ci-dessous est fourni (tel quel) pour télécharger la présentation

Politique de téléchargement : le contenu du site vous est fourni TEL QUEL pour votre information et votre usage personnel ; il ne peut être vendu, concédé sous licence ni partagé sur d’autres sites sans l’accord de son auteur.Le contenu vous est fourni TEL QUEL, pour votre information et votre usage personnel uniquement. Téléchargez la présentation en cliquant sur ce lien. Lors du téléchargement, si vous ne parvenez pas à télécharger une présentation, l’éditeur a peut-être supprimé le fichier de son serveur.Pendant le téléchargement, si vous ne parvenez pas à obtenir une présentation, le fichier a peut-être été supprimé par l’éditeur.

F I N

Plus de contenu associé

Transcription de la présentation
  1. Implementing In-App Purchases on iOS Christina Moulton Teak Mobile Inc Teakmobile.com @ChristinaMltn

  2. How? • App Store • Set up App • Add items • In App • Purchase • Restore • Server? • MKStoreKit

  3. Decisions • Price? • Business Model • Consumable • Non-Consumable • Subscription (auto-renew?) • Content Delivery • Compiled in • Your server • Apple Hosted

  4. Rules • Reviewed like apps • Must use Apple’s API • Only virtual goods • No intermediate currency • Subscriptions: Minimum 7 days, all devices • Can’t sell access to camera, gyroscope, etc. • Auto-renewing subscriptions only for periodicals, biz or media apps See https://developer.apple.com/appstore/resources/approval/guidelines.html

  5. Set Up: App & Products • Create Explicit App ID iniOS Provisioning Portal • Create App in iTunesConnect • Add Product(s) in iTunesConnect

  6. Used for auto-renewing subscriptions

  7. Implementation: Requirements • Transaction completion went app interrupted • Track # of consumables • Restore non-consumables on multiple devices • Remember purchases securely (Keychain) • Remember non-renewing subscriptions • Validate of auto-renewing subscriptions on each launch (latest purchase date) • Deliver content (check receipts on your server) • Localized prices and descriptions

  8. Implementation: MKStoreKit Pt.1 • https://github.com/MugunthKumar/MKStoreKit • Add MKStoreKit to project • Add Security and StoreKit Frameworks • Init in app delegate: [MKStoreManagersharedManager]; • Configure Plist • (If renewable, add shared secret to MKStoreKitConfigs.h)

  9. Implementation: MKStoreKit Pt.2 • Implement purchase [[MKStoreManagersharedManager] buyFeature:kFeatureAId onComplete:^(NSString* purchasedFeature, NSData* purchasedReceipt, NSArray* downloads) { NSLog(@"Purchased: %@", purchasedFeature); } onCancelled:^ { NSLog(@"User Cancelled Transaction"); }]; • (If auto-renewing, setup expiry notifications) • Pull data from App Store to populate UI • Implement restoring purchases

  10. Implementation: Testing • Test User Account in iTunesConnect • Banking & tax contracts must be set up • Other than hosted content, can use simulator • Sandbox can be slow

  11. Resources • Demo Project: https://github.com/cmoulton/ioskwiap • MKStoreKit: https://github.com/MugunthKumar/MKStoreKit • Intro to MKStoreKit: http://blog.mugunthkumar.com/coding/using-mkstorekit-in-your-apps/ • App Store Review Guidelines: https://developer.apple.com/appstore/resources/approval/guidelines.html • Based on iOS 5 Programming: Pushing the Limits, ch. 14: Selling Past the Sale with In App Purchases http://www.amazon.ca/iOS-Programming-Pushing-Limits-Extraordinary/dp/1119961327