<p>Issue was not RTFM. :) Basically I didn't include <a href="https://stripe.com/docs/custom-form" rel="nofollow noreferrer">every part of the stripe.js setup</a></p>

CC BY-SA 3.0
2016-11-23T21:11:48.187Z
2016-11-23T21:11:48.187Z
A Herrera
<p>We're using Stripe for an ecomm project that we're testing out right now and nothing is hitting Stripe. If we use a bad card number (<a href="https://stripe.com/docs/testing#cards" rel="nofollow noreferrer">per Stripe's docs</a>) like 4000000000000002, the order still goes through.</p>

<p>The Stripe account is brand new (hasn't fully been activated yet) and in Test mode and the test secret and publishable keys are in Commerce's settings. I'm not sure what else to check.</p>

<p>EDIT:</p>

<p>I had forgotten stripe.js altogether but now I'm getting "Payment information submitted is invalid." which I think is a Craft/Commerce error. <a href="http://d.pr/f/Ogol" rel="nofollow noreferrer">Here's a link</a> to my checkout template code. The wrapper template (extended template) contains <a href="http://d.pr/f/kj4y" rel="nofollow noreferrer">this javascript</a> before the closing body tag.</p>

CC BY-SA 3.0
2016-11-22T03:31:24.600Z
Are you sure you're looking in the right stripe account? Also are you using the test api keys from your stripe CP, and not the production keys? Also, are you using stripe.js or checkout.js on the front end?
Luke Holder
CC BY-SA 3.0
2016-11-22T08:48:36.630Z
Just tested this on a shop I'm developing right now. That card gives me a "Your card was declined." error.
André Elvan
CC BY-SA 3.0
2016-11-22T21:51:48.990Z
@LukeHolder - yes, correct Stripe account, test API keys from Stripe CP. I may be missing the JS. Have to look again.
A Herrera
CC BY-SA 3.0
2016-11-22T23:02:08.500Z
Alright, so I was missing stripe.js. Added all that per Stripe docs and now just get "Payment information submitted is invalid" which is a Craft/Commerce error from what I can tell. I've edited my original question to reflect this and added links to code.
A Herrera
CC BY-SA 3.0
2016-11-22T23:18:57.587Z
Where is your [``stripeResponseHandler``](https://stripe.com/docs/custom-form#step-3-sending-the-form-to-your-server) in your JS?  So basically your code is hitting Stripe with the card details to get the token. So you have the token, now your JS needs to insert that token back into the form so Commerce on the server side can actually submit the form and do what it needs to do with the token.
RitterKnight
CC BY-SA 3.0
2016-11-23T01:17:53.343Z
Angie, before trying to implement stripe.js which is the more advanced method. Have you tested the checkout.js stripe example included in the supplied example templates?
Luke Holder
CC BY-SA 3.0
2016-11-23T02:45:02.047Z
Oof, what a noob move! Thanks @RitterKnight - that was the last missing piece.
A Herrera
CC BY-SA 3.0
2016-11-23T07:15:10.977Z
@AngieHerrera Could you add that as an official answer for the next person to run into this issue?
Brad Bell
CC BY-SA 3.0
2016-11-23T21:10:26.967Z
@BradBell Oh I suppose I could do that. ;)
A Herrera
<plugin-craftcommerce><ecommerce><omnipay-stripe>
Getting Stripe to work with Commerce
# Getting Stripe to work with Commerce

(Asked by: username_0 on 2016-11-22)

We're using Stripe for an ecomm project that we're testing out right now and nothing is hitting Stripe. If we use a bad card number ([per Stripe's docs](https://stripe.com/docs/testing#cards)) like 4000000000000002, the order still goes through.

The Stripe account is brand new (hasn't fully been activated yet) and in Test mode and the test secret and publishable keys are in Commerce's settings. I'm not sure what else to check.

EDIT:

I had forgotten stripe.js altogether but now I'm getting "Payment information submitted is invalid." which I think is a Craft/Commerce error. [Here's a link](http://d.pr/f/Ogol) to my checkout template code. The wrapper template (extended template) contains [this javascript](http://d.pr/f/kj4y) before the closing body tag.

**Tags:** plugin-craftcommerce, ecommerce, omnipay-stripe
> **Comments:**
> **username_1**: Are you sure you're looking in the right stripe account? Also are you using the test api keys from your stripe CP, and not the production keys? Also, are you using stripe.js or checkout.js on the front end?  
> **username_2**: Just tested this on a shop I'm developing right now. That card gives me a "Your card was declined." error.  
> **username_0**: @LukeHolder - yes, correct Stripe account, test API keys from Stripe CP. I may be missing the JS. Have to look again.  
> **username_0**: Alright, so I was missing stripe.js. Added all that per Stripe docs and now just get "Payment information submitted is invalid" which is a Craft/Commerce error from what I can tell. I've edited my original question to reflect this and added links to code.  
> **username_3**: Where is your [``stripeResponseHandler``](https://stripe.com/docs/custom-form#step-3-sending-the-form-to-your-server) in your JS?  So basically your code is hitting Stripe with the card details to get the token. So you have the token, now your JS needs to insert that token back into the form so Commerce on the server side can actually submit the form and do what it needs to do with the token.  
> **username_1**: Angie, before trying to implement stripe.js which is the more advanced method. Have you tested the checkout.js stripe example included in the supplied example templates?  
> **username_0**: Oof, what a noob move! Thanks @RitterKnight - that was the last missing piece.  
> **username_4**: @AngieHerrera Could you add that as an official answer for the next person to run into this issue?  
> **username_0**: @BradBell Oh I suppose I could do that. ;)  

---

## 1 answers

### Answer by username_0 on 2016-11-23. Score: 1 | Accepted answer

Issue was not RTFM. :) Basically I didn't include [every part of the stripe.js setup](https://stripe.com/docs/custom-form)


---

