Documentation
¶
Index ¶
Constants ¶
View Source
const DefaultURL = "https://smsc.ru/sys/send.php"
Variables ¶
View Source
var ( ErrLongText = errors.New("smsc: too long text to send") ErrNoPhones = errors.New("smsc: empty phones list") )
View Source
var ErrBadValid = errors.New("smsc: invalid period for valid")
View Source
var ErrNoLoginPassword = errors.New("smsc: empty login or password")
Functions ¶
func CountBytes ¶
CountBytes returns a number of bytes for text to be send in SMS.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client has methods for API calls.
type Config ¶
type Config struct {
URL string
Login string
Password string
PasswordMD5 string
Opt Opt
Client *http.Client
}
Config is a Client config.
type ErrOpt ¶
type ErrOpt int
ErrOpt controls whether Response must include information about failed phone numbers.
const Err ErrOpt = 1
type OpOpt ¶
type OpOpt int
OpOpt controls whether Response must contain information about all phone numbers.
const Op OpOpt = 1
type Opt ¶
type Opt func(*message)
Opt configures a send message and a Result.
Click to show internal directories.
Click to hide internal directories.