sms

package module
v0.0.0-...-c497cca Latest Latest
Warning

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

Go to latest
Published: Jan 19, 2021 License: MIT Imports: 5 Imported by: 4 modules, 4 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

README

SMS-GO

  • Go语言的阿里云短信服务SDK
  • 安装 go get github.com/aliyun-sdk/sms-go
  • 使用详见 client_test.go

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BatchItem

type BatchItem struct {
	Sign   string
	Mobile string
	Params map[string]string
}

type BatchItems

type BatchItems []BatchItem

type Client

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

func New

func New(ak, sk string, fns ...Option) (*Client, error)

func (*Client) Clone

func (c *Client) Clone(fns ...Option) *Client

func (*Client) Send

func (c *Client) Send(fns ...Option) error

Send 短信发送 支持对多个手机号码发送短信,手机号码之间以英文逗号分隔,上限为1000个手机号码 详见 https://help.aliyun.com/document_detail/101414.html

func (*Client) SendBatch

func (c *Client) SendBatch(items BatchItems) error

SendBatch 批量发送短信 与Send不同的是,SendBatch支持不同的发送参数和签名,上限为100个手机号码 详见 https://help.aliyun.com/document_detail/102364.html

type Option

type Option func(req *requests.CommonRequest)

func Action

func Action(a string) Option

func Domain

func Domain(d string) Option

func Method

func Method(m string) Option

func Mobile

func Mobile(ss string) Option

func Parameter

func Parameter(v map[string]string) Option

func QueryParam

func QueryParam(k, v string) Option

func Scheme

func Scheme(s string) Option

func SignName

func SignName(n string) Option

func Template

func Template(t string) Option

func Version

func Version(v string) Option

type Options

type Options []Option

Jump to

Keyboard shortcuts

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