Skip to content

Magento 2 integration guide

Once you’ve installed and activated the iwocaPay plugin, it will integrate as a payment option in your Magento checkout. Payments made through iwocaPay will automatically reconcile with your store data to simplify your workflow.

With just a few clicks, you can offer Buy Now, Pay Later to your customers. Optionally, you can also include a Pay Now option powered by instant bank-to-bank transfers at no extra cost or effort.


Before You Begin

These notes will help the process go smoothly.

Time and skill

Installing the iwocaPay extension for Magento takes 1–2 hours. The process requires access to your server’s command line, so you’ll likely need a developer or someone with technical expertise.

Supported versions

The iwocaPay extension is not compatible with Magento 1.

Prerequisites

  • Always back up your database before making any changes to Magento.
  • Run the installation commands in maintenance mode.
  • You’ll need your API keys to go live. Contact your account manager to obtain them.
Choose your pricing structure

With iwocaPay, you decide who covers the cost of Pay Later transactions.

You can manage your pricing preferences from your Universal pay link in the iwocaPay dashboard.


Installing iwocaPay in Magento 2

  1. Access your Magento server via SSH and navigate to your Magento 2 installation directory:

    Terminal window
    cd /path/to/magento
    Terminal window
    composer config repositories.iwoca git "git@github.com:iwoca/iwocapay-magento-payment-gateway.git"
  2. Download the plugin files:

    Terminal window
    composer require iwoca/iwocapay-magento:^1.0
  3. Enable and install the plugin:

    Terminal window
    magento module:enable Iwoca_Iwocapay
    magento setup:upgrade
  4. Configure the plugin:

    • Log in to your admin panel at /admin.
    • Navigate to Stores > Configuration > Sales > Payment Methods.
    • Select iwocaPay Payment Method and configure the following:
      • Enabled: Yes
      • API Key: <Your key>
      • Seller ID: <Your ID>
    • Set Mode to Production mode.
    • Click Save Config
  5. Clear your cache:

    Terminal window
    magento cache:flush

Testing your setup

  • Add items to your basket and proceed to checkout.
  • Confirm that iwocaPay is now available as a payment option.

Updating the iwocaPay plugin

To take advantage of the latest features, update the plugin regularly.

  1. SSH into your server and navigate to the Magento 2 directory:

    Terminal window
    cd /path/to/magento
  2. Run the following command to update:

    Terminal window
    composer require iwoca/iwocapay-magento:^VERSION_NUMBER
  3. Apply the update:

    Terminal window
    composer update

Configuring payment options

You can customise which iwocaPay options are available to customers:

  • Pay Later
  • Pay Now (always free for both you and your customers).

Updating your options

  • Log in to your admin panel at /admin
  • Go to Stores > Configuration > Sales > Payment Methods
  • Select iwocaPay Payment Method.
  • Use the Payment modes drop-down menu to choose your preferred options.
  • Changes will update automatically.

Removing iwocaPay

If you need to remove iwocaPay from your checkout, follow these steps:

  • Enable maintenance mode on your server.
  • Disable the extension, update dependencies, and clear your cache.
  • Verify the removal.
  • Remove the module files from the app directory.
  • Disable maintenance mode.

To reinstall iwocaPay in the future, you’ll need to follow the installation steps again.