This commit is contained in:
邹宗楠
2026-05-13 10:04:33 +08:00
parent e5ed37fd49
commit adeb6575cb
4 changed files with 9 additions and 2 deletions

View File

@@ -3,7 +3,6 @@ package weixinapi
import (
"bytes"
"fmt"
"git.rosy.net.cn/jx-callback/globals"
"math/rand"
"mime/multipart"
"net/http"
@@ -90,7 +89,6 @@ func (a *API) AccessAPI(action string, params map[string]interface{}, body strin
if accessToken == "" {
panic("token is empty!")
}
globals.SugarLogger.Debugf("-------token := %s, action := %s", accessToken, action)
params2["access_token"] = accessToken
}
fullURL := utils.GenerateGetURL(prodURL, action, params2)

View File

@@ -5,6 +5,7 @@ import (
)
func TestGetUnlimited(t *testing.T) {
api.CBSetToken("103_WpV0UHqL-2svlix1nc_3LOkRmlrlvaWy-B5ZBRkAtNZ5TwyYRcwIB3BBWfIVCaccl3bSSNlA7yet9VPfOrIaxQfGugNSZRPmagxyb4H4j2MjYYQt7CakU9H8zT0LHPaAFAYUC")
result, err := api.GetUnlimited("storeID=103197", "")
if err != nil {
t.Fatal(err.Error())