GooglePlayのレシート linkedPurchaseToken について

定期購読時にキャンセルしたりアップグレードしたときに付与されるlinkedPurchaseTokenフィールド

発生するケースは以下の2パターン

サブスクリプションを購入後、期限前にキャンセルし、再び期限前に購入(1ヶ月のプランで、即日解約して、翌日買い直し)
サブスクリプションを購入後、別のプランにアップグレード

この場合にlinkedPurchaseTokenが以前のレシート情報を保持するtokenとなる(linkedPurchaseTokenは直訳すればつながれている購入履歴トークン)

以下GoogleのAPIページの意訳をしてみる。

For example, suppose a user originally signs up and you receive purchase token X, then the user cancels and goes through the resignup flow (before their subscription lapses) and you receive purchase token Y, and finally the user upgrades their subscription and you receive purchase token Z. If you call this API with purchase token Z, this field will be set to Y. If you call this API with purchase token Y, this field will be set to X. If you call this API with purchase token X, this field will not be set.

例えば、最初に購入したトークンをXとする。それをキャンセルしたのち、サブスクリプションの期限無いにもう一度購入するとトークンYが発行される。この後さらにプランをアップグレードするとトークンZが発行される。

トークンZでレシート検証APIを呼ぶと、linkedPurchaseTokenにはトークンYがセットされる。
トークンYでレシート検証APIを呼ぶと、linkedPurchaseTokenにはトークンXがセットされる。
トークンXでレシート検証APIを呼ぶと、linkedPurchaseTokenにはなにも設定されない。

カテゴリー: Android タグ: , パーマリンク

コメントを残す

メールアドレスが公開されることはありません。

Time limit is exhausted. Please reload the CAPTCHA.