Skip to content
Start here

Settings

SettingsZone

Show DNS Settings
client.dns.settings.zone.get(ZoneGetParams { zone_id } params, RequestOptionsoptions?): ZoneGetResponse { flatten_all_cnames, foundation_dns, internal_dns, 6 more }
GET/zones/{zone_id}/dns_settings
Update DNS Settings
client.dns.settings.zone.edit(ZoneEditParams { zone_id, flatten_all_cnames, foundation_dns, 7 more } params, RequestOptionsoptions?): ZoneEditResponse { flatten_all_cnames, foundation_dns, internal_dns, 6 more }
PATCH/zones/{zone_id}/dns_settings
ModelsExpand Collapse
ZoneGetResponse { flatten_all_cnames, foundation_dns, internal_dns, 6 more }
flatten_all_cnames: boolean

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.

foundation_dns: boolean

Whether to enable Foundation DNS Advanced Nameservers on the zone.

internal_dns: InternalDNS { reference_zone_id }

Settings for this internal zone.

reference_zone_id?: string

The ID of the zone to fallback to.

multi_provider: boolean

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.

nameservers: Nameservers { type, ns_set }

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

type: "cloudflare.standard" | "custom.account" | "custom.tenant" | "custom.zone"

Nameserver type

One of the following:
"cloudflare.standard"
"custom.account"
"custom.tenant"
"custom.zone"
ns_set?: number

Configured nameserver set to be used for this zone

maximum5
minimum1
ns_ttl: number

The time to live (TTL) of the zone's nameserver (NS) records.

maximum86400
minimum30
secondary_overrides: boolean

Allows a Secondary DNS zone to use (proxied) override records and CNAME flattening at the zone apex.

soa: SOA { expire, min_ttl, mname, 4 more }

Components of the zone's SOA record.

expire?: number

Time in seconds of being unable to query the primary server after which secondary servers should stop serving the zone.

maximum2419200
minimum86400
min_ttl?: number

The time to live (TTL) for negative caching of records within the zone.

maximum86400
minimum60
mname?: string | null

The primary nameserver, which may be used for outbound zone transfers. If null, a Cloudflare-assigned value will be used.

refresh?: number

Time in seconds after which secondary servers should re-check the SOA record to see if the zone has been updated.

maximum86400
minimum600
retry?: number

Time in seconds after which secondary servers should retry queries after the primary server was unresponsive.

maximum86400
minimum600
rname?: string

The email address of the zone administrator, with the first label representing the local part of the email address.

ttl?: number

The time to live (TTL) of the SOA record itself.

maximum86400
minimum300
zone_mode: "standard" | "cdn_only" | "dns_only"

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

One of the following:
"standard"
"cdn_only"
"dns_only"
ZoneEditResponse { flatten_all_cnames, foundation_dns, internal_dns, 6 more }
flatten_all_cnames: boolean

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.

foundation_dns: boolean

Whether to enable Foundation DNS Advanced Nameservers on the zone.

internal_dns: InternalDNS { reference_zone_id }

Settings for this internal zone.

reference_zone_id?: string

The ID of the zone to fallback to.

multi_provider: boolean

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.

nameservers: Nameservers { type, ns_set }

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

type: "cloudflare.standard" | "custom.account" | "custom.tenant" | "custom.zone"

Nameserver type

One of the following:
"cloudflare.standard"
"custom.account"
"custom.tenant"
"custom.zone"
ns_set?: number

Configured nameserver set to be used for this zone

maximum5
minimum1
ns_ttl: number

The time to live (TTL) of the zone's nameserver (NS) records.

maximum86400
minimum30
secondary_overrides: boolean

Allows a Secondary DNS zone to use (proxied) override records and CNAME flattening at the zone apex.

soa: SOA { expire, min_ttl, mname, 4 more }

Components of the zone's SOA record.

expire?: number

Time in seconds of being unable to query the primary server after which secondary servers should stop serving the zone.

maximum2419200
minimum86400
min_ttl?: number

The time to live (TTL) for negative caching of records within the zone.

