소스 검색

pod stripe

Abel 1 년 전
부모
커밋
7e8735b842
100개의 변경된 파일40674개의 추가작업 그리고 29172개의 파일을 삭제
  1. 34178 29172
      Pods/Pods.xcodeproj/project.pbxproj
  2. 21 0
      Pods/StripeApplePay/LICENSE
  3. 154 0
      Pods/StripeApplePay/README.md
  4. 44 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/ApplePayContext/STPAPIClient+ApplePay.swift
  5. 55 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/ApplePayContext/STPApplePayContext+LegacySupport.swift
  6. 761 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/ApplePayContext/STPApplePayContext.swift
  7. 18 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/Blocks.swift
  8. 101 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/Extensions/BillingDetails+ApplePay.swift
  9. 26 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/Extensions/PKContact+Stripe.swift
  10. 32 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/Extensions/PKPayment+Stripe.swift
  11. 43 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Models/Address.swift
  12. 67 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Models/BillingDetails.swift
  13. 33 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Models/CardBrand.swift
  14. 149 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Models/PaymentIntent.swift
  15. 101 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Models/PaymentIntentParams.swift
  16. 176 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Models/PaymentMethod.swift
  17. 73 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Models/PaymentMethodParams.swift
  18. 58 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Models/SetupIntent.swift
  19. 66 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Models/SetupIntentParams.swift
  20. 93 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Models/ShippingDetails.swift
  21. 130 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Models/Token.swift
  22. 85 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/PaymentIntent+API.swift
  23. 61 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/PaymentMethod+API.swift
  24. 84 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/SetupIntent+API.swift
  25. 92 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Token+API.swift
  26. 28 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/Analytics/STPAnalyticsClient+Payments.swift
  27. 72 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/Analytics/STPAnalyticsClient+PaymentsAPI.swift
  28. 20 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/Categories/STPAPIClient+PaymentsCore.swift
  29. 10 0
      Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/StripeCore+Import.swift
  30. 21 0
      Pods/StripeCore/LICENSE
  31. 154 0
      Pods/StripeCore/README.md
  32. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/bg-BG.lproj/Localizable.strings
  33. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/ca-ES.lproj/Localizable.strings
  34. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/cs-CZ.lproj/Localizable.strings
  35. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/da.lproj/Localizable.strings
  36. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/de.lproj/Localizable.strings
  37. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/el-GR.lproj/Localizable.strings
  38. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/en-GB.lproj/Localizable.strings
  39. 48 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/en.lproj/Localizable.strings
  40. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/es-419.lproj/Localizable.strings
  41. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/es.lproj/Localizable.strings
  42. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/et-EE.lproj/Localizable.strings
  43. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/fi.lproj/Localizable.strings
  44. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/fil.lproj/Localizable.strings
  45. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/fr-CA.lproj/Localizable.strings
  46. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/fr.lproj/Localizable.strings
  47. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/hr.lproj/Localizable.strings
  48. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/hu.lproj/Localizable.strings
  49. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/id.lproj/Localizable.strings
  50. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/it.lproj/Localizable.strings
  51. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/ja.lproj/Localizable.strings
  52. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/ko.lproj/Localizable.strings
  53. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/lt-LT.lproj/Localizable.strings
  54. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/lv-LV.lproj/Localizable.strings
  55. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/ms-MY.lproj/Localizable.strings
  56. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/mt.lproj/Localizable.strings
  57. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/nb.lproj/Localizable.strings
  58. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/nl.lproj/Localizable.strings
  59. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/nn-NO.lproj/Localizable.strings
  60. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/pl-PL.lproj/Localizable.strings
  61. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/pt-BR.lproj/Localizable.strings
  62. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/pt-PT.lproj/Localizable.strings
  63. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/ro-RO.lproj/Localizable.strings
  64. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/ru.lproj/Localizable.strings
  65. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/sk-SK.lproj/Localizable.strings
  66. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/sl-SI.lproj/Localizable.strings
  67. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/sv.lproj/Localizable.strings
  68. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/tr.lproj/Localizable.strings
  69. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/vi.lproj/Localizable.strings
  70. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/zh-HK.lproj/Localizable.strings
  71. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/zh-Hans.lproj/Localizable.strings
  72. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/zh-Hant.lproj/Localizable.strings
  73. 14 0
      Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/Models/EmptyResponse.swift
  74. 45 0
      Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/Models/StripeFile.swift
  75. 234 0
      Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/STPAPIClient+FileUpload.swift
  76. 545 0
      Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/STPAPIClient.swift
  77. 45 0
      Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/STPAppInfo.swift
  78. 38 0
      Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/STPMultipartFormDataEncoder.swift
  79. 63 0
      Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/STPMultipartFormDataPart.swift
  80. 174 0
      Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/StripeAPI.swift
  81. 19 0
      Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/StripeAPIConfiguration+Version.swift
  82. 16 0
      Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/StripeAPIConfiguration.swift
  83. 80 0
      Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/StripeError.swift
  84. 73 0
      Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/StripeServiceError.swift
  85. 37 0
      Pods/StripeCore/StripeCore/StripeCore/Source/Analytics/Analytic.swift
  86. 52 0
      Pods/StripeCore/StripeCore/StripeCore/Source/Analytics/AnalyticLoggableError.swift
  87. 153 0
      Pods/StripeCore/StripeCore/StripeCore/Source/Analytics/AnalyticsClientV2.swift
  88. 54 0
      Pods/StripeCore/StripeCore/StripeCore/Source/Analytics/NetworkDetector.swift
  89. 47 0
      Pods/StripeCore/StripeCore/StripeCore/Source/Analytics/PluginDetector.swift
  90. 175 0
      Pods/StripeCore/StripeCore/StripeCore/Source/Analytics/STPAnalyticEvent.swift
  91. 153 0
      Pods/StripeCore/StripeCore/StripeCore/Source/Analytics/STPAnalyticsClient.swift
  92. 15 0
      Pods/StripeCore/StripeCore/StripeCore/Source/Categories/Decimal+StripeCore.swift
  93. 82 0
      Pods/StripeCore/StripeCore/StripeCore/Source/Categories/Dictionary+Stripe.swift
  94. 29 0
      Pods/StripeCore/StripeCore/StripeCore/Source/Categories/Enums+CustomStringConvertible.swift
  95. 31 0
      Pods/StripeCore/StripeCore/StripeCore/Source/Categories/NSArray+Stripe.swift
  96. 32 0
      Pods/StripeCore/StripeCore/StripeCore/Source/Categories/NSBundle+Stripe_AppName.swift
  97. 21 0
      Pods/StripeCore/StripeCore/StripeCore/Source/Categories/NSCharacterSet+StripeCore.swift
  98. 135 0
      Pods/StripeCore/StripeCore/StripeCore/Source/Categories/NSError+Stripe.swift
  99. 18 0
      Pods/StripeCore/StripeCore/StripeCore/Source/Categories/NSError+StripeCore.swift
  100. 0 0
      Pods/StripeCore/StripeCore/StripeCore/Source/Categories/NSMutableURLRequest+Stripe.swift

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 34178 - 29172
Pods/Pods.xcodeproj/project.pbxproj


+ 21 - 0
Pods/StripeApplePay/LICENSE

@@ -0,0 +1,21 @@
+The MIT License
+
+Copyright (c) 2011- Stripe, Inc. (https://stripe.com)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 154 - 0
Pods/StripeApplePay/README.md


+ 44 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/ApplePayContext/STPAPIClient+ApplePay.swift

@@ -0,0 +1,44 @@
+//
+//  STPAPIClient+ApplePay.swift
+//  StripeApplePay
+//
+//  Created by Jack Flintermann on 12/19/14.
+//  Copyright © 2014 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+import PassKit
+@_spi(STP) import StripeCore
+
+/// STPAPIClient extensions to create Stripe Tokens, Sources, or PaymentMethods from Apple Pay PKPayment objects.
+extension STPAPIClient {
+    /// Converts Stripe errors into the appropriate Apple Pay error, for use in `PKPaymentAuthorizationResult`.
+    /// If the error can be fixed by the customer within the Apple Pay sheet, we return an NSError that can be displayed in the Apple Pay sheet.
+    /// Otherwise, the original error is returned, resulting in the Apple Pay sheet being dismissed. You should display the error message to the customer afterwards.
+    /// Currently, we convert billing address related errors into a PKPaymentError that helpfully points to the billing address field in the Apple Pay sheet.
+    /// Note that Apple Pay should prevent most card errors (e.g. invalid CVC, expired cards) when you add a card to the wallet.
+    /// - Parameter stripeError:   An error from the Stripe SDK.
+    @objc(pkPaymentErrorForStripeError:)
+    public class func pkPaymentError(forStripeError stripeError: Error?) -> Error? {
+        guard let stripeError = stripeError else {
+            return nil
+        }
+
+        if (stripeError as NSError).domain == STPError.stripeDomain
+            && ((stripeError as NSError).userInfo[STPError.cardErrorCodeKey] as? String
+                == STPCardErrorCode.incorrectZip.rawValue)
+        {
+            var userInfo = (stripeError as NSError).userInfo
+            var errorCode: PKPaymentError.Code = .unknownError
+            errorCode = .billingContactInvalidError
+            userInfo[PKPaymentErrorKey.postalAddressUserInfoKey.rawValue] =
+                CNPostalAddressPostalCodeKey
+            return NSError(
+                domain: STPError.stripeDomain,
+                code: errorCode.rawValue,
+                userInfo: userInfo
+            )
+        }
+        return stripeError
+    }
+}

+ 55 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/ApplePayContext/STPApplePayContext+LegacySupport.swift

@@ -0,0 +1,55 @@
+//
+//  STPApplePayContext+LegacySupport.swift
+//  StripeApplePay
+//
+//  Created by David Estes on 1/25/22.
+//  Copyright © 2022 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+import PassKit
+
+/// Internal Apple Pay class. Do not use.
+/// :nodoc:
+@objc @_spi(STP) public class _stpinternal_ApplePayContextDidCreatePaymentMethodStorage: NSObject {
+    @_spi(STP) public weak var delegate: _stpinternal_STPApplePayContextDelegateBase?
+    @_spi(STP) public var context: STPApplePayContext
+    @_spi(STP) public var paymentMethod: StripeAPI.PaymentMethod
+    @_spi(STP) public var paymentInformation: PKPayment
+    @_spi(STP) public var completion: STPIntentClientSecretCompletionBlock
+
+    @_spi(STP) public init(
+        delegate: _stpinternal_STPApplePayContextDelegateBase,
+        context: STPApplePayContext,
+        paymentMethod: StripeAPI.PaymentMethod,
+        paymentInformation: PKPayment,
+        completion: @escaping STPIntentClientSecretCompletionBlock
+    ) {
+        self.delegate = delegate
+        self.context = context
+        self.paymentMethod = paymentMethod
+        self.paymentInformation = paymentInformation
+        self.completion = completion
+    }
+}
+
+/// Internal Apple Pay class. Do not use.
+/// :nodoc:
+@objc @_spi(STP) public class _stpinternal_ApplePayContextDidCompleteStorage: NSObject {
+    @_spi(STP) public weak var delegate: _stpinternal_STPApplePayContextDelegateBase?
+    @_spi(STP) public var context: STPApplePayContext
+    @_spi(STP) public var status: STPApplePayContext.PaymentStatus
+    @_spi(STP) public var error: Error?
+
+    @_spi(STP) public init(
+        delegate: _stpinternal_STPApplePayContextDelegateBase,
+        context: STPApplePayContext,
+        status: STPApplePayContext.PaymentStatus,
+        error: Error?
+    ) {
+        self.delegate = delegate
+        self.context = context
+        self.status = status
+        self.error = error
+    }
+}

+ 761 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/ApplePayContext/STPApplePayContext.swift

@@ -0,0 +1,761 @@
+//
+//  STPApplePayContext.swift
+//  StripeApplePay
+//
+//  Created by Yuki Tokuhiro on 2/20/20.
+//  Copyright © 2020 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+import ObjectiveC
+import PassKit
+@_spi(STP) import StripeCore
+
+/// :nodoc:
+@objc public protocol _stpinternal_STPApplePayContextDelegateBase: NSObjectProtocol {
+    /// Called when the user selects a new shipping method.  The delegate should determine
+    /// shipping costs based on the shipping method and either the shipping address supplied in the original
+    /// PKPaymentRequest or the address fragment provided by the last call to paymentAuthorizationController:
+    /// didSelectShippingContact:completion:.
+    /// You must invoke the completion block with an updated array of PKPaymentSummaryItem objects.
+    @objc(applePayContext:didSelectShippingMethod:handler:)
+    optional func applePayContext(
+        _ context: STPApplePayContext,
+        didSelect shippingMethod: PKShippingMethod,
+        handler: @escaping (_ update: PKPaymentRequestShippingMethodUpdate) -> Void
+    )
+
+    /// Called when the user has selected a new shipping address.  You should inspect the
+    /// address and must invoke the completion block with an updated array of PKPaymentSummaryItem objects.
+    /// @note To maintain privacy, the shipping information is anonymized. For example, in the United States it only includes the city, state, and zip code. This provides enough information to calculate shipping costs, without revealing sensitive information until the user actually approves the purchase.
+    /// Receive full shipping information in the paymentInformation passed to `applePayContext:didCreatePaymentMethod:paymentInformation:completion:`
+    @objc optional func applePayContext(
+        _ context: STPApplePayContext,
+        didSelectShippingContact contact: PKContact,
+        handler: @escaping (_ update: PKPaymentRequestShippingContactUpdate) -> Void
+    )
+
+    /// Optionally configure additional information on your PKPaymentAuthorizationResult.
+    /// This closure will be called after the PaymentIntent or SetupIntent is confirmed, but before
+    /// the Apple Pay sheet has been closed.
+    /// In your implementation, you can configure the PKPaymentAuthorizationResult to add custom fields, such as `orderDetails`.
+    /// See https://developer.apple.com/documentation/passkit/pkpaymentauthorizationresult for all configuration options.
+    /// This method is optional. If you implement this, you must call the handler block with the PKPaymentAuthorizationResult on the main queue.
+    /// WARNING: If you do not call the completion handler, your app will hang until the Apple Pay sheet times out.
+    @objc optional func applePayContext(
+        _ context: STPApplePayContext,
+        willCompleteWithResult authorizationResult: PKPaymentAuthorizationResult,
+        handler: @escaping (_ authorizationResult: PKPaymentAuthorizationResult) -> Void
+    )
+}
+
+/// Implement the required methods of this delegate to supply a PaymentIntent to ApplePayContext and be notified of the completion of the Apple Pay payment.
+/// You may also implement the optional delegate methods to handle shipping methods and shipping address changes e.g. to verify you can ship to the address, or update the payment amount.
+public protocol ApplePayContextDelegate: _stpinternal_STPApplePayContextDelegateBase {
+    /// Called after the customer has authorized Apple Pay.  Implement this method to call the completion block with the client secret of a PaymentIntent or SetupIntent.
+    /// - Parameters:
+    ///   - paymentMethod:                 The PaymentMethod that represents the customer's Apple Pay payment method.
+    /// If you create the PaymentIntent with confirmation_method=manual, pass `paymentMethod.id` as the payment_method and confirm=true. Otherwise, you can ignore this parameter.
+    ///   - paymentInformation:      The underlying PKPayment created by Apple Pay.
+    /// If you create the PaymentIntent with confirmation_method=manual, you can collect shipping information using its `shippingContact` and `shippingMethod` properties.
+    ///   - completion:                        Call this with the PaymentIntent or SetupIntent client secret, or the error that occurred creating the PaymentIntent or SetupIntent.
+    func applePayContext(
+        _ context: STPApplePayContext,
+        didCreatePaymentMethod paymentMethod: StripeAPI.PaymentMethod,
+        paymentInformation: PKPayment,
+        completion: @escaping STPIntentClientSecretCompletionBlock
+    )
+
+    /// Called after the Apple Pay sheet is dismissed with the result of the payment.
+    /// Your implementation could stop a spinner and display a receipt view or error to the customer, for example.
+    /// - Parameters:
+    ///   - status: The status of the payment
+    ///   - error: The error that occurred, if any.
+    func applePayContext(
+        _ context: STPApplePayContext,
+        didCompleteWith status: STPApplePayContext.PaymentStatus,
+        error: Error?
+    )
+}
+
+/// A helper class that implements Apple Pay.
+/// Usage looks like this:
+/// 1. Initialize this class with a PKPaymentRequest describing the payment request (amount, line items, required shipping info, etc)
+/// 2. Call presentApplePayOnViewController:completion: to present the Apple Pay sheet and begin the payment process
+/// 3 (optional): If you need to respond to the user changing their shipping information/shipping method, implement the optional delegate methods
+/// 4. When the user taps 'Buy', this class uses the PaymentIntent that you supply in the applePayContext:didCreatePaymentMethod:completion: delegate method to complete the payment
+/// 5. After payment completes/errors and the sheet is dismissed, this class informs you in the applePayContext:didCompleteWithStatus: delegate method
+/// - seealso: https://stripe.com/docs/apple-pay#native for a full guide
+/// - seealso: ApplePayExampleViewController for an example
+@objc(STPApplePayContext)
+public class STPApplePayContext: NSObject, PKPaymentAuthorizationControllerDelegate {
+
+    /// A special string that can be passed in place of a intent client secret to force showing success and return a PaymentState of `success`.
+    /// - Note: ⚠️ If provided, the SDK performs no action to complete the payment or setup - it doesn't confirm a PaymentIntent or SetupIntent or handle next actions.
+    ///   You should only use this if your integration can't create a PaymentIntent or SetupIntent. It is your responsibility to ensure that you only pass this value if the payment or set up is successful. 
+    @_spi(STP) public static let COMPLETE_WITHOUT_CONFIRMING_INTENT = "COMPLETE_WITHOUT_CONFIRMING_INTENT"
+
+    /// Initializes this class.
+    /// @note This may return nil if the request is invalid e.g. the user is restricted by parental controls, or can't make payments on any of the request's supported networks
+    /// @note If using Swift, using ApplePayContextDelegate is recommended over STPApplePayContextDelegate.
+    /// - Parameters:
+    ///   - paymentRequest:      The payment request to use with Apple Pay.
+    ///   - delegate:                    The delegate.
+    @objc(initWithPaymentRequest:delegate:)
+    public required init?(
+        paymentRequest: PKPaymentRequest,
+        delegate: _stpinternal_STPApplePayContextDelegateBase?
+    ) {
+        STPAnalyticsClient.sharedClient.addClass(toProductUsageIfNecessary: STPApplePayContext.self)
+        if !StripeAPI.canSubmitPaymentRequest(paymentRequest) {
+            return nil
+        }
+
+        authorizationController = PKPaymentAuthorizationController(paymentRequest: paymentRequest)
+        if authorizationController == nil {
+            return nil
+        }
+
+        self.delegate = delegate
+
+        super.init()
+        authorizationController?.delegate = self
+    }
+
+    private var presentationWindow: UIWindow?
+
+    /// Presents the Apple Pay sheet from the key window, starting the payment process.
+    /// @note This method should only be called once; create a new instance of STPApplePayContext every time you present Apple Pay.
+    /// - Parameters:
+    ///   - completion:               Called after the Apple Pay sheet is presented
+    @objc(presentApplePayWithCompletion:)
+    public func presentApplePay(completion: STPVoidBlock? = nil) {
+        let window = UIApplication.shared.windows.first { $0.isKeyWindow }
+        self.presentApplePay(from: window, completion: completion)
+    }
+
+    /// Presents the Apple Pay sheet from the specified window, starting the payment process.
+    /// @note This method should only be called once; create a new instance of STPApplePayContext every time you present Apple Pay.
+    /// - Parameters:
+    ///   - window:                   The UIWindow to host the Apple Pay sheet
+    ///   - completion:               Called after the Apple Pay sheet is presented
+    @objc(presentApplePayFromWindow:completion:)
+    public func presentApplePay(from window: UIWindow?, completion: STPVoidBlock? = nil) {
+        presentationWindow = window
+        guard !didPresentApplePay, let applePayController = self.authorizationController else {
+            assert(
+                false,
+                "This method should only be called once; create a new instance of STPApplePayContext every time you present Apple Pay."
+            )
+            return
+        }
+        didPresentApplePay = true
+
+        // This instance (and the associated Objective-C bridge object, if any) must live so
+        // that the apple pay sheet is dismissed; until then, the app is effectively frozen.
+        objc_setAssociatedObject(
+            applePayController,
+            UnsafeRawPointer(&kApplePayContextAssociatedObjectKey),
+            self,
+            .OBJC_ASSOCIATION_RETAIN_NONATOMIC
+        )
+
+        applePayController.present { (_) in
+            DispatchQueue.main.async {
+                completion?()
+            }
+        }
+    }
+
+    /// Presents the Apple Pay sheet from the specified view controller, starting the payment process.
+    /// @note This method should only be called once; create a new instance of STPApplePayContext every time you present Apple Pay.
+    /// @deprecated A presenting UIViewController is no longer needed. Use presentApplePay(completion:) instead.
+    /// - Parameters:
+    ///   - viewController:      The UIViewController instance to present the Apple Pay sheet on
+    ///   - completion:               Called after the Apple Pay sheet is presented
+    @objc(presentApplePayOnViewController:completion:)
+    @available(
+        *,
+        deprecated,
+        message: "Use `presentApplePay(completion:)` instead.",
+        renamed: "presentApplePay(completion:)"
+    )
+    public func presentApplePay(
+        on viewController: UIViewController,
+        completion: STPVoidBlock? = nil
+    ) {
+        let window = viewController.viewIfLoaded?.window
+        presentApplePay(from: window, completion: completion)
+    }
+
+    /// The API Client to use to make requests.
+    /// Defaults to `STPAPIClient.shared`
+    @objc public var apiClient: STPAPIClient = STPAPIClient.shared
+    /// ApplePayContext passes this to the /confirm endpoint for PaymentIntents if it did not collect shipping details itself.
+    /// :nodoc:
+    @_spi(STP) public var shippingDetails: StripeAPI.ShippingDetails?
+    private weak var delegate: _stpinternal_STPApplePayContextDelegateBase?
+    @objc var authorizationController: PKPaymentAuthorizationController?
+    @_spi(STP) public var returnUrl: String?
+
+    @_spi(STP) @frozen public enum ConfirmType {
+        case client
+        case server
+        /// The merchant backend used the special string instead of a intent client secret, so we completed the payment without confirming an intent.
+        case none
+    }
+    /// Tracks where the call to confirm the PaymentIntent or SetupIntent happened.
+    @_spi(STP) public var confirmType: ConfirmType?
+    // Internal state
+    private var paymentState: PaymentState = .notStarted
+    private var error: Error?
+    /// YES if the flow cancelled or timed out.  This toggles which delegate method (didFinish or didAuthorize) calls our didComplete delegate method
+    private var didCancelOrTimeoutWhilePending = false
+    private var didPresentApplePay = false
+
+    /// :nodoc:
+    @objc public override func responds(to aSelector: Selector!) -> Bool {
+        // ApplePayContextDelegate exposes methods that map 1:1 to PKPaymentAuthorizationControllerDelegate methods
+        // We want this method to return YES for these methods IFF they are implemented by our delegate
+
+        // Why not simply implement the methods to call their equivalents on self.delegate?
+        // The implementation of e.g. didSelectShippingMethod must call the completion block.
+        // If the user does not implement e.g. didSelectShippingMethod, we don't know the correct PKPaymentSummaryItems to pass to the completion block
+        // (it may have changed since we were initialized due to another delegate method)
+        if let equivalentDelegateSelector = _delegateToAppleDelegateMapping()[aSelector] {
+            return delegate?.responds(to: equivalentDelegateSelector) ?? false
+        } else {
+            return super.responds(to: aSelector)
+        }
+    }
+
+    // MARK: - Private Helper
+    func _delegateToAppleDelegateMapping() -> [Selector: Selector] {
+        // We need this type to disambiguate from the other PKACDelegate.didSelect:handler: method
+        // HACK: This signature changed in Xcode 14, we need to check the compiler version to choose the right signature.
+        #if compiler(>=5.7)
+            typealias pkDidSelectShippingMethodSignature =
+                (any PKPaymentAuthorizationControllerDelegate) -> (
+                    (
+                        PKPaymentAuthorizationController,
+                        PKShippingMethod,
+                        @escaping (PKPaymentRequestShippingMethodUpdate) -> Void
+                    ) -> Void
+                )?
+        #else
+            typealias pkDidSelectShippingMethodSignature = (
+                (PKPaymentAuthorizationControllerDelegate) -> (
+                    PKPaymentAuthorizationController, PKShippingMethod,
+                    @escaping (PKPaymentRequestShippingMethodUpdate) -> Void
+                ) -> Void
+            )?
+        #endif
+
+        let pk_didSelectShippingMethod = #selector(
+            (PKPaymentAuthorizationControllerDelegate.paymentAuthorizationController(
+                _:
+                didSelectShippingMethod:
+                handler:
+            )) as pkDidSelectShippingMethodSignature)
+        let stp_didSelectShippingMethod = #selector(
+            _stpinternal_STPApplePayContextDelegateBase.applePayContext(_:didSelect:handler:))
+        let pk_didSelectShippingContact = #selector(
+            PKPaymentAuthorizationControllerDelegate.paymentAuthorizationController(
+                _:
+                didSelectShippingContact:
+                handler:
+            ))
+        let stp_didSelectShippingContact = #selector(
+            _stpinternal_STPApplePayContextDelegateBase.applePayContext(
+                _:
+                didSelectShippingContact:
+                handler:
+            ))
+
+        return [
+            pk_didSelectShippingMethod: stp_didSelectShippingMethod,
+            pk_didSelectShippingContact: stp_didSelectShippingContact,
+        ]
+    }
+
+    func _end() {
+        if let authorizationController = authorizationController {
+            objc_setAssociatedObject(
+                authorizationController,
+                UnsafeRawPointer(&kApplePayContextAssociatedObjectKey),
+                nil,
+                .OBJC_ASSOCIATION_RETAIN_NONATOMIC
+            )
+        }
+        authorizationController = nil
+        delegate = nil
+    }
+
+    func _shippingDetails(from payment: PKPayment) -> StripeAPI.ShippingDetails? {
+        guard let address = payment.shippingContact?.postalAddress,
+            let name = payment.shippingContact?.name
+        else {
+            // The shipping address street and name are required parameters for a valid .ShippingDetails
+            // Return `shippingDetails` instead
+            return shippingDetails
+        }
+
+        let addressParams = StripeAPI.ShippingDetails.Address(
+            city: address.city,
+            country: address.isoCountryCode,
+            line1: address.street,
+            postalCode: address.postalCode,
+            state: address.state
+        )
+
+        let formatter = PersonNameComponentsFormatter()
+        formatter.style = .long
+        let shippingParams = StripeAPI.ShippingDetails(
+            address: addressParams,
+            name: formatter.string(from: name),
+            phone: payment.shippingContact?.phoneNumber?.stringValue
+        )
+
+        return shippingParams
+    }
+
+    // MARK: - PKPaymentAuthorizationControllerDelegate
+    /// :nodoc:
+    @objc(paymentAuthorizationController:didAuthorizePayment:handler:)
+    public func paymentAuthorizationController(
+        _ controller: PKPaymentAuthorizationController,
+        didAuthorizePayment payment: PKPayment,
+        handler completion: @escaping (PKPaymentAuthorizationResult) -> Void
+    ) {
+        // Some observations (on iOS 12 simulator):
+        // - The docs say localizedDescription can be shown in the Apple Pay sheet, but I haven't seen this.
+        // - If you call the completion block w/ a status of .failure and an error, the user is prompted to try again.
+
+        _completePayment(with: payment) { status, error in
+            let errors = [STPAPIClient.pkPaymentError(forStripeError: error)].compactMap({ $0 })
+            let result = PKPaymentAuthorizationResult(status: status, errors: errors)
+            if self.delegate?.responds(
+                to: #selector(
+                    _stpinternal_STPApplePayContextDelegateBase.applePayContext(
+                        _:
+                        willCompleteWithResult:
+                        handler:
+                    ))
+            )
+                ?? false
+            {
+                self.delegate?.applePayContext?(
+                    self,
+                    willCompleteWithResult: result,
+                    handler: { newResult in
+                        completion(newResult)
+                    }
+                )
+            } else {
+                completion(result)
+            }
+        }
+    }
+
+    /// :nodoc:
+    @objc
+    public func paymentAuthorizationController(
+        _ controller: PKPaymentAuthorizationController,
+        didSelectShippingMethod shippingMethod: PKShippingMethod,
+        handler completion: @escaping (PKPaymentRequestShippingMethodUpdate) -> Void
+    ) {
+        if delegate?.responds(
+            to: #selector(
+                _stpinternal_STPApplePayContextDelegateBase.applePayContext(_:didSelect:handler:))
+        )
+            ?? false
+        {
+            delegate?.applePayContext?(self, didSelect: shippingMethod, handler: completion)
+        }
+    }
+
+    /// :nodoc:
+    @objc
+    public func paymentAuthorizationController(
+        _ controller: PKPaymentAuthorizationController,
+        didSelectShippingContact contact: PKContact,
+        handler completion: @escaping (PKPaymentRequestShippingContactUpdate) -> Void
+    ) {
+        if delegate?.responds(
+            to: #selector(
+                _stpinternal_STPApplePayContextDelegateBase.applePayContext(
+                    _:
+                    didSelectShippingContact:
+                    handler:
+                ))
+        ) ?? false {
+            delegate?.applePayContext?(self, didSelectShippingContact: contact, handler: completion)
+        }
+    }
+
+    /// :nodoc:
+    @objc public func paymentAuthorizationControllerDidFinish(
+        _ controller: PKPaymentAuthorizationController
+    ) {
+        // Note: If you don't dismiss the VC, the UI disappears, the VC blocks interaction, and this method gets called again.
+        // Note: This method is called if the user cancels (taps outside the sheet) or Apple Pay times out (empirically 30 seconds)
+        switch paymentState {
+        case .notStarted:
+            controller.dismiss {
+                stpDispatchToMainThreadIfNecessary {
+                    self.callDidCompleteDelegate(status: .userCancellation, error: nil)
+                    self._end()
+                }
+            }
+        case .pending:
+            // We can't cancel a pending payment. If we dismiss the VC now, the customer might interact with the app and miss seeing the result of the payment - risking a double charge, chargeback, etc.
+            // Instead, we'll dismiss and notify our delegate when the payment finishes.
+            didCancelOrTimeoutWhilePending = true
+        case .error:
+            controller.dismiss {
+                stpDispatchToMainThreadIfNecessary {
+                    self.callDidCompleteDelegate(status: .error, error: self.error)
+                    self._end()
+                }
+            }
+        case .success:
+            controller.dismiss {
+                stpDispatchToMainThreadIfNecessary {
+                    self.callDidCompleteDelegate(status: .success, error: nil)
+                    self._end()
+                }
+            }
+        }
+    }
+
+    /// :nodoc:
+    @objc public func presentationWindow(
+        for controller: PKPaymentAuthorizationController
+    ) -> UIWindow? {
+        return presentationWindow
+    }
+
+    // MARK: - Helpers
+    func _completePayment(
+        with payment: PKPayment,
+        completion: @escaping (PKPaymentAuthorizationStatus, Error?) -> Void
+    ) {
+        // Helper to handle annoying logic around "Do I call completion block or dismiss + call delegate?"
+        let handleFinalState: ((PaymentState, Error?) -> Void) = { state, error in
+            switch state {
+            case .error:
+                self.paymentState = .error
+                self.error = error
+                if self.didCancelOrTimeoutWhilePending {
+                    self.authorizationController?.dismiss {
+                        DispatchQueue.main.async {
+                            self.callDidCompleteDelegate(status: .error, error: self.error)
+                            self._end()
+                        }
+                    }
+                } else {
+                    completion(PKPaymentAuthorizationStatus.failure, error)
+                }
+                return
+            case .success:
+                self.paymentState = .success
+                if self.didCancelOrTimeoutWhilePending {
+                    self.authorizationController?.dismiss {
+                        DispatchQueue.main.async {
+                            self.callDidCompleteDelegate(status: .success, error: nil)
+                            self._end()
+                        }
+                    }
+                } else {
+                    completion(PKPaymentAuthorizationStatus.success, nil)
+                }
+                return
+            case .pending, .notStarted:
+                assert(false, "Invalid final state")
+                return
+            }
+        }
+
+        // 1. Create PaymentMethod
+        StripeAPI.PaymentMethod.create(apiClient: apiClient, payment: payment) { result in
+            guard let paymentMethod = try? result.get(), self.authorizationController != nil else {
+                if case .failure(let error) = result {
+                    handleFinalState(.error, error)
+                } else {
+                    handleFinalState(.error, nil)
+                }
+                return
+            }
+
+            let paymentMethodCompletion: STPIntentClientSecretCompletionBlock = {
+                clientSecret,
+                intentCreationError in
+                guard let clientSecret = clientSecret, intentCreationError == nil,
+                    self.authorizationController != nil
+                else {
+                    handleFinalState(.error, intentCreationError)
+                    return
+                }
+
+                guard clientSecret != STPApplePayContext.COMPLETE_WITHOUT_CONFIRMING_INTENT else {
+                    self.confirmType = STPApplePayContext.ConfirmType.none
+                    handleFinalState(.success, nil)
+                    return
+                }
+
+                if StripeAPI.SetupIntentConfirmParams.isClientSecretValid(clientSecret) {
+                    // 3a. Retrieve the SetupIntent and see if we need to confirm it client-side
+                    StripeAPI.SetupIntent.get(apiClient: self.apiClient, clientSecret: clientSecret)
+                    {
+                        result in
+                        guard let setupIntent = try? result.get(),
+                            self.authorizationController != nil
+                        else {
+                            if case .failure(let error) = result {
+                                handleFinalState(.error, error)
+                            } else {
+                                handleFinalState(.error, nil)
+                            }
+                            return
+                        }
+
+                        switch setupIntent.status {
+                        case .requiresConfirmation, .requiresAction, .requiresPaymentMethod:
+                            self.confirmType = .client
+                            // 4a. Confirm the SetupIntent
+                            self.paymentState = .pending  // After this point, we can't cancel
+                            var confirmParams = StripeAPI.SetupIntentConfirmParams(
+                                clientSecret: clientSecret
+                            )
+                            confirmParams.paymentMethod = paymentMethod.id
+                            confirmParams.useStripeSdk = true
+                            confirmParams.returnUrl = self.returnUrl
+
+                            StripeAPI.SetupIntent.confirm(
+                                apiClient: self.apiClient,
+                                params: confirmParams
+                            ) {
+                                result in
+                                guard let setupIntent = try? result.get(),
+                                    self.authorizationController != nil,
+                                    setupIntent.status == .succeeded
+                                else {
+                                    if case .failure(let error) = result {
+                                        handleFinalState(.error, error)
+                                    } else {
+                                        handleFinalState(.error, nil)
+                                    }
+                                    return
+                                }
+
+                                handleFinalState(.success, nil)
+                            }
+                        case .succeeded:
+                            self.confirmType = .server
+                            handleFinalState(.success, nil)
+                        case .canceled, .processing, .unknown, .unparsable, .none:
+                            handleFinalState(
+                                .error,
+                                Self.makeUnknownError(
+                                    message:
+                                        "The SetupIntent is in an unexpected state: \(setupIntent.status!)"
+                                )
+                            )
+                        }
+                    }
+                } else {
+                    let paymentIntentClientSecret = clientSecret
+                    // 3b. Retrieve the PaymentIntent and see if we need to confirm it client-side
+                    StripeAPI.PaymentIntent.get(
+                        apiClient: self.apiClient,
+                        clientSecret: paymentIntentClientSecret
+                    ) { result in
+                        guard let paymentIntent = try? result.get(),
+                            self.authorizationController != nil
+                        else {
+                            if case .failure(let error) = result {
+                                handleFinalState(.error, error)
+                            } else {
+                                handleFinalState(.error, nil)
+                            }
+                            return
+                        }
+
+                        if paymentIntent.confirmationMethod == .automatic
+                            && (paymentIntent.status == .requiresPaymentMethod
+                                || paymentIntent.status == .requiresConfirmation)
+                        {
+                            self.confirmType = .client
+                            // 4b. Confirm the PaymentIntent
+
+                            var paymentIntentParams = StripeAPI.PaymentIntentParams(
+                                clientSecret: paymentIntentClientSecret
+                            )
+                            paymentIntentParams.paymentMethod = paymentMethod.id
+                            paymentIntentParams.useStripeSdk = true
+                            // If a merchant attaches shipping to the PI on their server, the /confirm endpoint will error if we update shipping with a “requires secret key” error message.
+                            // To accommodate this, don't attach if our shipping is the same as the PI's shipping
+                            if paymentIntent.shipping != self._shippingDetails(from: payment) {
+                                paymentIntentParams.shipping = self._shippingDetails(from: payment)
+                            }
+
+                            self.paymentState = .pending  // After this point, we can't cancel
+
+                            // We don't use PaymentHandler because we can't handle next actions as-is - we'd need to dismiss the Apple Pay VC.
+                            StripeAPI.PaymentIntent.confirm(
+                                apiClient: self.apiClient,
+                                params: paymentIntentParams
+                            ) {
+                                result in
+                                guard let postConfirmPI = try? result.get(),
+                                    postConfirmPI.status == .succeeded
+                                        || postConfirmPI.status == .requiresCapture
+                                else {
+                                    if case .failure(let error) = result {
+                                        handleFinalState(.error, error)
+                                    } else {
+                                        handleFinalState(.error, nil)
+                                    }
+                                    return
+                                }
+                                handleFinalState(.success, nil)
+                            }
+                        } else if paymentIntent.status == .succeeded
+                            || paymentIntent.status == .requiresCapture
+                        {
+                            self.confirmType = .server
+                            handleFinalState(.success, nil)
+                        } else {
+                            let unknownError = Self.makeUnknownError(
+                                message:
+                                    "The PaymentIntent is in an unexpected state. If you pass confirmation_method = manual when creating the PaymentIntent, also pass confirm = true.  If server-side confirmation fails, double check you are passing the error back to the client."
+                            )
+                            handleFinalState(.error, unknownError)
+                        }
+                    }
+                }
+            }
+            // 2. Fetch PaymentIntent/SetupIntent client secret from delegate
+            let legacyDelegateSelector = NSSelectorFromString(
+                "applePayContext:didCreatePaymentMethod:paymentInformation:completion:"
+            )
+            if let delegate = self.delegate {
+                if let delegate = delegate as? ApplePayContextDelegate {
+                    delegate.applePayContext(
+                        self,
+                        didCreatePaymentMethod: paymentMethod,
+                        paymentInformation: payment,
+                        completion: paymentMethodCompletion
+                    )
+                } else if delegate.responds(to: legacyDelegateSelector),
+                    let helperClass = NSClassFromString("STPApplePayContextLegacyHelper")
+                {
+                    let legacyStorage = _stpinternal_ApplePayContextDidCreatePaymentMethodStorage(
+                        delegate: delegate,
+                        context: self,
+                        paymentMethod: paymentMethod,
+                        paymentInformation: payment,
+                        completion: paymentMethodCompletion
+                    )
+                    helperClass.performDidCreatePaymentMethod(legacyStorage)
+                } else {
+                    assertionFailure(
+                        "An STPApplePayContext's delegate must conform to ApplePayContextDelegate or STPApplePayContextDelegate."
+                    )
+                }
+            }
+        }
+    }
+
+    func callDidCompleteDelegate(status: PaymentStatus, error: Error?) {
+        if let delegate = self.delegate {
+            if let delegate = delegate as? ApplePayContextDelegate {
+                delegate.applePayContext(self, didCompleteWith: status, error: error)
+            } else if delegate.responds(
+                to: NSSelectorFromString("applePayContext:didCompleteWithStatus:error:")
+            ) {
+                if let helperClass = NSClassFromString("STPApplePayContextLegacyHelper") {
+                    let legacyStorage = _stpinternal_ApplePayContextDidCompleteStorage(
+                        delegate: delegate,
+                        context: self,
+                        status: status,
+                        error: error
+                    )
+                    helperClass.performDidComplete(legacyStorage)
+                }
+            } else {
+                assertionFailure(
+                    "An STPApplePayContext's delegate must conform to ApplePayContextDelegate or STPApplePayContextDelegate."
+                )
+            }
+        }
+
+    }
+
+    @_spi(STP) public static func makeUnknownError(message: String) -> NSError {
+        let userInfo = [
+            NSLocalizedDescriptionKey: NSError.stp_unexpectedErrorMessage(),
+            STPError.errorMessageKey: message,
+        ]
+        return NSError(
+            domain: STPError.STPPaymentHandlerErrorDomain,
+            code: STPPaymentHandlerErrorCodeIntentStatusErrorCode,
+            userInfo: userInfo
+        )
+    }
+
+    /// This is STPPaymentHandlerErrorCode.intentStatusErrorCode.rawValue, which we don't want to vend from this framework.
+    fileprivate static let STPPaymentHandlerErrorCodeIntentStatusErrorCode = 3
+
+    enum PaymentState {
+        case notStarted
+        case pending
+        case error
+        case success
+    }
+
+    /// An enum representing the status of a payment requested from the user.
+    @frozen public enum PaymentStatus {
+        /// The payment succeeded.
+        case success
+        /// The payment failed due to an unforeseen error, such as the user's Internet connection being offline.
+        case error
+        /// The user cancelled the payment (for example, by hitting "cancel" in the Apple Pay dialog).
+        case userCancellation
+    }
+}
+
+/// :nodoc:
+@_spi(STP) extension STPApplePayContext: STPAnalyticsProtocol {
+    @_spi(STP) public static var stp_analyticsIdentifier: String {
+        return "STPApplePayContext"
+    }
+}
+
+/// :nodoc:
+class ModernApplePayContext: STPAnalyticsProtocol {
+    @_spi(STP) public static var stp_analyticsIdentifier: String {
+        return "ModernApplePayContext"
+    }
+}
+
+private var kSTPApplePayContextAssociatedObjectKey = 0
+enum STPPaymentState: Int {
+    case notStarted
+    case pending
+    case error
+    case success
+}
+
+private class _stpinternal_STPApplePayContextLegacyHelper: NSObject {
+    @objc class func performDidCreatePaymentMethod(
+        _ storage: _stpinternal_ApplePayContextDidCreatePaymentMethodStorage
+    ) {
+        // Placeholder to allow this to be called on AnyObject
+    }
+    @objc class func performDidComplete(_ storage: _stpinternal_ApplePayContextDidCompleteStorage) {
+        // Placeholder to allow this to be called on AnyObject
+    }
+}
+
+private var kApplePayContextAssociatedObjectKey = 0

