Cloudflare/dns
@swamp/cloudflare/dnsv2026.05.22.1
01README
Cloudflare dns infrastructure models
02Release Notes
- Added: dns_firewall
- Added: dns_records
- Added: views
03Models
@swamp/cloudflare/dns/dns-firewallv2026.05.22.1dns_firewall.ts
Global Arguments
| Argument | Type | Description |
|---|---|---|
| account_id | string | Cloudflare account ID |
| attack_mitigation? | object | Attack mitigation settings |
| deprecate_any_requests? | boolean | Whether to refuse to answer queries for the ANY type |
| ecs_fallback? | boolean | Whether to forward client IP (resolver) subnet if no EDNS Client Subnet is sent |
| maximum_cache_ttl? | number | By default, Cloudflare attempts to cache responses for as long as\nindicated by the TTL received from upstream nameservers. This setting\nsets an upper bound on this duration. For caching purposes, higher TTLs\nwill be decreased to the maximum value defined by this setting.\n\nThis setting does not affect the TTL value in the DNS response\nCloudflare returns to clients. Cloudflare will always forward the TTL\nvalue received from upstream nameservers.\n |
| minimum_cache_ttl? | number | By default, Cloudflare attempts to cache responses for as long as\nindicated by the TTL received from upstream nameservers. This setting\nsets a lower bound on this duration. For caching purposes, lower TTLs\nwill be increased to the minimum value defined by this setting.\n\nThis setting does not affect the TTL value in the DNS response\nCloudflare returns to clients. Cloudflare will always forward the TTL\nvalue received from upstream nameservers.\n\nNote that, even with this setting, there is |
| name? | string | DNS Firewall cluster name |
| negative_cache_ttl? | number | This setting controls how long DNS Firewall should cache negative\nresponses (e.g., NXDOMAIN) from the upstream servers.\n\nThis setting does not affect the TTL value in the DNS response\nCloudflare returns to clients. Cloudflare will always forward the TTL\nvalue received from upstream nameservers.\n |
| ratelimit? | number | Ratelimit in queries per second per datacenter (applies to DNS queries sent to the upstream nameservers configured on the cluster) |
| retries? | number | Number of retries for fetching DNS responses from upstream nameservers (not counting the initial attempt) |
| upstream_ips? | array |
fn create()
Create a Dns Firewall
fn get(id: string)
Get a Dns Firewall
| Argument | Type | Description |
|---|---|---|
| id | string | The ID of the Dns Firewall |
fn update()
Update Dns Firewall attributes
fn delete(id: string)
Delete the Dns Firewall
| Argument | Type | Description |
|---|---|---|
| id | string | The ID of the Dns Firewall |
fn sync()
Sync Dns Firewall state from Cloudflare
Resources
state(infinite)— Dns Firewall resource state
@swamp/cloudflare/dns/dns-recordsv2026.05.22.1dns_records.ts
Global Arguments
| Argument | Type | Description |
|---|---|---|
| zone_id | string | Cloudflare zone ID |
| comment? | string | Comments or notes about the DNS record. This field has no effect on DNS responses. |
| name? | string | Complete DNS record name, including the zone name, in Punycode. |
| proxied? | boolean | Whether the record is receiving the performance and security benefits of Cloudflare. |
| settings? | object | Settings for the DNS record. |
| tags? | array | Custom tags for the DNS record. This field has no effect on DNS responses. |
| ttl? | number | |
| content? | string | A valid IPv4 address. |
| private_routing? | boolean | Enables private network routing to the origin. |
| type? | enum | Record type. |
| priority? | number | Required for MX and URI records; ignored for other record types (but may still be returned by the API). Records with lower priorities are preferred. This field is to be deprecated in favor of the priority field within the data map. |
| data? | object | Components of a CAA record. |
fn create()
Create a Dns Records
fn get(id: string)
Get a Dns Records
| Argument | Type | Description |
|---|---|---|
| id | string | The ID of the Dns Records |
fn update()
Update Dns Records attributes
fn delete(id: string)
Delete the Dns Records
| Argument | Type | Description |
|---|---|---|
| id | string | The ID of the Dns Records |
fn sync()
Sync Dns Records state from Cloudflare
Resources
state(infinite)— Dns Records resource state
@swamp/cloudflare/dns/viewsv2026.05.22.1views.ts
Global Arguments
| Argument | Type | Description |
|---|---|---|
| account_id | string | Cloudflare account ID |
| created_time? | string | When the view was created. |
| modified_time? | string | When the view was last modified. |
| name? | string | The name of the view. |
| zones? | array | The list of zones linked to this view. |
fn create()
Create a Views
fn get(id: string)
Get a Views
| Argument | Type | Description |
|---|---|---|
| id | string | The ID of the Views |
fn update()
Update Views attributes
fn delete(id: string)
Delete the Views
| Argument | Type | Description |
|---|---|---|
| id | string | The ID of the Views |
fn sync()
Sync Views state from Cloudflare
Resources
state(infinite)— Views resource state
04Stats
A
100 / 100
Downloads
0
Archive size
14.0 KB
Verified by Swamp
- Has README or module doc2/2earned
- README has a code example1/1earned
- README is substantive1/1earned
- Most symbols documented1/1earned
- No slow types1/1earned
- Dependencies pass trust audit2/2earned
- Has description1/1earned
- Platform support declared (or universal)2/2earned
- License declared1/1earned
- Verified public repository2/2earned
05Platforms
06Labels