Skip to content

Commit 92ad16d

Browse files
Bill GruberAndroid (Google) Code Review
authored andcommitted
Merge "Cherrypick from HCMR2 Change ID: Id849cb25098fef76c96c4935db31ebc1422d74d8 IAB doc update: CSV import feature Also fixed Bug 5221766" into ics-mr0
2 parents 8f3993b + 0c2d3c5 commit 92ad16d

File tree

3 files changed

+250
-25
lines changed

3 files changed

+250
-25
lines changed

docs/html/guide/market/billing/billing_admin.jd

Lines changed: 250 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -39,12 +39,12 @@ few administrative tasks, including setting up and maintaining your product list
3939
site, registering test accounts, and handling refunds when necessary.</p>
4040

4141
<p>You must have an Android Market publisher account to register test accounts. And you must have a
42-
Google Checkout Merchant account to create a product list and issue refunds to your users. If you
42+
Google Checkout merchant account to create a product list and issue refunds to your users. If you
4343
already have a publisher account on Android Market, you can use your existing account. You do not
4444
need to register for a new account to support in-app billing. If you do not have a publisher
4545
account, you can register as an Android Market developer and set up a publisher account at the
4646
Android Market <a href="http://market.android.com/publish">publisher site</a>. If you do not have a
47-
Google Checkout Merchant account, you can register for one at the <a
47+
Google Checkout merchant account, you can register for one at the <a
4848
href="http://checkout.google.com">Google Checkout site</a>.</p>
4949

5050
<h2 id="billing-list-setup">Creating a Product List</h2>
@@ -57,7 +57,7 @@ items that are listed in another application's product list.</p>
5757
<p>You can access an application's product list by clicking the <strong>In-App Products</strong>
5858
link that appears under each of the applications that are listed for your publisher account (see
5959
figure 1). The <strong>In-App Products</strong> link appears only if you have a Google Checkout
60-
Merchant account and an application's manifest includes the <code>com.android.vending.BILLING</code>
60+
merchant account and an application's manifest includes the <code>com.android.vending.BILLING</code>
6161
permission.</p>
6262

6363
<img src="{@docRoot}images/billing_product_list_entry.png" height="548" id="figure1" />
@@ -71,28 +71,45 @@ product description, and price (see figure 2). The product list stores only meta
7171
you are selling in your application. It does not store any digital content. You are responsible for
7272
storing and delivering the digital content that you sell in your applications.</p>
7373

74-
<img src="{@docRoot}images/billing_product_list.png" height="560" id="figure2" />
74+
<img src="{@docRoot}images/billing_product_list.png" height="658" id="figure2" />
7575
<p class="img-caption">
7676
<strong>Figure 2.</strong> An application's product list.
7777
</p>
7878

79-
<p>You can create a product list for a published application or a draft application that's been
80-
uploaded and saved to the Android Market site. However, you must have a Google Checkout Merchant
79+
<p>You can create a product list for any published application or any draft application that's been
80+
uploaded and saved to the Android Market site. However, you must have a Google Checkout merchant
8181
account and the application's manifest must include the <code>com.android.vending.BILLING</code>
8282
permission. If an application's manifest does not include this permission, you will be able to edit
8383
existing items in the product list but you will not be able to add new items to the list. For more
84-
information, see <a href="#billing-permission">Modifying your application's AndroidManifest.xml
85-
file</a>.</p>
84+
information about this permission, see
85+
<a href="{@docRoot}guide/market/billing/billing_integrate.html#billing-permission">Updating Your
86+
Application's Manifest</a>.</p>
8687

87-
<p>To create a product list for an application, follow these steps:</p>
88+
<p>In addition, an application package can have only one product list. If you create a product
89+
list for an application, and you use the <a
90+
href="{@docRoot}guide/market/publishing/multiple-apks.html">multiple APK feature</a> to distribute
91+
more than one APK for that application, the product list applies to all APK versions that are
92+
associated with the application listing. You cannot create individual product lists for each APK if
93+
you are using the multiple APK feature.</p>
94+
95+
<p>You can add items to a product list two ways: you can add items one at a time by using the In-app
96+
Products UI (see figure 3), or you can add a batch of items by importing the items from a
97+
comma-separated values (CSV) file (see figure 2). Adding items one at a time is useful if your
98+
application has only a few in-app items or you are adding only a few items to a
99+
product list for testing purposes. The CSV file method is useful if your application has a large
100+
number of in-app items.</p>
101+
102+
<h3 id="billing-form-add">Adding items one at a time to a product list</h3>
103+
104+
<p>To add an item to a product list using the In-app Products UI, follow these steps:</p>
88105