maximum86400
minimum60
mname?: string | null

The primary nameserver, which may be used for outbound zone transfers. If null, a Cloudflare-assigned value will be used.

refresh?: number

Time in seconds after which secondary servers should re-check the SOA record to see if the zone has been updated.

maximum86400
minimum600
retry?: number

Time in seconds after which secondary servers should retry queries after the primary server was unresponsive.

maximum86400
minimum600
rname?: string

The email address of the zone administrator, with the first label representing the local part of the email address.

ttl?: number

The time to live (TTL) of the SOA record itself.

maximum86400
minimum300
zone_mode: "standard" | "cdn_only" | "dns_only"

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

One of the following:
"standard"
"cdn_only"
"dns_only"

SettingsAccount

Show DNS Settings
client.dns.settings.account.get(AccountGetParams { account_id } params, RequestOptionsoptions?): AccountGetResponse { zone_defaults }
GET/accounts/{account_id}/dns_settings
Update DNS Settings
client.dns.settings.account.edit(AccountEditParams { account_id, zone_defaults } params, RequestOptionsoptions?): AccountEditResponse { zone_defaults }
PATCH/accounts/{account_id}/dns_settings
ModelsExpand Collapse
AccountGetResponse { zone_defaults }
zone_defaults: ZoneDefaults { flatten_all_cnames, foundation_dns, internal_dns, 6 more }
flatten_all_cnames: boolean

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.

foundation_dns: boolean

Whether to enable Foundation DNS Advanced Nameservers on the zone.

internal_dns: InternalDNS { reference_zone_id }

Settings for this internal zone.

reference_zone_id?: string

The ID of the zone to fallback to.

multi_provider: boolean

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.

nameservers: Nameservers { type }

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

type: "cloudflare.standard" | "cloudflare.standard.random" | "custom.account" | "custom.tenant"

Nameserver type

One of the following:
"cloudflare.standard"
"cloudflare.standard.random"
"custom.account"
"custom.tenant"
ns_ttl: number

The time to live (TTL) of the zone's nameserver (NS) records.

maximum86400
minimum30
secondary_overrides: boolean

Allows a Secondary DNS zone to use (proxied) override records and CNAME flattening at the zone apex.

soa: SOA { expire, min_ttl, mname, 4 more }

Components of the zone's SOA record.

expire?: number

Time in seconds of being unable to query the primary server after which secondary servers should stop serving the zone.

maximum2419200
minimum86400
min_ttl?: number

The time to live (TTL) for negative caching of records within the zone.

maximum86400
minimum60
mname?: string | null

The primary nameserver, which may be used for outbound zone transfers. If null, a Cloudflare-assigned value will be used.

refresh?: number

Time in seconds after which secondary servers should re-check the SOA record to see if the zone has been updated.

maximum86400
minimum600
retry?: number

Time in seconds after which secondary servers should retry queries after the primary server was unresponsive.

maximum86400
minimum600
rname?: string

The email address of the zone administrator, with the first label representing the local part of the email address.

ttl?: number

The time to live (TTL) of the SOA record itself.

maximum86400
minimum300
zone_mode: "standard" | "cdn_only" | "dns_only"

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

One of the following:
"standard"
"cdn_only"
"dns_only"
AccountEditResponse { zone_defaults }
zone_defaults: ZoneDefaults { flatten_all_cnames, foundation_dns, internal_dns, 6 more }
flatten_all_cnames: boolean

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.

foundation_dns: boolean

Whether to enable Foundation DNS Advanced Nameservers on the zone.

internal_dns: InternalDNS { reference_zone_id }

Settings for this internal zone.

reference_zone_id?: string

The ID of the zone to fallback to.

multi_provider: boolean

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.

nameservers: Nameservers { type }

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

type: "cloudflare.standard" | "cloudflare.standard.random" | "custom.account" | "custom.tenant"

Nameserver type

One of the following:
"cloudflare.standard"
"cloudflare.standard.random"
"custom.account"
"custom.tenant"
ns_ttl: number

