-
Notifications
You must be signed in to change notification settings - Fork 6
Home
AltaPay, headquartered in Denmark, is an internationally focused fintech company within payments with the mission to make payments less complicated. We help our merchants grow and expand their business across payment channels by offering a fully integrated seamless omni-channel experience for online, mobile and instore payments, creating transparency and reducing the need for manual tasks with one centralized payment platform.
AltaPay’s platform automizes, simplifies, and protects the transaction flow for shop owners and global retail and e-commerce companies, supporting and integrating smoothly into the major ERP systems. AltaPay performs as a Payment Service Provider operating under The Payment Card Industry Data Security Standard (PCI DSS).
Installing this plugin will enable your website to handle card transactions through AltaPay's gateway.
We highly recommend gathering all the below information, before starting the installation.
Table of Contents
Auto-cancelling orders with pending payment
Before configuring the plugin, you need the below information. These can be provided by AltaPay.
- AltaPay credentials:
- Username
- Password
- AltaPay gateway information:
- Terminal
- Gateway
- The package manager Composer (https://getcomposer.org/) must be installed on the server side.
- Your private and public keys must be located at repo.magento.com when installing the AltaPay module.
Note: If the API user credentials have not yet been created, refer to the Creating a New API User section for step-by-step instructions.
-
Search for "AltaPay Payment Gateway"
-
Download extension from Marketplace and place inside your project
root/app/code -
In Magento root directory run the following commands using the command line
php bin/magento setup:upgradephp bin/magento setup:static-content:deploy
-
In Magento root directory run the following commands using the command line
composer require altapay/magento2-communityphp bin/magento setup:upgradephp bin/magento setup:di:compilephp bin/magento setup:static-content:deployNote: If asked for authentication, use your Public Key as the username, and the Private Key as the password. This information can be found in the Secure Keys section of your Magento account:

- Check that the module is enabled
php bin/magento module:status
SDM_Altapay will appear in the module list, if not enabled run below command
- Enable the AltaPay module
php bin/magento module:enable SDM_Altapay
You can configure the plugin to suit your needs, including adding payment methods and configuring payments.
-
Connect the plugin to the AltaPay gateway
-
Navigate to: Admin > Stores > Configuration > Sales > Payment Methods
-
Complete the 'API Login', 'API Password' and 'Production URL' fields with the gateway information for your environment (provided by AltaPay)

-
Click: 'Save Config' button
If everything is correct, you should see the messages 'Connection successful' and 'Authentication successful' in the 'Test connection' and 'Test authentication' fields.
Once the API details are validated the terminals will be appeared in the terminal's dropdown in each terminal.
You can select currency used for AltaPay payment processing from charged currency setting section.
-
Display currency: The currency visible on the store view or display is used.
-
Global/Website currency: The base currency is used.

Navigate to: Admin > Stores > Configuration > Sales (Tab) > Payment Methods

Choose one of the below options from Payment page layout dropdown to select the layout type for payment page.

-
DefaultThis will use the styling from the checkout/theme.
-
Checkout IndependentThis will show the payment page independent from the theme styling. This will provide a visually appealing appearance seamlessly, without conflicting with the theme styling.
Enabling this option will display prices for subtotal, shipping, and item price, including taxes, on the order summary grid.
This logo will be displayed on the checkout page when the Checkout Independent option is selected. If left empty, the default store logo will be used. (jpg, jpeg, gif, png)

Choose one of the below options from Checkout form style dropdown to change the styling of Credit Card form on the checkout page.

-
LegacyLegacy design with basic form styling.
-
CheckoutSelect the option to show the Credit Card form in a modern look.
-
Checkout v2Select this option to display the credit card form with a sleek design, showing the expiry date in two-digit month and year format, and the payment amount on the pay button.
-
CustomThis option can be selected to implement custom styling on the payment page. Selecting this option will remove all the styling from the payment page.
Navigate to: Admin > Stores > Configuration > Sales (Tab) > Payment Methods

To synchronize the terminals with the gateway, click on the Synchronize Terminals button. This will fetch the latest terminals from the gateway and will automatically configure based on the store country.

-
Navigate to: Admin > Stores > Configuration > Sales (Tab) > Payment Methods
-
Enable the terminal
-
Choose a title for the terminal
-
Select the terminal name in the drop-down list
-
Optional fields: 'Custom Message', 'Force language', 'Secret', 'Is Apple Pay?', 'Apple Pay Form Label', 'Auto capture', 'Terminal Logo', 'Show both Logo and Title', 'Enable Customer Token Control', 'AVS', 'Enforce AVS', 'AVS accepted codes', 'Sort Order'.
-
If Apple Pay terminal is selected from the Terminal dropdown, make sure to enable isapplepay option.
-
Save changes by clicking 'Save Config'

Note: Remember to follow Magento's Cache Management guidelines to clear the site cache when updating the configurations.
-
To enable save credit cards option for customers follow the bellow steps
-
Navigate to Admin > Stores > Configuration > Sales > Payment Methods > AltaPay
-
Choose Terminal
-
"Enable Customer Token Control" to Yes
-
Choose Unscheduled Type from the list.

-
-
A new field will be appeared on checkout page for saving the credit card for later use

-
Customer can manage the
Saved Credit Cardsfrom customer dashboard
By performing the below steps a customer receives a payment link on the provided email.
-
Navigate to Admin > Sales > Order
-
Click on the "Create new order" button

-
Select an existing customer or create a new user

-
Click on the "Add Product" button and choose any product from the list

-
Then click on the "Add the selected product(s) to order" button

-
Add Billing and Shipping Address

-
Choose a payment method

-
Click on the "Submit Order" button

You can create a custom email template by following the link below and change the template from the dropdown: https://developer.adobe.com/commerce/frontend-core/guide/templates/email/

-
Navigate to: Admin > Stores > Configuration > Sales (Tab) > Payment Methods
-
Scroll to AltaPay section
-
Open Auto-cancelling orders with pending payment section and choose Yes to enable the configuration.
-
Choose Exclude admin orders option if you want to exclude order created from the admin panel.
-
Cancellation timeframe runs from the moment the order is generated.
Note Specify the time duration in hours; for instance, 2 days equals 48 hours with a default field setting of 24 hours.

To place an order through the admin, please follow the steps below:
-
For re-ordering through the admin, follow the steps outlined in the link: https://experienceleague.adobe.com/docs/commerce-admin/stores-sales/shopper-tools/reorders-allow.html?lang=en/#reorder-from-the-admin
-
Ensure that you select AltaPay payment methods from the available list.

-
Once the order is created, an email containing the payment link will be sent to the customer.
-
The admin can also locate the payment link under the Payment Information section.
In order to reconcile payments on Magento please follow the steps below:
-
Navigate to the Magento Admin page.
-
Select Sales > Orders in the left hand pane.
-
Select the order you want to view.
-
Copy the Reconciliation Identifier from the Reconciliation Details section.

-
Navigate to AltaPay Gateway dashboard
-
Click on FUNDING FILES under FINANCES menu
-
Download the CSV file
-
Or you can find the payment in the transaction list, open the reconciliation file from there and download a csv file
-
Open the downloaded CSV file and match the Reconciliation Identifier with Magento's Reconciliation Identifier.
Sample AltaPay Gateway CSV:

| 7.4.0 | Magento 2.4 |
|---|---|
| 7.1.3+, 7.2.x | Magento 2.3 |
For Magneto 2.2 and below version please install the extension from
here.
https://packagist.org/packages/altapay/magento2-payment
To create a new API user in your AltaPay account, please follow these steps:
-
Log in to your AltaPay account.
-
From the left menu, navigate to Settings > API Keys.

-
Click on the Create New API Key button from top right corner.
-
Fill in the required fields:
- Your current password
- Username
- Password
- Assign Shops

-
After entering the details, click Create.
The new credentials can now be used as the API Login and API Password in the AltaPay API Login section.
-
You can change/update the Payment Form Page by navigating to the below path:
-
Use the below link to apply the CSS to the form page:
Note If you've selected the
Custom Layoutoption for yourPayment page layoutyou can modify Payment Form Page and CSS from below paths respectively.Payment Form Page Path https://github.com/AltaPay/plugin-magento2-community/blob/main/view/frontend/templates/external/ordersummary.phtml
-
You can update the styling for the Checkout/Terminals page from below file
Note: It is recommended to extend the layout file instead of making changes in the plugin file directly. If you want to extend the layout file, use the below path in your custom module/theme:
Please visit Magento's official documentation to know more about how to Override a layout.
From version 3.8.2 onwards, you will receive a notification in Magento 2 admin when a new version of the plugin is available for installation. We recommend to update the plugin regularly upon receiving such notifications to ensure optimal performance and access to the latest features.

-
Callbacks 403 error
- If you are getting 403 forbidden error in "Magento Commerce Cloud". It can be caused by Fastly, which blocks our callbacks. In this case, please contact Fastly support.
- Make sure AltaPay's outgoing IPs are whitelisted. You can find the details for callback settings here.
-
PHP Warning: Input variables exceeded 1000. To increase the limit change max_input_vars in php.ini.
For orders that contain too many products, this PHP warning may be issued. You will need to:
- Open your php.ini file
- Edit the max_input_vars variable. This specifies the maximum number of variables that can be sent in a request. The default is 1000. Increase it to, say, 3000.
- Restart your server.
-
Parameters: description/unitPrice/quantity are required for each orderline, but was not set for line: xxxx
The same problem as above. The request is being truncated because the number of variables are exceeding the max_input_vars limit.
You can find the logs from the below path:
Debug logs: <install_directory>/var/log/debug.log
Exception logs: <install_directory>/var/log/exception.log
AltaPay plugin logs: <install_directory>/var/log/altapay.log
Web server error logs
For Apache server You can find it on /var/log/apache2/error.log
For Nginx it would be /var/log/nginx/error.log
Note: Your path may vary from the mentioned above.