From 3aaf9679c51eec05c28fe505cd26238e6c2ac303 Mon Sep 17 00:00:00 2001 From: ywmoyue Date: Wed, 21 Jun 2023 08:39:47 +0800 Subject: [PATCH] =?UTF-8?q?=E8=A1=A5=E5=85=85wbi=E6=96=87=E6=A1=A3=20(#706?= =?UTF-8?q?)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * 添加评论条目中图片数据说明 * wbi文档补充提示 * 修复代码格式 --- docs/misc/sign/wbi.md | 23 ++++++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) diff --git a/docs/misc/sign/wbi.md b/docs/misc/sign/wbi.md index 15e969f..aa11a05 100644 --- a/docs/misc/sign/wbi.md +++ b/docs/misc/sign/wbi.md @@ -49,9 +49,9 @@ ```javascript { - foo: '114', - bar: '514', - baz: 1919810 + foo: '114', + bar: '514', + baz: 1919810 } ``` @@ -61,6 +61,23 @@ bar=514&baz=1919810&foo=114 ``` + 请注意,如果参数值为中文或特殊字符,则进行 url query 编码后的字符串中参数值对应的字母必须是**大写字母** (部分库会编码为小写字母) + + 例如 + ```javascript + { + foo: 'one one four', + bar: '五一四', + baz: 1919810 + } + ``` + + 应该被编码为 + + ``` + bar=%E4%BA%94%E4%B8%80%E5%9B%9B&baz=1919810&foo=one%20one%20four + ``` + 4. 为参数中添加`wts`时间戳 `wts`字段的值应为以秒为单位的 Unix TimeStamp,如`1684746387`