> For the complete documentation index, see [llms.txt](https://docs.b2core.b2broker.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.b2core.b2broker.com/how-to-articles/manage-payment-methods/how-to-add-deposit-and-withdrawal-methods-through-pss/how-to-integrate-1-2pay.md).

# How to integrate 1-2-Pay

[1-2-Pay](https://1-2-pay.com/) can be connected to B2CORE through [PSS](/integrations/payment-systems.md#payment-system-service-pss). It supports deposits via QR codes and withdrawals to bank accounts, processed in `THB`.

Follow the instructions below to configure the 1-2-Pay connections and set up the deposit and withdrawal methods in the B2CORE Back Office. These instructions correspond to the [General procedure](/how-to-articles/manage-payment-methods/how-to-add-deposit-and-withdrawal-methods-through-pss.md) for adding methods for PSS-supported payment systems, but include details specific to 1-2-Pay.

{% hint style="info" %}
Before proceeding with the instructions, you must have signed up for 1-2-Pay and have an active account.

All the details required for configuring connections to 1-2-Pay, including the **API start base URL**, **API sync base URL**, and other credentials, must be requested from the 1-2-Pay support.
{% endhint %}

## Configure connections to 1-2-Pay

If you plan to use 1-2-Pay for both deposits and withdrawals, you must configure two separate connections: one for deposits and another for withdrawals.

To configure a connection to 1-2-Pay:

{% stepper %}
{% step %}
In the B2CORE Back Office, navigate to **System** > **External connections**.
{% endstep %}

{% step %}
Click **+Create** in the upper-right page corner.
{% endstep %}

{% step %}
On the **Create connection** page, fill in the following fields:

* In the **Name** field, enter a name for the connection. The name must be unique and may only contain Latin letters, numbers, dashes, and underscores (for example, `Deposits_1-2-Pay` or `Withdrawals_1-2-Pay`).
* In the **Caption** field, enter a caption that will be applied to the connection in the Back Office.
* In the **Provider** dropdown, select:
  * **PaymentSystemDeposit** — to add a connection that will be used for a deposit method.
  * **PaymentSystemWithdrawal** — to add a connection that will be used for a withdrawal method.
    {% endstep %}

{% step %}
In the **Driver** dropdown that appears, select **1-2-PAY**.
{% endstep %}

{% step %}
In the **Credentials** section that appears, configure the settings specific to 1-2-Pay:

* In the **Sandbox** dropdown, select:
  * **Yes** — for the sandbox testing environment
  * **No** — for the production environment
* In the **API start base URL** field, specify the base URL for creating payment requests, provided by 1-2-Pay.
* In the **API sync base URL** field, specify the base URL used by B2CORE to receive and validate callbacks, also provided by 1-2-Pay.

{% hint style="info" %}

#### Key points about URLs

* The **API start base URL** and **API sync base URL** are different endpoints and must be requested directly from 1-2-Pay.

* Make sure to always use HTTPS, for example:
  * API start base URL: `https://api.example.com/`
  * API sync base URL: `https://inquiry.example.com/`

* 1-2-Pay provides specific URLs for each environment. The URLs for sandbox differ from those for production, so be sure to request both sets and use the appropriate ones for your configuration.
  {% endhint %}

* In the **Channel** field, enter the channel assigned to your integration by 1-2-Pay.

* In the **Partner code** field, enter the partner code assigned to your company by 1-2-Pay.

* In the **Auth key** field, enter the API key for signing requests, provided by 1-2-Pay.
  {% endstep %}

{% step %}
Click **Save** to create the connection.

The **1-2-Pay** connection will appear in the list of external connections.
{% endstep %}

{% step %}
Check the connection status.

If the connection is inactive (**No** is displayed in the **Enabled** column), click the **Edit** button to open the connection details and set the **Enabled** dropdown to **Yes**.
{% endstep %}

{% step %}
Click **Save** to apply the changes.
{% endstep %}
{% endstepper %}

If you need to support both deposits and withdrawals via 1-2-Pay, follow the same instruction to create a new connection for the other operation.

## Add a deposit method through 1-2-Pay

To add and set up a method for making deposits through 1-2-Pay:

{% stepper %}
{% step %}
In the B2CORE Back Office, navigate to **System** > **Deposit system** > **Deposit methods**.
{% endstep %}

{% step %}
Click **+Create** in the upper-right page corner.
{% endstep %}

{% step %}
On the **Create a deposit method** page, fill in the following fields:

* In the **Name** field, enter a name for the method. The name must be unique and may only contain Latin letters, numbers, dashes, and underscores.
* In the **Caption** field, enter a caption for the method. This caption will be assigned to the method in the Back Office and will be visible to clients in the B2CORE UI.
* In the **Provider** dropdown, select **PaymentSystemDeposit**.
  {% endstep %}

{% step %}
After selecting **PaymentSystemDeposit**, the following fields appear:

* In the **Available account currencies** dropdown, select one or more currencies. Deposits through 1-2-Pay will be available to accounts denominated in the selected currencies. For these currencies, conversion rates for `THB` must be configured.
* In the **Driver** dropdown, select **1-2-PAY**.
* In the **Connection** dropdown, select the previously configured [1-2-Pay connection](#configure-connections-to-1-2-pay).
  {% endstep %}

{% step %}
Skip the **Configuration** section as no settings are required for the 1-2-Pay deposit method.
{% endstep %}

{% step %}
Click **Save** to create the deposit method.

The **1-2-Pay** deposit method will appear in the list of deposit methods.
{% endstep %}

{% step %}
Click **Edit** to enter the method details and complete the following fields:

* On the **Settings** tab, use the **Group** dropdown to select one or more groups where the method should be included.
* In the **Icon** field, specify `paymethod-12pay` to display the [predefined icon](/integrations/payment-systems.md) for the 1-2-Pay deposit method in the B2CORE UI. To use a custom icon, specify the URL of the image to be displayed.
* Check the method status.

  If the method is inactive (**No** is displayed in the **Enabled** field), activate it by setting the **Enabled** dropdown to **Yes**.
* On the **PS Currencies** tab, add `THB`.
* If needed, configure commissions for the method on the **Commissions** tab (for details, refer to [How to configure commissions for deposit and withdrawal methods](/how-to-articles/manage-payment-methods/how-to-configure-commissions-for-deposit-and-withdrawal-methods.md)).

<figure><img src="/files/Q4mGkP1OIdDXqaQOdIrB" alt="1-2-Pay deposit method — Settings tab"><figcaption><p>1-2-Pay deposit method — Settings tab</p></figcaption></figure>
{% endstep %}

{% step %}
Click **Test configuration** to validate the connection settings of the deposit method.

The test result will be displayed on the page.
{% endstep %}

{% step %}
After successfully validating the configuration, click **Save**.
{% endstep %}
{% endstepper %}

The **1-2-Pay** deposit method is now configured in the B2CORE Back Office.

## Add a withdrawal method through 1-2-Pay

To add and set up a method for making withdrawals through 1-2-Pay:

{% stepper %}
{% step %}
In the B2CORE Back Office, navigate to **System** > **Payout system** > **Payout methods**.
{% endstep %}

{% step %}
Click **+Create** in the upper-right page corner.
{% endstep %}

{% step %}
On the **Create a payout method** page, fill in the following fields:

* In the **Name** field, enter a name for the method. The name must be unique and may only contain Latin letters, numbers, dashes, and underscores.
* In the **Caption** field, enter a caption for the method. This caption will be assigned to the method in the Back Office and will be visible to clients in the B2CORE UI.
* In the **Provider** dropdown, select **PaymentSystemWithdrawal**.
  {% endstep %}

{% step %}
After selecting **PaymentSystemWithdrawal**, the following fields appear:

* In the **Available account currencies** dropdown, select one or more currencies. Withdrawals through 1-2-Pay will be available from accounts denominated in the selected currencies. For these currencies, conversion rates for `THB` must be configured.
* In the **Driver** dropdown, select **1-2-PAY**.
* In the **Connection** dropdown, select the previously configured [1-2-Pay connection for withdrawals](#configure-connections-to-1-2-pay).
  {% endstep %}

{% step %}
Skip the **Configuration** section as no settings are required for the 1-2-Pay withdrawal method.
{% endstep %}

{% step %}
Click **Save** to create the withdrawal method.

The **1-2-Pay** withdrawal method will appear in the list of withdrawal methods.
{% endstep %}

{% step %}
Click **Edit** to enter the method details and complete the following fields:

* On the **Settings** tab, use the **Group** dropdown to select one or more groups where the method should be included.
* In the **Icon** field, specify `paymethod-12pay` to display the [predefined icon](/integrations/payment-systems.md) for the 1-2-Pay withdrawal method in the B2CORE UI. To use a custom icon, specify the URL of the image to be displayed.
* Check the method status.

  If the method is inactive (**No** is displayed in the **Enabled** field), activate it by setting the **Enabled** dropdown to **Yes**.
* On the **PS Currencies** tab, add `THB`.
* If needed, configure commissions for the method on the **Commissions** tab (for details, refer to [How to configure commissions for deposit and withdrawal methods](/how-to-articles/manage-payment-methods/how-to-configure-commissions-for-deposit-and-withdrawal-methods.md)).

<figure><img src="/files/vP99D7qeeyJaMQpfvcch" alt="1-2-Pay withdrawal method — Settings tab"><figcaption><p>1-2-Pay withdrawal method — Settings tab</p></figcaption></figure>
{% endstep %}

{% step %}
Click **Test configuration** to validate the connection settings of the withdrawal method.

The test result will be displayed on the page.
{% endstep %}

{% step %}
After successfully validating the configuration, click **Save**.
{% endstep %}
{% endstepper %}

The **1-2-Pay** withdrawal method is now configured in the B2CORE Back Office.

## Set up webhooks in 1-2-Pay

To receive status updates for deposits and withdrawals in B2CORE, notification webhooks must be set up on the side of 1-2-Pay.

### Copy webhook URLs from the B2CORE Back Office

You will need separate webhook URLs for both deposit and withdrawal methods.

{% stepper %}
{% step %}
In the B2CORE Back Office, navigate to:

* **System** > **Deposit system** > **Deposit methods**
* **System** > **Payout system** > **Payout methods**
  {% endstep %}

{% step %}
Find the configured 1-2-Pay deposit or withdrawal method and click **Edit** to open its details.
{% endstep %}

{% step %}
Go to the **Webhooks** tab.
{% endstep %}

{% step %}
Copy the URL displayed in the **Notification URL** field.
{% endstep %}
{% endstepper %}

### Provide URLs to 1-2-Pay

Send the copied webhook URLs (for both deposits and withdrawals) to the 1-2-Pay support for configuration on their side.


---

# 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 dynamically by asking a question.

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

```
GET https://docs.b2core.b2broker.com/how-to-articles/manage-payment-methods/how-to-add-deposit-and-withdrawal-methods-through-pss/how-to-integrate-1-2pay.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.
