Demos Buy Now

Stripe Payment Gateway for Magento 2

Stripe Payment Gateway for Magento 2-This module is PCI compliant payments system and will work in Live and in Debugging mode. With Stripe Payment Gateway for Magento2, the customer can save the card for future payment and add a new one at the checkout page.

NOTE:– This module does not work with Multiple Address Checkout.

Features

  • Working with stripe supported currencies.
  • The admin can enable the zip code validation from the backend.
  • The admin can enable the shipping or billing address from the backend.
  • Admin can set payment action to decide whether to capture the payment immediately after placing an order or after invoice generation.
  • Integrated Alipay with the stripe checkout.
  • Alipay account can be saved for making future payments.
  • Added cards and payment methods and specific images are visible at the checkout page.
  • Allow buyers to pay using all cards that the Stripe supports.
  • The customer after selecting a saved card needs to input the respective card expiry date for making the payment.
  • The customer can save the card for future payment.
  • The customer can delete the saved cards on the Strive Saved Cards page.
  • Working with the latest Stripe API.

Installation

Stripe Payment Gateway for Magento2 installation is super easy. First, you have to unzip the module and then you will get an src folder. Click on the src folder and then you will get app folder. You need to move app folder in Magento 2 root directory as per the screenshot.

After the successful installation, you have to run these commands in the Magento2 root directory.

First command-composer require stripe/stripe-php

Second Command -php bin/magento setup:upgrade

Third Command – php bin/magento setup:di:compile

Fourth Command – php bin/magento setup:static-content:deploy

After running the commands, you have to log into the admin panel and you have to clear the Cache. You can refer to the below screenshot.

Multi-Lingual Support

For the multilingual support, the admin will navigate through Store->Configuration->General ->Locale Options and select the locale as German (the language into which admin want to translate his store content).

Language Translation

If a user wants to translate their module from English to German then they need to follow the path app/code/Webkul/Stripe/i18n in their unzipped Magento Marketplace folder and will get a CSV file with name “en_US.csv”. Now they will rename that CSV as “de_DE.csv” and translate all right side content after the comma in the German language. After editing the CSV, save it and then upload it to the path app/code/Webkul/Stripe/i18n where they have installed Magento2 on their server. The module will get translated in the German Language. It supports both the LTR and RTL languages.

Configuration –  Stripe Payment Gateway

After the module installation, the admin will do the module configuration. The admin will follow the path Stores > Configuration > Sales > Payment Methods > Stripe Payment and enter Stripe details like API Publishable Key & API Key.

As per the above screen, you can see many admin config parameters for the Stripe Payment Gateway module, we are going to explain every configuration parameters one by one.

Enabled- By this option, admin can enable or disable Stripe module.

Title- Here admin can set the title which will display on front-end.

Debug- By this option admin can set the mode production (live) or sandbox (test).

API Key- This option is used to set the API key (Secret Key) which is provided by Stripe Payment Gateway.

API Publishable Key- This option is used to set the API Publishable Key which is provided by Stripe Payment Gateway.

Set Name Display on Form- Here, the admin will enter the name which will appear on the checkout page.

Set Image- Here, the admin can upload any Image that they want to display on stripe payment popup at the checkout page.

Payment from Applicable Countries- Here admin can select the specific countries for stripe payment.

Minimum Order Total- This option allows admin to set minimum order total. If Grand total of order is less than specified Minimum Order Total value then Stripe module will not allow to checkout with Stripe payment gateway. $0.50 is the minimum amount allowed by Stripe for Minimum Order Total

Payment Action – Set payment action as “Authorize” or “Authorize and Capture“. The admin can set payment action to decide whether to capture the payment immediately after placing an order(Authorize and Capture) or after manual invoice generation in the Magento backend(Authorize).

If payment action is selected as “Authorize” then the payment of order not captured until the invoice of the order is not generated by the admin. In this case payment status at admin’s Stripe account will be “Uncaptured”.

Once Invoice generated for the order then the payment status becomes “Succeeded”.

If payment action selected as “Authorize and Capture” then payment of the order captured immediately after placing an order.

Maximum Order Total- This option allows admin to set maximum order total.

Sort Order- Here admin can set the sort order value.

Enable Alipay Checkout – Admin can enable/disable Alipay for use at the time of checkout.

To get the API Keys you can use https://dashboard.stripe.com/login Stripe website. You have to Login/Sign up your account and you will get your API Keys. As you can see in the following screenshot the keys are there for the Test and live environmentsPublishable key and the Secret Key.

Enabled Zip Code Validation

Here, the admin can specify whether the checkout should validate the billing zip code or not. Select “Yes” to enable validation of zip code at checkout else select “No“.

Enabled Shipping Address

Here, the admin can select whether the checkout should collect the user’s shipping address or not. If this option is set to “Yes“, then users will have to enter the shipping address manually else select “No“.

Enabled Billing Address

Here, the admin can specify whether the checkout should collect the user’s billing address or not. If the admin has selected “Yes” then the user will have to enter their billing address manually else select “No“.

Workflow –  Stripe Payment Gateway

Customer Checkout –

Card Payment:

At the checkout under the payment method section, the customer can see the stripe payment method. Here, the customer will check the stripe payment method for making the payment and then click “Pay With New Card” button.

Clicking the “Pay With Card” button brings up the stripe pop-up wherein you have to enter your card details. Enter the details and click the “Pay” button.

Clicking the “Pay” button will redirect you back to the payment method selection page. Here, you can choose to save the card for future use by checking the option “Save the card for future payments“. Click the “Place Order” button to complete the purchase.

**Note:

  1. If the admin has set the option –  “Enabled Zip Code Validation” as “Yes“, then when the customer is at the step where the card details are entered, the customer will have to validate their zip code as shown below in the snapshot.
  2. If the admin has set the option – “Enabled Shipping Address” as “Yes“, then when the customer selects the stripe payment method at the payment page, the customer will have to validate/enter his shipping address and then proceed as normal.
  3. If the admin has set the option – “Enabled Billing Address” as “Yes“, then when the customer selects the stripe payment method at the payment page, the customer will have to validate/enter his billing address and then proceed as normal.



AliPay Payment:

The customers can first select the Stripe payment method on the checkout page under the payment methods section to make use of AliPay for making the payment for the order. Now, click the “Pay With AliPay” button to proceed and pay using the AliPay.

After clicking “Pay With AliPay” you will be re-directed to another web page. Here, the customer needs to tap the “Authorize Test Payment” button for authorization.

Now, the customer will be redirected back to the payment method section. Lastly, click the “Place Order” button to complete the purchase using AliPay.

Guest Checkout –

Card Payment:

When a guest user goes for a checkout, then they will select the stripe payment method on the checkout page. Here, click on the “Pay With New Card” button to enter the card details.

Now, a pop-up will appear. Enter your email address, card details, and tap the “Pay” button to proceed.

Now, you will be redirected back to the payment method page with the selected card. Tap the “Place Order” button to complete the purchase.

AliPay Payment:

The customers can first select the Stripe payment method on the checkout page under the payment methods section to make use of AliPay for making the payment for the order. Now, click on the “Pay With AliPay” button to proceed and pay using the AliPay.

After clicking “Pay With AliPay” you will be re-directed to another web page. Here, the customer needs to tap the “Authorize Test Payment” button for authorization.

 

Now, the customer will be redirected back to the payment method section. Lastly, click the “Place Order” button to complete the purchase using AliPay.

If the customer doesn’t select any of the options and clicks on “Place Order” then error message will appear.

The customer can see their “Saved Cards” under the menu “Stripe Saved Cards” in the customer account. The customer can see the list of saved cards and they can delete those saved cards as well from the list.

 

At Backend OF Stripe Payment

See placed order details with Stripe Payment Gateway by navigating to path admin panel-> Sales->Orders.

Select the order by clicking on the View button & you will see the order information as under-

Order Invoice & Transaction Page.

After a successful transaction has been done using Stripe Payment, admin can see the invoices and transactions details for that particular order in which payment is done using Stripe Payment.

 Invoice Page

All transactions for their placed orders

Transaction Page Details

transaction- Stripe Payment Gateway

The admin can check the list of transactions on the stripe payment gateway.

Admin can view all the types of transactions and can export them by selecting the Export” button.

Refund –  Stripe Payment Gateway

The admin can also do online refund using this payment module. Under the Invoice menu, click on the specific invoice and then click on the Credit Memo button.

The admin can also check refund status and refunded amount on Stripe payment gateway.

That’s all for Stripe Payment Gateway for Magento2 module. Still, have any issue feel free to add a ticket and let us know your views to make the module better http://webkul.uvdesk.com/

Current Product Version - 2.1.0

Supported Framework Version - 2.0.x, 2.1.x,2.2.x,2.3.x

. . .

Comments (7)

Add Your Comment

  • Denys
    Hello, Webkul guys 😉
    Have a question about this module. Tell me…
    Can it be switched to make payment not on the website side, but on Stripe’s side? Oldschool redirecting to payment gateway and back to success/error page? I need it cuzz don’t very want to store credit cards due to GDPR liability. If not, tell please, how much will cost realization of such feature. Thank you!
    • kajal sharma
      Hi Denys,
      It doesn’t save the card details on the merchant server. It is all handled by stripe. So, there will be no security and GDPR issues.
  • Nirupama Shree
    Hello There,

    Sorry for the late response. Please mail us the issues which you are getting at support@webkul.com and we will surely look into the matter.

    Thanks & Regards

  • RCTalkIT
    Stripe option in checkout page is still not showing up.
    I’ve done the following:
    1) unzipped and moved code to folder under app as mentioned above
    2) composer require stripe/stripe-php
    3) php bin/magento setup:upgrade
    4) php bin/magento setup:di:compile
    5) php bin/magento setup:static-content:deploy
    6) Flushed the cache
    7) Reindexed all

    Still I see no payment option for Stripe on FE checkout page.

    What am I missing?

  • RCTalkIT
    I’m getting a blank checkout page (500 Server Error) after following the configuration steps
    I have set the keys as indicated for the test keys and in sandbox mode, I have stripe on test mode.

    This is the error I am getting on error_log for the site:

    PHP Fatal error: Class ‘Stripe\Stripe’ not found in: /var/www/html/e_comm_ana/app/code/Webkul/Stripe/Model/PaymentMethod.php on line 123

    I need help! Ideas?

    • RCTalkIT
      I think I got it in the end. I did not notice you guys say to run the composer to install stripe in vendors. Solved. Thanks.
      • dedar singh
        It Works. Thanks
  • css.php
    Hire Us!
    Brief us about your requirements and we'll get back to you.
    Woo! Hooy!
    We have just recieved your project brief and our expert will contact you shortly.
    Send Again
    Close

    Index