32 lines
805 B
Go
32 lines
805 B
Go
package hongbao
|
|
|
|
import (
|
|
"gitee.ltd/lxh/xybot/base"
|
|
)
|
|
|
|
// GetHongBaoDetail
|
|
// @description: 获取红包详情
|
|
// @receiver s
|
|
// @param xml string 红包 XML 数据
|
|
// @param encryptKey string 加密密钥
|
|
// @param encryptUserinfo string 加密的用户信息
|
|
// @return resp
|
|
// @return err
|
|
func (s service) GetHongBaoDetail(xml, encryptKey, encryptUserinfo string) (resp any, err error) {
|
|
var result base.Response[any]
|
|
_, err = s.client.R().
|
|
SetHeader("WeChatId", s.robotInfo.GetId()).
|
|
SetResult(&result).
|
|
SetBody(map[string]any{
|
|
"Wxid": s.robotInfo.GetId(),
|
|
"Xml": xml,
|
|
"EncryptKey": encryptKey,
|
|
"EncryptUserinfo": encryptUserinfo,
|
|
}).Post("/GetHongBaoDetail")
|
|
if err = result.CheckError(err); err != nil {
|
|
return
|
|
}
|
|
resp = result.Data
|
|
return
|
|
}
|