Stripe: error attaching cardholder name to source


#1

Hi everybody, I’m trying to attach the name of the cardholder to a newly created source with stripe’s elements.js.

However when I submit my form I get the following error:

Received unknown parameter: name

I attach an object with that info in the createSource function, like this:

$('#payment-form').submit(function(e) {
        console.log('submitted');
        e.preventDefault();

        stripe.createSource(cardNumberElement, { name: self.cardHolder }).then(function(result) {
            if (result.error) {
                self.cardErrors = result.error.message;
            } 
            else {
                stripeSourceHandler(result.source);
            }
        });
    });

Is there any other way to store cardholder name into sources?


#2

Is this related to Vue in any way?