Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func WithApiKey ¶
func WithApiKey(key string) option
func WithSecret ¶
func WithSecret(secret string) option
Types ¶
type ResultParam ¶
type WePayer ¶
type WePayer interface { //支付相关 //统一下单 UnifiedOrder(param Param) (ResultParam, error) //扫码下单 UnifiedMicro(param Param) (ResultParam, error) //撤销订单 ReverseOrder(param Param, p12CertPath string) (ResultParam, error) //查询订单 UnifiedQuery(param Param) (ResultParam, error) //关闭订单 CloseOrder(param Param) (ResultParam, error) //退款 RefundOrder(param Param, p12CertPath string) (ResultParam, error) //退款查询 RefundQuery(param Param) (ResultParam, error) //解析退款通知, 结果将不会返回req_info RefundNotify(body io.Reader) (ResultParam, error) //下单对账单 DownloadBill(param Param, fileSavePath string) error //下载资金账单 DownloadFundFlow(param Param, p12CertPath string, fileSavePath string) error //拉取订单评论数据 DownloadComment(param Param, p12CertPath string, fileSavePath string) (offset uint64, err error) //交易保障 Report(param Param) error // //企业付款 //付款到零钱 Transfers(param Param, p12CertPath string) (ResultParam, error) //查询企业付款到零钱 TransfersQuery(param Param, p12CertPath string) (ResultParam, error) //从微信获取RSA加密的公钥 GetPublicKey(p12CertPath string, targetPath string) error //TODO 待验证 企业付款到银行卡 TransferBank(param Param, p12CertPath string, publicKeyPath string) (ResultParam, error) ////TODO 待验证 查询企业付款到银行卡 TransferBankQuery(param Param, p12CertPath string) (ResultParam, error) //小程序相关 //获取授权access_token GetAccessTokenForMini() (Param, error) //获取小程序接口凭证,使用者自己保存token,过期重新获取 //获取微信信息 GetUserInfoForMini(code, encryptedData, ivData string) (Param, error) //获取微信手机号码 GetUserPhoneForMini(code string, encryptedData string, ivData string) (Param, error) //获取session_key GetSessionKeyAndOpenId(code string) (Param, error) //公众号相关 GetAppBaseAccessToken() (Param, error) GetAppOauthAccessToken(code string) (Param, error) RefreshOauthToken(refreshToken string) (Param, error) GetAppUserInfo(oauthToken, openId, lang string) (Param, error) CheckOauthToken(oauthToken, openId string) (bool, error) }
Click to show internal directories.
Click to hide internal directories.