feat(wechat): 关注公众号后自动回复欢迎语(被动回复,可后台配置) #12
@@ -19,6 +19,7 @@ const volcAppKey = "PlgvMymc7f3tQnJ6"
|
||||
func setVolcAuthHeaders(hdr http.Header, apiKey, appID, resourceID string) {
|
||||
// 直接赋 map(不走 Set)以**保留精确大小写**:Go 的 Header.Set 会把 "X-Api-App-ID"
|
||||
// 规范化成 "X-Api-App-Id",而火山网关按精确大小写匹配(官方 demo 用 X-Api-App-ID)。
|
||||
// 新版 API Key 走 X-Api-Access-Key;X-Api-App-Key 是网关固定常量,缺它 400 "app key not found"。
|
||||
hdr["X-Api-App-Key"] = []string{volcAppKey}
|
||||
hdr["X-Api-Access-Key"] = []string{apiKey}
|
||||
hdr["X-Api-Resource-Id"] = []string{resourceID}
|
||||
|
||||
Reference in New Issue
Block a user