type APIUsage struct {
	GeoLocationRequests int		// Number of geolocation API requests
	MailRequests 	    int		// Number of mail API requests


type Error struct {
	Status  int      // HTTP status code
	Success bool     // Success flag  
	Message string 	 // Descriptive error message
	Code    string   // Error code

You will find all the error codes in the REST API documentation.


type GeoLocationOptions struct {
	DisplayFields    string 	// comma separated list of fields to display (snake_case), rest of fields will be 0 or empty
	LookupHostname   bool       // set to true if you want to reverse lookup ip address to hostname
	ShowSecurityInfo bool       // set to true if you want additional security info 


type IPCurrency struct {
	Code          string 
	NumericCode   string 
	Name          string 
	PluralName    string 
	Symbol        string 
	NativeSymbol  string 
	DecimalDigits int    


type IPLanguage struct {
	Code       string 
	Code2      string 
	Name       string 
	NativeName string 
	RTL        bool   


type IPLocation struct {
	IPAddress       string // ip address        
	Type            string // ipv4 or ipv6       
	Hostname        string // resolved host name if LookupHostname set to true in GeoLocationOptions       
	Continent       string    
	ContinentCode   string    
	Country         string    
	CountryNative   string    
	CountryCode     string    
	CountryCode3    string    
	Capital         string    
	Region          string       
	RegionCode      string       
	City            string        
	Postcode        string        
	Latitude        float64        
	Longitude       float64        
	PhonePrefix     string       
	Currencies      []IPCurrency 
	Languages       []IPLanguage 
	Flag            string       
	FlagEmoji       string       
	IsEU            *bool        
	TLD             string       
	ISP             string       
	Timezone        *IPTimezone  
	Security        *IPSecurity  


type IPSecurity struct {
	IsProxy     bool     
	ProxyType   string   
	IsCrawler   bool     
	CrawlerName string   
	CrawlerType string   
	IsTOR       bool     
	ThreatLevel string   
	ThreatTypes []string 


type IPTimezone struct {
	ID             string 
	LocalTime      string 
	GMTOffset      int    
	Code           string 
	DaylightSaving bool   


import (

type MailMessage struct {
	Date        time.Time 
	From        string    
	FromName    string    
	ReplyTo     string    
	To          []string  
	Cc          []string  
	Bcc         []string  
	Subject     string    
	Text        string    
	HTML        string    
	Attachments []string  
	Tags        []string  
	Charset     string    
	Encoding    string    

	// Options:
	RequireTLS             null.Bool 
	VerifyCertificate      null.Bool 
	OpenTracking           null.Bool 
	ClickTracking          null.Bool 
	PlainTextClickTracking null.Bool 
	UnsubscribeTracking    null.Bool 
	TestMode               null.Bool 


type MailReceipt struct {
	ID                 string 
	AcceptedRecipients int    
	RejectedRecipients int