dns

package
v4.4.0 Latest Latest
Warning

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

Go to latest
Published: May 16, 2025 License: Apache-2.0 Imports: 19 Imported by: 14

Documentation

Index

Constants

View Source
const AuditLogActorTypeAdmin = shared.AuditLogActorTypeAdmin

This is an alias to an internal value.

View Source
const AuditLogActorTypeCloudflare = shared.AuditLogActorTypeCloudflare

This is an alias to an internal value.

View Source
const AuditLogActorTypeUser = shared.AuditLogActorTypeUser

This is an alias to an internal value.

View Source
const CertificateCADigicert = shared.CertificateCADigicert

This is an alias to an internal value.

View Source
const CertificateCAGoogle = shared.CertificateCAGoogle

This is an alias to an internal value.

View Source
const CertificateCALetsEncrypt = shared.CertificateCALetsEncrypt

This is an alias to an internal value.

View Source
const CertificateCASSLCom = shared.CertificateCASSLCom

This is an alias to an internal value.

View Source
const CertificateRequestTypeKeylessCertificate = shared.CertificateRequestTypeKeylessCertificate

This is an alias to an internal value.

View Source
const CertificateRequestTypeOriginECC = shared.CertificateRequestTypeOriginECC

This is an alias to an internal value.

View Source
const CertificateRequestTypeOriginRSA = shared.CertificateRequestTypeOriginRSA

This is an alias to an internal value.

View Source
const CloudflareTunnelStatusDegraded = shared.CloudflareTunnelStatusDegraded

This is an alias to an internal value.

View Source
const CloudflareTunnelStatusDown = shared.CloudflareTunnelStatusDown

This is an alias to an internal value.

View Source
const CloudflareTunnelStatusHealthy = shared.CloudflareTunnelStatusHealthy

This is an alias to an internal value.

View Source
const CloudflareTunnelStatusInactive = shared.CloudflareTunnelStatusInactive

This is an alias to an internal value.

View Source
const CloudflareTunnelTunTypeCNI = shared.CloudflareTunnelTunTypeCNI

This is an alias to an internal value.

View Source
const CloudflareTunnelTunTypeCfdTunnel = shared.CloudflareTunnelTunTypeCfdTunnel

This is an alias to an internal value.

View Source
const CloudflareTunnelTunTypeGRE = shared.CloudflareTunnelTunTypeGRE

This is an alias to an internal value.

View Source
const CloudflareTunnelTunTypeIPSec = shared.CloudflareTunnelTunTypeIPSec

This is an alias to an internal value.

View Source
const CloudflareTunnelTunTypeMagic = shared.CloudflareTunnelTunTypeMagic

This is an alias to an internal value.

View Source
const CloudflareTunnelTunTypeWARP = shared.CloudflareTunnelTunTypeWARP

This is an alias to an internal value.

View Source
const CloudflareTunnelTunTypeWARPConnector = shared.CloudflareTunnelTunTypeWARPConnector

This is an alias to an internal value.

View Source
const MemberPoliciesAccessAllow = shared.MemberPoliciesAccessAllow

This is an alias to an internal value.

View Source
const MemberPoliciesAccessDeny = shared.MemberPoliciesAccessDeny

This is an alias to an internal value.

View Source
const MemberStatusAccepted = shared.MemberStatusAccepted

This is an alias to an internal value.

View Source
const MemberStatusPending = shared.MemberStatusPending

This is an alias to an internal value.

View Source
const RatePlanIDBusiness = shared.RatePlanIDBusiness

This is an alias to an internal value.

View Source
const RatePlanIDEnterprise = shared.RatePlanIDEnterprise

This is an alias to an internal value.

View Source
const RatePlanIDFree = shared.RatePlanIDFree

This is an alias to an internal value.

View Source
const RatePlanIDLite = shared.RatePlanIDLite

This is an alias to an internal value.

View Source
const RatePlanIDPartnersBusiness = shared.RatePlanIDPartnersBusiness

This is an alias to an internal value.

View Source
const RatePlanIDPartnersEnterprise = shared.RatePlanIDPartnersEnterprise

This is an alias to an internal value.

View Source
const RatePlanIDPartnersFree = shared.RatePlanIDPartnersFree

This is an alias to an internal value.

View Source
const RatePlanIDPartnersPro = shared.RatePlanIDPartnersPro

This is an alias to an internal value.

View Source
const RatePlanIDPro = shared.RatePlanIDPro

This is an alias to an internal value.

View Source
const RatePlanIDProPlus = shared.RatePlanIDProPlus

This is an alias to an internal value.

View Source
const SortDirectionAsc = shared.SortDirectionAsc

This is an alias to an internal value.

View Source
const SortDirectionDesc = shared.SortDirectionDesc

This is an alias to an internal value.

View Source
const SubscriptionFrequencyMonthly = shared.SubscriptionFrequencyMonthly

This is an alias to an internal value.

View Source
const SubscriptionFrequencyQuarterly = shared.SubscriptionFrequencyQuarterly

This is an alias to an internal value.

View Source
const SubscriptionFrequencyWeekly = shared.SubscriptionFrequencyWeekly

This is an alias to an internal value.

View Source
const SubscriptionFrequencyYearly = shared.SubscriptionFrequencyYearly

This is an alias to an internal value.

View Source
const SubscriptionStateAwaitingPayment = shared.SubscriptionStateAwaitingPayment

This is an alias to an internal value.

View Source
const SubscriptionStateCancelled = shared.SubscriptionStateCancelled

This is an alias to an internal value.

View Source
const SubscriptionStateExpired = shared.SubscriptionStateExpired

This is an alias to an internal value.

View Source
const SubscriptionStateFailed = shared.SubscriptionStateFailed

This is an alias to an internal value.

View Source
const SubscriptionStatePaid = shared.SubscriptionStatePaid

This is an alias to an internal value.

View Source
const SubscriptionStateProvisioned = shared.SubscriptionStateProvisioned

This is an alias to an internal value.

View Source
const SubscriptionStateTrial = shared.SubscriptionStateTrial

This is an alias to an internal value.

View Source
const TokenPolicyEffectAllow = shared.TokenPolicyEffectAllow

This is an alias to an internal value.

View Source
const TokenPolicyEffectDeny = shared.TokenPolicyEffectDeny

This is an alias to an internal value.

View Source
const TokenStatusActive = shared.TokenStatusActive

This is an alias to an internal value.

View Source
const TokenStatusDisabled = shared.TokenStatusDisabled

This is an alias to an internal value.

View Source
const TokenStatusExpired = shared.TokenStatusExpired

This is an alias to an internal value.

Variables

This section is empty.

Functions

This section is empty.

Types

type AAAARecord

type AAAARecord struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment string `json:"comment"`
	// A valid IPv6 address.
	Content string `json:"content" format:"ipv6"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name string `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied bool `json:"proxied"`
	// Settings for the DNS record.
	Settings AAAARecordSettings `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags []RecordTags `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL TTL `json:"ttl"`
	// Record type.
	Type AAAARecordType `json:"type"`
	JSON aaaaRecordJSON `json:"-"`
}

func (*AAAARecord) UnmarshalJSON

func (r *AAAARecord) UnmarshalJSON(data []byte) (err error)

type AAAARecordParam

type AAAARecordParam struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// A valid IPv6 address.
	Content param.Field[string] `json:"content" format:"ipv6"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `json:"proxied"`
	// Settings for the DNS record.
	Settings param.Field[AAAARecordSettingsParam] `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags param.Field[[]RecordTagsParam] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
	// Record type.
	Type param.Field[AAAARecordType] `json:"type"`
}

func (AAAARecordParam) MarshalJSON

func (r AAAARecordParam) MarshalJSON() (data []byte, err error)

type AAAARecordSettings

type AAAARecordSettings struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only bool `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only bool                   `json:"ipv6_only"`
	JSON     aaaaRecordSettingsJSON `json:"-"`
}

Settings for the DNS record.

func (*AAAARecordSettings) UnmarshalJSON

func (r *AAAARecordSettings) UnmarshalJSON(data []byte) (err error)

type AAAARecordSettingsParam

type AAAARecordSettingsParam struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only param.Field[bool] `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only param.Field[bool] `json:"ipv6_only"`
}

Settings for the DNS record.

func (AAAARecordSettingsParam) MarshalJSON

func (r AAAARecordSettingsParam) MarshalJSON() (data []byte, err error)

type AAAARecordType

type AAAARecordType string

Record type.

const (
	AAAARecordTypeAAAA AAAARecordType = "AAAA"
)

func (AAAARecordType) IsKnown

func (r AAAARecordType) IsKnown() bool

type ACL

type ACL struct {
	ID string `json:"id,required"`
	// Allowed IPv4/IPv6 address range of primary or secondary nameservers. This will
	// be applied for the entire account. The IP range is used to allow additional
	// NOTIFY IPs for secondary zones and IPs Cloudflare allows AXFR/IXFR requests from
	// for primary zones. CIDRs are limited to a maximum of /24 for IPv4 and /64 for
	// IPv6 respectively.
	IPRange string `json:"ip_range,required"`
	// The name of the acl.
	Name string  `json:"name,required"`
	JSON aclJSON `json:"-"`
}

func (*ACL) UnmarshalJSON

func (r *ACL) UnmarshalJSON(data []byte) (err error)

type ACLParam

type ACLParam struct {
	// Allowed IPv4/IPv6 address range of primary or secondary nameservers. This will
	// be applied for the entire account. The IP range is used to allow additional
	// NOTIFY IPs for secondary zones and IPs Cloudflare allows AXFR/IXFR requests from
	// for primary zones. CIDRs are limited to a maximum of /24 for IPv4 and /64 for
	// IPv6 respectively.
	IPRange param.Field[string] `json:"ip_range,required"`
	// The name of the acl.
	Name param.Field[string] `json:"name,required"`
}

func (ACLParam) MarshalJSON

func (r ACLParam) MarshalJSON() (data []byte, err error)

type ARecord

type ARecord struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment string `json:"comment"`
	// A valid IPv4 address.
	Content string `json:"content" format:"ipv4"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name string `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied bool `json:"proxied"`
	// Settings for the DNS record.
	Settings ARecordSettings `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags []RecordTags `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL TTL `json:"ttl"`
	// Record type.
	Type ARecordType `json:"type"`
	JSON aRecordJSON `json:"-"`
}

func (*ARecord) UnmarshalJSON

func (r *ARecord) UnmarshalJSON(data []byte) (err error)

type ARecordParam

type ARecordParam struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// A valid IPv4 address.
	Content param.Field[string] `json:"content" format:"ipv4"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `json:"proxied"`
	// Settings for the DNS record.
	Settings param.Field[ARecordSettingsParam] `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags param.Field[[]RecordTagsParam] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
	// Record type.
	Type param.Field[ARecordType] `json:"type"`
}

func (ARecordParam) MarshalJSON

func (r ARecordParam) MarshalJSON() (data []byte, err error)

type ARecordSettings

type ARecordSettings struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only bool `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only bool                `json:"ipv6_only"`
	JSON     aRecordSettingsJSON `json:"-"`
}

Settings for the DNS record.

func (*ARecordSettings) UnmarshalJSON

func (r *ARecordSettings) UnmarshalJSON(data []byte) (err error)

type ARecordSettingsParam

type ARecordSettingsParam struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only param.Field[bool] `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only param.Field[bool] `json:"ipv6_only"`
}

Settings for the DNS record.

func (ARecordSettingsParam) MarshalJSON

func (r ARecordSettingsParam) MarshalJSON() (data []byte, err error)

type ARecordType

type ARecordType string

Record type.

const (
	ARecordTypeA ARecordType = "A"
)

func (ARecordType) IsKnown

func (r ARecordType) IsKnown() bool

type ASN

type ASN = shared.ASN

This is an alias to an internal type.

type ASNParam

type ASNParam = shared.ASNParam

This is an alias to an internal type.

type AnalyticsReportBytimeGetParams

type AnalyticsReportBytimeGetParams struct {
	// Identifier
	ZoneID param.Field[string] `path:"zone_id,required"`
	// A comma-separated list of dimensions to group results by.
	Dimensions param.Field[string] `query:"dimensions"`
	// Segmentation filter in 'attribute operator value' format.
	Filters param.Field[string] `query:"filters"`
	// Limit number of returned metrics.
	Limit param.Field[int64] `query:"limit"`
	// A comma-separated list of metrics to query.
	Metrics param.Field[string] `query:"metrics"`
	// Start date and time of requesting data period in ISO 8601 format.
	Since param.Field[time.Time] `query:"since" format:"date-time"`
	// A comma-separated list of dimensions to sort by, where each dimension may be
	// prefixed by - (descending) or + (ascending).
	Sort param.Field[string] `query:"sort"`
	// Unit of time to group data by.
	TimeDelta param.Field[AnalyticsReportBytimeGetParamsTimeDelta] `query:"time_delta"`
	// End date and time of requesting data period in ISO 8601 format.
	Until param.Field[time.Time] `query:"until" format:"date-time"`
}

func (AnalyticsReportBytimeGetParams) URLQuery

func (r AnalyticsReportBytimeGetParams) URLQuery() (v url.Values)

URLQuery serializes AnalyticsReportBytimeGetParams's query parameters as `url.Values`.

type AnalyticsReportBytimeGetParamsTimeDelta

type AnalyticsReportBytimeGetParamsTimeDelta string

Unit of time to group data by.

const (
	AnalyticsReportBytimeGetParamsTimeDeltaAll        AnalyticsReportBytimeGetParamsTimeDelta = "all"
	AnalyticsReportBytimeGetParamsTimeDeltaAuto       AnalyticsReportBytimeGetParamsTimeDelta = "auto"
	AnalyticsReportBytimeGetParamsTimeDeltaYear       AnalyticsReportBytimeGetParamsTimeDelta = "year"
	AnalyticsReportBytimeGetParamsTimeDeltaQuarter    AnalyticsReportBytimeGetParamsTimeDelta = "quarter"
	AnalyticsReportBytimeGetParamsTimeDeltaMonth      AnalyticsReportBytimeGetParamsTimeDelta = "month"
	AnalyticsReportBytimeGetParamsTimeDeltaWeek       AnalyticsReportBytimeGetParamsTimeDelta = "week"
	AnalyticsReportBytimeGetParamsTimeDeltaDay        AnalyticsReportBytimeGetParamsTimeDelta = "day"
	AnalyticsReportBytimeGetParamsTimeDeltaHour       AnalyticsReportBytimeGetParamsTimeDelta = "hour"
	AnalyticsReportBytimeGetParamsTimeDeltaDekaminute AnalyticsReportBytimeGetParamsTimeDelta = "dekaminute"
	AnalyticsReportBytimeGetParamsTimeDeltaMinute     AnalyticsReportBytimeGetParamsTimeDelta = "minute"
)

func (AnalyticsReportBytimeGetParamsTimeDelta) IsKnown

type AnalyticsReportBytimeGetResponseEnvelope

type AnalyticsReportBytimeGetResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success AnalyticsReportBytimeGetResponseEnvelopeSuccess `json:"success,required"`
	Result  ByTime                                          `json:"result"`
	JSON    analyticsReportBytimeGetResponseEnvelopeJSON    `json:"-"`
}

func (*AnalyticsReportBytimeGetResponseEnvelope) UnmarshalJSON

func (r *AnalyticsReportBytimeGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type AnalyticsReportBytimeGetResponseEnvelopeSuccess

type AnalyticsReportBytimeGetResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	AnalyticsReportBytimeGetResponseEnvelopeSuccessTrue AnalyticsReportBytimeGetResponseEnvelopeSuccess = true
)

func (AnalyticsReportBytimeGetResponseEnvelopeSuccess) IsKnown

type AnalyticsReportBytimeService

type AnalyticsReportBytimeService struct {
	Options []option.RequestOption
}

AnalyticsReportBytimeService contains methods and other services that help with interacting with the cloudflare API.

Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewAnalyticsReportBytimeService method instead.

func NewAnalyticsReportBytimeService

func NewAnalyticsReportBytimeService(opts ...option.RequestOption) (r *AnalyticsReportBytimeService)

NewAnalyticsReportBytimeService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*AnalyticsReportBytimeService) Get

Retrieves a list of aggregate metrics grouped by time interval.

See [Analytics API properties](https://developers.cloudflare.com/dns/reference/analytics-api-properties/) for detailed information about the available query parameters.

type AnalyticsReportGetParams

type AnalyticsReportGetParams struct {
	// Identifier
	ZoneID param.Field[string] `path:"zone_id,required"`
	// A comma-separated list of dimensions to group results by.
	Dimensions param.Field[string] `query:"dimensions"`
	// Segmentation filter in 'attribute operator value' format.
	Filters param.Field[string] `query:"filters"`
	// Limit number of returned metrics.
	Limit param.Field[int64] `query:"limit"`
	// A comma-separated list of metrics to query.
	Metrics param.Field[string] `query:"metrics"`
	// Start date and time of requesting data period in ISO 8601 format.
	Since param.Field[time.Time] `query:"since" format:"date-time"`
	// A comma-separated list of dimensions to sort by, where each dimension may be
	// prefixed by - (descending) or + (ascending).
	Sort param.Field[string] `query:"sort"`
	// End date and time of requesting data period in ISO 8601 format.
	Until param.Field[time.Time] `query:"until" format:"date-time"`
}

func (AnalyticsReportGetParams) URLQuery

func (r AnalyticsReportGetParams) URLQuery() (v url.Values)

URLQuery serializes AnalyticsReportGetParams's query parameters as `url.Values`.

type AnalyticsReportGetResponseEnvelope

type AnalyticsReportGetResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success AnalyticsReportGetResponseEnvelopeSuccess `json:"success,required"`
	Result  Report                                    `json:"result"`
	JSON    analyticsReportGetResponseEnvelopeJSON    `json:"-"`
}

func (*AnalyticsReportGetResponseEnvelope) UnmarshalJSON

func (r *AnalyticsReportGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type AnalyticsReportGetResponseEnvelopeSuccess

type AnalyticsReportGetResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	AnalyticsReportGetResponseEnvelopeSuccessTrue AnalyticsReportGetResponseEnvelopeSuccess = true
)

func (AnalyticsReportGetResponseEnvelopeSuccess) IsKnown

type AnalyticsReportService

type AnalyticsReportService struct {
	Options []option.RequestOption
	Bytimes *AnalyticsReportBytimeService
}

AnalyticsReportService contains methods and other services that help with interacting with the cloudflare API.

Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewAnalyticsReportService method instead.

func NewAnalyticsReportService

func NewAnalyticsReportService(opts ...option.RequestOption) (r *AnalyticsReportService)

NewAnalyticsReportService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*AnalyticsReportService) Get

Retrieves a list of summarised aggregate metrics over a given time period.

See [Analytics API properties](https://developers.cloudflare.com/dns/reference/analytics-api-properties/) for detailed information about the available query parameters.

type AnalyticsService

type AnalyticsService struct {
	Options []option.RequestOption
	Reports *AnalyticsReportService
}

AnalyticsService contains methods and other services that help with interacting with the cloudflare API.

Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewAnalyticsService method instead.

func NewAnalyticsService

func NewAnalyticsService(opts ...option.RequestOption) (r *AnalyticsService)

NewAnalyticsService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

type AuditLog

type AuditLog = shared.AuditLog

This is an alias to an internal type.

type AuditLogAction

type AuditLogAction = shared.AuditLogAction

This is an alias to an internal type.

type AuditLogActor

type AuditLogActor = shared.AuditLogActor

This is an alias to an internal type.

type AuditLogActorType

type AuditLogActorType = shared.AuditLogActorType

The type of actor, whether a User, Cloudflare Admin, or an Automated System.

This is an alias to an internal type.

type AuditLogOwner

type AuditLogOwner = shared.AuditLogOwner

This is an alias to an internal type.

type AuditLogResource

type AuditLogResource = shared.AuditLogResource

This is an alias to an internal type.

type BatchPatchAAAAParam added in v4.2.0

type BatchPatchAAAAParam struct {
	// Identifier.
	ID param.Field[string] `json:"id,required"`
	AAAARecordParam
}

func (BatchPatchAAAAParam) MarshalJSON added in v4.2.0

func (r BatchPatchAAAAParam) MarshalJSON() (data []byte, err error)

type BatchPatchAParam added in v4.2.0

type BatchPatchAParam struct {
	// Identifier.
	ID param.Field[string] `json:"id,required"`
	ARecordParam
}

func (BatchPatchAParam) MarshalJSON added in v4.2.0

func (r BatchPatchAParam) MarshalJSON() (data []byte, err error)

type BatchPatchCAAParam added in v4.2.0

type BatchPatchCAAParam struct {
	// Identifier.
	ID param.Field[string] `json:"id,required"`
	CAARecordParam
}

func (BatchPatchCAAParam) MarshalJSON added in v4.2.0

func (r BatchPatchCAAParam) MarshalJSON() (data []byte, err error)

type BatchPatchCERTParam added in v4.2.0

type BatchPatchCERTParam struct {
	// Identifier.
	ID param.Field[string] `json:"id,required"`
	CERTRecordParam
}

func (BatchPatchCERTParam) MarshalJSON added in v4.2.0

func (r BatchPatchCERTParam) MarshalJSON() (data []byte, err error)

type BatchPatchCNAMEParam added in v4.2.0

type BatchPatchCNAMEParam struct {
	// Identifier.
	ID param.Field[string] `json:"id,required"`
	CNAMERecordParam
}

func (BatchPatchCNAMEParam) MarshalJSON added in v4.2.0

func (r BatchPatchCNAMEParam) MarshalJSON() (data []byte, err error)

type BatchPatchDNSKEYParam added in v4.2.0

type BatchPatchDNSKEYParam struct {
	// Identifier.
	ID param.Field[string] `json:"id,required"`
	DNSKEYRecordParam
}

func (BatchPatchDNSKEYParam) MarshalJSON added in v4.2.0

func (r BatchPatchDNSKEYParam) MarshalJSON() (data []byte, err error)

type BatchPatchDSParam added in v4.2.0

type BatchPatchDSParam struct {
	// Identifier.
	ID param.Field[string] `json:"id,required"`
	DSRecordParam
}

func (BatchPatchDSParam) MarshalJSON added in v4.2.0

func (r BatchPatchDSParam) MarshalJSON() (data []byte, err error)

type BatchPatchHTTPSParam added in v4.2.0

type BatchPatchHTTPSParam struct {
	// Identifier.
	ID param.Field[string] `json:"id,required"`
	HTTPSRecordParam
}

func (BatchPatchHTTPSParam) MarshalJSON added in v4.2.0

func (r BatchPatchHTTPSParam) MarshalJSON() (data []byte, err error)

type BatchPatchLOCParam added in v4.2.0

type BatchPatchLOCParam struct {
	// Identifier.
	ID param.Field[string] `json:"id,required"`
	LOCRecordParam
}

func (BatchPatchLOCParam) MarshalJSON added in v4.2.0

func (r BatchPatchLOCParam) MarshalJSON() (data []byte, err error)

type BatchPatchMXParam added in v4.2.0

type BatchPatchMXParam struct {
	// Identifier.
	ID param.Field[string] `json:"id,required"`
	MXRecordParam
}

func (BatchPatchMXParam) MarshalJSON added in v4.2.0

func (r BatchPatchMXParam) MarshalJSON() (data []byte, err error)

type BatchPatchNAPTRParam added in v4.2.0

type BatchPatchNAPTRParam struct {
	// Identifier.
	ID param.Field[string] `json:"id,required"`
	NAPTRRecordParam
}

func (BatchPatchNAPTRParam) MarshalJSON added in v4.2.0

func (r BatchPatchNAPTRParam) MarshalJSON() (data []byte, err error)

type BatchPatchNSParam added in v4.2.0

type BatchPatchNSParam struct {
	// Identifier.
	ID param.Field[string] `json:"id,required"`
	NSRecordParam
}

func (BatchPatchNSParam) MarshalJSON added in v4.2.0

func (r BatchPatchNSParam) MarshalJSON() (data []byte, err error)

type BatchPatchOpenpgpkeyParam

type BatchPatchOpenpgpkeyParam struct {
	// Identifier.
	ID param.Field[string] `json:"id,required"`
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// A single Base64-encoded OpenPGP Transferable Public Key (RFC 4880 Section 11.1)
	Content param.Field[string] `json:"content"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `json:"proxied"`
	// Settings for the DNS record.
	Settings param.Field[BatchPatchOpenpgpkeySettingsParam] `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags param.Field[[]RecordTagsParam] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
	// Record type.
	Type param.Field[BatchPatchOpenpgpkeyType] `json:"type"`
}

func (BatchPatchOpenpgpkeyParam) MarshalJSON

func (r BatchPatchOpenpgpkeyParam) MarshalJSON() (data []byte, err error)

type BatchPatchOpenpgpkeySettingsParam

type BatchPatchOpenpgpkeySettingsParam struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only param.Field[bool] `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only param.Field[bool] `json:"ipv6_only"`
}

Settings for the DNS record.

func (BatchPatchOpenpgpkeySettingsParam) MarshalJSON

func (r BatchPatchOpenpgpkeySettingsParam) MarshalJSON() (data []byte, err error)

type BatchPatchOpenpgpkeyType

type BatchPatchOpenpgpkeyType string

Record type.

const (
	BatchPatchOpenpgpkeyTypeOpenpgpkey BatchPatchOpenpgpkeyType = "OPENPGPKEY"
)

func (BatchPatchOpenpgpkeyType) IsKnown

func (r BatchPatchOpenpgpkeyType) IsKnown() bool

type BatchPatchPTRParam added in v4.2.0

type BatchPatchPTRParam struct {
	// Identifier.
	ID param.Field[string] `json:"id,required"`
	PTRRecordParam
}

func (BatchPatchPTRParam) MarshalJSON added in v4.2.0

func (r BatchPatchPTRParam) MarshalJSON() (data []byte, err error)

type BatchPatchSMIMEAParam added in v4.2.0

type BatchPatchSMIMEAParam struct {
	// Identifier.
	ID param.Field[string] `json:"id,required"`
	SMIMEARecordParam
}

func (BatchPatchSMIMEAParam) MarshalJSON added in v4.2.0

func (r BatchPatchSMIMEAParam) MarshalJSON() (data []byte, err error)

type BatchPatchSRVParam added in v4.2.0

type BatchPatchSRVParam struct {
	// Identifier.
	ID param.Field[string] `json:"id,required"`
	SRVRecordParam
}

func (BatchPatchSRVParam) MarshalJSON added in v4.2.0

func (r BatchPatchSRVParam) MarshalJSON() (data []byte, err error)

type BatchPatchSSHFPParam added in v4.2.0

type BatchPatchSSHFPParam struct {
	// Identifier.
	ID param.Field[string] `json:"id,required"`
	SSHFPRecordParam
}

func (BatchPatchSSHFPParam) MarshalJSON added in v4.2.0

func (r BatchPatchSSHFPParam) MarshalJSON() (data []byte, err error)

type BatchPatchSVCBParam added in v4.2.0

type BatchPatchSVCBParam struct {
	// Identifier.
	ID param.Field[string] `json:"id,required"`
	SVCBRecordParam
}

func (BatchPatchSVCBParam) MarshalJSON added in v4.2.0

func (r BatchPatchSVCBParam) MarshalJSON() (data []byte, err error)

type BatchPatchTLSAParam added in v4.2.0

type BatchPatchTLSAParam struct {
	// Identifier.
	ID param.Field[string] `json:"id,required"`
	TLSARecordParam
}

func (BatchPatchTLSAParam) MarshalJSON added in v4.2.0

func (r BatchPatchTLSAParam) MarshalJSON() (data []byte, err error)

type BatchPatchTXTParam added in v4.2.0

type BatchPatchTXTParam struct {
	// Identifier.
	ID param.Field[string] `json:"id,required"`
	TXTRecordParam
}

func (BatchPatchTXTParam) MarshalJSON added in v4.2.0

func (r BatchPatchTXTParam) MarshalJSON() (data []byte, err error)

type BatchPatchURIParam added in v4.2.0

type BatchPatchURIParam struct {
	// Identifier.
	ID param.Field[string] `json:"id,required"`
	URIRecordParam
}

func (BatchPatchURIParam) MarshalJSON added in v4.2.0

func (r BatchPatchURIParam) MarshalJSON() (data []byte, err error)

type BatchPutAAAAParam added in v4.2.0

type BatchPutAAAAParam struct {
	// Identifier.
	ID param.Field[string] `json:"id"`
	AAAARecordParam
}

func (BatchPutAAAAParam) MarshalJSON added in v4.2.0

func (r BatchPutAAAAParam) MarshalJSON() (data []byte, err error)

type BatchPutAParam added in v4.2.0

type BatchPutAParam struct {
	// Identifier.
	ID param.Field[string] `json:"id"`
	ARecordParam
}

func (BatchPutAParam) MarshalJSON added in v4.2.0

func (r BatchPutAParam) MarshalJSON() (data []byte, err error)

type BatchPutCAAParam added in v4.2.0

type BatchPutCAAParam struct {
	// Identifier.
	ID param.Field[string] `json:"id"`
	CAARecordParam
}

func (BatchPutCAAParam) MarshalJSON added in v4.2.0

func (r BatchPutCAAParam) MarshalJSON() (data []byte, err error)

type BatchPutCERTParam added in v4.2.0

type BatchPutCERTParam struct {
	// Identifier.
	ID param.Field[string] `json:"id"`
	CERTRecordParam
}

func (BatchPutCERTParam) MarshalJSON added in v4.2.0

func (r BatchPutCERTParam) MarshalJSON() (data []byte, err error)

type BatchPutCNAMEParam added in v4.2.0

type BatchPutCNAMEParam struct {
	// Identifier.
	ID param.Field[string] `json:"id"`
	CNAMERecordParam
}

func (BatchPutCNAMEParam) MarshalJSON added in v4.2.0

func (r BatchPutCNAMEParam) MarshalJSON() (data []byte, err error)

type BatchPutDNSKEYParam added in v4.2.0

type BatchPutDNSKEYParam struct {
	// Identifier.
	ID param.Field[string] `json:"id"`
	DNSKEYRecordParam
}

func (BatchPutDNSKEYParam) MarshalJSON added in v4.2.0

func (r BatchPutDNSKEYParam) MarshalJSON() (data []byte, err error)

type BatchPutDSParam added in v4.2.0

type BatchPutDSParam struct {
	// Identifier.
	ID param.Field[string] `json:"id"`
	DSRecordParam
}

func (BatchPutDSParam) MarshalJSON added in v4.2.0

func (r BatchPutDSParam) MarshalJSON() (data []byte, err error)

type BatchPutHTTPSParam added in v4.2.0

type BatchPutHTTPSParam struct {
	// Identifier.
	ID param.Field[string] `json:"id"`
	HTTPSRecordParam
}

func (BatchPutHTTPSParam) MarshalJSON added in v4.2.0

func (r BatchPutHTTPSParam) MarshalJSON() (data []byte, err error)

type BatchPutLOCParam added in v4.2.0

type BatchPutLOCParam struct {
	// Identifier.
	ID param.Field[string] `json:"id"`
	LOCRecordParam
}

func (BatchPutLOCParam) MarshalJSON added in v4.2.0

func (r BatchPutLOCParam) MarshalJSON() (data []byte, err error)

type BatchPutMXParam added in v4.2.0

type BatchPutMXParam struct {
	// Identifier.
	ID param.Field[string] `json:"id"`
	MXRecordParam
}

func (BatchPutMXParam) MarshalJSON added in v4.2.0

func (r BatchPutMXParam) MarshalJSON() (data []byte, err error)

type BatchPutNAPTRParam added in v4.2.0

type BatchPutNAPTRParam struct {
	// Identifier.
	ID param.Field[string] `json:"id"`
	NAPTRRecordParam
}

func (BatchPutNAPTRParam) MarshalJSON added in v4.2.0

func (r BatchPutNAPTRParam) MarshalJSON() (data []byte, err error)

type BatchPutNSParam added in v4.2.0

type BatchPutNSParam struct {
	// Identifier.
	ID param.Field[string] `json:"id"`
	NSRecordParam
}

func (BatchPutNSParam) MarshalJSON added in v4.2.0

func (r BatchPutNSParam) MarshalJSON() (data []byte, err error)

type BatchPutOpenpgpkeyParam

type BatchPutOpenpgpkeyParam struct {
	// A single Base64-encoded OpenPGP Transferable Public Key (RFC 4880 Section 11.1)
	Content param.Field[string] `json:"content,required"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name,required"`
	// Record type.
	Type param.Field[BatchPutOpenpgpkeyType] `json:"type,required"`
	// Identifier.
	ID param.Field[string] `json:"id"`
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `json:"proxied"`
	// Settings for the DNS record.
	Settings param.Field[BatchPutOpenpgpkeySettingsParam] `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags param.Field[[]RecordTagsParam] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
}

func (BatchPutOpenpgpkeyParam) MarshalJSON

func (r BatchPutOpenpgpkeyParam) MarshalJSON() (data []byte, err error)

type BatchPutOpenpgpkeySettingsParam

type BatchPutOpenpgpkeySettingsParam struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only param.Field[bool] `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only param.Field[bool] `json:"ipv6_only"`
}

Settings for the DNS record.

func (BatchPutOpenpgpkeySettingsParam) MarshalJSON

func (r BatchPutOpenpgpkeySettingsParam) MarshalJSON() (data []byte, err error)

type BatchPutOpenpgpkeyType

type BatchPutOpenpgpkeyType string

Record type.

const (
	BatchPutOpenpgpkeyTypeOpenpgpkey BatchPutOpenpgpkeyType = "OPENPGPKEY"
)

func (BatchPutOpenpgpkeyType) IsKnown

func (r BatchPutOpenpgpkeyType) IsKnown() bool

type BatchPutPTRParam added in v4.2.0

type BatchPutPTRParam struct {
	// Identifier.
	ID param.Field[string] `json:"id"`
	PTRRecordParam
}

func (BatchPutPTRParam) MarshalJSON added in v4.2.0

func (r BatchPutPTRParam) MarshalJSON() (data []byte, err error)

type BatchPutSMIMEAParam added in v4.2.0

type BatchPutSMIMEAParam struct {
	// Identifier.
	ID param.Field[string] `json:"id"`
	SMIMEARecordParam
}

func (BatchPutSMIMEAParam) MarshalJSON added in v4.2.0

func (r BatchPutSMIMEAParam) MarshalJSON() (data []byte, err error)

type BatchPutSRVParam added in v4.2.0

type BatchPutSRVParam struct {
	// Identifier.
	ID param.Field[string] `json:"id"`
	SRVRecordParam
}

func (BatchPutSRVParam) MarshalJSON added in v4.2.0

func (r BatchPutSRVParam) MarshalJSON() (data []byte, err error)

type BatchPutSSHFPParam added in v4.2.0

type BatchPutSSHFPParam struct {
	// Identifier.
	ID param.Field[string] `json:"id"`
	SSHFPRecordParam
}

func (BatchPutSSHFPParam) MarshalJSON added in v4.2.0

func (r BatchPutSSHFPParam) MarshalJSON() (data []byte, err error)

type BatchPutSVCBParam added in v4.2.0

type BatchPutSVCBParam struct {
	// Identifier.
	ID param.Field[string] `json:"id"`
	SVCBRecordParam
}

func (BatchPutSVCBParam) MarshalJSON added in v4.2.0

func (r BatchPutSVCBParam) MarshalJSON() (data []byte, err error)

type BatchPutTLSAParam added in v4.2.0

type BatchPutTLSAParam struct {
	// Identifier.
	ID param.Field[string] `json:"id"`
	TLSARecordParam
}

func (BatchPutTLSAParam) MarshalJSON added in v4.2.0

func (r BatchPutTLSAParam) MarshalJSON() (data []byte, err error)

type BatchPutTXTParam added in v4.2.0

type BatchPutTXTParam struct {
	// Identifier.
	ID param.Field[string] `json:"id"`
	TXTRecordParam
}

func (BatchPutTXTParam) MarshalJSON added in v4.2.0

func (r BatchPutTXTParam) MarshalJSON() (data []byte, err error)

type BatchPutURIParam added in v4.2.0

type BatchPutURIParam struct {
	// Identifier.
	ID param.Field[string] `json:"id"`
	URIRecordParam
}

func (BatchPutURIParam) MarshalJSON added in v4.2.0

func (r BatchPutURIParam) MarshalJSON() (data []byte, err error)

type ByTime

type ByTime struct {
	// Array with one row per combination of dimension values.
	Data []ByTimeData `json:"data,required"`
	// Number of seconds between current time and last processed event, in another
	// words how many seconds of data could be missing.
	DataLag float64 `json:"data_lag,required"`
	// Maximum results for each metric (object mapping metric names to values).
	// Currently always an empty object.
	Max interface{} `json:"max,required"`
	// Minimum results for each metric (object mapping metric names to values).
	// Currently always an empty object.
	Min   interface{}       `json:"min,required"`
	Query DNSAnalyticsQuery `json:"query,required"`
	// Total number of rows in the result.
	Rows float64 `json:"rows,required"`
	// Array of time intervals in the response data. Each interval is represented as an
	// array containing two values: the start time, and the end time.
	TimeIntervals [][]time.Time `json:"time_intervals,required" format:"date-time"`
	// Total results for metrics across all data (object mapping metric names to
	// values).
	Totals interface{} `json:"totals,required"`
	JSON   byTimeJSON  `json:"-"`
}

func (*ByTime) UnmarshalJSON

func (r *ByTime) UnmarshalJSON(data []byte) (err error)

type ByTimeData

type ByTimeData struct {
	// Array of dimension values, representing the combination of dimension values
	// corresponding to this row.
	Dimensions []string `json:"dimensions,required"`
	// Array with one item per requested metric. Each item is an array of values,
	// broken down by time interval.
	Metrics []DNSAnalyticsNominalMetric `json:"metrics,required"`
	JSON    byTimeDataJSON              `json:"-"`
}

func (*ByTimeData) UnmarshalJSON

func (r *ByTimeData) UnmarshalJSON(data []byte) (err error)

type CAARecord

type CAARecord struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment string `json:"comment"`
	// Formatted CAA content. See 'data' to set CAA properties.
	Content string `json:"content"`
	// Components of a CAA record.
	Data CAARecordData `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name string `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied bool `json:"proxied"`
	// Settings for the DNS record.
	Settings CAARecordSettings `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags []RecordTags `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL TTL `json:"ttl"`
	// Record type.
	Type CAARecordType `json:"type"`
	JSON caaRecordJSON `json:"-"`
}

