Skip to main content

Magento 2

This guide describes how to integrate Sezzle into your Magento 2 website so that you can provide Sezzle as a payment option for your customers.

Sezzle's Magento 2 extension is certified in the marketplace and can also be downloaded from github.

After integrating Sezzle, your site will:

  • offer Sezzle as a payment option on the checkout page.
  • refund Sezzle payments from your Magento 2 order management system.
  • display Sezzle promotional messaging.
  • authorize and capture payments.
  • offer instant and delayed capture.

Integration Steps Overview

  1. Install and configure the Sezzle Magento 2 extension
  2. Test your integration

Before You Begin

  1. You should have a Sezzle merchant account.
    • Please visit our signup page if you don't have an account.
  2. Make sure you have the following Sezzle details handy.
  3. Familiarize yourself with the transaction flow when buying with Sezzle.

Install the Sezzle Magento 2 Extension

In the following section, [magento] refers to your Magento 2 root directory.

Using the Composer

Go to the Magento 2 installation directory, then run the below commands:

  1. composer require sezzle/sezzlepay
  2. php bin/magento setup:upgrade
  3. php bin/magento setup:di:compile
  4. php bin/magento setup:static-content:deploy
  5. php bin/magento cache:clean

Manual Method

  1. Download the .zip file from Sezzle's github repository.
  2. Unzip the file
  3. Navigate to Magento [Magento]/app/code/ using SFTP or SSH.
  4. Copy Sezzle directory from unzipped folder to [Magento]/app/code/.
  5. Open a terminal window and run the following command to enable Sezzle:
    • php bin/magento module:enable Sezzle_Sezzlepay
  6. Run the Magento setup upgrade:
    • php bin/magento setup:upgrade
  7. Run the Magento Dependencies Injection Compile:
    • php bin/`magento` setup:di:compile
  8. Run the Magento Static Content deployment:
    • php bin/magento setup:static-content:deploy
  9. Log in to Magento Admin and navigate to System > Cache Management.
  10. Flush the cache storage by selecting Flush Cache Storage.

You can now directly navigate from the Configuration Page to get signed up for Sezzle. To do so, you need to click on Signup for Sezzle which will redirect you to the Sezzle Merchant Signup Page. If you have the details already, you can simply click on I've already set up Sezzle, I want to edit my settings to move ahead.

  1. In your Magento 2 [Magento]/app/code/ directory, create a directory named Sezzle.
  2. Inside the new Sezzle directory, create a directory named Sezzlepay.
  3. Inside the new Sezzlepay directory, extract the files from this repository.
  4. Open the command line and run these commands:
    • php bin/magento module:enable Sezzle_Sezzlepay
    • php bin/magento setup:upgrade
    • php bin/magento setup:di:compile
    • php bin/magento setup:static-content:deploy
  5. Log in to your Magento 2 admin and go to System/Cache Management.
  6. Flush the cache storage by selecting Flush Cache Storage.

Upgrade the Magento 2 Extension

Using the Composer

  1. Open terminal and navigate to Magento root path.
  2. Execute the following commands in the terminal:
    • composer update sezzle/sezzlepay
    • php bin/magento setup:upgrade
    • php bin/magento setup:di:compile
    • php bin/magento setup:static-content:deploy
    • php bin/magento cache:clean

Configure Sezzle

Payment Configuration

  • In the Magento admin site, navigate to Stores > Configuration > Sales > Payment Methods > Sezzle > Payment Settings
  • Select the Payment Mode: Live, or Sandbox for testing.
  • Enter your Merchant UUID, Public Key and Private Key. These can be found at the Sezzle Merchant Dashboard.
  • Select the Payment Action. Authorize only will only authorize payment and requires that the payment be captured later. Authorize and Capture will perform both in a single step. Important: See Authorize Only vs Authorize and Capture for details about the difference between the two choices.
  • Set the Merchant Country as per the origin.
  • Set Min Checkout Amount to restrict Sezzle payment method below that amount.
  • Set Payment from Applicable Countries to Specific Countries.
  • Set Payment from Specific Countries to United States or Canada as Sezzle is currently available for US and Canada only.
  • Select Enable Customer Tokenization. Yes prompts the customer to allow their account to be tokenized. See Customer tokenization
  • Set Sort Order to manage the position of Sezzle in the checkout payment options list.
  • Save the configuration and clear the cache. Configuration_Settings_Stores_Magento_Admin__2022-08-22_at_2

In-Context Configuration

If you want to host Sezzle checkout in a modal iframe or pop-up window, you have to enable in-context checkout. To do this:

  • Set Enable In-Context Solution to Yes to enable In-Context Checkout.
  • Set In-Context Checkout Mode to IFrame or PopUp Configuration_Settings_Stores_Magento_Admin__2022-08-22_at_2

Settlement Report Configuration

  • Set Enable Settlement Reports to Yes to enable the Settlement Reports Dashboard.
  • Set Range to a value based on which you want to fetch the Settlement Reports.
  • Set Enable Automatic Syncing to fetch the Settlement Reports asynchronously. (Note that this requires cron to be enabled.)
  • Set Schedule and Time of Day for the automatic sync to run. Configuration_Settings_Stores_Magento_Admin__2022-08-22_at_2

