Integrator transaction lookup

When creating a charge with YocoSDK.charge(), third party integrators can pass an optional receiptNumber in PaymentParameters. The receiptNumber must be unique, and it is the responsibility of integrators to store. The receiptNumber allows for lookup if a transaction result is lost, due to e.g. application exiting prematurely.

The information can be retrieved by calling YocoSDK.getIntegratorTransactions().

Usage

This will allow you to get the PaymentResult of the transaction so you can determine if it was a success or failure.

Integrator transaction lookup
1import YocoSDK
2
3YocoSDK.getIntegratorTransactions(receiptNumber: receiptNumber) { (result, error) in
4 // result - collection of PaymentResult, null if no transactions found
5 // or lookup fails.
6 // error - error description string
7}