PaymentServiceProtocol
public protocol PaymentServiceProtocol : AnyObject
Undocumented
-
Returns a list of payment providers
Declaration
Swift
func paymentProviders(completion: @escaping CompletionResult<PaymentProviders>)Parameters
completionA completion callback, returning the payment list on success
-
Returns a payment providers
Declaration
Swift
func paymentProvider(id: String, completion: @escaping CompletionResult<PaymentProvider>)Parameters
idThe id of the payment provider
completionA completion callback, returning the payment provider on success
-
createPaymentRequest(sourceDocumentLocation:paymentProvider:recipient:iban:bic:amount:purpose:completion:)Creates a payment request
Declaration
Swift
func createPaymentRequest(sourceDocumentLocation: String?, paymentProvider: String, recipient: String, iban: String, bic: String?, amount: String, purpose: String, completion: @escaping CompletionResult<String>)Parameters
sourceDocumentLocationThe URI of the source document whenever the payment details were extracted by the Gini system beforehand (optional)
paymentProviderThe id of the target payment provider - see payment providers
recipientThe recipient of the payment
ibanThe iban (international bank account number) of the payment recipient
bicThe bic (bank identifier code) for the payment
amountThe amount of the paymentt
purposeThe purpose of the payment, eg. the invoice or the customer identifier
completionA completion callback, returning the payment request on success
-
Returns a payment request
Declaration
Swift
func paymentRequest(id: String, completion: @escaping CompletionResult<PaymentRequest>)Parameters
idThe id of the payment request
completionA completion callback, returning the payment request on success
-
Returns a list of payment requests
Declaration
Swift
func paymentRequests(limit: Int?, offset: Int?, completion: @escaping CompletionResult<PaymentRequests>)Parameters
limitThe maximum number of payment requests to return (default 20), (optional)
offsetA starting offset (default 0), (optional)
completionA completion callback, returning the request list on success
-
Resolves a payment request A payment is sent by a payment provider in order to resolve a payment request after it was paid.
Declaration
Swift
func resolvePaymentRequest(id: String, recipient: String, iban: String, bic: String?, amount: String, purpose: String, completion: @escaping CompletionResult<ResolvedPaymentRequest>)Parameters
recipientThe recipient of the payment
ibanThe iban (international bank account number) of the payment recipient
bicThe bic (bank identifier code) for the payment
amountThe amount of the paymentt
purposeThe purpose of the payment, eg. the invoice or the customer identifier
completionA completion callback, returning the resolved payment request structure on success
-
Returns a payment
Declaration
Swift
func payment(id: String, completion: @escaping CompletionResult<Payment>)Parameters
idThe the payment request’s unique identifier
completionA completion callback, returning the payment on success
View on GitHub
PaymentServiceProtocol Protocol Reference