Hacker News new | ask | show | jobs
by mrtron 4187 days ago
It looks like the secret code was the test code, which accepts test cards:

4242424242424242 for Visa

And rejects test cards:

card_declined: Use this special card number - 4000000000000002.

2 comments

You would think if you're using the live secret code server side it would reject charge tokens coming from the public test code.

edit: To be clear I haven't tested this and don't have time today with xmas and such.

Like sah88 says, on the server when you connect to Stripe with your prod secret key, it will reject tokens made on your test key.