Documentation ¶
Index ¶
- Variables
- func BindQuery(query string, i any)
- func GetBankCode(bank string) string
- func MD5(str string) string
- func PrivateKeyNormal(key string) string
- func PublicKeyNormal(key string) string
- func Replace(text string, kv map[string]string) string
- func RsaEncrypt(message []byte) (string, error)
- func Serialized(data any) string
- func SignWithMd5(data any) string
- type PayoutBodyNotificationInternal
- type PayoutInternalReq
- type PayoutNotificationBody
- type PayoutReq
- type PayoutResp
- type WithdrawalNotificationInternal
- type WithdrawalNotificationRequest
- type WithdrawalRequest
- type WithdrawalRequestInternal
- type WithdrawalResponse
- type WithdrawalResponseInternal
Constants ¶
This section is empty.
Variables ¶
View Source
var MD5_KEY = `` // release
var MD5_KEY = `5B8F9493253D97A9EA413F20A46DC1B4` // test
View Source
var MER_NO = ""
View Source
var MER_PRIVATE_KEY = ``
View Source
var PAUOUT_SUCCESS_URL = "https://d757-221-237-121-2.ngrok-free.app"
View Source
var PAYOUT_NOTIFY_URL = "https://d757-221-237-121-2.ngrok-free.app"
View Source
var WITHDRAWAL_NOTIFY_URL = "https://d757-221-237-121-2.ngrok-free.app"
Functions ¶
func GetBankCode ¶ added in v1.2.22
func PrivateKeyNormal ¶ added in v1.2.13
func PublicKeyNormal ¶ added in v1.2.13
func RsaEncrypt ¶
func Serialized ¶
func SignWithMd5 ¶
Types ¶
type PayoutBodyNotificationInternal ¶ added in v1.2.13
type PayoutBodyNotificationInternal struct { BusiCode string `json:"busi_code"` ErrCode string `json:"err_code"` ErrMsg string `json:"err_msg"` MerNo string `json:"mer_no"` MerOrderNo string `json:"mer_order_no"` OrderAmount string `json:"order_amount"` OrderNo string `json:"order_no"` OrderTime string `json:"order_time"` PayAmount string `json:"pay_amount"` PayTime string `json:"pay_time"` Status string `json:"status"` }
type PayoutInternalReq ¶
type PayoutInternalReq struct { MerNo string `json:"mer_no"` Phone string `json:"phone"` Pname string `json:"pname"` OrderAmount string `json:"order_amount"` NotifyUrl string `json:"notifyUrl"` PageUrl string `json:"pageUrl"` CcyNo string `json:"ccy_no"` Pemail string `json:"pemail"` BusiCode string `json:"busi_code"` MerOrderNo string `json:"mer_order_no"` }
type PayoutNotificationBody ¶ added in v1.2.13
type PayoutNotificationBody struct { PayoutBodyNotificationInternal Sign string `json:"sign"` }
func PayoutNotify ¶
func PayoutNotify(body []byte) (result PayoutNotificationBody, err error)
type PayoutReq ¶
type PayoutReq struct { Sign string `json:"sign"` PayoutInternalReq }
type PayoutResp ¶
type PayoutResp struct { OrderNo string `json:"order_no"` MerNo string `json:"mer_no"` Pname string `json:"pname"` Sign string `json:"sign"` ErrCode string `json:"err_code"` OrderTime string `json:"order_time"` Pemail string `json:"pemail"` Phone string `json:"phone"` OrderData string `json:"order_data"` ErrMsg string `json:"err_msg"` OrderAmount string `json:"order_amount"` NotifyUrl string `json:"notifyUrl"` PageUrl string `json:"pageUrl"` CcyNo string `json:"ccy_no"` BusiCode string `json:"busi_code"` MerOrderNo string `json:"mer_order_no"` Status string `json:"status"` }
func Payout ¶
func Payout(ordersn, amount string) (result PayoutResp, err error)
type WithdrawalNotificationInternal ¶ added in v1.2.13
type WithdrawalNotificationInternal struct { ErrCode string `json:"err_code"` ErrMsg string `json:"err_msg"` MerNo string `json:"mer_no"` MerOrderNo string `json:"mer_order_no"` OrderAmount string `json:"order_amount"` CcyNo string `json:"ccy_no"` OrderNo string `json:"order_no"` CreateTime string `json:"create_time"` PayTime string `json:"pay_time"` Status string `json:"status"` }
type WithdrawalNotificationRequest ¶ added in v1.2.13
type WithdrawalNotificationRequest struct { WithdrawalNotificationInternal Sign string `json:"sign"` }
func WithdrawalNotification ¶ added in v1.2.13
func WithdrawalNotification(body []byte) (result WithdrawalNotificationRequest, err error)
type WithdrawalRequest ¶ added in v1.2.13
type WithdrawalRequest struct { Sign string `json:"sign"` WithdrawalRequestInternal }
提现
type WithdrawalRequestInternal ¶ added in v1.2.13
type WithdrawalRequestInternal struct { Summary string `json:"summary"` BankCode string `json:"bank_code"` AccName string `json:"acc_name"` MerNo string `json:"mer_no"` Province string `json:"province"` OrderAmount string `json:"order_amount"` MobileNo string `json:"mobile_no"` AccNo string `json:"acc_no"` NotifyUrl string `json:"notifyUrl"` CcyNo string `json:"ccy_no"` MerOrderNo string `json:"mer_order_no"` }
type WithdrawalResponse ¶ added in v1.2.13
type WithdrawalResponse struct { Sign string `json:"sign"` WithdrawalResponseInternal }
func Withdrawal ¶ added in v1.2.13
func Withdrawal(ordersn, bank, accountName, accountId, amount string) (result WithdrawalResponse, err error)
type WithdrawalResponseInternal ¶ added in v1.2.13
type WithdrawalResponseInternal struct { Summary string `json:"summary"` OrderNo string `json:"order_no"` BankCode string `json:"bank_code"` MerNo string `json:"mer_no"` MobileNo string `json:"mobile_no"` ErrCode string `json:"err_code"` AccountNo string `json:"account_no"` AccName string `json:"acc_name"` Province string `json:"province"` ErrMsg string `json:"err_msg"` OrderAmount string `json:"order_amount"` AccNo string `json:"acc_no"` NotifyUrl string `json:"notifyUrl"` CcyNo string `json:"ccy_no"` MerOrderNo string `json:"mer_order_no"` Status string `json:"status"` }
Click to show internal directories.
Click to hide internal directories.