parent
dfd915fceb
commit
70e338cdd6
@ -1,5 +1,5 @@
|
||||
package go_library
|
||||
|
||||
func Version() string {
|
||||
return "1.0.108"
|
||||
return "1.0.109"
|
||||
}
|
||||
|
@ -0,0 +1,17 @@
|
||||
package alipayopen
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/dtapps/go-library/utils/gorequest"
|
||||
)
|
||||
|
||||
func (c *Client) Get(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, c.newParamsWithType(_method, params))
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return request.ResponseBody, err
|
||||
}
|
@ -0,0 +1,25 @@
|
||||
package dingdanxia
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/dtapps/go-library/utils/gorequest"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
func (c *Client) Get(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodGet)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
||||
|
||||
func (c *Client) Post(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodPost)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
@ -0,0 +1,25 @@
|
||||
package dingtalk
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/dtapps/go-library/utils/gorequest"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
func (c *Client) Get(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodGet)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
||||
|
||||
func (c *Client) Post(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodPost)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
@ -0,0 +1,25 @@
|
||||
package eastiot
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/dtapps/go-library/utils/gorequest"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
func (c *Client) Get(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodGet)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
||||
|
||||
func (c *Client) Post(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodPost)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
@ -0,0 +1,25 @@
|
||||
package ejiaofei
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/dtapps/go-library/utils/gorequest"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
func (c *Client) Get(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodGet)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
||||
|
||||
func (c *Client) Post(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodPost)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
@ -0,0 +1,15 @@
|
||||
package feishu
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/dtapps/go-library/utils/gorequest"
|
||||
)
|
||||
|
||||
func (c *Client) Post(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
@ -0,0 +1,14 @@
|
||||
package jd
|
||||
|
||||
import (
|
||||
"context"
|
||||
)
|
||||
|
||||
func (c *Client) Post(ctx context.Context, _method string, notMustParams ...Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := NewParamsWithType(_method, notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, params)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
@ -0,0 +1,34 @@
|
||||
package kashangwl
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/baidubce/bce-sdk-go/http"
|
||||
"github.com/dtapps/go-library/utils/gorequest"
|
||||
)
|
||||
|
||||
func (c *Client) Post(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
||||
|
||||
func (c *Client) CacheGet(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.requestCache(ctx, apiUrl+_method, params, http.GET)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
||||
|
||||
func (c *Client) CachePost(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.requestCache(ctx, apiUrl+_method, params, http.POST)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
@ -0,0 +1,25 @@
|
||||
package meituan
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/dtapps/go-library/utils/gorequest"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
func (c *Client) Get(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodGet)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
||||
|
||||
func (c *Client) Post(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodPost)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
@ -0,0 +1,15 @@
|
||||
package nldyp
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/dtapps/go-library/utils/gorequest"
|
||||
)
|
||||
|
||||
func (c *Client) Post(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
@ -0,0 +1,14 @@
|
||||
package pinduoduo
|
||||
|
||||
import (
|
||||
"context"
|
||||
)
|
||||
|
||||
func (c *Client) Get(ctx context.Context, _method string, notMustParams ...Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := NewParamsWithType(_method, notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, params)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
@ -0,0 +1,15 @@
|
||||
package pintoto
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/dtapps/go-library/utils/gorequest"
|
||||
)
|
||||
|
||||
func (c *Client) Post(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
@ -0,0 +1,14 @@
|
||||
package taobao
|
||||
|
||||
import (
|
||||
"context"
|
||||
)
|
||||
|
||||
func (c *Client) Get(ctx context.Context, _method string, notMustParams ...Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := NewParamsWithType(_method, notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, params)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
@ -0,0 +1,25 @@
|
||||
package wechatminiprogram
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/dtapps/go-library/utils/gorequest"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
func (c *Client) Get(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodGet)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
||||
|
||||
func (c *Client) Post(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodPost)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
@ -0,0 +1,25 @@
|
||||
package wechatoffice
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/dtapps/go-library/utils/gorequest"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
func (c *Client) Get(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodGet)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
||||
|
||||
func (c *Client) Post(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodPost)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
@ -0,0 +1,25 @@
|
||||
package wechatopen
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/dtapps/go-library/utils/gorequest"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
func (c *Client) Get(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodGet)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
||||
|
||||
func (c *Client) Post(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodPost)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
@ -0,0 +1,25 @@
|
||||
package wechatpayapiv3
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/dtapps/go-library/utils/gorequest"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
func (c *Client) Get(ctx context.Context, _method string, commonParams bool, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodGet, commonParams)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
||||
|
||||
func (c *Client) Post(ctx context.Context, _method string, commonParams bool, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodPost, commonParams)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
@ -0,0 +1,25 @@
|
||||
package wechatpayopen
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/dtapps/go-library/utils/gorequest"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
func (c *Client) Get(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodGet)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
||||
|
||||
func (c *Client) Post(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodPost)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
@ -0,0 +1,25 @@
|
||||
package wechatqy
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/dtapps/go-library/utils/gorequest"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
func (c *Client) Get(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodGet)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
||||
|
||||
func (c *Client) Post(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodPost)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
@ -0,0 +1,25 @@
|
||||
package wechatunion
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/dtapps/go-library/utils/gorequest"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
func (c *Client) Get(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodGet)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
||||
|
||||
func (c *Client) Post(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params, http.MethodPost)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
@ -0,0 +1,15 @@
|
||||
package wikeyun
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/dtapps/go-library/utils/gorequest"
|
||||
)
|
||||
|
||||
func (c *Client) Post(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error) {
|
||||
// 参数
|
||||
params := gorequest.NewParamsWith(notMustParams...)
|
||||
// 请求
|
||||
request, err := c.request(ctx, apiUrl+_method, params)
|
||||
// 定义
|
||||
return request.ResponseBody, err
|
||||
}
|
Binary file not shown.
Before Width: | Height: | Size: 69 MiB After Width: | Height: | Size: 69 MiB |
Binary file not shown.
Loading…
Reference in new issue