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

Add shipping info to Stripe purchases #3315

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

jonmast
Copy link

@jonmast jonmast commented Aug 29, 2019

This builds upon the work done by @whitby3001 in #2379

That PR was reverted in 28eb2a8 due to validation errors from Stripe with incomplete shipping information. I've added checks to ensure all required fields are present and added some test coverage for this case.

Stripe docs on required parameters: https://stripe.com/docs/api/charges/create#create_charge-shipping

whitby3001 and others added 2 commits August 29, 2019 08:21
The "shipping" parameter for Stripe is optional, but when it is
specified the "name" and "address" fields are required, and "address" in
turn requires "line1". Validate that those are present before we attempt
to add shipping information, this should prevent transaction errors due
to incomplete information.

See https://stripe.com/docs/api/charges/create#create_charge-shipping

Addresses issue raised in 28eb2a8
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants