-
Notifications
You must be signed in to change notification settings - Fork 977
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
base: master
Are you sure you want to change the base?
Conversation
} | ||
|
||
if let billingEmail, !billingEmail.isEmpty { | ||
parameters["billing_email_address"] = billingEmail |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
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" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🚨 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 ℹ️ 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 |
905cca9
to
dd16f78
Compare
StripePaymentSheet- public var paymentMethodLayout: StripePaymentSheet.PaymentSheet.PaymentMethodLayout
- public enum PaymentMethodLayout {
- case horizontal
- case vertical
- case automatic
- public static func == (a: StripePaymentSheet.PaymentSheet.PaymentMethodLayout, b: StripePaymentSheet.PaymentSheet.PaymentMethodLayout) -> Swift.Bool
- public func hash(into hasher: inout Swift.Hasher)
- public var hashValue: Swift.Int {
- get
- }
- } If you are adding a new public API consider the following:
If you are modifying or removing a public API:
If you confirm these APIs need to be added/updated and have undergone necessary review, add the label ℹ️ If this comment appears to be left in error, make sure your branch is up-to-date with |
Moving this to draft for now, since this PR will change slightly with this work: #4162 |
dd16f78
to
8e2d09b
Compare
📸 Snapshot TestNo snapshots generated
🛸 Powered by Emerge Tools |
764ccf7
to
594cdd6
Compare
9dfabf9
to
cf1076b
Compare
aaf0034
to
73eda16
Compare
cf1076b
to
9a0d88b
Compare
let billingAddress = BillingAddress( | ||
name: "Bobby Tables", | ||
line1: "123 Fake St", | ||
line2: nil, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we add a test with line2: ""
?
@@ -220,11 +220,13 @@ extension PaymentMethodFormViewController { | |||
}() | |||
|
|||
let linkMode = elementsSession.linkSettings?.linkMode | |||
let billingAddress = instantDebitsFormElement?.billingAddress |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems like we’re sending the address even if attachDefaults
is set to false
and address collection is set to never
. Can you take another look?
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=sharingMotivation
BANKCON-15711
Testing
Unit tests, and I've verified the billing fields are correctly passed from MPE to the API call:
Changelog
N/a