Documentation
¶
Overview ¶
Package dingTalkKit 钉钉开发群工具包
Index ¶
- type DingTalkBot
- func (t *DingTalkBot) SendActionCardMessage(title, text string, btnOrientation int, singleTitle, singleURL string) error
- func (t *DingTalkBot) SendLinkMessage(title, text, messageUrl, picUrl string, atIdType int, at ...string) error
- func (t *DingTalkBot) SendMarkdownMessage(title, text string, atIdType int, at ...string) error
- func (t *DingTalkBot) SendTextMessage(text string, atIdType int, at ...string) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DingTalkBot ¶
func NewDingTalkBot ¶
func NewDingTalkBot(webHookUrl, secret string) *DingTalkBot
NewDingTalkBot 创建一个钉钉机器人
func (*DingTalkBot) SendActionCardMessage ¶
func (t *DingTalkBot) SendActionCardMessage(title, text string, btnOrientation int, singleTitle, singleURL string) error
SendActionCardMessage 发送actionCard消息
- @param title 标题
- @param text 发送内容
- @param btnOrientation 按钮排序方向 0:按钮竖直排列,1:按钮横向排列
- @param singleTitle 单标题
- @param singleURL 单链接
func (*DingTalkBot) SendLinkMessage ¶
func (t *DingTalkBot) SendLinkMessage(title, text, messageUrl, picUrl string, atIdType int, at ...string) error
SendLinkMessage 发送link消息
- @param title 标题
- @param text 发送内容
- @param messageUrl 跳转地址
- @param picUrl 图片地址
- @param atIdType 1:@手机, 2:@userId, 3:@所有人, other:不@
- @param at 传入的手机号或者用户id
func (*DingTalkBot) SendMarkdownMessage ¶
func (t *DingTalkBot) SendMarkdownMessage(title, text string, atIdType int, at ...string) error
SendMarkdownMessage 发送markdown消息
- @param title 标题(用于左侧显示消息列表中显示缩略消息,在具体的内容中不显示)
- @param text 发送内容
- @param atIdType 1:@手机, 2:@userId, 3:@所有人, other:不@
- @param at 传入的手机号或者用户id
func (*DingTalkBot) SendTextMessage ¶
func (t *DingTalkBot) SendTextMessage(text string, atIdType int, at ...string) error
SendTextMessage 发送文本消息
- @param text 发送内容
- @param atIdType 1:@手机, 2:@userId, 3:@所有人, other:不@
- @param at 传入的手机号或者用户id
Click to show internal directories.
Click to hide internal directories.