CustomerPaymentSessionsRepository
public protocol CustomerPaymentSessionsRepository
Undocumented
-
Retrieve a
PaymentSession
by it’s IDDeclaration
Swift
func getBy(paymentSessionId: String, completion: @escaping ApiCompletion<PaymentSession>)
Parameters
paymentSessionId
The payment session ID.
-
Retrieve a
PaymentSession
by a QR code ID associated to the session.Declaration
Swift
func getBy(qrCodeId: String, completion: @escaping ApiCompletion<PaymentSession>)
Parameters
qrCodeId
The QR code ID.
-
Update a
PaymentSession
Declaration
Swift
func update( paymentSessionId: String, session: CustomerUpdatePaymentSessionRequest, completion: @escaping ApiCompletion<Void> )
Parameters
paymentSessionId
The payment session to update
session
The updates to apply to the session
-
Delete a
PaymentSession
Declaration
Swift
func delete(paymentSessionId: String, completion: @escaping ApiCompletion<Void>)
Parameters
paymentSessionId
The payment session to delete
-
preApprove(paymentSessionId:
primaryInstrument: secondaryInstruments: clientReference: preferences: challengeResponses: completion: ) Pre-approve payment for a
PaymentSession
Declaration
Swift
func preApprove( paymentSessionId: String, primaryInstrument: String?, secondaryInstruments: [SecondaryPaymentInstrument]?, clientReference: String?, preferences: PaymentPreferences?, challengeResponses: [ChallengeResponse]?, completion: @escaping ApiCompletion<Void> )
Parameters
paymentSessionId
The
PaymentSession
to pre-approve payment for.primaryInstrument
The primary (or only) instrument to use to make the payment. If not present then the primary instrument from the customer preferences will be used.
secondaryInstruments
Other payment instruments to use to split payment.
clientReference
An optional client reference to be associated with the transaction.
preferences
Optional payment preferences.
challengeResponses
Used when needing to complete challenge(s) to complete payment.