> For the complete documentation index, see [llms.txt](https://docs.ecommerce.seb.ee/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.ecommerce.seb.ee/integration/paypal.md).

# PayPal

**PayPal** allows customers to pay using their PayPal account through the **SEB Ecommerce Payment Gateway**.

PayPal is an optional payment method and must be enabled for each shop where you want to offer it.

The availability of PayPal depends on your merchant agreement, shop configuration, and approval by SEB.

***

### Before You Begin

Before configuring PayPal, ensure that:

* You have access to the **SEB Merchant Portal**.
* You have a Sandbox Shop or Live Shop where PayPal will be used.
* PayPal is enabled for the selected shop.
* You have an active [**PayPal Business account**](https://www.paypal.com/c2/webapps/mpp/manage-my-account?locale.x=en_C2), where required.
* You have the required PayPal credentials for the applicable environment.

{% hint style="info" %}
If PayPal is not currently enabled for your shop, you can request it through the Merchant Portal.
{% endhint %}

***

### Enable PayPal for Your Shop

PayPal must be enabled separately for each shop where you want to accept PayPal payments.

If PayPal is not included in the current configuration of your shop, you can request it by updating your shop agreement.

#### Request PayPal

To request PayPal:

1. Sign in to the **SEB Merchant Portal**.
2. Select the required **Sandbox Shop** or **Live Shop**.
3. Navigate to **Settings → Shop Settings**.
4. Select **Edit Agreement**.
5. Open the **Payments** section.
6. Add **PayPal** to the requested payment methods.
7. Complete any additional information requested in the Merchant Portal.
8. Select **Submit for Approval**.

Your request will be submitted to SEB for review.

{% hint style="info" %}
Adding PayPal through **Edit Agreement** does not immediately enable the payment method. PayPal becomes available for the selected shop after the request has been reviewed and approved by SEB.
{% endhint %}

***

### Track Your Request

You can monitor the status of your request in **My Requests** in the Merchant Portal.

The request will show its current processing status, for example whether it is awaiting review, approved, or declined.

You will also receive an email notification when SEB has approved or declined your request.

Once approved, PayPal becomes available for the applicable shop and you can continue with the required configuration.

{% hint style="info" %}
Sandbox Shops and Production Shops are configured separately. If you want to use PayPal in both environments, ensure that PayPal is enabled for both the applicable Sandbox Shop and Production Shop.
{% endhint %}

***

### Set Up Your PayPal Account

To process PayPal payments, you may need a [**PayPal Business account**](https://www.paypal.com/c2/webapps/mpp/manage-my-account?locale.x=en_C2) and PayPal API credentials.

If you do not already have an appropriate PayPal account, create one through PayPal and complete any verification required by PayPal.

To obtain PayPal API credentials:

1. Sign in to the [**PayPal Developer Dashboard**](https://developer.paypal.com/).
2. Open **Apps & Credentials**.
3. Select the required PayPal environment.
4. Create an application for your ecommerce payment integration.
5. Open the application.
6. Obtain the credentials provided by PayPal:
   * **Client ID**
   * **Client Secret**

Keep your PayPal credentials secure.

{% hint style="warning" %}
PayPal Sandbox and Live credentials are separate. Never use PayPal Sandbox credentials for live payment processing or PayPal Live credentials for Sandbox testing.
{% endhint %}

***

### Configure PayPal for Your SEB Shop

After PayPal has been approved for your shop, complete the required PayPal configuration for that shop.

PayPal configuration is **shop-specific**. If you manage multiple shops, ensure that the correct PayPal configuration is associated with each shop where you intend to offer PayPal.

The configuration required may differ between Sandbox and Production.

{% hint style="danger" %}
Treat your PayPal Client Secret as confidential authentication information. Do not expose it in browser code, mobile applications, public repositories, logs, or other client-accessible locations.
{% endhint %}

***

### Sandbox Testing

Use **Sandbox Mode** to validate the PayPal customer journey before processing live transactions.

Use only [PayPal Sandbox accounts](https://developer.paypal.com/sandbox-testing/accounts/), credentials, and test data when testing.

Where supported by your Sandbox configuration, validate:

* Successful PayPal payment.
* Failed payment.
* Customer cancellation.
* Customer return.
* Payment status handling.
* Callback processing.
* Refund processing.
* Transaction visibility in **Merchant Portal → Orders**.

{% hint style="info" %}
Sandbox PayPal transactions are test transactions only. They do not represent live customer payments or transfer real customer funds.
{% endhint %}

***

### Payment Result

Do not use the customer's browser return as confirmation that a PayPal payment has completed successfully.

Use the confirmed payment status provided by the **SEB Ecommerce Payment Gateway** as the source of truth for your order processing.

Your application should:

* Store the Payment ID.
* Process payment status updates.
* Handle callback notifications where applicable.
* Update the order only according to the confirmed payment status.
* Prevent duplicate order processing.

***

### Refunds

Where refunds are enabled for PayPal, you can refund an eligible completed payment using the payment operations supported by the SEB Ecommerce Payment Gateway.

Before initiating a refund:

* Verify the original payment status.
* Identify the original Payment ID.
* Verify the amount available for refund.
* Submit the refund using the supported Merchant Portal or API functionality.
* Verify the resulting refund status before updating your business records.

For detailed refund requirements and supported operations, see **Refunds**.

***

### Prepare for Live

Before accepting live PayPal payments:

* Confirm that PayPal is approved and enabled for your **Production Shop**.
* Ensure that your PayPal Business account is ready for live payment processing.
* Configure the required PayPal **Live credentials**.
* Ensure that no Sandbox credentials are used in Production.
* Verify the Live shop configuration.
* Verify your callback and payment status handling.
* Test your order-management logic.
* Verify refund processing where applicable.

{% hint style="info" %}
Sandbox and Live are separate environments. PayPal being available for a Sandbox Shop does not automatically mean that it is enabled for the corresponding Production Shop.
{% endhint %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

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

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.ecommerce.seb.ee/integration/paypal.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
