feat: init

This commit is contained in:
Rogee
2024-11-27 11:55:09 +08:00
parent e0eb7e5e2e
commit e4b9cc5f26
13 changed files with 462 additions and 2 deletions

16
pkg/wechat/response.go Normal file
View File

@@ -0,0 +1,16 @@
package wechat
type Response struct {
ErrCode int `json:"errcode"`
ErrMsg int `json:"errmsg"`
ErrDescribe int `json:"-"`
}
func (r *Response) Error() error {
return translateError(r.ErrCode)
}
type AccessTokenResponse struct {
AccessToken string `json:"access_token"`
ExpiresIn int `json:"expires_in"`
}