Installation¶
Starting from Magento version 2.3.0, the extension is available via Composer in Packagist or Magento
Marketplace as amzn/amazon-pay-magento-2-module
.
Pre-installation steps¶
For Magento versions from 2.2.4 up to 2.4.3, our Legacy extension (EOL) is probably already pre-installed. Beginning with version 2.4.4, the Amazon Pay extension will no longer be bundled with Magento installations.
Important
If you are upgrading to Magento 2.4.4 from an earlier installation, you will need to install version 5.12.0 or greater of the Amazon Pay module.
Warning
Please settle pending transactions processed with any version of Legacy Amazon Pay extension (EOL) extension prior to proceeding
with the installation. Refund operation on past transactions will always be possible with
newer versions. In case of issues, you can settle pending transactions in Seller Central and then
mark them as settled offline in Magento Orders
page.
Create a backup of your shop before proceeding to install this new Amazon Pay extension. Before
installing Amazon Pay, please disable any previously installed or preinstalled Amazon Pay extension:
bin/magento module:disable Amazon_Core Amazon_Login Amazon_Payment
Composer Install Method¶
Note
The composer require command below will always install the most current,
non-breaking, Amazon Pay extension for you, when you run an update. To fix it to a specifix
version, please replace the version behind the colon with the preferred version.
If legacy Amazon Pay packages are installed, they will be replaced by the Marketplace module.
-
Remove the
app/code/Amazon
folder if already present in your Magento installation. -
Sign in to your server via SSH.
-
cd
into your Magento installation directory. -
Install the extension via Composer:
- Purchase our free module from Magento
Marketplace and then run:
composer require amzn/amazon-pay-magento-2-module:5.*
php bin/magento module:enable Amazon_Pay --clear-static-content
- Purchase our free module from Magento
Marketplace and then run:
-
Run Magento database scripts:
php bin/magento setup:upgrade
-
Follow any advice the upgrade routine provides
-
Compile code and dependency injection:
php bin/magento setup:di:compile
-
Deploy static view files (production mode only):
php bin/magento setup:static-content:deploy xx_XX yy_YY
where xx_XX, yy_YY, ... are the locales you are aiming to support -
Check permissions on directories and files and set them correctly if needed
At this point the module is installed, and ready to be configured! You can proceed to Configuration.
Note
The module currently includes an automatic "key upgrade" feature. If upgrading from the legacy version of the module, a new Public Key ID (and corresponding Private Key) should be generated for each one of your stores, and the remaining configured values in the Credentials section should be transferred accordingly.
Note
Magento Marketplace has disabled the ability to download packages directly in favor of installing packages via the Composer install method. For more information on adding packages via Composer, please see General CLI installation in the Magento dev docs.
Note
Please also have a look at the official Magento documentation for command line configuration: http://devdocs.magento.com/guides/v2.4/config-guide/cli/config-cli-subcommands.html
Un-install Method¶
If there is a need to disable the module, you can disable Amazon Pay in the extension settings. This will remove all customer facing parts.
To completely disable the module, please run:
php bin/magento module:disable Amazon_Pay
To completely uninstall the module using Composer, please run:
composer remove amzn/amazon-pay-magento-2-module
composer remove amzn/amazon-payments-magento-2-plugin