Implementing custom "Remember Me" with Stripe
Posted
by
Matt
on Programmers
See other posts from Programmers
or by Matt
Published on 2014-08-17T22:56:10Z
Indexed on
2014/08/21
4:30 UTC
Read the original article
Hit count: 526
Implementing remember me with Stripe, while not using their Checkout
(not supported on PhoneGap), seems to be fine using the path:
First time:
- Request token on the client side using card info.
- Create customer on server side using token.
- Upon confirm, charge customer.
Second time:
- Check if current user is Stripe customer by requesting the info from our server.
- If is Stripe customer, show "use credit card on file" instead of regular CC form.
- Upon confirm, charge customer.
However, there is one important convenience items missing--last four digits of card number. Most sites inform you of the card you're using before making the payment, pretty important in case you have to switch out cards.
I have seen that you can retrieve charges which would allow me to get the last four digits. Is it bad practice to pull that and display it?
Are there alternative solutions anyone has in mind?
© Programmers or respective owner