签名步骤
步骤1:获取AppKey和AppSecret
联系东篱获取 AppKey 和 AppSecret(32位小写字母和数字组合)
步骤2:生成鉴权信息
先用AppKey + AppSecret + 当前 Unix 时间戳(秒),得到一个用来签名的字符串,然后MD5(上一步的字符串)
举例:
假如AppKey为 12345678,AppSecret为 58b176c5d9324f1db003aad4e9fbfa38, 当前 Unix 时间戳(秒)为 1691651505
。
那么拼接后的字符串为: 1234567858b176c5d9324f1db003aad4e9fbfa381691651505
,
对它进行MD5后的值为:8e66f89e0486e95be5448a3eb58dd7a5
使用签名
- 调用东篱 HTTP 接口时,在 HTTP 请求头中加入:
Sign: 上一步生成的MD5字符串
App-Key: 东篱给到的AppKey
Timestamp: 当前 Unix 时间戳(秒)
例如:
Sign: 8e66f89e0486e95be5448a3eb58dd7a5
App-Key: 12345678
Timestamp: 1691651505
- 东篱回调您的接口时,也是一样:
Authorization: 上一步生成的MD5字符串
作者:admin 创建时间:2023-08-10 15:17
最后编辑:Lin 更新时间:2025-01-23 09:40
最后编辑:Lin 更新时间:2025-01-23 09:40