AlPayments
public final class AlPayments
SDK Initialization object.
-
AlPayments
object instance.Declaration
Swift
public static let shared: AlPayments
-
Creates a card.
Declaration
Swift
public func createCard( token: String, accountUuid: String, data: CardRequest, delegate: PaymentMethodsDelegate)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
data
The data needed for the request.
delegate
The delegate to receive SDK updates.
-
Gets a card.
Declaration
Swift
public func getCard( token: String, accountUuid: String, paymentMethodUuid: String, delegate: PaymentMethodsDelegate)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
paymentMethodUuid
The payment method uuid.
delegate
The delegate to receive SDK updates.
-
Lists cards.
Declaration
Swift
public func listCards( token: String, accountUuid: String, query: CardsQuery? = nil, delegate: PaymentMethodsDelegate)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
query
The query.
delegate
The delegate to receive SDK updates.
-
Deletes a card.
Declaration
Swift
public func deleteCard( token: String, accountUuid: String, paymentMethodUuid: String, delegate: PaymentMethodsDelegate)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
paymentMethodUuid
The payment method uuid.
delegate
The delegate to receive SDK updates.
-
Creates a bank account.
Declaration
Swift
public func createBankAccount( token: String, accountUuid: String, data: BankRequest, delegate: PaymentMethodsDelegate)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
data
The data needed for the request.
delegate
The delegate to receive SDK updates.
-
Creates a plaid bank account.
Declaration
Swift
public func createPlaidBankAccount( token: String, accountUuid: String, data: PlaidBankRequest, delegate: PaymentMethodsDelegate)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
data
The data needed for the request.
delegate
The delegate to receive SDK updates.
-
Activates a plaid bank account.
Declaration
Swift
public func activatePlaidBankAccount( token: String, accountUuid: String, paymentMethodUuid: String, delegate: PaymentMethodsDelegate)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
paymentMethodUuid
The payment method uuid.
delegate
The delegate to receive SDK updates.
-
Gets a bank account.
Declaration
Swift
public func getBankAccount( token: String, accountUuid: String, paymentMethodUuid: String, delegate: PaymentMethodsDelegate)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
paymentMethodUuid
The payment method uuid.
delegate
The delegate to receive SDK updates.
-
Lists bank accounts.
Declaration
Swift
public func listBankAccounts( token: String, accountUuid: String, query: BanksQuery? = nil, delegate: PaymentMethodsDelegate)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
query
The query.
delegate
The delegate to receive SDK updates.
-
Deletes a bank account.
Declaration
Swift
public func deleteBankAccount( token: String, accountUuid: String, paymentMethodUuid: String, delegate: PaymentMethodsDelegate)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
paymentMethodUuid
The payment method uuid.
delegate
The delegate to receive SDK updates.
-
Create and returns a
CreateCardViewController
.Declaration
Swift
public func createCreateCardViewController( token: String, delegate: PaymentMethodsDelegate, extraData: CreateCardExtraData, validation: CardValidation? = nil, style: CreateCardStyle? = nil) -> CreateCardViewController
Parameters
token
The token to authenticate the SDK.
delegate
The delegate to receive SDK updates.
extraData
Extra data to be sent along card data.
validation
A custom fields validation to apply to the view. If
nil
is passed the default validations are applied.style
The style customizations object. If
nil
is passed the default style is applied.Return Value
A
CreateCardViewController
instance. -
Register a
CreateCardViewController
initialized from Interface Builder.Declaration
Swift
public func registerCreateCardViewController( token: String, viewController: CreateCardViewController, delegate: PaymentMethodsDelegate, extraData: CreateCardExtraData, validation: CardValidation? = nil, style: CreateCardStyle? = nil)
Parameters
token
The token to authenticate the SDK.
viewController
The
CreateCardViewController
view controller.delegate
The delegate to receive SDK updates.
extraData
Extra data to be sent along card data.
validation
A custom fields validation to apply to the view. If
nil
is passed the default validations are applied.style
The style customizations object. If
nil
is passed the default style is applied. -
Create and returns a
CreateCardView
.Declaration
Swift
public func createCreateCardView( token: String, delegate: PaymentMethodsDelegate, extraData: CreateCardExtraData, validation: CardValidation? = nil, style: CreateCardStyle? = nil) -> CreateCardView
Parameters
token
The token to authenticate the SDK.
delegate
The delegate to receive SDK updates.
extraData
Extra data to be sent along card data.
validation
A custom fields validation to apply to the view. If
nil
is passed the default validations are applied.style
The style customizations object. If
nil
is passed the default style is applied.Return Value
A
CreateCardView
instance. -
Register a
CreateCardView
initialized from Interface Builder.Declaration
Swift
public func registerCreateCardView( token: String, view: CreateCardView, delegate: PaymentMethodsDelegate, extraData: CreateCardExtraData, validation: CardValidation? = nil, style: CreateCardStyle? = nil)
Parameters
token
The token to authenticate the SDK.
view
The
CreateCardView
view.delegate
The delegate to receive SDK updates.
extraData
Extra data to be sent along card data.
validation
A custom fields validation to apply to the view. If
nil
is passed the default validations are applied.style
The style customizations object. If
nil
is passed the default style is applied.
-
Gets a wallet.
Declaration
Swift
public func getWallet( token: String, accountUuid: String, walletUuid: String, delegate: WalletsDelegate)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
walletUuid
The wallet uuid.
delegate
The delegate to receive SDK updates.
-
Lists wallets.
Declaration
Swift
public func listWallets( token: String, accountUuid: String, query: WalletsQuery? = nil, delegate: WalletsDelegate)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
query
The query.
delegate
The delegate to receive SDK updates.
-
Gets transaction details.
Declaration
Swift
public func getTransactionDetails( token: String, transactionUuid: String, delegate: TransactionsDelegate)
Parameters
token
The token to authenticate the SDK.
transactionUuid
The transaction uuid.
delegate
The delegate to receive SDK updates.
-
Cancel transaction.
Declaration
Swift
public func cancelTransaction( token: String, transactionUuid: String, delegate: TransactionsDelegate)
Parameters
token
The token to authenticate the SDK.
transactionUuid
The transaction uuid.
delegate
The delegate to receive SDK updates.
-
Lists wallet transactions.
Declaration
Swift
public func listWalletTransactions( token: String, walletUuid: String, query: WalletTransactionsQuery? = nil, delegate: WalletsDelegate)
Parameters
token
The token to authenticate the SDK.
walletUuid
The wallet uuid.
query
The query.
delegate
The delegate to receive SDK updates.
-
Lists child transactions.
Declaration
Swift
public func listChildTransactions( token: String, transactionUuid: String, query: ChildTransactionsQuery? = nil, delegate: TransactionsDelegate)
Parameters
token
The token to authenticate the SDK.
transactionUuid
The wallet uuid.
query
The query.
delegate
The delegate to receive SDK updates.
-
Gets a receipt.
Declaration
Swift
public func getReceipt( token: String, transactionUuid: String, delegate: TransactionsDelegate)
Parameters
token
The token to authenticate the SDK.
transactionUuid
The wallet uuid.
delegate
The delegate to receive SDK updates.
-
Loads funds.
Declaration
Swift
public func loadFunds( token: String, walletUuid: String, data: LoadFundsRequest, delegate: WalletsDelegate)
Parameters
token
The token to authenticate the SDK.
walletUuid
The wallet uuid.
data
The data needed for the request.
delegate
The delegate to receive SDK updates.
-
Withdraws funds.
Declaration
Swift
public func withdrawFunds( token: String, walletUuid: String, data: WithdrawFundsRequest, delegate: WalletsDelegate)
Parameters
token
The token to authenticate the SDK.
walletUuid
The wallet uuid.
data
The data needed for the request.
delegate
The delegate to receive SDK updates.
-
Send funds.
Declaration
Swift
public func sendFunds( token: String, walletUuid: String, data: SendFundsRequest, delegate: WalletsDelegate)
Parameters
token
The token to authenticate the SDK.
walletUuid
The wallet uuid.
data
The data needed for the request.
delegate
The delegate to receive SDK updates.
-
Send funds.
Declaration
Swift
public func transferFunds( token: String, walletUuid: String, data: TransferFundsRequest, delegate: WalletsDelegate)
Parameters
token
The token to authenticate the SDK.
walletUuid
The wallet uuid.
data
The data needed for the request.
delegate
The delegate to receive SDK updates.
-
Deposits a check.
Declaration
Swift
public func depositCheck( token: String, walletUuid: String, data: DepositCheckRequest, delegate: CheckDepositsDelegate)
Parameters
token
The token to authenticate the SDK
walletUuid
The wallet identifier.
data
The data needed for the request.
delegate
The delegate to receive SDK updates.
-
Gets a check.
Declaration
Swift
public func getCheck( token: String, walletUuid: String, checkUuid: String, delegate: CheckDepositsDelegate)
Parameters
token
The token to authenticate the SDK
walletUuid
The wallet identifier.
checkUuid
The check identifier.
delegate
The delegate to receive SDK updates.
-
Lists checks.
Declaration
Swift
public func listChecks( token: String, walletUuid: String, query: ChecksQuery? = nil, delegate: CheckDepositsDelegate)
Parameters
token
The token to authenticate the SDK
walletUuid
The wallet identifier.
query
The query.
delegate
The delegate to receive SDK updates.
-
Register a
DepositCheckViewController
initialized from Interface Builder.Declaration
Swift
public func registerCheckDepositViewController( token: String, cameraToken: String, viewController: DepositCheckViewController, data: DepositCheckRequest, extraData: DepositCheckExtraData, delegate: CheckDepositsDelegate, style: DepositCheckStyle? = nil)
Parameters
token
The token to authenticate the SDK.
cameraToken
The token to authenticate the Camera SDK.
viewController
The
DepositCheckViewController
view controller.data
Data model to setup check capture.
delegate
The delegate to receive SDK updates.
style
The style customizations object.
-
Create and returns a
DepositCheckViewController
.Declaration
Swift
public func createCheckDepositViewController( token: String, cameraToken: String, data: DepositCheckRequest, extraData: DepositCheckExtraData, delegate: CheckDepositsDelegate, style: DepositCheckStyle? = nil) -> DepositCheckViewController
Parameters
token
The token to authenticate the SDK.
cameraToken
The token to authenticate the Camera SDK.
data
Data model to setup check capture.
delegate
The delegate to receive SDK updates.
style
The style customizations object.
Return Value
A
DepositCheckViewController
instance. -
Register a
DepositCheckViewController
initialized from Interface Builder.Declaration
Swift
public func registerCaptureCheckDepositViewController( cameraToken: String, viewController: DepositCheckViewController, delegate: CheckDepositsCaptureDelegate, style: DepositCheckStyle? = nil)
Parameters
cameraToken
The token to authenticate the Camera SDK.
viewController
The
DepositCheckViewController
view controller.delegate
The delegate to receive SDK updates.
style
The style customizations object.
-
Create and returns a
DepositCheckViewController
.Declaration
Swift
public func createCaptureCheckDepositViewController( cameraToken: String, delegate: CheckDepositsCaptureDelegate, style: DepositCheckStyle? = nil) -> DepositCheckViewController
Parameters
cameraToken
The token to authenticate the Camera SDK.
delegate
The delegate to receive SDK updates.
style
The style customizations object.
Return Value
A
DepositCheckViewController
instance. -
Combine bindings.
See moreDeclaration
Swift
public class Async
-
Creates a card.
Declaration
Swift
func createCard( token: String, accountUuid: String, data: CardRequest, completion: @escaping (Result<(card: Card, validation: CardValidationResult), EventError>) -> Void)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
data
The data needed for the request.
completion
Called when the call was completed.
-
Gets a card.
Declaration
Swift
func getCard( token: String, accountUuid: String, paymentMethodUuid: String, completion: @escaping (Result<Card, EventError>) -> Void)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
paymentMethodUuid
The payment method uuid.
completion
Called when the call was completed.
-
Lists cards.
Declaration
Swift
func listCards( token: String, accountUuid: String, query: CardsQuery? = nil, completion: @escaping (Result<[Card], EventError>) -> Void)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
query
The query.
completion
Called when the call was completed.
-
Deletes a card.
Declaration
Swift
func deleteCard( token: String, accountUuid: String, paymentMethodUuid: String, completion: @escaping (Result<Bool, EventError>) -> Void)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
paymentMethodUuid
The payment method uuid.
completion
Called when the call was completed.
-
Creates a bank account.
Declaration
Swift
func createBankAccount( token: String, accountUuid: String, data: BankRequest, completion: @escaping (Result<Bank, EventError>) -> Void)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
data
The data needed for the request.
completion
Called when the call was completed.
-
Creates a plaid bank account.
Declaration
Swift
func createPlaidBankAccount( token: String, accountUuid: String, data: PlaidBankRequest, completion: @escaping (Result<Bank, EventError>) -> Void)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
data
The data needed for the request.
completion
Called when the call was completed.
-
Activates a plaid bank account.
Declaration
Swift
func activatePlaidBankAccount( token: String, accountUuid: String, paymentMethodUuid: String, completion: @escaping (Result<Bool, EventError>) -> Void)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
paymentMethodUuid
The payment method uuid.
completion
Called when the call was completed.
-
Gets a bank account.
Declaration
Swift
func getBankAccount( token: String, accountUuid: String, paymentMethodUuid: String, completion: @escaping (Result<Bank, EventError>) -> Void)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
paymentMethodUuid
The payment method uuid.
completion
Called when the call was completed.
-
Lists bank accounts.
Declaration
Swift
func listBankAccounts( token: String, accountUuid: String, query: BanksQuery? = nil, completion: @escaping (Result<[Bank], EventError>) -> Void)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
query
The query.
completion
Called when the call was completed.
-
Deletes a bank account.
Declaration
Swift
func deleteBankAccount( token: String, accountUuid: String, paymentMethodUuid: String, completion: @escaping (Result<Bool, EventError>) -> Void)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
paymentMethodUuid
The payment method uuid.
completion
Called when the call was completed.
-
Gets a wallet.
Declaration
Swift
func getWallet( token: String, accountUuid: String, walletUuid: String, completion: @escaping (Result<Wallet, EventError>) -> Void)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
walletUuid
The wallet uuid.
completion
Called when the call was completed.
-
Lists wallets.
Declaration
Swift
func listWallets( token: String, accountUuid: String, query: WalletsQuery? = nil, completion: @escaping (Result<[Wallet], EventError>) -> Void)
Parameters
token
The token to authenticate the SDK.
accountUuid
The account uuid.
query
The query.
completion
Called when the call was completed.
-
Gets transaction details.
Declaration
Swift
func getTransactionDetails( token: String, transactionUuid: String, completion: @escaping (Result<Transaction, EventError>) -> Void)
Parameters
token
The token to authenticate the SDK.
transactionUuid
The transaction uuid.
completion
Called when the call was completed.
-
Cancel transaction.
Declaration
Swift
func cancelTransaction( token: String, transactionUuid: String, completion: @escaping (Result<Bool, EventError>) -> Void)
Parameters
token
The token to authenticate the SDK.
transactionUuid
The transaction uuid.
completion
Called when the call was completed.
-
Lists wallet transactions.
Declaration
Swift
func listWalletTransactions( token: String, walletUuid: String, query: WalletTransactionsQuery? = nil, completion: @escaping (Result<[Transaction], EventError>) -> Void)
Parameters
token
The token to authenticate the SDK.
walletUuid
The wallet uuid.
query
The query.
completion
Called when the call was completed.
-
Lists child transactions.
Declaration
Swift
func listChildTransactions( token: String, transactionUuid: String, query: ChildTransactionsQuery? = nil, completion: @escaping (Result<[Transaction], EventError>) -> Void)
Parameters
token
The token to authenticate the SDK.
transactionUuid
The wallet uuid.
query
The query.
completion
Called when the call was completed.
-
Gets a receipt.
Declaration
Swift
func getReceipt( token: String, transactionUuid: String, completion: @escaping (Result<Receipt, EventError>) -> Void)
Parameters
token
The token to authenticate the SDK.
transactionUuid
The wallet uuid.
completion
Called when the call was completed.
-
Loads funds.
Declaration
Swift
func loadFunds( token: String, walletUuid: String, data: LoadFundsRequest, completion: @escaping (Result<Transaction, EventError>) -> Void)
Parameters
token
The token to authenticate the SDK.
walletUuid
The wallet uuid.
data
The data needed for the request.
completion
Called when the call was completed.
-
Withdraws funds.
Declaration
Swift
func withdrawFunds( token: String, walletUuid: String, data: WithdrawFundsRequest, completion: @escaping (Result<Transaction, EventError>) -> Void)
Parameters
token
The token to authenticate the SDK.
walletUuid
The wallet uuid.
data
The data needed for the request.
completion
Called when the call was completed.
-
Sends funds.
Declaration
Swift
func sendFunds( token: String, walletUuid: String, data: SendFundsRequest, completion: @escaping (Result<Transaction, EventError>) -> Void)
Parameters
token
The token to authenticate the SDK.
walletUuid
The wallet uuid.
data
The data needed for the request.
completion
Called when the call was completed.
-
Transfer funds.
Declaration
Swift
func transferFunds( token: String, walletUuid: String, data: TransferFundsRequest, completion: @escaping (Result<Transaction, EventError>) -> Void)
Parameters
token
The token to authenticate the SDK.
walletUuid
The wallet uuid.
data
The data needed for the request.
completion
Called when the call was completed.
-
Deposits a check.
Declaration
Swift
func depositCheck( token: String, walletUuid: String, data: DepositCheckRequest, completion: @escaping (Result<Check, EventError>) -> Void)
Parameters
token
The token to authenticate the SDK
walletUuid
The wallet identifier.
data
The data needed for the request.
completion
Called when the call was completed.
-
Gets a check.
Declaration
Swift
func getCheck( token: String, walletUuid: String, checkUuid: String, completion: @escaping (Result<Check, EventError>) -> Void)
Parameters
token
The token to authenticate the SDK.
walletUuid
The wallet uuid.
checkUuid
The check identifier.
completion
Called when the call was completed.
-
Lists checks.
Declaration
Swift
func listChecks( token: String, walletUuid: String, query: ChecksQuery? = nil, completion: @escaping (Result<[Check], EventError>) -> Void)
Parameters
token
The token to authenticate the SDK.
checkUuid
The check identifier.
query
The query.
completion
Called when the call was completed.
-
Combine bindings.
See moreDeclaration
Swift
public class Futures