verify

package
v5.3.0+incompatible Latest Latest
Warning

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

Go to latest
Published: Jul 3, 2019 License: BSD-2-Clause Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Delete

func Delete(c *messagebird.Client, id string) error

Delete deletes an existing Verify object by its ID.

Types

type Params

type Params struct {
	Originator  string
	Reference   string
	Type        string
	Template    string
	DataCoding  string
	ReportURL   string
	Voice       string
	Language    string
	Timeout     int
	TokenLength int
}

Params handles optional verification parameters.

type Verify

type Verify struct {
	ID                 string
	HRef               string
	Reference          string
	Status             string
	Messages           map[string]string
	CreatedDatetime    *time.Time
	ValidUntilDatetime *time.Time
	Recipient          int
}

Verify object represents MessageBird server response.

func Create

func Create(c *messagebird.Client, recipient string, params *Params) (*Verify, error)

Create generates a new One-Time-Password for one recipient.

func Read

func Read(c *messagebird.Client, id string) (*Verify, error)

Read retrieves an existing Verify object by its ID.

func VerifyToken

func VerifyToken(c *messagebird.Client, id, token string) (*Verify, error)

VerifyToken performs token value check against MessageBird API.

Jump to

Keyboard shortcuts

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