# Token

## Tokens

<mark style="color:green;">`GET`</mark> `/tokens`

Get Inscription Tokens list.

**Headers**

| Name         | Value              |
| ------------ | ------------------ |
| Content-Type | `application/json` |

**Request**

<table><thead><tr><th>Name</th><th>Type</th><th>Description</th><th data-type="checkbox">Optional</th></tr></thead><tbody><tr><td><code>order_by</code></td><td>string, values: (holders)</td><td>Sort</td><td>true</td></tr><tr><td><code>mint_finished</code></td><td>bool</td><td>Mint finished filter</td><td>true</td></tr><tr><td>page</td><td>number</td><td>page number</td><td>true</td></tr></tbody></table>

**Response**

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

```json
{
    "data": [
        {
            "blocknumber": "9931503",
            "from": "0x282e803c107fe517cf65f689afabdf84be8be3cd",
            "holders": "46881",
            "insc_id": 1,
            "market_cap": "651859250000000146472960",
            "market_floor_price": "8000000000000",
            "market_txs24h": "12",
            "market_volume24h": "52386238",
            "mint_finished": true,
            "mint_limit": "1000",
            "mint_max": "21000000000",
            "mint_progress": "21000608000",
            "tick": "test",
            "tick_i": "test",
            "timestamp": "1703093221",
            "tx": "0x0739e5e2a5cfd77711173683daf5d0bcbe529178af6996c5b784dfef0b98a12b"            
        },{
            ...
        },
        ...
    ],
    "error_code": 0
}
```

{% endtab %}
{% endtabs %}

## Token Info

<mark style="color:green;">`GET`</mark> `/token_info`

Get specific token info.

**Headers**

| Name         | Value              |
| ------------ | ------------------ |
| Content-Type | `application/json` |

**Body**

| Name   | Type   | Description     |
| ------ | ------ | --------------- |
| `tick` | string | Ticker of token |

**Response**

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

```json
{
    "data": {
            "blocknumber": "9931503",
            "from": "0x282e803c107fe517cf65f689afabdf84be8be3cd",
            "holders": "46881",
            "insc_id": 1,
            "market_cap": "651859250000000146472960",
            "market_floor_price": "8000000000000",
            "market_txs24h": "12",
            "market_volume24h": "52386238",
            "mint_finished": true,
            "mint_limit": "1000",
            "mint_max": "21000000000",
            "mint_progress": "21000608000",
            "tick": "test",
            "tick_i": "test",
            "timestamp": "1703093221",
            "tx": "0x0739e5e2a5cfd77711173683daf5d0bcbe529178af6996c5b784dfef0b98a12b"            
    },
    "error_code": 0
}
```

{% endtab %}
{% endtabs %}

## Token Holders

<mark style="color:green;">`GET`</mark> `/token_holders`

Get holders list of specific token.

**Headers**

| Name         | Value              |
| ------------ | ------------------ |
| Content-Type | `application/json` |

**Request**

| Name   | Type   | Description     |
| ------ | ------ | --------------- |
| `tick` | string | ticker of token |
| `page` | number | page number     |

**Response**

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

```json
{
    "data": [
        {
            "address": "0xa8ab79a4172713e2d77e31ad9594c72483299bfe",
            "balance": 100000
        }, {
            "address": "0x69937007ed6bd79236abc0f57827897cd4f62997",
            "balance": 500
        },{
            ...
        },
        ...
    ],
    "error_code": 0
}
```

{% endtab %}
{% endtabs %}

## Token Balance

<mark style="color:green;">`GET`</mark> `/token_balance`

Get token balances of specific address.

**Headers**

| Name         | Value              |
| ------------ | ------------------ |
| Content-Type | `application/json` |

**Request**

| Name      | Type   | Description    |
| --------- | ------ | -------------- |
| `address` | string | Wallet address |

**Response**

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

```json
{
    "data": [
        {
            "balance": 30000000,
            "tick": "token1"
        },
        {
            "balance": 20000000,
            "tick": "token2"
        },
        ...
    ],
    "error_code": 0
}
```

{% endtab %}
{% endtabs %}

## Token Transactions

<mark style="color:green;">`GET`</mark> `/token_txs`

