# Fundtransfer

## Request

{% hint style="info" %}
**Good to know:** Please press ">" to see detail.
{% endhint %}

## This API is used for making realtime transfer via Napas, Sacombank and eWallet in Vietnam (Zalo,VNPT,..)

<mark style="color:green;">`POST`</mark> `https://{SERVER}/Api/SBR/Fundtransfer`

The result of proceeding transaction shall be responded immediately (without recalling API for checking status). In case transaction is failed, SBR will actively re-proceed. Afterward, Partner can call API CheckOrderStatus/GetOrderDetails for rechecking (for the case of Status =2)

#### Request Body

| Name                                              | Type      | Description                                                                                                                                                                                                                                                                                                                                                                                         |
| ------------------------------------------------- | --------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| AuthID<mark style="color:red;">\*</mark>          | Text      | **User ID assigned by SBR**                                                                                                                                                                                                                                                                                                                                                                         |
| ProtocolData<mark style="color:red;">\*</mark>    |           | Data request                                                                                                                                                                                                                                                                                                                                                                                        |
| Reference<mark style="color:red;">\*</mark>       | Text      | ID of payment order                                                                                                                                                                                                                                                                                                                                                                                 |
| AgentID<mark style="color:red;">\*</mark>         | Text(20)  | Assigned by SBR, **AgentID=UserID=AuthID**                                                                                                                                                                                                                                                                                                                                                          |
| CurrencyID<mark style="color:red;">\*</mark>      | Text(10)  | Currency **(VND)**                                                                                                                                                                                                                                                                                                                                                                                  |
| OrderedAmt<mark style="color:red;">\*</mark>      | Number    | Amount                                                                                                                                                                                                                                                                                                                                                                                              |
| Beneficiary<mark style="color:red;">\*</mark>     | Text(300) | Beneficiary name                                                                                                                                                                                                                                                                                                                                                                                    |
| Address<mark style="color:red;">\*</mark>         | Text(500) | Address of beneficiary name                                                                                                                                                                                                                                                                                                                                                                         |
| Sender<mark style="color:red;">\*</mark>          | Text(300) | Sender name                                                                                                                                                                                                                                                                                                                                                                                         |
| SenderAddress<mark style="color:red;">\*</mark>   | Text(300) | Address of sender                                                                                                                                                                                                                                                                                                                                                                                   |
| SenderCountryID<mark style="color:red;">\*</mark> | Text(20)  | Sender country code                                                                                                                                                                                                                                                                                                                                                                                 |
| BankAcctNo<mark style="color:red;">\*</mark>      | Text(30)  | Aaccount number of Beneficiary                                                                                                                                                                                                                                                                                                                                                                      |
| BankName<mark style="color:red;">\*</mark>        | Text      | Bank name of Beneficiary                                                                                                                                                                                                                                                                                                                                                                            |
| BankGroup<mark style="color:red;">\*</mark>       | Text(1)   | <p>Bank mode</p><p></p><p><em><mark style="color:red;"><strong>Sacombank = 1</strong></mark></em> </p><p><em><mark style="color:red;"><strong>Napas= 3</strong></mark></em> </p><p><em><mark style="color:red;"><strong>eWallet = 7</strong></mark></em></p>                                                                                                                                        |
| AccType                                           | Text      | <p>Type of account transferring </p><p></p><p><em><mark style="color:red;"><strong>Account Deposit = ACC</strong></mark></em> </p><p><em><mark style="color:red;"><strong>Pan Depost = PAN</strong></mark></em></p><p><em><mark style="color:red;"><strong>ZaloPay = Zalo</strong></mark></em></p><p><em><mark style="color:red;"><strong>VNPTPay= VNPTPay</strong></mark></em></p>                 |
| BankCode<mark style="color:red;">\*</mark>        | Text      | <p>BankCode of Method</p><p><mark style="color:red;"><strong>Sacombank -> BankCode=303</strong></mark></p><p><mark style="color:red;"><strong>Zalo -> BankCode=Zalo</strong></mark></p><p><mark style="color:red;"><strong>If VNPTPay -> BankCode=VNPTPay</strong></mark></p><p><mark style="color:red;"><strong>If NAPAS -> BankCode=BankCode of NAPAS, ex: 970406 - DongABank</strong></mark></p> |

{% tabs %}
{% tab title="200: OK Success" %}

```javascript
{
    // Response
}
```

{% endtab %}

{% tab title="401: Unauthorized Invalid username or password. Please try again!" %}

{% endtab %}

{% tab title="406: Not Acceptable Require signature - Signature incorrect" %}

{% endtab %}
{% endtabs %}

### Response Data

|                   |               |                                                                                                                                                                                                                                                      |                                                                                                                                                                                     |
| ----------------- | ------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **Parameters**    | **Data Type** | **Description**                                                                                                                                                                                                                                      | **Note**                                                                                                                                                                            |
| **Status**        | Number        | <p>Return status of request:</p><p><mark style="color:red;"><strong>Fail = 0</strong></mark></p><p><mark style="color:green;"><strong>Success = 1</strong></mark><br><em><mark style="color:orange;"><strong>Processing = 2</strong></mark></em></p> | *<mark style="color:red;">**If Status = 0 and Error Message refers to a timeout/failed => please verify transaction status before proceeding with a retry or cancellation**</mark>* |
| **Error Message** | Text          | Error description                                                                                                                                                                                                                                    |                                                                                                                                                                                     |
| **ProtocolData**  | Object        | List of payments has error                                                                                                                                                                                                                           |                                                                                                                                                                                     |