+ 18 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/Blocks.swift

@@ -0,0 +1,18 @@
+//
+//  Blocks.swift
+//  StripeApplePay
+//
+//  Created by David Estes on 1/6/22.
+//  Copyright © 2022 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+
+/// An empty block, called with no arguments, returning nothing.
+public typealias STPVoidBlock = () -> Void
+
+/// A block to be run with the client secret of a PaymentIntent or SetupIntent.
+/// - Parameters:
+///   - clientSecret:    The client secret of the PaymentIntent or SetupIntent. See https://stripe.com/docs/api/payment_intents/object#payment_intent_object-client_secret
+///   - error:                    The error that occurred when creating the Intent, or nil if none occurred.
+public typealias STPIntentClientSecretCompletionBlock = (String?, Error?) -> Void

+ 101 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/Extensions/BillingDetails+ApplePay.swift

@@ -0,0 +1,101 @@
+//
+//  BillingDetails+ApplePay.swift
+//  StripeApplePay
+//
+//  Created by David Estes on 8/9/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+import PassKit
+@_spi(STP) import StripeCore
+
+extension StripeContact {
+    /// Initializes a new Contact with data from an PassKit contact.
+    /// - Parameter contact: The PassKit contact you want to populate the Contact from.
+    /// - Returns: A new Contact with data copied from the passed in contact.
+    init(
+        pkContact contact: PKContact
+    ) {
+        let nameComponents = contact.name
+        if let nameComponents = nameComponents {
+            givenName = stringIfHasContentsElseNil(nameComponents.givenName)
+            familyName = stringIfHasContentsElseNil(nameComponents.familyName)
+
+            name = stringIfHasContentsElseNil(
+                PersonNameComponentsFormatter.localizedString(from: nameComponents, style: .default)
+            )
+        }
+        email = stringIfHasContentsElseNil(contact.emailAddress)
+        if let phoneNumber = contact.phoneNumber {
+            phone = sanitizedPhoneString(from: phoneNumber)
+        } else {
+            phone = nil
+        }
+        setAddressFromCNPostal(contact.postalAddress)
+    }
+
+    private func sanitizedPhoneString(from phoneNumber: CNPhoneNumber) -> String? {
+        return stringIfHasContentsElseNil(
+            STPNumericStringValidator.sanitizedNumericString(for: phoneNumber.stringValue)
+        )
+    }
+
+    private mutating func setAddressFromCNPostal(_ address: CNPostalAddress?) {
+        line1 = stringIfHasContentsElseNil(address?.street)
+        city = stringIfHasContentsElseNil(address?.city)
+        state = stringIfHasContentsElseNil(address?.state)
+        postalCode = stringIfHasContentsElseNil(address?.postalCode)
+        country = stringIfHasContentsElseNil(address?.isoCountryCode.uppercased())
+    }
+}
+
+extension StripeAPI.BillingDetails {
+    init?(
+        from payment: PKPayment
+    ) {
+        var billingDetails: StripeAPI.BillingDetails?
+        if payment.billingContact != nil {
+            billingDetails = StripeAPI.BillingDetails()
+            if let billingContact = payment.billingContact {
+                let billingAddress = StripeContact(pkContact: billingContact)
+                billingDetails?.name = billingAddress.name
+                billingDetails?.email = billingAddress.email
+                billingDetails?.phone = billingAddress.phone
+                if billingContact.postalAddress != nil {
+                    billingDetails?.address = StripeAPI.BillingDetails.Address(
+                        contact: billingAddress
+                    )
+                }
+            }
+        }
+
+        // The phone number and email in the "Contact" panel in the Apple Pay dialog go into the shippingContact,
+        // not the billingContact. To work around this, we should fill the billingDetails' email and phone
+        // number from the shippingDetails.
+        if payment.shippingContact != nil {
+            var shippingAddress: StripeContact?
+            if let shippingContact = payment.shippingContact {
+                shippingAddress = StripeContact(pkContact: shippingContact)
+            }
+            if billingDetails?.email == nil && shippingAddress?.email != nil {
+                if billingDetails == nil {
+                    billingDetails = StripeAPI.BillingDetails()
+                }
+                billingDetails?.email = shippingAddress?.email
+            }
+            if billingDetails?.phone == nil && shippingAddress?.phone != nil {
+                if billingDetails == nil {
+                    billingDetails = StripeAPI.BillingDetails()
+                }
+                billingDetails?.phone = shippingAddress?.phone
+            }
+        }
+
+        if let billingDetails = billingDetails {
+            self = billingDetails
+        } else {
+            return nil
+        }
+    }
+}

+ 26 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/Extensions/PKContact+Stripe.swift

@@ -0,0 +1,26 @@
+//
+//  PKContact+Stripe.swift
+//  StripeApplePay
+//
+//  Created by David Estes on 11/16/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+import PassKit
+
+extension PKContact {
+    @_spi(STP) public var addressParams: [AnyHashable: Any] {
+        var params: [AnyHashable: Any] = [:]
+        let stpAddress = StripeContact(pkContact: self)
+
+        params["name"] = stpAddress.name
+        params["address_line1"] = stpAddress.line1
+        params["address_city"] = stpAddress.city
+        params["address_state"] = stpAddress.state
+        params["address_zip"] = stpAddress.postalCode
+        params["address_country"] = stpAddress.country
+
+        return params
+    }
+}

+ 32 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/Extensions/PKPayment+Stripe.swift

@@ -0,0 +1,32 @@
+//
+//  PKPayment+Stripe.swift
+//  StripeApplePay
+//
+//  Created by Ben Guo on 7/2/15.
+//  Copyright © 2015 Stripe, Inc. All rights reserved.
+//
+
+import PassKit
+
+extension PKPayment {
+    /// Returns true if the instance is a payment from the simulator.
+    @_spi(STP) public func stp_isSimulated() -> Bool {
+        return token.transactionIdentifier == "Simulated Identifier"
+    }
+
+    /// Returns a fake transaction identifier with the expected ~-separated format.
+    @_spi(STP) public class func stp_testTransactionIdentifier() -> String {
+        var uuid = UUID().uuidString
+        uuid = uuid.replacingOccurrences(of: "~", with: "")
+
+        // Simulated cards don't have enough info yet. For now, use a fake Visa number
+        let number = "4242424242424242"
+
+        // Without the original PKPaymentRequest, we'll need to use fake data here.
+        let amount = NSDecimalNumber(string: "0")
+        let cents = NSNumber(value: amount.multiplying(byPowerOf10: 2).intValue).stringValue
+        let currency = "USD"
+        let identifier = ["ApplePayStubs", number, cents, currency, uuid].joined(separator: "~")
+        return identifier
+    }
+}

+ 43 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Models/Address.swift

@@ -0,0 +1,43 @@
+//
+//  Address.swift
+//  StripeApplePay
+//
+//  Created by David Estes on 8/9/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+@_spi(STP) import StripeCore
+
+/// An internal struct for handling contacts. This is not encodable/decodable for use with the Stripe API.
+struct StripeContact {
+    /// The user's full name (e.g. "Jane Doe")
+    public var name: String?
+
+    /// The first line of the user's street address (e.g. "123 Fake St")
+    public var line1: String?
+
+    /// The apartment, floor number, etc of the user's street address (e.g. "Apartment 1A")
+    public var line2: String?
+
+    /// The city in which the user resides (e.g. "San Francisco")
+    public var city: String?
+
+    /// The state in which the user resides (e.g. "CA")
+    public var state: String?
+
+    /// The postal code in which the user resides (e.g. "90210")
+    public var postalCode: String?
+
+    /// The ISO country code of the address (e.g. "US")
+    public var country: String?
+
+    /// The phone number of the address (e.g. "8885551212")
+    public var phone: String?
+
+    /// The email of the address (e.g. "jane@doe.com")
+    public var email: String?
+
+    internal var givenName: String?
+    internal var familyName: String?
+}

+ 67 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Models/BillingDetails.swift

@@ -0,0 +1,67 @@
+//
+//  BillingDetails.swift
+//  StripeApplePay
+//
+//  Created by David Estes on 7/15/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+@_spi(STP) import StripeCore
+
+extension StripeAPI {
+    /// Billing information associated with a `STPPaymentMethod` that may be used or required by particular types of payment methods.
+    /// - seealso: https://stripe.com/docs/api/payment_methods/object#payment_method_object-billing_details
+    public struct BillingDetails: UnknownFieldsCodable {
+        /// Billing address.
+        public var address: Address?
+
+        /// The billing address, a property sent in a PaymentMethod response
+        public struct Address: UnknownFieldsCodable {
+            /// The first line of the user's street address (e.g. "123 Fake St")
+            public var line1: String?
+
+            /// The apartment, floor number, etc of the user's street address (e.g. "Apartment 1A")
+            public var line2: String?
+
+            /// The city in which the user resides (e.g. "San Francisco")
+            public var city: String?
+
+            /// The state in which the user resides (e.g. "CA")
+            public var state: String?
+
+            /// The postal code in which the user resides (e.g. "90210")
+            public var postalCode: String?
+
+            /// The ISO country code of the address (e.g. "US")
+            public var country: String?
+
+            public var _additionalParametersStorage: NonEncodableParameters?
+            public var _allResponseFieldsStorage: NonEncodableParameters?
+        }
+
+        /// Email address.
+        public var email: String?
+        /// Full name.
+        public var name: String?
+        /// Billing phone number (including extension).
+        public var phone: String?
+
+        public var _additionalParametersStorage: NonEncodableParameters?
+        public var _allResponseFieldsStorage: NonEncodableParameters?
+    }
+
+}
+
+extension StripeAPI.BillingDetails.Address {
+    init(
+        contact: StripeContact
+    ) {
+        self.city = contact.city
+        self.country = contact.country
+        self.line1 = contact.line1
+        self.line2 = contact.line2
+        self.postalCode = contact.postalCode
+        self.state = contact.state
+    }
+}

+ 33 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Models/CardBrand.swift

@@ -0,0 +1,33 @@
+//
+//  CardBrand.swift
+//  StripeApplePay
+//
+//  Created by David Estes on 4/14/22.
+//  Copyright © 2022 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+
+extension StripeAPI {
+    /// The various card brands to which a payment card can belong.
+    enum CardBrand: String, SafeEnumCodable {
+        /// Visa card
+        case visa = "Visa"
+        /// American Express card
+        case amex = "American Express"
+        /// Mastercard card
+        case mastercard = "MasterCard"
+        /// Discover card
+        case discover = "Discover"
+        /// JCB card
+        case JCB = "JCB"
+        /// Diners Club card
+        case dinersClub = "Diners Club"
+        /// UnionPay card
+        case unionPay = "UnionPay"
+        /// An unknown card brand type
+        case unknown = "Unknown"
+        /// An unparsable card brand
+        case unparsable
+    }
+}

+ 149 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Models/PaymentIntent.swift

@@ -0,0 +1,149 @@
+//
+//  PaymentIntent.swift
+//  StripeApplePay
+//
+//  Created by David Estes on 6/29/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+@_spi(STP) import StripeCore
+
+extension StripeAPI {
+    @_spi(STP) public struct PaymentIntent: UnknownFieldsDecodable {
+        // TODO: (MOBILESDK-468) Add modern bindings for more PaymentIntent fields
+        /// The Stripe ID of the PaymentIntent.
+        @_spi(STP) public let id: String
+
+        /// The client secret used to fetch this PaymentIntent
+        @_spi(STP) public let clientSecret: String
+
+        /// Amount intended to be collected by this PaymentIntent.
+        @_spi(STP) public let amount: Int
+
+        /// If status is `.canceled`, when the PaymentIntent was canceled.
+        @_spi(STP) public let canceledAt: Date?
+
+        /// Capture method of this PaymentIntent
+        @_spi(STP) public let captureMethod: CaptureMethod
+
+        /// Confirmation method of this PaymentIntent
+        @_spi(STP) public let confirmationMethod: ConfirmationMethod
+
+        /// When the PaymentIntent was created.
+        @_spi(STP) public let created: Date
+
+        /// The currency associated with the PaymentIntent.
+        @_spi(STP) public let currency: String
+
+        /// The `description` field of the PaymentIntent.
+        /// An arbitrary string attached to the object. Often useful for displaying to users.
+        @_spi(STP) public let stripeDescription: String?
+
+        /// Whether or not this PaymentIntent was created in livemode.
+        @_spi(STP) public let livemode: Bool
+
+        /// Email address that the receipt for the resulting payment will be sent to.
+        @_spi(STP) public let receiptEmail: String?
+
+        /// The Stripe ID of the Source used in this PaymentIntent.
+        @_spi(STP) public let sourceId: String?
+
+        /// The Stripe ID of the PaymentMethod used in this PaymentIntent.
+        @_spi(STP) public let paymentMethodId: String?
+
+        /// Status of the PaymentIntent
+        @_spi(STP) public let status: Status
+
+        /// Shipping information for this PaymentIntent.
+        @_spi(STP) public let shipping: ShippingDetails?
+
+        /// Status types for a PaymentIntent
+        @frozen @_spi(STP) public enum Status: String, SafeEnumCodable {
+            /// Unknown status
+            case unknown
+            /// This PaymentIntent requires a PaymentMethod or Source
+            case requiresPaymentMethod = "requires_payment_method"
+            /// This PaymentIntent requires a Source
+            /// Deprecated: Use STPPaymentIntentStatusRequiresPaymentMethod instead.
+            @available(
+                *,
+                deprecated,
+                message: "Use STPPaymentIntentStatus.requiresPaymentMethod instead",
+                renamed: "STPPaymentIntentStatus.requiresPaymentMethod"
+            )
+            case requiresSource = "requires_source"
+            /// This PaymentIntent needs to be confirmed
+            case requiresConfirmation = "requires_confirmation"
+            /// The selected PaymentMethod or Source requires additional authentication steps.
+            /// Additional actions found via `next_action`
+            case requiresAction = "requires_action"
+            /// The selected Source requires additional authentication steps.
+            /// Additional actions found via `next_source_action`
+            /// Deprecated: Use STPPaymentIntentStatusRequiresAction instead.
+            @available(
+                *,
+                deprecated,
+                message: "Use STPPaymentIntentStatus.requiresAction instead",
+                renamed: "STPPaymentIntentStatus.requiresAction"
+            )
+            case requiresSourceAction = "requires_source_action"
+            /// Stripe is processing this PaymentIntent
+            case processing
+            /// The payment has succeeded
+            case succeeded
+            /// Indicates the payment must be captured, for STPPaymentIntentCaptureMethodManual
+            case requiresCapture = "requires_capture"
+            /// This PaymentIntent was canceled and cannot be changed.
+            case canceled
+
+            case unparsable
+            // TODO: This is @frozen because of a bug in the Xcode 12.2 Swift compiler.
+            // Remove @frozen after Xcode 12.2 support has been dropped.
+        }
+
+        @frozen @_spi(STP) public enum ConfirmationMethod: String, SafeEnumCodable {
+            /// Unknown confirmation method
+            case unknown
+            /// Confirmed via publishable key
+            case manual
+            /// Confirmed via secret key
+            case automatic
+
+            case unparsable
+            // TODO: This is @frozen because of a bug in the Xcode 12.2 Swift compiler.
+            // Remove @frozen after Xcode 12.2 support has been dropped.
+        }
+
+        @frozen @_spi(STP) public enum CaptureMethod: String, SafeEnumCodable {
+            /// Unknown capture method
+            case unknown
+            /// The PaymentIntent will be automatically captured
+            case automatic
+            /// The PaymentIntent must be manually captured once it has the status
+            /// `.requiresCapture`
+            case manual
+
+            case unparsable
+            // TODO: This is @frozen because of a bug in the Xcode 12.2 Swift compiler.
+            // Remove @frozen after Xcode 12.2 support has been dropped.
+        }
+
+        @_spi(STP) public var _allResponseFieldsStorage: NonEncodableParameters?
+    }
+}
+
+extension StripeAPI.PaymentIntent {
+    /// Helper function for extracting PaymentIntent id from the Client Secret.
+    /// This avoids having to pass around both the id and the secret.
+    /// - Parameter clientSecret: The `client_secret` from the PaymentIntent
+    internal static func id(fromClientSecret clientSecret: String) -> String? {
+        // see parseClientSecret from stripe-js-v3
+        let components = clientSecret.components(separatedBy: "_secret_")
+        if components.count >= 2 && components[0].hasPrefix("pi_") {
+            return components[0]
+        } else {
+            return nil
+        }
+    }
+}

+ 101 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Models/PaymentIntentParams.swift