Get transfers tx of specific token.

**Headers**

| Name         | Value              |
| ------------ | ------------------ |
| Content-Type | `application/json` |

**Request**

| Name   | Type   | Description     |
| ------ | ------ | --------------- |
| `tick` | string | ticker of token |
| `page` | number | page number     |

**Response**

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

```json
{
    "data": [
        {
            "blocknumber": 12140171,
            "event_logs": [
                {
                    "address": "0xa8ab79a4172713e2d77e31ad9594c72483299bfe",
                    "blockHash": "0x1dd2b4c4163f300692a381ab575afd05a539f3f27069920511c74adc26884e37",
                    "blockNumber": "0xb93e8b",
                    "data": "0x0000000000000000000000003df5f3f03a0c35576c89915f15865d87e71771c653deaccf190c75f1e480542435e27a4fd446f12407cf62421af5a087c7d85ac8",
                    "logIndex": "0x1",
                    "logType": null,
                    "removed": false,
                    "topics": [
                        "0x7b568d13cd8dc699e62a140da890282e39b5ff92542a839fb4980aaac13b2025"
                    ],
                    "transactionHash": "0xeda9cae47db05bfa0fcbad1c9c9b36734d5bdf9b8e2b9c0d7744a60e9d67da86",
                    "transactionIndex": "0x1",
                    "transactionLogIndex": null
                }
            ],
            "from": "0x3df5f3f03a0c35576c89915f15865d87e71771c6",
            "id": 83723760,
            "market_order_id": "0x53deaccf190c75f1e480542435e27a4fd446f12407cf62421af5a087c7d85ac8",
            "mime_category": "4",
            "mime_data": "{\"p\":\"core-20\",\"op\":\"market_list\",\"sand\": \"1709720464217\", \"tick\":\"coco\",\"amt\":\"2000200\"}",
            "mime_type": "",
            "timestamp": 1709720470,
            "to": "0xa8ab79a4172713e2d77e31ad9594c72483299bfe",
            "tx_hash": "0xeda9cae47db05bfa0fcbad1c9c9b36734d5bdf9b8e2b9c0d7744a60e9d67da86",
            "tx_index": 1,
            "verified": "1"
        },
        {
            "blocknumber": 12140167,
            "event_logs": [
                {
                    "address": "0xa8ab79a4172713e2d77e31ad9594c72483299bfe",
                    "blockHash": "0x3c2ce8646f69992d655c236a09c439be7911e6308fc9dba4b1514b61bb7186ff",
                    "blockNumber": "0xb93e87",
                    "data": "0x000000000000000000000000951c42c59679dc6b769b1620a3922fa24023fcbb1bb570f7b0e7d1d7137d9668effb4598f84992fe68114dc04f2f258d3fb5dffc",
                    "logIndex": "0x6",
                    "logType": null,
                    "removed": false,
                    "topics": [
                        "0x7b568d13cd8dc699e62a140da890282e39b5ff92542a839fb4980aaac13b2025"
                    ],
                    "transactionHash": "0xfcf9711fa9f1b8b5940e4038c2b341c2a07f21870e5eb599282bc04bd7289f6e",
                    "transactionIndex": "0x1",
                    "transactionLogIndex": null
                }
            ],
            "from": "0x951c42c59679dc6b769b1620a3922fa24023fcbb",
            "id": 83723758,
            "market_order_id": "0x1bb570f7b0e7d1d7137d9668effb4598f84992fe68114dc04f2f258d3fb5dffc",
            "mime_category": "4",
            "mime_data": "{\"p\":\"core-20\",\"op\":\"market_list\",\"sand\": \"1709720448044\", \"tick\":\"coco\",\"amt\":\"2600000\"}",
            "mime_type": "",
            "timestamp": 1709720458,
            "to": "0xa8ab79a4172713e2d77e31ad9594c72483299bfe",
            "tx_hash": "0xfcf9711fa9f1b8b5940e4038c2b341c2a07f21870e5eb599282bc04bd7289f6e",
            "tx_index": 1,
            "verified": "1"
        },
        ...
    ],
    "error_code": 0
}
```

{% endtab %}
{% endtabs %}
