From 5ecf569bd47076ee8de9b1822b710f4c2994acfa Mon Sep 17 00:00:00 2001 From: YIHONG LIU Date: Tue, 29 Jun 2021 17:27:21 +0800 Subject: [PATCH 1/2] Update README.md MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 更改了python使用文档说明,企业的wecom_cid,wecom_aid参数顺序错误 --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 2df5184..4e8e729 100644 --- a/README.md +++ b/README.md @@ -113,7 +113,7 @@ PYTHON版: ```python import json,requests -def send_to_wecom(text,wecom_cid,wecom_secret,wecom_aid,wecom_touid='@all'): +def send_to_wecom(text,wecom_cid,wecom_aid,wecom_secret,wecom_touid='@all'): get_token_url = f"https://qyapi.weixin.qq.com/cgi-bin/gettoken?corpid={wecom_cid}&corpsecret={wecom_secret}" response = requests.get(get_token_url).content access_token = json.loads(response).get('access_token') From e3281514cdd0c3dddc45def4288d0bc753754d9a Mon Sep 17 00:00:00 2001 From: Easy Date: Tue, 29 Jun 2021 22:45:54 +0800 Subject: [PATCH 2/2] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 4e8e729..5b46477 100644 --- a/README.md +++ b/README.md @@ -67,7 +67,7 @@ PS:为使用方便,以下函数没有对 `access_token` 进行缓存。对 PHP版: ```php -function send_to_wecom($text, $wecom_cid, $wecom_secret, $wecom_aid, $wecom_touid = '@all') +function send_to_wecom($text, $wecom_cid, $wecom_aid, $wecom_secret, $wecom_touid = '@all') { $info = @json_decode(file_get_contents("https://qyapi.weixin.qq.com/cgi-bin/gettoken?corpid=".urlencode($wecom_cid)."&corpsecret=".urlencode($wecom_secret)), true);