Documentation ¶
Index ¶
- Constants
- func GenOrderID() string
- func MD5Sum(str string) string
- func MapToXml(params Params) string
- type Client
- func (c *Client) AuthCodeToOpenid(params Params) (Params, error)
- func (c *Client) CloseOrder(params Params) (Params, error)
- func (c *Client) DownloadBill(params Params) (Params, error)
- func (c *Client) DownloadFundFlow(params Params) (Params, error)
- func (c *Client) GetSandboxSignKey() (string, error)
- func (c *Client) MicroPay(params Params) (Params, error)
- func (c *Client) OnPayCallback(xmlStr string) (Params, error)
- func (c *Client) OrderQuery(params Params) (Params, error)
- func (c *Client) Refund(params Params) (Params, error)
- func (c *Client) RefundQuery(params Params) (Params, error)
- func (c *Client) Report(params Params) (Params, error)
- func (c *Client) Reverse(params Params) (Params, error)
- func (c *Client) SetCertData(certPath string) error
- func (c *Client) SetHttpConnectTimeoutMs(ms int)
- func (c *Client) SetHttpReadTimeoutMs(ms int)
- func (c *Client) SetSignType(signType string)
- func (c *Client) ShortUrl(params Params) (Params, error)
- func (c *Client) Sign(params Params) string
- func (c *Client) UnifiedOrder(params Params) (Params, error)
- func (c *Client) ValidSign(params Params) bool
- type Notifies
- type Params
Constants ¶
View Source
const ( Fail = "FAIL" Success = "SUCCESS" HMACSHA256 = "HMAC-SHA256" MD5 = "MD5" Sign = "sign" MicroPayUrl = "https://api.mch.weixin.qq.com/pay/micropay" UnifiedOrderUrl = "https://api.mch.weixin.qq.com/pay/unifiedorder" OrderQueryUrl = "https://api.mch.weixin.qq.com/pay/orderquery" ReverseUrl = "https://api.mch.weixin.qq.com/secapi/pay/reverse" CloseOrderUrl = "https://api.mch.weixin.qq.com/pay/closeorder" RefundUrl = "https://api.mch.weixin.qq.com/secapi/pay/refund" RefundQueryUrl = "https://api.mch.weixin.qq.com/pay/refundquery" DownloadBillUrl = "https://api.mch.weixin.qq.com/pay/downloadbill" DownloadFundFlowUrl = "https://api.mch.weixin.qq.com/pay/downloadfundflow" ReportUrl = "https://api.mch.weixin.qq.com/payitil/report" ShortUrl = "https://api.mch.weixin.qq.com/tools/shorturl" AuthCodeToOpenidUrl = "https://api.mch.weixin.qq.com/tools/authcodetoopenid" SandboxMicroPayUrl = "https://api.mch.weixin.qq.com/sandboxnew/pay/micropay" SandboxUnifiedOrderUrl = "https://api.mch.weixin.qq.com/sandboxnew/pay/unifiedorder" SandboxOrderQueryUrl = "https://api.mch.weixin.qq.com/sandboxnew/pay/orderquery" SandboxReverseUrl = "https://api.mch.weixin.qq.com/sandboxnew/secapi/pay/reverse" SandboxCloseOrderUrl = "https://api.mch.weixin.qq.com/sandboxnew/pay/closeorder" SandboxRefundUrl = "https://api.mch.weixin.qq.com/sandboxnew/secapi/pay/refund" SandboxRefundQueryUrl = "https://api.mch.weixin.qq.com/sandboxnew/pay/refundquery" SandboxDownloadBillUrl = "https://api.mch.weixin.qq.com/sandboxnew/pay/downloadbill" SandboxDownloadFundFlowUrl = "https://api.mch.weixin.qq.com/sandboxnew/pay/downloadfundflow" SandboxReportUrl = "https://api.mch.weixin.qq.com/sandboxnew/payitil/report" SandboxShortUrl = "https://api.mch.weixin.qq.com/sandboxnew/tools/shorturl" SandboxAuthCodeToOpenidUrl = "https://api.mch.weixin.qq.com/sandboxnew/tools/authcodetoopenid" SandboxGetSignKeyUrl = "https://api.mch.weixin.qq.com/sandboxnew/pay/getsignkey" )
Variables ¶
This section is empty.
Functions ¶
func GenOrderID ¶
func GenOrderID() string
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func (*Client) AuthCodeToOpenid ¶
授权码查询OPENID接口
func (*Client) GetSandboxSignKey ¶
获取沙箱 sandbox_signkey
func (*Client) SetHttpConnectTimeoutMs ¶
func (*Client) SetHttpReadTimeoutMs ¶
func (*Client) SetSignType ¶
Click to show internal directories.
Click to hide internal directories.