Documentation
¶
Index ¶
- Constants
- type PointClient
- func (client *PointClient) CreateRecord(record *Record) (bool, error)
- func (client *PointClient) CreateZone(zone *Zone) (bool, error)
- func (client *PointClient) Delete(path string, val interface{}) error
- func (client *PointClient) DoRequest(method, path string, body io.Reader) (string, int, error)
- func (client *PointClient) Get(path string, val interface{}) error
- func (client *PointClient) Record(zone interface{}, record *Record) (Record, error)
- func (client *PointClient) Records(zone interface{}) ([]Record, error)
- func (client *PointClient) Save(path string, payload Resource, val interface{}) error
- func (client *PointClient) Zone(zone interface{}) (Zone, error)
- func (client *PointClient) Zones() ([]Zone, error)
- type Record
- type Resource
- type RootRecord
- type RootZone
- type Zone
Constants ¶
View Source
const ( ApiUrl = "https://pointhq.com" ApiVersion = "" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PointClient ¶
func NewClient ¶
func NewClient(email, apiToken string) *PointClient
func (*PointClient) CreateRecord ¶
func (client *PointClient) CreateRecord(record *Record) (bool, error)
func (*PointClient) CreateZone ¶
func (client *PointClient) CreateZone(zone *Zone) (bool, error)
func (*PointClient) Delete ¶
func (client *PointClient) Delete(path string, val interface{}) error
func (*PointClient) Get ¶
func (client *PointClient) Get(path string, val interface{}) error
func (*PointClient) Record ¶
func (client *PointClient) Record(zone interface{}, record *Record) (Record, error)
func (*PointClient) Records ¶
func (client *PointClient) Records(zone interface{}) ([]Record, error)
func (*PointClient) Save ¶
func (client *PointClient) Save(path string, payload Resource, val interface{}) error
func (*PointClient) Zone ¶
func (client *PointClient) Zone(zone interface{}) (Zone, error)
func (*PointClient) Zones ¶
func (client *PointClient) Zones() ([]Zone, error)
type Record ¶
type Record struct { Id int `json:"id,omitempty"` Name string `json:"name,omitempty"` Data string `json:"data,omitempty"` Ttl int `json:"ttl,omitempty"` Aux string `json:"aux,omitempty"` ZoneId int `json:"zone_id,omitempty"` RecordType string `json:"record_type,omitempty"` // contains filtered or unexported fields }
type RootRecord ¶
type RootRecord struct {
Record Record `json:"zone_record"`
}
func (RootRecord) Id ¶
func (rootRecord RootRecord) Id() int
Click to show internal directories.
Click to hide internal directories.