跳到主要内容

用户充币

1、分配充币地址

HTTP 请求:

http://wallet.unn.com:8080/v2/user/create

请求方式:POST

Header

参数类型必选说明
tokenstringtrueAccess Token

请求参数

参数类型必选说明
user_idstringtrue商家系统内的用户 ID
namestringfalse昵称

请求示例

curl --location 'http://wallet.unn.com:8080/v2/user/create' \
--header 'token: service.eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoiMHg1QjgzYTI2N2I2QjhCZTRiRTZEOWFmMWMxZGQxOUMzNEZCMjY0MUIwIiwiZW50ZXJwcmlzZV9saXN0IjpbeyJjaGFpbiI6IkVSQzIwIiwiY29udHJhY3RfYWRkciI6IjB4RTU4MzExYjIxMGY0RUI1N2QzQmU2MTk0NkNlRTMzZUNhODc5M2NGMCIsImVudGVycHJpc2UiOiI2NGNlMGNiMjFiOWIwNDE5Y2VlMWRkNTgiLCJpc19vd25lciI6dHJ1ZSwicGVybWlzc2lvbiI6WzAsMSwyLDNdfSx7ImNoYWluIjoiVFJDMjAiLCJjb250cmFjdF9hZGRyIjoiVEVWUktYb05xcWk3UkJEYkY0TXplVDNwUHVpc1hCaXpBdSIsImVudGVycHJpc2UiOiI2NGNlMGNiMjFiOWIwNDE5Y2VlMWRkNTgiLCJpc19vd25lciI6dHJ1ZSwicGVybWlzc2lvbiI6WzAsMSwyLDNdfV0sImNyZWF0ZVRpbWUiOjE2OTIzNDE4ODIsImV4cCI6MTY5NDkzMzg4MiwiYWNjb3VudF9uYW1lIjoiIn0.ix213o6Azf2rGTmTiLX98BYEn-Ngme9P4LYrO3-zNQs' \
--header 'Content-Type: application/json' \
--data '{
"body": {
"user_id": "T1692343087",
"name": "Arthur02"
}
}'

返回参数

参数类型必选说明
merchant_idstringtrue商户ID
user_idstringtrue用户ID
namestringtrue用户昵称
descstringtrue描述
addressstringtrue用户充币地址

返回示例

{
"code": 200,
"message": "success",
"data": {
"entity": {
"merchant_id": "64f2974b8dd894bc6115e260",
"user_id": "T1692343087",
"name": "Arthur02",
"desc": "",
"address": {
"ERC20": "0xdd07371E0930ac4B60d103A3ce7B6D9509F39Dad",
"TRC20": "TYTUmbXev4qBpM2JeNkwAwkL3HE8h29Rvr"
},
"index": 6,
"in_used": true,
"create_time": 1695621744,
"update_time": 1695621744,
"id": "65112270467ce9af683bd8c7"
}
}
}

2、查询充币地址

请求 URL:

http://wallet.unn.com:8080/v2/order/deposit/{UserId}

UserId 为调用方系统的用户 ID

请求方式:GET

Header

参数类型必选说明
tokenstringtrueAccess Token

请求范例

curl --location 'http://43.198.64.79:30105/v2/order/deposit/test0011' \
--header 'token: service.eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX2lkIjoiMHg1MkM1NDBFZDdBMTk4ZTQ4QjU3RjYwYTc5MWFhRTgzYTVBMmIwNjNFIiwiZW50ZXJwcmlzZV9saXN0IjpbeyJjaGFpbiI6IkVSQzIwIiwiY29udHJhY3RfYWRkciI6IjB4NDU3ODU3MDEzQTkyMEQ3QzM3OWZjRTkwMjhmRmM2NzhDZUM4MUQ2OCIsImVudGVycHJpc2UiOiI2NGM3NGI2OTgwYTU4NjIwOThhZTIzMDEiLCJpc19vd25lciI6dHJ1ZSwicGVybWlzc2lvbiI6WzAsMSwyLDNdfV0sImNyZWF0ZVRpbWUiOjE2OTA3ODUyNzAsImV4cCI6MTY5MzM3NzI3MCwiYWNjb3VudF9uYW1lIjoiIn0.GSM0vsDjrgW1ZQzG2AQUWVQKA0UmtJynrG6sDePxbQo'

返回参数

参数类型必选说明
addressdicttrue地址
—ERC20stringtrueEth 地址
—TRC20stringtrueTron 地址

返回示例

{
"code": 200,
"message": "success",
"data": {
"entity": {
"address": {
"ERC20": "0x9E572A5e1012359365ab07A70Ff94aCdf9a2460c",
"TRC20": "TFwgcKZPn3WfmAHb6vtaL261DNFKCrU7Vf"
}
}
}
}