smsprofi

package
v0.14.2 Latest Latest
Warning

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

Go to latest
Published: Feb 26, 2024 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Message

type Message struct {
	Recepient string `json:"recipient"`
	Text      string `json:"text"`
	Timeout   int    `json:"timeout"`
	Source    string `json:"source,omitempty"`
}

type Request

type Request struct {
	Messages []Message `json:"messages"`
}

type Response

type Response struct {
	Success bool           `json:"success"`
	Error   *ResponseError `json:"error"`
}

func (*Response) Err

func (r *Response) Err() error

type ResponseError

type ResponseError struct {
	Code        int    `json:"code"`
	Description string `json:"descr"`
}

func (*ResponseError) Error

func (re *ResponseError) Error() string

type SMSProfi

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

func NewSMSProfiProvider

func NewSMSProfiProvider(source string, key string, messageTMPL string) *SMSProfi

func (*SMSProfi) SendVerificationCode

func (p *SMSProfi) SendVerificationCode(phone, code string) error

Jump to

Keyboard shortcuts

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