PREREQUISITES: Make sure the Stripe add-on is installed and enabled.
To enable the Stripe payment in your store:
1. Navigate to the Payment Methods page of your store's Admin area (Store Setup -> Payment Methods)
2. If Stripe is not already listed in "Online methods," click "Add payment method" to search and add Stripe.
See detailed instructions on how to add a payment method here.
Once the payment is added, you will be redirected to the Stripe settings page:
3. On the Stripe Settings page, click the blue Connect with Stripe button. It forwards you to the page where you can either sign in with an existing Stripe account or create a new one:
When signed in, you will be redirected back to the X-Cart Stripe settings page.
4. Here, copy “Webhook URL” and place it into your Stripe Account settings.
For this purpose:
Open the page “Webhooks” in the “Developers” section of the dashboard.stripe.com site.
In the section Endpoints receiving events from your account, click + Add endpoint.
In the form that opens, paste the “Webhook URL” value into the field URL to be called and click Add endpoint.
That’s it, the “Webhook URL” is added.
More information on the setup of webhooks is available here.
5. Check other settings on the Stripe settings page of your store's Admin area. They are as follows:
Secret key: The field is defined automatically by the system when a Stripe account is connected.
Publishable key: The field is defined automatically by the system when a Stripe account is connected.
Secret key (test mode): The field is defined automatically by the system when test mode is enabled.
Publishable key (test mode): The field is defined automatically by the system when test mode is enabled.
Transaction type: If you set the value as Authorization only, you’ll need to process each transaction manually. This option is preferred if you need to have an option to void orders. If the value is set as Authorization and Capture, X-Cart will process all transactions automatically.
Test/Live mode: Use this setting to select the operation mode for your Stripe integration. Before you can offer Stripe payment on your website, you will first need to carry out some required test transactions successfully. To do the testing, you will need to set the operation mode of your integration to Test. When the payment is ready for production use, you can switch the Test/Live mode setting to Live.
Invoice number prefix: If you use the same account to accept payments from more than one X-Cart store, use this field to set an invoice number prefix for this store. The prefix will serve as an identifier of the store and help you to avoid the “duplicate invoice number” type of errors. It’s recommended to limit the length of the invoice prefix to 9 characters. Larger prefixes will be cut before transaction initialization.
6. When all settings are configured, save the changes and switch ON the payment.
The Stripe payment will become available on checkout:
When a customer clicks the Place order button, Stripe will show a pop-up payment form where the customer can specify his credit card details and save them for future references if required:
The used payment method is displayed on both the order invoice page in the customer storefront and the order details page (Orders -> Order list), and the payment transactions page (Orders -> Payment transactions) in the Admin area.