TransactionOptions
@objc(DTTransactionOptions)
@objcMembers
public final class TransactionOptions : NSObject
This class can be used to specify miscellaneous options related to the transaction.
-
Your unique URL scheme to be used by other apps (e.g. Twint) to return to the merchant app.
Declaration
Swift
public var appCallbackScheme: String? { get set } -
A universal link to be used by other apps (e.g. card issuer app) to return to the merchant app.
Important
The URL must start with https://, custom schemes are not supported for this type of callback.Declaration
Swift
public var appCallbackURL: String? { get set } -
Specify the
ApplePayConfigobject here. This is mandatory for Apple Pay transactions.Declaration
Swift
public var applePayConfig: ApplePayConfig? -
Use this setting to choose which label to display for the card option in the payment method selection: “Credit card”, “Debit card”, or “Credit or debit card”. The latter is used by default.
Declaration
Swift
public var cardLabelType: CardLabelType -
Use this setting to display or hide critical and transaction errors.
Declaration
Swift
public var suppressCriticalErrorDialog: Bool -
In case you use Twint and can’t list all Twint app schemes from “twint-issuer1” to “twint-issuer39” under
LSApplicationQueriesSchemes, use this setting to specify the highest one you do list.The default value is 39. Listing “twint-extended” is always required to use Twint.
Important
ReducingtwintMaxIssuerNumberhas an adverse effect on the user experience.Declaration
Swift
public var twintMaxIssuerNumber: Int -
Sometimes, apps display a loading animation before starting the SDK. You can set the
customInitialLoaderDelegateoption if you want to keep showing this animation instead of the SDK’s loader during initial SDK network requests.Important
Your loader must be visible before starting the SDK. Be aware that the SDK blocks user input. Your loading screen can not have a cancel button or give the impression that users can still interact with the UI.Declaration
Swift
public weak var customInitialLoaderDelegate: InitialLoaderDelegate? -
Option to control when the DCC (Dynamic Currency Conversion) screen is presented for payments with saved cards (alias/tokenized payments). The default is
DCCShowMode.always, meaning DCC is always shown when available. SeeDCCShowModefor additional information.Declaration
Swift
public var savedCardDCCShowMode: DCCShowMode -
Option to automatically perform authorization in the background after a user has authenticated and confirmed a transaction. This is useful when a transaction is confirmed in a third-party app but the user fails to return to your app to finish the process. The transaction is then automatically authorized by the backend and a webhook is sent.
Important
If you use this option, you must implement webhooks. Since transactions are potentially finalized when your app is not visible, you must make sure that users are notified through other means about successful payments. Also, if your app is killed while in the background, it cannot be notified by the SDK about the transaction status. Please make sure to check whether a previously started transaction has been completed while your app was in the background and update your UI accordingly.Declaration
Swift
public var autoAuthorize: Bool
View on GitHub