@@ -0,0 +1,101 @@
+//
+//  PaymentIntentParams.swift
+//  StripeApplePay
+//
+//  Created by David Estes on 6/29/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+@_spi(STP) import StripeCore
+
+extension StripeAPI {
+    @_spi(STP) public struct PaymentIntentParams: UnknownFieldsEncodable {
+        /// The client secret of the PaymentIntent. Required
+        @_spi(STP) public let clientSecret: String
+
+        @_spi(STP) public init(
+            clientSecret: String
+        ) {
+            self.clientSecret = clientSecret
+        }
+
+        @_spi(STP) public var id: String? {
+            return PaymentIntent.id(fromClientSecret: clientSecret)
+        }
+
+        /// Provide a supported `PaymentMethodParams` object, and Stripe will create a
+        /// PaymentMethod during PaymentIntent confirmation.
+        /// @note alternative to `paymentMethodId`
+        @_spi(STP) public var paymentMethodData: PaymentMethodParams?
+
+        /// Provide an already created PaymentMethod's id, and it will be used to confirm the PaymentIntent.
+        /// @note alternative to `paymentMethodParams`
+        @_spi(STP) public var paymentMethod: String?
+
+        /// Provide an already created Source's id, and it will be used to confirm the PaymentIntent.
+        @_spi(STP) public var sourceId: String?
+
+        /// Email address that the receipt for the resulting payment will be sent to.
+        @_spi(STP) public var receiptEmail: String?
+
+        /// `@YES` to save this PaymentIntent’s PaymentMethod or Source to the associated Customer,
+        /// if the PaymentMethod/Source is not already attached.
+        /// This should be a boolean NSNumber, so that it can be `nil`
+        @_spi(STP) public var savePaymentMethod: Bool?
+
+        /// The URL to redirect your customer back to after they authenticate or cancel
+        /// their payment on the payment method’s app or site.
+        /// This should probably be a URL that opens your iOS app.
+        @_spi(STP) public var returnURL: String?
+
+        /// When provided, this property indicates how you intend to use the payment method that your customer provides after the current payment completes.
+        /// If applicable, additional authentication may be performed to comply with regional legislation or network rules required to enable the usage of the same payment method for additional payments.
+        @_spi(STP) public var setupFutureUsage: SetupFutureUsage?
+
+        /// A boolean number to indicate whether you intend to use the Stripe SDK's functionality to handle any PaymentIntent next actions.
+        /// If set to false, STPPaymentIntent.nextAction will only ever contain a redirect url that can be opened in a webview or mobile browser.
+        /// When set to true, the nextAction may contain information that the Stripe SDK can use to perform native authentication within your
+        /// app.
+        @_spi(STP) public var useStripeSdk: Bool?
+
+        /// Shipping information.
+        @_spi(STP) public var shipping: ShippingDetails?
+
+        /// Indicates how you intend to use the payment method that your customer provides after the current payment completes.
+        /// If applicable, additional authentication may be performed to comply with regional legislation or network rules required to enable the usage of the same payment method for additional payments.
+        /// - seealso: https://stripe.com/docs/api/payment_intents/object#payment_intent_object-setup_future_usage
+        @frozen @_spi(STP) public enum SetupFutureUsage: String, SafeEnumCodable {
+            /// Unknown value.  Update your SDK, or use `allResponseFields` for custom handling.
+            case unknown
+            /// No value was provided.
+            case none
+            /// Indicates you intend to only reuse the payment method when the customer is in your checkout flow.
+            case onSession
+            /// Indicates you intend to reuse the payment method when the customer may or may not be in your checkout flow.
+            case offSession
+
+            case unparsable
+            // TODO: This is @frozen because of a bug in the Xcode 12.2 Swift compiler.
+            // Remove @frozen after Xcode 12.2 support has been dropped.
+        }
+
+        @_spi(STP) public var _additionalParametersStorage: NonEncodableParameters?
+    }
+}
+
+extension StripeAPI.PaymentIntentParams {
+    static internal let isClientSecretValidRegex: NSRegularExpression = try! NSRegularExpression(
+        pattern: "^pi_[^_]+_secret_[^_]+$",
+        options: []
+    )
+
+    @_spi(STP) public static func isClientSecretValid(_ clientSecret: String) -> Bool {
+        return
+            (isClientSecretValidRegex.numberOfMatches(
+                in: clientSecret,
+                options: .anchored,
+                range: NSRange(location: 0, length: clientSecret.count)
+            )) == 1
+    }
+}

+ 176 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Models/PaymentMethod.swift

@@ -0,0 +1,176 @@
+//
+//  PaymentMethod.swift
+//  StripeApplePay
+//
+//  Created by David Estes on 6/29/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+@_spi(STP) import StripeCore
+
+extension StripeAPI {
+    /// PaymentMethod objects represent your customer's payment instruments. They can be used with PaymentIntents to collect payments.
+    /// - seealso: https://stripe.com/docs/api/payment_methods
+    public struct PaymentMethod: UnknownFieldsDecodable {
+        /// The Stripe ID of the PaymentMethod.
+        public let id: String
+
+        /// Time at which the object was created. Measured in seconds since the Unix epoch.
+        public var created: Date?
+        /// `YES` if the object exists in live mode or the value `NO` if the object exists in test mode.
+        public var livemode = false
+
+        /// The type of the PaymentMethod.  The corresponding, similarly named property contains additional information specific to the PaymentMethod type.
+        /// e.g. if the type is `Card`, the `card` property is also populated.
+        public var type: PaymentMethodType?
+
+        /// The type of the PaymentMethod.
+        @frozen public enum PaymentMethodType: String, SafeEnumCodable {
+            /// A card payment method.
+            case card
+            /// An unknown type.
+            case unknown
+            case unparsable
+            // TODO: This is @frozen because of a bug in the Xcode 12.2 Swift compiler.
+            // Remove @frozen after Xcode 12.2 support has been dropped.
+        }
+
+        /// Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
+        public var billingDetails: BillingDetails?
+        /// The ID of the Customer to which this PaymentMethod is saved. Nil when the PaymentMethod has not been saved to a Customer.
+        public var customerId: String?
+        /// If this is a card PaymentMethod (ie `self.type == .card`), this contains additional details.
+        public var card: Card?
+
+        /// :nodoc:
+        public struct Card: UnknownFieldsDecodable {
+            public var _allResponseFieldsStorage: NonEncodableParameters?
+            /// The issuer of the card.
+            public private(set) var brand: Brand = .unknown
+
+            /// The various card brands to which a payment card can belong.
+            @frozen public enum Brand: String, SafeEnumCodable {
+                /// Visa
+                case visa
+                /// American Express
+                case amex
+                /// Mastercard
+                case mastercard
+                /// Discover
+                case discover
+                /// JCB
+                case jcb
+                /// Diners Club
+                case diners
+                /// UnionPay
+                case unionpay
+                /// An unknown card brand
+                case unknown
+                case unparsable
+                // TODO: This is @frozen because of a bug in the Xcode 12.2 Swift compiler.
+                // Remove @frozen after Xcode 12.2 support has been dropped.
+            }
+
+            /// Two-letter ISO code representing the country of the card.
+            public private(set) var country: String?
+            /// Two-digit number representing the card’s expiration month.
+            public private(set) var expMonth: Int
+            /// Four-digit number representing the card’s expiration year.
+            public private(set) var expYear: Int
+            /// Card funding type. Can be credit, debit, prepaid, or unknown.
+            public private(set) var funding: String?
+            /// The last four digits of the card.
+            public private(set) var last4: String?
+            /// Uniquely identifies this particular card number. You can use this attribute to check whether two customers who’ve signed up with you are using the same card number, for example.
+            public private(set) var fingerprint: String?
+
+            /// Contains information about card networks that can be used to process the payment.
+            public private(set) var networks: Networks?
+
+            /// Contains details on how this Card maybe be used for 3D Secure authentication.
+            public private(set) var threeDSecureUsage: ThreeDSecureUsage?
+
+            /// If this Card is part of a Card Wallet, this contains the details of the Card Wallet.
+            public private(set) var wallet: Wallet?
+
+            public struct Networks: UnknownFieldsDecodable {
+                public var _allResponseFieldsStorage: NonEncodableParameters?
+
+                /// All available networks for the card.
+                public private(set) var available: [String]?
+                /// The preferred network for the card if one exists.
+                public private(set) var preferred: String?
+            }
+
+            /// Contains details on how a `Card` may be used for 3D Secure authentication.
+            public struct ThreeDSecureUsage: UnknownFieldsDecodable {
+                public var _allResponseFieldsStorage: NonEncodableParameters?
+
+                /// `true` if 3D Secure is supported on this card.
+                public private(set) var supported = false
+            }
+
+            public struct Wallet: UnknownFieldsDecodable {
+                public var _allResponseFieldsStorage: NonEncodableParameters?
+                /// The type of the Card Wallet. A matching property is populated if the type is `.masterpass` or `.visaCheckout` containing additional information specific to the Card Wallet type.
+                public private(set) var type: WalletType = .unknown
+                /// Contains additional Masterpass information, if the type of the Card Wallet is `STPPaymentMethodCardWalletTypeMasterpass`
+                public private(set) var masterpass: Masterpass?
+                /// Contains additional Visa Checkout information, if the type of the Card Wallet is `STPPaymentMethodCardWalletTypeVisaCheckout`
+                public private(set) var visaCheckout: VisaCheckout?
+
+                /// The type of Card Wallet.
+                @frozen public enum WalletType: String, SafeEnumCodable {
+                    /// Amex Express Checkout
+                    case amexExpressCheckout = "amex_express_checkout"
+                    /// Apple Pay
+                    case applePay = "apple_pay"
+                    /// Google Pay
+                    case googlePay = "google_pay"
+                    /// Masterpass
+                    case masterpass = "masterpass"
+                    /// Samsung Pay
+                    case samsungPay = "samsung_pay"
+                    /// Visa Checkout
+                    case visaCheckout = "visa_checkout"
+                    /// An unknown Card Wallet type.
+                    case unknown = "unknown"
+                    case unparsable
+                    // TODO: This is @frozen because of a bug in the Xcode 12.2 Swift compiler.
+                    // Remove @frozen after Xcode 12.2 support has been dropped.
+                }
+
+                public struct Masterpass: UnknownFieldsDecodable {
+                    public var _allResponseFieldsStorage: NonEncodableParameters?
+
+                    /// Owner’s verified email. Values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement.
+                    public private(set) var email: String?
+                    /// Owner’s verified email. Values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement.
+                    public private(set) var name: String?
+                    /// Owner’s verified billing address. Values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement.
+                    public private(set) var billingAddress: BillingDetails.Address?
+                    /// Owner’s verified shipping address. Values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement.
+                    public private(set) var shippingAddress: BillingDetails.Address?
+                }
+
+                /// A Visa Checkout Card Wallet
+                /// - seealso: https://stripe.com/docs/visa-checkout
+                public struct VisaCheckout: UnknownFieldsDecodable {
+                    /// Owner’s verified email. Values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement.
+                    public private(set) var email: String?
+                    /// Owner’s verified email. Values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement.
+                    public private(set) var name: String?
+                    /// Owner’s verified billing address. Values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement.
+                    public private(set) var billingAddress: BillingDetails.Address?
+                    /// Owner’s verified shipping address. Values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement.
+                    public private(set) var shippingAddress: BillingDetails.Address?
+
+                    public var _allResponseFieldsStorage: NonEncodableParameters?
+                }
+            }
+        }
+
+        public var _allResponseFieldsStorage: NonEncodableParameters?
+    }
+}

+ 73 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Models/PaymentMethodParams.swift

@@ -0,0 +1,73 @@
+//
+//  PaymentMethodParams.swift
+//  StripeApplePay
+//
+//  Created by David Estes on 6/29/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+@_spi(STP) import StripeCore
+
+extension StripeAPI {
+    /// An object representing parameters used to create a PaymentMethod object.
+    /// - seealso: https://stripe.com/docs/api/payment_methods/create
+    @_spi(STP) public struct PaymentMethodParams: UnknownFieldsEncodable {
+        /// The type of payment method.
+        /// The associated property will contain additional information (e.g. `type == .card` means `card` should also be populated).
+        @_spi(STP) public var type: PaymentMethod.PaymentMethodType
+
+        /// If this is a card PaymentMethod, this contains the user’s card details.
+        @_spi(STP) public var card: Card?
+
+        /// Billing information associated with the PaymentMethod that may be used or required by particular types of payment methods.
+        @_spi(STP) public var billingDetails: BillingDetails?
+
+        /// Used internally to identify the version of the SDK sending the request
+        @_spi(STP) public var paymentUserAgent: String? = {
+            return PaymentsSDKVariant.paymentUserAgent
+        }()
+
+        /// :nodoc:
+        @_spi(STP) public struct Card: UnknownFieldsEncodable {
+            /// The card number, as a string without any separators. Ex. "4242424242424242"
+            @_spi(STP) public var number: String?
+            /// Number representing the card's expiration month. Ex. 1
+            @_spi(STP) public var expMonth: Int?
+            /// Two- or four-digit number representing the card's expiration year.
+            @_spi(STP) public var expYear: Int?
+            /// For backwards compatibility, you can alternatively set this as a Stripe token (e.g., for Apple Pay)
+            @_spi(STP) public var token: String?
+            /// Card security code. It is highly recommended to always include this value.
+            @_spi(STP) public var cvc: String?
+
+            /// The last 4 digits of the card's number, if it's been set, otherwise nil.
+            @_spi(STP) public var last4: String? {
+                if number != nil && (number?.count ?? 0) >= 4 {
+                    return (number as NSString?)?.substring(from: (number?.count ?? 0) - 4)
+                } else {
+                    return nil
+                }
+            }
+            @_spi(STP) public var _additionalParametersStorage: NonEncodableParameters?
+        }
+
+        @_spi(STP) public var _additionalParametersStorage: NonEncodableParameters?
+    }
+}
+
+extension StripeAPI.PaymentMethodParams.Card: CustomStringConvertible, CustomDebugStringConvertible,
+    CustomLeafReflectable
+{
+    @_spi(STP) public var debugDescription: String {
+        return description
+    }
+
+    @_spi(STP) public var description: String {
+        return "Card \(last4 ?? "")"
+    }
+
+    @_spi(STP) public var customMirror: Mirror {
+        return Mirror(reflecting: self.description)
+    }
+}

+ 58 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Models/SetupIntent.swift

@@ -0,0 +1,58 @@
+//
+//  SetupIntent.swift
+//  StripeApplePay
+//
+//  Created by David Estes on 6/29/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+@_spi(STP) import StripeCore
+
+extension StripeAPI {
+    @_spi(STP) public struct SetupIntent: UnknownFieldsDecodable {
+        @_spi(STP) public let id: String
+        // TODO: (MOBILESDK-467) Add modern bindings for more SetupIntent fields
+        @_spi(STP) public let status: SetupIntentStatus?
+
+        /// Status types for an STPSetupIntent
+        @frozen @_spi(STP) public enum SetupIntentStatus: String, SafeEnumCodable {
+            /// Unknown status
+            case unknown
+            /// This SetupIntent requires a PaymentMethod
+            case requiresPaymentMethod = "requires_payment_method"
+            /// This SetupIntent needs to be confirmed
+            case requiresConfirmation = "requires_confirmation"
+            /// The selected PaymentMethod requires additional authentication steps.
+            /// Additional actions found via the `nextAction` property of `STPSetupIntent`
+            case requiresAction = "requires_action"
+            /// Stripe is processing this SetupIntent
+            case processing
+            /// The SetupIntent has succeeded
+            case succeeded
+            /// This SetupIntent was canceled and cannot be changed.
+            case canceled
+
+            case unparsable
+            // TODO: This is @frozen because of a bug in the Xcode 12.2 Swift compiler.
+            // Remove @frozen after Xcode 12.2 support has been dropped.
+        }
+
+        @_spi(STP) public var _allResponseFieldsStorage: NonEncodableParameters?
+    }
+}
+
+extension StripeAPI.SetupIntent {
+    /// Helper function for extracting SetupIntent id from the Client Secret.
+    /// This avoids having to pass around both the id and the secret.
+    /// - Parameter clientSecret: The `client_secret` from the SetupIntent
+    internal static func id(fromClientSecret clientSecret: String) -> String? {
+        // see parseClientSecret from stripe-js-v3
+        let components = clientSecret.components(separatedBy: "_secret_")
+        if components.count >= 2 && components[0].hasPrefix("seti_") {
+            return components[0]
+        } else {
+            return nil
+        }
+    }
+}

+ 66 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Models/SetupIntentParams.swift

@@ -0,0 +1,66 @@
+//
+//  SetupIntentParams.swift
+//  StripeApplePay
+//
+//  Created by David Estes on 6/29/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+@_spi(STP) import StripeCore
+
+extension StripeAPI {
+    @_spi(STP) public struct SetupIntentConfirmParams: UnknownFieldsEncodable {
+        /// Generated by by Editor -> Refactor -> Generate Memberwise Initializer
+        @_spi(STP) public init(
+            clientSecret: String,
+            paymentMethodData: StripeAPI.PaymentMethodParams? = nil,
+            paymentMethod: String? = nil,
+            returnUrl: String? = nil,
+            useStripeSdk: Bool? = nil,
+            _additionalParametersStorage: NonEncodableParameters? = nil
+        ) {
+            self.clientSecret = clientSecret
+            self.paymentMethodData = paymentMethodData
+            self.paymentMethod = paymentMethod
+            self.returnUrl = returnUrl
+            self.useStripeSdk = useStripeSdk
+            self._additionalParametersStorage = _additionalParametersStorage
+        }
+
+        /// The client secret of the SetupIntent. Required.
+        @_spi(STP) public let clientSecret: String
+        /// Provide a supported `PaymentMethodParams` object, and Stripe will create a
+        /// PaymentMethod during PaymentIntent confirmation.
+        /// @note alternative to `paymentMethodId`
+        @_spi(STP) public var paymentMethodData: PaymentMethodParams?
+        /// Provide an already created PaymentMethod's id, and it will be used to confirm the SetupIntent.
+        /// @note alternative to `paymentMethodParams`
+        @_spi(STP) public var paymentMethod: String?
+        /// The URL to redirect your customer back to after they authenticate or cancel
+        /// their payment on the payment method’s app or site.
+        /// This should probably be a URL that opens your iOS app.
+        @_spi(STP) public var returnUrl: String?
+        /// A boolean number to indicate whether you intend to use the Stripe SDK's functionality to handle any SetupIntent next actions.
+        /// If set to false, SetupIntent.nextAction will only ever contain a redirect url that can be opened in a webview or mobile browser.
+        /// When set to true, the nextAction may contain information that the Stripe SDK can use to perform native authentication within your
+        /// app.
+        @_spi(STP) public var useStripeSdk: Bool?
+
+        @_spi(STP) public var _additionalParametersStorage: NonEncodableParameters?
+
+        // MARK: - Utilities
+        static private let regex = try! NSRegularExpression(
+            pattern: "^seti_[^_]+_secret_[^_]+$",
+            options: []
+        )
+        @_spi(STP) public static func isClientSecretValid(_ clientSecret: String) -> Bool {
+            return
+                (regex.numberOfMatches(
+                    in: clientSecret,
+                    options: .anchored,
+                    range: NSRange(location: 0, length: clientSecret.count)
+                )) == 1
+        }
+    }
+}

+ 93 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Models/ShippingDetails.swift

@@ -0,0 +1,93 @@
+//
+//  ShippingDetails.swift
+//  StripeApplePay
+//
+//  Created by Yuki Tokuhiro on 8/4/22.
+//  Copyright © 2022 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+@_spi(STP) import StripeCore
+
+extension StripeAPI {
+    @_spi(STP) public struct ShippingDetails: UnknownFieldsCodable, Equatable {
+        @_spi(STP) public init(
+            address: StripeAPI.ShippingDetails.Address,
+            name: String,
+            carrier: String? = nil,
+            phone: String? = nil,
+            trackingNumber: String? = nil,
+            _allResponseFieldsStorage: NonEncodableParameters? = nil,
+            _additionalParametersStorage: NonEncodableParameters? = nil
+        ) {
+            self.address = address
+            self.name = name
+            self.carrier = carrier
+            self.phone = phone
+            self.trackingNumber = trackingNumber
+            self._allResponseFieldsStorage = _allResponseFieldsStorage
+            self._additionalParametersStorage = _additionalParametersStorage
+        }
+
+        /// Shipping address.
+        @_spi(STP) public var address: Address
+
+        /// Recipient name.
+        @_spi(STP) public var name: String
+
+        /// The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
+        @_spi(STP) public var carrier: String?
+
+        /// Recipient phone (including extension).
+        @_spi(STP) public var phone: String?
+
+        /// The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
+        @_spi(STP) public var trackingNumber: String?
+
+        @_spi(STP) public var _allResponseFieldsStorage: NonEncodableParameters?
+        @_spi(STP) public var _additionalParametersStorage: NonEncodableParameters?
+
+        @_spi(STP) public struct Address: UnknownFieldsCodable, Equatable {
+            @_spi(STP) public init(
+                city: String? = nil,
+                country: String? = nil,
+                line1: String,
+                line2: String? = nil,
+                postalCode: String? = nil,
+                state: String? = nil,
+                _allResponseFieldsStorage: NonEncodableParameters? = nil,
+                _additionalParametersStorage: NonEncodableParameters? = nil
+            ) {
+                self.city = city
+                self.country = country
+                self.line1 = line1
+                self.line2 = line2
+                self.postalCode = postalCode
+                self.state = state
+                self._allResponseFieldsStorage = _allResponseFieldsStorage
+                self._additionalParametersStorage = _additionalParametersStorage
+            }
+
+            /// City/District/Suburb/Town/Village.
+            @_spi(STP) public var city: String?
+
+            /// Two-letter country code (ISO 3166-1 alpha-2).
+            @_spi(STP) public var country: String?
+
+            /// Address line 1 (Street address/PO Box/Company name).
+            @_spi(STP) public var line1: String
+
+            /// Address line 2 (Apartment/Suite/Unit/Building).
+            @_spi(STP) public var line2: String?
+
+            /// ZIP or postal code.
+            @_spi(STP) public var postalCode: String?
+
+            /// State/County/Province/Region.
+            @_spi(STP) public var state: String?
+
+            @_spi(STP) public var _allResponseFieldsStorage: NonEncodableParameters?
+            @_spi(STP) public var _additionalParametersStorage: NonEncodableParameters?
+        }
+    }
+}

+ 130 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Models/Token.swift

@@ -0,0 +1,130 @@
+//
+//  Token.swift
+//  StripeApplePay
+//
+//  Created by David Estes on 7/14/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+import PassKit
+@_spi(STP) import StripeCore
+
+extension StripeAPI {
+    // Internal note: @_spi(StripeApplePayTokenization) is intended for limited public use. See https://docs.google.com/document/d/1Z9bTUBvDDufoqTaQeI3A0Cxdsoj_D0IkxdWX-GB-RTQ
+    @_spi(StripeApplePayTokenization) public struct Token: UnknownFieldsDecodable {
+        public var _allResponseFieldsStorage: NonEncodableParameters?
+
+        /// The value of the token. You can store this value on your server and use it to make charges and customers.
+        /// - seealso: https://stripe.com/docs/payments/charges-api
+        public let id: String
+        /// Whether or not this token was created in livemode. Will be YES if you used your Live Publishable Key, and NO if you used your Test Publishable Key.
+        var livemode: Bool
+        /// The type of this token.
+        var type: TokenType
+
+        /// Possible Token types
+        enum TokenType: String, SafeEnumCodable {
+            /// Account token type
+            case account
+            /// Bank account token type
+            case bankAccount = "bank_account"
+            /// Card token type
+            case card
+            /// PII token type
+            case PII = "pii"
+            /// CVC update token type
+            case cvcUpdate = "cvc_update"
+            case unparsable
+        }
+
+        /// The credit card details that were used to create the token. Will only be set if the token was created via a credit card or Apple Pay, otherwise it will be
+        /// nil.
+        var card: Card?
+        // /// The bank account details that were used to create the token. Will only be set if the token was created with a bank account, otherwise it will be nil.
+        // Not yet implemented.
+        //    var bankAccount: BankAccount?
+        /// When the token was created.
+        var created: Date?
+
+        struct Card: UnknownFieldsDecodable {
+            var _allResponseFieldsStorage: NonEncodableParameters?
+
+            /// The last 4 digits of the card.
+            var last4: String
+            /// For cards made with Apple Pay, this refers to the last 4 digits of the
+            /// "Device Account Number" for the tokenized card. For regular cards, it will
+            /// be nil.
+            var dynamicLast4: String?
+            /// Whether or not the card originated from Apple Pay.
+            var isApplePayCard: Bool {
+                return (allResponseFields["tokenization_method"] as? String) == "apple_pay"
+            }
+            /// The card's expiration month. 1-indexed (i.e. 1 == January)
+            var expMonth: Int
+            /// The card's expiration year.
+            var expYear: Int
+            /// The cardholder's name.
+            var name: String?
+
+            /// City/District/Suburb/Town/Village.
+            var addressCity: String?
+
+            /// Billing address country, if provided when creating card.
+            var addressCountry: String?
+
+            /// Address line 1 (Street address/PO Box/Company name).
+            var addressLine1: String?
+
+            /// If address_line1 was provided, results of the check.
+            var addressLine1Check: AddressCheck?
+
+            /// Results of an address check.
+            enum AddressCheck: String, SafeEnumCodable {
+                case pass
+                case fail
+                case unavailable
+                case unchecked
+                case unparsable
+            }
+
+            /// Address line 2 (Apartment/Suite/Unit/Building).
+            var addressLine2: String?
+
+            /// State/County/Province/Region.
+            var addressState: String?
+
+            /// ZIP or postal code.
+            var addressZip: String?
+
+            /// If address_zip was provided, results of the check.
+            var addressZipCheck: AddressCheck?
+
+            /// The issuer of the card.
+            var brand: CardBrand = .unknown
+
+            /// The funding source for the card (credit, debit, prepaid, or other)
+            var funding: FundingType = .unknown
+
+            /// The various funding sources for a payment card.
+            enum FundingType: String, SafeEnumCodable {
+                /// Debit card funding
+                case debit
+                /// Credit card funding
+                case credit
+                /// Prepaid card funding
+                case prepaid
+                /// An other or unknown type of funding source.
+                case unknown
+                case unparsable
+            }
+
+            /// Two-letter ISO code representing the issuing country of the card.
+            var country: String?
+            /// This is only applicable when tokenizing debit cards to issue payouts to managed
+            /// accounts. You should not set it otherwise. The card can then be used as a
+            /// transfer destination for funds in this currency.
+            var currency: String?
+        }
+    }
+}

+ 85 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/PaymentIntent+API.swift

@@ -0,0 +1,85 @@
+//
+//  PaymentIntent+API.swift
+//  StripeApplePay
+//
+//  Created by David Estes on 8/10/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+@_spi(STP) import StripeCore
+
+extension StripeAPI.PaymentIntent {
+    /// A callback to be run with a PaymentIntent response from the Stripe API.
+    /// - Parameters:
+    ///   - paymentIntent: The Stripe PaymentIntent from the response. Will be nil if an error occurs. - seealso: PaymentIntent
+    ///   - error: The error returned from the response, or nil if none occurs. - seealso: StripeError.h for possible values.
+    @_spi(STP) public typealias PaymentIntentCompletionBlock = (
+        Result<StripeAPI.PaymentIntent, Error>
+    ) -> Void
+
+    /// Retrieves the PaymentIntent object using the given secret. - seealso: https://stripe.com/docs/api#retrieve_payment_intent
+    /// - Parameters:
+    ///   - secret:      The client secret of the payment intent to be retrieved. Cannot be nil.
+    ///   - completion:  The callback to run with the returned PaymentIntent object, or an error.
+    @_spi(STP) public static func get(
+        apiClient: STPAPIClient = .shared,
+        clientSecret: String,
+        completion: @escaping PaymentIntentCompletionBlock
+    ) {
+        assert(
+            StripeAPI.PaymentIntentParams.isClientSecretValid(clientSecret),
+            "`secret` format does not match expected client secret formatting."
+        )
+        guard let identifier = StripeAPI.PaymentIntent.id(fromClientSecret: clientSecret) else {
+            completion(.failure(StripeError.invalidRequest))
+            return
+        }
+        let endpoint = "\(Resource)/\(identifier)"
+        let parameters: [String: String] = ["client_secret": clientSecret]
+
+        apiClient.get(resource: endpoint, parameters: parameters, completion: completion)
+    }
+
+    /// Confirms the PaymentIntent object with the provided params object.
+    /// At a minimum, the params object must include the `clientSecret`.
+    /// - seealso: https://stripe.com/docs/api#confirm_payment_intent
+    /// @note Use the `confirmPayment:withAuthenticationContext:completion:` method on `PaymentHandler` instead
+    /// of calling this method directly. It handles any authentication necessary for you. - seealso: https://stripe.com/docs/payments/3d-secure
+    /// - Parameters:
+    ///   - paymentIntentParams:  The `PaymentIntentParams` to pass to `/confirm`
+    ///   - completion:           The callback to run with the returned PaymentIntent object, or an error.
+    @_spi(STP) public static func confirm(
+        apiClient: STPAPIClient = .shared,
+        params: StripeAPI.PaymentIntentParams,
+        completion: @escaping PaymentIntentCompletionBlock
+    ) {
+        assert(
+            StripeAPI.PaymentIntentParams.isClientSecretValid(params.clientSecret),
+            "`paymentIntentParams.clientSecret` format does not match expected client secret formatting."
+        )
+
+        guard let identifier = StripeAPI.PaymentIntent.id(fromClientSecret: params.clientSecret)
+        else {
+            completion(.failure(StripeError.invalidRequest))
+            return
+        }
+        let endpoint = "\(Resource)/\(identifier)/confirm"
+
+        let type = params.paymentMethodData?.type.rawValue
+        STPAnalyticsClient.sharedClient.logPaymentIntentConfirmationAttempt(
+            paymentMethodType: type
+        )
+
+        // Add telemetry
+        var paramsWithTelemetry = params
+        if let pmAdditionalParams = paramsWithTelemetry.paymentMethodData?.additionalParameters {
+            paramsWithTelemetry.paymentMethodData?.additionalParameters = STPTelemetryClient.shared
+                .paramsByAddingTelemetryFields(toParams: pmAdditionalParams)
+        }
+
+        apiClient.post(resource: endpoint, object: paramsWithTelemetry, completion: completion)
+    }
+
+    static let Resource = "payment_intents"
+}

+ 61 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/PaymentMethod+API.swift

