Saving credit card information for later charge with Stripe in Woocommerce












0















We have a Wordpress web-shop and we are using the WooCommerce plugin and Stripe. We need to delay charging the customers until the physical items are shipped but Stripe doesn't have that functionality. We've been told to use saving-cards but we don't understand how to set this up on our backend considering that we've been using pre-built tools so far. Any idea of the integration? How does this process work?










share|improve this question




















  • 1





    This will involve considerable amount of customisation. You will need to create custom plugin of customise stripe plugin to enable the card saving functionality. Further more, you will need to create functionality to enable charging the saved card (either manually or automatic) after the physical items are shipped. If are allowing guest checkout (i.e. allowing visitors to place order without creating account on your website), then will also have to store their details and associate the saved card details with their record. Hope this gives you some direction for further investigation.

    – zipkundan
    Nov 15 '18 at 13:52













  • Hmm, thank you for your comment but there must be a easier way to do something like this considering that many of the web-shops out there have it up in running

    – roxana
    Nov 15 '18 at 15:00
















0















We have a Wordpress web-shop and we are using the WooCommerce plugin and Stripe. We need to delay charging the customers until the physical items are shipped but Stripe doesn't have that functionality. We've been told to use saving-cards but we don't understand how to set this up on our backend considering that we've been using pre-built tools so far. Any idea of the integration? How does this process work?










share|improve this question




















  • 1





    This will involve considerable amount of customisation. You will need to create custom plugin of customise stripe plugin to enable the card saving functionality. Further more, you will need to create functionality to enable charging the saved card (either manually or automatic) after the physical items are shipped. If are allowing guest checkout (i.e. allowing visitors to place order without creating account on your website), then will also have to store their details and associate the saved card details with their record. Hope this gives you some direction for further investigation.

    – zipkundan
    Nov 15 '18 at 13:52













  • Hmm, thank you for your comment but there must be a easier way to do something like this considering that many of the web-shops out there have it up in running

    – roxana
    Nov 15 '18 at 15:00














0












0








0








We have a Wordpress web-shop and we are using the WooCommerce plugin and Stripe. We need to delay charging the customers until the physical items are shipped but Stripe doesn't have that functionality. We've been told to use saving-cards but we don't understand how to set this up on our backend considering that we've been using pre-built tools so far. Any idea of the integration? How does this process work?










share|improve this question
















We have a Wordpress web-shop and we are using the WooCommerce plugin and Stripe. We need to delay charging the customers until the physical items are shipped but Stripe doesn't have that functionality. We've been told to use saving-cards but we don't understand how to set this up on our backend considering that we've been using pre-built tools so far. Any idea of the integration? How does this process work?







wordpress woocommerce stripe-payments payment-gateway credit-card






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Nov 15 '18 at 16:51









LoicTheAztec

92.5k1366106




92.5k1366106










asked Nov 15 '18 at 13:39









roxanaroxana

1




1








  • 1





    This will involve considerable amount of customisation. You will need to create custom plugin of customise stripe plugin to enable the card saving functionality. Further more, you will need to create functionality to enable charging the saved card (either manually or automatic) after the physical items are shipped. If are allowing guest checkout (i.e. allowing visitors to place order without creating account on your website), then will also have to store their details and associate the saved card details with their record. Hope this gives you some direction for further investigation.

    – zipkundan
    Nov 15 '18 at 13:52













  • Hmm, thank you for your comment but there must be a easier way to do something like this considering that many of the web-shops out there have it up in running

    – roxana
    Nov 15 '18 at 15:00














  • 1





    This will involve considerable amount of customisation. You will need to create custom plugin of customise stripe plugin to enable the card saving functionality. Further more, you will need to create functionality to enable charging the saved card (either manually or automatic) after the physical items are shipped. If are allowing guest checkout (i.e. allowing visitors to place order without creating account on your website), then will also have to store their details and associate the saved card details with their record. Hope this gives you some direction for further investigation.

    – zipkundan
    Nov 15 '18 at 13:52













  • Hmm, thank you for your comment but there must be a easier way to do something like this considering that many of the web-shops out there have it up in running

    – roxana
    Nov 15 '18 at 15:00








1




1





This will involve considerable amount of customisation. You will need to create custom plugin of customise stripe plugin to enable the card saving functionality. Further more, you will need to create functionality to enable charging the saved card (either manually or automatic) after the physical items are shipped. If are allowing guest checkout (i.e. allowing visitors to place order without creating account on your website), then will also have to store their details and associate the saved card details with their record. Hope this gives you some direction for further investigation.

– zipkundan
Nov 15 '18 at 13:52