func (*CAARecord) UnmarshalJSON

func (r *CAARecord) UnmarshalJSON(data []byte) (err error)

type CAARecordData

type CAARecordData struct {
	// Flags for the CAA record.
	Flags float64 `json:"flags"`
	// Name of the property controlled by this record (e.g.: issue, issuewild, iodef).
	Tag string `json:"tag"`
	// Value of the record. This field's semantics depend on the chosen tag.
	Value string            `json:"value"`
	JSON  caaRecordDataJSON `json:"-"`
}

Components of a CAA record.

func (*CAARecordData) UnmarshalJSON

func (r *CAARecordData) UnmarshalJSON(data []byte) (err error)

type CAARecordDataParam

type CAARecordDataParam struct {
	// Flags for the CAA record.
	Flags param.Field[float64] `json:"flags"`
	// Name of the property controlled by this record (e.g.: issue, issuewild, iodef).
	Tag param.Field[string] `json:"tag"`
	// Value of the record. This field's semantics depend on the chosen tag.
	Value param.Field[string] `json:"value"`
}

Components of a CAA record.

func (CAARecordDataParam) MarshalJSON

func (r CAARecordDataParam) MarshalJSON() (data []byte, err error)

type CAARecordParam

type CAARecordParam struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// Components of a CAA record.
	Data param.Field[CAARecordDataParam] `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `json:"proxied"`
	// Settings for the DNS record.
	Settings param.Field[CAARecordSettingsParam] `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags param.Field[[]RecordTagsParam] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
	// Record type.
	Type param.Field[CAARecordType] `json:"type"`
}

func (CAARecordParam) MarshalJSON

func (r CAARecordParam) MarshalJSON() (data []byte, err error)

type CAARecordSettings

type CAARecordSettings struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only bool `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only bool                  `json:"ipv6_only"`
	JSON     caaRecordSettingsJSON `json:"-"`
}

Settings for the DNS record.

func (*CAARecordSettings) UnmarshalJSON

func (r *CAARecordSettings) UnmarshalJSON(data []byte) (err error)

type CAARecordSettingsParam

type CAARecordSettingsParam struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only param.Field[bool] `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only param.Field[bool] `json:"ipv6_only"`
}

Settings for the DNS record.

func (CAARecordSettingsParam) MarshalJSON

func (r CAARecordSettingsParam) MarshalJSON() (data []byte, err error)

type CAARecordType

type CAARecordType string

Record type.

const (
	CAARecordTypeCAA CAARecordType = "CAA"
)

func (CAARecordType) IsKnown

func (r CAARecordType) IsKnown() bool

type CERTRecord

type CERTRecord struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment string `json:"comment"`
	// Formatted CERT content. See 'data' to set CERT properties.
	Content string `json:"content"`
	// Components of a CERT record.
	Data CERTRecordData `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name string `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied bool `json:"proxied"`
	// Settings for the DNS record.
	Settings CERTRecordSettings `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags []RecordTags `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL TTL `json:"ttl"`
	// Record type.
	Type CERTRecordType `json:"type"`
	JSON certRecordJSON `json:"-"`
}

func (*CERTRecord) UnmarshalJSON

func (r *CERTRecord) UnmarshalJSON(data []byte) (err error)

type CERTRecordData

type CERTRecordData struct {
	// Algorithm.
	Algorithm float64 `json:"algorithm"`
	// Certificate.
	Certificate string `json:"certificate"`
	// Key Tag.
	KeyTag float64 `json:"key_tag"`
	// Type.
	Type float64            `json:"type"`
	JSON certRecordDataJSON `json:"-"`
}

Components of a CERT record.

func (*CERTRecordData) UnmarshalJSON

func (r *CERTRecordData) UnmarshalJSON(data []byte) (err error)

type CERTRecordDataParam

type CERTRecordDataParam struct {
	// Algorithm.
	Algorithm param.Field[float64] `json:"algorithm"`
	// Certificate.
	Certificate param.Field[string] `json:"certificate"`
	// Key Tag.
	KeyTag param.Field[float64] `json:"key_tag"`
	// Type.
	Type param.Field[float64] `json:"type"`
}

Components of a CERT record.

func (CERTRecordDataParam) MarshalJSON

func (r CERTRecordDataParam) MarshalJSON() (data []byte, err error)

type CERTRecordParam

type CERTRecordParam struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// Components of a CERT record.
	Data param.Field[CERTRecordDataParam] `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `json:"proxied"`
	// Settings for the DNS record.
	Settings param.Field[CERTRecordSettingsParam] `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags param.Field[[]RecordTagsParam] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
	// Record type.
	Type param.Field[CERTRecordType] `json:"type"`
}

func (CERTRecordParam) MarshalJSON

func (r CERTRecordParam) MarshalJSON() (data []byte, err error)

type CERTRecordSettings

type CERTRecordSettings struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only bool `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only bool                   `json:"ipv6_only"`
	JSON     certRecordSettingsJSON `json:"-"`
}

Settings for the DNS record.

func (*CERTRecordSettings) UnmarshalJSON

func (r *CERTRecordSettings) UnmarshalJSON(data []byte) (err error)

type CERTRecordSettingsParam

type CERTRecordSettingsParam struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only param.Field[bool] `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only param.Field[bool] `json:"ipv6_only"`
}

Settings for the DNS record.

func (CERTRecordSettingsParam) MarshalJSON

func (r CERTRecordSettingsParam) MarshalJSON() (data []byte, err error)

type CERTRecordType

type CERTRecordType string

Record type.

const (
	CERTRecordTypeCERT CERTRecordType = "CERT"
)

func (CERTRecordType) IsKnown

func (r CERTRecordType) IsKnown() bool

type CNAMERecord

type CNAMERecord struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment string `json:"comment"`
	// A valid hostname. Must not match the record's name.
	Content string `json:"content"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name string `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied bool `json:"proxied"`
	// Settings for the DNS record.
	Settings CNAMERecordSettings `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags []RecordTags `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL TTL `json:"ttl"`
	// Record type.
	Type CNAMERecordType `json:"type"`
	JSON cnameRecordJSON `json:"-"`
}

func (*CNAMERecord) UnmarshalJSON

func (r *CNAMERecord) UnmarshalJSON(data []byte) (err error)

type CNAMERecordParam

type CNAMERecordParam struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// A valid hostname. Must not match the record's name.
	Content param.Field[string] `json:"content"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `json:"proxied"`
	// Settings for the DNS record.
	Settings param.Field[CNAMERecordSettingsParam] `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags param.Field[[]RecordTagsParam] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
	// Record type.
	Type param.Field[CNAMERecordType] `json:"type"`
}

func (CNAMERecordParam) MarshalJSON

func (r CNAMERecordParam) MarshalJSON() (data []byte, err error)

type CNAMERecordSettings

type CNAMERecordSettings struct {
	// If enabled, causes the CNAME record to be resolved externally and the resulting
	// address records (e.g., A and AAAA) to be returned instead of the CNAME record
	// itself. This setting is unavailable for proxied records, since they are always
	// flattened.
	FlattenCNAME bool `json:"flatten_cname"`
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only bool `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only bool                    `json:"ipv6_only"`
	JSON     cnameRecordSettingsJSON `json:"-"`
}

Settings for the DNS record.

func (*CNAMERecordSettings) UnmarshalJSON

func (r *CNAMERecordSettings) UnmarshalJSON(data []byte) (err error)

type CNAMERecordSettingsParam

type CNAMERecordSettingsParam struct {
	// If enabled, causes the CNAME record to be resolved externally and the resulting
	// address records (e.g., A and AAAA) to be returned instead of the CNAME record
	// itself. This setting is unavailable for proxied records, since they are always
	// flattened.
	FlattenCNAME param.Field[bool] `json:"flatten_cname"`
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only param.Field[bool] `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only param.Field[bool] `json:"ipv6_only"`
}

Settings for the DNS record.

func (CNAMERecordSettingsParam) MarshalJSON

func (r CNAMERecordSettingsParam) MarshalJSON() (data []byte, err error)

type CNAMERecordType

type CNAMERecordType string

Record type.

const (
	CNAMERecordTypeCNAME CNAMERecordType = "CNAME"
)

func (CNAMERecordType) IsKnown

func (r CNAMERecordType) IsKnown() bool

type CertificateCA

type CertificateCA = shared.CertificateCA

The Certificate Authority that will issue the certificate

This is an alias to an internal type.

type CertificateRequestType

type CertificateRequestType = shared.CertificateRequestType

Signature type desired on certificate ("origin-rsa" (rsa), "origin-ecc" (ecdsa), or "keyless-certificate" (for Keyless SSL servers).

This is an alias to an internal type.

type CloudflareTunnel

type CloudflareTunnel = shared.CloudflareTunnel

A Cloudflare Tunnel that connects your origin to Cloudflare's edge.

This is an alias to an internal type.

type CloudflareTunnelConnection

type CloudflareTunnelConnection = shared.CloudflareTunnelConnection

This is an alias to an internal type.

type CloudflareTunnelStatus

type CloudflareTunnelStatus = shared.CloudflareTunnelStatus

The status of the tunnel. Valid values are `inactive` (tunnel has never been run), `degraded` (tunnel is active and able to serve traffic but in an unhealthy state), `healthy` (tunnel is active and able to serve traffic), or `down` (tunnel can not serve traffic as it has no connections to the Cloudflare Edge).

This is an alias to an internal type.

type CloudflareTunnelTunType

type CloudflareTunnelTunType = shared.CloudflareTunnelTunType

The type of tunnel.

This is an alias to an internal type.

type DNSAnalyticsNominalMetric

type DNSAnalyticsNominalMetric []interface{}

type DNSAnalyticsQuery

type DNSAnalyticsQuery struct {
	// Array of dimension names.
	Dimensions []string `json:"dimensions,required"`
	// Limit number of returned metrics.
	Limit int64 `json:"limit,required"`
	// Array of metric names.
	Metrics []string `json:"metrics,required"`
	// Start date and time of requesting data period in ISO 8601 format.
	Since time.Time `json:"since,required" format:"date-time"`
	// Unit of time to group data by.
	TimeDelta DNSAnalyticsQueryTimeDelta `json:"time_delta,required"`
	// End date and time of requesting data period in ISO 8601 format.
	Until time.Time `json:"until,required" format:"date-time"`
	// Segmentation filter in 'attribute operator value' format.
	Filters string `json:"filters"`
	// Array of dimensions to sort by, where each dimension may be prefixed by -
	// (descending) or + (ascending).
	Sort []string              `json:"sort"`
	JSON dnsAnalyticsQueryJSON `json:"-"`
}

func (*DNSAnalyticsQuery) UnmarshalJSON

func (r *DNSAnalyticsQuery) UnmarshalJSON(data []byte) (err error)

type DNSAnalyticsQueryTimeDelta

type DNSAnalyticsQueryTimeDelta string

Unit of time to group data by.

const (
	DNSAnalyticsQueryTimeDeltaAll        DNSAnalyticsQueryTimeDelta = "all"
	DNSAnalyticsQueryTimeDeltaAuto       DNSAnalyticsQueryTimeDelta = "auto"
	DNSAnalyticsQueryTimeDeltaYear       DNSAnalyticsQueryTimeDelta = "year"
	DNSAnalyticsQueryTimeDeltaQuarter    DNSAnalyticsQueryTimeDelta = "quarter"
	DNSAnalyticsQueryTimeDeltaMonth      DNSAnalyticsQueryTimeDelta = "month"
	DNSAnalyticsQueryTimeDeltaWeek       DNSAnalyticsQueryTimeDelta = "week"
	DNSAnalyticsQueryTimeDeltaDay        DNSAnalyticsQueryTimeDelta = "day"
	DNSAnalyticsQueryTimeDeltaHour       DNSAnalyticsQueryTimeDelta = "hour"
	DNSAnalyticsQueryTimeDeltaDekaminute DNSAnalyticsQueryTimeDelta = "dekaminute"
	DNSAnalyticsQueryTimeDeltaMinute     DNSAnalyticsQueryTimeDelta = "minute"
)

func (DNSAnalyticsQueryTimeDelta) IsKnown

func (r DNSAnalyticsQueryTimeDelta) IsKnown() bool

type DNSKEYRecord

type DNSKEYRecord struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment string `json:"comment"`
	// Formatted DNSKEY content. See 'data' to set DNSKEY properties.
	Content string `json:"content"`
	// Components of a DNSKEY record.
	Data DNSKEYRecordData `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name string `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied bool `json:"proxied"`
	// Settings for the DNS record.
	Settings DNSKEYRecordSettings `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags []RecordTags `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL TTL `json:"ttl"`
	// Record type.
	Type DNSKEYRecordType `json:"type"`
	JSON dnskeyRecordJSON `json:"-"`
}

func (*DNSKEYRecord) UnmarshalJSON

func (r *DNSKEYRecord) UnmarshalJSON(data []byte) (err error)

type DNSKEYRecordData

type DNSKEYRecordData struct {
	// Algorithm.
	Algorithm float64 `json:"algorithm"`
	// Flags.
	Flags float64 `json:"flags"`
	// Protocol.
	Protocol float64 `json:"protocol"`
	// Public Key.
	PublicKey string               `json:"public_key"`
	JSON      dnskeyRecordDataJSON `json:"-"`
}

Components of a DNSKEY record.

func (*DNSKEYRecordData) UnmarshalJSON

func (r *DNSKEYRecordData) UnmarshalJSON(data []byte) (err error)

type DNSKEYRecordDataParam

type DNSKEYRecordDataParam struct {
	// Algorithm.
	Algorithm param.Field[float64] `json:"algorithm"`
	// Flags.
	Flags param.Field[float64] `json:"flags"`
	// Protocol.
	Protocol param.Field[float64] `json:"protocol"`
	// Public Key.
	PublicKey param.Field[string] `json:"public_key"`
}

Components of a DNSKEY record.

func (DNSKEYRecordDataParam) MarshalJSON

func (r DNSKEYRecordDataParam) MarshalJSON() (data []byte, err error)

type DNSKEYRecordParam

type DNSKEYRecordParam struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// Components of a DNSKEY record.
	Data param.Field[DNSKEYRecordDataParam] `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `json:"proxied"`
	// Settings for the DNS record.
	Settings param.Field[DNSKEYRecordSettingsParam] `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags param.Field[[]RecordTagsParam] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
	// Record type.
	Type param.Field[DNSKEYRecordType] `json:"type"`
}

func (DNSKEYRecordParam) MarshalJSON

func (r DNSKEYRecordParam) MarshalJSON() (data []byte, err error)

type DNSKEYRecordSettings

type DNSKEYRecordSettings struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only bool `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only bool                     `json:"ipv6_only"`
	JSON     dnskeyRecordSettingsJSON `json:"-"`
}

Settings for the DNS record.

func (*DNSKEYRecordSettings) UnmarshalJSON

func (r *DNSKEYRecordSettings) UnmarshalJSON(data []byte) (err error)

type DNSKEYRecordSettingsParam

type DNSKEYRecordSettingsParam struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only param.Field[bool] `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only param.Field[bool] `json:"ipv6_only"`
}

Settings for the DNS record.

func (DNSKEYRecordSettingsParam) MarshalJSON

func (r DNSKEYRecordSettingsParam) MarshalJSON() (data []byte, err error)

type DNSKEYRecordType

type DNSKEYRecordType string

Record type.

const (
	DNSKEYRecordTypeDNSKEY DNSKEYRecordType = "DNSKEY"
)

func (DNSKEYRecordType) IsKnown

func (r DNSKEYRecordType) IsKnown() bool

type DNSSEC

type DNSSEC struct {
	// Algorithm key code.
	Algorithm string `json:"algorithm,nullable"`
	// Digest hash.
	Digest string `json:"digest,nullable"`
	// Type of digest algorithm.
	DigestAlgorithm string `json:"digest_algorithm,nullable"`
	// Coded type for digest algorithm.
	DigestType string `json:"digest_type,nullable"`
	// If true, multi-signer DNSSEC is enabled on the zone, allowing multiple providers
	// to serve a DNSSEC-signed zone at the same time. This is required for DNSKEY
	// records (except those automatically generated by Cloudflare) to be added to the
	// zone.
	//
	// See
	// [Multi-signer DNSSEC](https://developers.cloudflare.com/dns/dnssec/multi-signer-dnssec/)
	// for details.
	DNSSECMultiSigner bool `json:"dnssec_multi_signer"`
	// If true, allows Cloudflare to transfer in a DNSSEC-signed zone including
	// signatures from an external provider, without requiring Cloudflare to sign any
	// records on the fly.
	//
	// Note that this feature has some limitations. See
	// [Cloudflare as Secondary](https://developers.cloudflare.com/dns/zone-setups/zone-transfers/cloudflare-as-secondary/setup/#dnssec)
	// for details.
	DNSSECPresigned bool `json:"dnssec_presigned"`
	// If true, enables the use of NSEC3 together with DNSSEC on the zone. Combined
	// with setting dnssec_presigned to true, this enables the use of NSEC3 records
	// when transferring in from an external provider. If dnssec_presigned is instead
	// set to false (default), NSEC3 records will be generated and signed at request
	// time.
	//
	// See
	// [DNSSEC with NSEC3](https://developers.cloudflare.com/dns/dnssec/enable-nsec3/)
	// for details.
	DNSSECUseNsec3 bool `json:"dnssec_use_nsec3"`
	// Full DS record.
	DS string `json:"ds,nullable"`
	// Flag for DNSSEC record.
	Flags float64 `json:"flags,nullable"`
	// Code for key tag.
	KeyTag float64 `json:"key_tag,nullable"`
	// Algorithm key type.
	KeyType string `json:"key_type,nullable"`
	// When DNSSEC was last modified.
	ModifiedOn time.Time `json:"modified_on,nullable" format:"date-time"`
	// Public key for DS record.
	PublicKey string `json:"public_key,nullable"`
	// Status of DNSSEC, based on user-desired state and presence of necessary records.
	Status DNSSECStatus `json:"status"`
	JSON   dnssecJSON   `json:"-"`
}

func (*DNSSEC) UnmarshalJSON

func (r *DNSSEC) UnmarshalJSON(data []byte) (err error)

type DNSSECDeleteParams

type DNSSECDeleteParams struct {
	// Identifier.
	ZoneID param.Field[string] `path:"zone_id,required"`
}

type DNSSECDeleteResponseEnvelope

type DNSSECDeleteResponseEnvelope struct {
	Errors   []DNSSECDeleteResponseEnvelopeErrors   `json:"errors,required"`
	Messages []DNSSECDeleteResponseEnvelopeMessages `json:"messages,required"`
	// Whether the API call was successful.
	Success DNSSECDeleteResponseEnvelopeSuccess `json:"success,required"`
	Result  string                              `json:"result"`
	JSON    dnssecDeleteResponseEnvelopeJSON    `json:"-"`
}

func (*DNSSECDeleteResponseEnvelope) UnmarshalJSON

func (r *DNSSECDeleteResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type DNSSECDeleteResponseEnvelopeErrors added in v4.3.0

type DNSSECDeleteResponseEnvelopeErrors struct {
	Code             int64                                    `json:"code,required"`
	Message          string                                   `json:"message,required"`
	DocumentationURL string                                   `json:"documentation_url"`
	Source           DNSSECDeleteResponseEnvelopeErrorsSource `json:"source"`
	JSON             dnssecDeleteResponseEnvelopeErrorsJSON   `json:"-"`
}

func (*DNSSECDeleteResponseEnvelopeErrors) UnmarshalJSON added in v4.3.0

func (r *DNSSECDeleteResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type DNSSECDeleteResponseEnvelopeErrorsSource added in v4.3.0

type DNSSECDeleteResponseEnvelopeErrorsSource struct {
	Pointer string                                       `json:"pointer"`
	JSON    dnssecDeleteResponseEnvelopeErrorsSourceJSON `json:"-"`
}

func (*DNSSECDeleteResponseEnvelopeErrorsSource) UnmarshalJSON added in v4.3.0

func (r *DNSSECDeleteResponseEnvelopeErrorsSource) UnmarshalJSON(data []byte) (err error)

type DNSSECDeleteResponseEnvelopeMessages added in v4.3.0

type DNSSECDeleteResponseEnvelopeMessages struct {
	Code             int64                                      `json:"code,required"`
	Message          string                                     `json:"message,required"`
	DocumentationURL string                                     `json:"documentation_url"`
	Source           DNSSECDeleteResponseEnvelopeMessagesSource `json:"source"`
	JSON             dnssecDeleteResponseEnvelopeMessagesJSON   `json:"-"`
}

func (*DNSSECDeleteResponseEnvelopeMessages) UnmarshalJSON added in v4.3.0

func (r *DNSSECDeleteResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type DNSSECDeleteResponseEnvelopeMessagesSource added in v4.3.0

type DNSSECDeleteResponseEnvelopeMessagesSource struct {
	Pointer string                                         `json:"pointer"`
	JSON    dnssecDeleteResponseEnvelopeMessagesSourceJSON `json:"-"`
}

func (*DNSSECDeleteResponseEnvelopeMessagesSource) UnmarshalJSON added in v4.3.0

func (r *DNSSECDeleteResponseEnvelopeMessagesSource) UnmarshalJSON(data []byte) (err error)

type DNSSECDeleteResponseEnvelopeSuccess

type DNSSECDeleteResponseEnvelopeSuccess bool

Whether the API call was successful.

const (
	DNSSECDeleteResponseEnvelopeSuccessTrue DNSSECDeleteResponseEnvelopeSuccess = true
)

func (DNSSECDeleteResponseEnvelopeSuccess) IsKnown

type DNSSECEditParams

type DNSSECEditParams struct {
	// Identifier.
	ZoneID param.Field[string] `path:"zone_id,required"`
	// If true, multi-signer DNSSEC is enabled on the zone, allowing multiple providers
	// to serve a DNSSEC-signed zone at the same time. This is required for DNSKEY
	// records (except those automatically generated by Cloudflare) to be added to the
	// zone.
	//
	// See
	// [Multi-signer DNSSEC](https://developers.cloudflare.com/dns/dnssec/multi-signer-dnssec/)
	// for details.
	DNSSECMultiSigner param.Field[bool] `json:"dnssec_multi_signer"`
	// If true, allows Cloudflare to transfer in a DNSSEC-signed zone including
	// signatures from an external provider, without requiring Cloudflare to sign any
	// records on the fly.
	//
	// Note that this feature has some limitations. See
	// [Cloudflare as Secondary](https://developers.cloudflare.com/dns/zone-setups/zone-transfers/cloudflare-as-secondary/setup/#dnssec)
	// for details.
	DNSSECPresigned param.Field[bool] `json:"dnssec_presigned"`
	// If true, enables the use of NSEC3 together with DNSSEC on the zone. Combined
	// with setting dnssec_presigned to true, this enables the use of NSEC3 records
	// when transferring in from an external provider. If dnssec_presigned is instead
	// set to false (default), NSEC3 records will be generated and signed at request
	// time.
	//
	// See
	// [DNSSEC with NSEC3](https://developers.cloudflare.com/dns/dnssec/enable-nsec3/)
	// for details.
	DNSSECUseNsec3 param.Field[bool] `json:"dnssec_use_nsec3"`
	// Status of DNSSEC, based on user-desired state and presence of necessary records.
	Status param.Field[DNSSECEditParamsStatus] `json:"status"`
}

func (DNSSECEditParams) MarshalJSON

func (r DNSSECEditParams) MarshalJSON() (data []byte, err error)

type DNSSECEditParamsStatus

type DNSSECEditParamsStatus string

Status of DNSSEC, based on user-desired state and presence of necessary records.

const (
	DNSSECEditParamsStatusActive   DNSSECEditParamsStatus = "active"
	DNSSECEditParamsStatusDisabled DNSSECEditParamsStatus = "disabled"
)

func (DNSSECEditParamsStatus) IsKnown

func (r DNSSECEditParamsStatus) IsKnown() bool

type DNSSECEditResponseEnvelope

type DNSSECEditResponseEnvelope struct {
	Errors   []DNSSECEditResponseEnvelopeErrors   `json:"errors,required"`
	Messages []DNSSECEditResponseEnvelopeMessages `json:"messages,required"`
	// Whether the API call was successful.
	Success DNSSECEditResponseEnvelopeSuccess `json:"success,required"`
	Result  DNSSEC                            `json:"result"`
	JSON    dnssecEditResponseEnvelopeJSON    `json:"-"`
}

func (*DNSSECEditResponseEnvelope) UnmarshalJSON

func (r *DNSSECEditResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type DNSSECEditResponseEnvelopeErrors added in v4.3.0

type DNSSECEditResponseEnvelopeErrors struct {
	Code             int64                                  `json:"code,required"`
	Message          string                                 `json:"message,required"`
	DocumentationURL string                                 `json:"documentation_url"`
	Source           DNSSECEditResponseEnvelopeErrorsSource `json:"source"`
	JSON             dnssecEditResponseEnvelopeErrorsJSON   `json:"-"`
}

func (*DNSSECEditResponseEnvelopeErrors) UnmarshalJSON added in v4.3.0

func (r *DNSSECEditResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type DNSSECEditResponseEnvelopeErrorsSource added in v4.3.0

type DNSSECEditResponseEnvelopeErrorsSource struct {
	Pointer string                                     `json:"pointer"`
	JSON    dnssecEditResponseEnvelopeErrorsSourceJSON `json:"-"`
}

func (*DNSSECEditResponseEnvelopeErrorsSource) UnmarshalJSON added in v4.3.0

func (r *DNSSECEditResponseEnvelopeErrorsSource) UnmarshalJSON(data []byte) (err error)

type DNSSECEditResponseEnvelopeMessages added in v4.3.0

type DNSSECEditResponseEnvelopeMessages struct {
	Code             int64                                    `json:"code,required"`
	Message          string                                   `json:"message,required"`
	DocumentationURL string                                   `json:"documentation_url"`
	Source           DNSSECEditResponseEnvelopeMessagesSource `json:"source"`
	JSON             dnssecEditResponseEnvelopeMessagesJSON   `json:"-"`
}

func (*DNSSECEditResponseEnvelopeMessages) UnmarshalJSON added in v4.3.0

func (r *DNSSECEditResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type DNSSECEditResponseEnvelopeMessagesSource added in v4.3.0

type DNSSECEditResponseEnvelopeMessagesSource struct {
	Pointer string                                       `json:"pointer"`
	JSON    dnssecEditResponseEnvelopeMessagesSourceJSON `json:"-"`
}

func (*DNSSECEditResponseEnvelopeMessagesSource) UnmarshalJSON added in v4.3.0

func (r *DNSSECEditResponseEnvelopeMessagesSource) UnmarshalJSON(data []byte) (err error)

type DNSSECEditResponseEnvelopeSuccess

type DNSSECEditResponseEnvelopeSuccess bool

Whether the API call was successful.

const (
	DNSSECEditResponseEnvelopeSuccessTrue DNSSECEditResponseEnvelopeSuccess = true
)

func (DNSSECEditResponseEnvelopeSuccess) IsKnown

type DNSSECGetParams

type DNSSECGetParams struct {
	// Identifier.
	ZoneID param.Field[string] `path:"zone_id,required"`
}

type DNSSECGetResponseEnvelope

type DNSSECGetResponseEnvelope struct {
	Errors   []DNSSECGetResponseEnvelopeErrors   `json:"errors,required"`
	Messages []DNSSECGetResponseEnvelopeMessages `json:"messages,required"`
	// Whether the API call was successful.
	Success DNSSECGetResponseEnvelopeSuccess `json:"success,required"`
	Result  DNSSEC                           `json:"result"`
	JSON    dnssecGetResponseEnvelopeJSON    `json:"-"`
}

func (*DNSSECGetResponseEnvelope) UnmarshalJSON

func (r *DNSSECGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type DNSSECGetResponseEnvelopeErrors added in v4.3.0

type DNSSECGetResponseEnvelopeErrors struct {
	Code             int64                                 `json:"code,required"`
	Message          string                                `json:"message,required"`
	DocumentationURL string                                `json:"documentation_url"`
	Source           DNSSECGetResponseEnvelopeErrorsSource `json:"source"`
	JSON             dnssecGetResponseEnvelopeErrorsJSON   `json:"-"`
}

func (*DNSSECGetResponseEnvelopeErrors) UnmarshalJSON added in v4.3.0

func (r *DNSSECGetResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type DNSSECGetResponseEnvelopeErrorsSource added in v4.3.0

type DNSSECGetResponseEnvelopeErrorsSource struct {
	Pointer string                                    `json:"pointer"`
	JSON    dnssecGetResponseEnvelopeErrorsSourceJSON `json:"-"`
}

func (*DNSSECGetResponseEnvelopeErrorsSource) UnmarshalJSON added in v4.3.0

func (r *DNSSECGetResponseEnvelopeErrorsSource) UnmarshalJSON(data []byte) (err error)

type DNSSECGetResponseEnvelopeMessages added in v4.3.0

type DNSSECGetResponseEnvelopeMessages struct {
	Code             int64                                   `json:"code,required"`
	Message          string                                  `json:"message,required"`
	DocumentationURL string                                  `json:"documentation_url"`
	Source           DNSSECGetResponseEnvelopeMessagesSource `json:"source"`
	JSON             dnssecGetResponseEnvelopeMessagesJSON   `json:"-"`
}

func (*DNSSECGetResponseEnvelopeMessages) UnmarshalJSON added in v4.3.0

func (r *DNSSECGetResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type DNSSECGetResponseEnvelopeMessagesSource added in v4.3.0

type DNSSECGetResponseEnvelopeMessagesSource struct {
	Pointer string                                      `json:"pointer"`
	JSON    dnssecGetResponseEnvelopeMessagesSourceJSON `json:"-"`
}

func (*DNSSECGetResponseEnvelopeMessagesSource) UnmarshalJSON added in v4.3.0

func (r *DNSSECGetResponseEnvelopeMessagesSource) UnmarshalJSON(data []byte) (err error)

type DNSSECGetResponseEnvelopeSuccess

type DNSSECGetResponseEnvelopeSuccess bool

Whether the API call was successful.

const (
	DNSSECGetResponseEnvelopeSuccessTrue DNSSECGetResponseEnvelopeSuccess = true
)

func (DNSSECGetResponseEnvelopeSuccess) IsKnown

type DNSSECService

type DNSSECService struct {
	Options []option.RequestOption
}

DNSSECService contains methods and other services that help with interacting with the cloudflare API.

Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewDNSSECService method instead.

func NewDNSSECService

func NewDNSSECService(opts ...option.RequestOption) (r *DNSSECService)

NewDNSSECService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*DNSSECService) Delete

func (r *DNSSECService) Delete(ctx context.Context, body DNSSECDeleteParams, opts ...option.RequestOption) (res *string, err error)

Delete DNSSEC.

func (*DNSSECService) Edit

func (r *DNSSECService) Edit(ctx context.Context, params DNSSECEditParams, opts ...option.RequestOption) (res *DNSSEC, err error)

Enable or disable DNSSEC.

func (*DNSSECService) Get

func (r *DNSSECService) Get(ctx context.Context, query DNSSECGetParams, opts ...option.RequestOption) (res *DNSSEC, err error)

Details about DNSSEC status and configuration.

type DNSSECStatus

type DNSSECStatus string

Status of DNSSEC, based on user-desired state and presence of necessary records.

const (
	DNSSECStatusActive          DNSSECStatus = "active"
	DNSSECStatusPending         DNSSECStatus = "pending"
	DNSSECStatusDisabled        DNSSECStatus = "disabled"
	DNSSECStatusPendingDisabled DNSSECStatus = "pending-disabled"
	DNSSECStatusError           DNSSECStatus = "error"
)

func (DNSSECStatus) IsKnown

func (r DNSSECStatus) IsKnown() bool

type DNSService

type DNSService struct {
	Options       []option.RequestOption
	DNSSEC        *DNSSECService
	Records       *RecordService
	Settings      *SettingService
	Analytics     *AnalyticsService
	ZoneTransfers *ZoneTransferService
}

DNSService contains methods and other services that help with interacting with the cloudflare API.

Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewDNSService method instead.

func NewDNSService

func NewDNSService(opts ...option.RequestOption) (r *DNSService)

NewDNSService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

type DSRecord

type DSRecord struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment string `json:"comment"`
	// Formatted DS content. See 'data' to set DS properties.
	Content string `json:"content"`
	// Components of a DS record.
	Data DSRecordData `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name string `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied bool `json:"proxied"`
	// Settings for the DNS record.
	Settings DSRecordSettings `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags []RecordTags `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL TTL `json:"ttl"`
	// Record type.
	Type DSRecordType `json:"type"`
	JSON dsRecordJSON `json:"-"`
}

func (*DSRecord) UnmarshalJSON

func (r *DSRecord) UnmarshalJSON(data []byte) (err error)

type DSRecordData

type DSRecordData struct {
	// Algorithm.
	Algorithm float64 `json:"algorithm"`
	// Digest.
	Digest string `json:"digest"`
	// Digest Type.
	DigestType float64 `json:"digest_type"`
	// Key Tag.
	KeyTag float64          `json:"key_tag"`
	JSON   dsRecordDataJSON `json:"-"`
}

Components of a DS record.

func (*DSRecordData) UnmarshalJSON

func (r *DSRecordData) UnmarshalJSON(data []byte) (err error)

type DSRecordDataParam

type DSRecordDataParam struct {
	// Algorithm.
	Algorithm param.Field[float64] `json:"algorithm"`
	// Digest.
	Digest param.Field[string] `json:"digest"`
	// Digest Type.
	DigestType param.Field[float64] `json:"digest_type"`
	// Key Tag.
	KeyTag param.Field[float64] `json:"key_tag"`
}

Components of a DS record.

func (DSRecordDataParam) MarshalJSON

func (r DSRecordDataParam) MarshalJSON() (data []byte, err error)

type DSRecordParam

type DSRecordParam struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// Components of a DS record.
	Data param.Field[DSRecordDataParam] `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `json:"proxied"`
	// Settings for the DNS record.
	Settings param.Field[DSRecordSettingsParam] `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags param.Field[[]RecordTagsParam] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
	// Record type.
	Type param.Field[DSRecordType] `json:"type"`
}

func (DSRecordParam) MarshalJSON

func (r DSRecordParam) MarshalJSON() (data []byte, err error)

type DSRecordSettings

type DSRecordSettings struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only bool `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only bool                 `json:"ipv6_only"`
	JSON     dsRecordSettingsJSON `json:"-"`
}

Settings for the DNS record.

func (*DSRecordSettings) UnmarshalJSON

func (r *DSRecordSettings) UnmarshalJSON(data []byte) (err error)

type DSRecordSettingsParam

type DSRecordSettingsParam struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only param.Field[bool] `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only param.Field[bool] `json:"ipv6_only"`
}

Settings for the DNS record.

func (DSRecordSettingsParam) MarshalJSON

func (r DSRecordSettingsParam) MarshalJSON() (data []byte, err error)

type DSRecordType

type DSRecordType string

Record type.

const (
	DSRecordTypeDS DSRecordType = "DS"
)

func (DSRecordType) IsKnown

func (r DSRecordType) IsKnown() bool

type DisableTransfer

type DisableTransfer = string

type EnableTransfer

type EnableTransfer = string

type Error

type Error = apierror.Error

type ErrorData

type ErrorData = shared.ErrorData

This is an alias to an internal type.

type ErrorDataSource added in v4.2.0

type ErrorDataSource = shared.ErrorDataSource

This is an alias to an internal type.

type ForceAXFR

type ForceAXFR = string

type HTTPSRecord

type HTTPSRecord struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment string `json:"comment"`
	// Formatted HTTPS content. See 'data' to set HTTPS properties.
	Content string `json:"content"`
	// Components of a HTTPS record.
	Data HTTPSRecordData `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name string `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied bool `json:"proxied"`
	// Settings for the DNS record.
	Settings HTTPSRecordSettings `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags []RecordTags `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL TTL `json:"ttl"`
	// Record type.
	Type HTTPSRecordType `json:"type"`
	JSON httpsRecordJSON `json:"-"`
}

func (*HTTPSRecord) UnmarshalJSON

func (r *HTTPSRecord) UnmarshalJSON(data []byte) (err error)

type HTTPSRecordData

type HTTPSRecordData struct {
	// priority.
	Priority float64 `json:"priority"`
	// target.
	Target string `json:"target"`
	// value.
	Value string              `json:"value"`
	JSON  httpsRecordDataJSON `json:"-"`
}

Components of a HTTPS record.

func (*HTTPSRecordData) UnmarshalJSON

func (r *HTTPSRecordData) UnmarshalJSON(data []byte) (err error)

type HTTPSRecordDataParam

type HTTPSRecordDataParam struct {
	// priority.
	Priority param.Field[float64] `json:"priority"`
	// target.
	Target param.Field[string] `json:"target"`
	// value.
	Value param.Field[string] `json:"value"`
}

Components of a HTTPS record.

func (HTTPSRecordDataParam) MarshalJSON

func (r HTTPSRecordDataParam) MarshalJSON() (data []byte, err error)

type HTTPSRecordParam

type HTTPSRecordParam struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// Components of a HTTPS record.
	Data param.Field[HTTPSRecordDataParam] `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `json:"proxied"`
	// Settings for the DNS record.
	Settings param.Field[HTTPSRecordSettingsParam] `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags param.Field[[]RecordTagsParam] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
	// Record type.
	Type param.Field[HTTPSRecordType] `json:"type"`
}

func (HTTPSRecordParam) MarshalJSON

func (r HTTPSRecordParam) MarshalJSON() (data []byte, err error)

type HTTPSRecordSettings

type HTTPSRecordSettings struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only bool `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only bool                    `json:"ipv6_only"`
	JSON     httpsRecordSettingsJSON `json:"-"`
}

Settings for the DNS record.

func (*HTTPSRecordSettings) UnmarshalJSON

func (r *HTTPSRecordSettings) UnmarshalJSON(data []byte) (err error)

type HTTPSRecordSettingsParam

type HTTPSRecordSettingsParam struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only param.Field[bool] `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only param.Field[bool] `json:"ipv6_only"`
}

Settings for the DNS record.

func (HTTPSRecordSettingsParam) MarshalJSON

func (r HTTPSRecordSettingsParam) MarshalJSON() (data []byte, err error)

type HTTPSRecordType

type HTTPSRecordType string

Record type.

const (
	HTTPSRecordTypeHTTPS HTTPSRecordType = "HTTPS"
)

func (HTTPSRecordType) IsKnown

func (r HTTPSRecordType) IsKnown() bool

type LOCRecord

type LOCRecord struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment string `json:"comment"`
	// Formatted LOC content. See 'data' to set LOC properties.
	Content string `json:"content"`
	// Components of a LOC record.
	Data LOCRecordData `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name string `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied bool `json:"proxied"`
	// Settings for the DNS record.
	Settings LOCRecordSettings `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags []RecordTags `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL TTL `json:"ttl"`
	// Record type.
	Type LOCRecordType `json:"type"`
	JSON locRecordJSON `json:"-"`
}

func (*LOCRecord) UnmarshalJSON

func (r *LOCRecord) UnmarshalJSON(data []byte) (err error)

type LOCRecordData

type LOCRecordData struct {
	// Altitude of location in meters.
	Altitude float64 `json:"altitude"`
	// Degrees of latitude.
	LatDegrees float64 `json:"lat_degrees"`
	// Latitude direction.
	LatDirection LOCRecordDataLatDirection `json:"lat_direction"`
	// Minutes of latitude.
	LatMinutes float64 `json:"lat_minutes"`
	// Seconds of latitude.
	LatSeconds float64 `json:"lat_seconds"`
	// Degrees of longitude.
	LongDegrees float64 `json:"long_degrees"`
	// Longitude direction.
	LongDirection LOCRecordDataLongDirection `json:"long_direction"`
	// Minutes of longitude.
	LongMinutes float64 `json:"long_minutes"`
	// Seconds of longitude.
	LongSeconds float64 `json:"long_seconds"`
	// Horizontal precision of location.
	PrecisionHorz float64 `json:"precision_horz"`
	// Vertical precision of location.
	PrecisionVert float64 `json:"precision_vert"`
	// Size of location in meters.
	Size float64           `json:"size"`
	JSON locRecordDataJSON `json:"-"`
}

Components of a LOC record.

func (*LOCRecordData) UnmarshalJSON

func (r *LOCRecordData) UnmarshalJSON(data []byte) (err error)

type LOCRecordDataLatDirection

type LOCRecordDataLatDirection string

Latitude direction.

const (
	LOCRecordDataLatDirectionN LOCRecordDataLatDirection = "N"
	LOCRecordDataLatDirectionS LOCRecordDataLatDirection = "S"
)

func (LOCRecordDataLatDirection) IsKnown

func (r LOCRecordDataLatDirection) IsKnown() bool

type LOCRecordDataLongDirection

type LOCRecordDataLongDirection string

Longitude direction.

const (
	LOCRecordDataLongDirectionE LOCRecordDataLongDirection = "E"
	LOCRecordDataLongDirectionW LOCRecordDataLongDirection = "W"
)

func (LOCRecordDataLongDirection) IsKnown

func (r LOCRecordDataLongDirection) IsKnown() bool

type LOCRecordDataParam

type LOCRecordDataParam struct {
	// Altitude of location in meters.
	Altitude param.Field[float64] `json:"altitude"`
	// Degrees of latitude.
	LatDegrees param.Field[float64] `json:"lat_degrees"`
	// Latitude direction.
	LatDirection param.Field[LOCRecordDataLatDirection] `json:"lat_direction"`
	// Minutes of latitude.
	LatMinutes param.Field[float64] `json:"lat_minutes"`
	// Seconds of latitude.
	LatSeconds param.Field[float64] `json:"lat_seconds"`
	// Degrees of longitude.
	LongDegrees param.Field[float64] `json:"long_degrees"`
	// Longitude direction.
	LongDirection param.Field[LOCRecordDataLongDirection] `json:"long_direction"`
	// Minutes of longitude.
	LongMinutes param.Field[float64] `json:"long_minutes"`
	// Seconds of longitude.
	LongSeconds param.Field[float64] `json:"long_seconds"`
	// Horizontal precision of location.
	PrecisionHorz param.Field[float64] `json:"precision_horz"`
	// Vertical precision of location.
	PrecisionVert param.Field[float64] `json:"precision_vert"`
	// Size of location in meters.
	Size param.Field[float64] `json:"size"`
}

Components of a LOC record.

func (LOCRecordDataParam) MarshalJSON

func (r LOCRecordDataParam) MarshalJSON() (data []byte, err error)

type LOCRecordParam

type LOCRecordParam struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// Components of a LOC record.
	Data param.Field[LOCRecordDataParam] `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `json:"proxied"`
	// Settings for the DNS record.
	Settings param.Field[LOCRecordSettingsParam] `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags param.Field[[]RecordTagsParam] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
	// Record type.
	Type param.Field[LOCRecordType] `json:"type"`
}

func (LOCRecordParam) MarshalJSON

func (r LOCRecordParam) MarshalJSON() (data []byte, err error)

type LOCRecordSettings

type LOCRecordSettings struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only bool `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only bool                  `json:"ipv6_only"`
	JSON     locRecordSettingsJSON `json:"-"`
}

Settings for the DNS record.

func (*LOCRecordSettings) UnmarshalJSON

func (r *LOCRecordSettings) UnmarshalJSON(data []byte) (err error)

type LOCRecordSettingsParam

type LOCRecordSettingsParam struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only param.Field[bool] `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only param.Field[bool] `json:"ipv6_only"`
}

Settings for the DNS record.

func (LOCRecordSettingsParam) MarshalJSON

func (r LOCRecordSettingsParam) MarshalJSON() (data []byte, err error)

type LOCRecordType

type LOCRecordType string

Record type.

const (
	LOCRecordTypeLOC LOCRecordType = "LOC"
)

func (LOCRecordType) IsKnown

func (r LOCRecordType) IsKnown() bool

type MXRecord

type MXRecord struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment string `json:"comment"`
	// A valid mail server hostname.
	Content string `json:"content" format:"hostname"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name string `json:"name"`
	// Required for MX, SRV and URI records; unused by other record types. Records with
	// lower priorities are preferred.
	Priority float64 `json:"priority"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied bool `json:"proxied"`
	// Settings for the DNS record.
	Settings MXRecordSettings `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags []RecordTags `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL TTL `json:"ttl"`
	// Record type.
	Type MXRecordType `json:"type"`
	JSON mxRecordJSON `json:"-"`
}

func (*MXRecord) UnmarshalJSON

func (r *MXRecord) UnmarshalJSON(data []byte) (err error)

type MXRecordParam

type MXRecordParam struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// A valid mail server hostname.
	Content param.Field[string] `json:"content" format:"hostname"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name"`
	// Required for MX, SRV and URI records; unused by other record types. Records with
	// lower priorities are preferred.
	Priority param.Field[float64] `json:"priority"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `json:"proxied"`
	// Settings for the DNS record.
	Settings param.Field[MXRecordSettingsParam] `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags param.Field[[]RecordTagsParam] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
	// Record type.
	Type param.Field[MXRecordType] `json:"type"`
}

func (MXRecordParam) MarshalJSON

func (r MXRecordParam) MarshalJSON() (data []byte, err error)

type MXRecordSettings

type MXRecordSettings struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only bool `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only bool                 `json:"ipv6_only"`
	JSON     mxRecordSettingsJSON `json:"-"`
}

Settings for the DNS record.

func (*MXRecordSettings) UnmarshalJSON

func (r *MXRecordSettings) UnmarshalJSON(data []byte) (err error)

type MXRecordSettingsParam

type MXRecordSettingsParam struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only param.Field[bool] `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only param.Field[bool] `json:"ipv6_only"`
}

Settings for the DNS record.

func (MXRecordSettingsParam) MarshalJSON

func (r MXRecordSettingsParam) MarshalJSON() (data []byte, err error)

type MXRecordType

type MXRecordType string

Record type.

const (
	MXRecordTypeMX MXRecordType = "MX"
)

func (MXRecordType) IsKnown

func (r MXRecordType) IsKnown() bool

type Member

type Member = shared.Member

This is an alias to an internal type.

type MemberPoliciesAccess

type MemberPoliciesAccess = shared.MemberPoliciesAccess

Allow or deny operations against the resources.

This is an alias to an internal type.

type MemberPoliciesPermissionGroup

type MemberPoliciesPermissionGroup = shared.MemberPoliciesPermissionGroup

A named group of permissions that map to a group of operations against resources.

This is an alias to an internal type.

type MemberPoliciesPermissionGroupsMeta

type MemberPoliciesPermissionGroupsMeta = shared.MemberPoliciesPermissionGroupsMeta

Attributes associated to the permission group.

This is an alias to an internal type.

type MemberPoliciesResourceGroup

type MemberPoliciesResourceGroup = shared.MemberPoliciesResourceGroup

A group of scoped resources.

This is an alias to an internal type.

type MemberPoliciesResourceGroupsMeta

type MemberPoliciesResourceGroupsMeta = shared.MemberPoliciesResourceGroupsMeta

Attributes associated to the resource group.

This is an alias to an internal type.

type MemberPoliciesResourceGroupsScope

type MemberPoliciesResourceGroupsScope = shared.MemberPoliciesResourceGroupsScope

A scope is a combination of scope objects which provides additional context.

This is an alias to an internal type.

type MemberPoliciesResourceGroupsScopeObject

type MemberPoliciesResourceGroupsScopeObject = shared.MemberPoliciesResourceGroupsScopeObject

A scope object represents any resource that can have actions applied against invite.

This is an alias to an internal type.

type MemberPolicy

type MemberPolicy = shared.MemberPolicy

This is an alias to an internal type.

type MemberStatus

type MemberStatus = shared.MemberStatus

A member's status in the account.

This is an alias to an internal type.

type MemberUser

type MemberUser = shared.MemberUser

Details of the user associated to the membership.

This is an alias to an internal type.

type NAPTRRecord

type NAPTRRecord struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment string `json:"comment"`
	// Formatted NAPTR content. See 'data' to set NAPTR properties.
	Content string `json:"content"`
	// Components of a NAPTR record.
	Data NAPTRRecordData `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name string `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied bool `json:"proxied"`
	// Settings for the DNS record.
	Settings NAPTRRecordSettings `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags []RecordTags `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL TTL `json:"ttl"`
	// Record type.
	Type NAPTRRecordType `json:"type"`
	JSON naptrRecordJSON `json:"-"`
}

func (*NAPTRRecord) UnmarshalJSON

func (r *NAPTRRecord) UnmarshalJSON(data []byte) (err error)

type NAPTRRecordData

type NAPTRRecordData struct {
	// Flags.
	Flags string `json:"flags"`
	// Order.
	Order float64 `json:"order"`
	// Preference.
	Preference float64 `json:"preference"`
	// Regex.
	Regex string `json:"regex"`
	// Replacement.
	Replacement string `json:"replacement"`
	// Service.
	Service string              `json:"service"`
	JSON    naptrRecordDataJSON `json:"-"`
}

Components of a NAPTR record.

func (*NAPTRRecordData) UnmarshalJSON

func (r *NAPTRRecordData) UnmarshalJSON(data []byte) (err error)

type NAPTRRecordDataParam

type NAPTRRecordDataParam struct {
	// Flags.
	Flags param.Field[string] `json:"flags"`
	// Order.
	Order param.Field[float64] `json:"order"`
	// Preference.
	Preference param.Field[float64] `json:"preference"`
	// Regex.
	Regex param.Field[string] `json:"regex"`
	// Replacement.
	Replacement param.Field[string] `json:"replacement"`
	// Service.
	Service param.Field[string] `json:"service"`
}

Components of a NAPTR record.

func (NAPTRRecordDataParam) MarshalJSON

func (r NAPTRRecordDataParam) MarshalJSON() (data []byte, err error)

type NAPTRRecordParam

type NAPTRRecordParam struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// Components of a NAPTR record.
	Data param.Field[NAPTRRecordDataParam] `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `json:"proxied"`
	// Settings for the DNS record.
	Settings param.Field[NAPTRRecordSettingsParam] `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags param.Field[[]RecordTagsParam] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
	// Record type.
	Type param.Field[NAPTRRecordType] `json:"type"`
}

func (NAPTRRecordParam) MarshalJSON

func (r NAPTRRecordParam) MarshalJSON() (data []byte, err error)

type NAPTRRecordSettings

type NAPTRRecordSettings struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only bool `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only bool                    `json:"ipv6_only"`
	JSON     naptrRecordSettingsJSON `json:"-"`
}

Settings for the DNS record.

func (*NAPTRRecordSettings) UnmarshalJSON

func (r *NAPTRRecordSettings) UnmarshalJSON(data []byte) (err error)

type NAPTRRecordSettingsParam

type NAPTRRecordSettingsParam struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only param.Field[bool] `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only param.Field[bool] `json:"ipv6_only"`
}

Settings for the DNS record.

func (NAPTRRecordSettingsParam) MarshalJSON

func (r NAPTRRecordSettingsParam) MarshalJSON() (data []byte, err error)

type NAPTRRecordType

type NAPTRRecordType string

Record type.

const (
	NAPTRRecordTypeNAPTR NAPTRRecordType = "NAPTR"
)

func (NAPTRRecordType) IsKnown

func (r NAPTRRecordType) IsKnown() bool

type NSRecord

type NSRecord struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment string `json:"comment"`
	// A valid name server host name.
	Content string `json:"content"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name string `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied bool `json:"proxied"`
	// Settings for the DNS record.
	Settings NSRecordSettings `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags []RecordTags `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL TTL `json:"ttl"`
	// Record type.
	Type NSRecordType `json:"type"`
	JSON nsRecordJSON `json:"-"`
}

func (*NSRecord) UnmarshalJSON

func (r *NSRecord) UnmarshalJSON(data []byte) (err error)

type NSRecordParam

type NSRecordParam struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// A valid name server host name.
	Content param.Field[string] `json:"content"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `json:"proxied"`
	// Settings for the DNS record.
	Settings param.Field[NSRecordSettingsParam] `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags param.Field[[]RecordTagsParam] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
	// Record type.
	Type param.Field[NSRecordType] `json:"type"`
}

func (NSRecordParam) MarshalJSON

func (r NSRecordParam) MarshalJSON() (data []byte, err error)

type NSRecordSettings

type NSRecordSettings struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only bool `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only bool                 `json:"ipv6_only"`
	JSON     nsRecordSettingsJSON `json:"-"`
}

Settings for the DNS record.

func (*NSRecordSettings) UnmarshalJSON

func (r *NSRecordSettings) UnmarshalJSON(data []byte) (err error)

type NSRecordSettingsParam

type NSRecordSettingsParam struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only param.Field[bool] `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only param.Field[bool] `json:"ipv6_only"`
}

Settings for the DNS record.

func (NSRecordSettingsParam) MarshalJSON

func (r NSRecordSettingsParam) MarshalJSON() (data []byte, err error)

type NSRecordType

type NSRecordType string

Record type.

const (
	NSRecordTypeNS NSRecordType = "NS"
)

func (NSRecordType) IsKnown

func (r NSRecordType) IsKnown() bool

type PTRRecord

type PTRRecord struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment string `json:"comment"`
	// Domain name pointing to the address.
	Content string `json:"content"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name string `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied bool `json:"proxied"`
	// Settings for the DNS record.
	Settings PTRRecordSettings `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags []RecordTags `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL TTL `json:"ttl"`
	// Record type.
	Type PTRRecordType `json:"type"`
	JSON ptrRecordJSON `json:"-"`
}

func (*PTRRecord) UnmarshalJSON

func (r *PTRRecord) UnmarshalJSON(data []byte) (err error)

type PTRRecordParam

type PTRRecordParam struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// Domain name pointing to the address.
	Content param.Field[string] `json:"content"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `json:"proxied"`
	// Settings for the DNS record.
	Settings param.Field[PTRRecordSettingsParam] `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags param.Field[[]RecordTagsParam] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
	// Record type.
	Type param.Field[PTRRecordType] `json:"type"`
}

func (PTRRecordParam) MarshalJSON

func (r PTRRecordParam) MarshalJSON() (data []byte, err error)

type PTRRecordSettings

type PTRRecordSettings struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only bool `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only bool                  `json:"ipv6_only"`
	JSON     ptrRecordSettingsJSON `json:"-"`
}

Settings for the DNS record.

func (*PTRRecordSettings) UnmarshalJSON

func (r *PTRRecordSettings) UnmarshalJSON(data []byte) (err error)

type PTRRecordSettingsParam

type PTRRecordSettingsParam struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only param.Field[bool] `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only param.Field[bool] `json:"ipv6_only"`
}

Settings for the DNS record.

func (PTRRecordSettingsParam) MarshalJSON

func (r PTRRecordSettingsParam) MarshalJSON() (data []byte, err error)

type PTRRecordType

type PTRRecordType string

Record type.

const (
	PTRRecordTypePTR PTRRecordType = "PTR"
)

func (PTRRecordType) IsKnown

func (r PTRRecordType) IsKnown() bool

type Peer

type Peer struct {
	ID string `json:"id,required"`
	// The name of the peer.
	Name string `json:"name,required"`
	// IPv4/IPv6 address of primary or secondary nameserver, depending on what zone
	// this peer is linked to. For primary zones this IP defines the IP of the
	// secondary nameserver Cloudflare will NOTIFY upon zone changes. For secondary
	// zones this IP defines the IP of the primary nameserver Cloudflare will send
	// AXFR/IXFR requests to.
	IP string `json:"ip"`
	// Enable IXFR transfer protocol, default is AXFR. Only applicable to secondary
	// zones.
	IxfrEnable bool `json:"ixfr_enable"`
	// DNS port of primary or secondary nameserver, depending on what zone this peer is
	// linked to.
	Port float64 `json:"port"`
	// TSIG authentication will be used for zone transfer if configured.
	TSIGID string   `json:"tsig_id"`
	JSON   peerJSON `json:"-"`
}

func (*Peer) UnmarshalJSON

func (r *Peer) UnmarshalJSON(data []byte) (err error)

type PeerParam

type PeerParam struct {
	// The name of the peer.
	Name param.Field[string] `json:"name,required"`
	// IPv4/IPv6 address of primary or secondary nameserver, depending on what zone
	// this peer is linked to. For primary zones this IP defines the IP of the
	// secondary nameserver Cloudflare will NOTIFY upon zone changes. For secondary
	// zones this IP defines the IP of the primary nameserver Cloudflare will send
	// AXFR/IXFR requests to.
	IP param.Field[string] `json:"ip"`
	// Enable IXFR transfer protocol, default is AXFR. Only applicable to secondary
	// zones.
	IxfrEnable param.Field[bool] `json:"ixfr_enable"`
	// DNS port of primary or secondary nameserver, depending on what zone this peer is
	// linked to.
	Port param.Field[float64] `json:"port"`
	// TSIG authentication will be used for zone transfer if configured.
	TSIGID param.Field[string] `json:"tsig_id"`
}

func (PeerParam) MarshalJSON

func (r PeerParam) MarshalJSON() (data []byte, err error)

type Permission

type Permission = shared.Permission

This is an alias to an internal type.

type PermissionGrant

type PermissionGrant = shared.PermissionGrant

This is an alias to an internal type.

type PermissionGrantParam

type PermissionGrantParam = shared.PermissionGrantParam

This is an alias to an internal type.

type RatePlan

type RatePlan = shared.RatePlan

The rate plan applied to the subscription.

This is an alias to an internal type.

type RatePlanID added in v4.1.0

type RatePlanID = shared.RatePlanID

The ID of the rate plan.

This is an alias to an internal type.

type RatePlanParam

type RatePlanParam = shared.RatePlanParam

The rate plan applied to the subscription.

This is an alias to an internal type.

type RecordBatchParams

type RecordBatchParams struct {
	// Identifier.
	ZoneID  param.Field[string]                    `path:"zone_id,required"`
	Deletes param.Field[[]RecordBatchParamsDelete] `json:"deletes"`
	Patches param.Field[[]BatchPatchUnionParam]    `json:"patches"`
	Posts   param.Field[[]RecordUnionParam]        `json:"posts"`
	Puts    param.Field[[]BatchPutUnionParam]      `json:"puts"`
}

func (RecordBatchParams) MarshalJSON

func (r RecordBatchParams) MarshalJSON() (data []byte, err error)

type RecordBatchParamsDelete

type RecordBatchParamsDelete struct {
	// Identifier.
	ID param.Field[string] `json:"id,required"`
}

func (RecordBatchParamsDelete) MarshalJSON

func (r RecordBatchParamsDelete) MarshalJSON() (data []byte, err error)

type RecordBatchResponse

type RecordBatchResponse struct {
	Deletes []RecordResponse        `json:"deletes"`
	Patches []RecordResponse        `json:"patches"`
	Posts   []RecordResponse        `json:"posts"`
	Puts    []RecordResponse        `json:"puts"`
	JSON    recordBatchResponseJSON `json:"-"`
}

func (*RecordBatchResponse) UnmarshalJSON

func (r *RecordBatchResponse) UnmarshalJSON(data []byte) (err error)

type RecordBatchResponseEnvelope

type RecordBatchResponseEnvelope struct {
	Errors   []RecordBatchResponseEnvelopeErrors   `json:"errors,required"`
	Messages []RecordBatchResponseEnvelopeMessages `json:"messages,required"`
	// Whether the API call was successful.
	Success RecordBatchResponseEnvelopeSuccess `json:"success,required"`
	Result  RecordBatchResponse                `json:"result"`
	JSON    recordBatchResponseEnvelopeJSON    `json:"-"`
}

func (*RecordBatchResponseEnvelope) UnmarshalJSON

func (r *RecordBatchResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type RecordBatchResponseEnvelopeErrors added in v4.3.0

type RecordBatchResponseEnvelopeErrors struct {
	Code             int64                                   `json:"code,required"`
	Message          string                                  `json:"message,required"`
	DocumentationURL string                                  `json:"documentation_url"`
	Source           RecordBatchResponseEnvelopeErrorsSource `json:"source"`
	JSON             recordBatchResponseEnvelopeErrorsJSON   `json:"-"`
}

func (*RecordBatchResponseEnvelopeErrors) UnmarshalJSON added in v4.3.0

func (r *RecordBatchResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type RecordBatchResponseEnvelopeErrorsSource added in v4.3.0

type RecordBatchResponseEnvelopeErrorsSource struct {
	Pointer string                                      `json:"pointer"`
	JSON    recordBatchResponseEnvelopeErrorsSourceJSON `json:"-"`
}

func (*RecordBatchResponseEnvelopeErrorsSource) UnmarshalJSON added in v4.3.0

func (r *RecordBatchResponseEnvelopeErrorsSource) UnmarshalJSON(data []byte) (err error)

type RecordBatchResponseEnvelopeMessages added in v4.3.0

type RecordBatchResponseEnvelopeMessages struct {
	Code             int64                                     `json:"code,required"`
	Message          string                                    `json:"message,required"`
	DocumentationURL string                                    `json:"documentation_url"`
	Source           RecordBatchResponseEnvelopeMessagesSource `json:"source"`
	JSON             recordBatchResponseEnvelopeMessagesJSON   `json:"-"`
}

func (*RecordBatchResponseEnvelopeMessages) UnmarshalJSON added in v4.3.0

func (r *RecordBatchResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type RecordBatchResponseEnvelopeMessagesSource added in v4.3.0

type RecordBatchResponseEnvelopeMessagesSource struct {
	Pointer string                                        `json:"pointer"`
	JSON    recordBatchResponseEnvelopeMessagesSourceJSON `json:"-"`
}

func (*RecordBatchResponseEnvelopeMessagesSource) UnmarshalJSON added in v4.3.0

func (r *RecordBatchResponseEnvelopeMessagesSource) UnmarshalJSON(data []byte) (err error)

type RecordBatchResponseEnvelopeSuccess

type RecordBatchResponseEnvelopeSuccess bool

Whether the API call was successful.

const (
	RecordBatchResponseEnvelopeSuccessTrue RecordBatchResponseEnvelopeSuccess = true
)

func (RecordBatchResponseEnvelopeSuccess) IsKnown

type RecordDeleteParams

type RecordDeleteParams struct {
	// Identifier.
	ZoneID param.Field[string] `path:"zone_id,required"`
}

type RecordDeleteResponse

type RecordDeleteResponse struct {
	// Identifier.
	ID   string                   `json:"id"`
	JSON recordDeleteResponseJSON `json:"-"`
}

func (*RecordDeleteResponse) UnmarshalJSON

func (r *RecordDeleteResponse) UnmarshalJSON(data []byte) (err error)

type RecordDeleteResponseEnvelope

type RecordDeleteResponseEnvelope struct {
	Result RecordDeleteResponse             `json:"result"`
	JSON   recordDeleteResponseEnvelopeJSON `json:"-"`
}

func (*RecordDeleteResponseEnvelope) UnmarshalJSON

func (r *RecordDeleteResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type RecordEditParams

type RecordEditParams struct {
	// Identifier.
	ZoneID param.Field[string] `path:"zone_id,required"`
	Record RecordUnionParam    `json:"record,required"`
}

func (RecordEditParams) MarshalJSON

func (r RecordEditParams) MarshalJSON() (data []byte, err error)

type RecordEditResponseEnvelope

type RecordEditResponseEnvelope struct {
	Errors   []RecordEditResponseEnvelopeErrors   `json:"errors,required"`
	Messages []RecordEditResponseEnvelopeMessages `json:"messages,required"`
	// Whether the API call was successful.
	Success RecordEditResponseEnvelopeSuccess `json:"success,required"`
	Result  RecordResponse                    `json:"result"`
	JSON    recordEditResponseEnvelopeJSON    `json:"-"`
}

func (*RecordEditResponseEnvelope) UnmarshalJSON

func (r *RecordEditResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type RecordEditResponseEnvelopeErrors added in v4.3.0

type RecordEditResponseEnvelopeErrors struct {
	Code             int64                                  `json:"code,required"`
	Message          string                                 `json:"message,required"`
	DocumentationURL string                                 `json:"documentation_url"`
	Source           RecordEditResponseEnvelopeErrorsSource `json:"source"`
	JSON             recordEditResponseEnvelopeErrorsJSON   `json:"-"`
}

func (*RecordEditResponseEnvelopeErrors) UnmarshalJSON added in v4.3.0

func (r *RecordEditResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type RecordEditResponseEnvelopeErrorsSource added in v4.3.0

type RecordEditResponseEnvelopeErrorsSource struct {
	Pointer string                                     `json:"pointer"`
	JSON    recordEditResponseEnvelopeErrorsSourceJSON `json:"-"`
}

func (*RecordEditResponseEnvelopeErrorsSource) UnmarshalJSON added in v4.3.0

func (r *RecordEditResponseEnvelopeErrorsSource) UnmarshalJSON(data []byte) (err error)

type RecordEditResponseEnvelopeMessages added in v4.3.0

type RecordEditResponseEnvelopeMessages struct {
	Code             int64                                    `json:"code,required"`
	Message          string                                   `json:"message,required"`
	DocumentationURL string                                   `json:"documentation_url"`
	Source           RecordEditResponseEnvelopeMessagesSource `json:"source"`
	JSON             recordEditResponseEnvelopeMessagesJSON   `json:"-"`
}

func (*RecordEditResponseEnvelopeMessages) UnmarshalJSON added in v4.3.0

func (r *RecordEditResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type RecordEditResponseEnvelopeMessagesSource added in v4.3.0

type RecordEditResponseEnvelopeMessagesSource struct {
	Pointer string                                       `json:"pointer"`
	JSON    recordEditResponseEnvelopeMessagesSourceJSON `json:"-"`
}

func (*RecordEditResponseEnvelopeMessagesSource) UnmarshalJSON added in v4.3.0

func (r *RecordEditResponseEnvelopeMessagesSource) UnmarshalJSON(data []byte) (err error)

type RecordEditResponseEnvelopeSuccess

type RecordEditResponseEnvelopeSuccess bool

Whether the API call was successful.

const (
	RecordEditResponseEnvelopeSuccessTrue RecordEditResponseEnvelopeSuccess = true
)

func (RecordEditResponseEnvelopeSuccess) IsKnown

type RecordExportParams

type RecordExportParams struct {
	// Identifier.
	ZoneID param.Field[string] `path:"zone_id,required"`
}

type RecordGetParams

type RecordGetParams struct {
	// Identifier.
	ZoneID param.Field[string] `path:"zone_id,required"`
}

type RecordGetResponseEnvelope

type RecordGetResponseEnvelope struct {
	Errors   []RecordGetResponseEnvelopeErrors   `json:"errors,required"`
	Messages []RecordGetResponseEnvelopeMessages `json:"messages,required"`
	// Whether the API call was successful.
	Success RecordGetResponseEnvelopeSuccess `json:"success,required"`
	Result  RecordResponse                   `json:"result"`
	JSON    recordGetResponseEnvelopeJSON    `json:"-"`
}

func (*RecordGetResponseEnvelope) UnmarshalJSON

func (r *RecordGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type RecordGetResponseEnvelopeErrors added in v4.3.0

type RecordGetResponseEnvelopeErrors struct {
	Code             int64                                 `json:"code,required"`
	Message          string                                `json:"message,required"`
	DocumentationURL string                                `json:"documentation_url"`
	Source           RecordGetResponseEnvelopeErrorsSource `json:"source"`
	JSON             recordGetResponseEnvelopeErrorsJSON   `json:"-"`
}

func (*RecordGetResponseEnvelopeErrors) UnmarshalJSON added in v4.3.0

func (r *RecordGetResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type RecordGetResponseEnvelopeErrorsSource added in v4.3.0

type RecordGetResponseEnvelopeErrorsSource struct {
	Pointer string                                    `json:"pointer"`
	JSON    recordGetResponseEnvelopeErrorsSourceJSON `json:"-"`
}

func (*RecordGetResponseEnvelopeErrorsSource) UnmarshalJSON added in v4.3.0

func (r *RecordGetResponseEnvelopeErrorsSource) UnmarshalJSON(data []byte) (err error)

type RecordGetResponseEnvelopeMessages added in v4.3.0

type RecordGetResponseEnvelopeMessages struct {
	Code             int64                                   `json:"code,required"`
	Message          string                                  `json:"message,required"`
	DocumentationURL string                                  `json:"documentation_url"`
	Source           RecordGetResponseEnvelopeMessagesSource `json:"source"`
	JSON             recordGetResponseEnvelopeMessagesJSON   `json:"-"`
}

func (*RecordGetResponseEnvelopeMessages) UnmarshalJSON added in v4.3.0

func (r *RecordGetResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type RecordGetResponseEnvelopeMessagesSource added in v4.3.0

type RecordGetResponseEnvelopeMessagesSource struct {
	Pointer string                                      `json:"pointer"`
	JSON    recordGetResponseEnvelopeMessagesSourceJSON `json:"-"`
}

func (*RecordGetResponseEnvelopeMessagesSource) UnmarshalJSON added in v4.3.0

func (r *RecordGetResponseEnvelopeMessagesSource) UnmarshalJSON(data []byte) (err error)

type RecordGetResponseEnvelopeSuccess

type RecordGetResponseEnvelopeSuccess bool

Whether the API call was successful.

const (
	RecordGetResponseEnvelopeSuccessTrue RecordGetResponseEnvelopeSuccess = true
)

func (RecordGetResponseEnvelopeSuccess) IsKnown

type RecordImportParams

type RecordImportParams struct {
	// Identifier.
	ZoneID param.Field[string] `path:"zone_id,required"`
	// BIND config to import.
	//
	// **Tip:** When using cURL, a file can be uploaded using
	// `--form 'file=@bind_config.txt'`.
	File param.Field[string] `json:"file,required"`
	// Whether or not proxiable records should receive the performance and security
	// benefits of Cloudflare.
	//
	// The value should be either `true` or `false`.
	Proxied param.Field[string] `json:"proxied"`
}

func (RecordImportParams) MarshalMultipart

func (r RecordImportParams) MarshalMultipart() (data []byte, contentType string, err error)

type RecordImportResponse

type RecordImportResponse struct {
	// Number of DNS records added.
	RecsAdded float64 `json:"recs_added"`
	// Total number of DNS records parsed.
	TotalRecordsParsed float64                  `json:"total_records_parsed"`
	JSON               recordImportResponseJSON `json:"-"`
}

func (*RecordImportResponse) UnmarshalJSON

func (r *RecordImportResponse) UnmarshalJSON(data []byte) (err error)

type RecordImportResponseEnvelope

type RecordImportResponseEnvelope struct {
	Errors   []RecordImportResponseEnvelopeErrors   `json:"errors,required"`
	Messages []RecordImportResponseEnvelopeMessages `json:"messages,required"`
	// Whether the API call was successful.
	Success RecordImportResponseEnvelopeSuccess `json:"success,required"`
	Result  RecordImportResponse                `json:"result"`
	JSON    recordImportResponseEnvelopeJSON    `json:"-"`
}

func (*RecordImportResponseEnvelope) UnmarshalJSON

func (r *RecordImportResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type RecordImportResponseEnvelopeErrors added in v4.3.0

type RecordImportResponseEnvelopeErrors struct {
	Code             int64                                    `json:"code,required"`
	Message          string                                   `json:"message,required"`
	DocumentationURL string                                   `json:"documentation_url"`
	Source           RecordImportResponseEnvelopeErrorsSource `json:"source"`
	JSON             recordImportResponseEnvelopeErrorsJSON   `json:"-"`
}

func (*RecordImportResponseEnvelopeErrors) UnmarshalJSON added in v4.3.0

func (r *RecordImportResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type RecordImportResponseEnvelopeErrorsSource added in v4.3.0

type RecordImportResponseEnvelopeErrorsSource struct {
	Pointer string                                       `json:"pointer"`
	JSON    recordImportResponseEnvelopeErrorsSourceJSON `json:"-"`
}

func (*RecordImportResponseEnvelopeErrorsSource) UnmarshalJSON added in v4.3.0

func (r *RecordImportResponseEnvelopeErrorsSource) UnmarshalJSON(data []byte) (err error)

type RecordImportResponseEnvelopeMessages added in v4.3.0

type RecordImportResponseEnvelopeMessages struct {
	Code             int64                                      `json:"code,required"`
	Message          string                                     `json:"message,required"`
	DocumentationURL string                                     `json:"documentation_url"`
	Source           RecordImportResponseEnvelopeMessagesSource `json:"source"`
	JSON             recordImportResponseEnvelopeMessagesJSON   `json:"-"`
}

func (*RecordImportResponseEnvelopeMessages) UnmarshalJSON added in v4.3.0

func (r *RecordImportResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type RecordImportResponseEnvelopeMessagesSource added in v4.3.0

type RecordImportResponseEnvelopeMessagesSource struct {
	Pointer string                                         `json:"pointer"`
	JSON    recordImportResponseEnvelopeMessagesSourceJSON `json:"-"`
}

func (*RecordImportResponseEnvelopeMessagesSource) UnmarshalJSON added in v4.3.0

func (r *RecordImportResponseEnvelopeMessagesSource) UnmarshalJSON(data []byte) (err error)

type RecordImportResponseEnvelopeSuccess

type RecordImportResponseEnvelopeSuccess bool

Whether the API call was successful.

const (
	RecordImportResponseEnvelopeSuccessTrue RecordImportResponseEnvelopeSuccess = true
)

func (RecordImportResponseEnvelopeSuccess) IsKnown

type RecordListParams

type RecordListParams struct {
	// Identifier.
	ZoneID  param.Field[string]                  `path:"zone_id,required"`
	Comment param.Field[RecordListParamsComment] `query:"comment"`
	Content param.Field[RecordListParamsContent] `query:"content"`
	// Direction to order DNS records in.
	Direction param.Field[shared.SortDirection] `query:"direction"`
	// Whether to match all search requirements or at least one (any). If set to `all`,
	// acts like a logical AND between filters. If set to `any`, acts like a logical OR
	// instead. Note that the interaction between tag filters is controlled by the
	// `tag-match` parameter instead.
	Match param.Field[RecordListParamsMatch] `query:"match"`
	Name  param.Field[RecordListParamsName]  `query:"name"`
	// Field to order DNS records by.
	Order param.Field[RecordListParamsOrder] `query:"order"`
	// Page number of paginated results.
	Page param.Field[float64] `query:"page"`
	// Number of DNS records per page.
	PerPage param.Field[float64] `query:"per_page"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `query:"proxied"`
	// Allows searching in multiple properties of a DNS record simultaneously. This
	// parameter is intended for human users, not automation. Its exact behavior is
	// intentionally left unspecified and is subject to change in the future. This
	// parameter works independently of the `match` setting. For automated searches,
	// please use the other available parameters.
	Search param.Field[string]              `query:"search"`
	Tag    param.Field[RecordListParamsTag] `query:"tag"`
	// Whether to match all tag search requirements or at least one (any). If set to
	// `all`, acts like a logical AND between tag filters. If set to `any`, acts like a
	// logical OR instead. Note that the regular `match` parameter is still used to
	// combine the resulting condition with other filters that aren't related to tags.
	TagMatch param.Field[RecordListParamsTagMatch] `query:"tag_match"`
	// Record type.
	Type param.Field[RecordListParamsType] `query:"type"`
}

func (RecordListParams) URLQuery

func (r RecordListParams) URLQuery() (v url.Values)

URLQuery serializes RecordListParams's query parameters as `url.Values`.

type RecordListParamsComment

type RecordListParamsComment struct {
	// If this parameter is present, only records _without_ a comment are returned.
	Absent param.Field[string] `query:"absent"`
	// Substring of the DNS record comment. Comment filters are case-insensitive.
	Contains param.Field[string] `query:"contains"`
	// Suffix of the DNS record comment. Comment filters are case-insensitive.
	Endswith param.Field[string] `query:"endswith"`
	// Exact value of the DNS record comment. Comment filters are case-insensitive.
	Exact param.Field[string] `query:"exact"`
	// If this parameter is present, only records _with_ a comment are returned.
	Present param.Field[string] `query:"present"`
	// Prefix of the DNS record comment. Comment filters are case-insensitive.
	Startswith param.Field[string] `query:"startswith"`
}

func (RecordListParamsComment) URLQuery

func (r RecordListParamsComment) URLQuery() (v url.Values)

URLQuery serializes RecordListParamsComment's query parameters as `url.Values`.

type RecordListParamsContent

type RecordListParamsContent struct {
	// Substring of the DNS record content. Content filters are case-insensitive.
	Contains param.Field[string] `query:"contains"`
	// Suffix of the DNS record content. Content filters are case-insensitive.
	Endswith param.Field[string] `query:"endswith"`
	// Exact value of the DNS record content. Content filters are case-insensitive.
	Exact param.Field[string] `query:"exact"`
	// Prefix of the DNS record content. Content filters are case-insensitive.
	Startswith param.Field[string] `query:"startswith"`
}

func (RecordListParamsContent) URLQuery

func (r RecordListParamsContent) URLQuery() (v url.Values)

URLQuery serializes RecordListParamsContent's query parameters as `url.Values`.

type RecordListParamsMatch

type RecordListParamsMatch string

Whether to match all search requirements or at least one (any). If set to `all`, acts like a logical AND between filters. If set to `any`, acts like a logical OR instead. Note that the interaction between tag filters is controlled by the `tag-match` parameter instead.

const (
	RecordListParamsMatchAny RecordListParamsMatch = "any"
	RecordListParamsMatchAll RecordListParamsMatch = "all"
)

func (RecordListParamsMatch) IsKnown

func (r RecordListParamsMatch) IsKnown() bool

type RecordListParamsName

type RecordListParamsName struct {
	// Substring of the DNS record name. Name filters are case-insensitive.
	Contains param.Field[string] `query:"contains"`
	// Suffix of the DNS record name. Name filters are case-insensitive.
	Endswith param.Field[string] `query:"endswith"`
	// Exact value of the DNS record name. Name filters are case-insensitive.
	Exact param.Field[string] `query:"exact"`
	// Prefix of the DNS record name. Name filters are case-insensitive.
	Startswith param.Field[string] `query:"startswith"`
}

func (RecordListParamsName) URLQuery

func (r RecordListParamsName) URLQuery() (v url.Values)

URLQuery serializes RecordListParamsName's query parameters as `url.Values`.

type RecordListParamsOrder

type RecordListParamsOrder string

Field to order DNS records by.

const (
	RecordListParamsOrderType    RecordListParamsOrder = "type"
	RecordListParamsOrderName    RecordListParamsOrder = "name"
	RecordListParamsOrderContent RecordListParamsOrder = "content"
	RecordListParamsOrderTTL     RecordListParamsOrder = "ttl"
	RecordListParamsOrderProxied RecordListParamsOrder = "proxied"
)

func (RecordListParamsOrder) IsKnown

func (r RecordListParamsOrder) IsKnown() bool

type RecordListParamsTag

type RecordListParamsTag struct {
	// Name of a tag which must _not_ be present on the DNS record. Tag filters are
	// case-insensitive.
	Absent param.Field[string] `query:"absent"`
	// A tag and value, of the form `<tag-name>:<tag-value>`. The API will only return
	// DNS records that have a tag named `<tag-name>` whose value contains
	// `<tag-value>`. Tag filters are case-insensitive.
	Contains param.Field[string] `query:"contains"`
	// A tag and value, of the form `<tag-name>:<tag-value>`. The API will only return
	// DNS records that have a tag named `<tag-name>` whose value ends with
	// `<tag-value>`. Tag filters are case-insensitive.
	Endswith param.Field[string] `query:"endswith"`
	// A tag and value, of the form `<tag-name>:<tag-value>`. The API will only return
	// DNS records that have a tag named `<tag-name>` whose value is `<tag-value>`. Tag
	// filters are case-insensitive.
	Exact param.Field[string] `query:"exact"`
	// Name of a tag which must be present on the DNS record. Tag filters are
	// case-insensitive.
	Present param.Field[string] `query:"present"`
	// A tag and value, of the form `<tag-name>:<tag-value>`. The API will only return
	// DNS records that have a tag named `<tag-name>` whose value starts with
	// `<tag-value>`. Tag filters are case-insensitive.
	Startswith param.Field[string] `query:"startswith"`
}

func (RecordListParamsTag) URLQuery

func (r RecordListParamsTag) URLQuery() (v url.Values)

URLQuery serializes RecordListParamsTag's query parameters as `url.Values`.

type RecordListParamsTagMatch

type RecordListParamsTagMatch string

Whether to match all tag search requirements or at least one (any). If set to `all`, acts like a logical AND between tag filters. If set to `any`, acts like a logical OR instead. Note that the regular `match` parameter is still used to combine the resulting condition with other filters that aren't related to tags.

const (
	RecordListParamsTagMatchAny RecordListParamsTagMatch = "any"
	RecordListParamsTagMatchAll RecordListParamsTagMatch = "all"
)

func (RecordListParamsTagMatch) IsKnown

func (r RecordListParamsTagMatch) IsKnown() bool

type RecordListParamsType

type RecordListParamsType string

Record type.

const (
	RecordListParamsTypeA          RecordListParamsType = "A"
	RecordListParamsTypeAAAA       RecordListParamsType = "AAAA"
	RecordListParamsTypeCAA        RecordListParamsType = "CAA"
	RecordListParamsTypeCERT       RecordListParamsType = "CERT"
	RecordListParamsTypeCNAME      RecordListParamsType = "CNAME"
	RecordListParamsTypeDNSKEY     RecordListParamsType = "DNSKEY"
	RecordListParamsTypeDS         RecordListParamsType = "DS"
	RecordListParamsTypeHTTPS      RecordListParamsType = "HTTPS"
	RecordListParamsTypeLOC        RecordListParamsType = "LOC"
	RecordListParamsTypeMX         RecordListParamsType = "MX"
	RecordListParamsTypeNAPTR      RecordListParamsType = "NAPTR"
	RecordListParamsTypeNS         RecordListParamsType = "NS"
	RecordListParamsTypeOpenpgpkey RecordListParamsType = "OPENPGPKEY"
	RecordListParamsTypePTR        RecordListParamsType = "PTR"
	RecordListParamsTypeSMIMEA     RecordListParamsType = "SMIMEA"
	RecordListParamsTypeSRV        RecordListParamsType = "SRV"
	RecordListParamsTypeSSHFP      RecordListParamsType = "SSHFP"
	RecordListParamsTypeSVCB       RecordListParamsType = "SVCB"
	RecordListParamsTypeTLSA       RecordListParamsType = "TLSA"
	RecordListParamsTypeTXT        RecordListParamsType = "TXT"
	RecordListParamsTypeURI        RecordListParamsType = "URI"
)

func (RecordListParamsType) IsKnown

func (r RecordListParamsType) IsKnown() bool

type RecordNewParams

type RecordNewParams struct {
	// Identifier.
	ZoneID param.Field[string] `path:"zone_id,required"`
	Record RecordUnionParam    `json:"record,required"`
}

func (RecordNewParams) MarshalJSON

func (r RecordNewParams) MarshalJSON() (data []byte, err error)

type RecordNewResponseEnvelope

type RecordNewResponseEnvelope struct {
	Errors   []RecordNewResponseEnvelopeErrors   `json:"errors,required"`
	Messages []RecordNewResponseEnvelopeMessages `json:"messages,required"`
	// Whether the API call was successful.
	Success RecordNewResponseEnvelopeSuccess `json:"success,required"`
	Result  RecordResponse                   `json:"result"`
	JSON    recordNewResponseEnvelopeJSON    `json:"-"`
}

func (*RecordNewResponseEnvelope) UnmarshalJSON

func (r *RecordNewResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type RecordNewResponseEnvelopeErrors added in v4.3.0

type RecordNewResponseEnvelopeErrors struct {
	Code             int64                                 `json:"code,required"`
	Message          string                                `json:"message,required"`
	DocumentationURL string                                `json:"documentation_url"`
	Source           RecordNewResponseEnvelopeErrorsSource `json:"source"`
	JSON             recordNewResponseEnvelopeErrorsJSON   `json:"-"`
}

func (*RecordNewResponseEnvelopeErrors) UnmarshalJSON added in v4.3.0

func (r *RecordNewResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type RecordNewResponseEnvelopeErrorsSource added in v4.3.0

type RecordNewResponseEnvelopeErrorsSource struct {
	Pointer string                                    `json:"pointer"`
	JSON    recordNewResponseEnvelopeErrorsSourceJSON `json:"-"`
}

func (*RecordNewResponseEnvelopeErrorsSource) UnmarshalJSON added in v4.3.0

func (r *RecordNewResponseEnvelopeErrorsSource) UnmarshalJSON(data []byte) (err error)

type RecordNewResponseEnvelopeMessages added in v4.3.0

type RecordNewResponseEnvelopeMessages struct {
	Code             int64                                   `json:"code,required"`
	Message          string                                  `json:"message,required"`
	DocumentationURL string                                  `json:"documentation_url"`
	Source           RecordNewResponseEnvelopeMessagesSource `json:"source"`
	JSON             recordNewResponseEnvelopeMessagesJSON   `json:"-"`
}

func (*RecordNewResponseEnvelopeMessages) UnmarshalJSON added in v4.3.0

func (r *RecordNewResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type RecordNewResponseEnvelopeMessagesSource added in v4.3.0

type RecordNewResponseEnvelopeMessagesSource struct {
	Pointer string                                      `json:"pointer"`
	JSON    recordNewResponseEnvelopeMessagesSourceJSON `json:"-"`
}

func (*RecordNewResponseEnvelopeMessagesSource) UnmarshalJSON added in v4.3.0

func (r *RecordNewResponseEnvelopeMessagesSource) UnmarshalJSON(data []byte) (err error)

type RecordNewResponseEnvelopeSuccess

type RecordNewResponseEnvelopeSuccess bool

Whether the API call was successful.

const (
	RecordNewResponseEnvelopeSuccessTrue RecordNewResponseEnvelopeSuccess = true
)

func (RecordNewResponseEnvelopeSuccess) IsKnown

type RecordOpenpgpkeyParam

type RecordOpenpgpkeyParam struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// A single Base64-encoded OpenPGP Transferable Public Key (RFC 4880 Section 11.1)
	Content param.Field[string] `json:"content"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `json:"proxied"`
	// Settings for the DNS record.
	Settings param.Field[RecordOpenpgpkeySettingsParam] `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags param.Field[[]RecordTagsParam] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
	// Record type.
	Type param.Field[RecordOpenpgpkeyType] `json:"type"`
}

func (RecordOpenpgpkeyParam) MarshalJSON

func (r RecordOpenpgpkeyParam) MarshalJSON() (data []byte, err error)

type RecordOpenpgpkeySettingsParam

type RecordOpenpgpkeySettingsParam struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only param.Field[bool] `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only param.Field[bool] `json:"ipv6_only"`
}

Settings for the DNS record.

func (RecordOpenpgpkeySettingsParam) MarshalJSON

func (r RecordOpenpgpkeySettingsParam) MarshalJSON() (data []byte, err error)

type RecordOpenpgpkeyType

type RecordOpenpgpkeyType string

Record type.

const (
	RecordOpenpgpkeyTypeOpenpgpkey RecordOpenpgpkeyType = "OPENPGPKEY"
)

func (RecordOpenpgpkeyType) IsKnown

func (r RecordOpenpgpkeyType) IsKnown() bool

type RecordParam

type RecordParam struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// A valid IPv4 address.
	Content param.Field[string]      `json:"content" format:"ipv4"`
	Data    param.Field[interface{}] `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name"`
	// Required for MX, SRV and URI records; unused by other record types. Records with
	// lower priorities are preferred.
	Priority param.Field[float64] `json:"priority"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied  param.Field[bool]        `json:"proxied"`
	Settings param.Field[interface{}] `json:"settings"`
	Tags     param.Field[interface{}] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
	// Record type.
	Type param.Field[RecordType] `json:"type"`
}

func (RecordParam) MarshalJSON

func (r RecordParam) MarshalJSON() (data []byte, err error)

type RecordResponse

type RecordResponse struct {
	// Identifier.
	ID string `json:"id"`
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment string `json:"comment"`
	// When the record comment was last modified. Omitted if there is no comment.
	CommentModifiedOn time.Time `json:"comment_modified_on" format:"date-time"`
	// A valid IPv4 address.
	Content string `json:"content" format:"ipv4"`
	// When the record was created.
	CreatedOn time.Time `json:"created_on" format:"date-time"`
	// This field can have the runtime type of [CAARecordData], [CERTRecordData],
	// [DNSKEYRecordData], [DSRecordData], [HTTPSRecordData], [LOCRecordData],
	// [NAPTRRecordData], [SMIMEARecordData], [SRVRecordData], [SSHFPRecordData],
	// [SVCBRecordData], [TLSARecordData], [URIRecordData].
	Data interface{} `json:"data"`
	// This field can have the runtime type of [interface{}].
	Meta interface{} `json:"meta"`
	// When the record was last modified.
	ModifiedOn time.Time `json:"modified_on" format:"date-time"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name string `json:"name"`
	// Required for MX, SRV and URI records; unused by other record types. Records with
	// lower priorities are preferred.
	Priority float64 `json:"priority"`
	// Whether the record can be proxied by Cloudflare or not.
	Proxiable bool `json:"proxiable"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied bool `json:"proxied"`
	// This field can have the runtime type of [ARecordSettings], [AAAARecordSettings],
	// [CAARecordSettings], [CERTRecordSettings], [CNAMERecordSettings],
	// [DNSKEYRecordSettings], [DSRecordSettings], [HTTPSRecordSettings],
	// [LOCRecordSettings], [MXRecordSettings], [NAPTRRecordSettings],
	// [NSRecordSettings], [RecordResponseOpenpgpkeySettings], [PTRRecordSettings],
	// [SMIMEARecordSettings], [SRVRecordSettings], [SSHFPRecordSettings],
	// [SVCBRecordSettings], [TLSARecordSettings], [TXTRecordSettings],
	// [URIRecordSettings].
	Settings interface{} `json:"settings"`
	// This field can have the runtime type of [[]RecordTags].
	Tags interface{} `json:"tags"`
	// When the record tags were last modified. Omitted if there are no tags.
	TagsModifiedOn time.Time `json:"tags_modified_on" format:"date-time"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL TTL `json:"ttl"`
	// Record type.
	Type RecordResponseType `json:"type"`
	JSON recordResponseJSON `json:"-"`
	// contains filtered or unexported fields
}

func (*RecordResponse) UnmarshalJSON

func (r *RecordResponse) UnmarshalJSON(data []byte) (err error)

type RecordResponseA added in v4.2.0

type RecordResponseA struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the record was created.
	CreatedOn time.Time `json:"created_on,required" format:"date-time"`
	// Extra Cloudflare-specific information about the record.
	Meta interface{} `json:"meta,required"`
	// When the record was last modified.
	ModifiedOn time.Time `json:"modified_on,required" format:"date-time"`
	// Whether the record can be proxied by Cloudflare or not.
	Proxiable bool `json:"proxiable,required"`
	// When the record comment was last modified. Omitted if there is no comment.
	CommentModifiedOn time.Time `json:"comment_modified_on" format:"date-time"`
	// When the record tags were last modified. Omitted if there are no tags.
	TagsModifiedOn time.Time           `json:"tags_modified_on" format:"date-time"`
	JSON           recordResponseAJSON `json:"-"`
	ARecord
}

func (*RecordResponseA) UnmarshalJSON added in v4.2.0

func (r *RecordResponseA) UnmarshalJSON(data []byte) (err error)

type RecordResponseAAAA added in v4.2.0

type RecordResponseAAAA struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the record was created.
	CreatedOn time.Time `json:"created_on,required" format:"date-time"`
	// Extra Cloudflare-specific information about the record.
	Meta interface{} `json:"meta,required"`
	// When the record was last modified.
	ModifiedOn time.Time `json:"modified_on,required" format:"date-time"`
	// Whether the record can be proxied by Cloudflare or not.
	Proxiable bool `json:"proxiable,required"`
	// When the record comment was last modified. Omitted if there is no comment.
	CommentModifiedOn time.Time `json:"comment_modified_on" format:"date-time"`
	// When the record tags were last modified. Omitted if there are no tags.
	TagsModifiedOn time.Time              `json:"tags_modified_on" format:"date-time"`
	JSON           recordResponseAAAAJSON `json:"-"`
	AAAARecord
}

func (*RecordResponseAAAA) UnmarshalJSON added in v4.2.0

func (r *RecordResponseAAAA) UnmarshalJSON(data []byte) (err error)

type RecordResponseCAA added in v4.2.0

type RecordResponseCAA struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the record was created.
	CreatedOn time.Time `json:"created_on,required" format:"date-time"`
	// Extra Cloudflare-specific information about the record.
	Meta interface{} `json:"meta,required"`
	// When the record was last modified.
	ModifiedOn time.Time `json:"modified_on,required" format:"date-time"`
	// Whether the record can be proxied by Cloudflare or not.
	Proxiable bool `json:"proxiable,required"`
	// When the record comment was last modified. Omitted if there is no comment.
	CommentModifiedOn time.Time `json:"comment_modified_on" format:"date-time"`
	// When the record tags were last modified. Omitted if there are no tags.
	TagsModifiedOn time.Time             `json:"tags_modified_on" format:"date-time"`
	JSON           recordResponseCAAJSON `json:"-"`
	CAARecord
}

func (*RecordResponseCAA) UnmarshalJSON added in v4.2.0

func (r *RecordResponseCAA) UnmarshalJSON(data []byte) (err error)

type RecordResponseCERT added in v4.2.0

type RecordResponseCERT struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the record was created.
	CreatedOn time.Time `json:"created_on,required" format:"date-time"`
	// Extra Cloudflare-specific information about the record.
	Meta interface{} `json:"meta,required"`
	// When the record was last modified.
	ModifiedOn time.Time `json:"modified_on,required" format:"date-time"`
	// Whether the record can be proxied by Cloudflare or not.
	Proxiable bool `json:"proxiable,required"`
	// When the record comment was last modified. Omitted if there is no comment.
	CommentModifiedOn time.Time `json:"comment_modified_on" format:"date-time"`
	// When the record tags were last modified. Omitted if there are no tags.
	TagsModifiedOn time.Time              `json:"tags_modified_on" format:"date-time"`
	JSON           recordResponseCERTJSON `json:"-"`
	CERTRecord
}

func (*RecordResponseCERT) UnmarshalJSON added in v4.2.0

func (r *RecordResponseCERT) UnmarshalJSON(data []byte) (err error)

type RecordResponseCNAME added in v4.2.0

type RecordResponseCNAME struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the record was created.
	CreatedOn time.Time `json:"created_on,required" format:"date-time"`
	// Extra Cloudflare-specific information about the record.
	Meta interface{} `json:"meta,required"`
	// When the record was last modified.
	ModifiedOn time.Time `json:"modified_on,required" format:"date-time"`
	// Whether the record can be proxied by Cloudflare or not.
	Proxiable bool `json:"proxiable,required"`
	// When the record comment was last modified. Omitted if there is no comment.
	CommentModifiedOn time.Time `json:"comment_modified_on" format:"date-time"`
	// When the record tags were last modified. Omitted if there are no tags.
	TagsModifiedOn time.Time               `json:"tags_modified_on" format:"date-time"`
	JSON           recordResponseCNAMEJSON `json:"-"`
	CNAMERecord
}

func (*RecordResponseCNAME) UnmarshalJSON added in v4.2.0

func (r *RecordResponseCNAME) UnmarshalJSON(data []byte) (err error)

type RecordResponseDNSKEY added in v4.2.0

type RecordResponseDNSKEY struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the record was created.
	CreatedOn time.Time `json:"created_on,required" format:"date-time"`
	// Extra Cloudflare-specific information about the record.
	Meta interface{} `json:"meta,required"`
	// When the record was last modified.
	ModifiedOn time.Time `json:"modified_on,required" format:"date-time"`
	// Whether the record can be proxied by Cloudflare or not.
	Proxiable bool `json:"proxiable,required"`
	// When the record comment was last modified. Omitted if there is no comment.
	CommentModifiedOn time.Time `json:"comment_modified_on" format:"date-time"`
	// When the record tags were last modified. Omitted if there are no tags.
	TagsModifiedOn time.Time                `json:"tags_modified_on" format:"date-time"`
	JSON           recordResponseDNSKEYJSON `json:"-"`
	DNSKEYRecord
}

func (*RecordResponseDNSKEY) UnmarshalJSON added in v4.2.0

func (r *RecordResponseDNSKEY) UnmarshalJSON(data []byte) (err error)

type RecordResponseDS added in v4.2.0

type RecordResponseDS struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the record was created.
	CreatedOn time.Time `json:"created_on,required" format:"date-time"`
	// Extra Cloudflare-specific information about the record.
	Meta interface{} `json:"meta,required"`
	// When the record was last modified.
	ModifiedOn time.Time `json:"modified_on,required" format:"date-time"`
	// Whether the record can be proxied by Cloudflare or not.
	Proxiable bool `json:"proxiable,required"`
	// When the record comment was last modified. Omitted if there is no comment.
	CommentModifiedOn time.Time `json:"comment_modified_on" format:"date-time"`
	// When the record tags were last modified. Omitted if there are no tags.
	TagsModifiedOn time.Time            `json:"tags_modified_on" format:"date-time"`
	JSON           recordResponseDSJSON `json:"-"`
	DSRecord
}

func (*RecordResponseDS) UnmarshalJSON added in v4.2.0

func (r *RecordResponseDS) UnmarshalJSON(data []byte) (err error)

type RecordResponseHTTPS added in v4.2.0

type RecordResponseHTTPS struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the record was created.
	CreatedOn time.Time `json:"created_on,required" format:"date-time"`
	// Extra Cloudflare-specific information about the record.
	Meta interface{} `json:"meta,required"`
	// When the record was last modified.
	ModifiedOn time.Time `json:"modified_on,required" format:"date-time"`
	// Whether the record can be proxied by Cloudflare or not.
	Proxiable bool `json:"proxiable,required"`
	// When the record comment was last modified. Omitted if there is no comment.
	CommentModifiedOn time.Time `json:"comment_modified_on" format:"date-time"`
	// When the record tags were last modified. Omitted if there are no tags.
	TagsModifiedOn time.Time               `json:"tags_modified_on" format:"date-time"`
	JSON           recordResponseHTTPSJSON `json:"-"`
	HTTPSRecord
}

func (*RecordResponseHTTPS) UnmarshalJSON added in v4.2.0

func (r *RecordResponseHTTPS) UnmarshalJSON(data []byte) (err error)

type RecordResponseLOC added in v4.2.0

type RecordResponseLOC struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the record was created.
	CreatedOn time.Time `json:"created_on,required" format:"date-time"`
	// Extra Cloudflare-specific information about the record.
	Meta interface{} `json:"meta,required"`
	// When the record was last modified.
	ModifiedOn time.Time `json:"modified_on,required" format:"date-time"`
	// Whether the record can be proxied by Cloudflare or not.
	Proxiable bool `json:"proxiable,required"`
	// When the record comment was last modified. Omitted if there is no comment.
	CommentModifiedOn time.Time `json:"comment_modified_on" format:"date-time"`
	// When the record tags were last modified. Omitted if there are no tags.
	TagsModifiedOn time.Time             `json:"tags_modified_on" format:"date-time"`
	JSON           recordResponseLOCJSON `json:"-"`
	LOCRecord
}

func (*RecordResponseLOC) UnmarshalJSON added in v4.2.0

func (r *RecordResponseLOC) UnmarshalJSON(data []byte) (err error)

type RecordResponseMX added in v4.2.0

type RecordResponseMX struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the record was created.
	CreatedOn time.Time `json:"created_on,required" format:"date-time"`
	// Extra Cloudflare-specific information about the record.
	Meta interface{} `json:"meta,required"`
	// When the record was last modified.
	ModifiedOn time.Time `json:"modified_on,required" format:"date-time"`
	// Whether the record can be proxied by Cloudflare or not.
	Proxiable bool `json:"proxiable,required"`
	// When the record comment was last modified. Omitted if there is no comment.
	CommentModifiedOn time.Time `json:"comment_modified_on" format:"date-time"`
	// When the record tags were last modified. Omitted if there are no tags.
	TagsModifiedOn time.Time            `json:"tags_modified_on" format:"date-time"`
	JSON           recordResponseMXJSON `json:"-"`
	MXRecord
}

func (*RecordResponseMX) UnmarshalJSON added in v4.2.0

func (r *RecordResponseMX) UnmarshalJSON(data []byte) (err error)

type RecordResponseNAPTR added in v4.2.0

type RecordResponseNAPTR struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the record was created.
	CreatedOn time.Time `json:"created_on,required" format:"date-time"`
	// Extra Cloudflare-specific information about the record.
	Meta interface{} `json:"meta,required"`
	// When the record was last modified.
	ModifiedOn time.Time `json:"modified_on,required" format:"date-time"`
	// Whether the record can be proxied by Cloudflare or not.
	Proxiable bool `json:"proxiable,required"`
	// When the record comment was last modified. Omitted if there is no comment.
	CommentModifiedOn time.Time `json:"comment_modified_on" format:"date-time"`
	// When the record tags were last modified. Omitted if there are no tags.
	TagsModifiedOn time.Time               `json:"tags_modified_on" format:"date-time"`
	JSON           recordResponseNAPTRJSON `json:"-"`
	NAPTRRecord
}

func (*RecordResponseNAPTR) UnmarshalJSON added in v4.2.0

func (r *RecordResponseNAPTR) UnmarshalJSON(data []byte) (err error)

type RecordResponseNS added in v4.2.0

type RecordResponseNS struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the record was created.
	CreatedOn time.Time `json:"created_on,required" format:"date-time"`
	// Extra Cloudflare-specific information about the record.
	Meta interface{} `json:"meta,required"`
	// When the record was last modified.
	ModifiedOn time.Time `json:"modified_on,required" format:"date-time"`
	// Whether the record can be proxied by Cloudflare or not.
	Proxiable bool `json:"proxiable,required"`
	// When the record comment was last modified. Omitted if there is no comment.
	CommentModifiedOn time.Time `json:"comment_modified_on" format:"date-time"`
	// When the record tags were last modified. Omitted if there are no tags.
	TagsModifiedOn time.Time            `json:"tags_modified_on" format:"date-time"`
	JSON           recordResponseNSJSON `json:"-"`
	NSRecord
}

func (*RecordResponseNS) UnmarshalJSON added in v4.2.0

func (r *RecordResponseNS) UnmarshalJSON(data []byte) (err error)

type RecordResponseOpenpgpkey

type RecordResponseOpenpgpkey struct {
	// Identifier.
	ID string `json:"id,required"`
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment string `json:"comment,required"`
	// A single Base64-encoded OpenPGP Transferable Public Key (RFC 4880 Section 11.1)
	Content string `json:"content,required"`
	// When the record was created.
	CreatedOn time.Time `json:"created_on,required" format:"date-time"`
	// Extra Cloudflare-specific information about the record.
	Meta interface{} `json:"meta,required"`
	// When the record was last modified.
	ModifiedOn time.Time `json:"modified_on,required" format:"date-time"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name string `json:"name,required"`
	// Whether the record can be proxied by Cloudflare or not.
	Proxiable bool `json:"proxiable,required"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied bool `json:"proxied,required"`
	// Settings for the DNS record.
	Settings RecordResponseOpenpgpkeySettings `json:"settings,required"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags []RecordTags `json:"tags,required"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL TTL `json:"ttl,required"`
	// Record type.
	Type RecordResponseOpenpgpkeyType `json:"type,required"`
	// When the record comment was last modified. Omitted if there is no comment.
	CommentModifiedOn time.Time `json:"comment_modified_on" format:"date-time"`
	// When the record tags were last modified. Omitted if there are no tags.
	TagsModifiedOn time.Time                    `json:"tags_modified_on" format:"date-time"`
	JSON           recordResponseOpenpgpkeyJSON `json:"-"`
}

func (*RecordResponseOpenpgpkey) UnmarshalJSON

func (r *RecordResponseOpenpgpkey) UnmarshalJSON(data []byte) (err error)

type RecordResponseOpenpgpkeySettings

type RecordResponseOpenpgpkeySettings struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only bool `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only bool                                 `json:"ipv6_only"`
	JSON     recordResponseOpenpgpkeySettingsJSON `json:"-"`
}

Settings for the DNS record.

func (*RecordResponseOpenpgpkeySettings) UnmarshalJSON

func (r *RecordResponseOpenpgpkeySettings) UnmarshalJSON(data []byte) (err error)

type RecordResponseOpenpgpkeyType

type RecordResponseOpenpgpkeyType string

Record type.

const (
	RecordResponseOpenpgpkeyTypeOpenpgpkey RecordResponseOpenpgpkeyType = "OPENPGPKEY"
)

func (RecordResponseOpenpgpkeyType) IsKnown

func (r RecordResponseOpenpgpkeyType) IsKnown() bool

type RecordResponsePTR added in v4.2.0

type RecordResponsePTR struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the record was created.
	CreatedOn time.Time `json:"created_on,required" format:"date-time"`
	// Extra Cloudflare-specific information about the record.
	Meta interface{} `json:"meta,required"`
	// When the record was last modified.
	ModifiedOn time.Time `json:"modified_on,required" format:"date-time"`
	// Whether the record can be proxied by Cloudflare or not.
	Proxiable bool `json:"proxiable,required"`
	// When the record comment was last modified. Omitted if there is no comment.
	CommentModifiedOn time.Time `json:"comment_modified_on" format:"date-time"`
	// When the record tags were last modified. Omitted if there are no tags.
	TagsModifiedOn time.Time             `json:"tags_modified_on" format:"date-time"`
	JSON           recordResponsePTRJSON `json:"-"`
	PTRRecord
}

func (*RecordResponsePTR) UnmarshalJSON added in v4.2.0

func (r *RecordResponsePTR) UnmarshalJSON(data []byte) (err error)

type RecordResponseSMIMEA added in v4.2.0

type RecordResponseSMIMEA struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the record was created.
	CreatedOn time.Time `json:"created_on,required" format:"date-time"`
	// Extra Cloudflare-specific information about the record.
	Meta interface{} `json:"meta,required"`
	// When the record was last modified.
	ModifiedOn time.Time `json:"modified_on,required" format:"date-time"`
	// Whether the record can be proxied by Cloudflare or not.
	Proxiable bool `json:"proxiable,required"`
	// When the record comment was last modified. Omitted if there is no comment.
	CommentModifiedOn time.Time `json:"comment_modified_on" format:"date-time"`
	// When the record tags were last modified. Omitted if there are no tags.
	TagsModifiedOn time.Time                `json:"tags_modified_on" format:"date-time"`
	JSON           recordResponseSMIMEAJSON `json:"-"`
	SMIMEARecord
}

func (*RecordResponseSMIMEA) UnmarshalJSON added in v4.2.0

func (r *RecordResponseSMIMEA) UnmarshalJSON(data []byte) (err error)

type RecordResponseSRV added in v4.2.0

type RecordResponseSRV struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the record was created.
	CreatedOn time.Time `json:"created_on,required" format:"date-time"`
	// Extra Cloudflare-specific information about the record.
	Meta interface{} `json:"meta,required"`
	// When the record was last modified.
	ModifiedOn time.Time `json:"modified_on,required" format:"date-time"`
	// Whether the record can be proxied by Cloudflare or not.
	Proxiable bool `json:"proxiable,required"`
	// When the record comment was last modified. Omitted if there is no comment.
	CommentModifiedOn time.Time `json:"comment_modified_on" format:"date-time"`
	// When the record tags were last modified. Omitted if there are no tags.
	TagsModifiedOn time.Time             `json:"tags_modified_on" format:"date-time"`
	JSON           recordResponseSRVJSON `json:"-"`
	SRVRecord
}

func (*RecordResponseSRV) UnmarshalJSON added in v4.2.0

func (r *RecordResponseSRV) UnmarshalJSON(data []byte) (err error)

type RecordResponseSSHFP added in v4.2.0

type RecordResponseSSHFP struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the record was created.
	CreatedOn time.Time `json:"created_on,required" format:"date-time"`
	// Extra Cloudflare-specific information about the record.
	Meta interface{} `json:"meta,required"`
	// When the record was last modified.
	ModifiedOn time.Time `json:"modified_on,required" format:"date-time"`
	// Whether the record can be proxied by Cloudflare or not.
	Proxiable bool `json:"proxiable,required"`
	// When the record comment was last modified. Omitted if there is no comment.
	CommentModifiedOn time.Time `json:"comment_modified_on" format:"date-time"`
	// When the record tags were last modified. Omitted if there are no tags.
	TagsModifiedOn time.Time               `json:"tags_modified_on" format:"date-time"`
	JSON           recordResponseSSHFPJSON `json:"-"`
	SSHFPRecord
}

func (*RecordResponseSSHFP) UnmarshalJSON added in v4.2.0

func (r *RecordResponseSSHFP) UnmarshalJSON(data []byte) (err error)

type RecordResponseSVCB added in v4.2.0

type RecordResponseSVCB struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the record was created.
	CreatedOn time.Time `json:"created_on,required" format:"date-time"`
	// Extra Cloudflare-specific information about the record.
	Meta interface{} `json:"meta,required"`
	// When the record was last modified.
	ModifiedOn time.Time `json:"modified_on,required" format:"date-time"`
	// Whether the record can be proxied by Cloudflare or not.
	Proxiable bool `json:"proxiable,required"`
	// When the record comment was last modified. Omitted if there is no comment.
	CommentModifiedOn time.Time `json:"comment_modified_on" format:"date-time"`
	// When the record tags were last modified. Omitted if there are no tags.
	TagsModifiedOn time.Time              `json:"tags_modified_on" format:"date-time"`
	JSON           recordResponseSVCBJSON `json:"-"`
	SVCBRecord
}

func (*RecordResponseSVCB) UnmarshalJSON added in v4.2.0

func (r *RecordResponseSVCB) UnmarshalJSON(data []byte) (err error)

type RecordResponseTLSA added in v4.2.0

type RecordResponseTLSA struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the record was created.
	CreatedOn time.Time `json:"created_on,required" format:"date-time"`
	// Extra Cloudflare-specific information about the record.
	Meta interface{} `json:"meta,required"`
	// When the record was last modified.
	ModifiedOn time.Time `json:"modified_on,required" format:"date-time"`
	// Whether the record can be proxied by Cloudflare or not.
	Proxiable bool `json:"proxiable,required"`
	// When the record comment was last modified. Omitted if there is no comment.
	CommentModifiedOn time.Time `json:"comment_modified_on" format:"date-time"`
	// When the record tags were last modified. Omitted if there are no tags.
	TagsModifiedOn time.Time              `json:"tags_modified_on" format:"date-time"`
	JSON           recordResponseTLSAJSON `json:"-"`
	TLSARecord
}

func (*RecordResponseTLSA) UnmarshalJSON added in v4.2.0

func (r *RecordResponseTLSA) UnmarshalJSON(data []byte) (err error)

type RecordResponseTXT added in v4.2.0

type RecordResponseTXT struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the record was created.
	CreatedOn time.Time `json:"created_on,required" format:"date-time"`
	// Extra Cloudflare-specific information about the record.
	Meta interface{} `json:"meta,required"`
	// When the record was last modified.
	ModifiedOn time.Time `json:"modified_on,required" format:"date-time"`
	// Whether the record can be proxied by Cloudflare or not.
	Proxiable bool `json:"proxiable,required"`
	// When the record comment was last modified. Omitted if there is no comment.
	CommentModifiedOn time.Time `json:"comment_modified_on" format:"date-time"`
	// When the record tags were last modified. Omitted if there are no tags.
	TagsModifiedOn time.Time             `json:"tags_modified_on" format:"date-time"`
	JSON           recordResponseTXTJSON `json:"-"`
	TXTRecord
}

func (*RecordResponseTXT) UnmarshalJSON added in v4.2.0

func (r *RecordResponseTXT) UnmarshalJSON(data []byte) (err error)

type RecordResponseType

type RecordResponseType string

Record type.

const (
	RecordResponseTypeA          RecordResponseType = "A"
	RecordResponseTypeAAAA       RecordResponseType = "AAAA"
	RecordResponseTypeCAA        RecordResponseType = "CAA"
	RecordResponseTypeCERT       RecordResponseType = "CERT"
	RecordResponseTypeCNAME      RecordResponseType = "CNAME"
	RecordResponseTypeDNSKEY     RecordResponseType = "DNSKEY"
	RecordResponseTypeDS         RecordResponseType = "DS"
	RecordResponseTypeHTTPS      RecordResponseType = "HTTPS"
	RecordResponseTypeLOC        RecordResponseType = "LOC"
	RecordResponseTypeMX         RecordResponseType = "MX"
	RecordResponseTypeNAPTR      RecordResponseType = "NAPTR"
	RecordResponseTypeNS         RecordResponseType = "NS"
	RecordResponseTypeOpenpgpkey RecordResponseType = "OPENPGPKEY"
	RecordResponseTypePTR        RecordResponseType = "PTR"
	RecordResponseTypeSMIMEA     RecordResponseType = "SMIMEA"
	RecordResponseTypeSRV        RecordResponseType = "SRV"
	RecordResponseTypeSSHFP      RecordResponseType = "SSHFP"
	RecordResponseTypeSVCB       RecordResponseType = "SVCB"
	RecordResponseTypeTLSA       RecordResponseType = "TLSA"
	RecordResponseTypeTXT        RecordResponseType = "TXT"
	RecordResponseTypeURI        RecordResponseType = "URI"
)

func (RecordResponseType) IsKnown

func (r RecordResponseType) IsKnown() bool

type RecordResponseURI added in v4.2.0

type RecordResponseURI struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the record was created.
	CreatedOn time.Time `json:"created_on,required" format:"date-time"`
	// Extra Cloudflare-specific information about the record.
	Meta interface{} `json:"meta,required"`
	// When the record was last modified.
	ModifiedOn time.Time `json:"modified_on,required" format:"date-time"`
	// Whether the record can be proxied by Cloudflare or not.
	Proxiable bool `json:"proxiable,required"`
	// When the record comment was last modified. Omitted if there is no comment.
	CommentModifiedOn time.Time `json:"comment_modified_on" format:"date-time"`
	// When the record tags were last modified. Omitted if there are no tags.
	TagsModifiedOn time.Time             `json:"tags_modified_on" format:"date-time"`
	JSON           recordResponseURIJSON `json:"-"`
	URIRecord
}

func (*RecordResponseURI) UnmarshalJSON added in v4.2.0

func (r *RecordResponseURI) UnmarshalJSON(data []byte) (err error)

type RecordScanParams

type RecordScanParams struct {
	// Identifier.
	ZoneID param.Field[string] `path:"zone_id,required"`
	Body   interface{}         `json:"body,required"`
}

func (RecordScanParams) MarshalJSON

func (r RecordScanParams) MarshalJSON() (data []byte, err error)

type RecordScanResponse

type RecordScanResponse struct {
	// Number of DNS records added.
	RecsAdded float64 `json:"recs_added"`
	// Total number of DNS records parsed.
	TotalRecordsParsed float64                `json:"total_records_parsed"`
	JSON               recordScanResponseJSON `json:"-"`
}

func (*RecordScanResponse) UnmarshalJSON

func (r *RecordScanResponse) UnmarshalJSON(data []byte) (err error)

type RecordScanResponseEnvelope

type RecordScanResponseEnvelope struct {
	Errors   []RecordScanResponseEnvelopeErrors   `json:"errors,required"`
	Messages []RecordScanResponseEnvelopeMessages `json:"messages,required"`
	// Whether the API call was successful.
	Success RecordScanResponseEnvelopeSuccess `json:"success,required"`
	Result  RecordScanResponse                `json:"result"`
	JSON    recordScanResponseEnvelopeJSON    `json:"-"`
}

func (*RecordScanResponseEnvelope) UnmarshalJSON

func (r *RecordScanResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type RecordScanResponseEnvelopeErrors added in v4.3.0

type RecordScanResponseEnvelopeErrors struct {
	Code             int64                                  `json:"code,required"`
	Message          string                                 `json:"message,required"`
	DocumentationURL string                                 `json:"documentation_url"`
	Source           RecordScanResponseEnvelopeErrorsSource `json:"source"`
	JSON             recordScanResponseEnvelopeErrorsJSON   `json:"-"`
}

func (*RecordScanResponseEnvelopeErrors) UnmarshalJSON added in v4.3.0

func (r *RecordScanResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type RecordScanResponseEnvelopeErrorsSource added in v4.3.0

type RecordScanResponseEnvelopeErrorsSource struct {
	Pointer string                                     `json:"pointer"`
	JSON    recordScanResponseEnvelopeErrorsSourceJSON `json:"-"`
}

func (*RecordScanResponseEnvelopeErrorsSource) UnmarshalJSON added in v4.3.0

func (r *RecordScanResponseEnvelopeErrorsSource) UnmarshalJSON(data []byte) (err error)

type RecordScanResponseEnvelopeMessages added in v4.3.0

type RecordScanResponseEnvelopeMessages struct {
	Code             int64                                    `json:"code,required"`
	Message          string                                   `json:"message,required"`
	DocumentationURL string                                   `json:"documentation_url"`
	Source           RecordScanResponseEnvelopeMessagesSource `json:"source"`
	JSON             recordScanResponseEnvelopeMessagesJSON   `json:"-"`
}

func (*RecordScanResponseEnvelopeMessages) UnmarshalJSON added in v4.3.0

func (r *RecordScanResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type RecordScanResponseEnvelopeMessagesSource added in v4.3.0

type RecordScanResponseEnvelopeMessagesSource struct {
	Pointer string                                       `json:"pointer"`
	JSON    recordScanResponseEnvelopeMessagesSourceJSON `json:"-"`
}

func (*RecordScanResponseEnvelopeMessagesSource) UnmarshalJSON added in v4.3.0

func (r *RecordScanResponseEnvelopeMessagesSource) UnmarshalJSON(data []byte) (err error)

type RecordScanResponseEnvelopeSuccess

type RecordScanResponseEnvelopeSuccess bool

Whether the API call was successful.

const (
	RecordScanResponseEnvelopeSuccessTrue RecordScanResponseEnvelopeSuccess = true
)

func (RecordScanResponseEnvelopeSuccess) IsKnown

type RecordService

type RecordService struct {
	Options []option.RequestOption
}

RecordService contains methods and other services that help with interacting with the cloudflare API.

Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewRecordService method instead.

func NewRecordService

func NewRecordService(opts ...option.RequestOption) (r *RecordService)

NewRecordService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*RecordService) Batch

func (r *RecordService) Batch(ctx context.Context, params RecordBatchParams, opts ...option.RequestOption) (res *RecordBatchResponse, err error)

Send a Batch of DNS Record API calls to be executed together.

Notes:

  • Although Cloudflare will execute the batched operations in a single database transaction, Cloudflare's distributed KV store must treat each record change as a single key-value pair. This means that the propagation of changes is not atomic. See [the documentation](https://developers.cloudflare.com/dns/manage-dns-records/how-to/batch-record-changes/ "Batch DNS records") for more information.

  • The operations you specify within the /batch request body are always executed in the following order:

  • Deletes

  • Patches

  • Puts

  • Posts

func (*RecordService) Delete

func (r *RecordService) Delete(ctx context.Context, dnsRecordID string, body RecordDeleteParams, opts ...option.RequestOption) (res *RecordDeleteResponse, err error)

Delete DNS Record

func (*RecordService) Edit

func (r *RecordService) Edit(ctx context.Context, dnsRecordID string, params RecordEditParams, opts ...option.RequestOption) (res *RecordResponse, err error)

Update an existing DNS record.

Notes:

  • A/AAAA records cannot exist on the same name as CNAME records.
  • NS records cannot exist on the same name as any other record type.
  • Domain names are always represented in Punycode, even if Unicode characters were used when creating the record.

func (*RecordService) Export

func (r *RecordService) Export(ctx context.Context, query RecordExportParams, opts ...option.RequestOption) (res *string, err error)

You can export your [BIND config](https://en.wikipedia.org/wiki/Zone_file "Zone file") through this endpoint.

See [the documentation](https://developers.cloudflare.com/dns/manage-dns-records/how-to/import-and-export/ "Import and export records") for more information.

func (*RecordService) Get

func (r *RecordService) Get(ctx context.Context, dnsRecordID string, query RecordGetParams, opts ...option.RequestOption) (res *RecordResponse, err error)

DNS Record Details

func (*RecordService) Import

func (r *RecordService) Import(ctx context.Context, params RecordImportParams, opts ...option.RequestOption) (res *RecordImportResponse, err error)

You can upload your [BIND config](https://en.wikipedia.org/wiki/Zone_file "Zone file") through this endpoint. It assumes that cURL is called from a location with bind_config.txt (valid BIND config) present.

See [the documentation](https://developers.cloudflare.com/dns/manage-dns-records/how-to/import-and-export/ "Import and export records") for more information.

func (*RecordService) List

List, search, sort, and filter a zones' DNS records.

func (*RecordService) ListAutoPaging

List, search, sort, and filter a zones' DNS records.

func (*RecordService) New

func (r *RecordService) New(ctx context.Context, params RecordNewParams, opts ...option.RequestOption) (res *RecordResponse, err error)

Create a new DNS record for a zone.

Notes:

  • A/AAAA records cannot exist on the same name as CNAME records.
  • NS records cannot exist on the same name as any other record type.
  • Domain names are always represented in Punycode, even if Unicode characters were used when creating the record.

func (*RecordService) Scan

func (r *RecordService) Scan(ctx context.Context, params RecordScanParams, opts ...option.RequestOption) (res *RecordScanResponse, err error)

Scan for common DNS records on your domain and automatically add them to your zone. Useful if you haven't updated your nameservers yet.

func (*RecordService) Update

func (r *RecordService) Update(ctx context.Context, dnsRecordID string, params RecordUpdateParams, opts ...option.RequestOption) (res *RecordResponse, err error)

Overwrite an existing DNS record.

Notes:

  • A/AAAA records cannot exist on the same name as CNAME records.
  • NS records cannot exist on the same name as any other record type.
  • Domain names are always represented in Punycode, even if Unicode characters were used when creating the record.

type RecordTags

type RecordTags = string

type RecordTagsParam

type RecordTagsParam = string

type RecordType

type RecordType string

Record type.

const (
	RecordTypeA          RecordType = "A"
	RecordTypeAAAA       RecordType = "AAAA"
	RecordTypeCAA        RecordType = "CAA"
	RecordTypeCERT       RecordType = "CERT"
	RecordTypeCNAME      RecordType = "CNAME"
	RecordTypeDNSKEY     RecordType = "DNSKEY"
	RecordTypeDS         RecordType = "DS"
	RecordTypeHTTPS      RecordType = "HTTPS"
	RecordTypeLOC        RecordType = "LOC"
	RecordTypeMX         RecordType = "MX"
	RecordTypeNAPTR      RecordType = "NAPTR"
	RecordTypeNS         RecordType = "NS"
	RecordTypeOpenpgpkey RecordType = "OPENPGPKEY"
	RecordTypePTR        RecordType = "PTR"
	RecordTypeSMIMEA     RecordType = "SMIMEA"
	RecordTypeSRV        RecordType = "SRV"
	RecordTypeSSHFP      RecordType = "SSHFP"
	RecordTypeSVCB       RecordType = "SVCB"
	RecordTypeTLSA       RecordType = "TLSA"
	RecordTypeTXT        RecordType = "TXT"
	RecordTypeURI        RecordType = "URI"
)

func (RecordType) IsKnown

func (r RecordType) IsKnown() bool

type RecordUpdateParams

type RecordUpdateParams struct {
	// Identifier.
	ZoneID param.Field[string] `path:"zone_id,required"`
	Record RecordUnionParam    `json:"record,required"`
}

func (RecordUpdateParams) MarshalJSON

func (r RecordUpdateParams) MarshalJSON() (data []byte, err error)

type RecordUpdateResponseEnvelope

type RecordUpdateResponseEnvelope struct {
	Errors   []RecordUpdateResponseEnvelopeErrors   `json:"errors,required"`
	Messages []RecordUpdateResponseEnvelopeMessages `json:"messages,required"`
	// Whether the API call was successful.
	Success RecordUpdateResponseEnvelopeSuccess `json:"success,required"`
	Result  RecordResponse                      `json:"result"`
	JSON    recordUpdateResponseEnvelopeJSON    `json:"-"`
}

func (*RecordUpdateResponseEnvelope) UnmarshalJSON

func (r *RecordUpdateResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type RecordUpdateResponseEnvelopeErrors added in v4.3.0

type RecordUpdateResponseEnvelopeErrors struct {
	Code             int64                                    `json:"code,required"`
	Message          string                                   `json:"message,required"`
	DocumentationURL string                                   `json:"documentation_url"`
	Source           RecordUpdateResponseEnvelopeErrorsSource `json:"source"`
	JSON             recordUpdateResponseEnvelopeErrorsJSON   `json:"-"`
}

func (*RecordUpdateResponseEnvelopeErrors) UnmarshalJSON added in v4.3.0

func (r *RecordUpdateResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type RecordUpdateResponseEnvelopeErrorsSource added in v4.3.0

type RecordUpdateResponseEnvelopeErrorsSource struct {
	Pointer string                                       `json:"pointer"`
	JSON    recordUpdateResponseEnvelopeErrorsSourceJSON `json:"-"`
}

func (*RecordUpdateResponseEnvelopeErrorsSource) UnmarshalJSON added in v4.3.0

func (r *RecordUpdateResponseEnvelopeErrorsSource) UnmarshalJSON(data []byte) (err error)

type RecordUpdateResponseEnvelopeMessages added in v4.3.0

type RecordUpdateResponseEnvelopeMessages struct {
	Code             int64                                      `json:"code,required"`
	Message          string                                     `json:"message,required"`
	DocumentationURL string                                     `json:"documentation_url"`
	Source           RecordUpdateResponseEnvelopeMessagesSource `json:"source"`
	JSON             recordUpdateResponseEnvelopeMessagesJSON   `json:"-"`
}

func (*RecordUpdateResponseEnvelopeMessages) UnmarshalJSON added in v4.3.0

func (r *RecordUpdateResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type RecordUpdateResponseEnvelopeMessagesSource added in v4.3.0

type RecordUpdateResponseEnvelopeMessagesSource struct {
	Pointer string                                         `json:"pointer"`
	JSON    recordUpdateResponseEnvelopeMessagesSourceJSON `json:"-"`
}

func (*RecordUpdateResponseEnvelopeMessagesSource) UnmarshalJSON added in v4.3.0

func (r *RecordUpdateResponseEnvelopeMessagesSource) UnmarshalJSON(data []byte) (err error)

type RecordUpdateResponseEnvelopeSuccess

type RecordUpdateResponseEnvelopeSuccess bool

Whether the API call was successful.

const (
	RecordUpdateResponseEnvelopeSuccessTrue RecordUpdateResponseEnvelopeSuccess = true
)

func (RecordUpdateResponseEnvelopeSuccess) IsKnown

type Report

type Report struct {
	// Array with one row per combination of dimension values.
	Data []ReportData `json:"data,required"`
	// Number of seconds between current time and last processed event, in another
	// words how many seconds of data could be missing.
	DataLag float64 `json:"data_lag,required"`
	// Maximum results for each metric (object mapping metric names to values).
	// Currently always an empty object.
	Max interface{} `json:"max,required"`
	// Minimum results for each metric (object mapping metric names to values).
	// Currently always an empty object.
	Min   interface{} `json:"min,required"`
	Query ReportQuery `json:"query,required"`
	// Total number of rows in the result.
	Rows float64 `json:"rows,required"`
	// Total results for metrics across all data (object mapping metric names to
	// values).
	Totals interface{} `json:"totals,required"`
	JSON   reportJSON  `json:"-"`
}

func (*Report) UnmarshalJSON

func (r *Report) UnmarshalJSON(data []byte) (err error)

type ReportData

type ReportData struct {
	// Array of dimension values, representing the combination of dimension values
	// corresponding to this row.
	Dimensions []string `json:"dimensions,required"`
	// Array with one item per requested metric. Each item is a single value.
	Metrics []float64      `json:"metrics,required"`
	JSON    reportDataJSON `json:"-"`
}

func (*ReportData) UnmarshalJSON

func (r *ReportData) UnmarshalJSON(data []byte) (err error)

type ReportQuery

type ReportQuery struct {
	// Array of dimension names.
	Dimensions []string `json:"dimensions,required"`
	// Limit number of returned metrics.
	Limit int64 `json:"limit,required"`
	// Array of metric names.
	Metrics []string `json:"metrics,required"`
	// Start date and time of requesting data period in ISO 8601 format.
	Since time.Time `json:"since,required" format:"date-time"`
	// End date and time of requesting data period in ISO 8601 format.
	Until time.Time `json:"until,required" format:"date-time"`
	// Segmentation filter in 'attribute operator value' format.
	Filters string `json:"filters"`
	// Array of dimensions to sort by, where each dimension may be prefixed by -
	// (descending) or + (ascending).
	Sort []string        `json:"sort"`
	JSON reportQueryJSON `json:"-"`
}

func (*ReportQuery) UnmarshalJSON

func (r *ReportQuery) UnmarshalJSON(data []byte) (err error)

type ResponseInfo

type ResponseInfo = shared.ResponseInfo

This is an alias to an internal type.

type ResponseInfoSource added in v4.3.0

type ResponseInfoSource = shared.ResponseInfoSource

This is an alias to an internal type.

type Role

type Role = shared.Role

This is an alias to an internal type.

type RoleParam

type RoleParam = shared.RoleParam

This is an alias to an internal type.

type RolePermissions

type RolePermissions = shared.RolePermissions

This is an alias to an internal type.

type RolePermissionsParam

type RolePermissionsParam = shared.RolePermissionsParam

This is an alias to an internal type.

type SMIMEARecord

type SMIMEARecord struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment string `json:"comment"`
	// Formatted SMIMEA content. See 'data' to set SMIMEA properties.
	Content string `json:"content"`
	// Components of a SMIMEA record.
	Data SMIMEARecordData `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name string `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied bool `json:"proxied"`
	// Settings for the DNS record.
	Settings SMIMEARecordSettings `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags []RecordTags `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL TTL `json:"ttl"`
	// Record type.
	Type SMIMEARecordType `json:"type"`
	JSON smimeaRecordJSON `json:"-"`
}

func (*SMIMEARecord) UnmarshalJSON

func (r *SMIMEARecord) UnmarshalJSON(data []byte) (err error)

type SMIMEARecordData

type SMIMEARecordData struct {
	// Certificate.
	Certificate string `json:"certificate"`
	// Matching Type.
	MatchingType float64 `json:"matching_type"`
	// Selector.
	Selector float64 `json:"selector"`
	// Usage.
	Usage float64              `json:"usage"`
	JSON  smimeaRecordDataJSON `json:"-"`
}

Components of a SMIMEA record.

func (*SMIMEARecordData) UnmarshalJSON

func (r *SMIMEARecordData) UnmarshalJSON(data []byte) (err error)

type SMIMEARecordDataParam

type SMIMEARecordDataParam struct {
	// Certificate.
	Certificate param.Field[string] `json:"certificate"`
	// Matching Type.
	MatchingType param.Field[float64] `json:"matching_type"`
	// Selector.
	Selector param.Field[float64] `json:"selector"`
	// Usage.
	Usage param.Field[float64] `json:"usage"`
}

Components of a SMIMEA record.

func (SMIMEARecordDataParam) MarshalJSON

func (r SMIMEARecordDataParam) MarshalJSON() (data []byte, err error)

type SMIMEARecordParam

type SMIMEARecordParam struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// Components of a SMIMEA record.
	Data param.Field[SMIMEARecordDataParam] `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `json:"proxied"`
	// Settings for the DNS record.
	Settings param.Field[SMIMEARecordSettingsParam] `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags param.Field[[]RecordTagsParam] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
	// Record type.
	Type param.Field[SMIMEARecordType] `json:"type"`
}

func (SMIMEARecordParam) MarshalJSON

func (r SMIMEARecordParam) MarshalJSON() (data []byte, err error)

type SMIMEARecordSettings

type SMIMEARecordSettings struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only bool `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only bool                     `json:"ipv6_only"`
	JSON     smimeaRecordSettingsJSON `json:"-"`
}

Settings for the DNS record.

func (*SMIMEARecordSettings) UnmarshalJSON

func (r *SMIMEARecordSettings) UnmarshalJSON(data []byte) (err error)

type SMIMEARecordSettingsParam

type SMIMEARecordSettingsParam struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only param.Field[bool] `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only param.Field[bool] `json:"ipv6_only"`
}

Settings for the DNS record.

func (SMIMEARecordSettingsParam) MarshalJSON

func (r SMIMEARecordSettingsParam) MarshalJSON() (data []byte, err error)

type SMIMEARecordType

type SMIMEARecordType string

Record type.

const (
	SMIMEARecordTypeSMIMEA SMIMEARecordType = "SMIMEA"
)

func (SMIMEARecordType) IsKnown

func (r SMIMEARecordType) IsKnown() bool

type SRVRecord

type SRVRecord struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment string `json:"comment"`
	// Priority, weight, port, and SRV target. See 'data' for setting the individual
	// component values.
	Content string `json:"content"`
	// Components of a SRV record.
	Data SRVRecordData `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name string `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied bool `json:"proxied"`
	// Settings for the DNS record.
	Settings SRVRecordSettings `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags []RecordTags `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL TTL `json:"ttl"`
	// Record type.
	Type SRVRecordType `json:"type"`
	JSON srvRecordJSON `json:"-"`
}

func (*SRVRecord) UnmarshalJSON

func (r *SRVRecord) UnmarshalJSON(data []byte) (err error)

type SRVRecordData

type SRVRecordData struct {
	// The port of the service.
	Port float64 `json:"port"`
	// Required for MX, SRV and URI records; unused by other record types. Records with
	// lower priorities are preferred.
	Priority float64 `json:"priority"`
	// A valid hostname.
	Target string `json:"target" format:"hostname"`
	// The record weight.
	Weight float64           `json:"weight"`
	JSON   srvRecordDataJSON `json:"-"`
}

Components of a SRV record.

func (*SRVRecordData) UnmarshalJSON

func (r *SRVRecordData) UnmarshalJSON(data []byte) (err error)

type SRVRecordDataParam

type SRVRecordDataParam struct {
	// The port of the service.
	Port param.Field[float64] `json:"port"`
	// Required for MX, SRV and URI records; unused by other record types. Records with
	// lower priorities are preferred.
	Priority param.Field[float64] `json:"priority"`
	// A valid hostname.
	Target param.Field[string] `json:"target" format:"hostname"`
	// The record weight.
	Weight param.Field[float64] `json:"weight"`
}

Components of a SRV record.

func (SRVRecordDataParam) MarshalJSON

func (r SRVRecordDataParam) MarshalJSON() (data []byte, err error)

type SRVRecordParam

type SRVRecordParam struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// Components of a SRV record.
	Data param.Field[SRVRecordDataParam] `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `json:"proxied"`
	// Settings for the DNS record.
	Settings param.Field[SRVRecordSettingsParam] `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags param.Field[[]RecordTagsParam] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
	// Record type.
	Type param.Field[SRVRecordType] `json:"type"`
}

func (SRVRecordParam) MarshalJSON

func (r SRVRecordParam) MarshalJSON() (data []byte, err error)

type SRVRecordSettings

type SRVRecordSettings struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only bool `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only bool                  `json:"ipv6_only"`
	JSON     srvRecordSettingsJSON `json:"-"`
}

Settings for the DNS record.

func (*SRVRecordSettings) UnmarshalJSON

func (r *SRVRecordSettings) UnmarshalJSON(data []byte) (err error)

type SRVRecordSettingsParam

type SRVRecordSettingsParam struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only param.Field[bool] `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only param.Field[bool] `json:"ipv6_only"`
}

Settings for the DNS record.

func (SRVRecordSettingsParam) MarshalJSON

func (r SRVRecordSettingsParam) MarshalJSON() (data []byte, err error)

type SRVRecordType

type SRVRecordType string

Record type.

const (
	SRVRecordTypeSRV SRVRecordType = "SRV"
)

func (SRVRecordType) IsKnown

func (r SRVRecordType) IsKnown() bool

type SSHFPRecord

type SSHFPRecord struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment string `json:"comment"`
	// Formatted SSHFP content. See 'data' to set SSHFP properties.
	Content string `json:"content"`
	// Components of a SSHFP record.
	Data SSHFPRecordData `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name string `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied bool `json:"proxied"`
	// Settings for the DNS record.
	Settings SSHFPRecordSettings `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags []RecordTags `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL TTL `json:"ttl"`
	// Record type.
	Type SSHFPRecordType `json:"type"`
	JSON sshfpRecordJSON `json:"-"`
}

func (*SSHFPRecord) UnmarshalJSON

func (r *SSHFPRecord) UnmarshalJSON(data []byte) (err error)

type SSHFPRecordData

type SSHFPRecordData struct {
	// algorithm.
	Algorithm float64 `json:"algorithm"`
	// fingerprint.
	Fingerprint string `json:"fingerprint"`
	// type.
	Type float64             `json:"type"`
	JSON sshfpRecordDataJSON `json:"-"`
}

Components of a SSHFP record.

func (*SSHFPRecordData) UnmarshalJSON

func (r *SSHFPRecordData) UnmarshalJSON(data []byte) (err error)

type SSHFPRecordDataParam

type SSHFPRecordDataParam struct {
	// algorithm.
	Algorithm param.Field[float64] `json:"algorithm"`
	// fingerprint.
	Fingerprint param.Field[string] `json:"fingerprint"`
	// type.
	Type param.Field[float64] `json:"type"`
}

Components of a SSHFP record.

func (SSHFPRecordDataParam) MarshalJSON

func (r SSHFPRecordDataParam) MarshalJSON() (data []byte, err error)

type SSHFPRecordParam

type SSHFPRecordParam struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// Components of a SSHFP record.
	Data param.Field[SSHFPRecordDataParam] `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `json:"proxied"`
	// Settings for the DNS record.
	Settings param.Field[SSHFPRecordSettingsParam] `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags param.Field[[]RecordTagsParam] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
	// Record type.
	Type param.Field[SSHFPRecordType] `json:"type"`
}

func (SSHFPRecordParam) MarshalJSON

func (r SSHFPRecordParam) MarshalJSON() (data []byte, err error)

type SSHFPRecordSettings

type SSHFPRecordSettings struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only bool `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only bool                    `json:"ipv6_only"`
	JSON     sshfpRecordSettingsJSON `json:"-"`
}

Settings for the DNS record.

func (*SSHFPRecordSettings) UnmarshalJSON

func (r *SSHFPRecordSettings) UnmarshalJSON(data []byte) (err error)

type SSHFPRecordSettingsParam

type SSHFPRecordSettingsParam struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only param.Field[bool] `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only param.Field[bool] `json:"ipv6_only"`
}

Settings for the DNS record.

func (SSHFPRecordSettingsParam) MarshalJSON

func (r SSHFPRecordSettingsParam) MarshalJSON() (data []byte, err error)

type SSHFPRecordType

type SSHFPRecordType string

Record type.

const (
	SSHFPRecordTypeSSHFP SSHFPRecordType = "SSHFP"
)

func (SSHFPRecordType) IsKnown

func (r SSHFPRecordType) IsKnown() bool

type SVCBRecord

type SVCBRecord struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment string `json:"comment"`
	// Formatted SVCB content. See 'data' to set SVCB properties.
	Content string `json:"content"`
	// Components of a SVCB record.
	Data SVCBRecordData `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name string `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied bool `json:"proxied"`
	// Settings for the DNS record.
	Settings SVCBRecordSettings `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags []RecordTags `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL TTL `json:"ttl"`
	// Record type.
	Type SVCBRecordType `json:"type"`
	JSON svcbRecordJSON `json:"-"`
}

func (*SVCBRecord) UnmarshalJSON

func (r *SVCBRecord) UnmarshalJSON(data []byte) (err error)

type SVCBRecordData

type SVCBRecordData struct {
	// priority.
	Priority float64 `json:"priority"`
	// target.
	Target string `json:"target"`
	// value.
	Value string             `json:"value"`
	JSON  svcbRecordDataJSON `json:"-"`
}

Components of a SVCB record.

func (*SVCBRecordData) UnmarshalJSON

func (r *SVCBRecordData) UnmarshalJSON(data []byte) (err error)

type SVCBRecordDataParam

type SVCBRecordDataParam struct {
	// priority.
	Priority param.Field[float64] `json:"priority"`
	// target.
	Target param.Field[string] `json:"target"`
	// value.
	Value param.Field[string] `json:"value"`
}

Components of a SVCB record.

func (SVCBRecordDataParam) MarshalJSON

func (r SVCBRecordDataParam) MarshalJSON() (data []byte, err error)

type SVCBRecordParam

type SVCBRecordParam struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// Components of a SVCB record.
	Data param.Field[SVCBRecordDataParam] `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `json:"proxied"`
	// Settings for the DNS record.
	Settings param.Field[SVCBRecordSettingsParam] `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags param.Field[[]RecordTagsParam] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
	// Record type.
	Type param.Field[SVCBRecordType] `json:"type"`
}

func (SVCBRecordParam) MarshalJSON

func (r SVCBRecordParam) MarshalJSON() (data []byte, err error)

type SVCBRecordSettings

type SVCBRecordSettings struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only bool `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only bool                   `json:"ipv6_only"`
	JSON     svcbRecordSettingsJSON `json:"-"`
}

Settings for the DNS record.

func (*SVCBRecordSettings) UnmarshalJSON

func (r *SVCBRecordSettings) UnmarshalJSON(data []byte) (err error)

type SVCBRecordSettingsParam

type SVCBRecordSettingsParam struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only param.Field[bool] `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only param.Field[bool] `json:"ipv6_only"`
}

Settings for the DNS record.

func (SVCBRecordSettingsParam) MarshalJSON

func (r SVCBRecordSettingsParam) MarshalJSON() (data []byte, err error)

type SVCBRecordType

type SVCBRecordType string

Record type.

const (
	SVCBRecordTypeSVCB SVCBRecordType = "SVCB"
)

func (SVCBRecordType) IsKnown

func (r SVCBRecordType) IsKnown() bool

type SettingAccountEditParams added in v4.2.0

type SettingAccountEditParams struct {
	// Identifier.
	AccountID    param.Field[string]                               `path:"account_id,required"`
	ZoneDefaults param.Field[SettingAccountEditParamsZoneDefaults] `json:"zone_defaults"`
}

func (SettingAccountEditParams) MarshalJSON added in v4.2.0

func (r SettingAccountEditParams) MarshalJSON() (data []byte, err error)

type SettingAccountEditParamsZoneDefaults added in v4.2.0

type SettingAccountEditParamsZoneDefaults struct {
	// Whether to flatten all CNAME records in the zone. Note that, due to DNS
	// limitations, a CNAME record at the zone apex will always be flattened.
	FlattenAllCNAMEs param.Field[bool] `json:"flatten_all_cnames"`
	// Whether to enable Foundation DNS Advanced Nameservers on the zone.
	FoundationDNS param.Field[bool] `json:"foundation_dns"`
	// Settings for this internal zone.
	InternalDNS param.Field[SettingAccountEditParamsZoneDefaultsInternalDNS] `json:"internal_dns"`
	// Whether to enable multi-provider DNS, which causes Cloudflare to activate the
	// zone even when non-Cloudflare NS records exist, and to respect NS records at the
	// zone apex during outbound zone transfers.
	MultiProvider param.Field[bool] `json:"multi_provider"`
	// Settings determining the nameservers through which the zone should be available.
	Nameservers param.Field[SettingAccountEditParamsZoneDefaultsNameservers] `json:"nameservers"`
	// The time to live (TTL) of the zone's nameserver (NS) records.
	NSTTL param.Field[float64] `json:"ns_ttl"`
	// Allows a Secondary DNS zone to use (proxied) override records and CNAME
	// flattening at the zone apex.
	SecondaryOverrides param.Field[bool] `json:"secondary_overrides"`
	// Components of the zone's SOA record.
	SOA param.Field[SettingAccountEditParamsZoneDefaultsSOA] `json:"soa"`
	// Whether the zone mode is a regular or CDN/DNS only zone.
	ZoneMode param.Field[SettingAccountEditParamsZoneDefaultsZoneMode] `json:"zone_mode"`
}

func (SettingAccountEditParamsZoneDefaults) MarshalJSON added in v4.2.0

func (r SettingAccountEditParamsZoneDefaults) MarshalJSON() (data []byte, err error)

type SettingAccountEditParamsZoneDefaultsInternalDNS added in v4.2.0

type SettingAccountEditParamsZoneDefaultsInternalDNS struct {
	// The ID of the zone to fallback to.
	ReferenceZoneID param.Field[string] `json:"reference_zone_id"`
}

Settings for this internal zone.

func (SettingAccountEditParamsZoneDefaultsInternalDNS) MarshalJSON added in v4.2.0

func (r SettingAccountEditParamsZoneDefaultsInternalDNS) MarshalJSON() (data []byte, err error)

type SettingAccountEditParamsZoneDefaultsNameservers added in v4.2.0

type SettingAccountEditParamsZoneDefaultsNameservers struct {
	// Nameserver type
	Type param.Field[SettingAccountEditParamsZoneDefaultsNameserversType] `json:"type,required"`
}

Settings determining the nameservers through which the zone should be available.

func (SettingAccountEditParamsZoneDefaultsNameservers) MarshalJSON added in v4.2.0

func (r SettingAccountEditParamsZoneDefaultsNameservers) MarshalJSON() (data []byte, err error)

type SettingAccountEditParamsZoneDefaultsNameserversType added in v4.2.0

type SettingAccountEditParamsZoneDefaultsNameserversType string

Nameserver type

const (
	SettingAccountEditParamsZoneDefaultsNameserversTypeCloudflareStandard       SettingAccountEditParamsZoneDefaultsNameserversType = "cloudflare.standard"
	SettingAccountEditParamsZoneDefaultsNameserversTypeCloudflareStandardRandom SettingAccountEditParamsZoneDefaultsNameserversType = "cloudflare.standard.random"
	SettingAccountEditParamsZoneDefaultsNameserversTypeCustomAccount            SettingAccountEditParamsZoneDefaultsNameserversType = "custom.account"
	SettingAccountEditParamsZoneDefaultsNameserversTypeCustomTenant             SettingAccountEditParamsZoneDefaultsNameserversType = "custom.tenant"
)

func (SettingAccountEditParamsZoneDefaultsNameserversType) IsKnown added in v4.2.0

type SettingAccountEditParamsZoneDefaultsSOA added in v4.2.0

type SettingAccountEditParamsZoneDefaultsSOA struct {
	// Time in seconds of being unable to query the primary server after which
	// secondary servers should stop serving the zone.
	Expire param.Field[float64] `json:"expire,required"`
	// The time to live (TTL) for negative caching of records within the zone.
	MinTTL param.Field[float64] `json:"min_ttl,required"`
	// The primary nameserver, which may be used for outbound zone transfers.
	MNAME param.Field[string] `json:"mname,required"`
	// Time in seconds after which secondary servers should re-check the SOA record to
	// see if the zone has been updated.
	Refresh param.Field[float64] `json:"refresh,required"`
	// Time in seconds after which secondary servers should retry queries after the
	// primary server was unresponsive.
	Retry param.Field[float64] `json:"retry,required"`
	// The email address of the zone administrator, with the first label representing
	// the local part of the email address.
	RNAME param.Field[string] `json:"rname,required"`
	// The time to live (TTL) of the SOA record itself.
	TTL param.Field[float64] `json:"ttl,required"`
}

Components of the zone's SOA record.

func (SettingAccountEditParamsZoneDefaultsSOA) MarshalJSON added in v4.2.0

func (r SettingAccountEditParamsZoneDefaultsSOA) MarshalJSON() (data []byte, err error)

type SettingAccountEditParamsZoneDefaultsZoneMode added in v4.2.0

type SettingAccountEditParamsZoneDefaultsZoneMode string

Whether the zone mode is a regular or CDN/DNS only zone.

const (
	SettingAccountEditParamsZoneDefaultsZoneModeStandard SettingAccountEditParamsZoneDefaultsZoneMode = "standard"
	SettingAccountEditParamsZoneDefaultsZoneModeCDNOnly  SettingAccountEditParamsZoneDefaultsZoneMode = "cdn_only"
	SettingAccountEditParamsZoneDefaultsZoneModeDNSOnly  SettingAccountEditParamsZoneDefaultsZoneMode = "dns_only"
)

func (SettingAccountEditParamsZoneDefaultsZoneMode) IsKnown added in v4.2.0

type SettingAccountEditResponse added in v4.2.0

type SettingAccountEditResponse struct {
	ZoneDefaults SettingAccountEditResponseZoneDefaults `json:"zone_defaults"`
	JSON         settingAccountEditResponseJSON         `json:"-"`
}

func (*SettingAccountEditResponse) UnmarshalJSON added in v4.2.0

func (r *SettingAccountEditResponse) UnmarshalJSON(data []byte) (err error)

type SettingAccountEditResponseEnvelope added in v4.2.0

type SettingAccountEditResponseEnvelope struct {
	Errors   []SettingAccountEditResponseEnvelopeErrors   `json:"errors,required"`
	Messages []SettingAccountEditResponseEnvelopeMessages `json:"messages,required"`
	// Whether the API call was successful.
	Success SettingAccountEditResponseEnvelopeSuccess `json:"success,required"`
	Result  SettingAccountEditResponse                `json:"result"`
	JSON    settingAccountEditResponseEnvelopeJSON    `json:"-"`
}

func (*SettingAccountEditResponseEnvelope) UnmarshalJSON added in v4.2.0

func (r *SettingAccountEditResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type SettingAccountEditResponseEnvelopeErrors added in v4.3.0

type SettingAccountEditResponseEnvelopeErrors struct {
	Code             int64                                          `json:"code,required"`
	Message          string                                         `json:"message,required"`
	DocumentationURL string                                         `json:"documentation_url"`
	Source           SettingAccountEditResponseEnvelopeErrorsSource `json:"source"`
	JSON             settingAccountEditResponseEnvelopeErrorsJSON   `json:"-"`
}

func (*SettingAccountEditResponseEnvelopeErrors) UnmarshalJSON added in v4.3.0

func (r *SettingAccountEditResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type SettingAccountEditResponseEnvelopeErrorsSource added in v4.3.0

type SettingAccountEditResponseEnvelopeErrorsSource struct {
	Pointer string                                             `json:"pointer"`
	JSON    settingAccountEditResponseEnvelopeErrorsSourceJSON `json:"-"`
}

func (*SettingAccountEditResponseEnvelopeErrorsSource) UnmarshalJSON added in v4.3.0

func (r *SettingAccountEditResponseEnvelopeErrorsSource) UnmarshalJSON(data []byte) (err error)

type SettingAccountEditResponseEnvelopeMessages added in v4.3.0

type SettingAccountEditResponseEnvelopeMessages struct {
	Code             int64                                            `json:"code,required"`
	Message          string                                           `json:"message,required"`
	DocumentationURL string                                           `json:"documentation_url"`
	Source           SettingAccountEditResponseEnvelopeMessagesSource `json:"source"`
	JSON             settingAccountEditResponseEnvelopeMessagesJSON   `json:"-"`
}

func (*SettingAccountEditResponseEnvelopeMessages) UnmarshalJSON added in v4.3.0

func (r *SettingAccountEditResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type SettingAccountEditResponseEnvelopeMessagesSource added in v4.3.0

type SettingAccountEditResponseEnvelopeMessagesSource struct {
	Pointer string                                               `json:"pointer"`
	JSON    settingAccountEditResponseEnvelopeMessagesSourceJSON `json:"-"`
}

func (*SettingAccountEditResponseEnvelopeMessagesSource) UnmarshalJSON added in v4.3.0

func (r *SettingAccountEditResponseEnvelopeMessagesSource) UnmarshalJSON(data []byte) (err error)

type SettingAccountEditResponseEnvelopeSuccess added in v4.2.0

type SettingAccountEditResponseEnvelopeSuccess bool

Whether the API call was successful.

const (
	SettingAccountEditResponseEnvelopeSuccessTrue SettingAccountEditResponseEnvelopeSuccess = true
)

func (SettingAccountEditResponseEnvelopeSuccess) IsKnown added in v4.2.0

type SettingAccountEditResponseZoneDefaults added in v4.2.0

type SettingAccountEditResponseZoneDefaults struct {
	// Whether to flatten all CNAME records in the zone. Note that, due to DNS
	// limitations, a CNAME record at the zone apex will always be flattened.
	FlattenAllCNAMEs bool `json:"flatten_all_cnames"`
	// Whether to enable Foundation DNS Advanced Nameservers on the zone.
	FoundationDNS bool `json:"foundation_dns"`
	// Settings for this internal zone.
	InternalDNS SettingAccountEditResponseZoneDefaultsInternalDNS `json:"internal_dns"`
	// Whether to enable multi-provider DNS, which causes Cloudflare to activate the
	// zone even when non-Cloudflare NS records exist, and to respect NS records at the
	// zone apex during outbound zone transfers.
	MultiProvider bool `json:"multi_provider"`
	// Settings determining the nameservers through which the zone should be available.
	Nameservers SettingAccountEditResponseZoneDefaultsNameservers `json:"nameservers"`
	// The time to live (TTL) of the zone's nameserver (NS) records.
	NSTTL float64 `json:"ns_ttl"`
	// Allows a Secondary DNS zone to use (proxied) override records and CNAME
	// flattening at the zone apex.
	SecondaryOverrides bool `json:"secondary_overrides"`
	// Components of the zone's SOA record.
	SOA SettingAccountEditResponseZoneDefaultsSOA `json:"soa"`
	// Whether the zone mode is a regular or CDN/DNS only zone.
	ZoneMode SettingAccountEditResponseZoneDefaultsZoneMode `json:"zone_mode"`
	JSON     settingAccountEditResponseZoneDefaultsJSON     `json:"-"`
}

func (*SettingAccountEditResponseZoneDefaults) UnmarshalJSON added in v4.2.0

func (r *SettingAccountEditResponseZoneDefaults) UnmarshalJSON(data []byte) (err error)

type SettingAccountEditResponseZoneDefaultsInternalDNS added in v4.2.0

type SettingAccountEditResponseZoneDefaultsInternalDNS struct {
	// The ID of the zone to fallback to.
	ReferenceZoneID string                                                `json:"reference_zone_id"`
	JSON            settingAccountEditResponseZoneDefaultsInternalDNSJSON `json:"-"`
}

Settings for this internal zone.

func (*SettingAccountEditResponseZoneDefaultsInternalDNS) UnmarshalJSON added in v4.2.0

func (r *SettingAccountEditResponseZoneDefaultsInternalDNS) UnmarshalJSON(data []byte) (err error)

type SettingAccountEditResponseZoneDefaultsNameservers added in v4.2.0

type SettingAccountEditResponseZoneDefaultsNameservers struct {
	// Nameserver type
	Type SettingAccountEditResponseZoneDefaultsNameserversType `json:"type,required"`
	JSON settingAccountEditResponseZoneDefaultsNameserversJSON `json:"-"`
}

Settings determining the nameservers through which the zone should be available.

func (*SettingAccountEditResponseZoneDefaultsNameservers) UnmarshalJSON added in v4.2.0

func (r *SettingAccountEditResponseZoneDefaultsNameservers) UnmarshalJSON(data []byte) (err error)

type SettingAccountEditResponseZoneDefaultsNameserversType added in v4.2.0

type SettingAccountEditResponseZoneDefaultsNameserversType string

Nameserver type

const (
	SettingAccountEditResponseZoneDefaultsNameserversTypeCloudflareStandard       SettingAccountEditResponseZoneDefaultsNameserversType = "cloudflare.standard"
	SettingAccountEditResponseZoneDefaultsNameserversTypeCloudflareStandardRandom SettingAccountEditResponseZoneDefaultsNameserversType = "cloudflare.standard.random"
	SettingAccountEditResponseZoneDefaultsNameserversTypeCustomAccount            SettingAccountEditResponseZoneDefaultsNameserversType = "custom.account"
	SettingAccountEditResponseZoneDefaultsNameserversTypeCustomTenant             SettingAccountEditResponseZoneDefaultsNameserversType = "custom.tenant"
)

func (SettingAccountEditResponseZoneDefaultsNameserversType) IsKnown added in v4.2.0

type SettingAccountEditResponseZoneDefaultsSOA added in v4.2.0

type SettingAccountEditResponseZoneDefaultsSOA struct {
	// Time in seconds of being unable to query the primary server after which
	// secondary servers should stop serving the zone.
	Expire float64 `json:"expire,required"`
	// The time to live (TTL) for negative caching of records within the zone.
	MinTTL float64 `json:"min_ttl,required"`
	// The primary nameserver, which may be used for outbound zone transfers.
	MNAME string `json:"mname,required"`
	// Time in seconds after which secondary servers should re-check the SOA record to
	// see if the zone has been updated.
	Refresh float64 `json:"refresh,required"`
	// Time in seconds after which secondary servers should retry queries after the
	// primary server was unresponsive.
	Retry float64 `json:"retry,required"`
	// The email address of the zone administrator, with the first label representing
	// the local part of the email address.
	RNAME string `json:"rname,required"`
	// The time to live (TTL) of the SOA record itself.
	TTL  float64                                       `json:"ttl,required"`
	JSON settingAccountEditResponseZoneDefaultsSOAJSON `json:"-"`
}

Components of the zone's SOA record.

func (*SettingAccountEditResponseZoneDefaultsSOA) UnmarshalJSON added in v4.2.0

func (r *SettingAccountEditResponseZoneDefaultsSOA) UnmarshalJSON(data []byte) (err error)

type SettingAccountEditResponseZoneDefaultsZoneMode added in v4.2.0

type SettingAccountEditResponseZoneDefaultsZoneMode string

Whether the zone mode is a regular or CDN/DNS only zone.

const (
	SettingAccountEditResponseZoneDefaultsZoneModeStandard SettingAccountEditResponseZoneDefaultsZoneMode = "standard"
	SettingAccountEditResponseZoneDefaultsZoneModeCDNOnly  SettingAccountEditResponseZoneDefaultsZoneMode = "cdn_only"
	SettingAccountEditResponseZoneDefaultsZoneModeDNSOnly  SettingAccountEditResponseZoneDefaultsZoneMode = "dns_only"
)

func (SettingAccountEditResponseZoneDefaultsZoneMode) IsKnown added in v4.2.0

type SettingAccountGetParams added in v4.2.0

type SettingAccountGetParams struct {
	// Identifier.
	AccountID param.Field[string] `path:"account_id,required"`
}

type SettingAccountGetResponse added in v4.2.0

type SettingAccountGetResponse struct {
	ZoneDefaults SettingAccountGetResponseZoneDefaults `json:"zone_defaults"`
	JSON         settingAccountGetResponseJSON         `json:"-"`
}

func (*SettingAccountGetResponse) UnmarshalJSON added in v4.2.0

func (r *SettingAccountGetResponse) UnmarshalJSON(data []byte) (err error)

type SettingAccountGetResponseEnvelope added in v4.2.0

type SettingAccountGetResponseEnvelope struct {
	Errors   []SettingAccountGetResponseEnvelopeErrors   `json:"errors,required"`
	Messages []SettingAccountGetResponseEnvelopeMessages `json:"messages,required"`
	// Whether the API call was successful.
	Success SettingAccountGetResponseEnvelopeSuccess `json:"success,required"`
	Result  SettingAccountGetResponse                `json:"result"`
	JSON    settingAccountGetResponseEnvelopeJSON    `json:"-"`
}

func (*SettingAccountGetResponseEnvelope) UnmarshalJSON added in v4.2.0

func (r *SettingAccountGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type SettingAccountGetResponseEnvelopeErrors added in v4.3.0

type SettingAccountGetResponseEnvelopeErrors struct {
	Code             int64                                         `json:"code,required"`
	Message          string                                        `json:"message,required"`
	DocumentationURL string                                        `json:"documentation_url"`
	Source           SettingAccountGetResponseEnvelopeErrorsSource `json:"source"`
	JSON             settingAccountGetResponseEnvelopeErrorsJSON   `json:"-"`
}

func (*SettingAccountGetResponseEnvelopeErrors) UnmarshalJSON added in v4.3.0

func (r *SettingAccountGetResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type SettingAccountGetResponseEnvelopeErrorsSource added in v4.3.0

type SettingAccountGetResponseEnvelopeErrorsSource struct {
	Pointer string                                            `json:"pointer"`
	JSON    settingAccountGetResponseEnvelopeErrorsSourceJSON `json:"-"`
}

func (*SettingAccountGetResponseEnvelopeErrorsSource) UnmarshalJSON added in v4.3.0

func (r *SettingAccountGetResponseEnvelopeErrorsSource) UnmarshalJSON(data []byte) (err error)

type SettingAccountGetResponseEnvelopeMessages added in v4.3.0

type SettingAccountGetResponseEnvelopeMessages struct {
	Code             int64                                           `json:"code,required"`
	Message          string                                          `json:"message,required"`
	DocumentationURL string                                          `json:"documentation_url"`
	Source           SettingAccountGetResponseEnvelopeMessagesSource `json:"source"`
	JSON             settingAccountGetResponseEnvelopeMessagesJSON   `json:"-"`
}

func (*SettingAccountGetResponseEnvelopeMessages) UnmarshalJSON added in v4.3.0

func (r *SettingAccountGetResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type SettingAccountGetResponseEnvelopeMessagesSource added in v4.3.0

type SettingAccountGetResponseEnvelopeMessagesSource struct {
	Pointer string                                              `json:"pointer"`
	JSON    settingAccountGetResponseEnvelopeMessagesSourceJSON `json:"-"`
}

func (*SettingAccountGetResponseEnvelopeMessagesSource) UnmarshalJSON added in v4.3.0

func (r *SettingAccountGetResponseEnvelopeMessagesSource) UnmarshalJSON(data []byte) (err error)

type SettingAccountGetResponseEnvelopeSuccess added in v4.2.0

type SettingAccountGetResponseEnvelopeSuccess bool

Whether the API call was successful.

const (
	SettingAccountGetResponseEnvelopeSuccessTrue SettingAccountGetResponseEnvelopeSuccess = true
)

func (SettingAccountGetResponseEnvelopeSuccess) IsKnown added in v4.2.0

type SettingAccountGetResponseZoneDefaults added in v4.2.0

type SettingAccountGetResponseZoneDefaults struct {
	// Whether to flatten all CNAME records in the zone. Note that, due to DNS
	// limitations, a CNAME record at the zone apex will always be flattened.
	FlattenAllCNAMEs bool `json:"flatten_all_cnames"`
	// Whether to enable Foundation DNS Advanced Nameservers on the zone.
	FoundationDNS bool `json:"foundation_dns"`
	// Settings for this internal zone.
	InternalDNS SettingAccountGetResponseZoneDefaultsInternalDNS `json:"internal_dns"`
	// Whether to enable multi-provider DNS, which causes Cloudflare to activate the
	// zone even when non-Cloudflare NS records exist, and to respect NS records at the
	// zone apex during outbound zone transfers.
	MultiProvider bool `json:"multi_provider"`
	// Settings determining the nameservers through which the zone should be available.
	Nameservers SettingAccountGetResponseZoneDefaultsNameservers `json:"nameservers"`
	// The time to live (TTL) of the zone's nameserver (NS) records.
	NSTTL float64 `json:"ns_ttl"`
	// Allows a Secondary DNS zone to use (proxied) override records and CNAME
	// flattening at the zone apex.
	SecondaryOverrides bool `json:"secondary_overrides"`
	// Components of the zone's SOA record.
	SOA SettingAccountGetResponseZoneDefaultsSOA `json:"soa"`
	// Whether the zone mode is a regular or CDN/DNS only zone.
	ZoneMode SettingAccountGetResponseZoneDefaultsZoneMode `json:"zone_mode"`
	JSON     settingAccountGetResponseZoneDefaultsJSON     `json:"-"`
}

func (*SettingAccountGetResponseZoneDefaults) UnmarshalJSON added in v4.2.0

func (r *SettingAccountGetResponseZoneDefaults) UnmarshalJSON(data []byte) (err error)

type SettingAccountGetResponseZoneDefaultsInternalDNS added in v4.2.0

type SettingAccountGetResponseZoneDefaultsInternalDNS struct {
	// The ID of the zone to fallback to.
	ReferenceZoneID string                                               `json:"reference_zone_id"`
	JSON            settingAccountGetResponseZoneDefaultsInternalDNSJSON `json:"-"`
}

Settings for this internal zone.

func (*SettingAccountGetResponseZoneDefaultsInternalDNS) UnmarshalJSON added in v4.2.0

func (r *SettingAccountGetResponseZoneDefaultsInternalDNS) UnmarshalJSON(data []byte) (err error)

type SettingAccountGetResponseZoneDefaultsNameservers added in v4.2.0

type SettingAccountGetResponseZoneDefaultsNameservers struct {
	// Nameserver type
	Type SettingAccountGetResponseZoneDefaultsNameserversType `json:"type,required"`
	JSON settingAccountGetResponseZoneDefaultsNameserversJSON `json:"-"`
}

Settings determining the nameservers through which the zone should be available.

func (*SettingAccountGetResponseZoneDefaultsNameservers) UnmarshalJSON added in v4.2.0

func (r *SettingAccountGetResponseZoneDefaultsNameservers) UnmarshalJSON(data []byte) (err error)

type SettingAccountGetResponseZoneDefaultsNameserversType added in v4.2.0

type SettingAccountGetResponseZoneDefaultsNameserversType string

Nameserver type

const (
	SettingAccountGetResponseZoneDefaultsNameserversTypeCloudflareStandard       SettingAccountGetResponseZoneDefaultsNameserversType = "cloudflare.standard"
	SettingAccountGetResponseZoneDefaultsNameserversTypeCloudflareStandardRandom SettingAccountGetResponseZoneDefaultsNameserversType = "cloudflare.standard.random"
	SettingAccountGetResponseZoneDefaultsNameserversTypeCustomAccount            SettingAccountGetResponseZoneDefaultsNameserversType = "custom.account"
	SettingAccountGetResponseZoneDefaultsNameserversTypeCustomTenant             SettingAccountGetResponseZoneDefaultsNameserversType = "custom.tenant"
)

func (SettingAccountGetResponseZoneDefaultsNameserversType) IsKnown added in v4.2.0

type SettingAccountGetResponseZoneDefaultsSOA added in v4.2.0

type SettingAccountGetResponseZoneDefaultsSOA struct {
	// Time in seconds of being unable to query the primary server after which
	// secondary servers should stop serving the zone.
	Expire float64 `json:"expire,required"`
	// The time to live (TTL) for negative caching of records within the zone.
	MinTTL float64 `json:"min_ttl,required"`
	// The primary nameserver, which may be used for outbound zone transfers.
	MNAME string `json:"mname,required"`
	// Time in seconds after which secondary servers should re-check the SOA record to
	// see if the zone has been updated.
	Refresh float64 `json:"refresh,required"`
	// Time in seconds after which secondary servers should retry queries after the
	// primary server was unresponsive.
	Retry float64 `json:"retry,required"`
	// The email address of the zone administrator, with the first label representing
	// the local part of the email address.
	RNAME string `json:"rname,required"`
	// The time to live (TTL) of the SOA record itself.
	TTL  float64                                      `json:"ttl,required"`
	JSON settingAccountGetResponseZoneDefaultsSOAJSON `json:"-"`
}

Components of the zone's SOA record.

func (*SettingAccountGetResponseZoneDefaultsSOA) UnmarshalJSON added in v4.2.0

func (r *SettingAccountGetResponseZoneDefaultsSOA) UnmarshalJSON(data []byte) (err error)

type SettingAccountGetResponseZoneDefaultsZoneMode added in v4.2.0

type SettingAccountGetResponseZoneDefaultsZoneMode string

Whether the zone mode is a regular or CDN/DNS only zone.

const (
	SettingAccountGetResponseZoneDefaultsZoneModeStandard SettingAccountGetResponseZoneDefaultsZoneMode = "standard"
	SettingAccountGetResponseZoneDefaultsZoneModeCDNOnly  SettingAccountGetResponseZoneDefaultsZoneMode = "cdn_only"
	SettingAccountGetResponseZoneDefaultsZoneModeDNSOnly  SettingAccountGetResponseZoneDefaultsZoneMode = "dns_only"
)

func (SettingAccountGetResponseZoneDefaultsZoneMode) IsKnown added in v4.2.0

type SettingAccountService added in v4.2.0

type SettingAccountService struct {
	Options []option.RequestOption
	Views   *SettingAccountViewService
}

SettingAccountService contains methods and other services that help with interacting with the cloudflare API.

Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewSettingAccountService method instead.

func NewSettingAccountService added in v4.2.0

func NewSettingAccountService(opts ...option.RequestOption) (r *SettingAccountService)

NewSettingAccountService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*SettingAccountService) Edit added in v4.2.0

Update DNS settings for an account

func (*SettingAccountService) Get added in v4.2.0

Show DNS settings for an account

type SettingAccountViewDeleteParams added in v4.2.0

type SettingAccountViewDeleteParams struct {
	// Identifier.
	AccountID param.Field[string] `path:"account_id,required"`
}

type SettingAccountViewDeleteResponse added in v4.2.0

type SettingAccountViewDeleteResponse struct {
	// Identifier.
	ID   string                               `json:"id"`
	JSON settingAccountViewDeleteResponseJSON `json:"-"`
}

func (*SettingAccountViewDeleteResponse) UnmarshalJSON added in v4.2.0

func (r *SettingAccountViewDeleteResponse) UnmarshalJSON(data []byte) (err error)

type SettingAccountViewDeleteResponseEnvelope added in v4.2.0

type SettingAccountViewDeleteResponseEnvelope struct {
	Result SettingAccountViewDeleteResponse             `json:"result"`
	JSON   settingAccountViewDeleteResponseEnvelopeJSON `json:"-"`
}

func (*SettingAccountViewDeleteResponseEnvelope) UnmarshalJSON added in v4.2.0

func (r *SettingAccountViewDeleteResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type SettingAccountViewEditParams added in v4.2.0

type SettingAccountViewEditParams struct {
	// Identifier.
	AccountID param.Field[string] `path:"account_id,required"`
	// The name of the view.
	Name param.Field[string] `json:"name"`
	// The list of zones linked to this view.
	Zones param.Field[[]string] `json:"zones"`
}

func (SettingAccountViewEditParams) MarshalJSON added in v4.2.0

func (r SettingAccountViewEditParams) MarshalJSON() (data []byte, err error)

type SettingAccountViewEditResponse added in v4.2.0

type SettingAccountViewEditResponse struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the view was created.
	CreatedTime time.Time `json:"created_time,required" format:"date-time"`
	// When the view was last modified.
	ModifiedTime time.Time `json:"modified_time,required" format:"date-time"`
	// The name of the view.
	Name string `json:"name,required"`
	// The list of zones linked to this view.
	Zones []string                           `json:"zones,required"`
	JSON  settingAccountViewEditResponseJSON `json:"-"`
}

func (*SettingAccountViewEditResponse) UnmarshalJSON added in v4.2.0

func (r *SettingAccountViewEditResponse) UnmarshalJSON(data []byte) (err error)

type SettingAccountViewEditResponseEnvelope added in v4.2.0

type SettingAccountViewEditResponseEnvelope struct {
	Errors   []SettingAccountViewEditResponseEnvelopeErrors   `json:"errors,required"`
	Messages []SettingAccountViewEditResponseEnvelopeMessages `json:"messages,required"`
	// Whether the API call was successful.
	Success SettingAccountViewEditResponseEnvelopeSuccess `json:"success,required"`
	Result  SettingAccountViewEditResponse                `json:"result"`
	JSON    settingAccountViewEditResponseEnvelopeJSON    `json:"-"`
}

func (*SettingAccountViewEditResponseEnvelope) UnmarshalJSON added in v4.2.0

func (r *SettingAccountViewEditResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type SettingAccountViewEditResponseEnvelopeErrors added in v4.3.0

type SettingAccountViewEditResponseEnvelopeErrors struct {
	Code             int64                                              `json:"code,required"`
	Message          string                                             `json:"message,required"`
	DocumentationURL string                                             `json:"documentation_url"`
	Source           SettingAccountViewEditResponseEnvelopeErrorsSource `json:"source"`
	JSON             settingAccountViewEditResponseEnvelopeErrorsJSON   `json:"-"`
}

func (*SettingAccountViewEditResponseEnvelopeErrors) UnmarshalJSON added in v4.3.0

func (r *SettingAccountViewEditResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type SettingAccountViewEditResponseEnvelopeErrorsSource added in v4.3.0

type SettingAccountViewEditResponseEnvelopeErrorsSource struct {
	Pointer string                                                 `json:"pointer"`
	JSON    settingAccountViewEditResponseEnvelopeErrorsSourceJSON `json:"-"`
}

func (*SettingAccountViewEditResponseEnvelopeErrorsSource) UnmarshalJSON added in v4.3.0

func (r *SettingAccountViewEditResponseEnvelopeErrorsSource) UnmarshalJSON(data []byte) (err error)

type SettingAccountViewEditResponseEnvelopeMessages added in v4.3.0

type SettingAccountViewEditResponseEnvelopeMessages struct {
	Code             int64                                                `json:"code,required"`
	Message          string                                               `json:"message,required"`
	DocumentationURL string                                               `json:"documentation_url"`
	Source           SettingAccountViewEditResponseEnvelopeMessagesSource `json:"source"`
	JSON             settingAccountViewEditResponseEnvelopeMessagesJSON   `json:"-"`
}

func (*SettingAccountViewEditResponseEnvelopeMessages) UnmarshalJSON added in v4.3.0

func (r *SettingAccountViewEditResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type SettingAccountViewEditResponseEnvelopeMessagesSource added in v4.3.0

type SettingAccountViewEditResponseEnvelopeMessagesSource struct {
	Pointer string                                                   `json:"pointer"`
	JSON    settingAccountViewEditResponseEnvelopeMessagesSourceJSON `json:"-"`
}

func (*SettingAccountViewEditResponseEnvelopeMessagesSource) UnmarshalJSON added in v4.3.0

func (r *SettingAccountViewEditResponseEnvelopeMessagesSource) UnmarshalJSON(data []byte) (err error)

type SettingAccountViewEditResponseEnvelopeSuccess added in v4.2.0

type SettingAccountViewEditResponseEnvelopeSuccess bool

Whether the API call was successful.

const (
	SettingAccountViewEditResponseEnvelopeSuccessTrue SettingAccountViewEditResponseEnvelopeSuccess = true
)

func (SettingAccountViewEditResponseEnvelopeSuccess) IsKnown added in v4.2.0

type SettingAccountViewGetParams added in v4.2.0

type SettingAccountViewGetParams struct {
	// Identifier.
	AccountID param.Field[string] `path:"account_id,required"`
}

type SettingAccountViewGetResponse added in v4.2.0

type SettingAccountViewGetResponse struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the view was created.
	CreatedTime time.Time `json:"created_time,required" format:"date-time"`
	// When the view was last modified.
	ModifiedTime time.Time `json:"modified_time,required" format:"date-time"`
	// The name of the view.
	Name string `json:"name,required"`
	// The list of zones linked to this view.
	Zones []string                          `json:"zones,required"`
	JSON  settingAccountViewGetResponseJSON `json:"-"`
}

func (*SettingAccountViewGetResponse) UnmarshalJSON added in v4.2.0

func (r *SettingAccountViewGetResponse) UnmarshalJSON(data []byte) (err error)

type SettingAccountViewGetResponseEnvelope added in v4.2.0

type SettingAccountViewGetResponseEnvelope struct {
	Errors   []SettingAccountViewGetResponseEnvelopeErrors   `json:"errors,required"`
	Messages []SettingAccountViewGetResponseEnvelopeMessages `json:"messages,required"`
	// Whether the API call was successful.
	Success SettingAccountViewGetResponseEnvelopeSuccess `json:"success,required"`
	Result  SettingAccountViewGetResponse                `json:"result"`
	JSON    settingAccountViewGetResponseEnvelopeJSON    `json:"-"`
}

func (*SettingAccountViewGetResponseEnvelope) UnmarshalJSON added in v4.2.0

func (r *SettingAccountViewGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type SettingAccountViewGetResponseEnvelopeErrors added in v4.3.0

type SettingAccountViewGetResponseEnvelopeErrors struct {
	Code             int64                                             `json:"code,required"`
	Message          string                                            `json:"message,required"`
	DocumentationURL string                                            `json:"documentation_url"`
	Source           SettingAccountViewGetResponseEnvelopeErrorsSource `json:"source"`
	JSON             settingAccountViewGetResponseEnvelopeErrorsJSON   `json:"-"`
}

func (*SettingAccountViewGetResponseEnvelopeErrors) UnmarshalJSON added in v4.3.0

func (r *SettingAccountViewGetResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type SettingAccountViewGetResponseEnvelopeErrorsSource added in v4.3.0

type SettingAccountViewGetResponseEnvelopeErrorsSource struct {
	Pointer string                                                `json:"pointer"`
	JSON    settingAccountViewGetResponseEnvelopeErrorsSourceJSON `json:"-"`
}

func (*SettingAccountViewGetResponseEnvelopeErrorsSource) UnmarshalJSON added in v4.3.0

func (r *SettingAccountViewGetResponseEnvelopeErrorsSource) UnmarshalJSON(data []byte) (err error)

type SettingAccountViewGetResponseEnvelopeMessages added in v4.3.0

type SettingAccountViewGetResponseEnvelopeMessages struct {
	Code             int64                                               `json:"code,required"`
	Message          string                                              `json:"message,required"`
	DocumentationURL string                                              `json:"documentation_url"`
	Source           SettingAccountViewGetResponseEnvelopeMessagesSource `json:"source"`
	JSON             settingAccountViewGetResponseEnvelopeMessagesJSON   `json:"-"`
}

func (*SettingAccountViewGetResponseEnvelopeMessages) UnmarshalJSON added in v4.3.0

func (r *SettingAccountViewGetResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type SettingAccountViewGetResponseEnvelopeMessagesSource added in v4.3.0

type SettingAccountViewGetResponseEnvelopeMessagesSource struct {
	Pointer string                                                  `json:"pointer"`
	JSON    settingAccountViewGetResponseEnvelopeMessagesSourceJSON `json:"-"`
}

func (*SettingAccountViewGetResponseEnvelopeMessagesSource) UnmarshalJSON added in v4.3.0

func (r *SettingAccountViewGetResponseEnvelopeMessagesSource) UnmarshalJSON(data []byte) (err error)

type SettingAccountViewGetResponseEnvelopeSuccess added in v4.2.0

type SettingAccountViewGetResponseEnvelopeSuccess bool

Whether the API call was successful.

const (
	SettingAccountViewGetResponseEnvelopeSuccessTrue SettingAccountViewGetResponseEnvelopeSuccess = true
)

func (SettingAccountViewGetResponseEnvelopeSuccess) IsKnown added in v4.2.0

type SettingAccountViewListParams added in v4.2.0

type SettingAccountViewListParams struct {
	// Identifier.
	AccountID param.Field[string] `path:"account_id,required"`
	// Direction to order DNS views in.
	Direction param.Field[SettingAccountViewListParamsDirection] `query:"direction"`
	// Whether to match all search requirements or at least one (any). If set to `all`,
	// acts like a logical AND between filters. If set to `any`, acts like a logical OR
	// instead.
	Match param.Field[SettingAccountViewListParamsMatch] `query:"match"`
	Name  param.Field[SettingAccountViewListParamsName]  `query:"name"`
	// Field to order DNS views by.
	Order param.Field[SettingAccountViewListParamsOrder] `query:"order"`
	// Page number of paginated results.
	Page param.Field[float64] `query:"page"`
	// Number of DNS views per page.
	PerPage param.Field[float64] `query:"per_page"`
	// A zone ID that exists in the zones list for the view.
	ZoneID param.Field[string] `query:"zone_id"`
	// A zone name that exists in the zones list for the view.
	ZoneName param.Field[string] `query:"zone_name"`
}

func (SettingAccountViewListParams) URLQuery added in v4.2.0

func (r SettingAccountViewListParams) URLQuery() (v url.Values)

URLQuery serializes SettingAccountViewListParams's query parameters as `url.Values`.

type SettingAccountViewListParamsDirection added in v4.2.0

type SettingAccountViewListParamsDirection string

Direction to order DNS views in.

const (
	SettingAccountViewListParamsDirectionAsc  SettingAccountViewListParamsDirection = "asc"
	SettingAccountViewListParamsDirectionDesc SettingAccountViewListParamsDirection = "desc"
)

func (SettingAccountViewListParamsDirection) IsKnown added in v4.2.0

type SettingAccountViewListParamsMatch added in v4.2.0

type SettingAccountViewListParamsMatch string

Whether to match all search requirements or at least one (any). If set to `all`, acts like a logical AND between filters. If set to `any`, acts like a logical OR instead.

const (
	SettingAccountViewListParamsMatchAny SettingAccountViewListParamsMatch = "any"
	SettingAccountViewListParamsMatchAll SettingAccountViewListParamsMatch = "all"
)

func (SettingAccountViewListParamsMatch) IsKnown added in v4.2.0

type SettingAccountViewListParamsName added in v4.2.0

type SettingAccountViewListParamsName struct {
	// Substring of the DNS view name.
	Contains param.Field[string] `query:"contains"`
	// Suffix of the DNS view name.
	Endswith param.Field[string] `query:"endswith"`
	// Exact value of the DNS view name.
	Exact param.Field[string] `query:"exact"`
	// Prefix of the DNS view name.
	Startswith param.Field[string] `query:"startswith"`
}

func (SettingAccountViewListParamsName) URLQuery added in v4.2.0

func (r SettingAccountViewListParamsName) URLQuery() (v url.Values)

URLQuery serializes SettingAccountViewListParamsName's query parameters as `url.Values`.

type SettingAccountViewListParamsOrder added in v4.2.0

type SettingAccountViewListParamsOrder string

Field to order DNS views by.

const (
	SettingAccountViewListParamsOrderName       SettingAccountViewListParamsOrder = "name"
	SettingAccountViewListParamsOrderCreatedOn  SettingAccountViewListParamsOrder = "created_on"
	SettingAccountViewListParamsOrderModifiedOn SettingAccountViewListParamsOrder = "modified_on"
)

func (SettingAccountViewListParamsOrder) IsKnown added in v4.2.0

type SettingAccountViewListResponse added in v4.2.0

type SettingAccountViewListResponse struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the view was created.
	CreatedTime time.Time `json:"created_time,required" format:"date-time"`
	// When the view was last modified.
	ModifiedTime time.Time `json:"modified_time,required" format:"date-time"`
	// The name of the view.
	Name string `json:"name,required"`
	// The list of zones linked to this view.
	Zones []string                           `json:"zones,required"`
	JSON  settingAccountViewListResponseJSON `json:"-"`
}

func (*SettingAccountViewListResponse) UnmarshalJSON added in v4.2.0

func (r *SettingAccountViewListResponse) UnmarshalJSON(data []byte) (err error)

type SettingAccountViewNewParams added in v4.2.0

type SettingAccountViewNewParams struct {
	// Identifier.
	AccountID param.Field[string] `path:"account_id,required"`
	// The name of the view.
	Name param.Field[string] `json:"name,required"`
	// The list of zones linked to this view.
	Zones param.Field[[]string] `json:"zones,required"`
}

func (SettingAccountViewNewParams) MarshalJSON added in v4.2.0

func (r SettingAccountViewNewParams) MarshalJSON() (data []byte, err error)

type SettingAccountViewNewResponse added in v4.2.0

type SettingAccountViewNewResponse struct {
	// Identifier.
	ID string `json:"id,required"`
	// When the view was created.
	CreatedTime time.Time `json:"created_time,required" format:"date-time"`
	// When the view was last modified.
	ModifiedTime time.Time `json:"modified_time,required" format:"date-time"`
	// The name of the view.
	Name string `json:"name,required"`
	// The list of zones linked to this view.
	Zones []string                          `json:"zones,required"`
	JSON  settingAccountViewNewResponseJSON `json:"-"`
}

func (*SettingAccountViewNewResponse) UnmarshalJSON added in v4.2.0

func (r *SettingAccountViewNewResponse) UnmarshalJSON(data []byte) (err error)

type SettingAccountViewNewResponseEnvelope added in v4.2.0

type SettingAccountViewNewResponseEnvelope struct {
	Errors   []SettingAccountViewNewResponseEnvelopeErrors   `json:"errors,required"`
	Messages []SettingAccountViewNewResponseEnvelopeMessages `json:"messages,required"`
	// Whether the API call was successful.
	Success SettingAccountViewNewResponseEnvelopeSuccess `json:"success,required"`
	Result  SettingAccountViewNewResponse                `json:"result"`
	JSON    settingAccountViewNewResponseEnvelopeJSON    `json:"-"`
}

func (*SettingAccountViewNewResponseEnvelope) UnmarshalJSON added in v4.2.0

func (r *SettingAccountViewNewResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type SettingAccountViewNewResponseEnvelopeErrors added in v4.3.0

type SettingAccountViewNewResponseEnvelopeErrors struct {
	Code             int64                                             `json:"code,required"`
	Message          string                                            `json:"message,required"`
	DocumentationURL string                                            `json:"documentation_url"`
	Source           SettingAccountViewNewResponseEnvelopeErrorsSource `json:"source"`
	JSON             settingAccountViewNewResponseEnvelopeErrorsJSON   `json:"-"`
}

func (*SettingAccountViewNewResponseEnvelopeErrors) UnmarshalJSON added in v4.3.0

func (r *SettingAccountViewNewResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type SettingAccountViewNewResponseEnvelopeErrorsSource added in v4.3.0

type SettingAccountViewNewResponseEnvelopeErrorsSource struct {
	Pointer string                                                `json:"pointer"`
	JSON    settingAccountViewNewResponseEnvelopeErrorsSourceJSON `json:"-"`
}

func (*SettingAccountViewNewResponseEnvelopeErrorsSource) UnmarshalJSON added in v4.3.0

func (r *SettingAccountViewNewResponseEnvelopeErrorsSource) UnmarshalJSON(data []byte) (err error)

type SettingAccountViewNewResponseEnvelopeMessages added in v4.3.0

type SettingAccountViewNewResponseEnvelopeMessages struct {
	Code             int64                                               `json:"code,required"`
	Message          string                                              `json:"message,required"`
	DocumentationURL string                                              `json:"documentation_url"`
	Source           SettingAccountViewNewResponseEnvelopeMessagesSource `json:"source"`
	JSON             settingAccountViewNewResponseEnvelopeMessagesJSON   `json:"-"`
}

func (*SettingAccountViewNewResponseEnvelopeMessages) UnmarshalJSON added in v4.3.0

func (r *SettingAccountViewNewResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type SettingAccountViewNewResponseEnvelopeMessagesSource added in v4.3.0

type SettingAccountViewNewResponseEnvelopeMessagesSource struct {
	Pointer string                                                  `json:"pointer"`
	JSON    settingAccountViewNewResponseEnvelopeMessagesSourceJSON `json:"-"`
}

func (*SettingAccountViewNewResponseEnvelopeMessagesSource) UnmarshalJSON added in v4.3.0

func (r *SettingAccountViewNewResponseEnvelopeMessagesSource) UnmarshalJSON(data []byte) (err error)

type SettingAccountViewNewResponseEnvelopeSuccess added in v4.2.0

type SettingAccountViewNewResponseEnvelopeSuccess bool

Whether the API call was successful.

const (
	SettingAccountViewNewResponseEnvelopeSuccessTrue SettingAccountViewNewResponseEnvelopeSuccess = true
)

func (SettingAccountViewNewResponseEnvelopeSuccess) IsKnown added in v4.2.0

type SettingAccountViewService added in v4.2.0

type SettingAccountViewService struct {
	Options []option.RequestOption
}

SettingAccountViewService contains methods and other services that help with interacting with the cloudflare API.

Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewSettingAccountViewService method instead.

func NewSettingAccountViewService added in v4.2.0

func NewSettingAccountViewService(opts ...option.RequestOption) (r *SettingAccountViewService)

NewSettingAccountViewService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*SettingAccountViewService) Delete added in v4.2.0

Delete an existing Internal DNS View

func (*SettingAccountViewService) Edit added in v4.2.0

Update an existing Internal DNS View

func (*SettingAccountViewService) Get added in v4.2.0

Get DNS Internal View

func (*SettingAccountViewService) List added in v4.2.0

List DNS Internal Views for an Account

func (*SettingAccountViewService) ListAutoPaging added in v4.2.0

List DNS Internal Views for an Account

func (*SettingAccountViewService) New added in v4.2.0

Create Internal DNS View for an account

type SettingService

type SettingService struct {
	Options []option.RequestOption
	Zone    *SettingZoneService
	Account *SettingAccountService
}

SettingService contains methods and other services that help with interacting with the cloudflare API.

Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewSettingService method instead.

func NewSettingService

func NewSettingService(opts ...option.RequestOption) (r *SettingService)

NewSettingService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

type SettingZoneEditParams added in v4.2.0

type SettingZoneEditParams struct {
	// Identifier.
	ZoneID param.Field[string] `path:"zone_id,required"`
	// Whether to flatten all CNAME records in the zone. Note that, due to DNS
	// limitations, a CNAME record at the zone apex will always be flattened.
	FlattenAllCNAMEs param.Field[bool] `json:"flatten_all_cnames"`
	// Whether to enable Foundation DNS Advanced Nameservers on the zone.
	FoundationDNS param.Field[bool] `json:"foundation_dns"`
	// Settings for this internal zone.
	InternalDNS param.Field[SettingZoneEditParamsInternalDNS] `json:"internal_dns"`
	// Whether to enable multi-provider DNS, which causes Cloudflare to activate the
	// zone even when non-Cloudflare NS records exist, and to respect NS records at the
	// zone apex during outbound zone transfers.
	MultiProvider param.Field[bool] `json:"multi_provider"`
	// Settings determining the nameservers through which the zone should be available.
	Nameservers param.Field[SettingZoneEditParamsNameservers] `json:"nameservers"`
	// The time to live (TTL) of the zone's nameserver (NS) records.
	NSTTL param.Field[float64] `json:"ns_ttl"`
	// Allows a Secondary DNS zone to use (proxied) override records and CNAME
	// flattening at the zone apex.
	SecondaryOverrides param.Field[bool] `json:"secondary_overrides"`
	// Components of the zone's SOA record.
	SOA param.Field[SettingZoneEditParamsSOA] `json:"soa"`
	// Whether the zone mode is a regular or CDN/DNS only zone.
	ZoneMode param.Field[SettingZoneEditParamsZoneMode] `json:"zone_mode"`
}

func (SettingZoneEditParams) MarshalJSON added in v4.2.0

func (r SettingZoneEditParams) MarshalJSON() (data []byte, err error)

type SettingZoneEditParamsInternalDNS added in v4.2.0

type SettingZoneEditParamsInternalDNS struct {
	// The ID of the zone to fallback to.
	ReferenceZoneID param.Field[string] `json:"reference_zone_id"`
}

Settings for this internal zone.

func (SettingZoneEditParamsInternalDNS) MarshalJSON added in v4.2.0

func (r SettingZoneEditParamsInternalDNS) MarshalJSON() (data []byte, err error)

type SettingZoneEditParamsNameservers added in v4.2.0

type SettingZoneEditParamsNameservers struct {
	// Nameserver type
	Type param.Field[SettingZoneEditParamsNameserversType] `json:"type,required"`
	// Configured nameserver set to be used for this zone
	NSSet param.Field[int64] `json:"ns_set"`
}

Settings determining the nameservers through which the zone should be available.

func (SettingZoneEditParamsNameservers) MarshalJSON added in v4.2.0

func (r SettingZoneEditParamsNameservers) MarshalJSON() (data []byte, err error)

type SettingZoneEditParamsNameserversType added in v4.2.0

type SettingZoneEditParamsNameserversType string

Nameserver type

const (
	SettingZoneEditParamsNameserversTypeCloudflareStandard SettingZoneEditParamsNameserversType = "cloudflare.standard"
	SettingZoneEditParamsNameserversTypeCustomAccount      SettingZoneEditParamsNameserversType = "custom.account"
	SettingZoneEditParamsNameserversTypeCustomTenant       SettingZoneEditParamsNameserversType = "custom.tenant"
	SettingZoneEditParamsNameserversTypeCustomZone         SettingZoneEditParamsNameserversType = "custom.zone"
)

func (SettingZoneEditParamsNameserversType) IsKnown added in v4.2.0

type SettingZoneEditParamsSOA added in v4.2.0

type SettingZoneEditParamsSOA struct {
	// Time in seconds of being unable to query the primary server after which
	// secondary servers should stop serving the zone.
	Expire param.Field[float64] `json:"expire,required"`
	// The time to live (TTL) for negative caching of records within the zone.
	MinTTL param.Field[float64] `json:"min_ttl,required"`
	// The primary nameserver, which may be used for outbound zone transfers.
	MNAME param.Field[string] `json:"mname,required"`
	// Time in seconds after which secondary servers should re-check the SOA record to
	// see if the zone has been updated.
	Refresh param.Field[float64] `json:"refresh,required"`
	// Time in seconds after which secondary servers should retry queries after the
	// primary server was unresponsive.
	Retry param.Field[float64] `json:"retry,required"`
	// The email address of the zone administrator, with the first label representing
	// the local part of the email address.
	RNAME param.Field[string] `json:"rname,required"`
	// The time to live (TTL) of the SOA record itself.
	TTL param.Field[float64] `json:"ttl,required"`
}

Components of the zone's SOA record.

func (SettingZoneEditParamsSOA) MarshalJSON added in v4.2.0

func (r SettingZoneEditParamsSOA) MarshalJSON() (data []byte, err error)

type SettingZoneEditParamsZoneMode added in v4.2.0

type SettingZoneEditParamsZoneMode string

Whether the zone mode is a regular or CDN/DNS only zone.

const (
	SettingZoneEditParamsZoneModeStandard SettingZoneEditParamsZoneMode = "standard"
	SettingZoneEditParamsZoneModeCDNOnly  SettingZoneEditParamsZoneMode = "cdn_only"
	SettingZoneEditParamsZoneModeDNSOnly  SettingZoneEditParamsZoneMode = "dns_only"
)

func (SettingZoneEditParamsZoneMode) IsKnown added in v4.2.0

func (r SettingZoneEditParamsZoneMode) IsKnown() bool

type SettingZoneEditResponse added in v4.2.0

type SettingZoneEditResponse struct {
	// Whether to flatten all CNAME records in the zone. Note that, due to DNS
	// limitations, a CNAME record at the zone apex will always be flattened.
	FlattenAllCNAMEs bool `json:"flatten_all_cnames"`
	// Whether to enable Foundation DNS Advanced Nameservers on the zone.
	FoundationDNS bool `json:"foundation_dns"`
	// Settings for this internal zone.
	InternalDNS SettingZoneEditResponseInternalDNS `json:"internal_dns"`
	// Whether to enable multi-provider DNS, which causes Cloudflare to activate the
	// zone even when non-Cloudflare NS records exist, and to respect NS records at the
	// zone apex during outbound zone transfers.
	MultiProvider bool `json:"multi_provider"`
	// Settings determining the nameservers through which the zone should be available.
	Nameservers SettingZoneEditResponseNameservers `json:"nameservers"`
	// The time to live (TTL) of the zone's nameserver (NS) records.
	NSTTL float64 `json:"ns_ttl"`
	// Allows a Secondary DNS zone to use (proxied) override records and CNAME
	// flattening at the zone apex.
	SecondaryOverrides bool `json:"secondary_overrides"`
	// Components of the zone's SOA record.
	SOA SettingZoneEditResponseSOA `json:"soa"`
	// Whether the zone mode is a regular or CDN/DNS only zone.
	ZoneMode SettingZoneEditResponseZoneMode `json:"zone_mode"`
	JSON     settingZoneEditResponseJSON     `json:"-"`
}

func (*SettingZoneEditResponse) UnmarshalJSON added in v4.2.0

func (r *SettingZoneEditResponse) UnmarshalJSON(data []byte) (err error)

type SettingZoneEditResponseEnvelope added in v4.2.0

type SettingZoneEditResponseEnvelope struct {
	Errors   []SettingZoneEditResponseEnvelopeErrors   `json:"errors,required"`
	Messages []SettingZoneEditResponseEnvelopeMessages `json:"messages,required"`
	// Whether the API call was successful.
	Success SettingZoneEditResponseEnvelopeSuccess `json:"success,required"`
	Result  SettingZoneEditResponse                `json:"result"`
	JSON    settingZoneEditResponseEnvelopeJSON    `json:"-"`
}

func (*SettingZoneEditResponseEnvelope) UnmarshalJSON added in v4.2.0

func (r *SettingZoneEditResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type SettingZoneEditResponseEnvelopeErrors added in v4.3.0

type SettingZoneEditResponseEnvelopeErrors struct {
	Code             int64                                       `json:"code,required"`
	Message          string                                      `json:"message,required"`
	DocumentationURL string                                      `json:"documentation_url"`
	Source           SettingZoneEditResponseEnvelopeErrorsSource `json:"source"`
	JSON             settingZoneEditResponseEnvelopeErrorsJSON   `json:"-"`
}

func (*SettingZoneEditResponseEnvelopeErrors) UnmarshalJSON added in v4.3.0

func (r *SettingZoneEditResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type SettingZoneEditResponseEnvelopeErrorsSource added in v4.3.0

type SettingZoneEditResponseEnvelopeErrorsSource struct {
	Pointer string                                          `json:"pointer"`
	JSON    settingZoneEditResponseEnvelopeErrorsSourceJSON `json:"-"`
}

func (*SettingZoneEditResponseEnvelopeErrorsSource) UnmarshalJSON added in v4.3.0

func (r *SettingZoneEditResponseEnvelopeErrorsSource) UnmarshalJSON(data []byte) (err error)

type SettingZoneEditResponseEnvelopeMessages added in v4.3.0

type SettingZoneEditResponseEnvelopeMessages struct {
	Code             int64                                         `json:"code,required"`
	Message          string                                        `json:"message,required"`
	DocumentationURL string                                        `json:"documentation_url"`
	Source           SettingZoneEditResponseEnvelopeMessagesSource `json:"source"`
	JSON             settingZoneEditResponseEnvelopeMessagesJSON   `json:"-"`
}

func (*SettingZoneEditResponseEnvelopeMessages) UnmarshalJSON added in v4.3.0

func (r *SettingZoneEditResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type SettingZoneEditResponseEnvelopeMessagesSource added in v4.3.0

type SettingZoneEditResponseEnvelopeMessagesSource struct {
	Pointer string                                            `json:"pointer"`
	JSON    settingZoneEditResponseEnvelopeMessagesSourceJSON `json:"-"`
}

func (*SettingZoneEditResponseEnvelopeMessagesSource) UnmarshalJSON added in v4.3.0

func (r *SettingZoneEditResponseEnvelopeMessagesSource) UnmarshalJSON(data []byte) (err error)

type SettingZoneEditResponseEnvelopeSuccess added in v4.2.0

type SettingZoneEditResponseEnvelopeSuccess bool

Whether the API call was successful.

const (
	SettingZoneEditResponseEnvelopeSuccessTrue SettingZoneEditResponseEnvelopeSuccess = true
)

func (SettingZoneEditResponseEnvelopeSuccess) IsKnown added in v4.2.0

type SettingZoneEditResponseInternalDNS added in v4.2.0

type SettingZoneEditResponseInternalDNS struct {
	// The ID of the zone to fallback to.
	ReferenceZoneID string                                 `json:"reference_zone_id"`
	JSON            settingZoneEditResponseInternalDNSJSON `json:"-"`
}

Settings for this internal zone.

func (*SettingZoneEditResponseInternalDNS) UnmarshalJSON added in v4.2.0

func (r *SettingZoneEditResponseInternalDNS) UnmarshalJSON(data []byte) (err error)

type SettingZoneEditResponseNameservers added in v4.2.0

type SettingZoneEditResponseNameservers struct {
	// Nameserver type
	Type SettingZoneEditResponseNameserversType `json:"type,required"`
	// Configured nameserver set to be used for this zone
	NSSet int64                                  `json:"ns_set"`
	JSON  settingZoneEditResponseNameserversJSON `json:"-"`
}

Settings determining the nameservers through which the zone should be available.

func (*SettingZoneEditResponseNameservers) UnmarshalJSON added in v4.2.0

func (r *SettingZoneEditResponseNameservers) UnmarshalJSON(data []byte) (err error)

type SettingZoneEditResponseNameserversType added in v4.2.0

type SettingZoneEditResponseNameserversType string

Nameserver type

const (
	SettingZoneEditResponseNameserversTypeCloudflareStandard SettingZoneEditResponseNameserversType = "cloudflare.standard"
	SettingZoneEditResponseNameserversTypeCustomAccount      SettingZoneEditResponseNameserversType = "custom.account"
	SettingZoneEditResponseNameserversTypeCustomTenant       SettingZoneEditResponseNameserversType = "custom.tenant"
	SettingZoneEditResponseNameserversTypeCustomZone         SettingZoneEditResponseNameserversType = "custom.zone"
)

func (SettingZoneEditResponseNameserversType) IsKnown added in v4.2.0

type SettingZoneEditResponseSOA added in v4.2.0

type SettingZoneEditResponseSOA struct {
	// Time in seconds of being unable to query the primary server after which
	// secondary servers should stop serving the zone.
	Expire float64 `json:"expire,required"`
	// The time to live (TTL) for negative caching of records within the zone.
	MinTTL float64 `json:"min_ttl,required"`
	// The primary nameserver, which may be used for outbound zone transfers.
	MNAME string `json:"mname,required"`
	// Time in seconds after which secondary servers should re-check the SOA record to
	// see if the zone has been updated.
	Refresh float64 `json:"refresh,required"`
	// Time in seconds after which secondary servers should retry queries after the
	// primary server was unresponsive.
	Retry float64 `json:"retry,required"`
	// The email address of the zone administrator, with the first label representing
	// the local part of the email address.
	RNAME string `json:"rname,required"`
	// The time to live (TTL) of the SOA record itself.
	TTL  float64                        `json:"ttl,required"`
	JSON settingZoneEditResponseSOAJSON `json:"-"`
}

Components of the zone's SOA record.

func (*SettingZoneEditResponseSOA) UnmarshalJSON added in v4.2.0

func (r *SettingZoneEditResponseSOA) UnmarshalJSON(data []byte) (err error)

type SettingZoneEditResponseZoneMode added in v4.2.0

type SettingZoneEditResponseZoneMode string

Whether the zone mode is a regular or CDN/DNS only zone.

const (
	SettingZoneEditResponseZoneModeStandard SettingZoneEditResponseZoneMode = "standard"
	SettingZoneEditResponseZoneModeCDNOnly  SettingZoneEditResponseZoneMode = "cdn_only"
	SettingZoneEditResponseZoneModeDNSOnly  SettingZoneEditResponseZoneMode = "dns_only"
)

func (SettingZoneEditResponseZoneMode) IsKnown added in v4.2.0

type SettingZoneGetParams added in v4.2.0

type SettingZoneGetParams struct {
	// Identifier.
	ZoneID param.Field[string] `path:"zone_id,required"`
}

type SettingZoneGetResponse added in v4.2.0

type SettingZoneGetResponse struct {
	// Whether to flatten all CNAME records in the zone. Note that, due to DNS
	// limitations, a CNAME record at the zone apex will always be flattened.
	FlattenAllCNAMEs bool `json:"flatten_all_cnames"`
	// Whether to enable Foundation DNS Advanced Nameservers on the zone.
	FoundationDNS bool `json:"foundation_dns"`
	// Settings for this internal zone.
	InternalDNS SettingZoneGetResponseInternalDNS `json:"internal_dns"`
	// Whether to enable multi-provider DNS, which causes Cloudflare to activate the
	// zone even when non-Cloudflare NS records exist, and to respect NS records at the
	// zone apex during outbound zone transfers.
	MultiProvider bool `json:"multi_provider"`
	// Settings determining the nameservers through which the zone should be available.
	Nameservers SettingZoneGetResponseNameservers `json:"nameservers"`
	// The time to live (TTL) of the zone's nameserver (NS) records.
	NSTTL float64 `json:"ns_ttl"`
	// Allows a Secondary DNS zone to use (proxied) override records and CNAME
	// flattening at the zone apex.
	SecondaryOverrides bool `json:"secondary_overrides"`
	// Components of the zone's SOA record.
	SOA SettingZoneGetResponseSOA `json:"soa"`
	// Whether the zone mode is a regular or CDN/DNS only zone.
	ZoneMode SettingZoneGetResponseZoneMode `json:"zone_mode"`
	JSON     settingZoneGetResponseJSON     `json:"-"`
}

func (*SettingZoneGetResponse) UnmarshalJSON added in v4.2.0

func (r *SettingZoneGetResponse) UnmarshalJSON(data []byte) (err error)

type SettingZoneGetResponseEnvelope added in v4.2.0

type SettingZoneGetResponseEnvelope struct {
	Errors   []SettingZoneGetResponseEnvelopeErrors   `json:"errors,required"`
	Messages []SettingZoneGetResponseEnvelopeMessages `json:"messages,required"`
	// Whether the API call was successful.
	Success SettingZoneGetResponseEnvelopeSuccess `json:"success,required"`
	Result  SettingZoneGetResponse                `json:"result"`
	JSON    settingZoneGetResponseEnvelopeJSON    `json:"-"`
}

func (*SettingZoneGetResponseEnvelope) UnmarshalJSON added in v4.2.0

func (r *SettingZoneGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type SettingZoneGetResponseEnvelopeErrors added in v4.3.0

type SettingZoneGetResponseEnvelopeErrors struct {
	Code             int64                                      `json:"code,required"`
	Message          string                                     `json:"message,required"`
	DocumentationURL string                                     `json:"documentation_url"`
	Source           SettingZoneGetResponseEnvelopeErrorsSource `json:"source"`
	JSON             settingZoneGetResponseEnvelopeErrorsJSON   `json:"-"`
}

func (*SettingZoneGetResponseEnvelopeErrors) UnmarshalJSON added in v4.3.0

func (r *SettingZoneGetResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type SettingZoneGetResponseEnvelopeErrorsSource added in v4.3.0

type SettingZoneGetResponseEnvelopeErrorsSource struct {
	Pointer string                                         `json:"pointer"`
	JSON    settingZoneGetResponseEnvelopeErrorsSourceJSON `json:"-"`
}

func (*SettingZoneGetResponseEnvelopeErrorsSource) UnmarshalJSON added in v4.3.0

func (r *SettingZoneGetResponseEnvelopeErrorsSource) UnmarshalJSON(data []byte) (err error)

type SettingZoneGetResponseEnvelopeMessages added in v4.3.0

type SettingZoneGetResponseEnvelopeMessages struct {
	Code             int64                                        `json:"code,required"`
	Message          string                                       `json:"message,required"`
	DocumentationURL string                                       `json:"documentation_url"`
	Source           SettingZoneGetResponseEnvelopeMessagesSource `json:"source"`
	JSON             settingZoneGetResponseEnvelopeMessagesJSON   `json:"-"`
}

func (*SettingZoneGetResponseEnvelopeMessages) UnmarshalJSON added in v4.3.0

func (r *SettingZoneGetResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type SettingZoneGetResponseEnvelopeMessagesSource added in v4.3.0

type SettingZoneGetResponseEnvelopeMessagesSource struct {
	Pointer string                                           `json:"pointer"`
	JSON    settingZoneGetResponseEnvelopeMessagesSourceJSON `json:"-"`
}

func (*SettingZoneGetResponseEnvelopeMessagesSource) UnmarshalJSON added in v4.3.0

func (r *SettingZoneGetResponseEnvelopeMessagesSource) UnmarshalJSON(data []byte) (err error)

type SettingZoneGetResponseEnvelopeSuccess added in v4.2.0

type SettingZoneGetResponseEnvelopeSuccess bool

Whether the API call was successful.

const (
	SettingZoneGetResponseEnvelopeSuccessTrue SettingZoneGetResponseEnvelopeSuccess = true
)

func (SettingZoneGetResponseEnvelopeSuccess) IsKnown added in v4.2.0

type SettingZoneGetResponseInternalDNS added in v4.2.0

type SettingZoneGetResponseInternalDNS struct {
	// The ID of the zone to fallback to.
	ReferenceZoneID string                                `json:"reference_zone_id"`
	JSON            settingZoneGetResponseInternalDNSJSON `json:"-"`
}

Settings for this internal zone.

func (*SettingZoneGetResponseInternalDNS) UnmarshalJSON added in v4.2.0

func (r *SettingZoneGetResponseInternalDNS) UnmarshalJSON(data []byte) (err error)

type SettingZoneGetResponseNameservers added in v4.2.0

type SettingZoneGetResponseNameservers struct {
	// Nameserver type
	Type SettingZoneGetResponseNameserversType `json:"type,required"`
	// Configured nameserver set to be used for this zone
	NSSet int64                                 `json:"ns_set"`
	JSON  settingZoneGetResponseNameserversJSON `json:"-"`
}

Settings determining the nameservers through which the zone should be available.

func (*SettingZoneGetResponseNameservers) UnmarshalJSON added in v4.2.0

func (r *SettingZoneGetResponseNameservers) UnmarshalJSON(data []byte) (err error)

type SettingZoneGetResponseNameserversType added in v4.2.0

type SettingZoneGetResponseNameserversType string

Nameserver type

const (
	SettingZoneGetResponseNameserversTypeCloudflareStandard SettingZoneGetResponseNameserversType = "cloudflare.standard"
	SettingZoneGetResponseNameserversTypeCustomAccount      SettingZoneGetResponseNameserversType = "custom.account"
	SettingZoneGetResponseNameserversTypeCustomTenant       SettingZoneGetResponseNameserversType = "custom.tenant"
	SettingZoneGetResponseNameserversTypeCustomZone         SettingZoneGetResponseNameserversType = "custom.zone"
)

func (SettingZoneGetResponseNameserversType) IsKnown added in v4.2.0

type SettingZoneGetResponseSOA added in v4.2.0

type SettingZoneGetResponseSOA struct {
	// Time in seconds of being unable to query the primary server after which
	// secondary servers should stop serving the zone.
	Expire float64 `json:"expire,required"`
	// The time to live (TTL) for negative caching of records within the zone.
	MinTTL float64 `json:"min_ttl,required"`
	// The primary nameserver, which may be used for outbound zone transfers.
	MNAME string `json:"mname,required"`
	// Time in seconds after which secondary servers should re-check the SOA record to
	// see if the zone has been updated.
	Refresh float64 `json:"refresh,required"`
	// Time in seconds after which secondary servers should retry queries after the
	// primary server was unresponsive.
	Retry float64 `json:"retry,required"`
	// The email address of the zone administrator, with the first label representing
	// the local part of the email address.
	RNAME string `json:"rname,required"`
	// The time to live (TTL) of the SOA record itself.
	TTL  float64                       `json:"ttl,required"`
	JSON settingZoneGetResponseSOAJSON `json:"-"`
}

Components of the zone's SOA record.

func (*SettingZoneGetResponseSOA) UnmarshalJSON added in v4.2.0

func (r *SettingZoneGetResponseSOA) UnmarshalJSON(data []byte) (err error)

type SettingZoneGetResponseZoneMode added in v4.2.0

type SettingZoneGetResponseZoneMode string

Whether the zone mode is a regular or CDN/DNS only zone.

const (
	SettingZoneGetResponseZoneModeStandard SettingZoneGetResponseZoneMode = "standard"
	SettingZoneGetResponseZoneModeCDNOnly  SettingZoneGetResponseZoneMode = "cdn_only"
	SettingZoneGetResponseZoneModeDNSOnly  SettingZoneGetResponseZoneMode = "dns_only"
)

func (SettingZoneGetResponseZoneMode) IsKnown added in v4.2.0

type SettingZoneService added in v4.2.0

type SettingZoneService struct {
	Options []option.RequestOption
}

SettingZoneService contains methods and other services that help with interacting with the cloudflare API.

Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewSettingZoneService method instead.

func NewSettingZoneService added in v4.2.0

func NewSettingZoneService(opts ...option.RequestOption) (r *SettingZoneService)

NewSettingZoneService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*SettingZoneService) Edit added in v4.2.0

Update DNS settings for a zone

func (*SettingZoneService) Get added in v4.2.0

Show DNS settings for a zone

type SortDirection

type SortDirection = shared.SortDirection

Direction to order DNS records in.

This is an alias to an internal type.

type Subscription

type Subscription = shared.Subscription

This is an alias to an internal type.

type SubscriptionFrequency

type SubscriptionFrequency = shared.SubscriptionFrequency

How often the subscription is renewed automatically.

This is an alias to an internal type.

type SubscriptionParam

type SubscriptionParam = shared.SubscriptionParam

This is an alias to an internal type.

type SubscriptionState

type SubscriptionState = shared.SubscriptionState

The state that the subscription is in.

This is an alias to an internal type.

type TLSARecord

type TLSARecord struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment string `json:"comment"`
	// Formatted TLSA content. See 'data' to set TLSA properties.
	Content string `json:"content"`
	// Components of a TLSA record.
	Data TLSARecordData `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name string `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied bool `json:"proxied"`
	// Settings for the DNS record.
	Settings TLSARecordSettings `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags []RecordTags `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL TTL `json:"ttl"`
	// Record type.
	Type TLSARecordType `json:"type"`
	JSON tlsaRecordJSON `json:"-"`
}

func (*TLSARecord) UnmarshalJSON

func (r *TLSARecord) UnmarshalJSON(data []byte) (err error)

type TLSARecordData

type TLSARecordData struct {
	// certificate.
	Certificate string `json:"certificate"`
	// Matching Type.
	MatchingType float64 `json:"matching_type"`
	// Selector.
	Selector float64 `json:"selector"`
	// Usage.
	Usage float64            `json:"usage"`
	JSON  tlsaRecordDataJSON `json:"-"`
}

Components of a TLSA record.

func (*TLSARecordData) UnmarshalJSON

func (r *TLSARecordData) UnmarshalJSON(data []byte) (err error)

type TLSARecordDataParam

type TLSARecordDataParam struct {
	// certificate.
	Certificate param.Field[string] `json:"certificate"`
	// Matching Type.
	MatchingType param.Field[float64] `json:"matching_type"`
	// Selector.
	Selector param.Field[float64] `json:"selector"`
	// Usage.
	Usage param.Field[float64] `json:"usage"`
}

Components of a TLSA record.

func (TLSARecordDataParam) MarshalJSON

func (r TLSARecordDataParam) MarshalJSON() (data []byte, err error)

type TLSARecordParam

type TLSARecordParam struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// Components of a TLSA record.
	Data param.Field[TLSARecordDataParam] `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `json:"proxied"`
	// Settings for the DNS record.
	Settings param.Field[TLSARecordSettingsParam] `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags param.Field[[]RecordTagsParam] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
	// Record type.
	Type param.Field[TLSARecordType] `json:"type"`
}

func (TLSARecordParam) MarshalJSON

func (r TLSARecordParam) MarshalJSON() (data []byte, err error)

type TLSARecordSettings

type TLSARecordSettings struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only bool `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only bool                   `json:"ipv6_only"`
	JSON     tlsaRecordSettingsJSON `json:"-"`
}

Settings for the DNS record.

func (*TLSARecordSettings) UnmarshalJSON

func (r *TLSARecordSettings) UnmarshalJSON(data []byte) (err error)

type TLSARecordSettingsParam

type TLSARecordSettingsParam struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only param.Field[bool] `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only param.Field[bool] `json:"ipv6_only"`
}

Settings for the DNS record.

func (TLSARecordSettingsParam) MarshalJSON

func (r TLSARecordSettingsParam) MarshalJSON() (data []byte, err error)

type TLSARecordType

type TLSARecordType string

Record type.

const (
	TLSARecordTypeTLSA TLSARecordType = "TLSA"
)

func (TLSARecordType) IsKnown

func (r TLSARecordType) IsKnown() bool

type TSIG

type TSIG struct {
	ID string `json:"id,required"`
	// TSIG algorithm.
	Algo string `json:"algo,required"`
	// TSIG key name.
	Name string `json:"name,required"`
	// TSIG secret.
	Secret string   `json:"secret,required"`
	JSON   tsigJSON `json:"-"`
}

func (*TSIG) UnmarshalJSON

func (r *TSIG) UnmarshalJSON(data []byte) (err error)

type TSIGParam

type TSIGParam struct {
	// TSIG algorithm.
	Algo param.Field[string] `json:"algo,required"`
	// TSIG key name.
	Name param.Field[string] `json:"name,required"`
	// TSIG secret.
	Secret param.Field[string] `json:"secret,required"`
}

func (TSIGParam) MarshalJSON

func (r TSIGParam) MarshalJSON() (data []byte, err error)

type TTL

type TTL float64

Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'. Value must be between 60 and 86400, with the minimum reduced to 30 for Enterprise zones.

const (
	TTL1 TTL = 1
)

func (TTL) IsKnown

func (r TTL) IsKnown() bool

type TXTRecord

type TXTRecord struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment string `json:"comment"`
	// Text content for the record. The content must consist of quoted "character
	// strings" (RFC 1035), each with a length of up to 255 bytes. Strings exceeding
	// this allowed maximum length are automatically split.
	//
	// Learn more at
	// <https://www.cloudflare.com/learning/dns/dns-records/dns-txt-record/>.
	Content string `json:"content"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name string `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied bool `json:"proxied"`
	// Settings for the DNS record.
	Settings TXTRecordSettings `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags []RecordTags `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL TTL `json:"ttl"`
	// Record type.
	Type TXTRecordType `json:"type"`
	JSON txtRecordJSON `json:"-"`
}

func (*TXTRecord) UnmarshalJSON

func (r *TXTRecord) UnmarshalJSON(data []byte) (err error)

type TXTRecordParam

type TXTRecordParam struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// Text content for the record. The content must consist of quoted "character
	// strings" (RFC 1035), each with a length of up to 255 bytes. Strings exceeding
	// this allowed maximum length are automatically split.
	//
	// Learn more at
	// <https://www.cloudflare.com/learning/dns/dns-records/dns-txt-record/>.
	Content param.Field[string] `json:"content"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `json:"proxied"`
	// Settings for the DNS record.
	Settings param.Field[TXTRecordSettingsParam] `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags param.Field[[]RecordTagsParam] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
	// Record type.
	Type param.Field[TXTRecordType] `json:"type"`
}

func (TXTRecordParam) MarshalJSON

func (r TXTRecordParam) MarshalJSON() (data []byte, err error)

type TXTRecordSettings

type TXTRecordSettings struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only bool `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only bool                  `json:"ipv6_only"`
	JSON     txtRecordSettingsJSON `json:"-"`
}

Settings for the DNS record.

func (*TXTRecordSettings) UnmarshalJSON

func (r *TXTRecordSettings) UnmarshalJSON(data []byte) (err error)

type TXTRecordSettingsParam

type TXTRecordSettingsParam struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only param.Field[bool] `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only param.Field[bool] `json:"ipv6_only"`
}

Settings for the DNS record.

func (TXTRecordSettingsParam) MarshalJSON

func (r TXTRecordSettingsParam) MarshalJSON() (data []byte, err error)

type TXTRecordType

type TXTRecordType string

Record type.

const (
	TXTRecordTypeTXT TXTRecordType = "TXT"
)

func (TXTRecordType) IsKnown

func (r TXTRecordType) IsKnown() bool

type Token

type Token = shared.Token

This is an alias to an internal type.

type TokenCondition

type TokenCondition = shared.TokenCondition

This is an alias to an internal type.

type TokenConditionCIDRList

type TokenConditionCIDRList = shared.TokenConditionCIDRList

IPv4/IPv6 CIDR.

This is an alias to an internal type.

type TokenConditionCIDRListParam

type TokenConditionCIDRListParam = shared.TokenConditionCIDRListParam

IPv4/IPv6 CIDR.

This is an alias to an internal type.

type TokenConditionParam

type TokenConditionParam = shared.TokenConditionParam

This is an alias to an internal type.

type TokenConditionRequestIP

type TokenConditionRequestIP = shared.TokenConditionRequestIP

Client IP restrictions.

This is an alias to an internal type.

type TokenConditionRequestIPParam

type TokenConditionRequestIPParam = shared.TokenConditionRequestIPParam

Client IP restrictions.

This is an alias to an internal type.

type TokenParam

type TokenParam = shared.TokenParam

This is an alias to an internal type.

type TokenPolicy

type TokenPolicy = shared.TokenPolicy

This is an alias to an internal type.

type TokenPolicyEffect

type TokenPolicyEffect = shared.TokenPolicyEffect

Allow or deny operations against the resources.

This is an alias to an internal type.

type TokenPolicyParam

type TokenPolicyParam = shared.TokenPolicyParam

This is an alias to an internal type.

type TokenPolicyPermissionGroup

type TokenPolicyPermissionGroup = shared.TokenPolicyPermissionGroup

A named group of permissions that map to a group of operations against resources.

This is an alias to an internal type.

type TokenPolicyPermissionGroupParam

type TokenPolicyPermissionGroupParam = shared.TokenPolicyPermissionGroupParam

A named group of permissions that map to a group of operations against resources.

This is an alias to an internal type.

type TokenPolicyPermissionGroupsMeta

type TokenPolicyPermissionGroupsMeta = shared.TokenPolicyPermissionGroupsMeta

Attributes associated to the permission group.

This is an alias to an internal type.

type TokenPolicyPermissionGroupsMetaParam

type TokenPolicyPermissionGroupsMetaParam = shared.TokenPolicyPermissionGroupsMetaParam

Attributes associated to the permission group.

This is an alias to an internal type.

type TokenStatus

type TokenStatus = shared.TokenStatus

Status of the token.

This is an alias to an internal type.

type TokenValue

type TokenValue = shared.TokenValue

The token value.

This is an alias to an internal type.

type URIRecord

type URIRecord struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment string `json:"comment"`
	// Formatted URI content. See 'data' to set URI properties.
	Content string `json:"content"`
	// Components of a URI record.
	Data URIRecordData `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name string `json:"name"`
	// Required for MX, SRV and URI records; unused by other record types. Records with
	// lower priorities are preferred.
	Priority float64 `json:"priority"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied bool `json:"proxied"`
	// Settings for the DNS record.
	Settings URIRecordSettings `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags []RecordTags `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL TTL `json:"ttl"`
	// Record type.
	Type URIRecordType `json:"type"`
	JSON uriRecordJSON `json:"-"`
}

func (*URIRecord) UnmarshalJSON

func (r *URIRecord) UnmarshalJSON(data []byte) (err error)

type URIRecordData

type URIRecordData struct {
	// The record content.
	Target string `json:"target"`
	// The record weight.
	Weight float64           `json:"weight"`
	JSON   uriRecordDataJSON `json:"-"`
}

Components of a URI record.

func (*URIRecordData) UnmarshalJSON

func (r *URIRecordData) UnmarshalJSON(data []byte) (err error)

type URIRecordDataParam

type URIRecordDataParam struct {
	// The record content.
	Target param.Field[string] `json:"target"`
	// The record weight.
	Weight param.Field[float64] `json:"weight"`
}

Components of a URI record.

func (URIRecordDataParam) MarshalJSON

func (r URIRecordDataParam) MarshalJSON() (data []byte, err error)

type URIRecordParam

type URIRecordParam struct {
	// Comments or notes about the DNS record. This field has no effect on DNS
	// responses.
	Comment param.Field[string] `json:"comment"`
	// Components of a URI record.
	Data param.Field[URIRecordDataParam] `json:"data"`
	// DNS record name (or @ for the zone apex) in Punycode.
	Name param.Field[string] `json:"name"`
	// Required for MX, SRV and URI records; unused by other record types. Records with
	// lower priorities are preferred.
	Priority param.Field[float64] `json:"priority"`
	// Whether the record is receiving the performance and security benefits of
	// Cloudflare.
	Proxied param.Field[bool] `json:"proxied"`
	// Settings for the DNS record.
	Settings param.Field[URIRecordSettingsParam] `json:"settings"`
	// Custom tags for the DNS record. This field has no effect on DNS responses.
	Tags param.Field[[]RecordTagsParam] `json:"tags"`
	// Time To Live (TTL) of the DNS record in seconds. Setting to 1 means 'automatic'.
	// Value must be between 60 and 86400, with the minimum reduced to 30 for
	// Enterprise zones.
	TTL param.Field[TTL] `json:"ttl"`
	// Record type.
	Type param.Field[URIRecordType] `json:"type"`
}

func (URIRecordParam) MarshalJSON

func (r URIRecordParam) MarshalJSON() (data []byte, err error)

type URIRecordSettings

type URIRecordSettings struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only bool `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only bool                  `json:"ipv6_only"`
	JSON     uriRecordSettingsJSON `json:"-"`
}

Settings for the DNS record.

func (*URIRecordSettings) UnmarshalJSON

func (r *URIRecordSettings) UnmarshalJSON(data []byte) (err error)

type URIRecordSettingsParam

type URIRecordSettingsParam struct {
	// When enabled, only A records will be generated, and AAAA records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV4Only param.Field[bool] `json:"ipv4_only"`
	// When enabled, only AAAA records will be generated, and A records will not be
	// created. This setting is intended for exceptional cases. Note that this option
	// only applies to proxied records and it has no effect on whether Cloudflare
	// communicates with the origin using IPv4 or IPv6.
	IPV6Only param.Field[bool] `json:"ipv6_only"`
}

Settings for the DNS record.

func (URIRecordSettingsParam) MarshalJSON

func (r URIRecordSettingsParam) MarshalJSON() (data []byte, err error)

type URIRecordType

type URIRecordType string

Record type.

const (
	URIRecordTypeURI URIRecordType = "URI"
)

func (URIRecordType) IsKnown

func (r URIRecordType) IsKnown() bool

type ZoneTransferACLDeleteParams

type ZoneTransferACLDeleteParams struct {
	AccountID param.Field[string] `path:"account_id,required"`
}

type ZoneTransferACLDeleteResponse

type ZoneTransferACLDeleteResponse struct {
	ID   string                            `json:"id"`
	JSON zoneTransferACLDeleteResponseJSON `json:"-"`
}

func (*ZoneTransferACLDeleteResponse) UnmarshalJSON

func (r *ZoneTransferACLDeleteResponse) UnmarshalJSON(data []byte) (err error)

type ZoneTransferACLDeleteResponseEnvelope

type ZoneTransferACLDeleteResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferACLDeleteResponseEnvelopeSuccess `json:"success,required"`
	Result  ZoneTransferACLDeleteResponse                `json:"result"`
	JSON    zoneTransferACLDeleteResponseEnvelopeJSON    `json:"-"`
}

func (*ZoneTransferACLDeleteResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferACLDeleteResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferACLDeleteResponseEnvelopeSuccess

type ZoneTransferACLDeleteResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferACLDeleteResponseEnvelopeSuccessTrue ZoneTransferACLDeleteResponseEnvelopeSuccess = true
)

func (ZoneTransferACLDeleteResponseEnvelopeSuccess) IsKnown

type ZoneTransferACLGetParams

type ZoneTransferACLGetParams struct {
	AccountID param.Field[string] `path:"account_id,required"`
}

type ZoneTransferACLGetResponseEnvelope

type ZoneTransferACLGetResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferACLGetResponseEnvelopeSuccess `json:"success,required"`
	Result  ACL                                       `json:"result"`
	JSON    zoneTransferACLGetResponseEnvelopeJSON    `json:"-"`
}

func (*ZoneTransferACLGetResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferACLGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferACLGetResponseEnvelopeSuccess

type ZoneTransferACLGetResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferACLGetResponseEnvelopeSuccessTrue ZoneTransferACLGetResponseEnvelopeSuccess = true
)

func (ZoneTransferACLGetResponseEnvelopeSuccess) IsKnown

type ZoneTransferACLListParams

type ZoneTransferACLListParams struct {
	AccountID param.Field[string] `path:"account_id,required"`
}

type ZoneTransferACLNewParams

type ZoneTransferACLNewParams struct {
	AccountID param.Field[string] `path:"account_id,required"`
	// Allowed IPv4/IPv6 address range of primary or secondary nameservers. This will
	// be applied for the entire account. The IP range is used to allow additional
	// NOTIFY IPs for secondary zones and IPs Cloudflare allows AXFR/IXFR requests from
	// for primary zones. CIDRs are limited to a maximum of /24 for IPv4 and /64 for
	// IPv6 respectively.
	IPRange param.Field[string] `json:"ip_range,required"`
	// The name of the acl.
	Name param.Field[string] `json:"name,required"`
}

func (ZoneTransferACLNewParams) MarshalJSON

func (r ZoneTransferACLNewParams) MarshalJSON() (data []byte, err error)

type ZoneTransferACLNewResponseEnvelope

type ZoneTransferACLNewResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferACLNewResponseEnvelopeSuccess `json:"success,required"`
	Result  ACL                                       `json:"result"`
	JSON    zoneTransferACLNewResponseEnvelopeJSON    `json:"-"`
}

func (*ZoneTransferACLNewResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferACLNewResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferACLNewResponseEnvelopeSuccess

type ZoneTransferACLNewResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferACLNewResponseEnvelopeSuccessTrue ZoneTransferACLNewResponseEnvelopeSuccess = true
)

func (ZoneTransferACLNewResponseEnvelopeSuccess) IsKnown

type ZoneTransferACLService

type ZoneTransferACLService struct {
	Options []option.RequestOption
}

ZoneTransferACLService contains methods and other services that help with interacting with the cloudflare API.

Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewZoneTransferACLService method instead.

func NewZoneTransferACLService

func NewZoneTransferACLService(opts ...option.RequestOption) (r *ZoneTransferACLService)

NewZoneTransferACLService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*ZoneTransferACLService) Delete

Delete ACL.

func (*ZoneTransferACLService) Get

func (r *ZoneTransferACLService) Get(ctx context.Context, aclID string, query ZoneTransferACLGetParams, opts ...option.RequestOption) (res *ACL, err error)

Get ACL.

func (*ZoneTransferACLService) List

List ACLs.

func (*ZoneTransferACLService) ListAutoPaging

List ACLs.

func (*ZoneTransferACLService) New

Create ACL.

func (*ZoneTransferACLService) Update

func (r *ZoneTransferACLService) Update(ctx context.Context, aclID string, params ZoneTransferACLUpdateParams, opts ...option.RequestOption) (res *ACL, err error)

Modify ACL.

type ZoneTransferACLUpdateParams

type ZoneTransferACLUpdateParams struct {
	AccountID param.Field[string] `path:"account_id,required"`
	ACL       ACLParam            `json:"acl,required"`
}

func (ZoneTransferACLUpdateParams) MarshalJSON

func (r ZoneTransferACLUpdateParams) MarshalJSON() (data []byte, err error)

type ZoneTransferACLUpdateResponseEnvelope

type ZoneTransferACLUpdateResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferACLUpdateResponseEnvelopeSuccess `json:"success,required"`
	Result  ACL                                          `json:"result"`
	JSON    zoneTransferACLUpdateResponseEnvelopeJSON    `json:"-"`
}

func (*ZoneTransferACLUpdateResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferACLUpdateResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferACLUpdateResponseEnvelopeSuccess

type ZoneTransferACLUpdateResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferACLUpdateResponseEnvelopeSuccessTrue ZoneTransferACLUpdateResponseEnvelopeSuccess = true
)

func (ZoneTransferACLUpdateResponseEnvelopeSuccess) IsKnown

type ZoneTransferForceAXFRNewParams

type ZoneTransferForceAXFRNewParams struct {
	ZoneID param.Field[string] `path:"zone_id,required"`
	Body   interface{}         `json:"body,required"`
}

func (ZoneTransferForceAXFRNewParams) MarshalJSON

func (r ZoneTransferForceAXFRNewParams) MarshalJSON() (data []byte, err error)

type ZoneTransferForceAXFRNewResponseEnvelope

type ZoneTransferForceAXFRNewResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferForceAXFRNewResponseEnvelopeSuccess `json:"success,required"`
	// When force_axfr query parameter is set to true, the response is a simple string
	Result ForceAXFR                                    `json:"result"`
	JSON   zoneTransferForceAXFRNewResponseEnvelopeJSON `json:"-"`
}

func (*ZoneTransferForceAXFRNewResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferForceAXFRNewResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferForceAXFRNewResponseEnvelopeSuccess

type ZoneTransferForceAXFRNewResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferForceAXFRNewResponseEnvelopeSuccessTrue ZoneTransferForceAXFRNewResponseEnvelopeSuccess = true
)

func (ZoneTransferForceAXFRNewResponseEnvelopeSuccess) IsKnown

type ZoneTransferForceAXFRService

type ZoneTransferForceAXFRService struct {
	Options []option.RequestOption
}

ZoneTransferForceAXFRService contains methods and other services that help with interacting with the cloudflare API.

Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewZoneTransferForceAXFRService method instead.

func NewZoneTransferForceAXFRService

func NewZoneTransferForceAXFRService(opts ...option.RequestOption) (r *ZoneTransferForceAXFRService)

NewZoneTransferForceAXFRService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*ZoneTransferForceAXFRService) New

Sends AXFR zone transfer request to primary nameserver(s).

type ZoneTransferIncomingDeleteParams

type ZoneTransferIncomingDeleteParams struct {
	ZoneID param.Field[string] `path:"zone_id,required"`
}

type ZoneTransferIncomingDeleteResponse

type ZoneTransferIncomingDeleteResponse struct {
	ID   string                                 `json:"id"`
	JSON zoneTransferIncomingDeleteResponseJSON `json:"-"`
}

func (*ZoneTransferIncomingDeleteResponse) UnmarshalJSON

func (r *ZoneTransferIncomingDeleteResponse) UnmarshalJSON(data []byte) (err error)

type ZoneTransferIncomingDeleteResponseEnvelope

type ZoneTransferIncomingDeleteResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferIncomingDeleteResponseEnvelopeSuccess `json:"success,required"`
	Result  ZoneTransferIncomingDeleteResponse                `json:"result"`
	JSON    zoneTransferIncomingDeleteResponseEnvelopeJSON    `json:"-"`
}

func (*ZoneTransferIncomingDeleteResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferIncomingDeleteResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferIncomingDeleteResponseEnvelopeSuccess

type ZoneTransferIncomingDeleteResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferIncomingDeleteResponseEnvelopeSuccessTrue ZoneTransferIncomingDeleteResponseEnvelopeSuccess = true
)

func (ZoneTransferIncomingDeleteResponseEnvelopeSuccess) IsKnown

type ZoneTransferIncomingGetParams

type ZoneTransferIncomingGetParams struct {
	ZoneID param.Field[string] `path:"zone_id,required"`
}

type ZoneTransferIncomingGetResponse

type ZoneTransferIncomingGetResponse struct {
	ID string `json:"id"`
	// How often should a secondary zone auto refresh regardless of DNS NOTIFY. Not
	// applicable for primary zones.
	AutoRefreshSeconds float64 `json:"auto_refresh_seconds"`
	// The time for a specific event.
	CheckedTime string `json:"checked_time"`
	// The time for a specific event.
	CreatedTime string `json:"created_time"`
	// The time for a specific event.
	ModifiedTime string `json:"modified_time"`
	// Zone name.
	Name string `json:"name"`
	// A list of peer tags.
	Peers []string `json:"peers"`
	// The serial number of the SOA for the given zone.
	SOASerial float64                             `json:"soa_serial"`
	JSON      zoneTransferIncomingGetResponseJSON `json:"-"`
}

func (*ZoneTransferIncomingGetResponse) UnmarshalJSON

func (r *ZoneTransferIncomingGetResponse) UnmarshalJSON(data []byte) (err error)

type ZoneTransferIncomingGetResponseEnvelope

type ZoneTransferIncomingGetResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferIncomingGetResponseEnvelopeSuccess `json:"success,required"`
	Result  ZoneTransferIncomingGetResponse                `json:"result"`
	JSON    zoneTransferIncomingGetResponseEnvelopeJSON    `json:"-"`
}

func (*ZoneTransferIncomingGetResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferIncomingGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferIncomingGetResponseEnvelopeSuccess

type ZoneTransferIncomingGetResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferIncomingGetResponseEnvelopeSuccessTrue ZoneTransferIncomingGetResponseEnvelopeSuccess = true
)

func (ZoneTransferIncomingGetResponseEnvelopeSuccess) IsKnown

type ZoneTransferIncomingNewParams

type ZoneTransferIncomingNewParams struct {
	ZoneID param.Field[string] `path:"zone_id,required"`
	// How often should a secondary zone auto refresh regardless of DNS NOTIFY. Not
	// applicable for primary zones.
	AutoRefreshSeconds param.Field[float64] `json:"auto_refresh_seconds,required"`
	// Zone name.
	Name param.Field[string] `json:"name,required"`
	// A list of peer tags.
	Peers param.Field[[]string] `json:"peers,required"`
}

func (ZoneTransferIncomingNewParams) MarshalJSON

func (r ZoneTransferIncomingNewParams) MarshalJSON() (data []byte, err error)

type ZoneTransferIncomingNewResponse

type ZoneTransferIncomingNewResponse struct {
	ID string `json:"id"`
	// How often should a secondary zone auto refresh regardless of DNS NOTIFY. Not
	// applicable for primary zones.
	AutoRefreshSeconds float64 `json:"auto_refresh_seconds"`
	// The time for a specific event.
	CheckedTime string `json:"checked_time"`
	// The time for a specific event.
	CreatedTime string `json:"created_time"`
	// The time for a specific event.
	ModifiedTime string `json:"modified_time"`
	// Zone name.
	Name string `json:"name"`
	// A list of peer tags.
	Peers []string `json:"peers"`
	// The serial number of the SOA for the given zone.
	SOASerial float64                             `json:"soa_serial"`
	JSON      zoneTransferIncomingNewResponseJSON `json:"-"`
}

func (*ZoneTransferIncomingNewResponse) UnmarshalJSON

func (r *ZoneTransferIncomingNewResponse) UnmarshalJSON(data []byte) (err error)

type ZoneTransferIncomingNewResponseEnvelope

type ZoneTransferIncomingNewResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferIncomingNewResponseEnvelopeSuccess `json:"success,required"`
	Result  ZoneTransferIncomingNewResponse                `json:"result"`
	JSON    zoneTransferIncomingNewResponseEnvelopeJSON    `json:"-"`
}

func (*ZoneTransferIncomingNewResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferIncomingNewResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferIncomingNewResponseEnvelopeSuccess

type ZoneTransferIncomingNewResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferIncomingNewResponseEnvelopeSuccessTrue ZoneTransferIncomingNewResponseEnvelopeSuccess = true
)

func (ZoneTransferIncomingNewResponseEnvelopeSuccess) IsKnown

type ZoneTransferIncomingService

type ZoneTransferIncomingService struct {
	Options []option.RequestOption
}

ZoneTransferIncomingService contains methods and other services that help with interacting with the cloudflare API.

Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewZoneTransferIncomingService method instead.

func NewZoneTransferIncomingService

func NewZoneTransferIncomingService(opts ...option.RequestOption) (r *ZoneTransferIncomingService)

NewZoneTransferIncomingService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*ZoneTransferIncomingService) Delete

Delete secondary zone configuration for incoming zone transfers.

func (*ZoneTransferIncomingService) Get

Get secondary zone configuration for incoming zone transfers.

func (*ZoneTransferIncomingService) New

Create secondary zone configuration for incoming zone transfers.

func (*ZoneTransferIncomingService) Update

Update secondary zone configuration for incoming zone transfers.

type ZoneTransferIncomingUpdateParams

type ZoneTransferIncomingUpdateParams struct {
	ZoneID param.Field[string] `path:"zone_id,required"`
	// How often should a secondary zone auto refresh regardless of DNS NOTIFY. Not
	// applicable for primary zones.
	AutoRefreshSeconds param.Field[float64] `json:"auto_refresh_seconds,required"`
	// Zone name.
	Name param.Field[string] `json:"name,required"`
	// A list of peer tags.
	Peers param.Field[[]string] `json:"peers,required"`
}

func (ZoneTransferIncomingUpdateParams) MarshalJSON

func (r ZoneTransferIncomingUpdateParams) MarshalJSON() (data []byte, err error)

type ZoneTransferIncomingUpdateResponse

type ZoneTransferIncomingUpdateResponse struct {
	ID string `json:"id"`
	// How often should a secondary zone auto refresh regardless of DNS NOTIFY. Not
	// applicable for primary zones.
	AutoRefreshSeconds float64 `json:"auto_refresh_seconds"`
	// The time for a specific event.
	CheckedTime string `json:"checked_time"`
	// The time for a specific event.
	CreatedTime string `json:"created_time"`
	// The time for a specific event.
	ModifiedTime string `json:"modified_time"`
	// Zone name.
	Name string `json:"name"`
	// A list of peer tags.
	Peers []string `json:"peers"`
	// The serial number of the SOA for the given zone.
	SOASerial float64                                `json:"soa_serial"`
	JSON      zoneTransferIncomingUpdateResponseJSON `json:"-"`
}

func (*ZoneTransferIncomingUpdateResponse) UnmarshalJSON

func (r *ZoneTransferIncomingUpdateResponse) UnmarshalJSON(data []byte) (err error)

type ZoneTransferIncomingUpdateResponseEnvelope

type ZoneTransferIncomingUpdateResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferIncomingUpdateResponseEnvelopeSuccess `json:"success,required"`
	Result  ZoneTransferIncomingUpdateResponse                `json:"result"`
	JSON    zoneTransferIncomingUpdateResponseEnvelopeJSON    `json:"-"`
}

func (*ZoneTransferIncomingUpdateResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferIncomingUpdateResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferIncomingUpdateResponseEnvelopeSuccess

type ZoneTransferIncomingUpdateResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferIncomingUpdateResponseEnvelopeSuccessTrue ZoneTransferIncomingUpdateResponseEnvelopeSuccess = true
)

func (ZoneTransferIncomingUpdateResponseEnvelopeSuccess) IsKnown

type ZoneTransferOutgoingDeleteParams

type ZoneTransferOutgoingDeleteParams struct {
	ZoneID param.Field[string] `path:"zone_id,required"`
}

type ZoneTransferOutgoingDeleteResponse

type ZoneTransferOutgoingDeleteResponse struct {
	ID   string                                 `json:"id"`
	JSON zoneTransferOutgoingDeleteResponseJSON `json:"-"`
}

func (*ZoneTransferOutgoingDeleteResponse) UnmarshalJSON

func (r *ZoneTransferOutgoingDeleteResponse) UnmarshalJSON(data []byte) (err error)

type ZoneTransferOutgoingDeleteResponseEnvelope

type ZoneTransferOutgoingDeleteResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferOutgoingDeleteResponseEnvelopeSuccess `json:"success,required"`
	Result  ZoneTransferOutgoingDeleteResponse                `json:"result"`
	JSON    zoneTransferOutgoingDeleteResponseEnvelopeJSON    `json:"-"`
}

func (*ZoneTransferOutgoingDeleteResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferOutgoingDeleteResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferOutgoingDeleteResponseEnvelopeSuccess

type ZoneTransferOutgoingDeleteResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferOutgoingDeleteResponseEnvelopeSuccessTrue ZoneTransferOutgoingDeleteResponseEnvelopeSuccess = true
)

func (ZoneTransferOutgoingDeleteResponseEnvelopeSuccess) IsKnown

type ZoneTransferOutgoingDisableParams

type ZoneTransferOutgoingDisableParams struct {
	ZoneID param.Field[string] `path:"zone_id,required"`
	Body   interface{}         `json:"body,required"`
}

func (ZoneTransferOutgoingDisableParams) MarshalJSON

func (r ZoneTransferOutgoingDisableParams) MarshalJSON() (data []byte, err error)

type ZoneTransferOutgoingDisableResponseEnvelope

type ZoneTransferOutgoingDisableResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferOutgoingDisableResponseEnvelopeSuccess `json:"success,required"`
	// The zone transfer status of a primary zone
	Result DisableTransfer                                 `json:"result"`
	JSON   zoneTransferOutgoingDisableResponseEnvelopeJSON `json:"-"`
}

func (*ZoneTransferOutgoingDisableResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferOutgoingDisableResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferOutgoingDisableResponseEnvelopeSuccess

type ZoneTransferOutgoingDisableResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferOutgoingDisableResponseEnvelopeSuccessTrue ZoneTransferOutgoingDisableResponseEnvelopeSuccess = true
)

func (ZoneTransferOutgoingDisableResponseEnvelopeSuccess) IsKnown

type ZoneTransferOutgoingEnableParams

type ZoneTransferOutgoingEnableParams struct {
	ZoneID param.Field[string] `path:"zone_id,required"`
	Body   interface{}         `json:"body,required"`
}

func (ZoneTransferOutgoingEnableParams) MarshalJSON

func (r ZoneTransferOutgoingEnableParams) MarshalJSON() (data []byte, err error)

type ZoneTransferOutgoingEnableResponseEnvelope

type ZoneTransferOutgoingEnableResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferOutgoingEnableResponseEnvelopeSuccess `json:"success,required"`
	// The zone transfer status of a primary zone
	Result EnableTransfer                                 `json:"result"`
	JSON   zoneTransferOutgoingEnableResponseEnvelopeJSON `json:"-"`
}

func (*ZoneTransferOutgoingEnableResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferOutgoingEnableResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferOutgoingEnableResponseEnvelopeSuccess

type ZoneTransferOutgoingEnableResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferOutgoingEnableResponseEnvelopeSuccessTrue ZoneTransferOutgoingEnableResponseEnvelopeSuccess = true
)

func (ZoneTransferOutgoingEnableResponseEnvelopeSuccess) IsKnown

type ZoneTransferOutgoingForceNotifyParams

type ZoneTransferOutgoingForceNotifyParams struct {
	ZoneID param.Field[string] `path:"zone_id,required"`
	Body   interface{}         `json:"body,required"`
}

func (ZoneTransferOutgoingForceNotifyParams) MarshalJSON

func (r ZoneTransferOutgoingForceNotifyParams) MarshalJSON() (data []byte, err error)

type ZoneTransferOutgoingForceNotifyResponseEnvelope

type ZoneTransferOutgoingForceNotifyResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferOutgoingForceNotifyResponseEnvelopeSuccess `json:"success,required"`
	// When force_notify query parameter is set to true, the response is a simple
	// string
	Result string                                              `json:"result"`
	JSON   zoneTransferOutgoingForceNotifyResponseEnvelopeJSON `json:"-"`
}

func (*ZoneTransferOutgoingForceNotifyResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferOutgoingForceNotifyResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferOutgoingForceNotifyResponseEnvelopeSuccess

type ZoneTransferOutgoingForceNotifyResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferOutgoingForceNotifyResponseEnvelopeSuccessTrue ZoneTransferOutgoingForceNotifyResponseEnvelopeSuccess = true
)

func (ZoneTransferOutgoingForceNotifyResponseEnvelopeSuccess) IsKnown

type ZoneTransferOutgoingGetParams

type ZoneTransferOutgoingGetParams struct {
	ZoneID param.Field[string] `path:"zone_id,required"`
}

type ZoneTransferOutgoingGetResponse

type ZoneTransferOutgoingGetResponse struct {
	ID string `json:"id"`
	// The time for a specific event.
	CheckedTime string `json:"checked_time"`
	// The time for a specific event.
	CreatedTime string `json:"created_time"`
	// The time for a specific event.
	LastTransferredTime string `json:"last_transferred_time"`
	// Zone name.
	Name string `json:"name"`
	// A list of peer tags.
	Peers []string `json:"peers"`
	// The serial number of the SOA for the given zone.
	SOASerial float64                             `json:"soa_serial"`
	JSON      zoneTransferOutgoingGetResponseJSON `json:"-"`
}

func (*ZoneTransferOutgoingGetResponse) UnmarshalJSON

func (r *ZoneTransferOutgoingGetResponse) UnmarshalJSON(data []byte) (err error)

type ZoneTransferOutgoingGetResponseEnvelope

type ZoneTransferOutgoingGetResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferOutgoingGetResponseEnvelopeSuccess `json:"success,required"`
	Result  ZoneTransferOutgoingGetResponse                `json:"result"`
	JSON    zoneTransferOutgoingGetResponseEnvelopeJSON    `json:"-"`
}

func (*ZoneTransferOutgoingGetResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferOutgoingGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferOutgoingGetResponseEnvelopeSuccess

type ZoneTransferOutgoingGetResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferOutgoingGetResponseEnvelopeSuccessTrue ZoneTransferOutgoingGetResponseEnvelopeSuccess = true
)

func (ZoneTransferOutgoingGetResponseEnvelopeSuccess) IsKnown

type ZoneTransferOutgoingNewParams

type ZoneTransferOutgoingNewParams struct {
	ZoneID param.Field[string] `path:"zone_id,required"`
	// Zone name.
	Name param.Field[string] `json:"name,required"`
	// A list of peer tags.
	Peers param.Field[[]string] `json:"peers,required"`
}

func (ZoneTransferOutgoingNewParams) MarshalJSON

func (r ZoneTransferOutgoingNewParams) MarshalJSON() (data []byte, err error)

type ZoneTransferOutgoingNewResponse

type ZoneTransferOutgoingNewResponse struct {
	ID string `json:"id"`
	// The time for a specific event.
	CheckedTime string `json:"checked_time"`
	// The time for a specific event.
	CreatedTime string `json:"created_time"`
	// The time for a specific event.
	LastTransferredTime string `json:"last_transferred_time"`
	// Zone name.
	Name string `json:"name"`
	// A list of peer tags.
	Peers []string `json:"peers"`
	// The serial number of the SOA for the given zone.
	SOASerial float64                             `json:"soa_serial"`
	JSON      zoneTransferOutgoingNewResponseJSON `json:"-"`
}

func (*ZoneTransferOutgoingNewResponse) UnmarshalJSON

func (r *ZoneTransferOutgoingNewResponse) UnmarshalJSON(data []byte) (err error)

type ZoneTransferOutgoingNewResponseEnvelope

type ZoneTransferOutgoingNewResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferOutgoingNewResponseEnvelopeSuccess `json:"success,required"`
	Result  ZoneTransferOutgoingNewResponse                `json:"result"`
	JSON    zoneTransferOutgoingNewResponseEnvelopeJSON    `json:"-"`
}

func (*ZoneTransferOutgoingNewResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferOutgoingNewResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferOutgoingNewResponseEnvelopeSuccess

type ZoneTransferOutgoingNewResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferOutgoingNewResponseEnvelopeSuccessTrue ZoneTransferOutgoingNewResponseEnvelopeSuccess = true
)

func (ZoneTransferOutgoingNewResponseEnvelopeSuccess) IsKnown

type ZoneTransferOutgoingService

type ZoneTransferOutgoingService struct {
	Options []option.RequestOption
	Status  *ZoneTransferOutgoingStatusService
}

ZoneTransferOutgoingService contains methods and other services that help with interacting with the cloudflare API.

Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewZoneTransferOutgoingService method instead.

func NewZoneTransferOutgoingService

func NewZoneTransferOutgoingService(opts ...option.RequestOption) (r *ZoneTransferOutgoingService)

NewZoneTransferOutgoingService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*ZoneTransferOutgoingService) Delete

Delete primary zone configuration for outgoing zone transfers.

func (*ZoneTransferOutgoingService) Disable

Disable outgoing zone transfers for primary zone and clears IXFR backlog of primary zone.

func (*ZoneTransferOutgoingService) Enable

Enable outgoing zone transfers for primary zone.

func (*ZoneTransferOutgoingService) ForceNotify

Notifies the secondary nameserver(s) and clears IXFR backlog of primary zone.

func (*ZoneTransferOutgoingService) Get

Get primary zone configuration for outgoing zone transfers.

func (*ZoneTransferOutgoingService) New

Create primary zone configuration for outgoing zone transfers.

func (*ZoneTransferOutgoingService) Update

Update primary zone configuration for outgoing zone transfers.

type ZoneTransferOutgoingStatusGetParams

type ZoneTransferOutgoingStatusGetParams struct {
	ZoneID param.Field[string] `path:"zone_id,required"`
}

type ZoneTransferOutgoingStatusGetResponseEnvelope

type ZoneTransferOutgoingStatusGetResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferOutgoingStatusGetResponseEnvelopeSuccess `json:"success,required"`
	// The zone transfer status of a primary zone
	Result EnableTransfer                                    `json:"result"`
	JSON   zoneTransferOutgoingStatusGetResponseEnvelopeJSON `json:"-"`
}

func (*ZoneTransferOutgoingStatusGetResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferOutgoingStatusGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferOutgoingStatusGetResponseEnvelopeSuccess

type ZoneTransferOutgoingStatusGetResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferOutgoingStatusGetResponseEnvelopeSuccessTrue ZoneTransferOutgoingStatusGetResponseEnvelopeSuccess = true
)

func (ZoneTransferOutgoingStatusGetResponseEnvelopeSuccess) IsKnown

type ZoneTransferOutgoingStatusService

type ZoneTransferOutgoingStatusService struct {
	Options []option.RequestOption
}

ZoneTransferOutgoingStatusService contains methods and other services that help with interacting with the cloudflare API.

Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewZoneTransferOutgoingStatusService method instead.

func NewZoneTransferOutgoingStatusService

func NewZoneTransferOutgoingStatusService(opts ...option.RequestOption) (r *ZoneTransferOutgoingStatusService)

NewZoneTransferOutgoingStatusService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*ZoneTransferOutgoingStatusService) Get

Get primary zone transfer status.

type ZoneTransferOutgoingUpdateParams

type ZoneTransferOutgoingUpdateParams struct {
	ZoneID param.Field[string] `path:"zone_id,required"`
	// Zone name.
	Name param.Field[string] `json:"name,required"`
	// A list of peer tags.
	Peers param.Field[[]string] `json:"peers,required"`
}

func (ZoneTransferOutgoingUpdateParams) MarshalJSON

func (r ZoneTransferOutgoingUpdateParams) MarshalJSON() (data []byte, err error)

type ZoneTransferOutgoingUpdateResponse

type ZoneTransferOutgoingUpdateResponse struct {
	ID string `json:"id"`
	// The time for a specific event.
	CheckedTime string `json:"checked_time"`
	// The time for a specific event.
	CreatedTime string `json:"created_time"`
	// The time for a specific event.
	LastTransferredTime string `json:"last_transferred_time"`
	// Zone name.
	Name string `json:"name"`
	// A list of peer tags.
	Peers []string `json:"peers"`
	// The serial number of the SOA for the given zone.
	SOASerial float64                                `json:"soa_serial"`
	JSON      zoneTransferOutgoingUpdateResponseJSON `json:"-"`
}

func (*ZoneTransferOutgoingUpdateResponse) UnmarshalJSON

func (r *ZoneTransferOutgoingUpdateResponse) UnmarshalJSON(data []byte) (err error)

type ZoneTransferOutgoingUpdateResponseEnvelope

type ZoneTransferOutgoingUpdateResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferOutgoingUpdateResponseEnvelopeSuccess `json:"success,required"`
	Result  ZoneTransferOutgoingUpdateResponse                `json:"result"`
	JSON    zoneTransferOutgoingUpdateResponseEnvelopeJSON    `json:"-"`
}

func (*ZoneTransferOutgoingUpdateResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferOutgoingUpdateResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferOutgoingUpdateResponseEnvelopeSuccess

type ZoneTransferOutgoingUpdateResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferOutgoingUpdateResponseEnvelopeSuccessTrue ZoneTransferOutgoingUpdateResponseEnvelopeSuccess = true
)

func (ZoneTransferOutgoingUpdateResponseEnvelopeSuccess) IsKnown

type ZoneTransferPeerDeleteParams

type ZoneTransferPeerDeleteParams struct {
	AccountID param.Field[string] `path:"account_id,required"`
}

type ZoneTransferPeerDeleteResponse

type ZoneTransferPeerDeleteResponse struct {
	ID   string                             `json:"id"`
	JSON zoneTransferPeerDeleteResponseJSON `json:"-"`
}

func (*ZoneTransferPeerDeleteResponse) UnmarshalJSON

func (r *ZoneTransferPeerDeleteResponse) UnmarshalJSON(data []byte) (err error)

type ZoneTransferPeerDeleteResponseEnvelope

type ZoneTransferPeerDeleteResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferPeerDeleteResponseEnvelopeSuccess `json:"success,required"`
	Result  ZoneTransferPeerDeleteResponse                `json:"result"`
	JSON    zoneTransferPeerDeleteResponseEnvelopeJSON    `json:"-"`
}

func (*ZoneTransferPeerDeleteResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferPeerDeleteResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferPeerDeleteResponseEnvelopeSuccess

type ZoneTransferPeerDeleteResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferPeerDeleteResponseEnvelopeSuccessTrue ZoneTransferPeerDeleteResponseEnvelopeSuccess = true
)

func (ZoneTransferPeerDeleteResponseEnvelopeSuccess) IsKnown

type ZoneTransferPeerGetParams

type ZoneTransferPeerGetParams struct {
	AccountID param.Field[string] `path:"account_id,required"`
}

type ZoneTransferPeerGetResponseEnvelope

type ZoneTransferPeerGetResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferPeerGetResponseEnvelopeSuccess `json:"success,required"`
	Result  Peer                                       `json:"result"`
	JSON    zoneTransferPeerGetResponseEnvelopeJSON    `json:"-"`
}

func (*ZoneTransferPeerGetResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferPeerGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferPeerGetResponseEnvelopeSuccess

type ZoneTransferPeerGetResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferPeerGetResponseEnvelopeSuccessTrue ZoneTransferPeerGetResponseEnvelopeSuccess = true
)

func (ZoneTransferPeerGetResponseEnvelopeSuccess) IsKnown

type ZoneTransferPeerListParams

type ZoneTransferPeerListParams struct {
	AccountID param.Field[string] `path:"account_id,required"`
}

type ZoneTransferPeerNewParams

type ZoneTransferPeerNewParams struct {
	AccountID param.Field[string] `path:"account_id,required"`
	// The name of the peer.
	Name param.Field[string] `json:"name,required"`
}

func (ZoneTransferPeerNewParams) MarshalJSON

func (r ZoneTransferPeerNewParams) MarshalJSON() (data []byte, err error)

type ZoneTransferPeerNewResponseEnvelope

type ZoneTransferPeerNewResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferPeerNewResponseEnvelopeSuccess `json:"success,required"`
	Result  Peer                                       `json:"result"`
	JSON    zoneTransferPeerNewResponseEnvelopeJSON    `json:"-"`
}

func (*ZoneTransferPeerNewResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferPeerNewResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferPeerNewResponseEnvelopeSuccess

type ZoneTransferPeerNewResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferPeerNewResponseEnvelopeSuccessTrue ZoneTransferPeerNewResponseEnvelopeSuccess = true
)

func (ZoneTransferPeerNewResponseEnvelopeSuccess) IsKnown

type ZoneTransferPeerService

type ZoneTransferPeerService struct {
	Options []option.RequestOption
}

ZoneTransferPeerService contains methods and other services that help with interacting with the cloudflare API.

Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewZoneTransferPeerService method instead.

func NewZoneTransferPeerService

func NewZoneTransferPeerService(opts ...option.RequestOption) (r *ZoneTransferPeerService)

NewZoneTransferPeerService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*ZoneTransferPeerService) Delete

Delete Peer.

func (*ZoneTransferPeerService) Get

func (r *ZoneTransferPeerService) Get(ctx context.Context, peerID string, query ZoneTransferPeerGetParams, opts ...option.RequestOption) (res *Peer, err error)

Get Peer.

func (*ZoneTransferPeerService) List

List Peers.

func (*ZoneTransferPeerService) ListAutoPaging

List Peers.

func (*ZoneTransferPeerService) New

Create Peer.

func (*ZoneTransferPeerService) Update

func (r *ZoneTransferPeerService) Update(ctx context.Context, peerID string, params ZoneTransferPeerUpdateParams, opts ...option.RequestOption) (res *Peer, err error)

Modify Peer.

type ZoneTransferPeerUpdateParams

type ZoneTransferPeerUpdateParams struct {
	AccountID param.Field[string] `path:"account_id,required"`
	Peer      PeerParam           `json:"peer,required"`
}

func (ZoneTransferPeerUpdateParams) MarshalJSON

func (r ZoneTransferPeerUpdateParams) MarshalJSON() (data []byte, err error)

type ZoneTransferPeerUpdateResponseEnvelope

type ZoneTransferPeerUpdateResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferPeerUpdateResponseEnvelopeSuccess `json:"success,required"`
	Result  Peer                                          `json:"result"`
	JSON    zoneTransferPeerUpdateResponseEnvelopeJSON    `json:"-"`
}

func (*ZoneTransferPeerUpdateResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferPeerUpdateResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferPeerUpdateResponseEnvelopeSuccess

type ZoneTransferPeerUpdateResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferPeerUpdateResponseEnvelopeSuccessTrue ZoneTransferPeerUpdateResponseEnvelopeSuccess = true
)

func (ZoneTransferPeerUpdateResponseEnvelopeSuccess) IsKnown

type ZoneTransferService

ZoneTransferService contains methods and other services that help with interacting with the cloudflare API.

Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewZoneTransferService method instead.

func NewZoneTransferService

func NewZoneTransferService(opts ...option.RequestOption) (r *ZoneTransferService)

NewZoneTransferService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

type ZoneTransferTSIGDeleteParams

type ZoneTransferTSIGDeleteParams struct {
	AccountID param.Field[string] `path:"account_id,required"`
}

type ZoneTransferTSIGDeleteResponse

type ZoneTransferTSIGDeleteResponse struct {
	ID   string                             `json:"id"`
	JSON zoneTransferTSIGDeleteResponseJSON `json:"-"`
}

func (*ZoneTransferTSIGDeleteResponse) UnmarshalJSON

func (r *ZoneTransferTSIGDeleteResponse) UnmarshalJSON(data []byte) (err error)

type ZoneTransferTSIGDeleteResponseEnvelope

type ZoneTransferTSIGDeleteResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferTSIGDeleteResponseEnvelopeSuccess `json:"success,required"`
	Result  ZoneTransferTSIGDeleteResponse                `json:"result"`
	JSON    zoneTransferTSIGDeleteResponseEnvelopeJSON    `json:"-"`
}

func (*ZoneTransferTSIGDeleteResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferTSIGDeleteResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferTSIGDeleteResponseEnvelopeSuccess

type ZoneTransferTSIGDeleteResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferTSIGDeleteResponseEnvelopeSuccessTrue ZoneTransferTSIGDeleteResponseEnvelopeSuccess = true
)

func (ZoneTransferTSIGDeleteResponseEnvelopeSuccess) IsKnown

type ZoneTransferTSIGGetParams

type ZoneTransferTSIGGetParams struct {
	AccountID param.Field[string] `path:"account_id,required"`
}

type ZoneTransferTSIGGetResponseEnvelope

type ZoneTransferTSIGGetResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferTSIGGetResponseEnvelopeSuccess `json:"success,required"`
	Result  TSIG                                       `json:"result"`
	JSON    zoneTransferTSIGGetResponseEnvelopeJSON    `json:"-"`
}

func (*ZoneTransferTSIGGetResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferTSIGGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferTSIGGetResponseEnvelopeSuccess

type ZoneTransferTSIGGetResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferTSIGGetResponseEnvelopeSuccessTrue ZoneTransferTSIGGetResponseEnvelopeSuccess = true
)

func (ZoneTransferTSIGGetResponseEnvelopeSuccess) IsKnown

type ZoneTransferTSIGListParams

type ZoneTransferTSIGListParams struct {
	AccountID param.Field[string] `path:"account_id,required"`
}

type ZoneTransferTSIGNewParams

type ZoneTransferTSIGNewParams struct {
	AccountID param.Field[string] `path:"account_id,required"`
	TSIG      TSIGParam           `json:"tsig,required"`
}

func (ZoneTransferTSIGNewParams) MarshalJSON

func (r ZoneTransferTSIGNewParams) MarshalJSON() (data []byte, err error)

type ZoneTransferTSIGNewResponseEnvelope

type ZoneTransferTSIGNewResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferTSIGNewResponseEnvelopeSuccess `json:"success,required"`
	Result  TSIG                                       `json:"result"`
	JSON    zoneTransferTSIGNewResponseEnvelopeJSON    `json:"-"`
}

func (*ZoneTransferTSIGNewResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferTSIGNewResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferTSIGNewResponseEnvelopeSuccess

type ZoneTransferTSIGNewResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferTSIGNewResponseEnvelopeSuccessTrue ZoneTransferTSIGNewResponseEnvelopeSuccess = true
)

func (ZoneTransferTSIGNewResponseEnvelopeSuccess) IsKnown

type ZoneTransferTSIGService

type ZoneTransferTSIGService struct {
	Options []option.RequestOption
}

ZoneTransferTSIGService contains methods and other services that help with interacting with the cloudflare API.

Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewZoneTransferTSIGService method instead.

func NewZoneTransferTSIGService

func NewZoneTransferTSIGService(opts ...option.RequestOption) (r *ZoneTransferTSIGService)

NewZoneTransferTSIGService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*ZoneTransferTSIGService) Delete

Delete TSIG.

func (*ZoneTransferTSIGService) Get

func (r *ZoneTransferTSIGService) Get(ctx context.Context, tsigID string, query ZoneTransferTSIGGetParams, opts ...option.RequestOption) (res *TSIG, err error)

Get TSIG.

func (*ZoneTransferTSIGService) List

List TSIGs.

func (*ZoneTransferTSIGService) ListAutoPaging

List TSIGs.

func (*ZoneTransferTSIGService) New

Create TSIG.

func (*ZoneTransferTSIGService) Update

func (r *ZoneTransferTSIGService) Update(ctx context.Context, tsigID string, params ZoneTransferTSIGUpdateParams, opts ...option.RequestOption) (res *TSIG, err error)

Modify TSIG.

type ZoneTransferTSIGUpdateParams

type ZoneTransferTSIGUpdateParams struct {
	AccountID param.Field[string] `path:"account_id,required"`
	TSIG      TSIGParam           `json:"tsig,required"`
}

func (ZoneTransferTSIGUpdateParams) MarshalJSON

func (r ZoneTransferTSIGUpdateParams) MarshalJSON() (data []byte, err error)

type ZoneTransferTSIGUpdateResponseEnvelope

type ZoneTransferTSIGUpdateResponseEnvelope struct {
	Errors   []shared.ResponseInfo `json:"errors,required"`
	Messages []shared.ResponseInfo `json:"messages,required"`
	// Whether the API call was successful
	Success ZoneTransferTSIGUpdateResponseEnvelopeSuccess `json:"success,required"`
	Result  TSIG                                          `json:"result"`
	JSON    zoneTransferTSIGUpdateResponseEnvelopeJSON    `json:"-"`
}

func (*ZoneTransferTSIGUpdateResponseEnvelope) UnmarshalJSON

func (r *ZoneTransferTSIGUpdateResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ZoneTransferTSIGUpdateResponseEnvelopeSuccess

type ZoneTransferTSIGUpdateResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ZoneTransferTSIGUpdateResponseEnvelopeSuccessTrue ZoneTransferTSIGUpdateResponseEnvelopeSuccess = true
)

func (ZoneTransferTSIGUpdateResponseEnvelopeSuccess) IsKnown

Jump to

Keyboard shortcuts

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