airtime

package
v0.0.0-...-8bb53dc Latest Latest
Warning

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

Go to latest
Published: Mar 14, 2019 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Entry

type Entry struct {
	ErrorMessage string
	PhoneNumber  string
	Amount       string
	Discount     string
	Status       string
	RequestID    string
}

Entry is the entry for each airtime response

type Response

type Response struct {
	NumSent       int
	TotalAmount   string
	TotalDiscount string
	ErrorMessage  string
	Responses     []Entry
}

Response is the reponse from the api

type Service

type Service struct {
	Username string
	APIKey   string
	Env      string
}

Service is the airtime service

func NewService

func NewService(username, apiKey, env string) Service

NewService returns a new service

func (Service) Send

func (service Service) Send() (*Response, error)

Send sends a new airtime request

Jump to

Keyboard shortcuts

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