Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BANKCON-15711] Pass billing address and email address to payment details API #4148

Merged
merged 4 commits into from
Oct 29, 2024

Conversation

mats-stripe
Copy link
Collaborator

@mats-stripe mats-stripe commented Oct 16, 2024

Android equivalent: stripe/stripe-android#9446

Summary

This passes the billing address model and a billing email to the /consumers/payment_details/ API. More details: https://docs.google.com/document/d/1IP66DkxVK6DzeGCmuw00Gt9okFhEHQgM3lqBZSA-M4E/edit?usp=sharing

Motivation

BANKCON-15711

Testing

Unit tests, and I've verified the billing fields are correctly passed from MPE to the API call:

Screenshot 2024-10-16 at 3 12 25 PM

Changelog

N/a

}

if let billingEmail, !billingEmail.isEmpty {
parameters["billing_email_address"] = billingEmail
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comment on lines +38 to +44
case name
case line1 = "line_1"
case line2 = "line_2"
case city = "locality"
case state = "administrative_area"
case postalCode = "postal_code"
case countryCode = "country_code"
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link

github-actions bot commented Oct 16, 2024

🚨 New dead code detected in this PR:

FinancialConnectionsAPIClient.swift:246 warning: Function 'paymentDetails(consumerSessionClientSecret:bankAccountId:billingAddress:billingEmail:)' is unused

Please remove the dead code before merging.

If this is intentional, you can bypass this check by adding the label skip dead code check to this PR.

ℹ️ If this comment appears to be left in error, double check that the flagged code is actually used and/or make sure your branch is up-to-date with master.

@mats-stripe mats-stripe marked this pull request as ready for review October 17, 2024 13:24
@mats-stripe mats-stripe requested review from a team as code owners October 17, 2024 13:24
@mats-stripe mats-stripe force-pushed the mats/pass_billing_address_to_payment_details branch 2 times, most recently from 905cca9 to dd16f78 Compare October 18, 2024 20:07
Copy link

github-actions bot commented Oct 18, 2024

⚠️ Public API changes detected:

Stripe

- public var description: Swift.String {
+ get
+ }
- public var description: Swift.String {
+ get
+ }
- public var description: Swift.String {
+ get
+ }
- public var description: Swift.String {
+ get
+ }
+ @available(*, deprecated, message: "This initializer previously configured publishableKey and stripeAccount via the STPPaymentConfiguration instance. This behavior is deprecated; set the STPAPIClient configuration, publishableKey, and stripeAccount properties directly on the STPAPIClient instead.")
- public init(configuration: Stripe.STPPaymentConfiguration)
- public var configuration: Stripe.STPPaymentConfiguration {
+ @objc get
+ @objc set
+ }
- public init()
- public init(configuration: Stripe.STPPaymentConfiguration, theme: Stripe.STPTheme)
- public var delegate: (any Stripe.STPAddCardViewControllerDelegate)?
- public var prefilledInformation: Stripe.STPUserInformation? {
+ @objc get
+ @objc set
+ }
- public var customFooterView: UIKit.UIView? {
+ @objc get
+ @objc set(footerView)
+ }
- public var apiClient: StripeCore.STPAPIClient
- public func tableView(_ tableView: UIKit.UITableView, estimatedHeightForRowAt indexPath: Foundation.IndexPath) -> CoreFoundation.CGFloat
- public func viewDidLayoutSubviews()
- public func updateAppearance()
- public func viewDidAppear(_ animated: Swift.Bool)
- public func handleCancelTapped(_ sender: Any?)
- public func paymentCardTextFieldDidChange(_ textField: StripePaymentsUI.STPPaymentCardTextField)
- public func paymentCardTextFieldWillEndEditing(forReturn textField: StripePaymentsUI.STPPaymentCardTextField)
- public func paymentCardTextFieldDidBeginEditingCVC(_ textField: StripePaymentsUI.STPPaymentCardTextField)
- public func paymentCardTextFieldDidEndEditingCVC(_ textField: StripePaymentsUI.STPPaymentCardTextField)
- public func paymentCardTextFieldDidBeginEditing(_ textField: StripePaymentsUI.STPPaymentCardTextField)
- public func numberOfSections(in tableView: UIKit.UITableView) -> Swift.Int
- public func tableView(_ tableView: UIKit.UITableView, numberOfRowsInSection section: Swift.Int) -> Swift.Int
- public func tableView(_ tableView: UIKit.UITableView, cellForRowAt indexPath: Foundation.IndexPath) -> UIKit.UITableViewCell
- public func tableView(_ tableView: UIKit.UITableView, willDisplay cell: UIKit.UITableViewCell, forRowAt indexPath: Foundation.IndexPath)
- public func tableView(_ tableView: UIKit.UITableView, heightForFooterInSection section: Swift.Int) -> CoreFoundation.CGFloat
- public func tableView(_ tableView: UIKit.UITableView, heightForHeaderInSection section: Swift.Int) -> CoreFoundation.CGFloat
- public func tableView(_ tableView: UIKit.UITableView, viewForHeaderInSection section: Swift.Int) -> UIKit.UIView?
- public func tableView(_ tableView: UIKit.UITableView, viewForFooterInSection section: Swift.Int) -> UIKit.UIView?
- public func viewWillTransition(to size: CoreFoundation.CGSize, with coordinator: any UIKit.UIViewControllerTransitionCoordinator)
+ @objc deinit
+ @objc func addCardViewControllerDidCancel(_ addCardViewController: Stripe.STPAddCardViewController)
+ @objc func addCardViewController(_ addCardViewController: Stripe.STPAddCardViewController, didCreatePaymentMethod paymentMethod: StripePayments.STPPaymentMethod, completion: @escaping StripePayments.STPErrorBlock)
+ @available(*, deprecated, renamed: "addCardViewController(_:didCreatePaymentMethod:completion:)", message: "Use addCardViewController(_:didCreatePaymentMethod:completion:) instead and migrate your integration to PaymentIntents. See https://stripe.com/docs/payments/payment-intents/migration/charges#read")
+ @objc optional func addCardViewController(_ addCardViewController: Stripe.STPAddCardViewController, didCreateToken token: StripePayments.STPToken, completion: ((any Swift.Error)?) -> Swift.Void)
+ @available(*, deprecated, renamed: "addCardViewController(_:didCreatePaymentMethod:completion:)", message: "Use addCardViewController(_:didCreatePaymentMethod:completion:) instead and migrate your integration to PaymentIntents. See https://stripe.com/docs/payments/payment-intents/migration/charges#read")
+ @objc optional func addCardViewController(_ addCardViewController: Stripe.STPAddCardViewController, didCreateSource source: StripePayments.STPSource, completion: ((any Swift.Error)?) -> Swift.Void)
+ case none
+ case postalCode
+ case full
+ case name
+ @available(*, deprecated, message: "Use STPBillingAddressFields.postalCode instead")
+ case zip
- public init?(rawValue: Swift.UInt)
- public typealias RawValue = Swift.UInt
- public var rawValue: Swift.UInt {
+ get
+ }
- public func containsRequiredFields(_ requiredFields: Stripe.STPBillingAddressFields) -> Swift.Bool
- public func containsContent(for desiredFields: Stripe.STPBillingAddressFields) -> Swift.Bool
- public func containsRequiredShippingAddressFields(_ requiredFields: Swift.Set<StripePayments.STPContactField>?) -> Swift.Bool
- public func containsContent(forShippingAddressFields desiredFields: Swift.Set<StripePayments.STPContactField>?) -> Swift.Bool
- public class func applePayContactFields(from billingAddressFields: Stripe.STPBillingAddressFields) -> Swift.Set<PassKit.PKContactField>
- public class func pkContactFields(fromStripeContactFields contactFields: Swift.Set<StripePayments.STPContactField>?) -> Swift.Set<PassKit.PKContactField>?
- public var image: UIKit.UIImage {
+ @objc get
+ }
- public var templateImage: UIKit.UIImage {
+ @objc get
+ }
- public var label: Swift.String {
+ @objc get
+ }
- public var isReusable: Swift.Bool {
+ @objc get
+ }
- public func isEqual(_ object: Any?) -> Swift.Bool
- public var hash: Swift.Int {
+ @objc get
+ }
- public init()
+ @objc deinit
+ @objc func retrieveCustomer(_ completion: StripePayments.STPCustomerCompletionBlock?)
+ @objc func listPaymentMethodsForCustomer(completion: StripePayments.STPPaymentMethodsCompletionBlock?)
+ @objc func attachPaymentMethod(toCustomer paymentMethod: StripePayments.STPPaymentMethod, completion: StripePayments.STPErrorBlock?)
+ @objc optional func detachPaymentMethod(fromCustomer paymentMethod: StripePayments.STPPaymentMethod, completion: StripePayments.STPErrorBlock?)
+ @objc optional func updateCustomer(withShippingAddress shipping: StripePayments.STPAddress, completion: StripePayments.STPErrorBlock?)
+ case FPX
+ case unknown
- public init?(rawValue: Swift.Int)
- public typealias RawValue = Swift.Int
- public var rawValue: Swift.Int {
+ get
+ }
- public init(bankMethod: Stripe.STPBankSelectionMethod)
- public init(theme: Stripe.STPTheme?)
- public init(bankMethod: Stripe.STPBankSelectionMethod, configuration: Stripe.STPPaymentConfiguration, theme: Stripe.STPTheme)
- public var delegate: (any Stripe.STPBankSelectionViewControllerDelegate)?
- public var apiClient: StripeCore.STPAPIClient
+ @objc deinit
- public func numberOfSections(in tableView: UIKit.UITableView) -> Swift.Int
- public func tableView(_ tableView: UIKit.UITableView, numberOfRowsInSection section: Swift.Int) -> Swift.Int
- public func tableView(_ tableView: UIKit.UITableView, cellForRowAt indexPath: Foundation.IndexPath) -> UIKit.UITableViewCell
- public func tableView(_ tableView: UIKit.UITableView, willDisplay cell: UIKit.UITableViewCell, forRowAt indexPath: Foundation.IndexPath)
- public func tableView(_ tableView: UIKit.UITableView, heightForFooterInSection section: Swift.Int) -> CoreFoundation.CGFloat
- public func tableView(_ tableView: UIKit.UITableView, shouldHighlightRowAt indexPath: Foundation.IndexPath) -> Swift.Bool
- public func tableView(_ tableView: UIKit.UITableView, didSelectRowAt indexPath: Foundation.IndexPath)
+ @objc(bankSelectionViewController:didCreatePaymentMethodParams:) func bankSelectionViewController(_ bankViewController: Stripe.STPBankSelectionViewController, didCreatePaymentMethodParams paymentMethodParams: StripePayments.STPPaymentMethodParams)
+ case shipping
+ case delivery
- public init?(rawValue: Swift.Int)
- public typealias RawValue = Swift.Int
- public var rawValue: Swift.Int {
+ get
+ }
+ case valid
+ case invalid
- public init?(rawValue: Swift.Int)
- public typealias RawValue = Swift.Int
- public var rawValue: Swift.Int {
+ get
+ }
- public var image: UIKit.UIImage {
+ @objc get
+ }
- public var templateImage: UIKit.UIImage {
+ @objc get
+ }
- public var label: Swift.String {
+ @objc get
+ }
- public var isReusable: Swift.Bool {
+ @objc get
+ }
- public var scrollView: UIKit.UIScrollView {
+ @objc get
+ @objc set
+ }
- public func viewDidLoad()
- public func viewDidLayoutSubviews()
- public init(theme: Stripe.STPTheme?)
- public init(nibName nibNameOrNil: Swift.String?, bundle nibBundleOrNil: Foundation.Bundle?)
- public init?(coder aDecoder: Foundation.NSCoder)
+ @objc deinit
- public var tableView: UIKit.UITableView? {
+ @objc get
+ }
- public func viewWillAppear(_ animated: Swift.Bool)
- public func tableView(_ tableView: UIKit.UITableView, heightForHeaderInSection section: Swift.Int) -> CoreFoundation.CGFloat
- public init(theme: Stripe.STPTheme?)
- public init(nibName nibNameOrNil: Swift.String?, bundle nibBundleOrNil: Foundation.Bundle?)
- public init?(coder aDecoder: Foundation.NSCoder)
+ @objc deinit
- public init()
- public init(theme: Stripe.STPTheme?)
- public init(nibName nibNameOrNil: Swift.String?, bundle nibBundleOrNil: Foundation.Bundle?)
- public init?(coder aDecoder: Foundation.NSCoder)
- public func viewDidLoad()
- public func viewWillAppear(_ animated: Swift.Bool)
- public func viewWillDisappear(_ animated: Swift.Bool)
- public var preferredStatusBarStyle: UIKit.UIStatusBarStyle {
+ @objc get
+ }
+ @objc deinit
- public init(keyProvider: any Stripe.STPCustomerEphemeralKeyProvider)
- public init(keyProvider: (any Stripe.STPCustomerEphemeralKeyProvider)?, apiClient: StripeCore.STPAPIClient)
- public func clearCache()
- public var includeApplePayPaymentMethods: Swift.Bool {
+ @objc get
+ @objc set(includeApplePayMethods)
+ }
- public func retrieveCustomer(_ completion: StripePayments.STPCustomerCompletionBlock? = nil)
- public func updateCustomer(withShippingAddress shipping: StripePayments.STPAddress, completion: StripePayments.STPErrorBlock?)
- public func attachPaymentMethodToCustomer(paymentMethodId: Swift.String, completion: StripePayments.STPErrorBlock?)
- public func attachPaymentMethod(toCustomer paymentMethod: StripePayments.STPPaymentMethod, completion: StripePayments.STPErrorBlock?)
- public func detachPaymentMethodFromCustomer(paymentMethodId: Swift.String, completion: StripePayments.STPErrorBlock?)
- public func detachPaymentMethod(fromCustomer paymentMethod: StripePayments.STPPaymentMethod, completion: StripePayments.STPErrorBlock?)
- public func listPaymentMethodsForCustomer(completion: StripePayments.STPPaymentMethodsCompletionBlock? = nil)
+ @objc deinit
+ @objc deinit
- public func setAnimating(_ animating: Swift.Bool, animated: Swift.Bool)
- public var animating: Swift.Bool {
+ @objc get
+ @objc set(animating)
+ }
- public var hidesWhenStopped: Swift.Bool {
+ @objc get
+ @objc set(hidesWhenStopped)
+ }
- public var tintColor: UIKit.UIColor! {
+ @objc get
+ @objc set(tintColor)
+ }
- public func layoutSubviews()
+ @objc deinit
- public static var shared: Stripe.STPPaymentConfiguration
- public var applePayEnabled: Swift.Bool {
+ @objc get
+ @objc set
+ }
- public var fpxEnabled: Swift.Bool
- public var requiredBillingAddressFields: Stripe.STPBillingAddressFields
- public var requiredShippingAddressFields: Swift.Set<StripePayments.STPContactField>?
- public var verifyPrefilledShippingAddress: Swift.Bool
- public var shippingType: Stripe.STPShippingType
- public var availableCountries: Swift.Set<Swift.String>
- public var companyName: Swift.String
- public var appleMerchantIdentifier: Swift.String?
- public var canDeletePaymentOptions: Swift.Bool
- public var cardScanningEnabled: Swift.Bool
+ @available(*, deprecated, message: "additionalPaymentOptions has been removed. Set applePayEnabled and fpxEnabled on STPPaymentConfiguration instead.")
- public var additionalPaymentOptions: Swift.Int
+ @available(*, deprecated, message: "If you used STPPaymentConfiguration.shared.publishableKey, use STPAPIClient.shared.publishableKey instead. If you passed a STPPaymentConfiguration instance to an SDK component, create an STPAPIClient, set publishableKey on it, and set the SDK component's APIClient property.")
- public var publishableKey: Swift.String? {
+ @objc get
+ @objc set(publishableKey)
+ }
+ @available(*, deprecated, message: "If you used STPPaymentConfiguration.shared.stripeAccount, use STPAPIClient.shared.stripeAccount instead. If you passed a STPPaymentConfiguration instance to an SDK component, create an STPAPIClient, set stripeAccount on it, and set the SDK component's APIClient property.")
- public var stripeAccount: Swift.String? {
+ @objc get
+ @objc set(stripeAccount)
+ }
- public var description: Swift.String {
+ @objc get
+ }
- public func copy(with zone: ObjectiveC.NSZone? = nil) -> Any
- public init()
+ @objc deinit
- public init(customerContext: Stripe.STPCustomerContext)
- public init(customerContext: Stripe.STPCustomerContext, configuration: Stripe.STPPaymentConfiguration, theme: Stripe.STPTheme)
- public init(apiAdapter: any Stripe.STPBackendAPIAdapter)
- public init(apiAdapter: any Stripe.STPBackendAPIAdapter, configuration: Stripe.STPPaymentConfiguration, theme: Stripe.STPTheme)
- public var apiAdapter: any Stripe.STPBackendAPIAdapter {
+ get
+ }
- public var configuration: Stripe.STPPaymentConfiguration {
+ get
+ }
- public var theme: Stripe.STPTheme {
+ get
+ }
- public var prefilledInformation: Stripe.STPUserInformation? {
+ @objc get
+ @objc set(prefilledInformation)
+ }
- public var hostViewController: UIKit.UIViewController? {
+ @objc get
+ @objc set(hostViewController)
+ }
- public var delegate: (any Stripe.STPPaymentContextDelegate)? {
+ @objc get
+ @objc set(delegate)
+ }
- public var loading: Swift.Bool {
+ @objc get
+ }
- public var defaultPaymentMethod: Swift.String?
- public var selectedPaymentOption: (any Stripe.STPPaymentOption)? {
+ @objc get
+ }
- public var paymentOptions: [any Stripe.STPPaymentOption]? {
+ @objc get
+ }
- public var selectedShippingMethod: PassKit.PKShippingMethod? {
+ get
+ }
- public var shippingMethods: [PassKit.PKShippingMethod]? {
+ @objc get
+ }
- public var shippingAddress: StripePayments.STPAddress? {
+ get
+ }
- public var paymentAmount: Swift.Int {
+ @objc get
+ @objc set(paymentAmount)
+ }
- public var paymentCurrency: Swift.String
- public var paymentCountry: Swift.String
- public var paymentSummaryItems: [PassKit.PKPaymentSummaryItem] {
+ @objc get
+ @objc set(paymentSummaryItems)
+ }
+ @available(macOS 14.0, iOS 17.0, *)
- public var applePayLaterAvailability: PassKit.PKApplePayLaterAvailability {
+ @objc get
+ @objc set
+ }
- public var modalPresentationStyle: UIKit.UIModalPresentationStyle
- public var largeTitleDisplayMode: UIKit.UINavigationItem.LargeTitleDisplayMode
- public var paymentOptionsViewControllerFooterView: UIKit.UIView?
- public var addCardViewControllerFooterView: UIKit.UIView?
- public var apiClient: StripeCore.STPAPIClient {
+ get
+ set
+ }
- public func retryLoading()
- public func presentPaymentOptionsViewController()
- public func pushPaymentOptionsViewController()
- public func presentShippingViewController()
- public func pushShippingViewController()
- public func requestPayment()
- public func paymentOptionsViewController(_ paymentOptionsViewController: Stripe.STPPaymentOptionsViewController, didSelect paymentOption: any Stripe.STPPaymentOption)
- public func paymentOptionsViewControllerDidFinish(_ paymentOptionsViewController: Stripe.STPPaymentOptionsViewController)
- public func paymentOptionsViewControllerDidCancel(_ paymentOptionsViewController: Stripe.STPPaymentOptionsViewController)
- public func paymentOptionsViewController(_ paymentOptionsViewController: Stripe.STPPaymentOptionsViewController, didFailToLoadWithError error: any Swift.Error)
- public func shippingAddressViewControllerDidCancel(_ addressViewController: Stripe.STPShippingAddressViewController)
- public func shippingAddressViewController(_ addressViewController: Stripe.STPShippingAddressViewController, didEnter address: StripePayments.STPAddress, completion: @escaping Stripe.STPShippingMethodsCompletionBlock)
- public func shippingAddressViewController(_ addressViewController: Stripe.STPShippingAddressViewController, didFinishWith address: StripePayments.STPAddress, shippingMethod method: PassKit.PKShippingMethod?)
- public func authenticationPresentingViewController() -> UIKit.UIViewController
- public func prepare(forPresentation completion: @escaping StripePayments.STPVoidBlock)
+ @objc func paymentContext(_ paymentContext: Stripe.STPPaymentContext, didFailToLoadWithError error: any Swift.Error)
+ @objc func paymentContextDidChange(_ paymentContext: Stripe.STPPaymentContext)
+ @objc func paymentContext(_ paymentContext: Stripe.STPPaymentContext, didCreatePaymentResult paymentResult: Stripe.STPPaymentResult, completion: @escaping StripePayments.STPPaymentStatusBlock)
+ @objc func paymentContext(_ paymentContext: Stripe.STPPaymentContext, didFinishWith status: StripePayments.STPPaymentStatus, error: (any Swift.Error)?)
+ @objc optional func paymentContext(_ paymentContext: Stripe.STPPaymentContext, didUpdateShippingAddress address: StripePayments.STPAddress, completion: @escaping Stripe.STPShippingMethodsCompletionBlock)
- public func configure(with paymentResult: Stripe.STPPaymentResult)
- public var image: UIKit.UIImage {
+ @objc get
+ }
- public var templateImage: UIKit.UIImage {
+ @objc get
+ }
- public var label: Swift.String {
+ @objc get
+ }
- public var isReusable: Swift.Bool {
+ @objc get
+ }
- public var image: UIKit.UIImage {
+ @objc get
+ }
- public var templateImage: UIKit.UIImage {
+ @objc get
+ }
- public var isReusable: Swift.Bool {
+ @objc get
+ }
+ @objc var image: UIKit.UIImage { get }
+ @objc var templateImage: UIKit.UIImage { get }
+ @objc var label: Swift.String { get }
+ @objc var isReusable: Swift.Bool { get }
- public init(paymentContext: Stripe.STPPaymentContext)
- public init(configuration: Stripe.STPPaymentConfiguration, theme: Stripe.STPTheme, customerContext: Stripe.STPCustomerContext, delegate: any Stripe.STPPaymentOptionsViewControllerDelegate)
- public init(configuration: Stripe.STPPaymentConfiguration, theme: Stripe.STPTheme, apiAdapter: any Stripe.STPBackendAPIAdapter, delegate: any Stripe.STPPaymentOptionsViewControllerDelegate)
- public var prefilledInformation: Stripe.STPUserInformation? {
+ @objc get
+ @objc set
+ }
- public var defaultPaymentMethod: Swift.String?
- public var paymentOptionsViewControllerFooterView: UIKit.UIView? {
+ @objc get
+ @objc set
+ }
- public var addCardViewControllerFooterView: UIKit.UIView? {
+ @objc get
+ @objc set
+ }
- public var apiClient: StripeCore.STPAPIClient
- public func dismiss(withCompletion completion: StripePayments.STPVoidBlock?)
+ @available(*, unavailable, message: "Use one of the initializers declared in this interface instead.")
- public init(theme: Stripe.STPTheme?)
+ @available(*, unavailable, message: "Use one of the initializers declared in this interface instead.")
- public init(nibName nibNameOrNil: Swift.String?, bundle nibBundleOrNil: Foundation.Bundle?)
+ @available(*, unavailable, message: "Use one of the initializers declared in this interface instead.")
- public init?(coder aDecoder: Foundation.NSCoder)
- public func viewDidLayoutSubviews()
- public func viewDidAppear(_ animated: Swift.Bool)
- public func addCardViewControllerDidCancel(_ addCardViewController: Stripe.STPAddCardViewController)
- public func addCardViewController(_ addCardViewController: Stripe.STPAddCardViewController, didCreatePaymentMethod paymentMethod: StripePayments.STPPaymentMethod, completion: @escaping StripePayments.STPErrorBlock)
+ @objc deinit
+ @objc func paymentOptionsViewController(_ paymentOptionsViewController: Stripe.STPPaymentOptionsViewController, didFailToLoadWithError error: any Swift.Error)
+ @objc func paymentOptionsViewControllerDidFinish(_ paymentOptionsViewController: Stripe.STPPaymentOptionsViewController)
+ @objc func paymentOptionsViewControllerDidCancel(_ paymentOptionsViewController: Stripe.STPPaymentOptionsViewController)
+ @objc(paymentOptionsViewController:didSelectPaymentOption:) optional func paymentOptionsViewController(_ paymentOptionsViewController: Stripe.STPPaymentOptionsViewController, didSelect paymentOption: any Stripe.STPPaymentOption)
- public var paymentMethod: StripePayments.STPPaymentMethod? {
+ get
+ }
- public var paymentMethodParams: StripePayments.STPPaymentMethodParams? {
+ get
+ }
- public var paymentOption: (any Stripe.STPPaymentOption)? {
+ @objc get
+ }
- public init(paymentOption: (any Stripe.STPPaymentOption)?)
+ @objc deinit
- public init()
- public init(paymentContext: Stripe.STPPaymentContext)
- public init(configuration: Stripe.STPPaymentConfiguration, theme: Stripe.STPTheme, currency: Swift.String?, shippingAddress: StripePayments.STPAddress?, selectedShippingMethod: PassKit.PKShippingMethod?, prefilledInformation: Stripe.STPUserInformation?)
- public var delegate: (any Stripe.STPShippingAddressViewControllerDelegate)?
- public func dismiss(withCompletion completion: StripePayments.STPVoidBlock?)
+ @available(*, unavailable, message: "Use one of the initializers declared in this interface instead.")
- public init(theme: Stripe.STPTheme?)
+ @available(*, unavailable, message: "Use one of the initializers declared in this interface instead.")
- public init(nibName nibNameOrNil: Swift.String?, bundle nibBundleOrNil: Foundation.Bundle?)
- public func viewDidAppear(_ animated: Swift.Bool)
- public func tableView(_ tableView: UIKit.UITableView, heightForHeaderInSection section: Swift.Int) -> CoreFoundation.CGFloat
+ @objc deinit
+ @objc func shippingAddressViewControllerDidCancel(_ addressViewController: Stripe.STPShippingAddressViewController)
+ @objc(shippingAddressViewController:didEnterAddress:completion:) func shippingAddressViewController(_ addressViewController: Stripe.STPShippingAddressViewController, didEnter address: StripePayments.STPAddress, completion: @escaping Stripe.STPShippingMethodsCompletionBlock)
+ @objc(shippingAddressViewController:didFinishWithAddress:shippingMethod:) func shippingAddressViewController(_ addressViewController: Stripe.STPShippingAddressViewController, didFinishWith address: StripePayments.STPAddress, shippingMethod method: PassKit.PKShippingMethod?)
- public func numberOfSections(in tableView: UIKit.UITableView) -> Swift.Int
- public func tableView(_ tableView: UIKit.UITableView, numberOfRowsInSection section: Swift.Int) -> Swift.Int
- public func tableView(_ tableView: UIKit.UITableView, cellForRowAt indexPath: Foundation.IndexPath) -> UIKit.UITableViewCell
- public func tableView(_ tableView: UIKit.UITableView, willDisplay cell: UIKit.UITableViewCell, forRowAt indexPath: Foundation.IndexPath)
- public func tableView(_ tableView: UIKit.UITableView, heightForFooterInSection section: Swift.Int) -> CoreFoundation.CGFloat
- public func tableView(_ tableView: UIKit.UITableView, viewForFooterInSection section: Swift.Int) -> UIKit.UIView?
- public func tableView(_ tableView: UIKit.UITableView, viewForHeaderInSection section: Swift.Int) -> UIKit.UIView?
- public var image: UIKit.UIImage {
+ @objc get
+ }
- public var templateImage: UIKit.UIImage {
+ @objc get
+ }
- public var label: Swift.String {
+ @objc get
+ }
- public var isReusable: Swift.Bool {
+ @objc get
+ }
- public static let defaultTheme: Stripe.STPTheme
+ @available(*, deprecated, renamed: "defaultTheme", message: "Use defaultTheme instead")
- public static func `default`() -> Stripe.STPTheme
- public var primaryBackgroundColor: UIKit.UIColor
- public var secondaryBackgroundColor: UIKit.UIColor
- public var tertiaryBackgroundColor: UIKit.UIColor {
+ @objc get
+ }
- public var quaternaryBackgroundColor: UIKit.UIColor {
+ @objc get
+ }
- public var primaryForegroundColor: UIKit.UIColor
- public var secondaryForegroundColor: UIKit.UIColor
- public var tertiaryForegroundColor: UIKit.UIColor {
+ @objc get
+ }
- public var accentColor: UIKit.UIColor
- public var errorColor: UIKit.UIColor
- public var font: UIKit.UIFont {
+ @objc get
+ @objc set
+ }
- public var emphasisFont: UIKit.UIFont {
+ @objc get
+ @objc set
+ }
- public var barStyle: UIKit.UIBarStyle {
+ @objc get
+ @objc set
+ }
- public var translucentNavigationBar: Swift.Bool
- public var smallFont: UIKit.UIFont {
+ @objc get
+ }
- public var largeFont: UIKit.UIFont {
+ @objc get
+ }
- public init()
+ @objc deinit
- public func copy(with zone: ObjectiveC.NSZone? = nil) -> Any
- public var billingAddress: StripePayments.STPAddress?
- public var shippingAddress: StripePayments.STPAddress?
- public func setBillingAddress(with billingDetails: StripePayments.STPPaymentMethodBillingDetails)
- public func copy(with zone: ObjectiveC.NSZone? = nil) -> Any
- public init()
+ @objc deinit
+ @available(*, deprecated, message: "Use the `stp_theme` property instead")
- public func stp_setTheme(_ theme: Stripe.STPTheme)
- public var stp_theme: Stripe.STPTheme? {
+ @objc get
+ @objc set(theme)
+ }

StripePayments

- public var label: Swift.String {
+ @objc get
+ }

If you are adding a new public API consider the following:

  • Do these APIs need to be public or can they be protected with @_spi(STP)?
  • If these APIs need to be public, assess whether they require an API review.

If you are modifying or removing a public API:

  • Does this require a breaking version change?
  • Do these changes require API review?

If you confirm these APIs need to be added/updated and have undergone necessary review, add the label modifies public API to this PR to acknowledge and bypass this check.

ℹ️ If this comment appears to be left in error, make sure your branch is up-to-date with master.

@mats-stripe
Copy link
Collaborator Author

Moving this to draft for now, since this PR will change slightly with this work: #4162

@mats-stripe mats-stripe marked this pull request as draft October 21, 2024 13:52
@mats-stripe mats-stripe force-pushed the mats/pass_billing_address_to_payment_details branch from dd16f78 to 8e2d09b Compare October 21, 2024 17:47
@mats-stripe mats-stripe changed the base branch from master to mats/add_requested_fields_in_bank_tab October 21, 2024 17:47
@mats-stripe mats-stripe marked this pull request as ready for review October 21, 2024 17:48
Copy link

emerge-tools bot commented Oct 21, 2024

📸 Snapshot Test

No snapshots generated

Name Version Added Removed Modified Unchanged Errored Approval
StripeSize
com.stripe.StripeSize
1.0 (1) 0 0 0 0 0 N/A
StripePaymentSheetSize
com.stripe.StripePaymentSheetSize
1.0 (1) 0 0 0 0 0 N/A
StripeFinancialConnectionsSize
com.stripe.StripeFinancialConnectionsSize
1.0 (1) 0 0 0 0 0 N/A
StripeApplePaySize
com.stripe.StripeApplePaySize
1.0 (1) 0 0 0 0 0 N/A
StripePaymentsSize
com.stripe.StripePaymentsSize
1.0 (1) 0 0 0 0 0 N/A
StripePaymentsUISize
com.stripe.StripePaymentsUISize
1.0 (1) 0 0 0 0 0 N/A

🛸 Powered by Emerge Tools

@mats-stripe mats-stripe force-pushed the mats/add_requested_fields_in_bank_tab branch from 764ccf7 to 594cdd6 Compare October 22, 2024 14:39
@mats-stripe mats-stripe force-pushed the mats/pass_billing_address_to_payment_details branch 4 times, most recently from 9dfabf9 to cf1076b Compare October 24, 2024 14:14
@mats-stripe mats-stripe force-pushed the mats/add_requested_fields_in_bank_tab branch from aaf0034 to 73eda16 Compare October 24, 2024 14:54
Base automatically changed from mats/add_requested_fields_in_bank_tab to master October 24, 2024 17:49
@mats-stripe mats-stripe force-pushed the mats/pass_billing_address_to_payment_details branch from cf1076b to 9a0d88b Compare October 24, 2024 18:44
Copy link

emerge-tools bot commented Oct 29, 2024

6 builds increased size

Name Version Download Change Install Change Approval
StripeSize
com.stripe.StripeSize
1.0 (1) 2.1 MB ⬆️ 3.9 kB (0.19%) 6.8 MB ⬆️ 9.0 kB (0.13%) N/A
StripeApplePaySize
com.stripe.StripeApplePaySize
1.0 (1) 441.2 kB ⬆️ 3.1 kB (0.7%) 1.6 MB ⬆️ 8.0 kB (0.53%) N/A
StripeFinancialConnectionsSize
com.stripe.StripeFinancialConnectionsSize
1.0 (1) 1.3 MB ⬆️ 5.1 kB (0.39%) 4.3 MB ⬆️ 14.1 kB (0.33%) N/A
StripePaymentsSize
com.stripe.StripePaymentsSize
1.0 (1) 1.2 MB ⬆️ 3.8 kB (0.33%) 4.1 MB ⬆️ 8.6 kB (0.21%) N/A
StripePaymentsUISize
com.stripe.StripePaymentsUISize
1.0 (1) 1.9 MB ⬆️ 3.2 kB (0.17%) 6.3 MB ⬆️ 8.6 kB (0.14%) N/A
StripePaymentSheetSize
com.stripe.StripePaymentSheetSize
1.0 (1) 3.5 MB ⬆️ 7.5 kB (0.21%) 10.6 MB ⬆️ 14.7 kB (0.14%) N/A

StripeSize 1.0 (1)
com.stripe.StripeSize

⚖️ Compare build
⏱️ Analyze build performance

Total install size change: ⬆️ 9.0 kB (0.13%)
Total download size change: ⬆️ 3.9 kB (0.19%)

Largest size changes

Item Install Size Change
StripeCore.ElementsSessionContext.value witness ⬆️ 960 B
📝 StripeCore.BillingAddress.encode(to) ⬆️ 920 B
📝 StripeCore.BillingAddress.value witness ⬆️ 912 B
Other ⬆️ 6.2 kB
View Treemap

Image of diff

StripeApplePaySize 1.0 (1)
com.stripe.StripeApplePaySize

⚖️ Compare build
⏱️ Analyze build performance

Total install size change: ⬆️ 8.0 kB (0.53%)
Total download size change: ⬆️ 3.1 kB (0.7%)

Largest size changes

Item Install Size Change
StripeCore.ElementsSessionContext.value witness ⬆️ 960 B
📝 StripeCore.BillingAddress.encode(to) ⬆️ 932 B
📝 StripeCore.BillingAddress.value witness ⬆️ 912 B
Other ⬆️ 5.2 kB
View Treemap

Image of diff

StripeFinancialConnectionsSize 1.0 (1)
com.stripe.StripeFinancialConnectionsSize

⚖️ Compare build
⏱️ Analyze build performance

Total install size change: ⬆️ 14.1 kB (0.33%)
Total download size change: ⬆️ 5.1 kB (0.39%)

Largest size changes

Item Install Size Change
📝 StripeFinancialConnections.FinancialConnectionsAPIClient.paymentD... ⬆️ 2.1 kB
StripeFinancialConnections.NativeFlowController.createPaymentMeth... ⬆️ 1.1 kB
StripeCore.ElementsSessionContext.value witness ⬆️ 960 B
🗑 StripeFinancialConnections.FinancialConnectionsAPIClient.paymentD... ⬇️ -952 B
📝 StripeCore.BillingAddress.encode(to) ⬆️ 932 B
View Treemap

Image of diff

StripePaymentsSize 1.0 (1)
com.stripe.StripePaymentsSize

⚖️ Compare build
⏱️ Analyze build performance

Total install size change: ⬆️ 8.6 kB (0.21%)
Total download size change: ⬆️ 3.8 kB (0.33%)

Largest size changes

Item Install Size Change
StripeCore.ElementsSessionContext.value witness ⬆️ 960 B
📝 StripeCore.BillingAddress.encode(to) ⬆️ 932 B
📝 StripeCore.BillingAddress.value witness ⬆️ 912 B
Other ⬆️ 5.8 kB
View Treemap

Image of diff

StripePaymentsUISize 1.0 (1)
com.stripe.StripePaymentsUISize

⚖️ Compare build
⏱️ Analyze build performance

Total install size change: ⬆️ 8.6 kB (0.14%)
Total download size change: ⬆️ 3.2 kB (0.17%)

Largest size changes

Item Install Size Change
StripeCore.ElementsSessionContext.value witness ⬆️ 960 B
📝 StripeCore.BillingAddress.encode(to) ⬆️ 932 B
📝 StripeCore.BillingAddress.value witness ⬆️ 912 B
Other ⬆️ 5.8 kB
View Treemap

Image of diff

StripePaymentSheetSize 1.0 (1)
com.stripe.StripePaymentSheetSize

⚖️ Compare build
⏱️ Analyze build performance

Total install size change: ⬆️ 14.7 kB (0.14%)
Total download size change: ⬆️ 7.5 kB (0.21%)

Largest size changes

Item Install Size Change
📝 StripePaymentSheet.InstantDebitsPaymentMethodElement.defaultAddre... ⬆️ 1.7 kB
📝 StripePaymentSheet.InstantDebitsPaymentMethodElement.defaultName ⬆️ 1.6 kB
StripeCore.ElementsSessionContext.value witness ⬆️ 960 B
📝 StripeCore.BillingAddress.encode(to) ⬆️ 920 B
📝 StripeCore.BillingAddress.value witness ⬆️ 912 B
View Treemap

Image of diff


🛸 Powered by Emerge Tools

tillh-stripe
tillh-stripe previously approved these changes Oct 29, 2024
@mats-stripe mats-stripe force-pushed the mats/pass_billing_address_to_payment_details branch from c2a8180 to 7dbe362 Compare October 29, 2024 14:56
@mats-stripe mats-stripe merged commit 7abb1ad into master Oct 29, 2024
6 checks passed
@mats-stripe mats-stripe deleted the mats/pass_billing_address_to_payment_details branch October 29, 2024 19:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants