dnsla

package
v0.4.9 Latest Latest
Warning

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

Go to latest
Published: Dec 11, 2025 License: MIT Imports: 7 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 {
	// contains filtered or unexported fields
}

func NewClient

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

func (*Client) CreateRecord

func (c *Client) CreateRecord(req *CreateRecordRequest) (*CreateRecordResponse, error)

func (*Client) CreateRecordWithContext

func (c *Client) CreateRecordWithContext(ctx context.Context, req *CreateRecordRequest) (*CreateRecordResponse, error)

func (*Client) DeleteRecord

func (c *Client) DeleteRecord(recordId string) (*DeleteRecordResponse, error)

func (*Client) DeleteRecordWithContext

func (c *Client) DeleteRecordWithContext(ctx context.Context, recordId string) (*DeleteRecordResponse, error)

func (*Client) ListDomains

func (c *Client) ListDomains(req *ListDomainsRequest) (*ListDomainsResponse, error)

func (*Client) ListDomainsWithContext

func (c *Client) ListDomainsWithContext(ctx context.Context, req *ListDomainsRequest) (*ListDomainsResponse, error)

func (*Client) ListRecords

func (c *Client) ListRecords(req *ListRecordsRequest) (*ListRecordsResponse, error)

func (*Client) ListRecordsWithContext

func (c *Client) ListRecordsWithContext(ctx context.Context, req *ListRecordsRequest) (*ListRecordsResponse, error)

func (*Client) SetTimeout

func (c *Client) SetTimeout(timeout time.Duration) *Client

func (*Client) UpdateRecord

func (c *Client) UpdateRecord(req *UpdateRecordRequest) (*UpdateRecordResponse, error)

func (*Client) UpdateRecordWithContext

func (c *Client) UpdateRecordWithContext(ctx context.Context, req *UpdateRecordRequest) (*UpdateRecordResponse, error)

type CreateRecordRequest

type CreateRecordRequest struct {
	DomainId   *string `json:"domainId"`
	GroupId    *string `json:"groupId,omitempty"`
	LineId     *string `json:"lineId,omitempty"`
	Type       *int32  `json:"type"`
	Host       *string `json:"host"`
	Data       *string `json:"data"`
	Ttl        *int32  `json:"ttl"`
	Weight     *int32  `json:"weight,omitempty"`
	Preference *int32  `json:"preference,omitempty"`
}

type CreateRecordResponse

type CreateRecordResponse struct {
	Data *struct {
		Id string `json:"id"`
	} `json:"data,omitempty"`
	// contains filtered or unexported fields
}

func (*CreateRecordResponse) GetCode

func (r *CreateRecordResponse) GetCode() int32

func (*CreateRecordResponse) GetMessage

func (r *CreateRecordResponse) GetMessage() string

type DeleteRecordResponse

type DeleteRecordResponse struct {
	// contains filtered or unexported fields
}

func (*DeleteRecordResponse) GetCode

func (r *DeleteRecordResponse) GetCode() int32

func (*DeleteRecordResponse) GetMessage

func (r *DeleteRecordResponse) GetMessage() string

type DnsRecord

type DnsRecord struct {
	Id          string `json:"id"`
	DomainId    string `json:"domainId"`
	GroupId     string `json:"groupId"`
	GroupName   string `json:"groupName"`
	LineId      string `json:"lineId"`
	LineCode    string `json:"lineCode"`
	LineName    string `json:"lineName"`
	Type        int32  `json:"type"`
	Host        string `json:"host"`
	DisplayHost string `json:"displayHost"`
	Data        string `json:"data"`
	DisplayData string `json:"displayData"`
	Ttl         int32  `json:"ttl"`
	Weight      int32  `json:"weight"`
	Preference  int32  `json:"preference"`
	CreatedAt   int64  `json:"createdAt"`
	UpdatedAt   int64  `json:"updatedAt"`
}

type DomainRecord

type DomainRecord struct {
	Id            string `json:"id"`
	GroupId       string `json:"groupId"`
	GroupName     string `json:"groupName"`
	Domain        string `json:"domain"`
	DisplayDomain string `json:"displayDomain"`
	CreatedAt     int64  `json:"createdAt"`
	UpdatedAt     int64  `json:"updatedAt"`
}

type ListDomainsRequest

type ListDomainsRequest struct {
	GroupId   *string `json:"groupId,omitempty" url:"groupId,omitempty"`
	PageIndex *int32  `json:"pageIndex,omitempty" url:"pageIndex,omitempty"`
	PageSize  *int32  `json:"pageSize,omitempty" url:"pageSize,omitempty"`
}

type ListDomainsResponse

type ListDomainsResponse struct {
	Data *struct {
		Total   int32           `json:"total"`
		Results []*DomainRecord `json:"results"`
	} `json:"data,omitempty"`
	// contains filtered or unexported fields
}

func (*ListDomainsResponse) GetCode

func (r *ListDomainsResponse) GetCode() int32

func (*ListDomainsResponse) GetMessage

func (r *ListDomainsResponse) GetMessage() string

type ListRecordsRequest

type ListRecordsRequest struct {
	DomainId  *string `json:"domainId,omitempty" url:"domainId,omitempty"`
	GroupId   *string `json:"groupId,omitempty" url:"groupId,omitempty"`
	LineId    *string `json:"lineId,omitempty" url:"lineId,omitempty"`
	Type      *int32  `json:"type,omitempty" url:"type,omitempty"`
	Host      *string `json:"host,omitempty" url:"host,omitempty"`
	Data      *string `json:"data,omitempty" url:"data,omitempty"`
	PageIndex *int32  `json:"pageIndex,omitempty" url:"pageIndex,omitempty"`
	PageSize  *int32  `json:"pageSize,omitempty" url:"pageSize,omitempty"`
}

type ListRecordsResponse

type ListRecordsResponse struct {
	Data *struct {
		Total   int32        `json:"total"`
		Results []*DnsRecord `json:"results"`
	} `json:"data,omitempty"`
	// contains filtered or unexported fields
}

func (*ListRecordsResponse) GetCode

func (r *ListRecordsResponse) GetCode() int32

func (*ListRecordsResponse) GetMessage

func (r *ListRecordsResponse) GetMessage() string

type UpdateRecordRequest

type UpdateRecordRequest struct {
	Id         *string `json:"id"`
	GroupId    *string `json:"groupId,omitempty"`
	LineId     *string `json:"lineId,omitempty"`
	Type       *int32  `json:"type,omitempty"`
	Host       *string `json:"host,omitempty"`
	Data       *string `json:"data,omitempty"`
	Ttl        *int32  `json:"ttl,omitempty"`
	Weight     *int32  `json:"weight,omitempty"`
	Preference *int32  `json:"preference,omitempty"`
}

type UpdateRecordResponse

type UpdateRecordResponse struct {
	// contains filtered or unexported fields
}

func (*UpdateRecordResponse) GetCode

func (r *UpdateRecordResponse) GetCode() int32

func (*UpdateRecordResponse) GetMessage

func (r *UpdateRecordResponse) GetMessage() string

Jump to

Keyboard shortcuts

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