From 3414f6e6219f0110fe38edeeec8ae4a240ff8fd5 Mon Sep 17 00:00:00 2001
From: Anyon <zoujingli@qq.com>
Date: Wed, 7 Mar 2018 17:42:18 +0800
Subject: [PATCH] =?UTF-8?q?[=E6=9B=B4=E6=96=B0]=E5=A2=9E=E5=8A=A0=E5=BE=AE?=
 =?UTF-8?q?=E4=BF=A1=E7=B2=89=E4=B8=9D=E6=A0=87=E7=AD=BE=E6=9B=B4=E6=96=B0?=
 =?UTF-8?q?=E6=8E=A5=E5=8F=A3?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

---
 WeChat/Tags.php | 15 +++++++++++++++
 1 file changed, 15 insertions(+)

diff --git a/WeChat/Tags.php b/WeChat/Tags.php
index 82e7e40..db26acf 100644
--- a/WeChat/Tags.php
+++ b/WeChat/Tags.php
@@ -49,6 +49,21 @@ class Tags extends BasicWeChat
         return $this->httpPostForJson($url, ['tag' => ['name' => $name]]);
     }
 
+    /**
+     * 更新粉丝标签
+     * @param integer $id 标签ID
+     * @param string $name 标签名称
+     * @return array
+     * @throws Exceptions\InvalidResponseException
+     * @throws Exceptions\LocalCacheException
+     */
+    public function updateTags($id, $name)
+    {
+        $url = "https://api.weixin.qq.com/cgi-bin/tags/update?access_token=ACCESS_TOKEN";
+        $this->registerApi($url, __FUNCTION__, func_get_args());
+        return $this->httpPostForJson($url, ['tag' => ['name' => $name, 'id' => $id]]);
+    }
+
     /**
      * 删除粉丝标签
      * @param int $tagId