Widget Configuration

  • Set Enable Widget in PDP to Yes when adding the widget script to the Product Display Page, helping to enable the Sezzle payment widget modal in the PDP.

  • Set Enable Widget in Cart Page to Yes when adding the widget script to the Cart Page, helping to enable Sezzle payment widget modal in the Cart Page.

  • Set Enable Installment Widget in Checkout Page to Yes if you want to show the Sezzle installment plan widget under the Sezzle payment option on the Checkout Page.

  • Set Path to Price Element to define where in the Checkout Page the order total text value will be detected.

  • Save the configuration and clear the cache. Configuration_Settings_Stores_Magento_Admin__2022-08-22_at_2

  • PDP Widget Radiant_Tee__2022-08-22_at_2

  • Cart Page Widget Shopping_Cart__2022-08-22_at_2

Developer Configuration

  • Enable the log tracker to trace the Sezzle checkout process.
  • Set Send Logs to Sezzle to Yes to send the logs to Sezzle on a periodic basis. (Note that this requires cron to be enabled.)
  • You may download the latest logs by clicking on Sezzle Log.
  • Save the configuration and clear the cache. Configuration_Settings_Stores_Magento_Admin__2022-08-22_at_2

Your store is now ready to accept payments through Sezzle.

Validate

Step through a test checkout to validate the integration is properly installed.

Capture Payment

  • If Payment Action is set to Authorize and Capture, the capture will be performed instantly from the extension after the order is created and validated in Magento.
  • If Payment Action is set to Authorize, you will need to capture the payment manually from the Magento admin using the following steps:
  • Go to the order and click on Invoice.
  • Verify your input in the Create Invoice page and click on Save to create the invoice.
  • This will automatically capture the payment in Sezzle.

Refund Payment

  • Go to Sales > Orders in the Magento admin.
  • Select the order for which you want to refund the payment.
  • Click on Credit Memo and verify your input on the Create Credit Memo page.
  • Save it to initiate the refund in Sezzle.
  • Check the Order Status in the Sezzle Merchant Dashboard. Refunded indicates that payment has been fully refunded while Partially Refunded indicates that the payment has been partially refunded.

Release Payment

  • Go to Sales > Orders in the Magento admin.
  • Select the order for which you want to release the payment.
  • Click on Void and confirm your action.
  • Check the Order Status in Sezzle Merchant Dashboard. Deleted due to checkout not being captured before expiration indicates that the payment has been fully released. Magento does not support partial releases.

Order Verification in Magento Admin

  • Log in to Magento admin, navigate to Sales > Orders, and select the order to verify.
  • If Order Status is Processing and Total Paid equals Grand Total, then the payment was successfully captured by Sezzle.
  • If Order Status is Pending and Total Paid does not equal Grand Total, then payment is authorized but yet not captured.
  • If the Order Status is Closed, then payment has been refunded.
  • If the Order Status is Canceled, then payment has been released.

Order Verification in Sezzle Merchant Dashboard

  • Log in to Sezzle Merchant Dashboard, navigate to Orders, and select the order to verify.
  • Approved status indicates that payment was successfully captured by Sezzle.
  • Authorized, uncaptured indicates that payment was authorized but yet not captured.
  • Refunded status indicates that the payment was refunded.
  • Deleted due to checkout not being captured before expiration status indicates that either the payment was not captured before the authorization expired, or the payment has been released.

Customer Tokenization Details

  • Log in to Magento admin, navigate to Customers > All Customers, and select the customer to view tokenization details.
  • If the customer is tokenized, the Sezzle tab will appear.
  • The Status, Token, and Token Expiration will appear on the tab. Veronica_Costello_Customers_Customers_Magento_Admin_2022-08-22_at_4

Settlement Reports

  • Log in to Magento admin and navigate to Reports > Sales > Sezzle Settlement. A list of recent Settlement Reports will be shown.
  • To make a quick sync, enter the From and To Date and click on Sync.
  • Click on Download from the Action column to download a Settlement Report.
  • To view details of a particular Settlement Report, click on View from the Action column. You may also download the Settlement Report details from the Settlement Report view.
  • You can download the Settlement Report in CSV or Excel format. Sezzle_Settlement_Reports_Sales_Reports_Magento_Admin__2022-08-22_at_3

Troubleshooting

If testing was unsuccessful, review the following:

  • Sezzle-Magento2 extension is the latest version.
  • Sezzle extension is enabled.
    • Go to System > Configuration > Sales > Payment Methods > Sezzle and ensure Enabled dropdown is set to Yes.
  • Merchant UUID was entered correctly.
  • API Keys were entered correctly.
  • It is recommended to use the Copy icon in the Sezzle Merchant Dashboard to avoid typos or extra spaces.
  • Cache Storage was flushed.
  • Widget script is present on your website and reflects the Merchant UUID from your Sezzle Merchant Dashboard.
    • Go to a product page on your website.
    • Right-click then select Inspect.
    • In the Elements tab, search for widget.sezzle.
  • If all the above checks failed, the merchant can forward the <magento root>/var/log/sezzlepay.log to the Sezzle team at merchantsupport@sezzle.com. It is always recommended to send the system.log and exception.log for better tracing of issues.