title: Stripe PaymentIntent Card how to implement?
body: <p>I'm trying to implement payments on stripe with PaymentIntent API.
  My problem is that I don't find where/how to feed the card details (number, exp_year, exp_month, cvc) for the PaymentIntent. </p>
  
  <p>Here's my code <a href="https://github.com/rever96/example-stripe-paymentIntent" rel="nofollow noreferrer">https://github.com/rever96/example-stripe-paymentIntent</a> that create the PaymentIntent, and than confirm it. The confirm change the status to <code>succeded</code>. So that makes me think: "Wow, it's working!" But what about card details?</p>
  
  <p>Thats the server code interested:</p>
  
  <pre><code>const stripe = require('stripe')('sk_test_4eC39HqLyjWDarjtT1zdp7dc');
  
  app.post("/createPayment", (req, res) =&gt; {
      console.log('i\'m trying to create a paymentIntent');
      (async () =&gt; {
          paymentIntent = await stripe.paymentIntents.create({
              amount: 1099,
              currency: 'eur',
              payment_method_types: ['card'],
          }).then(paymentIntentResponse =&gt; {
              console.log("paymentIntent created");
              res.send(paymentIntentResponse)
          });
      })();
  });
  
  app.post("/confirmPayment", (req, res) =&gt; {
      console.log(req.body);
      (async () =&gt; {
          paymentIntent = await stripe.paymentIntents.confirm(req.body.id, { payment_method: 'pm_card_visa' })
              .then(paymentIntentResponse =&gt; {
                  console.log("paymentIntent confirmed");
                  res.send(paymentIntentResponse)
              });
      })();
  });
  </code></pre>
  
  <p>and that's the client code interested:</p>
  
  <pre><code>constructor(
      private http: HttpClient) {
    }
    ngOnInit() {
      this.http.post('http://localhost:8080/createPayment', {}).subscribe(res =&gt; {
        console.log('back from server!');
        console.log(res);
        this.paymentIntentID = res['id'];
        this.paymentIntentClientSecret = res['client_secret'];
      });
    }
  
    submitPaymentData() {
      this.collectCardDetails();
      console.log('confirm payment');
      this.http.post('http://localhost:8080/confirmPayment', { id: this.paymentIntentID }).subscribe(res =&gt; {
        console.log('back from server!');
        console.log(res);
      });
    }
  </code></pre>