签名算法
- 请求参数中除去sign和空值参数外,其他参数按字典序排序.
- 排序完成后,按照”key1value1key2value2…”进行拼接
- 将项目的API Key拼接到第 2 步中得到的字符串最前面
- 将第 3 步中获取的字符串使用散列算法取md5并转为小写即为sign,将sign添加到请求参数中
签名示例
步骤 1 假设项目API Key 为:
Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
API Key 为:
f502a9ac9ca54327986f29c03b271491
{
"pid": 1382528827416576,
"currency": "195@195",
"address": "TXsmKpEuW7qWnXzJLGP9eDLvWPR2GRn1FS",
"amount": "1.1",
"remark": "payout",
"third_party_id": "c9231e604da54469a735af3f449c880f",
"callback_url": "http://192.168.2.29:9099/callback",
"nonce": "hwlkk6",
"timestamp": 1688004243314
}
addressTXsmKpEuW7qWnXzJLGP9eDLvWPR2GRn1FSamount1.1callback_urlhttp://192.168.2.29:9099/callbackcurrency195@195noncehwlkk6pid1382528827416576remarkpayoutthird_party_idc9231e604da54469a735af3f449c880ftimestamp1688004243314
f502a9ac9ca54327986f29c03b271491addressTXsmKpEuW7qWnXzJLGP9eDLvWPR2GRn1FSamount1.1callback_urlhttp://192.168.2.29:9099/callbackcurrency195@195noncehwlkk6pid1382528827416576remarkpayoutthird_party_idc9231e604da54469a735af3f449c880ftimestamp1688004243314
c9bae061ae3f5f8d3bfde817f6966c36
{
"pid": 1382528827416576,
"currency": "195@195",
"address": "TXsmKpEuW7qWnXzJLGP9eDLvWPR2GRn1FS",
"amount": "1.1",
"remark": "payout",
"third_party_id": "c9231e604da54469a735af3f449c880f",
"callback_url": "http://192.168.2.29:9099/callback",
"nonce": "hwlkk6",
"timestamp": 1688004243314,
"sign": "d6eef2de79e39f434a38efb910213ba6"
}
