internal

package
v4.12.0 Latest Latest
Warning

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

Go to latest
Published: Dec 19, 2023 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	BaseURL    string
	HTTPClient *http.Client
	// contains filtered or unexported fields
}

Client DNSMadeEasy client.

func NewClient

func NewClient(apiKey, apiSecret string) (*Client, error)

NewClient creates a DNSMadeEasy client.

func (*Client) CreateRecord

func (c *Client) CreateRecord(domain *Domain, record *Record) error

CreateRecord creates a TXT records.

func (*Client) DeleteRecord

func (c *Client) DeleteRecord(record Record) error

DeleteRecord deletes a TXT records.

func (*Client) GetDomain

func (c *Client) GetDomain(authZone string) (*Domain, error)

GetDomain gets a domain.

func (*Client) GetRecords

func (c *Client) GetRecords(domain *Domain, recordName, recordType string) (*[]Record, error)

GetRecords gets all TXT records.

type Domain

type Domain struct {
	ID   int    `json:"id"`
	Name string `json:"name"`
}

Domain holds the DNSMadeEasy API representation of a Domain.

type Record

type Record struct {
	ID       int    `json:"id"`
	Type     string `json:"type"`
	Name     string `json:"name"`
	Value    string `json:"value"`
	TTL      int    `json:"ttl"`
	SourceID int    `json:"sourceId"`
}

Record holds the DNSMadeEasy API representation of a Domain Record.

Jump to

Keyboard shortcuts

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