[<mark style="color:red;">**Note:**</mark> ](#user-content-fn-1)[^1] *In case you receive a response **"400 - Internal server error/Timeout" o*****r errors starting with 'Internal server error!....'"*****,** call the CheckOrderStatus or GetOrderDetail API to check the final status of the transaction. If the result is Payment not found, please re-send the new transaction or cancel on your side. If the result returns the status of the transaction => The transaction has been sent to SBR successfully and the status is compared according to the description of the API CheckOrderStatus or GetOrderDetail*

**Example:** { "Status": 0, "Error": "400 - Internal server error/Timeout", }

#### Request Example

{% tabs %}
{% tab title="Sacombank Deposit with Account Number" %}

```json
// Request Sacmbank Deposit with Account Number
{
  "AuthID": "123",
  "ProtocolData": {
    "BankName": "Sacombank",
    "SenderAddress": "JAPAN",
    "Address": "Vietnam",
    "AccType": "ACC",
    "Reference": "REF123456",
    "SenderCountryID": "JP",
    "BankCode": "303",
    "CurrencyID": "VND",
    "OrderedAmt": "10000",
    "Sender": "NGUYEN VAN B",
    "BankAcctNo": "0909227275",
    "AgentID": "123",
    "BankGroup": "1",
    "Beneficiary": "NGUYEN VAN A"
  }
}
```

{% endtab %}

{% tab title="Sacombank Deposit with PAN Number" %}

```json
// Request Sacmbank Deposit with PAN Number
{
  "AuthID": "123",
  "ProtocolData": {
    "BankName": "Sacombank",
    "SenderAddress": "JAPAN",
    "Address": "Vietnam",
    "AccType": "PAN",
    "Reference": "REF123456",
    "SenderCountryID": "JP",
    "BankCode": "303",
    "CurrencyID": "VND",
    "OrderedAmt": "10000",
    "Sender": "NGUYEN VAN B",
    "BankAcctNo": "970403XXXXXXX",
    "AgentID": "123",
    "BankGroup": "1",
    "Beneficiary": "NGUYEN VAN A"
  }
}
```

{% endtab %}

{% tab title="Napas Deposit with PAN Number" %}

```json
// Request Napas Deposit with PAN Number
{
  "AuthID": "123",
  "ProtocolData": {
    "BankName": "DONG A BANK",
    "SenderAddress": "JAPAN",
    "Address": "Vietnam",
    "AccType": "PAN",
    "Reference": "REF123456",
    "SenderCountryID": "JP",
    "BankCode": "970406",
    "CurrencyID": "VND",
    "OrderedAmt": "10000",
    "Sender": "NGUYEN VAN B",
    "BankAcctNo": "970406xxxxxxxxx",
    "AgentID": "123",
    "BankGroup": "1",
    "Beneficiary": "NGUYEN VAN A"
  }
}
```

{% endtab %}

{% tab title="ZaloPay" %}

```json
// Request Zalo Pay
{
  "AuthID": "123",
  "ProtocolData": {
    "BankName": "ZaloPay",
    "SenderAddress": "JAPAN",
    "Address": "Vietnam",
    "AccType": "Zalo",
    "Reference": "REF123456",
    "SenderCountryID": "JP",
    "BankCode": "Zalo",
    "CurrencyID": "VND",
    "OrderedAmt": "10000",
    "Sender": "NGUYEN VAN B",
    "BankAcctNo": "0909227275",
    "AgentID": "123",
    "BankGroup": "7",
    "Beneficiary": "NGUYEN VAN A"
  }
}
```

{% endtab %}

{% tab title="VNPTPay" %}

```json
// Request VNPTPay eWallet
{
  "AuthID": "123",
  "ProtocolData": {
    "BankName": "VNPTPay",
    "SenderAddress": "JAPAN",
    "Address": "Vietnam",
    "AccType": "VNPTPay",
    "Reference": "REF123456",
    "SenderCountryID": "JP",
    "BankCode": "VNPTPay",
    "CurrencyID": "VND",
    "OrderedAmt": "10000",
    "Sender": "NGUYEN VAN B",
    "BankAcctNo": "0909227275",
    "AgentID": "123",
    "BankGroup": "7",
    "Beneficiary": "NGUYEN VAN A"
  }
}
```

{% endtab %}
{% endtabs %}

#### Response Example

{% tabs %}
{% tab title="Order is error" %}

```json
//Payment received for processing 
{
  "Status": 2,
  "Error": "206-Balance is not enough to payment",
  "Trace": "Payment received for processing, please check the status in a few minutes"
}
```

{% endtab %}

{% tab title="Success" %}

```json
{
  "Status": 1,
  "Error": ""
}
```

{% endtab %}
{% endtabs %}

[^1]:


---

# 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://docs.sacombank-sbr.com.vn/reference/api-reference/fundtransfer.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.
