DNS Records
Retrieves DNS records from Cloudflare for DNS management and security monitoring. This input collects DNS record data across all zones in your Cloudflare account, including A, AAAA, CNAME, MX, TXT, NS, SRV, CAA, and other DNS record types for comprehensive domain management and monitoring.
Sync Type: Full Synchronization
Requirements
- A Cloudflare account with API access
- An API Token with the
Zone:ReadandZone:DNS:Readpermissions - Access to at least one DNS zone
Creating an API Token
- Log in to your Cloudflare dashboard
- Navigate to My Profile > API Tokens
- Click Create Token
- Use the Create Custom Token option
- Configure the token:
- Token name: Give it a descriptive name (e.g., "Monad DNS Records")
- Permissions: Add
Zone>Zone>ReadandZone>DNS>Read - Zone Resources: Select the specific zone(s) or "All zones"
- Click Continue to summary and then Create Token
- Copy the token value (you won't be able to see it again)
Details
- State Management: Uses deduplication to avoid re-processing unchanged records across runs. Each full sync retrieves all current DNS records from all zones.
- API Endpoints:
GET /zones- Lists all zones in the accountGET /zones/{zone_id}/dns_records- Lists DNS records for a specific zone
- Pagination: Page-based pagination with up to 5,000 records per page, sorted in ascending order.
- Rate Limits: 1,200 requests per 5 minutes (approximately 4 requests per second). The input automatically enforces this limit.
- Multi-Zone: Iterates through all zones in the account and fetches DNS records for each zone.
Configuration
Settings
| Setting | Type | Required | Description |
|---|---|---|---|
| Cron | string | Yes | Cron expression for scheduling the input (e.g., 0 0 * * * for daily execution at midnight) |
| Zone IDs | array | No | Optional list of specific Cloudflare zone IDs to fetch DNS records from. If empty, fetches from all zones accessible by the API token. |
Secrets
| Secret | Type | Required | Description |
|---|---|---|---|
| API Token | string | Yes | API Token with Zone:Read and Zone:DNS:Read permissions |
Rate Limits
| Scope | Limit | Window | Notes |
|---|---|---|---|
| API Requests | 1,200 | 5 minutes | Enforced by Cloudflare |
| Records per page | 5,000 | Per request | Maximum allowed by API |
Headers: Authorization: Bearer {api_token}
Source: Cloudflare API Rate Limits
Troubleshooting
Common Issues
Issue: API returned success=false with authentication error
Cause: The API token is invalid, expired, or lacks the required permissions.
Solution: Verify your API token is correct and has both Zone:Read and Zone:DNS:Read permissions. Create a new token if needed.
Issue: No records returned despite having DNS records Cause: The API token may not have access to your zones, or you have no zones configured. Solution: Verify that your API token has been granted access to the zones you want to monitor. Ensure you have at least one active DNS zone in your Cloudflare account.
Issue: Rate limit exceeded errors Cause: Multiple integrations or manual API calls are consuming the rate limit quota. Solution: The input automatically handles rate limiting. If you see persistent errors, reduce the frequency of other API calls to your Cloudflare account.
Issue: Timeout errors when fetching DNS records Cause: Account has a very large number of DNS records across many zones, exceeding timeout. Solution: The input uses page-based pagination. If timeouts persist, consider checking Cloudflare API status or contacting Cloudflare support for large account configurations.
Related Articles
Sample Record
{
"id": "372e67954025e0ba6aaa6d586b9e0b59",
"type": "A",
"name": "example.com",
"content": "198.51.100.4",
"proxied": true,
"proxiable": false,
"ttl": 3600,
"comment": "Domain verification record",
"created_on": "2025-01-13T10:30:45Z",
"modified_on": "2025-01-13T10:30:45Z",
"tags": [],
"meta": {},
"settings": {
"flatten_cname": false
}
}