- Home Startseite ホーム 主页 首頁
- SDK
- Dev Guide Handbuch Guía Guide Guida 開発ガイド 开发人员指南 開發指南
- Reference Referenz Referencia Référence Riferimento リファレンス 参考 參考資料
- Resources
- Videos ビデオ
- Blog ブログ 博客 網誌

Android.com

# In-app Billing

## Topics

1. Overview of In-app Billing
2. Implementing In-app Billing
3. Security and Design
4. Testing In-app Billing
5. Administering In-app Billing

## Reference

1. In-app Billing Reference

## Downloads

1. Sample Application

Android Market In-app Billing is an Android Market service that lets you sell digital content in your applications. You can use the service to sell a wide range of content, including downloadable content such as media files or photos, and virtual content such as game levels or potions.

When you use Android Market's in-app billing service to sell an item, Android Market handles all checkout details so your application never has to directly process any financial transactions. Android Market uses the same checkout service that is used for application purchases, so your users experience a consistent and familiar purchase flow (see figure 1). Also, the transaction fee for in-app purchases is the same as the transaction fee for application purchases (30%).

Any application that you publish through Android Market can implement in-app billing. No special account or registration is required other than an Android Market publisher account and a Google Checkout Merchant account. Also, because the service uses no dedicated framework APIs, you can add in-app billing to any application that uses a minimum API level of 4 or higher.

To help you integrate in-app billing into your application, the Android SDK provides a sample application that demonstrates a simple implementation of in-app billing. The sample application contains examples of billing-related classes you can use to implement in-app billing in your application. It also contains examples of the database, user interface, and business logic you might use to implement in-app billing.

Important: Although the sample application is a working example of how you can implement in-app billing, we strongly recommend that you modify and obfuscate the sample code before you use it in a production application. For more information, see Security and Design.

Figure 1. Applications initiate in-app billing requests through their own UI (first screen). Android Market responds to the request by providing the checkout user interface (middle screen). When checkout is complete, the application resumes.

To learn more about Android Market's in-app billing service and start integrating it into your applications, read the following documents:

Overview of In-app Billing
  Learn how the service works and what a typical in-app billing implementation looks like.
Implementing In-app Billing
  Use this step-by-step guide to start incorporating in-app billing into your application.
Security and Design
  Review these best practices to help ensure that your in-app billing implementation is secure and well designed.
Testing In-app Billing
  Understand how the in-app billing test tools work and learn how to test your in-app billing implementation.
Administering In-app Billing
  Learn how to set up your product list, register test accounts, and handle refunds.
In-app Billing Reference
  Get detailed information about Android Market response codes and the in-app billing interface.

↑ Go to top