This will involve considerable amount of customisation. You will need to create custom plugin of customise stripe plugin to enable the card saving functionality. Further more, you will need to create functionality to enable charging the saved card (either manually or automatic) after the physical items are shipped. If are allowing guest checkout (i.e. allowing visitors to place order without creating account on your website), then will also have to store their details and associate the saved card details with their record. Hope this gives you some direction for further investigation.

– zipkundan
Nov 15 '18 at 13:52















Hmm, thank you for your comment but there must be a easier way to do something like this considering that many of the web-shops out there have it up in running

– roxana
Nov 15 '18 at 15:00





Hmm, thank you for your comment but there must be a easier way to do something like this considering that many of the web-shops out there have it up in running

– roxana
Nov 15 '18 at 15:00












2 Answers
2






active

oldest

votes


















0














welcome to StackOverflow!



While Stripe does not allow to save cards directly, you can store a tokenized anonymous version of the card and use the token to charge the card anytime.



The card's data are stored remotely by Stripe and the system is able to match the card with the token.



You can find more information here: https://stripe.com/docs/saving-cards (as you know) and here https://stripe.com/docs/charges



This topic may be also useful: Stripe Payment: Save token and customer and make payment later from token



Hope it helps.



Cheers,
Francesco






share|improve this answer































    0














    to do this:



    You create a customer and a charge but specify not to capture the charge



    You then use the saved customer token to charge the customer when goods are shipped.



    This isn't in php but something like this:



    customer = Stripe::Customer.create({
    :source => 'tok_1234',
    :email => params[:stripeEmail],
    })

    charge = Stripe::Charge.create({
    amount: @amount,
    currency: 'usd',
    customer: customer.id,
    capture: false,
    })


    note: capture: false...



    Then when you update the order, when goods are shipped:



    charge = Stripe::Charge.create({
    :amount => @amount,
    :description => 'Rails Stripe customer',
    :currency => 'usd',
    :customer => #where you save the customer token ---,

    })





    share|improve this answer
























    • Hi! Thanks for the tip. How does it work when a customer creates an order on wordpress? How do I change it to create automatically a customer and not a charge? So far I can only do it manually using Stripe API

      – roxana
      Nov 16 '18 at 8:29











    • The code above does that. The charge is there just to attach a credit/debit to the customer. Essentially you are only creating a customer but you don't want people buying stuff with no credit card or no funds in their credit card.....you don't capture the payment though. Stripe will only validate they have the funds in their account to make the order. then under your update when the order is sent, you then create the charge without the "capture: false" --- without specifying the capture, it will automatically capture it. ....

      – uno
      Nov 16 '18 at 9:29











    • You may be asking how the it even charges after when you sent; you will need to store the stripeToken which is the customer id as i commented out "#where you save the customer token ---, ..."

      – uno
      Nov 16 '18 at 9:29











    Your Answer






    StackExchange.ifUsing("editor", function () {
    StackExchange.using("externalEditor", function () {
    StackExchange.using("snippets", function () {
    StackExchange.snippets.init();
    });
    });
    }, "code-snippets");

    StackExchange.ready(function() {
    var channelOptions = {
    tags: "".split(" "),
    id: "1"
    };
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function() {
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled) {
    StackExchange.using("snippets", function() {
    createEditor();
    });
    }
    else {
    createEditor();
    }
    });

    function createEditor() {
    StackExchange.prepareEditor({
    heartbeatType: 'answer',
    autoActivateHeartbeat: false,
    convertImagesToLinks: true,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: 10,
    bindNavPrevention: true,
    postfix: "",
    imageUploader: {
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    },
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    });


    }
    });














    draft saved

    draft discarded


















    StackExchange.ready(
    function () {
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53320762%2fsaving-credit-card-information-for-later-charge-with-stripe-in-woocommerce%23new-answer', 'question_page');
    }
    );

    Post as a guest















    Required, but never shown

























    2 Answers
    2






    active

    oldest

    votes








    2 Answers
    2






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    0














    welcome to StackOverflow!



    While Stripe does not allow to save cards directly, you can store a tokenized anonymous version of the card and use the token to charge the card anytime.



    The card's data are stored remotely by Stripe and the system is able to match the card with the token.



    You can find more information here: https://stripe.com/docs/saving-cards (as you know) and here https://stripe.com/docs/charges



    This topic may be also useful: Stripe Payment: Save token and customer and make payment later from token



    Hope it helps.



    Cheers,
    Francesco






    share|improve this answer




























      0














      welcome to StackOverflow!



      While Stripe does not allow to save cards directly, you can store a tokenized anonymous version of the card and use the token to charge the card anytime.



      The card's data are stored remotely by Stripe and the system is able to match the card with the token.



      You can find more information here: https://stripe.com/docs/saving-cards (as you know) and here https://stripe.com/docs/charges



      This topic may be also useful: Stripe Payment: Save token and customer and make payment later from token



      Hope it helps.



      Cheers,
      Francesco






      share|improve this answer


























        0












        0








        0







        welcome to StackOverflow!



        While Stripe does not allow to save cards directly, you can store a tokenized anonymous version of the card and use the token to charge the card anytime.



        The card's data are stored remotely by Stripe and the system is able to match the card with the token.



        You can find more information here: https://stripe.com/docs/saving-cards (as you know) and here https://stripe.com/docs/charges



        This topic may be also useful: Stripe Payment: Save token and customer and make payment later from token



        Hope it helps.



        Cheers,
        Francesco






        share|improve this answer













        welcome to StackOverflow!



        While Stripe does not allow to save cards directly, you can store a tokenized anonymous version of the card and use the token to charge the card anytime.



        The card's data are stored remotely by Stripe and the system is able to match the card with the token.



        You can find more information here: https://stripe.com/docs/saving-cards (as you know) and here https://stripe.com/docs/charges



        This topic may be also useful: Stripe Payment: Save token and customer and make payment later from token



        Hope it helps.



        Cheers,
        Francesco







        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered Nov 15 '18 at 15:43









        FrancescoCarlucciFrancescoCarlucci

        929710




        929710

























            0














            to do this:



            You create a customer and a charge but specify not to capture the charge



            You then use the saved customer token to charge the customer when goods are shipped.



            This isn't in php but something like this:



            customer = Stripe::Customer.create({
            :source => 'tok_1234',
            :email => params[:stripeEmail],
            })

            charge = Stripe::Charge.create({
            amount: @amount,
            currency: 'usd',
            customer: customer.id,
            capture: false,
            })


            note: capture: false...



            Then when you update the order, when goods are shipped:



            charge = Stripe::Charge.create({
            :amount => @amount,
            :description => 'Rails Stripe customer',
            :currency => 'usd',
            :customer => #where you save the customer token ---,

            })





            share|improve this answer
























            • Hi! Thanks for the tip. How does it work when a customer creates an order on wordpress? How do I change it to create automatically a customer and not a charge? So far I can only do it manually using Stripe API

              – roxana
              Nov 16 '18 at 8:29











            • The code above does that. The charge is there just to attach a credit/debit to the customer. Essentially you are only creating a customer but you don't want people buying stuff with no credit card or no funds in their credit card.....you don't capture the payment though. Stripe will only validate they have the funds in their account to make the order. then under your update when the order is sent, you then create the charge without the "capture: false" --- without specifying the capture, it will automatically capture it. ....

              – uno
              Nov 16 '18 at 9:29











            • You may be asking how the it even charges after when you sent; you will need to store the stripeToken which is the customer id as i commented out "#where you save the customer token ---, ..."

              – uno
              Nov 16 '18 at 9:29
















            0














            to do this:



            You create a customer and a charge but specify not to capture the charge



            You then use the saved customer token to charge the customer when goods are shipped.



            This isn't in php but something like this:



            customer = Stripe::Customer.create({
            :source => 'tok_1234',
            :email => params[:stripeEmail],
            })

            charge = Stripe::Charge.create({
            amount: @amount,
            currency: 'usd',
            customer: customer.id,
            capture: false,
            })


            note: capture: false...



            Then when you update the order, when goods are shipped:



            charge = Stripe::Charge.create({
            :amount => @amount,
            :description => 'Rails Stripe customer',
            :currency => 'usd',
            :customer => #where you save the customer token ---,

            })





            share|improve this answer
























            • Hi! Thanks for the tip. How does it work when a customer creates an order on wordpress? How do I change it to create automatically a customer and not a charge? So far I can only do it manually using Stripe API

              – roxana
              Nov 16 '18 at 8:29











            • The code above does that. The charge is there just to attach a credit/debit to the customer. Essentially you are only creating a customer but you don't want people buying stuff with no credit card or no funds in their credit card.....you don't capture the payment though. Stripe will only validate they have the funds in their account to make the order. then under your update when the order is sent, you then create the charge without the "capture: false" --- without specifying the capture, it will automatically capture it. ....

              – uno
              Nov 16 '18 at 9:29











            • You may be asking how the it even charges after when you sent; you will need to store the stripeToken which is the customer id as i commented out "#where you save the customer token ---, ..."

              – uno
              Nov 16 '18 at 9:29














            0












            0








            0







            to do this:



            You create a customer and a charge but specify not to capture the charge



            You then use the saved customer token to charge the customer when goods are shipped.



            This isn't in php but something like this:



            customer = Stripe::Customer.create({
            :source => 'tok_1234',
            :email => params[:stripeEmail],
            })

            charge = Stripe::Charge.create({
            amount: @amount,
            currency: 'usd',
            customer: customer.id,
            capture: false,
            })


            note: capture: false...



            Then when you update the order, when goods are shipped:



            charge = Stripe::Charge.create({
            :amount => @amount,
            :description => 'Rails Stripe customer',
            :currency => 'usd',
            :customer => #where you save the customer token ---,

            })





            share|improve this answer













            to do this:



            You create a customer and a charge but specify not to capture the charge



            You then use the saved customer token to charge the customer when goods are shipped.



            This isn't in php but something like this:



            customer = Stripe::Customer.create({
            :source => 'tok_1234',
            :email => params[:stripeEmail],
            })

            charge = Stripe::Charge.create({
            amount: @amount,
            currency: 'usd',
            customer: customer.id,
            capture: false,
            })


            note: capture: false...



            Then when you update the order, when goods are shipped:



            charge = Stripe::Charge.create({
            :amount => @amount,
            :description => 'Rails Stripe customer',
            :currency => 'usd',
            :customer => #where you save the customer token ---,

            })






            share|improve this answer












            share|improve this answer



            share|improve this answer










            answered Nov 15 '18 at 23:18









            unouno

            18719




            18719













            • Hi! Thanks for the tip. How does it work when a customer creates an order on wordpress? How do I change it to create automatically a customer and not a charge? So far I can only do it manually using Stripe API

              – roxana
              Nov 16 '18 at 8:29











            • The code above does that. The charge is there just to attach a credit/debit to the customer. Essentially you are only creating a customer but you don't want people buying stuff with no credit card or no funds in their credit card.....you don't capture the payment though. Stripe will only validate they have the funds in their account to make the order. then under your update when the order is sent, you then create the charge without the "capture: false" --- without specifying the capture, it will automatically capture it. ....

              – uno
              Nov 16 '18 at 9:29











            • You may be asking how the it even charges after when you sent; you will need to store the stripeToken which is the customer id as i commented out "#where you save the customer token ---, ..."

              – uno
              Nov 16 '18 at 9:29



















            • Hi! Thanks for the tip. How does it work when a customer creates an order on wordpress? How do I change it to create automatically a customer and not a charge? So far I can only do it manually using Stripe API

              – roxana
              Nov 16 '18 at 8:29











            • The code above does that. The charge is there just to attach a credit/debit to the customer. Essentially you are only creating a customer but you don't want people buying stuff with no credit card or no funds in their credit card.....you don't capture the payment though. Stripe will only validate they have the funds in their account to make the order. then under your update when the order is sent, you then create the charge without the "capture: false" --- without specifying the capture, it will automatically capture it. ....

              – uno
              Nov 16 '18 at 9:29











            • You may be asking how the it even charges after when you sent; you will need to store the stripeToken which is the customer id as i commented out "#where you save the customer token ---, ..."

              – uno
              Nov 16 '18 at 9:29

















            Hi! Thanks for the tip. How does it work when a customer creates an order on wordpress? How do I change it to create automatically a customer and not a charge? So far I can only do it manually using Stripe API

            – roxana
            Nov 16 '18 at 8:29





            Hi! Thanks for the tip. How does it work when a customer creates an order on wordpress? How do I change it to create automatically a customer and not a charge? So far I can only do it manually using Stripe API

            – roxana
            Nov 16 '18 at 8:29













            The code above does that. The charge is there just to attach a credit/debit to the customer. Essentially you are only creating a customer but you don't want people buying stuff with no credit card or no funds in their credit card.....you don't capture the payment though. Stripe will only validate they have the funds in their account to make the order. then under your update when the order is sent, you then create the charge without the "capture: false" --- without specifying the capture, it will automatically capture it. ....

            – uno
            Nov 16 '18 at 9:29





            The code above does that. The charge is there just to attach a credit/debit to the customer. Essentially you are only creating a customer but you don't want people buying stuff with no credit card or no funds in their credit card.....you don't capture the payment though. Stripe will only validate they have the funds in their account to make the order. then under your update when the order is sent, you then create the charge without the "capture: false" --- without specifying the capture, it will automatically capture it. ....

            – uno
            Nov 16 '18 at 9:29













            You may be asking how the it even charges after when you sent; you will need to store the stripeToken which is the customer id as i commented out "#where you save the customer token ---, ..."

            – uno
            Nov 16 '18 at 9:29





            You may be asking how the it even charges after when you sent; you will need to store the stripeToken which is the customer id as i commented out "#where you save the customer token ---, ..."

            – uno
            Nov 16 '18 at 9:29


















            draft saved

            draft discarded




















































            Thanks for contributing an answer to Stack Overflow!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid



            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.


            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53320762%2fsaving-credit-card-information-for-later-charge-with-stripe-in-woocommerce%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            List item for chat from Array inside array React Native

            Thiostrepton

            Caerphilly