STPPaymentMethodCardParams
public class STPPaymentMethodCardParams : NSObject, STPFormEncodable
The user’s card details.
-
Declaration
Swift
@objc public var additionalAPIParameters: [AnyHashable : Any]
-
A convenience initializer for creating a payment method from a card source. This should be used to help with migrations to Payment Methods from Sources.
Declaration
Swift
@objc public convenience init(cardSourceParams: STPCardParams)
-
Initializes an empty STPPaymentMethodCardParams.
Declaration
Swift
public required override init()
-
The card number, as a string without any separators. Ex. @“4242424242424242”
Declaration
Swift
@objc public var number: String?
-
Number representing the card’s expiration month. Ex. @1
Declaration
Swift
@objc public var expMonth: NSNumber?
-
Two- or four-digit number representing the card’s expiration year.
Declaration
Swift
@objc public var expYear: NSNumber?
-
For backwards compatibility, you can alternatively set this as a Stripe token (e.g., for apple pay)
Declaration
Swift
@objc public var token: String?
-
Card security code. It is highly recommended to always include this value.
Declaration
Swift
@objc public var cvc: String?
-
The last 4 digits of the card.
Declaration
Swift
@objc public var last4: String? { get }
-
Declaration
Swift
@objc public class func rootObjectName() -> String?
-
Declaration
Swift
@objc public class func propertyNamesToFormFieldNamesMapping() -> [String : String]