Go API for interacting with DreamHost DNS provider's interface
key := "<your dreamhost API key>"
var httpClient http.Client // if you need a configured http client
client, err := api.NewClient(key, httpClient)
If the DNS record is created through this API, Dreamhost persists the record with a trailing .
.
So if you've created a record with record=test.mydomain.com
value, upon listing and deletion the record will be displayed as record=test.mydomain.com.
(not the trailing dot).
Currently the API supports the following operations:
input := api.DNSRecordInput{}
err := client.AddDNSRecord(context.Background(), input)
records, err = client.ListDNSRecords(context.Background())
input := api.DNSRecordInput{}
err := client.RemoveDNSRecord(context.Background(), input)
See example/
.