From cf528fb4995d3bf042cccb15a3cc6560fd66e0c3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B5=84=E6=BA=90=E6=98=9F=E7=90=83?= Date: Thu, 28 Mar 2024 13:44:45 +0800 Subject: [PATCH 1/2] Update client.go MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 修正参数类型:公众号发布文章API接口返回的PublishId参数实际为数字型 --- src/officialAccount/publish/client.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/officialAccount/publish/client.go b/src/officialAccount/publish/client.go index 3fcc5c3b..9943a16f 100644 --- a/src/officialAccount/publish/client.go +++ b/src/officialAccount/publish/client.go @@ -122,7 +122,7 @@ func (comp *Client) PublishSubmit(ctx context.Context, mediaID string) (*respons // 发布状态轮询接口 // https://developers.weixin.qq.com/doc/offiaccount/Publish/Get_status.html -func (comp *Client) PublishGet(ctx context.Context, publishID string) (*response.ResponsePublishGet, error) { +func (comp *Client) PublishGet(ctx context.Context, publishID uint64) (*response.ResponsePublishGet, error) { result := &response.ResponsePublishGet{} _, err := comp.BaseClient.HttpPostJson(ctx, "cgi-bin/freepublish/get", &object.HashMap{ From 993d2552aa4b902b60f4bafa62c9befbae85c920 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B5=84=E6=BA=90=E6=98=9F=E7=90=83?= Date: Thu, 28 Mar 2024 13:45:27 +0800 Subject: [PATCH 2/2] Update responsePublish.go MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 修正参数类型:公众号发布文章API接口返回的PublishId参数实际为数字型 --- src/officialAccount/publish/response/responsePublish.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/officialAccount/publish/response/responsePublish.go b/src/officialAccount/publish/response/responsePublish.go index a26e8361..754be7e2 100644 --- a/src/officialAccount/publish/response/responsePublish.go +++ b/src/officialAccount/publish/response/responsePublish.go @@ -5,7 +5,7 @@ import "github.com/ArtisanCloud/PowerWeChat/v3/src/kernel/response" type ResponsePublishSubmit struct { response.ResponseOfficialAccount - PublishId string `json:"publish_id"` + PublishId uint64 `json:"publish_id"` } type ArticleItem struct { @@ -21,7 +21,7 @@ type ArticleDetail struct { type ResponsePublishGet struct { response.ResponseOfficialAccount - PublishId string `json:"publish_id"` + PublishId uint64 `json:"publish_id"` PublishStatus int `json:"publish_status"` ArticleId interface{} `json:"article_id"` ArticleDetail *ArticleDetail `json:"article_detail"`