> For the complete documentation index, see [llms.txt](https://platformv2docs.chainup.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://platformv2docs.chainup.com/qian-bao.md).

# 钱包

#### 钱包地址映射关系

## 钱包地址映射关系

<mark style="color:green;">`POST`</mark> `https://service.xxx.com/platformapi/chainup/open/wallet/addressMapping`

#### Query Parameters

| Name                                         | Type   | Description                                       |
| -------------------------------------------- | ------ | ------------------------------------------------- |
| walletType<mark style="color:red;">\*</mark> | number | 钱包类型（1 custody 2 wapi 3 fireblocks 4 custody mpc） |
| symbol<mark style="color:red;">\*</mark>     | String | chainup币种名称                                       |
| uid                                          | number | uid (非必填)                                         |
| page<mark style="color:red;">\*</mark>       | number | 分页参数（页码）                                          |
| pageSize<mark style="color:red;">\*</mark>   | number | 分页参数（每页大小）                                        |

#### Headers

| Name         | Type   | Description      |
| ------------ | ------ | ---------------- |
| Content-type | String | application/json |

#### Request Body

| Name                                      | Type   | Description |
| ----------------------------------------- | ------ | ----------- |
| app\_id<mark style="color:red;">\*</mark> | String | 商家唯一app\_id |
| time<mark style="color:red;">\*</mark>    | String | 请求时间        |
| sign<mark style="color:red;">\*</mark>    | String | 签名          |
| data<mark style="color:red;">\*</mark>    | String | 加密字符串       |

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

```json
{
    "code": "", //返回code	
    "msg": "", //成功或失败提示信息	
    "data": "",
    "sign": ""
}

data 中解密后的结构体

{
    "count":50, // total record number
    "page":1, // Paging parameters (page number)
    "pageSize":2, // Paging parameters (page size)
    "symbol":"BTCTEST1760", // chainup symbol
    "walletSymbol":"BTC_TEST", //wallet symbol 
    "list":[
      {
        "address":"1K1zD7ypt6oiXH4z54NoohddEV7JwQKCEo", // user deposit address
        "tag":"4567", // tag
        "uid":1234, // chainup uid
        "walletUid":2 // wallet uid or fireblocks vault id
      },
      {
        "address":"1K1zD7ypt6oiXH4z54Noo", // user deposit address
        "tag":"4567", // tag
        "uid":4567, // chainup uid
        "walletUid":3 // wallet uid or fireblocks vault id
      }
    ]
}
```

{% endtab %}
{% endtabs %}

#### 钱包币种映射

## 钱包币种映射

<mark style="color:green;">`POST`</mark> `https://service.xxx.com/platformapi/chainup/open/wallet/symbolMapping`

#### Query Parameters

| Name                                          | Type   | Description                                       |
| --------------------------------------------- | ------ | ------------------------------------------------- |
| walletType	<mark style="color:red;">\*</mark> | number | 钱包类型（1 custody 2 wapi 3 fireblocks 4 custody mpc） |
| symbol                                        | String | chainup币种名称(非必填)                                  |
| walletSymbol                                  | String | 钱包币种名称(非必填)                                       |
| page<mark style="color:red;">\*</mark>        | number | 分页参数（页码）                                          |
| pageSize<mark style="color:red;">\*</mark>    | number | 分页参数（每页大小）                                        |

#### Headers

| Name         | Type   | Description      |
| ------------ | ------ | ---------------- |
| Content-type | String | application/json |

#### Request Body

| Name                                      | Type   | Description |
| ----------------------------------------- | ------ | ----------- |
| app\_id<mark style="color:red;">\*</mark> | String | 商家唯一app\_id |
| time<mark style="color:red;">\*</mark>    | String | 请求时间        |
| sign<mark style="color:red;">\*</mark>    | String | 签名          |
| data<mark style="color:red;">\*</mark>    | String | 加密字符串       |

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

```json
{
    "code": "", //返回code	
    "msg": "", //成功或失败提示信息	
    "data": "",
    "sign": ""
}

data 中解密后的结构体

{
    "count":50, // total record number
    "page":1, // Paging parameters (page number)
    "pageSize":2, // Paging parameters (page size)
    "walletType":3 //1 custody 2 wapi 3 fireblocks 4 custody mpc
    "list":[
      {
        "symbol":"BTCTEST1760", // chainup symbol name
        "walletSymbol":"BTC_TEST" // wallet symbol name
      },
      {
        "symbol":"ETHTEST1760", // chainup symbol name
        "walletSymbol":"ETH_TEST5" // wallet symbol name
      }
    ]
}
```

{% endtab %}
{% endtabs %}

#### 公司资产

## 公司资产

<mark style="color:green;">`POST`</mark> `https://service.xxx.com/platformapi/chainup/open/wallet/companyAsset`

#### Query Parameters

| Name                                     | Type   | Description |
| ---------------------------------------- | ------ | ----------- |
| symbol<mark style="color:red;">\*</mark> | String | chainup币种名称 |

#### Headers

| Name         | Type   | Description      |
| ------------ | ------ | ---------------- |
| Content-Type | String | application/json |

#### Request Body

| Name                                      | Type   | Description |
| ----------------------------------------- | ------ | ----------- |
| app\_id<mark style="color:red;">\*</mark> | String | 商家唯一app\_id |
| time<mark style="color:red;">\*</mark>    | String | 请求时间        |
| sign<mark style="color:red;">\*</mark>    | String | 签名          |
| data<mark style="color:red;">\*</mark>    | String | 加密字符串       |

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

```json
{
    "code": "", //返回code	
    "msg": "", //成功或失败提示信息	
    "data": "",
    "sign": ""
}

data 中解密后的结构体

{
    "accounts":[
      {
        "companyId": 1760, // company id
        "balance": "1000", // account balance
        "type": "113"  // account type,see the table below for a detailed description
      },
      {
        "companyId": 1760, // company id
        "balance": "1000", // account balance
        "type": "112" // account type,see the table below for a detailed description
      }
    ]
}
```

{% endtab %}
{% endtabs %}

#### 公司资产type描述

| type | description                |
| ---- | -------------------------- |
| 113  | 公司:管理员充值账户                 |
| 112  | 公司:赠币账户                    |
| 105  | 公司:提币手续费收入&矿工费支出账户         |
| 114  | 公司:分红币返还账户                 |
| 116  | 公司:锁仓账户                    |
| 130  | 公司:锁仓代币发放（释放到用户锁仓账户）V2     |
| 121  | 公司:IEO收入账户（募集收入）           |
| 122  | 公司:IEO支出账户（释放到用户可用账户）      |
| 181  | 公司:（Spot\&Margin）交易手续费收入账户 |
| 187  | 公司:C2C交易手续费收入账户            |
| 118  | 公司:（现货 & 合约）经纪人奖励账户        |
| 115  | 公司:分红币分红账户                 |
| 149  | 公司:合约赠金支出/回收账户             |
| 150  | 公司:理财发币账户                  |
| 152  | 邀请注册奖励账户                   |
| 153  | 公司：抵押借贷利息分成账户              |

#### 币币与合约划转记录

## 币币与合约划转记录

<mark style="color:green;">`POST`</mark> `https://service.xxx.com/platformapi/chainup/open/wallet/futuresTransferRecord`

#### Query Parameters

| Name                                       | Type   | Description      |
| ------------------------------------------ | ------ | ---------------- |
| symbol                                     | String | chainup币种名称(非必填) |
| uid                                        | number | uid(非必填)         |
| page<mark style="color:red;">\*</mark>     | number | 分页参数（页码）         |
| pageSize<mark style="color:red;">\*</mark> | number | 分页参数（每页大小）       |

#### Headers

| Name         | Type   | Description      |
| ------------ | ------ | ---------------- |
| Content-Type | String | application/json |

#### Request Body

| Name                                      | Type   | Description |
| ----------------------------------------- | ------ | ----------- |
| app\_id<mark style="color:red;">\*</mark> | String | 商家唯一app\_id |
| time<mark style="color:red;">\*</mark>    | String | 请求时间        |
| sign<mark style="color:red;">\*</mark>    | String | 签名          |
| data<mark style="color:red;">\*</mark>    | String | 加密字符串       |

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

```json
{
    "code": "", //返回code	
    "msg": "", //成功或失败提示信息	
    "data": "",
    "sign": ""
}

data 中解密后的结构体

{
    "count":50, // total record number
    "page":1, // Paging parameters (page number)
    "pageSize":2, // Paging parameters (page size)
    "list":[
      {
        "uid":12345,
        "symbol":"USDT1760", // chainup symbol name
        "transferType":"contract_to_wallet", // Fixed value: contract_to_wallet(Transfer the contract to currency)、wallet_to_contract（Currency transfer to the contract）
        "transferTime":1691388963422, // transfer time
        "amount":"1000"
      },
      {
        "uid":12345,
        "symbol":"USDT1760", // chainup symbol name
        "transferType":"wallet_to_contract", // Fixed value: contract_to_wallet(Transfer the contract to currency)、wallet_to_contract（Currency transfer to the contract）
        "transferTime":1691388963966, // transfer time
        "amount":"500"
      }
    ]
}
```

{% endtab %}
{% endtabs %}
