smsav8d

package
v0.0.6 Latest Latest
Warning

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

Go to latest
Published: Nov 18, 2020 License: MPL-2.0 Imports: 7 Imported by: 0

Documentation

Overview

Package smsav8d provides a driver to send SMS using https://www.teamplus.tech/product/every8d-value/

Index

Constants

View Source
const SMSAV8D = "SMSAV8D"

SMSAV8D is the type of the driver

Variables

This section is empty.

Functions

func New

func New(account, password string, hc *http.Client) (ret types.Driver)

New creates a driver to send SMS

The format of payload is defined by Message struct, and endpoint is same as "DEST" field in official API doc.

Types

type Message

type Message struct {
	// required
	Content string `json:"content"` // MSG field

	// optional
	Subject string `json:"subject"` // SB field
	Time    string `json:"time"`    // ST field
	Retry   int    `json:"retry"`   // RETRYTIME field
}

Message defines payload structure

Refer to every8d's API doc for further information

Jump to

Keyboard shortcuts

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