# API Reference

## Request for Cross-border Bank Transfer

<mark style="color:green;">`POST`</mark> `/trans/telegraphicTransfer`

\<Use this endpoint to request for SWIFT cross-border fund transfers>

**Parameters**

<table data-full-width="false"><thead><tr><th width="210">Parameters</th><th width="87">Type</th><th width="339">Description</th><th width="105">Is Required</th></tr></thead><tbody><tr><td><code>accountId</code></td><td>string</td><td>The ID of the account that is to make the transfer</td><td>TRUE</td></tr><tr><td><code>beneficiarySwiftBic</code></td><td>string</td><td><p>The bank code of the receiving bank</p><p>Use /staticData/getBankCodes endpoint to get the list of bank codes</p></td><td>TRUE</td></tr><tr><td><code>beneficiaryBankName</code></td><td>string</td><td>The name of the receiving bank</td><td>TRUE</td></tr><tr><td><code>beneficiaryBankCountry</code></td><td>string</td><td>The branch code of the receiving bank</td><td>FALSE</td></tr><tr><td><code>beneficiaryBankCity</code></td><td>string</td><td>The city of the receiving bank</td><td>TRUE</td></tr><tr><td><code>beneficiaryBankAddress</code></td><td>string</td><td>The address of the receiving bank</td><td>FALSE</td></tr><tr><td><code>beneficiaryAccountId</code></td><td>string</td><td>The number of the receiving account</td><td>TRUE</td></tr><tr><td><code>beneficiaryAccountCcy</code></td><td>string</td><td>The currency of the receiving account</td><td>TRUE</td></tr><tr><td><code>beneficiaryName</code></td><td>string</td><td>Beneficiary name</td><td>TRUE</td></tr><tr><td><code>beneficiaryEmail</code></td><td>string</td><td>The email address of the beneficiary</td><td>FALSE</td></tr><tr><td><code>amount</code></td><td>decimal</td><td>Transfer amount</td><td>TRUE</td></tr><tr><td><code>amountType</code></td><td>Int</td><td><p>0 - In Debit Account Currency</p><p>1 - In Credit Account Currency</p></td><td>TRUE</td></tr><tr><td><code>messageToBeneficiary</code></td><td>string</td><td>The message to beneficiary. Not more than 100 characters.</td><td>FALSE</td></tr><tr><td><code>paymentChannel</code></td><td>string</td><td>SWIFT</td><td>TRUE</td></tr><tr><td><code>paymentPurposeId</code></td><td>string</td><td>Please refer to <a href="../../../appendix/const#payment-purpose">Payment Purpose</a></td><td>TRUE</td></tr><tr><td><code>paymentPurpose</code></td><td>string</td><td>When paymentPurposeId == OTHR, specify the payment payment in this parameter. Not more than 35 characters.</td><td>FALSE</td></tr><tr><td><code>senderAddress</code></td><td>string</td><td>Sender's address</td><td>TRUE</td></tr><tr><td><code>supportDocument</code></td><td>string</td><td>Base 64 string</td><td>FALSE</td></tr><tr><td><code>supportDocumentType</code></td><td>string</td><td><p>PDF</p><p>Image</p></td><td>FALSE</td></tr><tr><td><code>chargeType</code></td><td>string</td><td><p>OUR </p><p>BEN </p><p>SHA </p><p></p><p>Notes: </p><p>OUR: Remitter to pay all charges </p><p></p><p>BEN: Beneficiary to pay all charges </p><p></p><p>SHA: Shared. Remitter to pay all fees charged by the sending bank (Here, Choice Bank) and Beneficiary to pay all fees charged by the receiving bank and intermediary/correspondent bank</p></td><td>TRUE</td></tr></tbody></table>

**Response**

{% tabs %}
{% tab title="00000" %}
```json
{
  "applicationId": ""
}
```
{% endtab %}
{% endtabs %}

## Query Inter-Bank Fund Transfer List

<mark style="color:green;">`POST`</mark> `/trans/getInterBankTransferList`

\<Use this endpoint to query the transfer application list of RTGS/EFT/SWIFT>

**Parameters**

<table data-full-width="false"><thead><tr><th width="210">Parameters</th><th width="87">Type</th><th width="339">Description</th><th width="105">Is Required</th></tr></thead><tbody><tr><td><code>accountId</code></td><td>string</td><td>The ID of the account that is to make the transfer</td><td>TRUE</td></tr><tr><td><code>startTime</code></td><td>long</td><td>Start time</td><td>TRUE</td></tr><tr><td><code>endTime</code></td><td>long</td><td>End time</td><td>TRUE</td></tr><tr><td><code>pageNo</code></td><td>int</td><td>Page number</td><td>TRUE</td></tr><tr><td><code>pageSize</code></td><td>int</td><td>Page size</td><td>TRUE</td></tr></tbody></table>

**Response**

{% tabs %}
{% tab title="00000" %}
```json
{
  "result": [
    {
      "applicationId": "",
      "accountId": "",
      "type": "", //1-Domesitc Fund Transfer; 2-Cross-border Fund Transfer
      "currency": "",
      "amount": "",
      "createTime": "",
      "status": "",
    }
  ]
}
```
{% endtab %}
{% endtabs %}

## Query Inter-Bank Fund Transfer Details

<mark style="color:green;">`POST`</mark> `/trans/getInterBankTransferDetails`

\<Use this endpoint to query the transfer application list of RTGS/EFT/SWIFT>

**Parameters**

<table data-full-width="false"><thead><tr><th width="210">Parameters</th><th width="87">Type</th><th width="339">Description</th><th width="105">Is Required</th></tr></thead><tbody><tr><td><code>applicationId</code></td><td>string</td><td>The ID of the RTGS/EFT/SWIFT transfer application</td><td>TRUE</td></tr><tr><td><code>accountId</code></td><td>string</td><td>Account number</td><td>TRUE</td></tr></tbody></table>

**Response**

{% tabs %}
{% tab title="00000" %}
```json
{
  "applicationId": "",
  "type": "", //1-Domesitc Fund Transfer; 2-Cross-border Fund Transfer
  "debitAccountId": "",
  "beneficiaryBankName": "",
  "beneficiaryBankCode": "",
  "beneficiaryBranchCode": "",
  "beneficiaryBankCountry": "",
  "beneficiaryBankCity": "",
  "beneficiaryBankAddress": "",
  "beneficiaryName": "",
  "beneficiaryEmail": "",
  "beneficiaryAccountId": "",
  "beneficiaryAccountCurr": "",
  "requestAmtType": "",//0-In debit account currency; 1-in beneficiary account currency
  "requestAmt": "",//requested transfer amount in the selected requestAmtType
  "transferAmt": "",//Actual transfer amount in debit account currency
  "bankCharge": "",
  "debitAmt": "",
  "chargeType": "",
  "paymentChannel": "",
  "paymentPurposeId": "",
  "paymentPurpose": "",
  "senderAddress": "",
  "messageToBeneficiary": "",
  "supportDocument": "",
  "supportDocumentType": "",
  "txId": "",
  "refundTxId": "",
  "referenceNumber": "",
  "createTime": "",
  "updateTime": "",
  "status": "",
  "errorCode": "",
  "errorMsg": "",
  "exchangeRate": "",
}
```
{% endtab %}
{% endtabs %}