89106
<ol>
90107
<li><a href="http://market.android.com/publish">Log in</a> to your publisher account.</li>
91108
<li>In the <strong>All Android Market listings</strong> panel, under the application name, click
92109
<strong>In-app Products</strong>.</li>
93110
<li>On the In-app Products List page, click <strong>Add in-app product</strong>.</li>
94111
<li>On the Create New In-app Product page (see figure 3), provide details about the item you are
95-
selling and then click <strong>Save</strong>.</li>
112+
selling and then click <strong>Save</strong> or <strong>Publish</strong>.</li>
96113
</ol>
97114

98115
<img src="{@docRoot}images/billing_list_form.png" height="840" id="figure3" />
@@ -109,25 +126,31 @@ file</a>.</p>
109126
(0-9), underlines (_), and dots (.). The product ID "android.test" is reserved, as are all
110127
product IDs that start with "android.test."</p>
111128
<p>In addition, you cannot modify an item's product ID after it is created, and you cannot reuse
112-
a product ID, even if you delete the item previously using the product ID.</p>
129+
a product ID.</p>
113130
</li>
114-
<li><strong>Purchase type</strong>
115-
<p>The purchase type can be "managed per user account" or "unmanaged." You can specify an item's
116-
purchase type only through the publisher site and you can never change an item's purchase type
117-
once you specify it. For more information, see <a href="#billing_purchase_type">Choosing a
118-
purchase type</a> later in this document.</p>
131+
<li><strong>Purchase Type</strong>
132+
<p>The purchase type can be <strong>Managed per user account</strong> or <strong>
133+
Unmanaged</strong>. You can never change an item's purchase type after you set it. For more
134+
information, see <a href="#billing-purchase-type">Choosing a purchase type</a> later in this
135+
document.</p>
119136
</li>
120137
<li><strong>Publishing State</strong>
121-
<p>An item's publishing state can be "published" or "unpublished." However, to be visible to a
122-
user during checkout, an item's publishing state must be set to "published" and the item's
123-
application must be published on Android Market.</p>
138+
<p>An item's publishing state can be <strong>Published</strong> or <strong>Unpublished
139+
</strong>. To be visible to a user during checkout, an item's publishing state must be set to
140+
<strong>Published</strong> and the item's application must be published on Android Market.</p>
124141
<p class="note"><strong>Note:</strong> This is not true for test accounts. An item is visible to
125142
a test account if the application is not published and the item is published. See <a
126143
href="{@docRoot}guide/market/billing/billing_testing.html#billing-testing-real">Testing In-app
127144
Billing</a> for more information.</p>
128145
</li>
129146
<li><strong>Language</strong>
130-
<p>A product list inherits its language from the parent application.</p>
147+
<p>The language setting determines which languages are used to display the item title and
148+
item description during checkout. A product list inherits its default language from the
149+
parent application. You can add more languages by clicking <strong>add language</strong>. You
150+
can also choose to have the title and description automatically translated from the default
151+
language by selecting the <strong>Fill fields with auto translation</strong> checkbox (see
152+
figure 4). If you do not use the auto translation feature, you must provide the translated
153+
versions of the title and description.</p>
131154
</li>
132155
<li><strong>Title</strong>
133156
<p>The title is a short descriptor for the item. For example, "Sleeping potion." Titles must be
@@ -141,9 +164,20 @@ file</a>.</p>
141164
visible to users during checkout. Descriptions can be up to 80 characters in length.</p>
142165
</li>
143166
<li><strong>Price</strong>
144-
<p>Every item must have a price greater than zero; you cannot set a price of "0" (free).</p>
167+
<p>You must provide a default price in your home currency. You can also provide prices in other
168+
currencies, but you can do this only if a currency's corresponding country is listed as a
169+
target country for your application. You can specify target countries on the Edit Application
170+
page in the Android Market developer console.</p>
171+
<p>To specify prices in other currencies, you can manually enter the price for each
172+
currency or you can click <strong>Auto Fill</strong> and let Android Market do a one-time
173+
conversion from your home currency to the currencies you are targeting (see figure 4).</p>
145174
</li>
146175
</ul>
176+
<img src="{@docRoot}images/billing_list_form_2.png" height="1226" id="figure4" />
177+
<p class="img-caption">
178+
<strong>Figure 4.</strong> Specifying additional currencies and additional languages for the
179+
item title and description.
180+
</p>
147181

