toolz

package
v0.0.0-...-6162916 Latest Latest
Warning

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

Go to latest
Published: Jun 22, 2020 License: MIT Imports: 13 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrType_twilioInvalidNumber     = errors.New("Twilio to phone number is invalid")
	ErrType_twilioRateLimitExceeded = errors.New("Twilio message que limit reached")
)

Functions

This section is empty.

Types

type MailgunConfig_t

type MailgunConfig_t struct {
	Domain, Key string
}

type Mailgun_c

type Mailgun_c struct {
}

func (*Mailgun_c) Send

func (this *Mailgun_c) Send(ctx context.Context, from, subject, body, html, campaign string, to ...string) error

! \brief Sends a single plain text email to a user

func (*Mailgun_c) ValidateEmail

func (this *Mailgun_c) ValidateEmail(email *string) bool

! \brief Does a validate call against the mailgun server

type SlackConfig_t

type SlackConfig_t struct {
	Username, Token string
}

type Slack_c

type Slack_c struct {
}

func (*Slack_c) Error

func (this *Slack_c) Error(ctx context.Context, msg string) error

type TwilioConfig_t

type TwilioConfig_t struct {
	SID, Token string
}

type Twilio_c

type Twilio_c struct {
}

func (*Twilio_c) SMS

func (this *Twilio_c) SMS(ctx context.Context, config *TwilioConfig_t, to, from, outMsg, outMediaUrl string) error

! \brief Sends an sms/mms message to the target number

func (*Twilio_c) ValidatePhoneNumber

func (this *Twilio_c) ValidatePhoneNumber(original string) (out string, err error)

! \brief Validates a phone number and returns the twilio approved format for it

Jump to

Keyboard shortcuts

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