Blocks
- 
                  
                  
A block called with a connection token or an error from your backend.
See
SCPConnectionTokenProvider
Declaration
Objective-C
typedef void (^SCPConnectionTokenCompletionBlock)(NSString *_Nullable, NSError *_Nullable)Swift
typealias ConnectionTokenCompletionBlock = (String?, Error?) -> VoidParameters
tokenThe connection token from your backend server.
errorAn error if one occurred, or nil.
 - 
                  
                  
A block called with an optional error.
Declaration
Objective-C
typedef void (^SCPErrorCompletionBlock)(NSError *_Nullable)Swift
typealias ErrorCompletionBlock = (Error?) -> VoidParameters
errorThe error, or nil if no error occured.
 - 
                  
                  
A block called with a logline from the SDK.
Declaration
Objective-C
typedef void (^SCPLogListenerBlock)(NSString *_Nonnull)Swift
typealias LogListenerBlock = (String) -> VoidParameters
loglineAn internal logline from the SDK.
 - 
                  
                  
A block called with a PaymentIntent or an error.
Declaration
Objective-C
typedef void (^SCPPaymentIntentCompletionBlock)(SCPPaymentIntent *_Nullable, NSError *_Nullable)Swift
typealias PaymentIntentCompletionBlock = (SCPPaymentIntent?, Error?) -> VoidParameters
intentThe PaymentIntent, or nil.
errorAn error if one occurred, or nil.
 - 
                  
                  
A block called with a PaymentMethod.
Declaration
Objective-C
typedef void (^SCPPaymentMethodCompletionBlock)(SCPPaymentMethod *_Nullable, NSError *_Nullable)Swift
typealias PaymentMethodCompletionBlock = (SCPPaymentMethod?, Error?) -> VoidParameters
paymentMethodA PaymentMethod object, or nil if an error occurred.
errorAn error if one occurred, or nil.
 - 
                  
                  
A block called with a PaymentIntent or a ProcessPaymentError
Declaration
Objective-C
typedef void (^SCPProcessPaymentCompletionBlock)( SCPPaymentIntent *_Nullable, SCPProcessPaymentError *_Nullable)Swift
typealias ProcessPaymentCompletionBlock = (SCPPaymentIntent?, SCPProcessPaymentError?) -> VoidParameters
intentThe PaymentIntent, or nil.
errorAn error if one occurred, or nil.
 - 
                  
                  
A block called with a reader object or an error.
Declaration
Objective-C
typedef void (^SCPReaderCompletionBlock)(SCPReader *_Nullable, NSError *_Nullable)Swift
typealias ReaderCompletionBlock = (SCPReader?, Error?) -> VoidParameters
readerA reader object, or nil.
errorAn error if one occurred, or nil.
 - 
                  
                  
A block called with a Refund or a ProcessRefundError.
Declaration
Objective-C
typedef void (^SCPProcessRefundCompletionBlock)( SCPRefund *_Nullable, SCPProcessRefundError *_Nullable)Swift
typealias ProcessRefundCompletionBlock = (SCPRefund?, SCPProcessRefundError?) -> VoidParameters
refundThe Refund, or nil.
errorAn error if one occurred, or nil.
 - 
                  
                  
A block called with a SetupIntent or a ConfirmSetupIntentError.
Declaration
Objective-C
typedef void (^SCPConfirmSetupIntentCompletionBlock)( SCPSetupIntent *_Nullable, SCPConfirmSetupIntentError *_Nullable)Swift
typealias ConfirmSetupIntentCompletionBlock = (SCPSetupIntent?, SCPConfirmSetupIntentError?) -> VoidParameters
intentThe SetupIntent, or nil.
errorAn error if one occurred, or nil.
 - 
                  
                  
A block called with a list of Locations or an error.
Declaration
Objective-C
typedef void (^SCPLocationsCompletionBlock)(NSArray<SCPLocation *> *_Nullable, BOOL, NSError *_Nullable)Swift
typealias LocationsCompletionBlock = ([SCPLocation]?, Bool, Error?) -> VoidParameters
locationsA list of Locations, or nil.
hasMoreIndicates whether there are more locations for the account; use the pagination parameters in SCPListLocationsParameters to fetch more locations
errorAn error if one occurred, or nil.
 - 
                  
                  
A block called with a SetupIntent or an error.
Declaration
Objective-C
typedef void (^SCPSetupIntentCompletionBlock)(SCPSetupIntent *_Nullable, NSError *_Nullable)Swift
typealias SetupIntentCompletionBlock = (SCPSetupIntent?, Error?) -> VoidParameters
intentThe SetupIntent, or nil.
errorAn error if one occurred, or nil.
 
      Blocks  Reference