STPBankAccountCollector
public class STPBankAccountCollector : NSObject
A class responsible for collecting bank account information
-
By default
sharedHandler
initializes with STPAPIClient.shared.Declaration
Swift
public var apiClient: STPAPIClient
-
By default
sharedHandler
initializes with STPAPIClient.shared.Declaration
Swift
@available(swift, deprecated: 0.0.1, renamed: "apiClient") @objc(apiClient) public var _objc_apiClient: _stpobjc_STPAPIClient { get set }
-
Presents a modal from the viewController to collect bank account and if completed successfully, link your bank account to a PaymentIntent
Declaration
Swift
@available(iOS 12, *) @objc(collectBankAccountForPaymentWithClientSecret:params:from:completion:) public func collectBankAccountForPayment(clientSecret: String, params: STPCollectBankAccountParams, from viewController: UIViewController, completion: @escaping STPCollectBankAccountForPaymentCompletionBlock)
Parameters
clientSecret
Client secret of the payment intent
params
Parameters for this call
viewController
Presenting view controller that will present the modal
completion
Completion block to be called on completion of the operation. Upon success, the
STPPaymentIntent
instance will have an expandedpaymentMethod
containing detailed payment method information
-
Presents a modal from the viewController to collect bank account and if completed successfully, link your bank account to a SetupIntent
Declaration
Swift
@available(iOS 12, *) @objc(collectBankAccountForSetupWithClientSecret:params:from:completion:) public func collectBankAccountForSetup(clientSecret: String, params: STPCollectBankAccountParams, from viewController: UIViewController, completion: @escaping STPCollectBankAccountForSetupCompletionBlock)
Parameters
clientSecret
Client secret of the setup intent
params
Parameters for this call
viewController
Presenting view controller that will present the modal
completion
Completion block to be called on completion of the operation. Upon success, the
STPSetupIntent
instance will have an expandedpaymentMethod
containing detailed payment method information