 Documentation
      ¶
      Documentation
      ¶
    
    
  
    
  
    Overview ¶
Package dingding 钉钉机器人
Index ¶
Constants ¶
This section is empty.
Variables ¶
      View Source
      
  
var ( TOKEN = `` SECRET = `` API_URL = `https://oapi.dingtalk.com/robot/send?access_token=%v×tamp=%v&sign=%v` )
Functions ¶
func HmacSHA256 ¶
Types ¶
type ActionCard ¶
type ActionCard struct {
	Title          string    `json:"title"`          //消息标题
	Text           string    `json:"text"`           //markdown格式的消息
	SingleTitle    string    `json:"singleTitle"`    //单个按钮的方案。(设置此项和singleURL后btns无效)
	SingleURL      string    `json:"singleURL"`      //点击singleTitle按钮触发的URL
	BtnOrientation string    `json:"btnOrientation"` //0-按钮竖直排列,1-按钮横向排列
	Buttons        []*Button `json:"btns,omitempty"` //按钮组
}
    type Message ¶
type Message struct {
	MsgType    string      `json:"msgtype"`              //消息类型 text/markdown/link/actionCard/feedCard
	Text       *Text       `json:"text,omitempty"`       // MsgType=text 时有效
	Markdown   *Markdown   `json:"markdown,omitempty"`   // MsgType=markdown 时有效
	Link       *Link       `json:"link,omitempty"`       // MsgType=link 时有效
	ActionCard *ActionCard `json:"actionCard,omitempty"` // MsgType=actionCard 时有效
	FeedCard   *FeedCard   `json:"feedCard,omitempty"`   // MsgType=feedCard 时有效
	At         *At         `json:"at,omitempty"`         // MsgType=text 和 MsgType=markdown  时有效
}
    Message 消息实体
func (*Message) SendMarkdown ¶
 Click to show internal directories. 
   Click to hide internal directories.