dingtalk

package module
v0.0.0-...-05c9766 Latest Latest
Warning

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

Go to latest
Published: Mar 22, 2022 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type App

type App struct {
	Secret      string
	AccessToken string
	ZapLog      *zap.Logger   // 日志服务
	Db          *gorm.DB      // 关系数据库服务
	RDb         *redis.Client // 缓存数据库服务
	MDb         *mongo.Client // 非关系数据库服务
}

func (*App) NewParamsWith

func (app *App) NewParamsWith(params ...Params) Params

func (*App) RobotSend

func (app *App) RobotSend(notMustParams ...Params) *RobotSendResult

RobotSend 自定义机器人 https://open.dingtalk.com/document/group/custom-robot-access

type Params

type Params map[string]interface{}

Params 请求参数

func NewParams

func NewParams() Params

func (Params) Set

func (p Params) Set(key string, value interface{})

func (Params) SetParams

func (p Params) SetParams(params Params)

type RobotSendResponse

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

type RobotSendResult

type RobotSendResult struct {
	Result RobotSendResponse // 结果
	Body   []byte            // 内容
	Err    error             // 错误
}

func NewRobotSendResult

func NewRobotSendResult(result RobotSendResponse, body []byte, err error) *RobotSendResult

Jump to

Keyboard shortcuts

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