# Magento 2

## **Requirements**

Before installing the extension, ensure your environment meets the following requirements:

* Magento version: 2.4.7
* PHP version: 8.3

> Using an unsupported version of Magento or PHP may result in unexpected behavior.

## **Installation Instructions**

Follow these steps to install the **E-commerce Gateway extension:**

1. **Navigate to the Magento 2 code directory**

Go to your Magento installation path:

> magento2/app/code

{% hint style="info" %}
If the code directory does not exist, create it manually.
{% endhint %}

2. **Extract the extension files**

&#x20;Unzip the downloaded extension package and place its contents into:

> magento2/app/code

Folder structure should look like:

> magento2/app/code/Tietoevry/EGW

3. **Enable the extension via command line**

&#x20;Open a terminal and navigate to the root of your Magento installation and then run the following commands:

> php bin/magento module:enable Tietoevry\_EGW\
> php bin/magento setup:upgrade\
> php bin/magento cache:flush

The extension is now installed and ready for configuration.

## **Configuration Instructions**

The payment methods provided by the E-commerce Payment Gateway extension are disabled by default. To enable and configure them:

1. **Log in to the Magento Admin Panel**

By default, this is accessible at:

> https\://\<your\_domain>/admin

2. **Navigate to the configuration settings**

In the left-hand menu, go to:

> Stores → Configuration
>
> ![](/files/BVDW8pVUGbi0n5qhXWJo)

3. **Access payment method settings**

Under the **Sales** section, click on **Payment Methods**.

<figure><img src="/files/7i8VzzYwFJB69m9QLUU4" alt=""><figcaption></figcaption></figure>

4. **Locate the E-commerce Gateway settings**

Scroll to the **Other Payment Methods** section and find **Tietoevry E-commerce Payment  Gateway**.

5\. Configure the extension:

\- Set **Enabled** to **Yes** to activate the payment methods.\
\- Choose the desired Environment:\
  - Sandbox (recommended for testing)\
  - Live (for production use)\
\- Enter your OAuth2 credentials as provided by Tietoevry.

<figure><img src="/files/O7WkkrItY08rwhUk5hzH" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
We recommend thoroughly testing in the sandbox environment before switching to live mode.
{% endhint %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://doc.ecomm.api.tietoevry.com/integrations/plug-ins/magento-2.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