@@ -0,0 +1,61 @@
+//
+//  PaymentMethod+API.swift
+//  StripeApplePay
+//
+//  Created by David Estes on 8/10/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+import PassKit
+@_spi(STP) import StripeCore
+
+extension StripeAPI.PaymentMethod {
+    /// A callback to be run with a PaymentMethod response from the Stripe API.
+    /// - Parameters:
+    ///   - paymentMethod: The Stripe PaymentMethod from the response. Will be nil if an error occurs. - seealso: PaymentMethod
+    ///   - error: The error returned from the response, or nil if none occurs. - seealso: StripeError.h for possible values.
+    @_spi(STP) public typealias PaymentMethodCompletionBlock = (
+        Result<StripeAPI.PaymentMethod, Error>
+    ) -> Void
+
+    static func create(
+        apiClient: STPAPIClient = .shared,
+        params: StripeAPI.PaymentMethodParams,
+        completion: @escaping PaymentMethodCompletionBlock
+    ) {
+        STPAnalyticsClient.sharedClient.logPaymentMethodCreationAttempt(
+            paymentMethodType: params.type.rawValue
+        )
+        apiClient.post(resource: Resource, object: params, completion: completion)
+    }
+
+    /// Converts a PKPayment object into a Stripe Payment Method using the Stripe API.
+    /// - Parameters:
+    ///   - payment:     The user's encrypted payment information as returned from a PKPaymentAuthorizationController. Cannot be nil.
+    ///   - completion:  The callback to run with the returned Stripe source (and any errors that may have occurred).
+    @_spi(STP) public static func create(
+        apiClient: STPAPIClient = .shared,
+        payment: PKPayment,
+        completion: @escaping PaymentMethodCompletionBlock
+    ) {
+        StripeAPI.Token.create(apiClient: apiClient, payment: payment) { (result) in
+            guard let token = try? result.get() else {
+                if case .failure(let error) = result {
+                    completion(.failure(error))
+                } else {
+                    completion(.failure(NSError.stp_genericConnectionError()))
+                }
+                return
+            }
+            var cardParams = StripeAPI.PaymentMethodParams.Card()
+            cardParams.token = token.id
+            let billingDetails = StripeAPI.BillingDetails(from: payment)
+            var paymentMethodParams = StripeAPI.PaymentMethodParams(type: .card, card: cardParams)
+            paymentMethodParams.billingDetails = billingDetails
+            Self.create(apiClient: apiClient, params: paymentMethodParams, completion: completion)
+        }
+    }
+
+    static let Resource = "payment_methods"
+}

+ 84 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/SetupIntent+API.swift

@@ -0,0 +1,84 @@
+//
+//  SetupIntent+API.swift
+//  StripeApplePay
+//
+//  Created by David Estes on 8/10/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+@_spi(STP) import StripeCore
+
+extension StripeAPI.SetupIntent {
+    /// A callback to be run with a SetupIntent response from the Stripe API.
+    /// - Parameters:
+    ///   - setupIntent: The Stripe SetupIntent from the response. Will be nil if an error occurs. - seealso: SetupIntent
+    ///   - error: The error returned from the response, or nil if none occurs. - seealso: StripeError.h for possible values.
+    @_spi(STP) public typealias SetupIntentCompletionBlock = (Result<StripeAPI.SetupIntent, Error>)
+        -> Void
+
+    /// Retrieves the SetupIntent object using the given secret. - seealso: https://stripe.com/docs/api/setup_intents/retrieve
+    /// - Parameters:
+    ///   - secret:      The client secret of the SetupIntent to be retrieved. Cannot be nil.
+    ///   - completion:  The callback to run with the returned SetupIntent object, or an error.
+    @_spi(STP) public static func get(
+        apiClient: STPAPIClient = .shared,
+        clientSecret: String,
+        completion: @escaping SetupIntentCompletionBlock
+    ) {
+        assert(
+            StripeAPI.SetupIntentConfirmParams.isClientSecretValid(clientSecret),
+            "`secret` format does not match expected client secret formatting."
+        )
+        guard let identifier = StripeAPI.SetupIntent.id(fromClientSecret: clientSecret) else {
+            completion(.failure(StripeError.invalidRequest))
+            return
+        }
+        let endpoint = "\(Resource)/\(identifier)"
+        let parameters: [String: String] = ["client_secret": clientSecret]
+
+        apiClient.get(resource: endpoint, parameters: parameters, completion: completion)
+    }
+
+    /// Confirms the SetupIntent object with the provided params object.
+    /// At a minimum, the params object must include the `clientSecret`.
+    /// - seealso: https://stripe.com/docs/api/setup_intents/confirm
+    /// @note Use the `confirmSetupIntent:withAuthenticationContext:completion:` method on `PaymentHandler` instead
+    /// of calling this method directly. It handles any authentication necessary for you. - seealso: https://stripe.com/docs/payments/3d-secure
+    /// - Parameters:
+    ///   - setupIntentParams:    The `SetupIntentConfirmParams` to pass to `/confirm`
+    ///   - completion:           The callback to run with the returned PaymentIntent object, or an error.
+    @_spi(STP) public static func confirm(
+        apiClient: STPAPIClient = .shared,
+        params: StripeAPI.SetupIntentConfirmParams,
+        completion: @escaping SetupIntentCompletionBlock
+    ) {
+        assert(
+            StripeAPI.SetupIntentConfirmParams.isClientSecretValid(params.clientSecret),
+            "`setupIntentConfirmParams.clientSecret` format does not match expected client secret formatting."
+        )
+
+        guard let identifier = StripeAPI.SetupIntent.id(fromClientSecret: params.clientSecret)
+        else {
+            completion(.failure(StripeError.invalidRequest))
+            return
+        }
+        let endpoint = "\(Resource)/\(identifier)/confirm"
+
+        let type = params.paymentMethodData?.type.rawValue
+        STPAnalyticsClient.sharedClient.logSetupIntentConfirmationAttempt(
+            paymentMethodType: type
+        )
+
+        // Add telemetry
+        var paramsWithTelemetry = params
+        if let pmAdditionalParams = paramsWithTelemetry.paymentMethodData?.additionalParameters {
+            paramsWithTelemetry.paymentMethodData?.additionalParameters = STPTelemetryClient.shared
+                .paramsByAddingTelemetryFields(toParams: pmAdditionalParams)
+        }
+
+        apiClient.post(resource: endpoint, object: paramsWithTelemetry, completion: completion)
+    }
+
+    static let Resource = "setup_intents"
+}

+ 92 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/API/Token+API.swift

@@ -0,0 +1,92 @@
+//
+//  Token+API.swift
+//  StripeApplePay
+//
+//  Created by David Estes on 8/10/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+import PassKit
+@_spi(STP) import StripeCore
+
+extension StripeAPI.Token {
+    /// A callback to be run with a token response from the Stripe API.
+    /// - Parameters:
+    ///   - token: The Stripe token from the response. Will be nil if an error occurs. - seealso: STPToken
+    ///   - error: The error returned from the response, or nil if none occurs. - seealso: StripeError.h for possible values.
+    @_spi(StripeApplePayTokenization) public typealias TokenCompletionBlock = (Result<StripeAPI.Token, Error>) -> Void
+
+    /// Converts a PKPayment object into a Stripe token using the Stripe API.
+    /// - Parameters:
+    ///   - payment:     The user's encrypted payment information as returned from a PKPaymentAuthorizationController. Cannot be nil.
+    ///   - completion:  The callback to run with the returned Stripe token (and any errors that may have occurred).
+    @_spi(StripeApplePayTokenization) public static func create(
+        apiClient: STPAPIClient = .shared,
+        payment: PKPayment,
+        completion: @escaping TokenCompletionBlock
+    ) {
+        // Internal note: @_spi(StripeApplePayTokenization) is intended for limited public use. See https://docs.google.com/document/d/1Z9bTUBvDDufoqTaQeI3A0Cxdsoj_D0IkxdWX-GB-RTQ
+        let params = payment.stp_tokenParameters(apiClient: apiClient)
+        create(
+            apiClient: apiClient,
+            parameters: params,
+            completion: completion
+        )
+    }
+
+    static func create(
+        apiClient: STPAPIClient = .shared,
+        parameters: [String: Any],
+        completion: @escaping TokenCompletionBlock
+    ) {
+        let tokenType = STPAnalyticsClient.tokenType(fromParameters: parameters)
+        var mutableParams = parameters
+        STPTelemetryClient.shared.addTelemetryFields(toParams: &mutableParams)
+        mutableParams = STPAPIClient.paramsAddingPaymentUserAgent(mutableParams)
+        STPAnalyticsClient.sharedClient.logTokenCreationAttempt(tokenType: tokenType)
+        apiClient.post(resource: Resource, parameters: mutableParams, completion: completion)
+        STPTelemetryClient.shared.sendTelemetryData()
+    }
+
+    static let Resource = "tokens"
+}
+
+extension PKPayment {
+    func stp_tokenParameters(apiClient: STPAPIClient) -> [String: Any] {
+        let paymentString = String(data: self.token.paymentData, encoding: .utf8)
+        var payload: [String: Any] = [:]
+        payload["pk_token"] = paymentString
+        if let billingContact = self.billingContact {
+            payload["card"] = billingContact.addressParams
+        }
+
+        assert(
+            !((paymentString?.count ?? 0) == 0
+                && apiClient.publishableKey?.hasPrefix("pk_live") ?? false),
+            "The pk_token is empty. Using Apple Pay with an iOS Simulator while not in Stripe Test Mode will always fail."
+        )
+
+        let paymentInstrumentName = self.token.paymentMethod.displayName
+        if let paymentInstrumentName = paymentInstrumentName {
+            payload["pk_token_instrument_name"] = paymentInstrumentName
+        }
+
+        let paymentNetwork = self.token.paymentMethod.network
+        if let paymentNetwork = paymentNetwork {
+            // Note: As of SDK 20.0.0, this will return `PKPaymentNetwork(_rawValue: MasterCard)`.
+            // We're intentionally leaving it this way: See RUN_MOBILESDK-125.
+            payload["pk_token_payment_network"] = paymentNetwork
+        }
+
+        var transactionIdentifier = self.token.transactionIdentifier
+        if transactionIdentifier != "" {
+            if self.stp_isSimulated() {
+                transactionIdentifier = PKPayment.stp_testTransactionIdentifier()
+            }
+            payload["pk_token_transaction_id"] = transactionIdentifier
+        }
+
+        return payload
+    }
+}

+ 28 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/Analytics/STPAnalyticsClient+Payments.swift

@@ -0,0 +1,28 @@
+//
+//  STPAnalyticsClient+Payments.swift
+//  StripeApplePay
+//
+//  Created by David Estes on 1/24/22.
+//  Copyright © 2022 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+@_spi(STP) import StripeCore
+
+/// An analytic specific to payments that serializes payment-specific
+/// information into its params.
+@_spi(STP) public protocol PaymentAnalytic: Analytic {
+    var productUsage: Set<String> { get }
+    var additionalParams: [String: Any] { get }
+}
+
+@_spi(STP) extension PaymentAnalytic {
+    public var params: [String: Any] {
+        var params = additionalParams
+
+        params["apple_pay_enabled"] = NSNumber(value: StripeAPI.deviceSupportsApplePay())
+        params["ocr_type"] = PaymentsSDKVariant.ocrTypeString
+        params["pay_var"] = PaymentsSDKVariant.variant
+        return params
+    }
+}

+ 72 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/Analytics/STPAnalyticsClient+PaymentsAPI.swift

@@ -0,0 +1,72 @@
+//
+//  STPAnalyticsClient+PaymentsAPI.swift
+//  StripeApplePay
+//
+//  Created by David Estes on 1/21/22.
+//  Copyright © 2022 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+@_spi(STP) import StripeCore
+
+extension STPAnalyticsClient {
+    // MARK: - Log events
+
+    func logPaymentMethodCreationAttempt(paymentMethodType: String?) {
+        log(
+            analytic: PaymentAPIAnalytic(
+                event: .paymentMethodCreation,
+                productUsage: productUsage,
+                additionalParams: [
+                    "source_type": paymentMethodType ?? "unknown"
+                ]
+            )
+        )
+    }
+
+    func logTokenCreationAttempt(tokenType: String?) {
+        log(
+            analytic: PaymentAPIAnalytic(
+                event: .tokenCreation,
+                productUsage: productUsage,
+                additionalParams: [
+                    "token_type": tokenType ?? "unknown"
+                ]
+            )
+        )
+    }
+
+    func logPaymentIntentConfirmationAttempt(
+        paymentMethodType: String?
+    ) {
+        log(
+            analytic: PaymentAPIAnalytic(
+                event: .paymentMethodIntentCreation,
+                productUsage: productUsage,
+                additionalParams: [
+                    "source_type": paymentMethodType ?? "unknown"
+                ]
+            )
+        )
+    }
+
+    func logSetupIntentConfirmationAttempt(
+        paymentMethodType: String?
+    ) {
+        log(
+            analytic: PaymentAPIAnalytic(
+                event: .setupIntentConfirmationAttempt,
+                productUsage: productUsage,
+                additionalParams: [
+                    "source_type": paymentMethodType ?? "unknown"
+                ]
+            )
+        )
+    }
+}
+
+struct PaymentAPIAnalytic: PaymentAnalytic {
+    let event: STPAnalyticEvent
+    let productUsage: Set<String>
+    let additionalParams: [String: Any]
+}

+ 20 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/PaymentsCore/Categories/STPAPIClient+PaymentsCore.swift

@@ -0,0 +1,20 @@
+//
+//  STPAPIClient+PaymentsCore.swift
+//  StripeApplePay
+//
+//  Created by David Estes on 1/25/22.
+//  Copyright © 2022 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+@_spi(STP) import StripeCore
+
+extension STPAPIClient {
+    @_spi(STP) public class func paramsAddingPaymentUserAgent(
+        _ params: [String: Any]
+    ) -> [String: Any] {
+        var newParams = params
+        newParams["payment_user_agent"] = PaymentsSDKVariant.paymentUserAgent
+        return newParams
+    }
+}

+ 10 - 0
Pods/StripeApplePay/StripeApplePay/StripeApplePay/Source/StripeCore+Import.swift

@@ -0,0 +1,10 @@
+//
+//  StripeCore+Import.swift
+//  StripeApplePay
+//
+//  Created by David Estes on 11/15/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+@_exported import StripeCore

+ 21 - 0
Pods/StripeCore/LICENSE

