Page Summary
-
A VoidedPurchase resource represents a purchase that was canceled, refunded, or charged back.
-
The resource provides details about the voided purchase including purchase time, voided time, order ID, initiator, reason, and quantity.
-
The
listmethod is available to retrieve a list of voided purchases. -
Error codes like 5xx and 409 indicate generic server errors or concurrency update errors, respectively.
Resource: VoidedPurchase
A VoidedPurchase resource indicates a purchase that was either canceled/refunded/charged-back.
| JSON representation |
|---|
{ "kind": string, "purchaseToken": string, "purchaseTimeMillis": string, "voidedTimeMillis": string, "orderId": string, "voidedSource": integer, "voidedReason": integer, "voidedQuantity": integer } |
| Fields | |
|---|---|
kind |
This kind represents a voided purchase object in the androidpublisher service. |
purchaseToken |
The token which uniquely identifies a one-time purchase or subscription. To uniquely identify subscription renewals use orderId (available starting from version 3 of the API). |
purchaseTimeMillis |
The time at which the purchase was made, in milliseconds since the epoch (Jan 1, 1970). |
voidedTimeMillis |
The time at which the purchase was canceled/refunded/charged-back, in milliseconds since the epoch (Jan 1, 1970). |
orderId |
The order id which uniquely identifies a one-time purchase, subscription purchase, or subscription renewal. |
voidedSource |
The initiator of voided purchase, possible values are: 0. User 1. Developer 2. Google |
voidedReason |
The reason why the purchase was voided, possible values are: 0. Other 1. Remorse 2. Not_received 3. Defective 4. Accidental_purchase 5. Fraud 6. Friendly_fraud 7. Chargeback 8. Unacknowledged_purchase |
voidedQuantity |
The voided quantity as the result of a quantity-based partial refund. Voided purchases of quantity-based partial refunds may only be returned when includeQuantityBasedPartialRefund is set to true. |
Methods |
|
|---|---|
|
Lists the purchases that were canceled, refunded or charged-back. |
Error codes
The operations of this resource, return the following HTTP error codes:
| Error code | Reason | Description | Resolution |
|---|---|---|---|
400 |
invalidValue |
An invalid value was provided in the request. This is often returned for a malformed or invalid purchase token. | Correct the invalid field value in the request body or parameters based on the API reference. |
400 |
required |
A required field or parameter is missing from the request. | Consult the API documentation to ensure all mandatory fields and parameters are included. |
403 |
userInsufficientPermission |
The user does not have sufficient permission to perform the requested operation. | Ensure the authenticated user has the necessary permissions in the Google Play Console. See Using a service account for more details. |
404 |
notFound |
The requested resource could not be found. | Verify the identifiers (e.g., purchase token, package name, product ID, subscription ID) are correct. |
409 |
concurrentUpdate |
There was an attempt to update an object that is being updated concurrently. | Retry the request with exponential backoff. Avoid simultaneous modifications to the same resource. |
5xx |
Generic error |
Generic error in the Google Play server. | Retry your request. If the problem persists contact your Google Play account manager or submit a support request. Consider checking the Play Status Dashboard for any known outages. |