Skip to content
This repository has been archived by the owner on Jan 3, 2024. It is now read-only.

Android pay - how to retrieve shipping address? #173

Closed
shokimble opened this issue Nov 22, 2017 · 7 comments
Closed

Android pay - how to retrieve shipping address? #173

shokimble opened this issue Nov 22, 2017 · 7 comments
Assignees
Labels

Comments

@shokimble
Copy link
Contributor

Hi,

I'm using Android pay and setting

shipping_address_required = true
When I receive the token back unlike on Apple Pay there is no shipping information included even though it was entered.

Looking through the source (https://github.com/tipsi/tipsi-stripe/blob/master/android/src/main/java/com/gettipsi/stripe/StripeModule.java) it looks like the token received back from stripe does not include this information as the source of com.stripe.android.model.Token doesn't refer to a shipping address.

If I'm missing something obvious please let me know. Otherwise I'd really like to be able to retrieve the information as Android Pay has a very nice address input mechanism. If you could give me pointers on how to implement, I'm happy to do so and submit a pull request. Looking through the stripe docs is not helping much.

@paynd
Copy link
Contributor

paynd commented Nov 26, 2017

Hi @shokimble!
Check #178

@shokimble
Copy link
Contributor Author

Haha good timing. I was about to sit down and add it myself today as I just realised it comes from the Pay API not Stripe.

I will test it in a couple of hours but code review wise it looks good.

Now I can see what's available we should also have email address available for completeness (as in all the information available) and parity with the Apple Pay results. Heck some people might even need the billing address.

Are you happy to add that otherwise I can do it ?

Thanks a million!

@shokimble
Copy link
Contributor Author

I can confirm it works perfectly - both when shipping address is enabled or disabled. It's just an empty object when it's disabled.

Let me know about the email and billing address support - I'm happy to do it just thought it would be neater all in the one go.

@shokimble
Copy link
Contributor Author

I've found a separate but related issue with Android Pay. By default only the USA is allowed to be selected as a shipping country. I've logged an issue describing how to add more countries.

#180

@paynd
Copy link
Contributor

paynd commented Nov 29, 2017

@shokimble going to add email and billing address soon

@paynd
Copy link
Contributor

paynd commented Nov 29, 2017

@shokimble updated

@paynd
Copy link
Contributor

paynd commented Dec 7, 2017

#178 has been merged

This issue was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

3 participants