Skip to content

Latest commit

 

History

History
133 lines (75 loc) · 3.38 KB

CdvPurchase.VerifiedReceipt.md

File metadata and controls

133 lines (75 loc) · 3.38 KB

Class: VerifiedReceipt

CdvPurchase.VerifiedReceipt

Receipt data as validated by the receipt validation server

Table of contents

Properties

Accessors

Methods

Properties

collection

collection: VerifiedPurchase[]

The collection of purchases in this receipt.


id

id: string

Id of the product that have been validated. Used internally.


latestReceipt

latestReceipt: boolean

True if we've used the latest receipt.


nativeTransactions

nativeTransactions: NativeTransaction[]

Raw content from the platform's API.


sourceReceipt

sourceReceipt: Receipt

Source local receipt used for this validation


validationDate

validationDate: Date

Date and time the receipt was verified


warning

Optional warning: string

Optional warning message about this validation.

It might be present when the server had to fallback to a backup validation solution (like a cached response or using local validation only). This happens generally when communication with the platform's receipt validation service isn't possible (because it's down, there's a network issue, ...)

When a warning is present, you should threat the content of this receipt accordingly.

Accessors

platform

get platform(): Platform

Platform this receipt originated from

Returns

Platform


raw

get raw(): Object

Get raw response data from the receipt validation request

Returns

Object

Name Type Description
collection? VerifiedPurchase[] The collection of purchases in this receipt. An array of ValidatorPurchase
date? string Date and time the receipt was validated. It will provide the client with a more reliable clock time than the user's device when needed.
id string Id of the product that have been validated
ineligible_for_intro_price? string[] List of product ids for which intro price isn't available anymore
latest_receipt boolean Tell the plugin that we've used the latest receipt
transaction NativeTransaction Native transaction detail
warning? string A warning message about this validation. It might be present when the server had to fallback to a backup validation solution.

Methods

finish

finish(): Promise<void>

Finish all transactions in the receipt

Returns

Promise<void>