瀏覽代碼

test

master
huangjiajun 11 月之前
父節點
當前提交
307d812b0a
共有 1 個文件被更改,包括 4 次插入1 次删除
  1. +4
    -1
      tik_tok/api.go

+ 4
- 1
tik_tok/api.go 查看文件

@@ -6,6 +6,7 @@ import (
"crypto/hmac"
"crypto/sha256"
"encoding/hex"
"fmt"
"github.com/syyongx/php2go"
"strings"
"time"
@@ -20,7 +21,7 @@ func Send(appkey, appSecret, method string, params map[string]interface{}, accto
"app_key": appkey,
"method": method,
"param_json": paramJson,
"timestamp": zhios_third_party_utils.Int64ToStr(time.Now().Unix()),
"timestamp": time.Now().Format("2006-01-02 15:04:05"),
"v": "2",
}
sign := GetSign(appSecret, param)
@@ -36,6 +37,8 @@ func Send(appkey, appSecret, method string, params map[string]interface{}, accto
url += "?" + k + "=" + php2go.URLEncode(v)
}
}
fmt.Println(url)
fmt.Println(paramJson)
data, err := zhios_third_party_utils.CurlPost(url, paramJson, nil)
return string(data), err
}


Loading…
取消
儲存