148182
<p>For more information about product IDs and product lists, see <a
149183
href="http://market.android.com/support/bin/answer.py?answer=1072599">Creating In-App Product
@@ -154,6 +188,197 @@ Pricing</a>.</p>
154188
<p class="note"><strong>Note</strong>: Be sure to plan your product ID namespace. You cannot reuse
155189
or modify product IDs after you save them.</p>
156190

191+
<h3 id="billing-bulk-add">Adding a batch of items to a product list</h3>
192+
193+
<p>To add a batch of items to a product list using a CSV file, you first need to create your CSV
194+
file. The data values that you specify in the CSV file represent the same data values you specify
195+
manually through the In-app Products UI (see <a href="#billing-form-add">Adding items one at a time
196+
to a product list</a>). The CSV file uses commas (,) and semi-colons (;) to separate data values.
197+
Commas are used to separate primary data values, and semi-colons are used to separate subvalues. For
198+
example, the syntax for the CSV file is as follows:</p>
199+
200+
<p>"<em>product_id</em>","<em>publish_state</em>","<em>purchase_type</em>","<em>autotranslate</em>
201+
","<em>locale</em>; <em>title</em>; <em>description</em>","<em>autofill</em>","<em>country</em>;
202+
<em>price</em>"
203+
</p>
204+
205+
<p>Descriptions and usage details are provided below.</p>
206+
207+
<ul>
208+
<li><em>product_id</em>
209+
<p>This is equivalent to the In-app Product ID setting in the In-app Products UI. If you specify
210+
a <em>product_id</em> that already exists in a product list, and you choose to overwrite
211+
the product list while importing the CSV file, the data for the existing item is overwritten with
212+
the values specified in the CSV file. The overwrite feature does not delete items that are on a
213+
product list but not present in the CSV file.</p>
214+
</li>
215+
<li><em>publish_state</em>
216+
<p>This is equivalent to the Publishing State setting in the In-app Products UI. Can be <code>
217+
published</code> or <code>unpublished</code>.</p>
218+
</li>
219+
<li><em>purchase_type</em>
220+
<p>This is equivalent to the Purchase Type setting in the In-app Products UI. Can be <code>
221+
managed_by_android</code>, which is equivalent to <strong>Managed per user account
222+
</strong> in the In-app Products UI, or <code>managed_by_publisher</code>, which is equivalent
223+
to <strong>Unmanaged</strong> in the In-app Products UI.</p>
224+
</li>
225+
<li><em>autotranslate</em>
226+
<p>This is equivalent to selecting the <strong>Fill fields with auto translation</strong>
227+
checkbox in the In-app Products UI. Can be <code>true</code> or <code>false</code>.</p>
228+
</li>
229+
<li><em>locale</em>
230+
<p>This is equivalent to the Language setting in the In-app Products UI. You must have an entry
231+
for the default locale. The default locale must be the first entry in the list of
232+
locales, and it must include a <em>title</em> and <em>description</em>. If you want to provide
233+
translated versions of the <em>title</em> and <em>description</em> in addition to the default,
234+
you must use the following syntax rules:</p>
235+
<p>If <em>autotranslate</em> is <code>true</code>, you must specify the default locale,
236+
default title, default description, and other locales using the following format:</p>
237+
<p>"true,"<em>default_locale</em>; <em>default_locale_title</em>;
238+
<em>default_locale_description</em>; <em>locale_2</em>; <em>locale_3</em>, ..."</p>
239+
<p>If <em>autotranslate</em> is <code>false</code>, you must specify the default locale,
240+
default title, and default description as well as the translated titles and descriptions using
241+
the following format:</p>
242+
<p>"false,"<em>default_locale</em>; <em>default_locale_title</em>;
243+
<em>default_locale_description</em>; <em>locale_2</em>; <em>locale_2_title</em>;
244+
<em>local_2_description</em>; <em>locale_3</em>; <em>locale_3_title</em>;
245+
<em>locale_3_description</em>; ..."</p>
246+
<p>See table 1 for a list of the language codes you can use with the <em>locale</em> field.</p>
247+
</li>
248+
<li><em>title</em>
249+
<p>This is equivalent to the Title setting in the In-app Products UI. If the <em>title</em>
250+
contains a semicolon, it must be escaped with a backslash (for example, "\;"). A backslash
251+
should also be escaped with a backslash (for example, "\\">.</p>
252+
</li>
253+
<li><em>description</em>
254+
<p>This is equivalent to the Description in the In-app Products UI. If the <em>description</em>
255+
contains a semicolon, it must be escaped with a backslash (for example, "\;"). A backslash
256+
should also be escaped with a backslash (for example, "\\">.</p>
257+
</li>
258+
<li><em>autofill</em>
259+
<p>This is equivalent to clicking <strong>Auto Fill</strong> in the In-app Products UI. Can be
260+
<code>true</code> or <code>false</code>. The syntax for specifying the <em>country</em>
261+
and <em>price</em> varies depending on which <em>autofill</em> setting you use.</p>
262+
<p>If <em>autofill</em> is set to <code>true</code>, you need to specify only the default
263+
price in your home currency and you must use this syntax:</p>
264+
<p>"true","<em>default_price_in_home_currency</em>"
265+
<p>If <em>autofill</em> is set to <code>false</code>, you need to specify a <em>country</em>
266+
and a <em>price</em> for each currency and you must use the following syntax:</p>
267+
<p>"false", "<em>home_country</em>; <em>default_price_in_home_currency</em>; <em>country_2</em>;
268+
<em>country_2_price</em>; <em>country_3</em>; <em>country_3_price</em>; ..."</p>
269+
</li>
270+
<li><em>country</em>
271+
<p>The country for which you are specifying a price. You can only list countries that your
272+
application is targeting. The country codes are two-letter uppercase
273+
ISO country codes (such as "US") as defined by
274+
<a href="http://en.wikipedia.org/wiki/ISO_3166-1_alpha-2">ISO 3166-2</a>.</p>
275+
</li>
276+
<li><em>price</em>
277+
<p>This is equivalent to the Price in the In-app Products UI. The price must be specified in
278+
micro-units. To convert a currency value to micro-units, you multiply the real value by 1,000,000.
279+
For example, if you want to sell an in-app item for $1.99 you specify 1990000 in the
280+
<em>price</em> field.</p>
281+
</li>
282+
</ul>
283+
284+
<p class="table-caption" id="language-table"><strong>Table 1.</strong> Language codes you can use
285+
with the <em>locale</em> field.</p>
286+
287+
<table>
288+
289+
<tr>
290+
<th>Language</th>
291+
<th>Code</th>
292+
<th>Language</th>
293+
<th>Code</th>
294+
</tr>
295+
<tr>
296+
<td>Chinese</td>
297+
<td>zh_TW</td>
298+
<td>Italian</td>
299+
<td>it_IT</td>
300+
</tr>
301+
<tr>
302+
<td>Czech</td>
303+
<td>cs_CZ</td>
304+
<td>Japanese</td>
305+
<td>ja_JP</td>
306+
</tr>
307+
<tr>
308+
<td>Danish</td>
309+
<td>da_DK</td>
310+
<td>Korean</td>
311+
<td>ko_KR</td>
312+
</tr>
313+
<tr>
314+
<td>Dutch</td>
315+
<td>nl_NL</td>
316+
<td>Norwegian</td>
317+
<td>no_NO</td>
318+
</tr>
319+
<tr>
320+
<td>English</td>
321+
<td>en_US</td>
322+
<td>Polish</td>
323+
<td>pl_PL</td>
324+
</tr>
325+
<tr>
326+
<td>French</td>
327+
<td>fr_FR</td>
328+
<td>Portuguese</td>
329+
<td>pt_PT</td>
330+
</tr>
331+
<tr>
332+
<td>Finnish</td>
333+
<td>fi_FI</td>
334+
<td>Russian</td>
335+
<td>ru_RU</td>
336+
</tr>
337+
<tr>
338+
<td>German</td>
339+
<td>de_DE</td>
340+
<td>Spanish</td>
341+
<td>es_ES</td>
342+
</tr>
343+
<tr>
344+
<td>Hebrew</td>
345+
<td>iw_IL</td>
346+
<td>Swedish</td>
347+
<td>sv_SE</td>
348+
</tr>
349+
<tr>
350+
<td>Hindi</td>
351+
<td>hi_IN</td>
352+
<td>--</td>
353+
<td>--</td>
354+
</tr>
355+
</table>
356+
357+
<p>To import the items that are specified in your CSV file, do the following:</p>
358+
359+
<ol>
360+
<li><a href="http://market.android.com/publish">Log in</a> to your publisher account.</li>
361+
<li>In the <strong>All Android Market listings</strong> panel, under the application name, click
362+
<strong>In-app Products</strong>.</li>
363+
<li>On the In-app Products List page, click <strong>Choose File</strong> and select your CSV
364+
file.
365+
<p>The CSV file must be on your local computer or on a local disk that is connected to your
366+
computer.</p>
367+
</li>
368+
<li>Select the <strong>Overwrite</strong> checkbox if you want to overwrite existing items in
369+
your product list.
370+
<p>This option overwrites values of existing items only if the value of the <em>product_id</em>
371+
in the CSV file matches the In-app Product ID for an existing item in the product list.
372+
Overwriting does not delete items that are on a product list but not present in the CSV
373+
file.</p>
374+
</li>
375+
<li>On the In-app Products List page, click <strong>Import from CSV</strong>.</li>
376+
</ol>
377+
378+
<p>You can also export an existing product list to a CSV file by clicking <strong>Export to CSV
379+
</strong> on the In-app Product List page. This is useful if you have manually added items to
380+
a product list and you want to start managing the product list through a CSV file.</p>
381+
157382
<h3 id="billing-purchase-type">Choosing a Purchase Type</h3>
158383

159384
<p>An item's purchase type controls how Android Market manages the purchase of the item. There are
@@ -194,7 +419,7 @@ times.</p>
194419

195420
<p>In-app billing does not allow users to send a refund request to Android Market. Refunds for
196421
in-app purchases must be directed to you (the application developer). You can then process the
197-
refund through your Google Checkout Merchant account. When you do this, Android Market receives a
422+
refund through your Google Checkout merchant account. When you do this, Android Market receives a
198423
refund notification from Google Checkout, and Android Market sends a refund message to your
199424
application. For more information, see <a
200425
href="{@docRoot}guide/market/billing/billing_overview.html#billing-action-notify">Handling
@@ -236,15 +461,15 @@ accounts yourself and distribute the credentials to your developers or testers.<
236461
<li><a href="http://market.android.com/publish">Log in</a> to your publisher account.</li>
237462
<li>On the upper left part of the page, under your name, click <strong>Edit profile</strong>.</li>
238463
<li>On the Edit Profile page, scroll down to the Licensing &amp; In-app Billing panel (see figure
239-
4).</li>
464+
5).</li>
240465
<li>In Test Accounts, add the email addresses for the test accounts you want to register,
241466
separating each account with a comma.</li>
242467
<li>Click <strong>Save</strong> to save your profile changes.</li>
243468
</ol>
244469

245-
<img src="{@docRoot}images/billing_public_key.png" height="510" id="figure4" />
470+
<img src="{@docRoot}images/billing_public_key.png" height="510" id="figure5" />
246471
<p class="img-caption">
247-
<strong>Figure 4.</strong> The Licensing and In-app Billing panel of your account's Edit Profile
472+
<strong>Figure 5.</strong> The Licensing and In-app Billing panel of your account's Edit Profile
248473
page lets you register test accounts.
249474
</p>
250475

137 KB
Loading
11.8 KB
Loading

0 commit comments

Comments
 (0)