# Get Token List

{% openapi src="<https://2330303583-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FXEWf0ylbbPQ6t8CoOLdL%2Fuploads%2Fgit-blob-a3069d4dd3ee104fd54371bb6ae0d122d7d67108%2Fglobal.json?alt=media>" path="/brc20swap/search\_ticks" method="post" %}
[global.json](https://2330303583-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FXEWf0ylbbPQ6t8CoOLdL%2Fuploads%2Fgit-blob-a3069d4dd3ee104fd54371bb6ae0d122d7d67108%2Fglobal.json?alt=media)
{% endopenapi %}

Used to get the list of available tokens for swapping, adding liquidity, etc.

## Swapping

Used for swapping tokens.

Get the complete list of tokens available for swapping, i.e., all tokens that have liquidity pools.

* **usetype:** Use `swap`.

{% hint style="info" %}
**Note:** Only tokens with injected liquidity pools can be swapped.
{% endhint %}

#### Example

{% tabs %}
{% tab title="Parameter" %}

```json
{
    "page": 1,
    "page_size": 30,
    "keyword": "",
    "usetype": "swap",
    "coin_type": "runes"
}
```

{% endtab %}

{% tab title="cURL Example" %}

```sh
curl 'https://test-api-proxy.ddpurse.com/brc20swap/search_ticks' \
  -H 'Accept: application/json, text/plain, */*' \
  -H 'Accept-Language: en' \
  -H 'Cache-Control: no-cache' \
  -H 'Connection: keep-alive' \
  -H 'Content-Type: application/json' \
  -H 'Origin: http://localhost:56651' \
  -H 'Pragma: no-cache' \
  -H 'Referer: http://localhost:56651/' \
  -H 'Sec-Fetch-Dest: empty' \
  -H 'Sec-Fetch-Mode: cors' \
  -H 'Sec-Fetch-Site: cross-site' \
  -H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36' \
  -H 'sec-ch-ua: "Not_A Brand";v="8", "Chromium";v="120", "Google Chrome";v="120"' \
  -H 'sec-ch-ua-mobile: ?0' \
  -H 'sec-ch-ua-platform: "macOS"' \
  --data-raw '{"page":1,"page_size":30,"keyword":"","usetype":"swap","coin_type":"runes"}' \
  --compressed
```

{% endtab %}
{% endtabs %}

## Swappable Tokens

Used to get the list of all tokens swappable with a selected token (tick1).

* **tick1:** The name of the selected token.
* **usetype:** Use `gettick2`.

**Example**

{% tabs %}
{% tab title="Parameters" %}

```typescript
{
    "page": 1,
    "page_size": 30,
    "keyword": "",
    "usetype": "gettick2",
    "coin_type": "runes",
    "tick1": "BTC"
}
```

{% endtab %}

{% tab title="cURL Example" %}

```sh
curl 'https://test-api-proxy.ddpurse.com/brc20swap/search_ticks' \
  -H 'Accept: application/json, text/plain, */*' \
  -H 'Accept-Language: en' \
  -H 'Cache-Control: no-cache' \
  -H 'Connection: keep-alive' \
  -H 'Content-Type: application/json' \
  -H 'Origin: http://localhost:56651' \
  -H 'Pragma: no-cache' \
  -H 'Referer: http://localhost:56651/' \
  -H 'Sec-Fetch-Dest: empty' \
  -H 'Sec-Fetch-Mode: cors' \
  -H 'Sec-Fetch-Site: cross-site' \
  -H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36' \
  -H 'sec-ch-ua: "Not_A Brand";v="8", "Chromium";v="120", "Google Chrome";v="120"' \
  -H 'sec-ch-ua-mobile: ?0' \
  -H 'sec-ch-ua-platform: "macOS"' \
  --data-raw '{"page":1,"page_size":30,"keyword":"","usetype":"gettick2","coin_type":"runes","tick1":"BTC"}' \
  --compressed
```

{% endtab %}
{% endtabs %}

#### Adding Liquidity

Used to get the list of all tokens available for adding liquidity.

* **usetype:** Use `liquid`.

**Example**

{% tabs %}
{% tab title="Request Body" %}

```json
{
    "page": 1,
    "page_size": 30,
    "keyword": "", 
    "address": "",
    "usetype": "liquid",  
    "coin_type": "runes"
}
```

{% endtab %}

{% tab title="cURL Example" %}

```sh
curl 'https://test-api-proxy.ddpurse.com/brc20swap/search_ticks' \
  -H 'Accept: application/json, text/plain, */*' \
  -H 'Accept-Language: en' \
  -H 'Cache-Control: no-cache' \
  -H 'Connection: keep-alive' \
  -H 'Content-Type: application/json' \
  -H 'Origin: http://192.168.10.66:56651' \
  -H 'Pragma: no-cache' \
  -H 'Referer: http://192.168.10.66:56651/' \
  -H 'Sec-Fetch-Dest: empty' \
  -H 'Sec-Fetch-Mode: cors' \
  -H 'Sec-Fetch-Site: cross-site' \
  -H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/121.0.0.0 Safari/537.36' \
  -H 'sec-ch-ua: "Not A(Brand";v="99", "Google Chrome";v="121", "Chromium";v="121"' \
  -H 'sec-ch-ua-mobile: ?0' \
  -H 'sec-ch-ua-platform: "macOS"' \
  --data-raw '{"page":1,"page_size":30,"keyword":"","usetype":"liquid","coin_type":"runes"}' \
  --compressed
```

{% endtab %}
{% endtabs %}

## Important Notes:

{% hint style="info" %}
The query interface for RUNES, BRC20, and ARC20 is the same; only the `coin_type` is different.
{% endhint %}
