Depending on the source, there are two methods of installing the Feefo_Reviews module.

Method A

If you purchased the extension for your account at the Marketplace:

Ensure the access keys for your account are specified in auth.json file. For example:

{
"http-basic": {
"repo.magento.com": {
"username": "<public_key>",
"password": "<private_key>"
}
}
}

To set your keys globally use the following command:

composer global config http-basic.repo.magento.com <public_key> <private_key>

For more details, please, check the official Magento 2.x guide. Move to Step 2.

Method B

If the extension was provided via a ZIP archive:

Composer can be configured to load the extension from a local storage location. You need to copy the provided ZIP archive to:

magento_root_folder/src/feefo/packages/Feefo_Reviews.zip

Where:

magento_root_folder = the first and top-most directory in your Magento 2.x file-tree hierarchy. Its location will depend on your installation.

Once done, navigate to the Magento 2.x installation root folder and configure Composer for the local artifact repository usage:

composer config repositories.feefo.artifacts artifact $(pwd)/src/feefo/packages

Where:

$(pwd) = the absolute path to your magento_root_folder.

In order to remove the ability to use the local archive and switch back to Method A, the local artifact repository should be removed from the composer.json in the Magento 2.x installation root directory as follows:

composer config repositories.atwix.artifacts "FALSE"

Move to Step 2.

Step 2 - Run the following command to add the Feefo Reviews dependency into composer.json file and install the module.

composer require feefo/reviews

Step 3 - Enable the module:

php bin/magento --clear-static-content module:enable Feefo_Reviews

Step 4 - Update the database:

php bin/magento setup:upgrade

Step 5 - Run Magento 2.x compile:

bin/magento setup:di:compile

The latest version of the module is now installed.

Possible Installation Issues

When installing Magento 2.x using Composer, you may see the following error message:

PHP Fatal error: Uncaught Error: Cannot instantiate interface Feefo\Reviews\Api\Feefo\StorageInterface in /[path-to-M2]/vendor/magento/framework/ObjectManager/Factory/Dynamic/Developer.php:73

This is probably due to a missing or incorrect Magento version number being entered into Composer and so it tries to install a more recent version than is needed. Ensure that the correct version number is used and you should find that Composer installs the correct version without errors.

How to uninstall the Feefo_Reviews (only if the extension was installed via Composer)

To uninstall the Feefo Reviews extension run the following command:

bin/magento module:uninstall Feefo_Reviews