Skip to content

Latest commit

 

History

History
34 lines (26 loc) · 792 Bytes

README.md

File metadata and controls

34 lines (26 loc) · 792 Bytes

linode

linode is a library for interacting with the Linode API.

Support for the API is as follows:

  • DNS: Supported.
  • Raw interaction with the API: Supported.
  • Batch requests: Partially supported.

Usage

This section definitely needs to be fleshed out more in the future, but until that point, here is a simple example:

import (
        "log"

        "github.com/timewasted/linode/dns"
)

linode := dns.New("<insert api key here>")
domain, err := linode.GetDomain("example.com")
if err != nil {
        log.Fatalln(err)
}
resource, err := linode.CreateDomainResourceTXT(domain.DomainID, "_acme-challenge", "super secret value", 60)
if err != nil {
        log.Fatalln(err)
}
// Do stuff with resource