Documentation ¶
Index ¶
- type Client
- func (c *Client) CreateRecord(ctx context.Context, record DNSRecord) error
- func (c *Client) DeleteRecord(ctx context.Context, recordID string) error
- func (c *Client) GetTxtRecord(ctx context.Context, name, value, zoneID string) (*DNSRecord, error)
- func (c *Client) GetZoneID(ctx context.Context, domain string) (string, error)
- type DNSRecord
- type DNSRecords
- type Meta
- type Pagination
- type Zone
- type Zones
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
Client the Hetzner client.
func (*Client) CreateRecord ¶
CreateRecord creates a DNS record. https://dns.hetzner.com/api-docs#operation/CreateRecord
func (*Client) DeleteRecord ¶
DeleteRecord deletes a DNS record. https://dns.hetzner.com/api-docs#operation/DeleteRecord
func (*Client) GetTxtRecord ¶
GetTxtRecord gets a TXT record.
type DNSRecord ¶
type DNSRecord struct { ID string `json:"id,omitempty"` Name string `json:"name,omitempty"` Type string `json:"type,omitempty"` Value string `json:"value"` Priority int `json:"priority,omitempty"` TTL int `json:"ttl,omitempty"` ZoneID string `json:"zone_id,omitempty"` }
DNSRecord a DNS record.
type DNSRecords ¶
type DNSRecords struct {
Records []DNSRecord `json:"records"`
}
DNSRecords a set of DNS record.
type Meta ¶
type Meta struct {
Pagination Pagination `json:"pagination,omitempty"`
}
Meta response metadata.
Click to show internal directories.
Click to hide internal directories.