@@ -0,0 +1,21 @@
+The MIT License
+
+Copyright (c) 2011- Stripe, Inc. (https://stripe.com)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 154 - 0
Pods/StripeCore/README.md


파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/bg-BG.lproj/Localizable.strings


+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/ca-ES.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Tanca";
+
+"Scan Card" = "Escanejar targeta";
+
+"Scan card" = "Escanejar targeta";
+
+"The IBAN you entered is invalid." = "L'IBAN és incorrecte.";
+
+"There was an error processing your card -- try again in a few seconds" = "Hi ha hagut un error processant la teva targeta - torna-ho a intentar en uns segons";
+
+"There was an unexpected error -- try again in a few seconds" = "Hi ha hagut un error inesperat - torna-ho a intentar en uns segons";
+
+"Try again" = "Intenta-ho un altre cop";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Emprem Stripe per verificar els detalls de la vostra targeta. És possible que Stripe faci ús i emmagatzemi les dades d'acord amb la política de privadesa. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Més informació</u></a>";
+
+"Your card has expired" = "La teva targeta ha caducat";
+
+"Your card was declined" = "S'ha rebutjat la teva targeta";
+
+"Your card's expiration month is invalid" = "El mes de caducitat de la teva targeta no és vàlid";
+
+"Your card's expiration year is invalid" = "L'any de caducitat de la teva targeta no és vàlid";
+
+"Your card's number is invalid" = "El número de la teva targeta no és vàlid";
+
+"Your card's security code is invalid" = "El codi de seguretat de la teva targeta no és vàlid";
+
+"Your name is invalid." = "El nom no és vàlid.";
+
+"Your payment method was declined." = "S'ha rebutjat el mètode de pagament.";

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/cs-CZ.lproj/Localizable.strings


+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/da.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Luk";
+
+"Scan Card" = "Scan kort";
+
+"Scan card" = "Scan kort";
+
+"The IBAN you entered is invalid." = "Det indtastede IBAN-nummer er ugyldigt.";
+
+"There was an error processing your card -- try again in a few seconds" = "Der opstod en fejl under behandling af dit kort – prøv igen om et par sekunder";
+
+"There was an unexpected error -- try again in a few seconds" = "Der opstod en uventet fejl – prøv igen om et par sekunder";
+
+"Try again" = "Prøv igen";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Vi bruger Stripe til at bekræfte dine kortoplysninger. Stripe kan bruge og gemme dine oplysninger i henhold til selskabets Privatlivspolitik. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Lær mere</u></a>";
+
+"Your card has expired" = "Dit kort er udløbet";
+
+"Your card was declined" = "Dit kort blev afvist";
+
+"Your card's expiration month is invalid" = "Kortets udløbsmåned er ugyldig";
+
+"Your card's expiration year is invalid" = "Kortets udløbsår er ugyldigt";
+
+"Your card's number is invalid" = "Kortnummeret er ugyldigt";
+
+"Your card's security code is invalid" = "Kortets sikkerhedskode er ugyldig";
+
+"Your name is invalid." = "Dit navn er ugyldigt.";
+
+"Your payment method was declined." = "Din betalingsmetode blev afvist.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/de.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Schließen";
+
+"Scan Card" = "Karte scannen";
+
+"Scan card" = "Karte scannen";
+
+"The IBAN you entered is invalid." = "Die eingegebene IBAN ist ungültig.";
+
+"There was an error processing your card -- try again in a few seconds" = "Fehler bei der Verarbeitung Ihrer Karte – versuchen Sie es in ein paar Sekunden noch einmal.";
+
+"There was an unexpected error -- try again in a few seconds" = "Unerwarteter Fehler – versuchen Sie es in ein paar Sekunden noch einmal.";
+
+"Try again" = "Erneut versuchen";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Wir nutzen Stripe, um Ihre Kartenangaben zu verifizieren. Stripe kann im Einklang mit seiner Datenschutzerklärung Ihre Daten verwenden und speichern. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Mehr erfahren</u></a>";
+
+"Your card has expired" = "Ihre Karte ist abgelaufen.";
+
+"Your card was declined" = "Ihre Karte wurde abgelehnt.";
+
+"Your card's expiration month is invalid" = "Der Ablaufmonat Ihrer Karte ist ungültig";
+
+"Your card's expiration year is invalid" = "Das Ablaufjahr Ihrer Karte ist ungültig.";
+
+"Your card's number is invalid" = "Die Kartennummer ist ungültig.";
+
+"Your card's security code is invalid" = "Der Sicherheitscode Ihrer Karte ist ungültig.";
+
+"Your name is invalid." = "Ihr Name ist ungültig.";
+
+"Your payment method was declined." = "Ihre Zahlungsmethode wurde abgelehnt.";

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/el-GR.lproj/Localizable.strings


+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/en-GB.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Close";
+
+"Scan Card" = "Scan Card";
+
+"Scan card" = "Scan card";
+
+"The IBAN you entered is invalid." = "The IBAN you entered is invalid.";
+
+"There was an error processing your card -- try again in a few seconds" = "There was an error processing your card - please try again in a few seconds";
+
+"There was an unexpected error -- try again in a few seconds" = "There was an unexpected error - please try again in a few seconds";
+
+"Try again" = "Try again";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>";
+
+"Your card has expired" = "Your card has expired";
+
+"Your card was declined" = "Your card has been declined";
+
+"Your card's expiration month is invalid" = "Your card's expiry month is invalid";
+
+"Your card's expiration year is invalid" = "Your card's expiry year is invalid";
+
+"Your card's number is invalid" = "Your card's number is invalid";
+
+"Your card's security code is invalid" = "Your card's security code is invalid";
+
+"Your name is invalid." = "Your name is invalid.";
+
+"Your payment method was declined." = "Your payment method was declined.";

+ 48 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/en.lproj/Localizable.strings

@@ -0,0 +1,48 @@
+/* Text for close button */
+"Close" = "Close";
+
+/* Text for button to scan a credit card */
+"Scan Card" = "Scan Card";
+
+/* Button title to open camera to scan credit/debit card */
+"Scan card" = "Scan card";
+
+/* An error message displayed when the customer's iban is invalid. */
+"The IBAN you entered is invalid." = "The IBAN you entered is invalid.";
+
+/* Error when there is a problem processing the credit card */
+"There was an error processing your card -- try again in a few seconds" = "There was an error processing your card -- try again in a few seconds";
+
+/* Unexpected error, such as a 500 from Stripe or a JSON parse error */
+"There was an unexpected error -- try again in a few seconds" = "There was an unexpected error -- try again in a few seconds";
+
+/* Text for a retry button */
+"Try again" = "Try again";
+
+/* Informational text informing the user that Stripe is used to process data and a link to Stripe's privacy policy */
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>";
+
+/* Error when the card has already expired */
+"Your card has expired" = "Your card has expired";
+
+/* Error when the card was declined by the credit card networks */
+"Your card was declined" = "Your card was declined";
+
+/* Error when the card's expiration month is not valid */
+"Your card's expiration month is invalid" = "Your card's expiration month is invalid";
+
+/* Error when the card's expiration year is not valid */
+"Your card's expiration year is invalid" = "Your card's expiration year is invalid";
+
+/* Error when the card number is not valid */
+"Your card's number is invalid" = "Your card's number is invalid";
+
+/* Error when the card's CVC is not valid */
+"Your card's security code is invalid" = "Your card's security code is invalid";
+
+/* Error when customer's name is invalid */
+"Your name is invalid." = "Your name is invalid.";
+
+/* Error message when a payment method gets declined. */
+"Your payment method was declined." = "Your payment method was declined.";
+

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/es-419.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Cerrar";
+
+"Scan Card" = "Escanear tarjeta";
+
+"Scan card" = "Escanear tarjeta";
+
+"The IBAN you entered is invalid." = "El IBAN que ingresaste no es válido.";
+
+"There was an error processing your card -- try again in a few seconds" = "Hubo un error al procesar tu tarjeta. Vuelve a intentar en unos segundos.";
+
+"There was an unexpected error -- try again in a few seconds" = "Se produjo un error inesperado. Vuelve a intentar en unos segundos.";
+
+"Try again" = "Reintentar";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Usamos Stripe para verificar los datos de tu tarjeta. Stripe puede usar y almacenar tus datos de acuerdo con la política de privacidad. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Más información</u></a>";
+
+"Your card has expired" = "Tu tarjeta ha vencido.";
+
+"Your card was declined" = "Tu tarjeta fue rechazada.";
+
+"Your card's expiration month is invalid" = "El mes de vencimiento de tu tarjeta no es válido.";
+
+"Your card's expiration year is invalid" = "El año de vencimiento de tu tarjeta no es válido";
+
+"Your card's number is invalid" = "El número de tarjeta no es válido";
+
+"Your card's security code is invalid" = "El código de seguridad de tu tarjeta no es válido.";
+
+"Your name is invalid." = "El nombre no es válido.";
+
+"Your payment method was declined." = "Tu método de pago fue rechazado.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/es.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Cerrar";
+
+"Scan Card" = "Escanear tarjeta";
+
+"Scan card" = "Escanear tarjeta";
+
+"The IBAN you entered is invalid." = "El IBAN introducido no es válido.";
+
+"There was an error processing your card -- try again in a few seconds" = "Error al procesar la tarjeta. Vuelve a intentarlo en unos segundos.";
+
+"There was an unexpected error -- try again in a few seconds" = "Se ha producido un error inesperado. Vuelve a intentarlo en unos segundos";
+
+"Try again" = "Reintentar";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Usamos Stripe para verificar los datos de tu tarjeta. Stripe puede usar y almacenar tus datos de acuerdo con la política de privacidad. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Más información</a></u>";
+
+"Your card has expired" = "La tarjeta ha caducado";
+
+"Your card was declined" = "La tarjeta ha sido rechazada";
+
+"Your card's expiration month is invalid" = "El mes de caducidad de tu tarjeta no es válido";
+
+"Your card's expiration year is invalid" = "El año de caducidad de tu tarjeta no es válido";
+
+"Your card's number is invalid" = "El número de tarjeta no es válido";
+
+"Your card's security code is invalid" = "El código de seguridad de tu tarjeta no es válido";
+
+"Your name is invalid." = "El nombre no es válido.";
+
+"Your payment method was declined." = "Se ha rechazado tu método de pago.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/et-EE.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Sule";
+
+"Scan Card" = "Skanni kaart";
+
+"Scan card" = "Skanni kaart";
+
+"The IBAN you entered is invalid." = "Sisestatud IBAN on kehtetu.";
+
+"There was an error processing your card -- try again in a few seconds" = "Kaardi töötlemisel esines tõrge – proovige mõne sekundi pärast uuesti";
+
+"There was an unexpected error -- try again in a few seconds" = "Esines ootamatu tõrge – proovige mõne sekundi pärast uuesti";
+
+"Try again" = "Proovi uuesti";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Kasutame teie kaardiandmete kontrollimiseks Stripe'i. Stripe võib teie andmeid kasutada ja säilitada vastavalt oma privaatsuspoliitikale. <a href='https://support.stripe.com/questions/stripes-card-image-verification'>Vaata lähemalt</u></a><u>";
+
+"Your card has expired" = "Kaart on aegunud";
+
+"Your card was declined" = "Kaart lükati tagasi";
+
+"Your card's expiration month is invalid" = "Kaardi aegumiskuu on kehtetu";
+
+"Your card's expiration year is invalid" = "Kaardi aegumisaasta on kehtetu";
+
+"Your card's number is invalid" = "Kaardi number on kehtetu";
+
+"Your card's security code is invalid" = "Kaardi turvakood on kehtetu";
+
+"Your name is invalid." = "Teie nimi on kehtetu.";
+
+"Your payment method was declined." = "Teie makseviis lükati tagasi.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/fi.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Sulje";
+
+"Scan Card" = "Skannaa kortti";
+
+"Scan card" = "Skannaa kortti";
+
+"The IBAN you entered is invalid." = "Antamasi IBAN on virheellinen.";
+
+"There was an error processing your card -- try again in a few seconds" = "Kortin käsittelyssä tapahtui virhe – kokeile uudelleen muutaman sekunnin kuluttua";
+
+"There was an unexpected error -- try again in a few seconds" = "Odottamaton virhe – kokeile uudelleen muutaman sekunnin kuluttua";
+
+"Try again" = "Yritä uudelleen";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Käytämme Stripeä korttitietojen vahvistamiseen. Stripe voi käyttää ja säilyttää tietojasi heidän tietosuojaselosteensa mukaisesti. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Lue lisää</u></a>";
+
+"Your card has expired" = "Korttisi on vanhentunut";
+
+"Your card was declined" = "Korttiasi ei hyväksytty";
+
+"Your card's expiration month is invalid" = "Kortin erääntymiskuukausi ei kelpaa";
+
+"Your card's expiration year is invalid" = "Kortin erääntymisvuosi ei kelpaa";
+
+"Your card's number is invalid" = "Kortin numero ei kelpaa";
+
+"Your card's security code is invalid" = "Kortin turvakoodi ei kelpaa";
+
+"Your name is invalid." = "Nimi on virheellinen.";
+
+"Your payment method was declined." = "Maksutapasi on hylätty.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/fil.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Isara";
+
+"Scan Card" = "I-scan ang kard";
+
+"Scan card" = "I-scan ang kard";
+
+"The IBAN you entered is invalid." = "Ang IBAN na iniligay mo ay imbalido.";
+
+"There was an error processing your card -- try again in a few seconds" = "Nagkaroon ng kamalian sa pagproseso ng iyong kard -- subukin muli sa ilang segundo";
+
+"There was an unexpected error -- try again in a few seconds" = "Nagkaroon ng di-inaasahang kamalian -- subukin muli sa ilang segundo";
+
+"Try again" = "Subukan muli";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Gumagamit kami ng Stripe para i-verify ang mga detalye ng iyong kard. Maaaring gamitin at imbakin ng Stripe ang iyong data ayon sa patakaran sa privacy nito. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Alamin ang higit pa</u></a>";
+
+"Your card has expired" = "Napaso na ang iyong kard";
+
+"Your card was declined" = "Tinanggihan ang iyong kard";
+
+"Your card's expiration month is invalid" = "Ang buwan ng pagkapaso ng iyong kard ay di balido";
+
+"Your card's expiration year is invalid" = "Ang taon ng pagkapaso ng iyong kard ay di balido";
+
+"Your card's number is invalid" = "Ang numero ng iyong kard ay di balido";
+
+"Your card's security code is invalid" = "Ang security code ng iyong kard ay di balido";
+
+"Your name is invalid." = "Ang iyong pangalan ay imbalido.";
+
+"Your payment method was declined." = "Tinanggihan ang iyong paraan ng pagbabayad.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/fr-CA.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Fermer";
+
+"Scan Card" = "Scanner la carte";
+
+"Scan card" = "Scanner la carte";
+
+"The IBAN you entered is invalid." = "L'IBAN que vous avez saisi n'est pas valide.";
+
+"There was an error processing your card -- try again in a few seconds" = "Une erreur est survenue lors du traitement de votre carte. Réessayez dans quelques secondes.";
+
+"There was an unexpected error -- try again in a few seconds" = "Une erreur inattendue est survenue. Réessayez dans quelques secondes.";
+
+"Try again" = "Réessayer";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Nous faisons appel à Stripe pour vérifier les informations de votre carte. Stripe peut utiliser et stocker vos données conformément à sa politique de confidentialité. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>En savoir plus</u></a>";
+
+"Your card has expired" = "Votre carte a expiré";
+
+"Your card was declined" = "Votre carte a été refusée";
+
+"Your card's expiration month is invalid" = "Le mois d'expiration de votre carte n'est pas valide";
+
+"Your card's expiration year is invalid" = "L'année d'expiration de votre carte n'est pas valide";
+
+"Your card's number is invalid" = "Votre numéro de carte n'est pas valide";
+
+"Your card's security code is invalid" = "Le code de sécurité de votre carte n'est pas valide";
+
+"Your name is invalid." = "Votre nom n'est pas valide.";
+
+"Your payment method was declined." = "Votre moyen de paiement a été refusé.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/fr.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Fermer";
+
+"Scan Card" = "Scanner la carte";
+
+"Scan card" = "Scanner la carte";
+
+"The IBAN you entered is invalid." = "L'IBAN que vous avez saisi n'est pas valide.";
+
+"There was an error processing your card -- try again in a few seconds" = "Une erreur est survenue lors du traitement de votre carte. Réessayez dans quelques secondes.";
+
+"There was an unexpected error -- try again in a few seconds" = "Une erreur inattendue est survenue. Réessayez dans quelques secondes.";
+
+"Try again" = "Réessayer";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Nous faisons appel à Stripe pour vérifier les informations de votre carte. Stripe peut utiliser et stocker vos données conformément à sa politique de confidentialité. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>En savoir plus</u></a>";
+
+"Your card has expired" = "Votre carte est arrivée à expiration.";
+
+"Your card was declined" = "Votre carte a été refusée.";
+
+"Your card's expiration month is invalid" = "Le mois d'expiration de votre carte n'est pas valide.";
+
+"Your card's expiration year is invalid" = "L'année d'expiration de votre carte n'est pas valide.";
+
+"Your card's number is invalid" = "Votre numéro de carte n'est pas valide.";
+
+"Your card's security code is invalid" = "Le code de sécurité de votre carte n'est pas valide";
+
+"Your name is invalid." = "Votre nom n'est pas valide.";
+
+"Your payment method was declined." = "Votre moyen de paiement a été refusé.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/hr.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Zatvori";
+
+"Scan Card" = "Skeniraj karticu";
+
+"Scan card" = "Skeniraj karticu";
+
+"The IBAN you entered is invalid." = "Uneseni IBAN nije valjan.";
+
+"There was an error processing your card -- try again in a few seconds" = "Došlo je do pogreške u obradi vaše kartice -- pokušajte ponovno za nekoliko sekundi";
+
+"There was an unexpected error -- try again in a few seconds" = "Došlo je do neočekivane pogreške -- pokušajte ponovno za nekoliko sekundi";
+
+"Try again" = "Pokušajte ponovo";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Koristimo Stripe za provjeru vaših podataka o kartici. Stripe može koristiti i pohranjivati vaše podatke u skladu sa svojim pravilima privatnosti. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Saznajte više</u></a>";
+
+"Your card has expired" = "Vaša kartica je istekla";
+
+"Your card was declined" = "Kartica je odbijena";
+
+"Your card's expiration month is invalid" = "Mjesec isteka kartice nije valjan";
+
+"Your card's expiration year is invalid" = "Godina isteka kartice nije valjana";
+
+"Your card's number is invalid" = "Broj kartice nije valjan";
+
+"Your card's security code is invalid" = "Sigurnosni kod vaše kartice nije valjan";
+
+"Your name is invalid." = "Vaše ime je neispravno.";
+
+"Your payment method was declined." = "Vaš način plaćanja je odbijen.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/hu.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Bezárás";
+
+"Scan Card" = "Kártya beolvasása";
+
+"Scan card" = "Kártya beolvasása";
+
+"The IBAN you entered is invalid." = "A beírt IBAN-szám érvénytelen.";
+
+"There was an error processing your card -- try again in a few seconds" = "Hiba történt kártyája feldolgozása során, próbálja újra néhány másodperc múlva";
+
+"There was an unexpected error -- try again in a few seconds" = "Váratlan hiba lépett fel, próbálja újra néhány másodperc múlva";
+
+"Try again" = "Próbálja újra";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "A Stripe-ot használjuk a kártyájának az ellenőrzésére. A Stripe az adatvédelmi szabályzatának megfelelően használhatja és tárolhatja az Ön adatait. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>További tudnivalók</u></a>";
+
+"Your card has expired" = "A kártyája lejárt";
+
+"Your card was declined" = "A kártyáját elutasítottuk";
+
+"Your card's expiration month is invalid" = "Kártyájának lejárati hónapja érvénytelen";
+
+"Your card's expiration year is invalid" = "A kártyája lejárati éve érvénytelen";
+
+"Your card's number is invalid" = "Kártyaszáma érvénytelen";
+
+"Your card's security code is invalid" = "Kártyájának biztonsági kódja érvénytelen";
+
+"Your name is invalid." = "Érvénytelen név.";
+
+"Your payment method was declined." = "Fizetési módja elutasításra került.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/id.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Tutup";
+
+"Scan Card" = "Pindai Kartu";
+
+"Scan card" = "Pindai kartu";
+
+"The IBAN you entered is invalid." = "IBAN yang Anda masukkan tidak valid.";
+
+"There was an error processing your card -- try again in a few seconds" = "Ada kesalahan saat memproses kartu Anda -- cobalah lagi dalam beberapa detik";
+
+"There was an unexpected error -- try again in a few seconds" = "Ada kesalahan tak terduga -- cobalah lagi dalam beberapa detik";
+
+"Try again" = "Coba lagi";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Kami menggunakan Stripe untuk memverifikasi detail kartu Anda. Stripe mungkin menggunakan dan menyimpan data Anda sesuai dengan kebijakan privasi mereka. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Pelajari selengkapnya</u></a>";
+
+"Your card has expired" = "Kartu Anda telah kedaluwarsa";
+
+"Your card was declined" = "Kartu Anda ditolak";
+
+"Your card's expiration month is invalid" = "Bulan kedaluwarsa kartu Anda tidak valid";
+
+"Your card's expiration year is invalid" = "Tahun kedaluwarsa kartu Anda tidak valid";
+
+"Your card's number is invalid" = "Nomor kartu Anda tidak valid";
+
+"Your card's security code is invalid" = "Kode keamanan kartu Anda tidak valid";
+
+"Your name is invalid." = "Nama Anda tidak valid.";
+
+"Your payment method was declined." = "Metode pembayaran Anda ditolak.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/it.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Chiudi";
+
+"Scan Card" = "Scansiona carta";
+
+"Scan card" = "Scansiona carta";
+
+"The IBAN you entered is invalid." = "L'IBAN inserito non è valido.";
+
+"There was an error processing your card -- try again in a few seconds" = "Si è verificato un errore durante l'elaborazione della carta. Riprova fra qualche secondo.";
+
+"There was an unexpected error -- try again in a few seconds" = "Si è verificato un errore imprevisto. Riprova fra qualche secondo.";
+
+"Try again" = "Riprova";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Utilizziamo Stripe per verificare i dati della carta. Come stabilito nella sua informativa sulla privacy, Stripe può utilizzare e conservare i tuoi dati. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Ulteriori informazioni</u></a>";
+
+"Your card has expired" = "La carta è scaduta";
+
+"Your card was declined" = "La carta è stata rifiutata";
+
+"Your card's expiration month is invalid" = "Il mese di scadenza della carta non è valido";
+
+"Your card's expiration year is invalid" = "L'anno di scadenza della carta non è valido";
+
+"Your card's number is invalid" = "Il numero della carta non è valido";
+
+"Your card's security code is invalid" = "Il codice di sicurezza della carta non è valido";
+
+"Your name is invalid." = "Nome non valido.";
+
+"Your payment method was declined." = "La tua modalità di pagamento è stata rifiutata.";

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/ja.lproj/Localizable.strings


+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/ko.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "닫기";
+
+"Scan Card" = "카드 스캔";
+
+"Scan card" = "카드 스캔";
+
+"The IBAN you entered is invalid." = "입력한 IBAN이 잘못되었습니다.";
+
+"There was an error processing your card -- try again in a few seconds" = "카드를 처리하는 동안 오류가 발생했습니다. 몇 초 후에 다시 시도하십시오.";
+
+"There was an unexpected error -- try again in a few seconds" = "예기치 않은 오류가 발생했습니다. 몇 초 후에 다시 시도하십시오.";
+
+"Try again" = "다시 시도";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Stripe를 통해 카드 세부사항을 확인합니다. Stripe에서 자사 개인정보정책에 따라 귀하의 데이터를 사용하고 저장할 수 있습니다. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>자세히 알아보기</u></a>";
+
+"Your card has expired" = "카드가 만료되었습니다";
+
+"Your card was declined" = "카드가 거절되었습니다";
+
+"Your card's expiration month is invalid" = "카드의 만료 월이 유효하지 않습니다";
+
+"Your card's expiration year is invalid" = "카드의 만료 연도가 유효하지 않습니다";
+
+"Your card's number is invalid" = "카드 번호가 유효하지 않습니다";
+
+"Your card's security code is invalid" = "카드의 보안 코드가 유효하지 않습니다";
+
+"Your name is invalid." = "이름이 잘못되었습니다.";
+
+"Your payment method was declined." = "결제 방식이 거부되었습니다.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/lt-LT.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Užverti";
+
+"Scan Card" = "Skenuoti kortelę";
+
+"Scan card" = "Nuskaityti kortelę";
+
+"The IBAN you entered is invalid." = "Įvedėte neteisingą IBAN.";
+
+"There was an error processing your card -- try again in a few seconds" = "Įvyko kortelės apdorojimo klaida, po kelių sekundžių bandykite dar kartą";
+
+"There was an unexpected error -- try again in a few seconds" = "Įvyko netikėta klaida, po kelių sekundžių bandykite dar kartą";
+
+"Try again" = "Bandyti dar kartą";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Naudojame „Stripe“, kad patikrintume jūsų kortelės duomenis. „Stripe“ gali naudoti ir saugoti jūsų duomenis pagal savo privatumo politiką. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Sužinokite daugiau</u></a>";
+
+"Your card has expired" = "Kortelė baigė galioti";
+
+"Your card was declined" = "Kortelė buvo atmesta";
+
+"Your card's expiration month is invalid" = "Negaliojantis kortelės galiojimo pabaigos mėnuo";
+
+"Your card's expiration year is invalid" = "Kortelės galiojimo pabaigos metai neteisingi";
+
+"Your card's number is invalid" = "Negaliojantis kortelės numeris";
+
+"Your card's security code is invalid" = "Kortelės saugos kodas negalioja";
+
+"Your name is invalid." = "Jūsų vardas neteisingas.";
+
+"Your payment method was declined." = "Jūsų mokėjimo būdas buvo atmestas.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/lv-LV.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Aizvērt";
+
+"Scan Card" = "Skenēt karti";
+
+"Scan card" = "Skenēt karti";
+
+"The IBAN you entered is invalid." = "Ievadītais IBAN nav derīgs.";
+
+"There was an error processing your card -- try again in a few seconds" = "Radās kļūda, apstrādājot jūsu karti — mēģiniet vēlreiz pēc dažām sekundēm";
+
+"There was an unexpected error -- try again in a few seconds" = "Radusies negaidīta kļūda — mēģiniet vēlreiz pēc dažām sekundēm";
+
+"Try again" = "Mēģināt vēlreiz";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Mēs izmantojam Stripe, lai verificētu jūsu kartes informāciju. Stripe var izmantot un uzglabāt jūsu datus saskaņā ar konfidencialitātes politiku. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Uzzināt vairāk</u></a>";
+
+"Your card has expired" = "Kartes derīguma termiņš ir beidzies";
+
+"Your card was declined" = "Karte tika noraidīta";
+
+"Your card's expiration month is invalid" = "Kartes derīguma termiņa mēnesis nav derīgs";
+
+"Your card's expiration year is invalid" = "Kartes derīguma termiņa gads nav derīgs";
+
+"Your card's number is invalid" = "Kartes numurs nav derīgs";
+
+"Your card's security code is invalid" = "Kartes drošības kods nav derīgs";
+
+"Your name is invalid." = "Jūsu vārds nav derīgs.";
+
+"Your payment method was declined." = "Maksājuma veids tika noraidīts.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/ms-MY.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Tutup";
+
+"Scan Card" = "Imbas Kad";
+
+"Scan card" = "Imbas kad";
+
+"The IBAN you entered is invalid." = "IBAN yang anda masukkan tidak sah.";
+
+"There was an error processing your card -- try again in a few seconds" = "Ada ralat semasa memproses kad anda -- cuba lagi dalam masa beberapa saat";
+
+"There was an unexpected error -- try again in a few seconds" = "Ada ralat yang tidak dijangka -- cuba lagi dalam masa beberapa saat";
+
+"Try again" = "Cuba lagi";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Kami menggunakan Stripe untuk mengesahkan butiran kad anda. Stripe mungkin menggunakan dan menyimpan data anda menurut dasar privasi Stripe. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Ketahui selanjutnya</u></a>";
+
+"Your card has expired" = "Kad anda telah tamat tempoh";
+
+"Your card was declined" = "Kad anda telah ditolak";
+
+"Your card's expiration month is invalid" = "Bulan tamat tempoh kad anda tidak sah";
+
+"Your card's expiration year is invalid" = "Tahun tamat tempoh kad anda tidak sah";
+
+"Your card's number is invalid" = "Nombor kad anda tidak sah";
+
+"Your card's security code is invalid" = "Kod keselamatan kad anda tidak sah";
+
+"Your name is invalid." = "Nama anda tidak sah.";
+
+"Your payment method was declined." = "Kaedah pembayaran anda ditolak.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/mt.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Agħlaq";
+
+"Scan Card" = "Skennja l-Kard";
+
+"Scan card" = "Skennja l-karta";
+
+"The IBAN you entered is invalid." = "L-IBAN li daħħalt mhux tajjeb.";
+
+"There was an error processing your card -- try again in a few seconds" = "Kien hemm żball fl-ipproċessar tal-kard tiegħek -- erġa' pprova wara ftit sekondi";
+
+"There was an unexpected error -- try again in a few seconds" = "Kien hemm żball mhux mistenni -- erġa' pprova wara ftit sekondi";
+
+"Try again" = "Erġa' pprova";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Aħna naħdmu ma' Stripe biex nivverifikaw id-dettalji tal-karta tiegħek. Stripe tista' tuża u taħżen id-dejta tiegħek skont il-politika tal-privatezza tagħha. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Sir af iktar</u></a>";
+
+"Your card has expired" = "Il-kard tiegħek skadiet";
+
+"Your card was declined" = "Il-kard tiegħek ma ġietx aċċettata";
+
+"Your card's expiration month is invalid" = "Ix-xahar tal-iskadenza tal-kard tiegħek mhux validu";
+
+"Your card's expiration year is invalid" = "Is-sena tal-iskadenza tal-kard tiegħek mhijiex valida";
+
+"Your card's number is invalid" = "In-numru tal-kard tiegħek mhux validu";
+
+"Your card's security code is invalid" = "Il-kodiċi tas-sigurtà tal-kard tiegħek mhux validu";
+
+"Your name is invalid." = "L-isem li daħħalt mhux tajjeb.";
+
+"Your payment method was declined." = "Il-metodu tal-pagament tiegħek m'għaddiex.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/nb.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Lukk";
+
+"Scan Card" = "Skann kort";
+
+"Scan card" = "Skann kort";
+
+"The IBAN you entered is invalid." = "IBAN-nummeret du la inn er ugyldig.";
+
+"There was an error processing your card -- try again in a few seconds" = "Det oppstod en feil ved prosessering av kortet -- prøv igjen om et par sekunder";
+
+"There was an unexpected error -- try again in a few seconds" = "En uventet feil har oppstått -- prøv igjen om et par sekunder";
+
+"Try again" = "Prøv igjen";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Vi bruker Stripe til å verifisere kontoopplysningene. Stripe kan bruke og lagre opplysningene dine i henhold til personvernerklæringen sin. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Finn ut mer</u></a>";
+
+"Your card has expired" = "Kortet ditt har utløpt";
+
+"Your card was declined" = "Kortet ditt ble avvist";
+
+"Your card's expiration month is invalid" = "Kortet sin utløpsmåned er ugyldig";
+
+"Your card's expiration year is invalid" = "Kortet sitt utløpsår er ugyldig";
+
+"Your card's number is invalid" = "Ugyldig kortnummer";
+
+"Your card's security code is invalid" = "Ugyldig sikkerhetskode";
+
+"Your name is invalid." = "Navnet er ugyldig.";
+
+"Your payment method was declined." = "Betalingsmetoden din ble avvist.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/nl.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Sluiten";
+
+"Scan Card" = "Kaart scannen";
+
+"Scan card" = "Betaalkaart scannen";
+
+"The IBAN you entered is invalid." = "Het opgegeven IBAN-nummer is ongeldig.";
+
+"There was an error processing your card -- try again in a few seconds" = "Er is een fout met de verwerking van je kaart. Probeer het over enkele seconden opnieuw";
+
+"There was an unexpected error -- try again in a few seconds" = "Er is een onverwachte fout opgetreden. Probeer het over enkele seconden opnieuw";
+
+"Try again" = "Opnieuw proberen";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "We gebruiken Stripe om je kaartgegevens te verifiëren. Stripe kan je gegevens gebruiken en bewaren volgens hun privacybeleid. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Meer informatie</u></a>";
+
+"Your card has expired" = "Je kaart is vervallen";
+
+"Your card was declined" = "Je kaart is geweigerd";
+
+"Your card's expiration month is invalid" = "De vervalmaand van je kaart is ongeldig";
+
+"Your card's expiration year is invalid" = "Het vervaljaar van je kaart is ongeldig";
+
+"Your card's number is invalid" = "Je kaartnummer is ongeldig";
+
+"Your card's security code is invalid" = "De beveiligingscode van je kaart is ongeldig";
+
+"Your name is invalid." = "Je naam is ongeldig.";
+
+"Your payment method was declined." = "Je betaalmethode is geweigerd.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/nn-NO.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Lukk";
+
+"Scan Card" = "Skann kortet";
+
+"Scan card" = "Skann kort";
+
+"The IBAN you entered is invalid." = "Du skreiv inn eit ugyldig IBAN-nummer.";
+
+"There was an error processing your card -- try again in a few seconds" = "Det oppstod ei feil under behandlinga av kortet – prøv igjen om nokre få sekund";
+
+"There was an unexpected error -- try again in a few seconds" = "Det oppstod ein uventa feil – prøv igjen om nokre få sekund";
+
+"Try again" = "Prøv igjen";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Vi brukar Stripe til å verifisere kortdetaljane dine. Stripe kan bruke og lagre dataa dine i samsvar med personvernerklæringa deira. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Finn ut meir</u></a>";
+
+"Your card has expired" = "Kortet har gått ut";
+
+"Your card was declined" = "Kortet vart avvist";
+
+"Your card's expiration month is invalid" = "Utløpsmånaden på kortet er ugyldig";
+
+"Your card's expiration year is invalid" = "Utløpsåret på kortet ditt er ugyldig";
+
+"Your card's number is invalid" = "Kortnummeret ditt er ugyldig";
+
+"Your card's security code is invalid" = "Sikkerheitskoden til kortet er ugyldig";
+
+"Your name is invalid." = "Namnet ditt er ugyldig.";
+
+"Your payment method was declined." = "Betalingsmåten din vart avvist.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/pl-PL.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Zamknij";
+
+"Scan Card" = "Skanuj kartę";
+
+"Scan card" = "Skanuj kartę";
+
+"The IBAN you entered is invalid." = "Podany IBAN jest nieprawidłowy.";
+
+"There was an error processing your card -- try again in a few seconds" = "Podczas przetwarzania Twojej karty wystąpił błąd – spróbuj ponownie za kilka sekund";
+
+"There was an unexpected error -- try again in a few seconds" = "Wystąpił nieoczekiwany błąd – spróbuj ponownie za kilka sekund";
+
+"Try again" = "Spróbuj ponownie";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Korzystamy ze Stripe, aby weryfikować szczegóły Twojej karty. Stripe może używać Twoich danych i przechowywać je zgodnie ze swoją polityką prywatności. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Dowiedz się więcej</u></a>";
+
+"Your card has expired" = "Ważność Twojej karty wygasła";
+
+"Your card was declined" = "Karta została odrzucona";
+
+"Your card's expiration month is invalid" = "Miesiąc daty ważności karty jest nieprawidłowy.";
+
+"Your card's expiration year is invalid" = "Rok daty ważności karty jest nieprawidłowy";
+
+"Your card's number is invalid" = "Numer Twojej karty jest nieprawidłowy";
+
+"Your card's security code is invalid" = "Kod bezpieczeństwa karty jest nieprawidłowy";
+
+"Your name is invalid." = "Twoje imię i nazwisko jest nieprawidłowe.";
+
+"Your payment method was declined." = "Twoja metoda płatności została odrzucona.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/pt-BR.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Fechar";
+
+"Scan Card" = "Digitalizar cartão";
+
+"Scan card" = "Ler cartão";
+
+"The IBAN you entered is invalid." = "O IBAN inserido é inválido.";
+
+"There was an error processing your card -- try again in a few seconds" = "Erro ao processar o cartão – tente novamente em alguns segundos";
+
+"There was an unexpected error -- try again in a few seconds" = "Erro inesperado – tente novamente em alguns segundos";
+
+"Try again" = "Tentar novamente";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Usamos a Stripe para verificar os dados do seu cartão. A Stripe pode usar e armazenar seus dados de acordo com a política de privacidade da empresa. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Saiba mais</u></a>";
+
+"Your card has expired" = "O cartão expirou";
+
+"Your card was declined" = "O cartão foi recusado";
+
+"Your card's expiration month is invalid" = "O mês de expiração doi cartão é inválido";
+
+"Your card's expiration year is invalid" = "O ano de expiração do cartão é inválido";
+
+"Your card's number is invalid" = "O número do cartão é inválido";
+
+"Your card's security code is invalid" = "O código de segurança do cartão é inválido";
+
+"Your name is invalid." = "Nome inválido.";
+
+"Your payment method was declined." = "A forma de pagamento foi recusada.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/pt-PT.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Fechar";
+
+"Scan Card" = "Ler cartão";
+
+"Scan card" = "Ler cartão";
+
+"The IBAN you entered is invalid." = "O IBAN que introduziu é inválido.";
+
+"There was an error processing your card -- try again in a few seconds" = "Ocorreu um erro ao processar o seu cartão -- tente novamente dentro de alguns segundos";
+
+"There was an unexpected error -- try again in a few seconds" = "Ocorreu um erro inesperado -- tente novamente dentro de alguns segundos";
+
+"Try again" = "Tentar novamente";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Utilizamos a Stripe para verificar os detalhes do seu cartão. A Stripe pode utilizar e armazenar os seus dados de acordo com a sua política de privacidade. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Saiba mais</u></a>";
+
+"Your card has expired" = "O seu cartão expirou";
+
+"Your card was declined" = "O seu cartão foi recusado";
+
+"Your card's expiration month is invalid" = "O mês de validade do seu cartão é inválido";
+
+"Your card's expiration year is invalid" = "O ano de validade do seu cartão é inválido";
+
+"Your card's number is invalid" = "O número do seu cartão é inválido";
+
+"Your card's security code is invalid" = "O código de segurança do seu cartão é inválido";
+
+"Your name is invalid." = "O seu nome é inválido.";
+
+"Your payment method was declined." = "O seu método de pagamento foi recusado.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/ro-RO.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Închidere";
+
+"Scan Card" = "Scanare card";
+
+"Scan card" = "Scanare card";
+
+"The IBAN you entered is invalid." = "Codul IBAN pe care l-ați introdus nu este valid.";
+
+"There was an error processing your card -- try again in a few seconds" = "A apărut o eroare la procesarea cardului dvs. -- încercați din nou în câteva secunde";
+
+"There was an unexpected error -- try again in a few seconds" = "A apărut o eroare neașteptată -- încercați din nou în câteva secunde";
+
+"Try again" = "Încercați din nou";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Folosim Stripe pentru a verifica detaliile cardului dvs. Stripe poate utiliza și stoca datele dvs. în conformitate cu politica sa de confidențialitate. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Aflați mai multe</u></a>";
+
+"Your card has expired" = "Cardul dvs. a expirat";
+
+"Your card was declined" = "Cardul dvs. a fost respins";
+
+"Your card's expiration month is invalid" = "Luna de expirare a cardului dvs. nu este validă";
+
+"Your card's expiration year is invalid" = "Anul de expirare al cardului dvs. nu este valid";
+
+"Your card's number is invalid" = "Numărul cardului dvs. nu este valid";
+
+"Your card's security code is invalid" = "Codul de securitate al cardului dvs. nu este valid";
+
+"Your name is invalid." = "Numele dvs. nu este valid.";
+
+"Your payment method was declined." = "Metoda dvs. de plată a fost respinsă.";

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/ru.lproj/Localizable.strings


파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/sk-SK.lproj/Localizable.strings


+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/sl-SI.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Zapri";
+
+"Scan Card" = "Optično preberi kartico";
+
+"Scan card" = "Optično preberi kartico";
+
+"The IBAN you entered is invalid." = "Vnesena koda IBAN ni veljavna.";
+
+"There was an error processing your card -- try again in a few seconds" = "Pri obdelavi vaše kartice je prišlo do napake. Poskusite znova čez nekaj sekund.";
+
+"There was an unexpected error -- try again in a few seconds" = "Prišlo je do nepričakovane napake. Poskusite znova čez nekaj sekund.";
+
+"Try again" = "Poskusi znova";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Za preverjanje podatkov o vaši kartici uporabljamo storitev Stripe. Stripe lahko vaše podatke uporablja in hrani v skladu s svojim pravilnikom o zasebnosti. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Več informacij</u></a>";
+
+"Your card has expired" = "Vaša kartica je potekla";
+
+"Your card was declined" = "Vaša kartica je bila zavrnjena";
+
+"Your card's expiration month is invalid" = "Mesec poteka vaše kartice ni veljaven";
+
+"Your card's expiration year is invalid" = "Leto poteka vaše kartice ni veljavno";
+
+"Your card's number is invalid" = "Številka vaše kartice ni veljavna";
+
+"Your card's security code is invalid" = "Varnostna koda vaše kartice ni veljavna";
+
+"Your name is invalid." = "Vaše ime ni veljavno.";
+
+"Your payment method was declined." = "Vaš način plačila je bil zavrnjen.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/sv.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Stäng";
+
+"Scan Card" = "Skanna kort";
+
+"Scan card" = "Skanna kort";
+
+"The IBAN you entered is invalid." = "Angivet IBAN är ogiltigt.";
+
+"There was an error processing your card -- try again in a few seconds" = "Ett fel uppstod vid behandlingen av ditt kort - försök igen om ett par sekunder";
+
+"There was an unexpected error -- try again in a few seconds" = "Ett oväntat fel uppstod - försök igen om ett par sekunder";
+
+"Try again" = "Försök igen";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Vi använder Stripe för att verifiera dina kortuppgifter. Stripe kan komma att använda och lagra dina uppgifter i enlighet med sin integritetspolicy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Läs mer</u></a>";
+
+"Your card has expired" = "Kortet har löpt ut";
+
+"Your card was declined" = "Ditt kort nekades";
+
+"Your card's expiration month is invalid" = "Kortets utgångsmånad är ogiltig";
+
+"Your card's expiration year is invalid" = "Kortets utgångsår är ogiltigt";
+
+"Your card's number is invalid" = "Kortnumret är ogiltigt";
+
+"Your card's security code is invalid" = "Kortets säkerhetskod är ogiltig";
+
+"Your name is invalid." = "Ditt namn är ogiltigt.";
+
+"Your payment method was declined." = "Din betalningsmetod godkändes inte.";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/tr.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "Kapat";
+
+"Scan Card" = "Kartı Tara";
+
+"Scan card" = "Kartı tara";
+
+"The IBAN you entered is invalid." = "Girdiğiniz IBAN geçersiz.";
+
+"There was an error processing your card -- try again in a few seconds" = "Kartınızla işlem yapılırken bir hata oluştu -- birazdan tekrar deneyin";
+
+"There was an unexpected error -- try again in a few seconds" = "Beklenmedik bir hata oluştu -- birazdan tekrar deneyin";
+
+"Try again" = "Tekrar dene";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "Kart bilgilerinizi doğrulamak için Stripe kullanıyoruz. Stripe verilerinizi gizlilik politikasına uygun şekilde kullanabilir ve saklayabilir.<a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Daha fazlasını öğrenin</u></a>";
+
+"Your card has expired" = "Kartınızın kullanım süresi dolmuş";
+
+"Your card was declined" = "Kartınız reddedildi";
+
+"Your card's expiration month is invalid" = "Kartınızın son kullanma ayı geçersiz";
+
+"Your card's expiration year is invalid" = "Kartınızın son kullanma yılı geçersiz";
+
+"Your card's number is invalid" = "Kart numaranız geçersiz";
+
+"Your card's security code is invalid" = "Kartınızın güvenlik kodu geçersiz";
+
+"Your name is invalid." = "Adınız geçersiz.";
+
+"Your payment method was declined." = "Ödeme yönteminiz reddedildi.";

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/vi.lproj/Localizable.strings


+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/zh-HK.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "關閉";
+
+"Scan Card" = "掃描銀行卡";
+
+"Scan card" = "掃描卡";
+
+"The IBAN you entered is invalid." = "您輸入的 IBAN 無效。";
+
+"There was an error processing your card -- try again in a few seconds" = "處理您的卡時發生了錯誤 -- 請稍候再試";
+
+"There was an unexpected error -- try again in a few seconds" = "發生了意外錯誤 -- 請稍候再試";
+
+"Try again" = "重試";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "我們用 Stripe 來驗證您的銀行卡資訊。Stripe 可能會根據其私隱政策使用並存儲您的資料。<a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>瞭解更多</u></a>";
+
+"Your card has expired" = "您的卡已過期";
+
+"Your card was declined" = "您的卡已被拒絕";
+
+"Your card's expiration month is invalid" = "您的銀行卡的到期月份無效";
+
+"Your card's expiration year is invalid" = "您的銀行卡的到期年份無效";
+
+"Your card's number is invalid" = "您的卡號無效";
+
+"Your card's security code is invalid" = "您的銀行卡的安全碼無效";
+
+"Your name is invalid." = "您的姓名無效。";
+
+"Your payment method was declined." = "您的支付方式被拒絕了。";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/zh-Hans.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "关闭";
+
+"Scan Card" = "扫描银行卡";
+
+"Scan card" = "扫描卡";
+
+"The IBAN you entered is invalid." = "您输入的 IBAN 无效。";
+
+"There was an error processing your card -- try again in a few seconds" = "处理您的卡时发生错误 —— 请稍后再试";
+
+"There was an unexpected error -- try again in a few seconds" = "发生了意外错误 —— 请过几秒钟再试";
+
+"Try again" = "重试";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "我们用 Stripe 来验证您的银行卡信息。Stripe 可能会根据其隐私政策使用并存储您的数据。<a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>了解更多</u></a>";
+
+"Your card has expired" = "您的银行卡已过期";
+
+"Your card was declined" = "您的卡已被拒绝";
+
+"Your card's expiration month is invalid" = "您银行卡有效期的月份无效";
+
+"Your card's expiration year is invalid" = "您的银行卡的到期年份无效。";
+
+"Your card's number is invalid" = "您的卡号无效";
+
+"Your card's security code is invalid" = "您的银行卡的安全码无效";
+
+"Your name is invalid." = "您的姓名无效。";
+
+"Your payment method was declined." = "您的支付方式被拒绝了。";

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Resources/Localizations/zh-Hant.lproj/Localizable.strings

@@ -0,0 +1,31 @@
+"Close" = "關閉";
+
+"Scan Card" = "掃描金融卡";
+
+"Scan card" = "掃描卡";
+
+"The IBAN you entered is invalid." = "您輸入的 IBAN 無效。";
+
+"There was an error processing your card -- try again in a few seconds" = "處理您的卡時發生錯誤 -- 請等待幾秒後再試";
+
+"There was an unexpected error -- try again in a few seconds" = "發生了意外錯誤 -- 請等待幾秒後再試一次";
+
+"Try again" = "重試";
+
+"We use Stripe to verify your card details. Stripe may use and store your data according its privacy policy. <a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>Learn more</u></a>" = "我們用 Stripe 來驗證您的金融卡資訊。Stripe 可能會根據其隱私政策使用並存儲您的資料。<a href='https://support.stripe.com/questions/stripes-card-image-verification'><u>瞭解更多</u></a>";
+
+"Your card has expired" = "您的卡已過期";
+
+"Your card was declined" = "您的卡已被拒絕";
+
+"Your card's expiration month is invalid" = "您的金融卡的到期月份無效";
+
+"Your card's expiration year is invalid" = "您的金融卡的到期年份無效";
+
+"Your card's number is invalid" = "您的卡號無效";
+
+"Your card's security code is invalid" = "您的金融卡的安全碼無效";
+
+"Your name is invalid." = "您的名稱無效。";
+
+"Your payment method was declined." = "您的支付方式被拒絕了。";

+ 14 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/Models/EmptyResponse.swift

@@ -0,0 +1,14 @@
+//
+//  EmptyResponse.swift
+//  StripeCore
+//
+//  Created by Jaime Park on 11/19/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+
+/// This is an object representing an empty response from a request.
+@_spi(STP) public struct EmptyResponse: UnknownFieldsDecodable {
+    public var _allResponseFieldsStorage: NonEncodableParameters?
+}

+ 45 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/Models/StripeFile.swift

@@ -0,0 +1,45 @@
+//
+// StripeFile.swift
+//
+// Generated by swagger-codegen
+// https://github.com/swagger-api/swagger-codegen
+//
+
+import Foundation
+
+/// This is an object representing a file hosted on Stripe's servers.
+///
+/// The file may have been uploaded by yourself using the
+/// [create file](https://stripe.com/docs/api#create_file) request
+/// (for example, when uploading dispute evidence) or it may have been created by Stripe
+/// (for example, the results of a [Sigma scheduled query](#scheduled_queries)).
+/// Related guide: [File Upload Guide](https://stripe.com/docs/file-upload).
+@_spi(STP) public struct StripeFile: UnknownFieldsDecodable, Equatable {
+    @frozen public enum Purpose: String, SafeEnumCodable, Equatable {
+        // NOTE: If adding cases here that should also be available to the
+        // public API, please also add to `STPFilePurpose`. This is not
+        // necessary for cases that are only used internally.
+
+        /// Dispute evidence file.
+        case disputeEvidence = "dispute_evidence"
+        /// Identity document file.
+        case identityDocument = "identity_document"
+        /// Identity document file used only internally.
+        case identityPrivate = "identity_private"
+        /// Not a valid purpose – only used for `SafeEnumCodable` conformance.
+        case unparsable = ""
+    }
+    /// Time at which the object was created.
+    ///
+    /// Measured in seconds since the Unix epoch.
+    public let created: Date
+    /// Unique identifier for the object.
+    public let id: String
+    /// The [purpose](https://stripe.com/docs/file-upload#uploading-a-file) of the uploaded file.
+    public let purpose: Purpose
+    /// The size in bytes of the file object.
+    public let size: Int
+    /// The type of the file returned (e.g., `csv`, `pdf`, `jpg`, or `png`).
+    public let type: String?
+    public var _allResponseFieldsStorage: NonEncodableParameters?
+}

+ 234 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/STPAPIClient+FileUpload.swift

@@ -0,0 +1,234 @@
+//
+//  STPAPIClient+FileUpload.swift
+//  StripeCore
+//
+//  Created by Mel Ludowise on 11/9/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+import UIKit
+
+extension StripeFile.Purpose {
+    /// See max purpose sizes https://stripe.com/docs/file-upload.
+    var maxBytes: Int? {
+        switch self {
+        case .identityDocument,
+            .identityPrivate:
+            return 16_000_000
+        case .disputeEvidence:
+            return 5_000_000
+        case .unparsable:
+            return nil
+        }
+    }
+}
+
+/// STPAPIClient extensions to upload files.
+extension STPAPIClient {
+    @_spi(STP) public typealias FileAndUploadMetrics = (
+        file: StripeFile,
+        metrics: ImageUploadMetrics
+    )
+
+    /// Metrics returned in callback after image is uploaded to track performance.
+    @_spi(STP) public struct ImageUploadMetrics {
+        public let timeToUpload: TimeInterval
+        public let fileSizeBytes: Int
+    }
+
+    @_spi(STP) public static let defaultImageFileName = "image"
+
+    func data(
+        forUploadedImage image: UIImage,
+        compressionQuality: CGFloat,
+        purpose: String
+    ) -> Data {
+        // Get maxBytes if file purpose is known to the client
+        let maxBytes = StripeFile.Purpose(rawValue: purpose)?.maxBytes
+        return image.jpegDataAndDimensions(
+            maxBytes: maxBytes,
+            compressionQuality: compressionQuality
+        ).imageData
+    }
+
+    /// Uses the Stripe file upload API to upload a JPEG encoded image.
+    ///
+    /// The image will be automatically resized down if:
+    /// 1. The given purpose is recognized by the client.
+    /// 2. It's larger than the maximum allowed file size for the given purpose.
+    ///
+    /// - Parameters:
+    ///   - image: The image to be uploaded.
+    ///   - compressionQuality: The compression quality to use when encoding the jpeg.
+    ///   - purpose: The purpose of this file.
+    ///   - fileName: The name of the uploaded file. The "jpeg" extension will
+    ///     automatically be appended to this name.
+    ///   - ownedBy: A Stripe-internal property that sets the owner of the file.
+    ///   - ephemeralKeySecret: Authorization key, if applicable.
+    ///   - completion: The callback to run with the returned Stripe file (and any
+    ///     errors that may have occurred).
+    ///
+    /// - Note:
+    ///   The provided `purpose` must match a supported Purpose by Stripe's File
+    ///   Upload API, or the API will respond with an error. Generally, this should
+    ///   match a value in `StripeFile.Purpose`, but can be specified by any string
+    ///   when forwarding the value from a Stripe server response in situations
+    ///   where the purpose is not yet encoded in the client SDK.
+    @_spi(STP) public func uploadImage(
+        _ image: UIImage,
+        compressionQuality: CGFloat = UIImage.defaultCompressionQuality,
+        purpose: String,
+        fileName: String = defaultImageFileName,
+        ownedBy: String? = nil,
+        ephemeralKeySecret: String? = nil,
+        completion: @escaping (Result<StripeFile, Error>) -> Void
+    ) {
+        uploadImageAndGetMetrics(
+            image,
+            compressionQuality: compressionQuality,
+            purpose: purpose,
+            fileName: fileName,
+            ownedBy: ownedBy,
+            ephemeralKeySecret: ephemeralKeySecret
+        ) { result in
+            completion(result.map { $0.file })
+        }
+    }
+
+    @_spi(STP) public func uploadImageAndGetMetrics(
+        _ image: UIImage,
+        compressionQuality: CGFloat = UIImage.defaultCompressionQuality,
+        purpose: String,
+        fileName: String = defaultImageFileName,
+        ownedBy: String? = nil,
+        ephemeralKeySecret: String? = nil,
+        completion: @escaping (Result<FileAndUploadMetrics, Error>) -> Void
+    ) {
+        let purposePart = STPMultipartFormDataPart()
+        purposePart.name = "purpose"
+        // `unparsable` is not a valid purpose
+        if purpose != StripeFile.Purpose.unparsable.rawValue,
+            let purposeData = purpose.data(using: .utf8)
+        {
+            purposePart.data = purposeData
+        }
+
+        let imagePart = STPMultipartFormDataPart()
+        imagePart.name = "file"
+        imagePart.filename = "\(fileName).jpg"
+        imagePart.contentType = "image/jpeg"
+        imagePart.data = self.data(
+            forUploadedImage: image,
+            compressionQuality: compressionQuality,
+            purpose: purpose
+        )
+
+        let ownedByPart: STPMultipartFormDataPart? = ownedBy?.data(using: .utf8).map { ownedByData in
+            let part = STPMultipartFormDataPart()
+            part.name = "owned_by"
+            part.data = ownedByData
+            return part
+        }
+
+        let boundary = STPMultipartFormDataEncoder.generateBoundary()
+        let parts = [purposePart, ownedByPart, imagePart].compactMap { $0 }
+        let data = STPMultipartFormDataEncoder.multipartFormData(
+            for: parts,
+            boundary: boundary
+        )
+
+        var request = configuredRequest(
+            for: URL(string: FileUploadURL)!,
+            using: ephemeralKeySecret
+        )
+        request.httpMethod = HTTPMethod.post.rawValue
+        request.stp_setMultipartForm(data, boundary: boundary)
+
+        let requestStartTime = Date()
+        sendRequest(
+            request: request,
+            completion: { (result: Result<StripeFile, Error>) in
+                let timeToUpload = Date().timeIntervalSince(requestStartTime)
+                completion(
+                    result.map {
+                        (
+                            file: $0,
+                            metrics: .init(
+                                timeToUpload: timeToUpload,
+                                fileSizeBytes: imagePart.data?.count ?? 0
+                            )
+                        )
+                    }
+                )
+            }
+        )
+    }
+
+    /// Uses the Stripe file upload API to upload a JPEG encoded image.
+    ///
+    /// The image will be automatically resized down if:
+    /// 1. The given purpose is recognized by the client.
+    /// 2. It's larger than the maximum allowed file size for the given purpose.
+    ///
+    /// - Parameters:
+    ///   - image: The image to be uploaded.
+    ///   - compressionQuality: The compression quality to use when encoding the jpeg.
+    ///   - purpose: The purpose of this file.
+    ///   - fileName: The name of the uploaded file. The "jpeg" extension will
+    ///     automatically be appended to this name.
+    ///   - ownedBy: A Stripe-internal property that sets the owner of the file.
+    ///   - ephemeralKeySecret: Authorization key, if applicable.
+    ///
+    /// - Returns: A promise that resolves to a Stripe file, if successful, or an
+    ///   error that may have occurred.
+    ///
+    /// - Note:
+    ///   The provided `purpose` must match a supported Purpose by our API or the
+    ///   API will return an error. Generally, this should match a value in
+    ///   `StripeFile.Purpose`, but can be specified by any string for instances
+    ///   where a Stripe endpoint needs to specify a newer purpose that the client
+    ///   SDK does not recognize.
+    @_spi(STP) public func uploadImage(
+        _ image: UIImage,
+        compressionQuality: CGFloat = UIImage.defaultCompressionQuality,
+        purpose: String,
+        fileName: String = defaultImageFileName,
+        ownedBy: String? = nil,
+        ephemeralKeySecret: String? = nil
+    ) -> Future<StripeFile> {
+        return uploadImageAndGetMetrics(
+            image,
+            compressionQuality: compressionQuality,
+            purpose: purpose,
+            fileName: fileName,
+            ownedBy: ownedBy,
+            ephemeralKeySecret: ephemeralKeySecret
+        ).chained { Promise(value: $0.file) }
+    }
+
+    @_spi(STP) public func uploadImageAndGetMetrics(
+        _ image: UIImage,
+        compressionQuality: CGFloat = UIImage.defaultCompressionQuality,
+        purpose: String,
+        fileName: String = defaultImageFileName,
+        ownedBy: String? = nil,
+        ephemeralKeySecret: String? = nil
+    ) -> Future<FileAndUploadMetrics> {
+        let promise = Promise<FileAndUploadMetrics>()
+        uploadImageAndGetMetrics(
+            image,
+            compressionQuality: compressionQuality,
+            purpose: purpose,
+            fileName: fileName,
+            ownedBy: ownedBy,
+            ephemeralKeySecret: ephemeralKeySecret
+        ) { result in
+            promise.fullfill(with: result)
+        }
+        return promise
+    }
+
+}
+
+private let FileUploadURL = "https://uploads.stripe.com/v1/files"

+ 545 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/STPAPIClient.swift

@@ -0,0 +1,545 @@
+//
+//  STPAPIClient.swift
+//  StripeCore
+//
+//  Created by Jack Flintermann on 12/18/14.
+//  Copyright (c) 2014 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+import UIKit
+
+/// A client for making connections to the Stripe API.
+@objc public class STPAPIClient: NSObject {
+    /// The current version of this library.
+    @objc public static let STPSDKVersion = StripeAPIConfiguration.STPSDKVersion
+
+    /// A shared singleton API client.
+    ///
+    /// By default, the SDK uses this instance to make API requests
+    /// eg in STPPaymentHandler, STPPaymentContext, STPCustomerContext, etc.
+    @objc(sharedClient) public static let shared: STPAPIClient = {
+        let client = STPAPIClient()
+        return client
+    }()
+
+    /// The client's publishable key.
+    ///
+    /// The default value is `StripeAPI.defaultPublishableKey`.
+    @objc public var publishableKey: String? {
+        get {
+            if let publishableKey = _publishableKey {
+                return publishableKey
+            }
+            return StripeAPI.defaultPublishableKey
+        }
+        set {
+            _publishableKey = newValue
+            Self.validateKey(newValue)
+        }
+    }
+    var _publishableKey: String?
+
+    /// A publishable key that only contains publishable keys and not secret keys.
+    ///
+    /// If a secret key is found, returns "[REDACTED_LIVE_KEY]".
+    var sanitizedPublishableKey: String? {
+        guard let publishableKey = publishableKey else {
+            return nil
+        }
+
+        return (publishableKey.isSecretKey || publishableKeyIsUserKey)
+            ? "[REDACTED_LIVE_KEY]" : publishableKey
+    }
+
+    // Stored STPPaymentConfiguration: Type checking handled in STPAPIClient+Payments.swift.
+    @_spi(STP) public var _stored_configuration: NSObject?
+
+    /// In order to perform API requests on behalf of a connected account, e.g. to
+    /// create a Source or Payment Method on a connected account, set this property to the ID of the
+    /// account for which this request is being made.
+    ///
+    /// - seealso: https://stripe.com/docs/connect/authentication#authentication-via-the-stripe-account-header
+    @objc public var stripeAccount: String?
+
+    /// Libraries wrapping the Stripe SDK should set this, so that Stripe can contact you
+    /// about future issues or critical updates.
+    ///
+    /// - seealso: https://stripe.com/docs/building-plugins#setappinfo
+    @objc public var appInfo: STPAppInfo?
+
+    /// The API version used to communicate with Stripe.
+    @objc public static let apiVersion = APIVersion
+
+    // MARK: Internal/private properties
+    @_spi(STP) public var apiURL: URL! = URL(string: APIBaseURL)
+    @_spi(STP) public var urlSession = URLSession(
+        configuration: StripeAPIConfiguration.sharedUrlSessionConfiguration
+    )
+
+    @_spi(STP) public var sourcePollers: [String: NSObject]?
+    @_spi(STP) public var sourcePollersQueue: DispatchQueue?
+    /// A set of beta headers to add to Stripe API requests e.g. `Set(["alipay_beta=v1"])`.
+    @_spi(STP) public var betas: Set<String> = []
+
+    /// Returns `true` if `publishableKey` is actually a user key, `false` otherwise.
+    @_spi(STP) public var publishableKeyIsUserKey: Bool {
+        return publishableKey?.hasPrefix("uk_") ?? false
+    }
+
+    // MARK: Initializers
+    override public init() {
+        sourcePollers = [:]
+        sourcePollersQueue = DispatchQueue(label: "com.stripe.sourcepollers")
+    }
+
+    /// Initializes an API client with the given publishable key.
+    ///
+    /// - Parameter publishableKey: The publishable key to use.
+    /// - Returns: An instance of STPAPIClient.
+    @objc(initWithPublishableKey:)
+    public convenience init(
+        publishableKey: String
+    ) {
+        self.init()
+        self.publishableKey = publishableKey
+    }
+
+    @_spi(STP) public func configuredRequest(
+        for url: URL,
+        using ephemeralKeySecret: String? = nil,
+        additionalHeaders: [String: String] = [:]
+    )
+        -> URLRequest
+    {
+        var request = URLRequest(url: url)
+        var headers = defaultHeaders(ephemeralKeySecret: ephemeralKeySecret)
+        // additionalHeaders can overwrite defaultHeaders.
+        for (k, v) in additionalHeaders { headers[k] = v }
+        headers.forEach { key, value in
+            request.setValue(value, forHTTPHeaderField: key)
+        }
+        return request
+    }
+
+    /// Headers common to all API requests for a given API Client.
+    func defaultHeaders(ephemeralKeySecret: String?) -> [String: String] {
+        var defaultHeaders: [String: String] = [:]
+        defaultHeaders["X-Stripe-User-Agent"] = STPAPIClient.stripeUserAgentDetails(with: appInfo)
+        var stripeVersion = APIVersion
+        for beta in betas {
+            stripeVersion += "; \(beta)"
+        }
+        defaultHeaders["Stripe-Version"] = stripeVersion
+        defaultHeaders["Stripe-Account"] = stripeAccount
+        for (k, v) in authorizationHeader(using: ephemeralKeySecret) { defaultHeaders[k] = v }
+        return defaultHeaders
+    }
+
+    // MARK: Helpers
+
+    static var didShowTestmodeKeyWarning = false
+    class func validateKey(_ publishableKey: String?) {
+        guard NSClassFromString("XCTest") == nil else {
+            return  // no asserts in unit tests
+        }
+        guard let publishableKey = publishableKey, !publishableKey.isEmpty else {
+            assertionFailure(
+                "You must use a valid publishable key. For more info, see https://stripe.com/docs/keys"
+            )
+            return
+        }
+        let secretKey = publishableKey.hasPrefix("sk_")
+        assert(
+            !secretKey,
+            "You are using a secret key. Use a publishable key instead. For more info, see https://stripe.com/docs/keys"
+        )
+        #if !DEBUG
+            if publishableKey.lowercased().hasPrefix("pk_test") && !didShowTestmodeKeyWarning {
+                print(
+                    "ℹ️ You're using your Stripe testmode key. Make sure to use your livemode key when submitting to the App Store!"
+                )
+                didShowTestmodeKeyWarning = true
+            }
+        #endif
+    }
+
+    class func stripeUserAgentDetails(with appInfo: STPAppInfo?) -> String {
+        var details: [String: String] = [
+            // This SDK isn't in Objective-C anymore, but we sometimes check for
+            // 'objective-c' to enable iOS SDK-specific behavior in the API.
+            "lang": "objective-c",
+            "bindings_version": STPSDKVersion,
+        ]
+        let version = UIDevice.current.systemVersion
+        if version != "" {
+            details["os_version"] = version
+        }
+        var systemInfo = utsname()
+        uname(&systemInfo)
+
+        // Thanks to https://stackoverflow.com/questions/26028918/how-to-determine-the-current-iphone-device-model
+        let machineMirror = Mirror(reflecting: systemInfo.machine)
+        let deviceType = machineMirror.children.reduce("") { identifier, element in
+            guard let value = element.value as? Int8, value != 0 else { return identifier }
+            return identifier + String(UnicodeScalar(UInt8(value)))
+        }
+        details["type"] = deviceType
+        let model = UIDevice.current.localizedModel
+        if model != "" {
+            details["model"] = model
+        }
+
+        if let vendorIdentifier = UIDevice.current.identifierForVendor?.uuidString {
+            details["vendor_identifier"] = vendorIdentifier
+        }
+        if let appInfo = appInfo {
+            details["name"] = appInfo.name
+            details["partner_id"] = appInfo.partnerId
+            if appInfo.version != nil {
+                details["version"] = appInfo.version
+            }
+            if appInfo.url != nil {
+                details["url"] = appInfo.url
+            }
+        }
+        let data = try? JSONSerialization.data(withJSONObject: details, options: [])
+        return String(data: data ?? Data(), encoding: .utf8) ?? ""
+    }
+
+    @_spi(STP) public func authorizationHeader(
+        using substituteAuthorizationBearer: String? = nil
+    ) -> [String: String] {
+        let authorizationBearer = substituteAuthorizationBearer ?? publishableKey ?? ""
+        var headers = ["Authorization": "Bearer " + authorizationBearer]
+
+        if publishableKeyIsUserKey {
+            let liveMode = ProcessInfo.processInfo.environment["Stripe-Livemode"] != "false"
+            headers["Stripe-Livemode"] = liveMode ? "true" : "false"
+        }
+        return headers
+    }
+
+    @_spi(STP) public var isTestmode: Bool {
+        guard let publishableKey = publishableKey, !publishableKey.isEmpty else {
+            return false
+        }
+        return publishableKey.lowercased().hasPrefix("pk_test")
+    }
+}
+
+private let APIVersion = "2020-08-27"
+private let APIBaseURL = "https://api.stripe.com/v1"
+
+// MARK: Modern bindings
+extension STPAPIClient {
+    /// Make a GET request using the passed parameters.
+    @_spi(STP) public func get<T: Decodable>(
+        resource: String,
+        parameters: [String: Any],
+        ephemeralKeySecret: String? = nil,
+        completion: @escaping (
+            Result<T, Error>
+        ) -> Void
+    ) {
+        request(
+            method: .get,
+            parameters: parameters,
+            ephemeralKeySecret: ephemeralKeySecret,
+            resource: resource,
+            completion: completion
+        )
+    }
+
+    /// Make a GET request using the passed parameters.
+    @_spi(STP) public func get<T: Decodable>(
+        url: URL,
+        parameters: [String: Any],
+        ephemeralKeySecret: String? = nil,
+        completion: @escaping (
+            Result<T, Error>
+        ) -> Void
+    ) {
+        request(
+            method: .get,
+            parameters: parameters,
+            ephemeralKeySecret: ephemeralKeySecret,
+            url: url,
+            completion: completion
+        )
+    }
+
+    /// Make a GET request using the passed parameters.
+    ///
+    /// - Returns: a promise that is fullfilled when the request is complete.
+    @_spi(STP) public func get<T: Decodable>(
+        resource: String,
+        parameters: [String: Any],
+        ephemeralKeySecret: String? = nil
+    ) -> Promise<T> {
+        return request(
+            method: .get,
+            parameters: parameters,
+            ephemeralKeySecret: ephemeralKeySecret,
+            resource: resource
+        )
+    }
+
+    /// Make a POST request using the passed parameters.
+    @_spi(STP) public func post<T: Decodable>(
+        resource: String,
+        parameters: [String: Any],
+        ephemeralKeySecret: String? = nil,
+        completion: @escaping (Result<T, Error>) -> Void
+    ) {
+        request(
+            method: .post,
+            parameters: parameters,
+            ephemeralKeySecret: ephemeralKeySecret,
+            resource: resource,
+            completion: completion
+        )
+    }
+
+    /// Make a POST request using the passed parameters.
+    @_spi(STP) public func post<T: Decodable>(
+        url: URL,
+        parameters: [String: Any],
+        ephemeralKeySecret: String? = nil,
+        completion: @escaping (Result<T, Error>) -> Void
+    ) {
+        request(
+            method: .post,
+            parameters: parameters,
+            ephemeralKeySecret: ephemeralKeySecret,
+            url: url,
+            completion: completion
+        )
+    }
+
+    /// Make a POST request using the passed parameters.
+    ///
+    /// - Returns: a promise that is fullfilled when the request is complete.
+    @_spi(STP) public func post<T: Decodable>(
+        resource: String,
+        parameters: [String: Any],
+        ephemeralKeySecret: String? = nil
+    ) -> Promise<T> {
+        return request(
+            method: .post,
+            parameters: parameters,
+            ephemeralKeySecret: ephemeralKeySecret,
+            resource: resource
+        )
+    }
+
+    func request<T: Decodable>(
+        method: HTTPMethod,
+        parameters: [String: Any],
+        ephemeralKeySecret: String?,
+        resource: String
+    ) -> Promise<T> {
+        let promise = Promise<T>()
+        self.request(
+            method: method,
+            parameters: parameters,
+            ephemeralKeySecret: ephemeralKeySecret,
+            resource: resource
+        ) { result in
+            promise.fullfill(with: result)
+        }
+        return promise
+    }
+
+    func request<T: Decodable>(
+        method: HTTPMethod,
+        parameters: [String: Any],
+        ephemeralKeySecret: String?,
+        resource: String,
+        completion: @escaping (Result<T, Error>) -> Void
+    ) {
+        let url = apiURL.appendingPathComponent(resource)
+        request(
+            method: method,
+            parameters: parameters,
+            ephemeralKeySecret: ephemeralKeySecret,
+            url: url,
+            completion: completion
+        )
+    }
+
+    func request<T: Decodable>(
+        method: HTTPMethod,
+        parameters: [String: Any],
+        ephemeralKeySecret: String?,
+        url: URL,
+        completion: @escaping (Result<T, Error>) -> Void
+    ) {
+        var request = configuredRequest(for: url)
+        switch method {
+        case .get:
+            request.stp_addParameters(toURL: parameters)
+        case .post:
+            let formData = URLEncoder.queryString(from: parameters).data(using: .utf8)
+            request.httpBody = formData
+            request.setValue(
+                String(format: "%lu", UInt(formData?.count ?? 0)),
+                forHTTPHeaderField: "Content-Length"
+            )
+            request.setValue(
+                "application/x-www-form-urlencoded",
+                forHTTPHeaderField: "Content-Type"
+            )
+        }
+
+        request.httpMethod = method.rawValue
+        for (k, v) in authorizationHeader(using: ephemeralKeySecret) {
+            request.setValue(v, forHTTPHeaderField: k)
+        }
+
+        self.sendRequest(request: request, completion: completion)
+    }
+
+    /// Make a POST request using the passed Encodable object.
+    ///
+    /// - Returns: a promise that is fullfilled when the request is complete.
+    @_spi(STP) public func post<I: Encodable, O: Decodable>(
+        resource: String,
+        object: I,
+        ephemeralKeySecret: String? = nil
+    ) -> Promise<O> {
+        let promise = Promise<O>()
+        self.post(
+            resource: resource,
+            object: object,
+            ephemeralKeySecret: ephemeralKeySecret
+        ) { result in
+            promise.fullfill(with: result)
+        }
+        return promise
+    }
+
+    /// Make a POST request using the passed Encodable object.
+    @_spi(STP) public func post<I: Encodable, O: Decodable>(
+        resource: String,
+        object: I,
+        ephemeralKeySecret: String? = nil,
+        completion: @escaping (Result<O, Error>) -> Void
+    ) {
+        let url = apiURL.appendingPathComponent(resource)
+        post(
+            url: url,
+            object: object,
+            ephemeralKeySecret: ephemeralKeySecret,
+            completion: completion
+        )
+    }
+
+    /// Make a POST request using the passed Encodable object.
+    @_spi(STP) public func post<I: Encodable, O: Decodable>(
+        url: URL,
+        object: I,
+        ephemeralKeySecret: String? = nil,
+        completion: @escaping (Result<O, Error>) -> Void
+    ) {
+        do {
+            let jsonDictionary = try object.encodeJSONDictionary()
+            let formData = URLEncoder.queryString(from: jsonDictionary).data(using: .utf8)
+            var request = configuredRequest(
+                for: url,
+                using: ephemeralKeySecret,
+                additionalHeaders: [
+                    "Content-Length": String(format: "%lu", UInt(formData?.count ?? 0)),
+                    "Content-Type": "application/x-www-form-urlencoded",
+                ]
+            )
+            request.httpBody = formData
+            request.httpMethod = HTTPMethod.post.rawValue
+
+            self.sendRequest(request: request, completion: completion)
+        } catch {
+            // JSONEncoder can only throw two possible exceptions:
+            // `invalidFloatingPointValue`, which will never be thrown because of
+            // our encoder's NonConformingFloatEncodingStrategy.
+            // The other is `invalidValue` if the top-level object doesn't encode any values.
+            // This should ~never happen, and if it does the object will be empty,
+            // so it should be safe to return the un-redacted underlying error.
+            DispatchQueue.main.async {
+                completion(.failure(error))
+            }
+        }
+    }
+
+    func sendRequest<T: Decodable>(
+        request: URLRequest,
+        completion: @escaping (Result<T, Error>) -> Void
+    ) {
+        urlSession.stp_performDataTask(
+            with: request,
+            completionHandler: { (data, response, error) in
+                DispatchQueue.main.async {
+                    completion(
+                        STPAPIClient.decodeResponse(data: data, error: error, response: response)
+                    )
+                }
+            }
+        )
+    }
+
+    @_spi(STP) public static func decodeResponse<T: Decodable>(
+        data: Data?,
+        error: Error?,
+        response: URLResponse?
+    ) -> Result<T, Error> {
+        if let error = error {
+            return .failure(error)
+        }
+        guard let data = data else {
+            return .failure(NSError.stp_genericFailedToParseResponseError())
+        }
+
+        do {
+            /// HACK: We must first check if EmptyResponses contain an error since it'll always parse successfully.
+            if T.self == EmptyResponse.self,
+                let decodedStripeError = decodeStripeErrorResponse(data: data, response: response)
+            {
+                return .failure(decodedStripeError)
+            }
+
+            let decodedObject: T = try StripeJSONDecoder.decode(jsonData: data)
+            return .success(decodedObject)
+        } catch {
+            // Try decoding the error from the service if one is available
+            if let decodedStripeError = decodeStripeErrorResponse(data: data, response: response) {
+                return .failure(decodedStripeError)
+            } else {
+                // Return decoding error directly
+                return .failure(error)
+            }
+        }
+    }
+
+    /// Decodes request data to see if it can be parsed as a Stripe error.
+    private static func decodeStripeErrorResponse(
+        data: Data,
+        response: URLResponse?
+    ) -> StripeError? {
+        var decodedError: StripeError?
+
+        if let decodedErrorResponse: StripeAPIErrorResponse = try? StripeJSONDecoder.decode(
+            jsonData: data
+        ),
+            var apiError = decodedErrorResponse.error
+        {
+            apiError.statusCode = (response as? HTTPURLResponse)?.statusCode
+            decodedError = StripeError.apiError(apiError)
+        }
+
+        return decodedError
+    }
+
+    enum HTTPMethod: String {
+        case get = "GET"
+        case post = "POST"
+    }
+}

+ 45 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/STPAppInfo.swift

@@ -0,0 +1,45 @@
+//
+//  STPAppInfo.swift
+//  StripeCore
+//
+//  Created by Yuki Tokuhiro on 6/20/19.
+//  Copyright © 2019 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+
+/// Libraries wrapping the Stripe SDK should use this object to provide information about the
+/// library, and set it in on `STPAPIClient`.
+///
+/// This information is passed to Stripe so that we can contact you about future issues or
+/// critical updates.
+/// - seealso: https://stripe.com/docs/building-plugins#setappinfo
+@objc public class STPAppInfo: NSObject {
+    /// Initializes an instance of `STPAppInfo`.
+    ///
+    /// - Parameters:
+    ///   - name:        The name of your library (e.g. "MyAwesomeLibrary").
+    ///   - partnerId:   Your Stripe Partner ID (e.g. "pp_partner_1234"). Required for Stripe Verified Partners, optional otherwise.
+    ///   - version:     The version of your library (e.g. "1.2.34"). Optional.
+    ///   - url:         The website for your library (e.g. "https://myawesomelibrary.info"). Optional.
+    @objc public init(
+        name: String,
+        partnerId: String?,
+        version: String?,
+        url: String?
+    ) {
+        self.name = name
+        self.partnerId = partnerId
+        self.version = version
+        self.url = url
+    }
+
+    /// The name of your library (e.g. "MyAwesomeLibrary").
+    @objc public private(set) var name: String
+    /// Your Stripe Partner ID (e.g. "pp_partner_1234").
+    @objc public private(set) var partnerId: String?
+    /// The version of your library (e.g. "1.2.34").
+    @objc public private(set) var version: String?
+    /// The website for your library (e.g. "https://myawesomelibrary.info").
+    @objc public private(set) var url: String?
+}

+ 38 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/STPMultipartFormDataEncoder.swift

@@ -0,0 +1,38 @@
+//
+//  STPMultipartFormDataEncoder.swift
+//  StripeCore
+//
+//  Created by Charles Scalesse on 12/1/16.
+//  Copyright © 2016 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+
+/// Encoder class to generate the HTTP body data for a multipart/form-data request.
+///
+/// - seealso: https://www.w3.org/TR/html401/interact/forms.html#h-17.13.4
+class STPMultipartFormDataEncoder: NSObject {
+    /// Generates the HTTP body data from an array of parts.
+    class func multipartFormData(for parts: [STPMultipartFormDataPart], boundary: String) -> Data {
+        var data = Data()
+        let boundaryData = "--\(boundary)\r\n".data(using: .utf8)
+
+        for part in parts {
+            if let boundaryData = boundaryData {
+                data.append(boundaryData)
+            }
+            data.append(part.composedData())
+        }
+
+        if let data1 = "--\(boundary)--\r\n".data(using: .utf8) {
+            data.append(data1)
+        }
+
+        return data
+    }
+
+    /// Generates a unique boundary string to be used between parts.
+    class func generateBoundary() -> String {
+        return "Stripe-iOS-\(UUID().uuidString)"
+    }
+}

+ 63 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/STPMultipartFormDataPart.swift

@@ -0,0 +1,63 @@
+//
+//  STPMultipartFormDataPart.swift
+//  StripeCore
+//
+//  Created by Charles Scalesse on 12/1/16.
+//  Copyright © 2016 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+
+/// Represents a single part of a multipart/form-data upload.
+///
+/// - seealso: https://www.w3.org/TR/html401/interact/forms.html#h-17.13.4
+class STPMultipartFormDataPart: NSObject {
+    /// The data for this part.
+    var data: Data?
+    /// The name for this part.
+    var name: String?
+    /// The filename for this part.
+    ///
+    /// As a rule of thumb, this can be ommitted when the data is just an encoded string.
+    /// However, this is typically required for other types of binary file data (like images).
+    var filename: String?
+    /// The content type for this part.
+    ///
+    /// When omitted, the multipart/form-data standard assumes text/plain.
+    var contentType: String?
+
+    // MARK: - Data Composition
+
+    /// Returns the fully-composed data for this part.
+    func composedData() -> Data {
+        var data = Data()
+
+        var contentDisposition = "Content-Disposition: form-data; name=\"\(name ?? "")\""
+        if filename != nil {
+            contentDisposition += "; filename=\"\(filename ?? "")\""
+        }
+        contentDisposition += "\r\n"
+
+        if let data1 = contentDisposition.data(using: .utf8) {
+            data.append(data1)
+        }
+
+        var contentType = ""
+        if let _contentType = self.contentType {
+            contentType.append("Content-Type: \(_contentType)\r\n")
+        }
+        contentType += "\r\n"
+        if let data1 = contentType.data(using: .utf8) {
+            data.append(data1)
+        }
+
+        if let _data = self.data {
+            data.append(_data)
+        }
+        if let data1 = "\r\n".data(using: .utf8) {
+            data.append(data1)
+        }
+
+        return data
+    }
+}

+ 174 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/StripeAPI.swift

@@ -0,0 +1,174 @@
+//
+//  StripeAPI.swift
+//  StripeCore
+//
+//  Created by Yuki Tokuhiro on 9/22/20.
+//  Copyright © 2020 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+import PassKit
+
+/// A top-level class that imports the rest of the Stripe SDK.
+@objc public class StripeAPI: NSObject {
+    /// Set this to your Stripe publishable API key, obtained from https://dashboard.stripe.com/apikeys.
+    ///
+    /// Set this as early as possible in your application's lifecycle, preferably in your AppDelegate or SceneDelegate.
+    /// New instances of STPAPIClient will be initialized with this value.
+    /// @warning Make sure not to ship your test API keys to the App Store! This will log a warning if you use your test key in a release build.
+    @objc public static var defaultPublishableKey: String?
+
+    /// Set this to your Stripe publishable API key, obtained from https://dashboard.stripe.com/apikeys.
+    ///
+    /// Set this as early as possible in your application's lifecycle, preferably in your AppDelegate or SceneDelegate.
+    /// New instances of STPAPIClient will be initialized with this value.
+    /// @warning Make sure not to ship your test API keys to the App Store! This will log a warning if you use your test key in a release build.
+    @objc public func setDefaultPublishableKey(_ publishableKey: String) {
+        StripeAPI.defaultPublishableKey = publishableKey
+    }
+
+    /// A Boolean value that determines whether additional device data is sent to Stripe for fraud prevention.
+    ///
+    /// If YES, additional device signals will be sent to Stripe.
+    /// For more details on the information we collect, visit https://stripe.com/docs/disputes/prevention/advanced-fraud-detection
+    /// Disabling this setting will reduce Stripe's ability to protect your business from fraudulent payments.
+    /// The default value is YES.
+    @objc public static var advancedFraudSignalsEnabled: Bool = true
+
+    /// If the SDK receives a "Too Many Requests" (429) status code from Stripe,
+    /// it will automatically retry the request.
+    ///
+    /// The default value is 3.
+    /// See https://stripe.com/docs/rate-limits for more information.
+    @objc public static var maxRetries = 3
+
+    // MARK: - Apple Pay
+
+    /// Japanese users can enable JCB for Apple Pay by setting this to `YES`,
+    /// after they have been approved by JCB.
+    ///
+    /// The default value is NO.
+    /// @note JCB is only supported on iOS 10.1+
+    @objc public class var jcbPaymentNetworkSupported: Bool {
+        get {
+            return self.additionalEnabledApplePayNetworks.contains(.JCB)
+        }
+        set(JCBPaymentNetworkSupported) {
+            if JCBPaymentNetworkSupported
+                && !self.additionalEnabledApplePayNetworks.contains(.JCB)
+            {
+                self.additionalEnabledApplePayNetworks =
+                    self.additionalEnabledApplePayNetworks + [PKPaymentNetwork.JCB]
+            } else if !JCBPaymentNetworkSupported {
+                var updatedNetworks = self.additionalEnabledApplePayNetworks
+                updatedNetworks.removeAll {
+                    $0 as AnyObject === PKPaymentNetwork.JCB as AnyObject
+                }
+                self.additionalEnabledApplePayNetworks = updatedNetworks
+            }
+        }
+    }
+    /// The SDK accepts Amex, Mastercard, Visa, and Discover for Apple Pay.
+    ///
+    /// Set this property to enable other card networks in addition to these.
+    /// For example, `additionalEnabledApplePayNetworks = [.JCB]` enables JCB (note this requires onboarding from JCB and Stripe).
+    @objc public static var additionalEnabledApplePayNetworks: [PKPaymentNetwork] = []
+
+    /// Whether or not this device is capable of using Apple Pay.
+    ///
+    /// This checks both whether the device supports Apple Pay, as well as whether or not they have
+    /// stored Apple Pay cards on their device.
+    ///
+    /// - Parameter paymentRequest: The return value of this method depends on the
+    /// `supportedNetworks` property of this payment request, which by default should be
+    /// `[.amex, .masterCard, .visa, .discover]`.
+    /// - Returns: whether or not the user is currently able to pay with Apple Pay.
+    @objc public class func canSubmitPaymentRequest(_ paymentRequest: PKPaymentRequest) -> Bool {
+        if !self.deviceSupportsApplePay() {
+            return false
+        }
+        if paymentRequest.merchantIdentifier.isEmpty {
+            return false
+        }
+        // "In versions of iOS prior to version 12.0 and watchOS prior to version 5.0, the amount of the grand total must be greater than zero."
+        return paymentRequest.paymentSummaryItems.last?.amount.floatValue ?? 0.0 >= 0
+    }
+
+    class func supportedPKPaymentNetworks() -> [PKPaymentNetwork] {
+        var additionalOSSupportedNetworks: [PKPaymentNetwork] = []
+        additionalOSSupportedNetworks.append(.maestro)
+        return [
+            .amex,
+            .masterCard,
+            .visa,
+            .discover,
+        ] + additionalEnabledApplePayNetworks + additionalOSSupportedNetworks
+    }
+
+    /// Whether or not this can make Apple Pay payments via a card network supported
+    /// by Stripe.
+    ///
+    /// The Stripe supported Apple Pay card networks are:
+    /// American Express, Visa, Mastercard, Discover, Maestro.
+    /// Japanese users can enable JCB by setting `JCBPaymentNetworkSupported` to YES,
+    /// after they have been approved by JCB.
+    /// - Returns: YES if the device is currently able to make Apple Pay payments via one
+    /// of the supported networks. NO if the user does not have a saved card of a
+    /// supported type, or other restrictions prevent payment (such as parental controls).
+    @objc public class func deviceSupportsApplePay() -> Bool {
+        return PKPaymentAuthorizationController.canMakePayments(
+            usingNetworks: self.supportedPKPaymentNetworks()
+        )
+    }
+
+    /// A convenience method to build a `PKPaymentRequest` with sane default values.
+    ///
+    /// You will still need to configure the `paymentSummaryItems` property to indicate
+    /// what the user is purchasing, as well as the optional `requiredShippingContactFields`,
+    /// `requiredBillingContactFields`, and `shippingMethods` properties to indicate
+    /// what additional contact information your application requires.
+    /// - Parameters:
+    ///   - merchantIdentifier: Your Apple Merchant ID.
+    ///   - countryCode:        The two-letter code for the country where the payment
+    /// will be processed. This should be the country of your Stripe account.
+    ///   - currencyCode:       The three-letter code for the currency used by this
+    /// payment request. Apple Pay interprets the amounts provided by the summary items
+    /// attached to this request as amounts in this currency.
+    /// - Returns: a `PKPaymentRequest` with proper default values.
+    @objc(paymentRequestWithMerchantIdentifier:country:currency:)
+    public class func paymentRequest(
+        withMerchantIdentifier merchantIdentifier: String,
+        country countryCode: String,
+        currency currencyCode: String
+    ) -> PKPaymentRequest {
+        let paymentRequest = PKPaymentRequest()
+        paymentRequest.merchantIdentifier = merchantIdentifier
+        paymentRequest.supportedNetworks = self.supportedPKPaymentNetworks()
+        paymentRequest.merchantCapabilities = .capability3DS
+        paymentRequest.countryCode = countryCode.uppercased()
+        paymentRequest.currencyCode = currencyCode.uppercased()
+        paymentRequest.requiredBillingContactFields = Set([.postalAddress])
+        return paymentRequest
+    }
+
+    // MARK: - URL callbacks
+
+    /// Call this method in your app delegate whenever you receive an URL in your
+    /// app delegate for a Stripe callback.
+    ///
+    /// For convenience, you can pass all URL's you receive in your app delegate
+    /// to this method first, and check the return value
+    /// to easily determine whether it is a callback URL that Stripe will handle
+    /// or if your app should process it normally.
+    /// If you are using a universal link URL, you will receive the callback in `application:continueUserActivity:restorationHandler:`
+    /// To learn more about universal links, see https://developer.apple.com/library/content/documentation/General/Conceptual/AppSearch/UniversalLinks.html
+    /// If you are using a native scheme URL, you will receive the callback in `application:openURL:options:`
+    /// To learn more about native url schemes, see https://developer.apple.com/library/content/documentation/iPhone/Conceptual/iPhoneOSProgrammingGuide/Inter-AppCommunication/Inter-AppCommunication.html#//apple_ref/doc/uid/TP40007072-CH6-SW10
+    /// - Parameter url: The URL that you received in your app delegate
+    /// - Returns: YES if the URL is expected and will be handled by Stripe. NO otherwise.
+    @objc(handleStripeURLCallbackWithURL:) @discardableResult public static func handleURLCallback(
+        with url: URL
+    ) -> Bool {
+        return STPURLCallbackHandler.shared().handleURLCallback(url)
+    }
+}

+ 19 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/StripeAPIConfiguration+Version.swift

@@ -0,0 +1,19 @@
+//
+// StripeAPIConfiguration+Version.swift
+//
+// This file was generated by update_version.sh
+// Do not edit this file directly.
+// Instead, edit the `VERSION` file and run `ci_scripts/update_version.sh`
+//
+
+import Foundation
+
+extension StripeAPIConfiguration {
+    /// The current version of this library.
+    public static let STPSDKVersion = "23.13.0"
+
+    // NOTE: `STPSDKVersion` must be a hard-coded static string instead of
+    // dynamically generated from the bundle's `CFBundleShortVersionString` to
+    // ensure the correct value is returned when the SDK is statically linked.
+
+}

+ 16 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/StripeAPIConfiguration.swift

@@ -0,0 +1,16 @@
+//
+//  StripeAPIConfiguration.swift
+//  StripeCore
+//
+//  Created by Mel Ludowise on 5/17/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+
+/// Shared configurations across all Stripe frameworks.
+@_spi(STP) public struct StripeAPIConfiguration {
+
+    public static let sharedUrlSessionConfiguration = URLSessionConfiguration.default
+
+}

+ 80 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/StripeError.swift

@@ -0,0 +1,80 @@
+//
+//  StripeError.swift
+//  StripeCore
+//
+//  Created by David Estes on 8/11/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+
+/// Error codes returned from STPAPIClient.
+@_spi(STP) public enum StripeError: Error {
+    /// The server returned an API error.
+    case apiError(StripeAPIError)
+
+    /// The request was invalid.
+    case invalidRequest
+
+    /// Localized description of the error.
+    public var localizedDescription: String {
+        return errorDescription ?? NSError.stp_unexpectedErrorMessage()
+    }
+}
+
+// MARK: - LocalizedError
+
+extension StripeError: LocalizedError {
+    @_spi(STP) public var errorDescription: String? {
+        switch self {
+        case .apiError(let apiError):
+            return apiError.errorUserInfoString(key: NSLocalizedDescriptionKey)
+        case .invalidRequest:
+            return nil
+        }
+    }
+
+    @_spi(STP) public var failureReason: String? {
+        switch self {
+        case .apiError(let apiError):
+            return apiError.errorUserInfoString(key: NSLocalizedFailureReasonErrorKey)
+        case .invalidRequest:
+            return nil
+        }
+    }
+
+    @_spi(STP) public var recoverySuggestion: String? {
+        switch self {
+        case .apiError(let apiError):
+            return apiError.errorUserInfoString(key: NSLocalizedRecoverySuggestionErrorKey)
+        case .invalidRequest:
+            return nil
+        }
+    }
+
+    @_spi(STP) public var helpAnchor: String? {
+        switch self {
+        case .apiError(let apiError):
+            return apiError.errorUserInfoString(key: NSHelpAnchorErrorKey)
+        case .invalidRequest:
+            return nil
+        }
+    }
+}
+
+extension StripeError: AnalyticLoggableError {
+    public func analyticLoggableSerializeForLogging() -> [String: Any] {
+        var code: Int
+        switch self {
+        case .apiError:
+            code = 0
+        case .invalidRequest:
+            code = 1
+        }
+
+        return [
+            "domain": (self as NSError).domain,
+            "code": code,
+        ]
+    }
+}

+ 73 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/API Bindings/StripeServiceError.swift

@@ -0,0 +1,73 @@
+//
+//  StripeServiceError.swift
+//  StripeCore
+//
+//  Created by David Estes on 8/11/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+
+/// An error returned from the Stripe API.
+///
+/// https://stripe.com/docs/api/errors
+@_spi(STP) public struct StripeAPIError: UnknownFieldsDecodable {
+    /// The type of error returned.
+    @_spi(STP) public var type: ErrorType
+    /// For some errors that could be handled programmatically,
+    /// a short string indicating the error code reported.
+    ///
+    /// https://stripe.com/docs/error-codes
+    @_spi(STP) public var code: String?
+    /// A URL to more information about the error code reported.
+    @_spi(STP) public var docUrl: URL?
+    /// A human-readable message providing more details about the error.
+    ///
+    /// For card errors, these messages can be shown to your users.
+    @_spi(STP) public var message: String?
+    /// If the error is parameter-specific, the parameter related to the error.
+    ///
+    /// For example, you can use this to display a message near the correct form field.
+    @_spi(STP) public var param: String?
+    /// The response’s HTTP status code.
+    @_spi(STP) public var statusCode: Int?
+
+    // More information may be available in `allResponseFields`, including
+    // the PaymentIntent or PaymentMethod.
+
+    /// Types of errors presented by the API.
+    @_spi(STP) public enum ErrorType: String, SafeEnumCodable {
+        case apiError = "api_error"
+        case cardError = "card_error"
+        case idempotencyError = "idempotency_error"
+        case invalidRequestError = "invalid_request_error"
+        case unparsable
+    }
+
+    public var _allResponseFieldsStorage: NonEncodableParameters?
+}
+
+@_spi(STP) public struct StripeAPIErrorResponse: UnknownFieldsDecodable {
+    @_spi(STP) public var error: StripeAPIError?
+
+    public var _allResponseFieldsStorage: NonEncodableParameters?
+}
+
+extension NSError {
+    static func stp_error(from stripeApiError: StripeAPIError) -> NSError? {
+        return stp_error(
+            errorType: stripeApiError.type.rawValue,
+            stripeErrorCode: stripeApiError.code,
+            stripeErrorMessage: stripeApiError.message,
+            errorParam: stripeApiError.param,
+            declineCode: nil,
+            httpResponse: nil
+        )
+    }
+}
+
+extension StripeAPIError {
+    func errorUserInfoString(key: String) -> String? {
+        return NSError.stp_error(from: self)?.userInfo[key] as? String
+    }
+}

+ 37 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/Analytics/Analytic.swift

@@ -0,0 +1,37 @@
+//
+//  Analytic.swift
+//  StripeCore
+//
+//  Created by Mel Ludowise on 3/12/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+
+/// An analytic that can be logged to our analytics system.
+@_spi(STP) public protocol Analytic {
+    var event: STPAnalyticEvent { get }
+    var params: [String: Any] { get }
+}
+
+/// An error analytic that can be logged to our analytics system.
+@_spi(STP) public protocol ErrorAnalytic: Analytic {
+    var error: Error { get }
+}
+
+/// A generic analytic type.
+///
+/// - NOTE: This should only be used to support legacy analytics.
+/// Any new analytic events should create a new type and conform to `Analytic`.
+@_spi(STP) public struct GenericAnalytic: Analytic {
+    public let event: STPAnalyticEvent
+    public let params: [String: Any]
+
+    public init(
+        event: STPAnalyticEvent,
+        params: [String: Any]
+    ) {
+        self.event = event
+        self.params = params
+    }
+}

+ 52 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/Analytics/AnalyticLoggableError.swift

@@ -0,0 +1,52 @@
+//
+//  AnalyticLoggableError.swift
+//  StripeCore
+//
+//  Created by Nick Porter on 9/2/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+
+/// Defines a common loggable error to our analytics service.
+@_spi(STP) public protocol AnalyticLoggableError: Error {
+
+    /// Serializes this error for analytics logging.
+    ///
+    /// - Returns: A dictionary representing this error, not containing any PII or PDE
+    func analyticLoggableSerializeForLogging() -> [String: Any]
+}
+
+/// Error types that conform to this protocol and String-based RawRepresentable
+/// will automatically serialize the rawValue for analytics logging.
+@_spi(STP) public protocol AnalyticLoggableStringError: Error {
+    var loggableType: String { get }
+}
+
+@_spi(STP) extension AnalyticLoggableStringError
+where Self: RawRepresentable, Self.RawValue == String {
+    public var loggableType: String {
+        return rawValue
+    }
+}
+
+@_spi(STP) extension Error {
+    public func serializeForLogging() -> [String: Any] {
+        if let loggableError = self as? AnalyticLoggableError {
+            return loggableError.analyticLoggableSerializeForLogging()
+        }
+        let nsError = self as NSError
+
+        var payload: [String: Any] = [
+            "domain": nsError.domain,
+        ]
+
+        if let stringError = self as? AnalyticLoggableStringError {
+            payload["type"] = stringError.loggableType
+        } else {
+            payload["code"] = nsError.code
+        }
+
+        return payload
+    }
+}

+ 153 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/Analytics/AnalyticsClientV2.swift

@@ -0,0 +1,153 @@
+//
+//  AnalyticsClientV2.swift
+//  StripeCore
+//
+//  Created by Mel Ludowise on 6/7/22.
+//  Copyright © 2022 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+import UIKit
+
+/// Dependency-injectable protocol for `AnalyticsClientV2`.
+@_spi(STP) public protocol AnalyticsClientV2Protocol {
+    var clientId: String { get }
+
+    func log(eventName: String, parameters: [String: Any])
+}
+
+/// Logs analytics to `r.stripe.com`.
+///
+/// To log analytics to the legacy `q.stripe.com`, use `STPAnalyticsClient`.
+@_spi(STP) public class AnalyticsClientV2: AnalyticsClientV2Protocol {
+
+    static let loggerUrl = URL(string: "https://r.stripe.com/0")!
+
+    public let clientId: String
+    public let origin: String
+
+    private(set) var urlSession: URLSession = URLSession(
+        configuration: StripeAPIConfiguration.sharedUrlSessionConfiguration
+    )
+
+    /// Instantiates an AnalyticsClient capable of logging to a specific events table.
+    ///
+    /// - Parameters:
+    ///     - clientId: The client identifier corresponding to `client_config.yaml`.
+    ///     - origin: The origin corresponding to `r.stripe.com.conf`.
+    public init(
+        clientId: String,
+        origin: String
+    ) {
+        self.clientId = clientId
+        self.origin = origin
+    }
+
+    static let shouldCollectAnalytics: Bool = {
+        #if targetEnvironment(simulator)
+            return false
+        #else
+            return NSClassFromString("XCTest") == nil
+        #endif
+    }()
+
+    var requestHeaders: [String: String] {
+        return [
+            "user-agent": "Stripe/v1 ios/\(StripeAPIConfiguration.STPSDKVersion)",
+            "origin": origin,
+        ]
+    }
+
+    /// Helper to serialize errors to a dictionary that can be included in event parameters.
+    ///
+    /// - Parameters:
+    ///     - error: The error to serialize.
+    ///     - filePath: Optionally include the filePath of the call site that threw
+    ///     the error. Only the name of the file (e.g. "MyClass.swift")
+    ///     will be serialized and not the full path.
+    ///     - line: Optionally include the line number of the call site that threw the error.
+    public static func serialize(
+        error: Error,
+        filePath: StaticString?,
+        line: UInt?
+    ) -> [String: Any] {
+
+        var payload = error.serializeForLogging()
+
+        if let filePath = filePath {
+            // The full file path can contain the device name, so only include the file name
+            let fileName = NSString(string: "\(filePath)").lastPathComponent
+            payload["file"] = fileName
+        }
+        if let line = line {
+            payload["line"] = line
+        }
+
+        return payload
+    }
+
+    public func log(eventName: String, parameters: [String: Any]) {
+        let payload = payload(withEventName: eventName, parameters: parameters)
+
+        #if DEBUG
+            NSLog("LOG ANALYTICS: \(payload)")
+        #endif
+
+        guard AnalyticsClientV2.shouldCollectAnalytics else {
+            return
+        }
+
+        var request = URLRequest(url: AnalyticsClientV2.loggerUrl)
+        request.httpMethod = "POST"
+        request.stp_setFormPayload(payload.jsonEncodeNestedDicts(options: .sortedKeys))
+        requestHeaders.forEach { key, value in
+            request.setValue(value, forHTTPHeaderField: key)
+        }
+        let task: URLSessionDataTask = urlSession.dataTask(with: request as URLRequest)
+        task.resume()
+    }
+}
+
+extension AnalyticsClientV2Protocol {
+    public func makeCommonPayload() -> [String: Any] {
+        var payload: [String: Any] = [:]
+
+        // Required by Analytics Event Logger
+        payload["client_id"] = self.clientId
+        payload["event_id"] = UUID().uuidString
+        payload["created"] = Date().timeIntervalSince1970
+
+        // Common payload
+        let version = UIDevice.current.systemVersion
+        if !version.isEmpty {
+            payload["os_version"] = version
+        }
+        payload["sdk_platform"] = "ios"
+        payload["sdk_version"] = StripeAPIConfiguration.STPSDKVersion
+        if let deviceType = STPDeviceUtils.deviceType {
+            payload["device_type"] = deviceType
+        }
+        payload["app_name"] = Bundle.stp_applicationName() ?? ""
+        payload["app_version"] = Bundle.stp_applicationVersion() ?? ""
+        payload["plugin_type"] = PluginDetector.shared.pluginType?.rawValue
+        payload["platform_info"] = [
+            "install": InstallMethod.current.rawValue,
+            "app_bundle_id": Bundle.stp_applicationBundleId() ?? "",
+        ]
+
+        return payload
+    }
+
+    public func payload(withEventName eventName: String, parameters: [String: Any]) -> [String: Any]
+    {
+        var payload = makeCommonPayload()
+        payload["event_name"] = eventName
+        payload = payload.merging(
+            parameters,
+            uniquingKeysWith: { a, _ in
+                return a
+            }
+        )
+        return payload
+    }
+}

+ 54 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/Analytics/NetworkDetector.swift

@@ -0,0 +1,54 @@
+//
+//  NetworkDetector.swift
+//  StripeCore
+//
+//  Created by Nick Porter on 7/5/23.
+//
+
+import CoreTelephony
+import Foundation
+import SystemConfiguration
+
+/// A class which can detect the current network type of the device
+class NetworkDetector {
+
+    static func getConnectionType() -> String? {
+        guard let reachability = SCNetworkReachabilityCreateWithName(kCFAllocatorDefault, "www.stripe.com") else {
+            return nil
+        }
+
+        var flags = SCNetworkReachabilityFlags()
+        SCNetworkReachabilityGetFlags(reachability, &flags)
+
+        let isReachable = flags.contains(.reachable)
+        let isWWAN = flags.contains(.isWWAN)
+
+        guard isReachable else {
+            return nil
+        }
+
+        guard isWWAN else {
+            return "Wi-Fi"
+        }
+
+        let networkInfo = CTTelephonyNetworkInfo()
+        let carrierType = networkInfo.serviceCurrentRadioAccessTechnology
+
+        guard let carrierTypeName = carrierType?.first?.value else {
+            return "unknown"
+        }
+
+        switch carrierTypeName {
+        case CTRadioAccessTechnologyGPRS, CTRadioAccessTechnologyEdge, CTRadioAccessTechnologyCDMA1x:
+            return "2G"
+        case CTRadioAccessTechnologyWCDMA, CTRadioAccessTechnologyHSDPA, CTRadioAccessTechnologyHSUPA, CTRadioAccessTechnologyCDMAEVDORev0, CTRadioAccessTechnologyCDMAEVDORevA, CTRadioAccessTechnologyCDMAEVDORevB, CTRadioAccessTechnologyeHRPD:
+            return "3G"
+        case CTRadioAccessTechnologyLTE:
+            return "4G"
+        default:
+            return "5G"
+        }
+
+    }
+
+}

+ 47 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/Analytics/PluginDetector.swift

@@ -0,0 +1,47 @@
+//
+//  PluginDetector.swift
+//  StripeCore
+//
+//  Created by Nick Porter on 10/1/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+
+/// A class which can detect if the host app is using a known cross-platform solution.
+class PluginDetector {
+
+    /// Shared instance of the `PluginDetector` to enable caching of the `pluginType`.
+    static let shared = PluginDetector()
+
+    /// Represents all the known/tracked cross-platform solutions.
+    enum PluginType: String, CaseIterable {
+        case cordova
+        case flutter
+        case ionic
+        case reactNative = "react-native"
+        case unity
+        case xamarin
+
+        /// Represents a known class contained in each cross-platform environment.
+        var className: String {
+            switch self {
+            case .cordova: return "CDVPlugin"
+            case .flutter: return "FlutterAppDelegate"
+            case .ionic: return "CAPPlugin"
+            case .reactNative: return "RCTBridge"
+            case .unity: return "UnityFramework"
+            case .xamarin: return "XamarinAssociatedObject"
+            }
+        }
+    }
+
+    /// Determines if this app is running within a plugin environment.
+    ///
+    /// - Returns: returns the plugin type if found, otherwise nil.
+    lazy var pluginType: PluginType? = {
+        PluginType.allCases.first { type in
+            NSClassFromString(type.className) != nil
+        }
+    }()
+}

+ 175 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/Analytics/STPAnalyticEvent.swift

@@ -0,0 +1,175 @@
+//
+//  STPAnalyticEvent.swift
+//  StripeCore
+//
+//  Created by Mel Ludowise on 3/12/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+
+/// Enumeration of all the analytic events logged by our SDK.
+@_spi(STP) public enum STPAnalyticEvent: String {
+    // MARK: - Payment Creation
+    case tokenCreation = "stripeios.token_creation"
+
+    // This was "stripeios.source_creation" in earlier SDKs,
+    // but we need to support both the old and new values forever.
+    case sourceCreation = "stripeios.source_creationn"
+
+    case paymentMethodCreation = "stripeios.payment_method_creation"
+    case paymentMethodIntentCreation = "stripeios.payment_intent_confirmation"
+    case setupIntentConfirmationAttempt = "stripeios.setup_intent_confirmation"
+
+    // MARK: - Payment Confirmation
+    case _3DS2AuthenticationRequestParamsFailed =
+        "stripeios.3ds2_authentication_request_params_failed"
+    case _3DS2AuthenticationAttempt = "stripeios.3ds2_authenticate"
+    case _3DS2FrictionlessFlow = "stripeios.3ds2_frictionless_flow"
+    case urlRedirectNextAction = "stripeios.url_redirect_next_action"
+    case _3DS2ChallengeFlowPresented = "stripeios.3ds2_challenge_flow_presented"
+    case _3DS2ChallengeFlowTimedOut = "stripeios.3ds2_challenge_flow_timed_out"
+    case _3DS2ChallengeFlowUserCanceled = "stripeios.3ds2_challenge_flow_canceled"
+    case _3DS2ChallengeFlowCompleted = "stripeios.3ds2_challenge_flow_completed"
+    case _3DS2ChallengeFlowErrored = "stripeios.3ds2_challenge_flow_errored"
+    case _3DS2RedirectUserCanceled = "stripeios.3ds2_redirect_canceled"
+
+    // MARK: - Card Metadata
+    case cardMetadataLoadedTooSlow = "stripeios.card_metadata_loaded_too_slow"
+    case cardMetadataResponseFailure = "stripeios.card_metadata_load_failure"
+    case cardMetadataMissingRange = "stripeios.card_metadata_missing_range"
+
+    // MARK: - Card Scanning
+    case cardScanSucceeded = "stripeios.cardscan_success"
+    case cardScanCancelled = "stripeios.cardscan_cancel"
+
+    // MARK: - Identity Verification Flow
+    case verificationSheetPresented = "stripeios.idprod.verification_sheet.presented"
+    case verificationSheetClosed = "stripeios.idprod.verification_sheet.closed"
+    case verificationSheetFailed = "stripeios.idprod.verification_sheet.failed"
+
+    // MARK: - FinancialConnections
+    case financialConnectionsSheetPresented = "stripeios.financialconnections.sheet.presented"
+    case financialConnectionsSheetClosed = "stripeios.financialconnections.sheet.closed"
+    case financialConnectionsSheetFailed = "stripeios.financialconnections.sheet.failed"
+
+    // MARK: - PaymentSheet Init
+    case mcInitCustomCustomer = "mc_custom_init_customer"
+    case mcInitCompleteCustomer = "mc_complete_init_customer"
+    case mcInitCustomApplePay = "mc_custom_init_applepay"
+    case mcInitCompleteApplePay = "mc_complete_init_applepay"
+    case mcInitCustomCustomerApplePay = "mc_custom_init_customer_applepay"
+    case mcInitCompleteCustomerApplePay = "mc_complete_init_customer_applepay"
+    case mcInitCustomDefault = "mc_custom_init_default"
+    case mcInitCompleteDefault = "mc_complete_init_default"
+
+    // MARK: - PaymentSheet Show
+    case mcShowCustomNewPM = "mc_custom_sheet_newpm_show"
+    case mcShowCustomSavedPM = "mc_custom_sheet_savedpm_show"
+    case mcShowCustomApplePay = "mc_custom_sheet_applepay_show"
+    case mcShowCustomLink = "mc_custom_sheet_link_show"
+    case mcShowCompleteNewPM = "mc_complete_sheet_newpm_show"
+    case mcShowCompleteSavedPM = "mc_complete_sheet_savedpm_show"
+    case mcShowCompleteApplePay = "mc_complete_sheet_applepay_show"
+    case mcShowCompleteLink = "mc_complete_sheet_link_show"
+
+    // MARK: - PaymentSheet Payment
+    case mcPaymentCustomNewPMSuccess = "mc_custom_payment_newpm_success"
+    case mcPaymentCustomSavedPMSuccess = "mc_custom_payment_savedpm_success"
+    case mcPaymentCustomApplePaySuccess = "mc_custom_payment_applepay_success"
+    case mcPaymentCustomLinkSuccess = "mc_custom_payment_link_success"
+
+    case mcPaymentCompleteNewPMSuccess = "mc_complete_payment_newpm_success"
+    case mcPaymentCompleteSavedPMSuccess = "mc_complete_payment_savedpm_success"
+    case mcPaymentCompleteApplePaySuccess = "mc_complete_payment_applepay_success"
+    case mcPaymentCompleteLinkSuccess = "mc_complete_payment_link_success"
+
+    case mcPaymentCustomNewPMFailure = "mc_custom_payment_newpm_failure"
+    case mcPaymentCustomSavedPMFailure = "mc_custom_payment_savedpm_failure"
+    case mcPaymentCustomApplePayFailure = "mc_custom_payment_applepay_failure"
+    case mcPaymentCustomLinkFailure = "mc_custom_payment_link_failure"
+
+    case mcPaymentCompleteNewPMFailure = "mc_complete_payment_newpm_failure"
+    case mcPaymentCompleteSavedPMFailure = "mc_complete_payment_savedpm_failure"
+    case mcPaymentCompleteApplePayFailure = "mc_complete_payment_applepay_failure"
+    case mcPaymentCompleteLinkFailure = "mc_complete_payment_link_failure"
+
+    // MARK: - PaymentSheet Option Selected
+    case mcOptionSelectCustomNewPM = "mc_custom_paymentoption_newpm_select"
+    case mcOptionSelectCustomSavedPM = "mc_custom_paymentoption_savedpm_select"
+    case mcOptionSelectCustomApplePay = "mc_custom_paymentoption_applepay_select"
+    case mcOptionSelectCustomLink = "mc_custom_paymentoption_link_select"
+    case mcOptionSelectCompleteNewPM = "mc_complete_paymentoption_newpm_select"
+    case mcOptionSelectCompleteSavedPM = "mc_complete_paymentoption_savedpm_select"
+    case mcOptionSelectCompleteApplePay = "mc_complete_paymentoption_applepay_select"
+    case mcOptionSelectCompleteLink = "mc_complete_paymentoption_link_select"
+
+    // MARK: - Link Signup
+    case linkSignupCheckboxChecked = "link.signup.checkbox_checked"
+    case linkSignupFlowPresented = "link.signup.flow_presented"
+    case linkSignupStart = "link.signup.start"
+    case linkSignupComplete = "link.signup.complete"
+    case linkSignupFailure = "link.signup.failure"
+
+    // MARK: - Link Popup
+    case linkPopupShow = "link.popup.show"
+    case linkPopupSuccess = "link.popup.success"
+    case linkPopupCancel = "link.popup.cancel"
+    case linkPopupSkipped = "link.popup.skipped"
+    case linkPopupError = "link.popup.error"
+    case linkPopupLogout = "link.popup.logout"
+
+    // MARK: - Link Misc
+    case linkAccountLookupFailure = "link.account_lookup.failure"
+
+    // MARK: - LUXE
+    case luxeSerializeFailure = "luxe_serialize_failure"
+
+    case luxeImageSelectorIconDownloaded = "luxe_image_selector_icon_downloaded"
+    case luxeImageSelectorIconFromBundle = "luxe_image_selector_icon_from_bundle"
+    case luxeImageSelectorIconNotFound = "luxe_image_selector_icon_not_found"
+
+    // MARK: - Customer Sheet
+    case cs_add_payment_method_screen_presented = "cs_add_payment_method_screen_presented"
+    case cs_select_payment_method_screen_presented = "cs_select_payment_method_screen_presented"
+
+    case cs_select_payment_method_screen_confirmed_savedpm_success = "cs_select_payment_method_screen_confirmed_savedpm_success"
+    case cs_select_payment_method_screen_confirmed_savedpm_failure = "cs_select_payment_method_screen_confirmed_savedpm_failure"
+
+    case cs_select_payment_method_screen_edit_tapped = "cs_select_payment_method_screen_edit_tapped"
+    case cs_select_payment_method_screen_done_tapped = "cs_select_payment_method_screen_done_tapped"
+
+    case cs_select_payment_method_screen_removepm_success = "cs_select_payment_method_screen_removepm_success"
+    case cs_select_payment_method_screen_removepm_failure = "cs_select_payment_method_screen_removepm_failure"
+
+    case cs_add_payment_method_via_setupintent_success = "cs_add_payment_method_via_setup_intent_success"
+    case cs_add_payment_method_via_setupintent_canceled = "cs_add_payment_method_via_setupintent_canceled"
+    case cs_add_payment_method_via_setupintent_failure = "cs_add_payment_method_via_setup_intent_failure"
+
+    case cs_add_payment_method_via_createAttach_success = "cs_add_payment_method_via_createAttach_success"
+    case cs_add_payment_method_via_createAttach_failure = "cs_add_payment_method_via_createAttach_failure"
+
+    // MARK: - Address Element
+    case addressShow = "mc_address_show"
+    case addressCompleted = "mc_address_completed"
+
+    // MARK: - PaymentMethodMessagingView
+    case paymentMethodMessagingViewLoadSucceeded = "pmmv_load_succeeded"
+    case paymentMethodMessagingViewLoadFailed = "pmmv_load_failed"
+    case paymentMethodMessagingViewTapped = "pmmv_tapped"
+
+    // MARK: - PaymentSheet Force Success
+    case paymentSheetForceSuccess = "mc_force_success"
+
+    // MARK: - PaymentSheet initialization
+    case paymentSheetLoadStarted = "mc_load_started"
+    case paymentSheetLoadSucceeded = "mc_load_succeeded"
+    case paymentSheetLoadFailed = "mc_load_failed"
+
+    // MARK: - PaymentSheet dismiss
+    case paymentSheetDismissed = "mc_dismiss"
+
+    // MARK: - PaymentSheet checkout
+    case paymentSheetCarouselPaymentMethodTapped = "mc_carousel_payment_method_tapped"
+    case paymentSheetConfirmButtonTapped = "mc_confirm_button_tapped"
+}

+ 153 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/Analytics/STPAnalyticsClient.swift

@@ -0,0 +1,153 @@
+//
+//  STPAnalyticsClient.swift
+//  StripeCore
+//
+//  Created by Ben Guo on 4/22/16.
+//  Copyright © 2016 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+import UIKit
+
+@_spi(STP) public protocol STPAnalyticsProtocol {
+    static var stp_analyticsIdentifier: String { get }
+}
+
+@_spi(STP) public protocol STPAnalyticsClientProtocol {
+    func addClass<T: STPAnalyticsProtocol>(toProductUsageIfNecessary klass: T.Type)
+    func log(analytic: Analytic, apiClient: STPAPIClient)
+}
+
+@_spi(STP) public class STPAnalyticsClient: NSObject, STPAnalyticsClientProtocol {
+    @objc public static let sharedClient = STPAnalyticsClient()
+
+    @objc public var productUsage: Set<String> = Set()
+    private var additionalInfoSet: Set<String> = Set()
+    private var urlSession: URLSession {
+        // Set up a configuration with a background session ID
+        let configuration = URLSessionConfiguration.background(withIdentifier: "com.stripe.analyticsclient")
+
+        // Set configuration to discretionary
+        configuration.isDiscretionary = true
+        return URLSession(configuration: configuration)
+    }
+
+    @objc public class func tokenType(fromParameters parameters: [AnyHashable: Any]) -> String? {
+        let parameterKeys = parameters.keys
+
+        // Before SDK 23.0.0, this returned "card" for some Apple Pay payments.
+        if parameterKeys.contains("pk_token") {
+            return "apple_pay"
+        }
+        // these are currently mutually exclusive, so we can just run through and find the first match
+        let tokenTypes = ["account", "bank_account", "card", "pii", "cvc_update"]
+        if let type = tokenTypes.first(where: { parameterKeys.contains($0) }) {
+            return type
+        }
+        return nil
+    }
+
+    public func addClass<T: STPAnalyticsProtocol>(toProductUsageIfNecessary klass: T.Type) {
+        objc_sync_enter(self)
+        _ = productUsage.insert(klass.stp_analyticsIdentifier)
+        objc_sync_exit(self)
+    }
+
+    func addAdditionalInfo(_ info: String) {
+        _ = additionalInfoSet.insert(info)
+    }
+
+    public func clearAdditionalInfo() {
+        additionalInfoSet.removeAll()
+    }
+
+    // MARK: - Card Scanning
+
+    @objc class func shouldCollectAnalytics() -> Bool {
+        #if targetEnvironment(simulator)
+            return false
+        #else
+            return NSClassFromString("XCTest") == nil
+        #endif
+    }
+
+    public func additionalInfo() -> [String] {
+        return additionalInfoSet.sorted()
+    }
+
+    func logPayload(_ payload: [String: Any]) {
+        #if DEBUG
+            NSLog("LOG ANALYTICS: \(payload)")
+        #endif
+
+        guard type(of: self).shouldCollectAnalytics(),
+            let url = URL(string: "https://q.stripe.com")
+        else {
+            return
+        }
+
+        var request = URLRequest(url: url)
+        request.stp_addParameters(toURL: payload)
+        let task: URLSessionDataTask = urlSession.dataTask(with: request as URLRequest)
+        task.resume()
+    }
+
+    /// Creates a payload dictionary for the given analytic that includes the event name,
+    /// common payload, additional info, and product usage dictionary.
+    ///
+    /// - Parameters:
+    ///   - analytic: The analytic to log.
+    ///   - apiClient: The `STPAPIClient` instance with which this payload should be associated
+    ///     (i.e. publishable key). Defaults to `STPAPIClient.shared`.
+    func payload(from analytic: Analytic, apiClient: STPAPIClient = .shared) -> [String: Any] {
+        var payload = commonPayload(apiClient)
+
+        payload["event"] = analytic.event.rawValue
+        payload["additional_info"] = additionalInfo()
+        payload["product_usage"] = productUsage.sorted()
+
+        // Attach error information if this is an error analytic
+        if let errorAnalytic = analytic as? ErrorAnalytic {
+            payload["error_dictionary"] = errorAnalytic.error.serializeForLogging()
+        }
+
+        payload.merge(analytic.params) { (_, new) in new }
+        return payload
+    }
+
+    /// Logs an analytic with a payload dictionary that includes the event name, common payload,
+    /// additional info, and product usage dictionary.
+    ///
+    /// - Parameters
+    ///   - analytic: The analytic to log.
+    ///   - apiClient: The `STPAPIClient` instance with which this payload should be associated
+    ///     (i.e. publishable key). Defaults to `STPAPIClient.shared`.
+    public func log(analytic: Analytic, apiClient: STPAPIClient = .shared) {
+        logPayload(payload(from: analytic))
+    }
+}
+
+// MARK: - Helpers
+
+extension STPAnalyticsClient {
+    public func commonPayload(_ apiClient: STPAPIClient) -> [String: Any] {
+        var payload: [String: Any] = [:]
+        payload["bindings_version"] = StripeAPIConfiguration.STPSDKVersion
+        payload["analytics_ua"] = "analytics.stripeios-1.0"
+        let version = UIDevice.current.systemVersion
+        if !version.isEmpty {
+            payload["os_version"] = version
+        }
+        if let deviceType = STPDeviceUtils.deviceType {
+            payload["device_type"] = deviceType
+        }
+        payload["app_name"] = Bundle.stp_applicationName() ?? ""
+        payload["app_version"] = Bundle.stp_applicationVersion() ?? ""
+        payload["plugin_type"] = PluginDetector.shared.pluginType?.rawValue
+        payload["network_type"] = NetworkDetector.getConnectionType()
+        payload["install"] = InstallMethod.current.rawValue
+        payload["publishable_key"] = apiClient.sanitizedPublishableKey ?? "unknown"
+
+        return payload
+    }
+}

+ 15 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/Categories/Decimal+StripeCore.swift

@@ -0,0 +1,15 @@
+//
+//  Decimal+StripeCore.swift
+//  StripeCore
+//
+//  Created by Mel Ludowise on 4/14/22.
+//  Copyright © 2022 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+
+@_spi(STP) extension Decimal {
+    public var floatValue: Float {
+        return (self as NSDecimalNumber).floatValue
+    }
+}

+ 82 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/Categories/Dictionary+Stripe.swift

@@ -0,0 +1,82 @@
+//
+//  Dictionary+Stripe.swift
+//  StripeCore
+//
+//  Created by David Estes on 10/18/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+
+extension Dictionary {
+    static func stp_deepMerge(old: Any, new: Any) throws -> Any {
+        if let oldDictionary = old as? [String: Any],
+            let newDictionary = new as? [String: Any]
+        {
+            return try oldDictionary.merging(newDictionary, uniquingKeysWith: stp_deepMerge)
+        }
+        return new
+    }
+
+    /// Return the dictionary, minus any fields that also exist in
+    /// the passed dictionary.
+    func subtracting(_ subtractDict: Dictionary) -> Dictionary {
+        var newDict = self
+        for (key, value) in self {
+            if let equatableValue = value as? AnyHashable,
+                let equatableSubtractValue = subtractDict[key] as? AnyHashable
+            {
+                if equatableValue == equatableSubtractValue {
+                    newDict.removeValue(forKey: key)
+                    continue
+                }
+            }
+            if let dict1 = value as? Dictionary,
+                let dict2 = subtractDict[key] as? Dictionary
+            {
+                let subtractedDict = dict1.subtracting(dict2)
+                if subtractedDict.isEmpty {
+                    newDict.removeValue(forKey: key)
+                } else {
+                    newDict[key] = subtractedDict as? Value
+                }
+            }
+        }
+        return newDict
+    }
+}
+
+extension Dictionary where Value == Any {
+    func jsonEncodeNestedDicts(options: JSONSerialization.WritingOptions = []) -> [Key: Any] {
+        return compactMapValues { value in
+            guard let dict = value as? Dictionary else {
+                return value
+            }
+
+            // Note: An NSInvalidArgumentException can occur when the dict can't be
+            // serialized instead of throwing an error, resulting in an app crash.
+            // Call `isValidJSONObject` to ensure it's able to serialize the dict.
+            guard JSONSerialization.isValidJSONObject(dict),
+                let data = try? JSONSerialization.data(withJSONObject: dict, options: options)
+            else {
+                assertionFailure("Dictionary could not be serialized")
+                return nil
+            }
+
+            return String(data: data, encoding: .utf8)
+        }
+    }
+}
+
+// From https://talk.objc.io/episodes/S01E31-mutating-untyped-dictionaries
+extension Dictionary {
+    /// Example usage: `dict[jsonDict: "countries"]?[jsonDict: "japan"]?["capital"] = "berlin"`
+    subscript(jsonDict key: Key) -> [String: Any]? {
+        get {
+            return self[key] as? [String: Any]
+        }
+        set {
+            self[key] = newValue as? Value
+        }
+    }
+}

+ 29 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/Categories/Enums+CustomStringConvertible.swift

@@ -0,0 +1,29 @@
+//
+//  Enums+CustomStringConvertible.swift
+//  Stripe
+//
+//  Autogenerated by generate_objc_enum_string_values.rb
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+/// :nodoc:
+extension STPErrorCode: CustomStringConvertible {
+    public var description: String {
+        switch self {
+        case .apiError:
+            return "apiError"
+        case .authenticationError:
+            return "authenticationError"
+        case .cancellationError:
+            return "cancellationError"
+        case .cardError:
+            return "cardError"
+        case .connectionError:
+            return "connectionError"
+        case .ephemeralKeyDecodingError:
+            return "ephemeralKeyDecodingError"
+        case .invalidRequestError:
+            return "invalidRequestError"
+        }
+    }
+}

+ 31 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/Categories/NSArray+Stripe.swift

@@ -0,0 +1,31 @@
+//
+//  NSArray+Stripe.swift
+//  StripeCore
+//
+//  Created by Jack Flintermann on 1/19/16.
+//  Copyright © 2016 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+
+@_spi(STP) extension Array {
+    public func stp_boundSafeObject(at index: Int) -> Element? {
+        if index + 1 > count || index < 0 {
+            return nil
+        }
+        return self[index]
+    }
+}
+
+extension Array where Element == String {
+    public func caseInsensitiveContains(_ other: String) -> Bool {
+        return self.map { $0.uppercased() }.contains(other.uppercased())
+    }
+}
+
+extension Array where Element: Equatable {
+    @discardableResult public mutating func remove(_ element: Element) -> Element? {
+        guard let index = firstIndex(of: element) else { return nil }
+        return remove(at: index)
+    }
+}

+ 32 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/Categories/NSBundle+Stripe_AppName.swift

@@ -0,0 +1,32 @@
+//
+//  NSBundle+Stripe_AppName.swift
+//  StripeCore
+//
+//  Created by Jack Flintermann on 4/20/16.
+//  Copyright © 2016 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+
+extension Bundle {
+    @_spi(STP) public class func stp_applicationName() -> String? {
+        return self.main.infoDictionary?[kCFBundleNameKey as String] as? String
+    }
+
+    @_spi(STP) public class func stp_applicationVersion() -> String? {
+        return self.main.infoDictionary?["CFBundleShortVersionString"] as? String
+    }
+
+    @_spi(STP) public class func stp_applicationBundleId() -> String? {
+        return self.main.bundleIdentifier
+    }
+
+    @_spi(STP) public class func buildVersion() -> String? {
+        return self.main.infoDictionary?["CFBundleVersion"] as? String
+    }
+
+    @_spi(STP) public class var displayName: String? {
+        return self.main.object(forInfoDictionaryKey: "CFBundleDisplayName") as? String ?? self.main
+            .object(forInfoDictionaryKey: "CFBundleName") as? String
+    }
+}

+ 21 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/Categories/NSCharacterSet+StripeCore.swift

@@ -0,0 +1,21 @@
+//
+//  NSCharacterSet+StripeCore.swift
+//  StripeCore
+//
+//  Created by Brian Dorfman on 6/9/17.
+//  Copyright © 2017 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+
+@_spi(STP) extension CharacterSet {
+    public static let stp_asciiDigit = CharacterSet(charactersIn: "0123456789")
+    public static let stp_asciiLetters = CharacterSet(
+        charactersIn: "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"
+    )
+    public static let stp_invertedAsciiDigit = stp_asciiDigit.inverted
+    public static let stp_postalCode = CharacterSet(
+        charactersIn: "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789- "
+    )
+    public static let stp_invertedPostalCode = stp_postalCode.inverted
+}

+ 135 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/Categories/NSError+Stripe.swift

@@ -0,0 +1,135 @@
+//
+//  NSError+Stripe.swift
+//  StripeCore
+//
+//  Created by Brian Dorfman on 8/4/17.
+//  Copyright © 2017 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+
+extension NSError {
+    @objc @_spi(STP) public class func stp_genericConnectionError() -> NSError {
+        let userInfo = [
+            NSLocalizedDescriptionKey: self.stp_unexpectedErrorMessage(),
+            STPError.errorMessageKey: "There was an error connecting to Stripe.",
+        ]
+        return NSError(
+            domain: STPError.stripeDomain,
+            code: STPErrorCode.connectionError.rawValue,
+            userInfo: userInfo
+        )
+    }
+
+    @objc @_spi(STP) public class func stp_genericFailedToParseResponseError() -> NSError {
+        let userInfo = [
+            NSLocalizedDescriptionKey: self.stp_unexpectedErrorMessage(),
+            STPError.errorMessageKey:
+                "The response from Stripe failed to get parsed into valid JSON.",
+        ]
+        return NSError(
+            domain: STPError.stripeDomain,
+            code: STPErrorCode.apiError.rawValue,
+            userInfo: userInfo
+        )
+    }
+
+    @objc @_spi(STP) public class func stp_ephemeralKeyDecodingError() -> NSError {
+        let userInfo = [
+            NSLocalizedDescriptionKey: self.stp_unexpectedErrorMessage(),
+            STPError.errorMessageKey:
+                "Failed to decode the ephemeral key. Make sure your backend is sending the unmodified JSON of the ephemeral key to your app.",
+        ]
+        return NSError(
+            domain: STPError.stripeDomain,
+            code: STPErrorCode.ephemeralKeyDecodingError.rawValue,
+            userInfo: userInfo
+        )
+    }
+
+    @objc @_spi(STP) public class func stp_clientSecretError() -> NSError {
+        let userInfo = [
+            NSLocalizedDescriptionKey: self.stp_unexpectedErrorMessage(),
+            STPError.errorMessageKey:
+                "The `secret` format does not match expected client secret formatting.",
+        ]
+        return NSError(
+            domain: STPError.stripeDomain,
+            code: STPErrorCode.invalidRequestError.rawValue,
+            userInfo: userInfo
+        )
+    }
+
+    // TODO(davide): We'll want to move these into StripePayments, once it exists.
+
+    // MARK: Strings
+    @objc @_spi(STP) public class func stp_cardErrorInvalidNumberUserMessage() -> String {
+        return STPLocalizedString(
+            "Your card's number is invalid",
+            "Error when the card number is not valid"
+        )
+    }
+
+    @objc @_spi(STP) public class func stp_cardInvalidCVCUserMessage() -> String {
+        return STPLocalizedString(
+            "Your card's security code is invalid",
+            "Error when the card's CVC is not valid"
+        )
+    }
+
+    @objc @_spi(STP) public class func stp_cardErrorInvalidExpMonthUserMessage() -> String {
+        return STPLocalizedString(
+            "Your card's expiration month is invalid",
+            "Error when the card's expiration month is not valid"
+        )
+    }
+
+    @objc @_spi(STP) public class func stp_cardErrorInvalidExpYearUserMessage() -> String {
+        return STPLocalizedString(
+            "Your card's expiration year is invalid",
+            "Error when the card's expiration year is not valid"
+        )
+    }
+
+    @objc @_spi(STP) public class func stp_cardErrorExpiredCardUserMessage() -> String {
+        return STPLocalizedString(
+            "Your card has expired",
+            "Error when the card has already expired"
+        )
+    }
+
+    @objc @_spi(STP) public class func stp_cardErrorDeclinedUserMessage() -> String {
+        return STPLocalizedString(
+            "Your card was declined",
+            "Error when the card was declined by the credit card networks"
+        )
+    }
+
+    @objc @_spi(STP) public class func stp_genericDeclineErrorUserMessage() -> String {
+        return STPLocalizedString(
+            "Your payment method was declined.",
+            "Error message when a payment method gets declined."
+        )
+    }
+
+    @objc @_spi(STP) public class func stp_cardErrorProcessingErrorUserMessage() -> String {
+        return STPLocalizedString(
+            "There was an error processing your card -- try again in a few seconds",
+            "Error when there is a problem processing the credit card"
+        )
+    }
+
+    @_spi(STP) public static var stp_invalidOwnerName: String {
+        return STPLocalizedString(
+            "Your name is invalid.",
+            "Error when customer's name is invalid"
+        )
+    }
+
+    @_spi(STP) public static var stp_invalidBankAccountIban: String {
+        return STPLocalizedString(
+            "The IBAN you entered is invalid.",
+            "An error message displayed when the customer's iban is invalid."
+        )
+    }
+}

+ 18 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/Categories/NSError+StripeCore.swift

@@ -0,0 +1,18 @@
+//
+//  NSError+StripeCore.swift
+//  StripeCore
+//
+//  Created by Mel Ludowise on 7/7/21.
+//  Copyright © 2021 Stripe, Inc. All rights reserved.
+//
+
+import Foundation
+
+@_spi(STP) extension NSError {
+    public class func stp_unexpectedErrorMessage() -> String {
+        return STPLocalizedString(
+            "There was an unexpected error -- try again in a few seconds",
+            "Unexpected error, such as a 500 from Stripe or a JSON parse error"
+        )
+    }
+}

+ 0 - 0
Pods/StripeCore/StripeCore/StripeCore/Source/Categories/NSMutableURLRequest+Stripe.swift


이 변경점에서 너무 많은 파일들이 변경되어 몇몇 파일들은 표시되지 않았습니다.