class PurchasesProducts extends Resource (View source)

The "products" collection of methods.

Typical usage is:

 $androidpublisherService = new Google\Service\AndroidPublisher(...);
 $products = $androidpublisherService->purchases_products;

Methods

acknowledge(string $packageName, string $productId, string $token, ProductPurchasesAcknowledgeRequest $postBody, array $optParams = [])

Acknowledges a purchase of an inapp item. (products.acknowledge)

consume(string $packageName, string $productId, string $token, array $optParams = [])

Consumes a purchase for an inapp item. (products.consume)

get(string $packageName, string $productId, string $token, array $optParams = [])

Checks the purchase and consumption status of an inapp item. (products.get)

Details

acknowledge(string $packageName, string $productId, string $token, ProductPurchasesAcknowledgeRequest $postBody, array $optParams = [])

Acknowledges a purchase of an inapp item. (products.acknowledge)

Parameters

string $packageName

The package name of the application the inapp product was sold in (for example, 'com.some.thing').

string $productId

The inapp product SKU (for example, 'com.some.thing.inapp1').

string $token

The token provided to the user's device when the inapp product was purchased.

ProductPurchasesAcknowledgeRequest $postBody
array $optParams

Optional parameters.

Exceptions

Exception

consume(string $packageName, string $productId, string $token, array $optParams = [])

Consumes a purchase for an inapp item. (products.consume)

Parameters

string $packageName

The package name of the application the inapp product was sold in (for example, 'com.some.thing').

string $productId

The inapp product SKU (for example, 'com.some.thing.inapp1').

string $token

The token provided to the user's device when the inapp product was purchased.

array $optParams

Optional parameters.

Exceptions

Exception

ProductPurchase get(string $packageName, string $productId, string $token, array $optParams = [])

Checks the purchase and consumption status of an inapp item. (products.get)

Parameters

string $packageName

The package name of the application the inapp product was sold in (for example, 'com.some.thing').

string $productId

The inapp product SKU (for example, 'com.some.thing.inapp1').

string $token

The token provided to the user's device when the inapp product was purchased.

array $optParams

Optional parameters.

Return Value

ProductPurchase

Exceptions

Exception