用户积分汇总
返回当前登录用户在指定 Epoch 内的积分汇总信息。
GET /points
Authorization: Bearer <token>
别名:GET /points/balance,GET /points/summary
Query 参数
| 参数 | 类型 | 必填 | 说明 |
|---|---|---|---|
epoch | integer | 否 | Epoch 编号;默认当前进行中 Epoch |
响应
{
"success": true,
"data": {
"user_address": "0xAbCd...1234",
"epoch_number": 3,
"epoch_status": "active",
"trading_points": "1250.50",
"pnl_points": "340.20",
"holding_points": "85.00",
"referral_points": "20.00",
"referral_code": "AXBLADE2026",
"staking_points": "0.00",
"total_points": "1695.70",
"tier": "T2",
"tier_multiplier": "1.5",
"earn_level": 1,
"earn_level_weight": 8,
"earn_level_points_to_next": "8304.30",
"rank": 142,
"trading_volume": "2500000.00",
"trade_count": 47,
"referral_count": 2,
"updated_at": "2026-04-15T12:30:00Z"
},
"error": null,
"timestamp": 1745280000
}
新用户所有积分字段返回 "0.00",rank 为 null。下方字段表描述的是 data 载荷。
响应字段
| 字段 | 类型 | 说 明 |
|---|---|---|
user_address | string | 用户钱包地址 |
epoch_number | int | 数据所属 Epoch |
epoch_status | string | Epoch 状态(pending / active / ended / settled) |
trading_points | Decimal | 本 Epoch 交易积分(TP) |
pnl_points | Decimal | 本 Epoch PnL 积分(PP) |
holding_points | Decimal | 本 Epoch 持仓积分(HP) |
referral_points | Decimal | 本 Epoch 推荐积分(RP) |
referral_code | string | null | 用户推荐码;未创建则为 null |
staking_points | Decimal | 本 Epoch 质押积分(SP) |
total_points | Decimal | 各类积分之和 |
tier | string | 当前 Tier:T1 / T2 / T3 |
tier_multiplier | string | Tier 费率倍率 |
earn_level | int | 当前 Earn Level(0–5) |
earn_level_weight | int | 当前等级的 Earn 申购配额权重(不参与代币分配) |
earn_level_points_to_next | Decimal | 距下一等级所需积分;L5 时为 "0.00" |
rank | int | null | 本 Epoch 排名;未上榜则为 null |
trading_volume | Decimal | 本 Epoch 总交易量(USD) |
trade_count | int | 本 Epoch 成交笔数 |
referral_count | int | 推荐人数 |
updated_at | string | 最后更新时间(ISO 8601) |
代码示例
Python
import requests
BASE_URL = "https://api.prex.world/api/v1"
JWT_TOKEN = "your_jwt_token"
resp = requests.get(
f"{BASE_URL}/points",
headers={"Authorization": f"Bearer {JWT_TOKEN}"},
)
data = resp.json()["data"]
print(f"总积分: {data['total_points']}(Epoch {data['epoch_number']})")
print(f"Tier: {data['tier']}(×{data['tier_multiplier']}),Earn Level: L{data['earn_level']}")
print(f"排名: {data['rank']}")