The time to live (TTL) of the zone's nameserver (NS) records.

maximum86400
minimum30
secondary_overrides: boolean

Allows a Secondary DNS zone to use (proxied) override records and CNAME flattening at the zone apex.

soa: SOA { expire, min_ttl, mname, 4 more }

Components of the zone's SOA record.

expire?: number

Time in seconds of being unable to query the primary server after which secondary servers should stop serving the zone.

maximum2419200
minimum86400
min_ttl?: number

The time to live (TTL) for negative caching of records within the zone.

maximum86400
minimum60
mname?: string | null

The primary nameserver, which may be used for outbound zone transfers. If null, a Cloudflare-assigned value will be used.

refresh?: number

Time in seconds after which secondary servers should re-check the SOA record to see if the zone has been updated.

maximum86400
minimum600
retry?: number

Time in seconds after which secondary servers should retry queries after the primary server was unresponsive.

maximum86400
minimum600
rname?: string

The email address of the zone administrator, with the first label representing the local part of the email address.

ttl?: number

The time to live (TTL) of the SOA record itself.

maximum86400
minimum300
zone_mode: "standard" | "cdn_only" | "dns_only"

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

One of the following:
"standard"
"cdn_only"
"dns_only"

SettingsAccountViews

List Internal DNS Views
client.dns.settings.account.views.list(ViewListParams { account_id, direction, match, 6 more } params, RequestOptionsoptions?): V4PagePaginationArray<ViewListResponse { id, created_time, modified_time, 2 more } >
GET/accounts/{account_id}/dns_settings/views
DNS Internal View Details
client.dns.settings.account.views.get(stringviewId, ViewGetParams { account_id } params, RequestOptionsoptions?): ViewGetResponse { id, created_time, modified_time, 2 more }
GET/accounts/{account_id}/dns_settings/views/{view_id}
Create Internal DNS View
client.dns.settings.account.views.create(ViewCreateParams { account_id, name, zones } params, RequestOptionsoptions?): ViewCreateResponse { id, created_time, modified_time, 2 more }
POST/accounts/{account_id}/dns_settings/views
Update Internal DNS View
client.dns.settings.account.views.edit(stringviewId, ViewEditParams { account_id, name, zones } params, RequestOptionsoptions?): ViewEditResponse { id, created_time, modified_time, 2 more }
PATCH/accounts/{account_id}/dns_settings/views/{view_id}
Delete Internal DNS View
client.dns.settings.account.views.delete(stringviewId, ViewDeleteParams { account_id } params, RequestOptionsoptions?): ViewDeleteResponse { id }
DELETE/accounts/{account_id}/dns_settings/views/{view_id}
ModelsExpand Collapse
ViewListResponse { id, created_time, modified_time, 2 more }
id: string

Identifier.

maxLength32
created_time: string

When the view was created.

formatdate-time
modified_time: string

When the view was last modified.

formatdate-time
name: string

The name of the view.

maxLength255
minLength1
zones: Array<string>

The list of zones linked to this view.

ViewGetResponse { id, created_time, modified_time, 2 more }
id: string

Identifier.

maxLength32
created_time: string

When the view was created.

formatdate-time
modified_time: string

When the view was last modified.

formatdate-time
name: string

The name of the view.

maxLength255
minLength1
zones: Array<string>

The list of zones linked to this view.

ViewCreateResponse { id, created_time, modified_time, 2 more }
id: string

Identifier.

maxLength32
created_time: string

When the view was created.

formatdate-time
modified_time: string

When the view was last modified.

formatdate-time
name: string

The name of the view.

maxLength255
minLength1
zones: Array<string>

The list of zones linked to this view.

ViewEditResponse { id, created_time, modified_time, 2 more }
id: string

Identifier.

maxLength32
created_time: string

When the view was created.

formatdate-time
modified_time: string

When the view was last modified.

formatdate-time
name: string

The name of the view.

maxLength255
minLength1
zones: Array<string>

The list of zones linked to this view.

ViewDeleteResponse { id }
id?: string

Identifier.

maxLength32