dingtalk

package module
v1.0.20 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 8, 2024 License: MIT Imports: 10 Imported by: 0

README

Golang

📦 Golang 钉钉机器人

godoc goproxy.cn goreportcard.com deps.dev

安装

go get -v -u go.dtapp.net/dingtalk@v1.0.20

Documentation

Index

Constants

View Source
const (
	LogTable = "dingtalk"
)
View Source
const (
	Version = "1.0.20"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

Client 实例

func NewClient

func NewClient() (*Client, error)

NewClient 创建实例化

func (*Client) ConfigApiGormFun added in v1.0.17

func (c *Client) ConfigApiGormFun(apiClientFun golog.ApiGormFun)

ConfigApiGormFun 接口日志配置

func (*Client) Get added in v1.0.17

func (c *Client) Get(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error)

func (*Client) Post added in v1.0.17

func (c *Client) Post(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error)

func (*Client) RobotSend

func (c *Client) RobotSend(ctx context.Context, access_token string, notMustParams ...gorequest.Params) (*RobotSendResult, error)

RobotSend 发送消息 https://open.dingtalk.com/document/group/custom-robot-access

func (*Client) RobotSendSign added in v1.0.19

func (c *Client) RobotSendSign(ctx context.Context, access_token string, secret string, notMustParams ...gorequest.Params) (*RobotSendResult, error)

RobotSendSign 发送消息签名版 https://open.dingtalk.com/document/group/custom-robot-access

type RobotSendResponse

type RobotSendResponse struct {
	Errcode int64  `json:"errcode"`
	Errmsg  string `json:"errmsg"`
}

type RobotSendResult

type RobotSendResult struct {
	Result RobotSendResponse  // 结果
	Body   []byte             // 内容
	Http   gorequest.Response // 请求
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL