PayService

class PayService(apiKey: String, client: OkHttpClient, backendUrl: String) : ServiceBase

Constructors

PayService
Link copied to clipboard
fun PayService(apiKey: String)
PayService
Link copied to clipboard
fun PayService(apiKey: String, backendUrl: String)
PayService
Link copied to clipboard
fun PayService(apiKey: String, client: OkHttpClient)

Functions

create
Link copied to clipboard
fun create(body: Xs2aPay): WizardSessionResponse
Create xs2a.pay object Create a xs2a.pay object and receive Wizard session key in return.
delete
Link copied to clipboard
fun delete(transactionId: String): String
Delete a xs2a.pay transaction object Transaction data also can be deleted manually by sending a DELETE request for that transaction.
generatePainFile
Link copied to clipboard
fun generatePainFile(body: RefundPayoutRequest): RefundPayoutResponse
Generates a pain file.
get
Link copied to clipboard
fun get(transactionId: String): PayObject
Get a xs2a.pay object Here you can retrieve a specific xs2a.pay object by its `transaction-id`.
getEvents
Link copied to clipboard
fun getEvents(transactionId: String, perPage: Int = 15, page: Int = 1): EventObjectList
Get all events for a xs2a.
getPainFile
Link copied to clipboard
fun getPainFile(messageId: String): BufferedSource
Get a pain file.
getRefundPayout
Link copied to clipboard
fun getRefundPayout(transactionId: String): RefundsPayout
Get a refund Payout of transaction.
getReport
Link copied to clipboard
fun getReport(transactionId: String, reportId: String, format: ReportFormat = ReportFormat.JSON, locale: ReportLocale = ReportLocale.EN): Any
Download a Report
list
Link copied to clipboard
fun list(senderHolder: String? = null, senderIban: String? = null, senderBic: String? = null, senderAccountNumber: String? = null, senderBankCode: String? = null, senderCountryId: String? = null, recipientHolder: String? = null, recipientIban: String? = null, recipientBic: String? = null, recipientCountryId: String? = null, amount: Float? = null, purpose: String? = null, perPage: Int? = null, page: Int? = null, from: OffsetDateTime? = null, to: OffsetDateTime? = null): PayObjectList
Get a list of all xs2a.pay transaction objects Get a list of all xs2a.pay transactions, or filter using query parameters.
listRefundPayouts
Link copied to clipboard
fun listRefundPayouts(perPage: Int = 15, page: Int = 1): RefundPayoutObjectList
Get a list of all refund and payout with their message_id.
updatePaymentStatus
Link copied to clipboard
fun updatePaymentStatus(transactionId: String, statusToSet: PaymentStatus): PayObject
Change the payment status of a transaction