mirror of
https://github.com/psviderski/uncloud.git
synced 2026-08-26 11:03:34 +00:00
This runs: ``` go run golang.org/x/tools/gopls/internal/analysis/modernize/cmd/modernize@latest -fix ./... ``` over the codebase, as this is using go 1.26, it can also use the new new() functionallity so AsPtr and boolPtr is are needed anymore. Signed-off-by: Miek Gieben <miek@miek.nl>
35 lines
712 B
Go
35 lines
712 B
Go
package dns
|
|
|
|
const (
|
|
RecordTypeA RecordType = "A"
|
|
RecordTypeAAAA RecordType = "AAAA"
|
|
)
|
|
|
|
type RecordType string
|
|
|
|
type DomainResponse struct {
|
|
Name string `json:"name,omitempty"`
|
|
Token string `json:"token,omitempty"`
|
|
}
|
|
|
|
type RecordRequest struct {
|
|
Name string `json:"name,omitempty"`
|
|
Type RecordType `json:"type,omitempty"`
|
|
Values []string `json:"values,omitempty"`
|
|
}
|
|
|
|
type RecordResponse struct {
|
|
RecordRequest
|
|
FQDN string `json:"fqdn,omitempty"`
|
|
}
|
|
|
|
type AuthErrorResponse struct {
|
|
Status int `json:"status,omitempty"`
|
|
Message string `json:"msg,omitempty"`
|
|
Data authErrorData `json:"data"`
|
|
}
|
|
|
|
type authErrorData struct {
|
|
NoDomain bool `json:"noDomain,omitempty"`
|
|
}
|