In-App Purchase Programming Guide----(一) ---- About In-App Purchase

About In-App Purchase

In-App Purchase allows you to embed a store inside your app using the Store Kit framework. This framework connects to the App Store on your app’s behalf to securely process payments from users, prompting them to authorize payment. The framework then notifies your app, which provides the purchased items to users. Use In-App Purchase to collect payment for additional features and content.html

内置购买使用Store Kit 框架在应用程序里内置一个商店。该框架把你的应用程序的行为链接到应用商店来安全地处理用户的支付,促使他们受权支付。 而后框架给你的应用程序发送通知,该应用程序提供了用户购买的商品。使用内置购买能够为额外的功能和内容提供支付。ios

Art/remote_store_fetch_2x.png

For example, using In-App Purchase, you can implement the following scenarios:安全

好比,使用内置购买,你能够实现如下内容:app

  • A basic version of your app with additional premium features框架

    一个带有额外高级功能的应用程序的基础版本。ide

  • A magazine app that lets users purchase and download new issues测试

    一个可让用户购买和下载新刊的杂志应用。fetch

  • A game that offers new levels to exploreui

    一个提供新关卡让用户攻克的游戏。this

  • An online game that allows players to purchase virtual property

    一个容许玩家购买虚拟资产在线游戏。

At a Glance

概论

At a high level, the interactions between the user, your app, and the App Store during the In-App Purchase process take place in three stages, as shown in Figure I-1. First, the user navigates to your app’s store and your app displays its products. Second, the user selects a product to buy and the app requests payment from the App Store. Third, the App Store processes the payment and your app delivers the purchased product.

从高层次来讲,内置购买过程处理期间,用户,应用程序和应用商店之间的交互发生在三个阶段,如图I-1。首先,用户导航到你的应用程序商店,你的应用程序显示其产品。 其次,用户选择一个产品购买,应用程序从应用商店请求支付。 最后,应用商店处理该支付,你的应用程序传递被购产品。

Figure I-1  Stages of the purchase process

图I-1 购买过程的阶段

You Create and Configure Products in iTunes Connect

1、在iTunes Connect里建立和配置产品

Understanding what kinds of products and behaviors are supported by In-App Purchase lets you design your app and in-app store to make the best use of this technology.

理解内置购买支持哪些产品和行为让你最大化使用该技术来设计应用程序和内置商店。

Your App Interacts with the App Store to Sell Products

2、应用程序跟应用商店交互来出售产品

All apps that use In-App Purchase need to implement the core functionality described in these chapters to let users make purchases and then deliver the purchased products.

全部使用内置购买的应用程序都须要实现这些章节中描述的内核功能,让用户能够购买而后传递已购的产品。

These development tasks need to be done in order. The relevant chapters introduce them in the order you implement them, and they’re listed in full in“Implementation Checklist.” To help plan your development, you may want to read the full checklist before you begin.

这些开发任务须要按顺序完成。 相关章节按照你实现它们的顺序介绍,它们在“Implementation Checklist.”中有完整列表来帮助你计划你的开发,你能够在开始前先阅读完整的清单。

Subscriptions Require Additional Application Logic

3、订阅须要更多应用逻辑

Apps that offer subscriptions need to keep track of when the user has an active subscription, respond to expiration and renewal, and determine what content the user has access to.

提供订阅的应用程序须要随时监控用户什么时候有一个活动订阅,响应到期和续期,而后决定用户访问什么内容。

Users Can Restore Purchases

4、用户能够恢复购买

Users can restore products that they previously purchased—for example, to bring content they’ve already paid for onto their new phone.

用户能够恢复它们先前已经购买的产品--好比,能够把购买产品给新的手机使用。

Apps and Products Are Submitted for Review

5、应用程序和产品须要提交审核

When you’re done developing and testing, you submit your app and your In-App Purchase products for review.

当你完成开发和测试后,你须要提交你的应用程序和内置购买产品以供审核。

See Also

参见

相关文章
相关标签/搜索