template

package
v0.0.0-...-63002a4 Latest Latest
Warning

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

Go to latest
Published: Sep 17, 2021 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DataItem

type DataItem struct {
	Value string `json:"value"`
	Color string `json:"color"`
}

DataItem ...

type ReplyInfo

type ReplyInfo struct {
	ToUser   string               `json:"touser"`
	ID       string               `json:"template_id"`
	URL      string               `json:"url"`
	TopColor string               `json:"topcolor"`
	Data     map[string]*DataItem `json:"data"`
}

ReplyInfo 消息模板回复

func NewReplyInfo

func NewReplyInfo(tmplID string) *ReplyInfo

NewReplyInfo ...

func (*ReplyInfo) JSON

func (r *ReplyInfo) JSON() string

JSON ...

type Template

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

Template 消息

func NewTemplate

func NewTemplate(c wechat.Clienter) *Template

NewTemplate ...

func (*Template) Send

func (t *Template) Send(data *ReplyInfo) error

Send 发送模板消息 https://mp.weixin.qq.com/debug/cgi-bin/readtmpl?t=tmplmsg/faq_tmpl

Jump to

Keyboard shortcuts

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