Documentation ¶
Index ¶
- Constants
- func AddEntry(entry Domain, data string, name string, dnsType dnsType, ttl int, ...) error
- func DelEntry(entry Domain, name string, dnsType dnsType, goDaddyURL string) error
- func ListEntries(entry Domain, dnsType dnsType, filedump string, notable bool, ...) error
- func PrintDomains(domains []Domain)
- func PrintErrorMsg(msg string)
- func PrintInfo(msg string)
- func SetNoColor()
- type DNSEntry
- type Domain
- type Domains
Constants ¶
View Source
const ( A dnsType = "A" AAAA dnsType = "AAAA" CNAME dnsType = "CNAME" MX dnsType = "MX" NS dnsType = "NS" SOA dnsType = "SOA" SRV dnsType = "SRV" TXT dnsType = "TXT" NIL dnsType = "NIL" )
View Source
const GO_DADDY_API_SERVER = "https://api.godaddy.com"
View Source
const GO_DADDY_DOMAIN = "/v1/domains/{domain}/records/"
View Source
const GO_DADDY_DOMAIN_TYPE = GO_DADDY_DOMAIN + "{type}/"
View Source
const GO_DADDY_DOMAIN_TYPE_NAME = GO_DADDY_DOMAIN_TYPE + "{name}/"
Variables ¶
This section is empty.
Functions ¶
func AddEntry ¶
func AddEntry(entry Domain, data string, name string, dnsType dnsType, ttl int, goDaddyUrl string) error
Add an entry to the DNS
func ListEntries ¶
func ListEntries(entry Domain, dnsType dnsType, filedump string, notable bool, goDaddyURL string) error
Get call for listing entries in the domain https://developer.godaddy.com/doc/endpoint/domains#/v1/recordGet
Types ¶
type DNSEntry ¶
type DNSEntry struct { Data string `json:"data"` Name string `json:"name"` TTL int `json:"ttl"` DNSType dnsType `json:"type"` Weight int `json:"weight"` Service string `json:"service"` Priority int `json:"priority"` Protocol string `json:"protocol"` Port int `json:"port"` }
DNS entry struct returned by the godaddy api Json is the following [
{ "data": "string", "name": "string", "port": 65535, "priority": 0, "protocol": "string", "service": "string", "ttl": 0, "type": "A", "weight": 0 }
]
Click to show internal directories.
Click to hide internal directories.