Merchant iOS SDKs
Parameters
doc

Revolut Reader iOS SDK parameters

This page contains information about the available parameters for the Revolut Reader iOS SDK. For detailed instructions on how to integrate the SDK, see the Revolut Reader guides.

How to integrate the Revolut Reader iOS SDK

  1. Create an account, install and configure the SDK in your Xcode project. For more information, see: Revolut Reader guides: Get started.
  2. Create a RevolutReaderKit object. It provides all the necessary tools for initialising the SDK and authenticating users. For more information, see: Revolut Reader guides: Initialise the SDK.
  3. Integrate further functionalities of the SDK, to support payment processing and different UI flows.

Configuration

RevolutCardReaderKit.shared.initialise(
clientId: "<clientId>",
returnURL: "<returnURL>",
environment: .production
)

RevolutCardReaderKit.initialise method:

ParameterDescriptionFormatRequired
clientIdThe unique identifier of the client application obtained from the Revolut Developer Portal.StringYes
returnURLThe URL of your app being opened upon payment completion.StringYes
environmentThe environment used by the RevolutCardReaderKit.

Possible values:
  • .production

note
Currently, only .production environment is available on the RevolutCardReaderKit.
EnumYes

Options

Profile flow options

RevolutCardReaderKit.shared.startProfileFlow(
onResult handleResult: { result in
// This closure is where you handle the result of the profile flow.
// Depending on the result, you might update the UI, log events, or handle errors.
}
)

RevolutCardReaderKit.startProfileFlow method:

ParameterDescriptionTypeRequired
onResultThis closure is a callback function executed when the payment operation is completed. The result parameter within this closure represents the outcome of the payment process. This callback is crucial for handling the result of the payment request.
note
For more information on what is returned in the callback, see: Error codes.
ClosureYes

Payment flow options

let paymentDefinition = PaymentDefinition(
money: Money(
amount: 15_00,
currency: .GBP
),
description: "My first transaction",
locationId: "8d9a7125-805f-40f3-a405-bc89765db996"
)

RevolutCardReaderKit.shared.startPaymentFlow(
definition: paymentDefinition,
onResult: { result in
// This closure is where you handle the result of the payment flow.
// Depending on the result, you might update the UI, log events, or handle errors.
}
)

PaymentDefinition parameters:

ParameterDescriptionTypeRequired
moneyAn instance of Money containing amount and currency information.ClassYes
descriptionThe description of the payment.StringNo
locationIdThe unique identifier of your store's location associated with the payment.StringNo

Money object:

ParameterDescriptionTypeRequired
amountThe amount to be paid by the customer, given in minor currency unit following the ISO 4217 standard. For example, €70.34 is represented by the value 70_34.Int64Yes
currencyThe payment currency in ISO 4217 format.

Possible values
  • .AUD
  • .CAD
  • .CHF
  • .DKK
  • .EUR
  • .GBP
  • .HKD
  • .JPY
  • .NOK
  • .NZD
  • .PLN
  • .USD
  • .ZAR
  • .HUF
  • .RON
caution
Specifying an unsupported currency will return an error.
EnumYes

RevolutCardReaderKit.startPaymentFlow method:

ParameterDescriptionTypeRequired
definitionThe parameter refers to an instance of PaymentDefinition, which encapsulates all the necessary information required to process a payment.ClassYes
onResultThis closure is a callback function executed when the payment operation is completed. The result parameter within this closure represents the outcome of the payment process. This callback is crucial for handling the result of the payment request.
note
For more information on what is returned in the callback, see: Error codes.
ClosureYes

Refund flow options

let refundDefinition = RefundDefinition(
money: Money(
amount: 15_00,
currency: .GBP
),
description: "Refund for a macchiato",
paymentId: "<paymentId>"
)

RevolutCardReaderKit.shared.refund(
definition: refundDefinition,
onResult: { result in
// Handle the result of the refund process
// This could include updating the user interface, logging the refund, or handling errors
}
)

RefundDefinition parameters:

ParameterDescriptionTypeRequired
moneyAn instance of Money containing amount and currency information.ClassYes
descriptionThe description of the refund.StringNo
paymentIdThe unique identifier of the payment that is being refunded.StringYes

Money object:

ParameterDescriptionTypeRequired
amountThe amount to be refunded to the customer, given in minor currency unit following the ISO 4217 standard. For example, €70.34 is represented by the value 70_34.Int64Yes
currencyThe refund currency in ISO 4217 format.

Possible values
  • .AUD
  • .CAD
  • .CHF
  • .DKK
  • .EUR
  • .GBP
  • .HKD
  • .JPY
  • .NOK
  • .NZD
  • .PLN
  • .USD
  • .ZAR
  • .HUF
  • .RON
caution
Specifying an unsupported currency will return an error.
EnumYes

RevolutCardReaderKit.refund method:

ParameterDescriptionTypeRequired
definitionThe parameter refers to an instance of RefundDefinition, which encapsulates all the necessary information required to process a refund.ClassYes
onResultThis closure is a callback function executed when the refund operation is completed. The result parameter within this closure represents the outcome of the refund process. This callback is crucial for handling the result of the refund request.
note
For more information on what is returned in the callback, see: Error codes.
ClosureYes
Was this page helpful?