> For the complete documentation index, see [llms.txt](https://docs.en.omnibridge.pro/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.en.omnibridge.pro/cross-chain-swap-api/check-token-types-list-port.md).

# Get Coin List

Provide token types list to display users, tell user which tokens can be traded

1. Url:

```
https://{host}/api/v1/queryCoinList
```

2\. Request parameter instance

| parameter   | whether | explain                                                                                                                                             |
| ----------- | ------- | --------------------------------------------------------------------------------------------------------------------------------------------------- |
| supportType | no      | Advanced: return only the currencies that support cross chain exchange, and return all currencies without transferring or transferring other values |
| mainNetwork | no      | According to the currency main search                                                                                                               |
| sourceFlag  | yes     | sourceFlag                                                                                                                                          |

3\. Example of request parameters

```
{
    "supportType":"advanced",
    "mainNetwork":"ETH",
    "sourceFlag": "xxx"
}
```

4.Example of returned results

```
{
    "data": [
        {
            "coinAllCode": "SwftCoin",
            "coinCode": "SWFTC",
            "coinDecimal": 8,
            "contact": "0x0bb217E40F8a5Cb79Adf04E1aAb60E5abd0dfC1e",
            "isSupportAdvanced": "Y",
            "isSupportMemo": "N",
            "mainNetwork": "ETH",
            "noSupportCoin": "BOS,YOYO,..."
        },
        {
            "coinAllCode": "TetherUS",
            "coinCode": "USDT",
            "coinDecimal": 6,
            "contact": "0xdac17f958d2ee523a2206206994597c13d831ec7",
            "isSupportAdvanced": "Y",
            "isSupportMemo": "N",
            "mainNetwork": "BTC",
            "noSupportCoin": "BCC,UCTT,..."
        }
    ],
    "resCode": "800",
    "resMsg": "success",
    "resMsgEn": ""
}
```

5.Return Parameter Description

<table><thead><tr><th width="197">Field Name  </th><th width="187">Field  </th><th width="84">Type  </th><th width="290">Remarks</th></tr></thead><tbody><tr><td>coinAllCode</td><td>coinAllCode</td><td>String</td><td>Bitcoin</td></tr><tr><td>coinCode</td><td>coinCode</td><td>String</td><td>BTC</td></tr><tr><td>coin decimal</td><td>coinDecimal</td><td>String</td><td>8</td></tr><tr><td>contact </td><td>contact </td><td>String</td><td>This field has a value only when the currency belongs to a token on a primary chain</td></tr><tr><td>isSupportAdvanced</td><td>isSupportAdvanced</td><td>String</td><td>Y:  supported. N: no supported</td></tr><tr><td>isSupportMemo</td><td>isSupportMemo</td><td>String</td><td>Y:  supported. N: no supported</td></tr><tr><td>mainNetwork</td><td>mainNetwork</td><td>String</td><td>For example, if SWFTC is the token on Ethereum, mainNetwork is ETH</td></tr><tr><td>noSupportCoin</td><td>noSupportCoin</td><td>String</td><td>If there are multiple unsupported currencies, separate them with ','. For example: "noSupportCoin":"TKT,SHE,AIDOC"</td></tr></tbody></table>

### &#x20;Code example <a href="#code-example" id="code-example"></a>

#### &#x20;java code exampl&#x65;**：** <a href="#java-code-example" id="java-code-example"></a>

```java
OkHttpClient client = new OkHttpClient();
  ​
  MediaType mediaType = MediaType.parse("application/json");
  RequestBody body = RequestBody.create(mediaType, "{\"supportType\":\"advanced\"}");
  Request request = new Request.Builder()
    .url("https://{host}/api/v1/queryCoinList")
    .post(body)
    .addHeader("Content-Type", "application/json")
    .addHeader("cache-control", "no-cache")
    .build();
  ​
  Response response = client.newCall(request).execute();
```

**Nodejs** **code example**

```javascript
   //getToken example 
   import axios from 'axios'
   const params = {
      supportType: 'advanced',
    }
   const res = await axios.post('https://{host}/api/v1/queryCoinList', params )
   console.log(res)
```

#### Postman example

![](/files/z4dGtjlHxmb1WFbmmNmc)

### **Response result example** <a href="#response-result-example" id="response-result-example"></a>

```yaml
  {
      "data": [
        {
            "coinAllCode": "Bitcoin",
            "coinCode": "BTC",
            "coinImageUrl": "/static/image/coins/bitcoin.png",
            "coinName": "比特币",
            "contact": "",
            "isSupportAdvanced": "Y",
            "mainNetwork": "",
            "noSupportCoin": "BCC,SAN,ICX,EET,ETDM,BCC,GZRO,DTO,UCTT"
        },
        {
            "coinAllCode": "Ether",
            "coinCode": "ETH",
            "coinImageUrl": "/static/image/coins/ether.png",
            "coinName": "以太币",
            "contact": "",
            "isSupportAdvanced": "Y",
            "mainNetwork": "",
            "noSupportCoin": "BCC,SAN,ICX,EET,ETDM,BCC,GZRO,DTO,UCTT"
        },
        {
            "coinAllCode": "EOS",
            "coinCode": "EOS",
            "coinImageUrl": "",
            "coinName": "基数链",
            "contact": "",
            "isSupportAdvanced": "Y",
            "mainNetwork": "",
            "noSupportCoin": "BCC,SAN,ICX,EET,ETDM,BCC,GZRO,DTO,UCTT"
        },
        {
            "coinAllCode": "Stellar",
            "coinCode": "XLM",
            "coinImageUrl": "",
            "coinName": "Stellar",
            "contact": "",
            "isSupportAdvanced": "Y",
            "mainNetwork": "",
            "noSupportCoin": "BCC,SAN,TCT,ICX,GAT,CK.USD,EET,ETDM,USDC,BCC,GZRO,DTO,LV,TRX,DAI,UCTT"
        },
        {
            "coinAllCode": "Litecoin",
            "coinCode": "LTC",
            "coinImageUrl": "/static/image/coins/litecoin.png",
            "coinName": "莱特币",
            "contact": "",
            "isSupportAdvanced": "Y",
            "mainNetwork": "",
            "noSupportCoin": "BCC,SAN,ICX,EET,ETDM,BCC,GZRO,DTO,UCTT"
        },
          ...
      ],
      "resCode": "800",
      "resMsg": "成功"
  }
```

### &#x20;Important Items:

> &#x20; For some of the tokens supported on our platform, sometimes there will be a conflict with the tokens supported by other platforms or have different names for the token. In order to avoid sending the wrong token, you should used the names specifed in the fields `mainNetwork`and `contact`\`, currently the platform supports **ETH, BSC,HECO,MATIC,OEC,TRON,EOS,XRP,** etc. mainnet's tokens.&#x20;
