# Keep dated mail DNS snapshots in Google Drive

Give your mail administrator a dated text file listing the domain’s MX, SPF and DMARC records, including days when the configuration stays the same.

[Use template](https://dashboard.fasthook.io/workflow/new?templateKey=cloudflare-dns-mail-snapshots-to-google-drive&templateName=Keep+dated+mail+DNS+snapshots+in+Google+Drive)

**Required accounts**

- Cloudflare DNS
- Google Drive

## Keep dated mail DNS snapshots in Google Drive

### 1. Trigger · Daily schedule

**Schedule**. Run automatically on the configured schedule.

### 2. Action · Read MX, SPF and DMARC records

**Cloudflare DNS**. Collect and sort the domain’s MX, SPF and DMARC records for comparison with an earlier snapshot.

### 3. Action · Save the readable snapshot

**Google Drive**. Create a UTF-8 file in My Drive or a selected folder.

## Set up your workflow

1. **Choose the domain** Connect Cloudflare with DNS Read access. Select the zone and enter the fully qualified domain whose incoming mail and sender policies you want to document.
2. **Choose the archive location** Connect Google Drive and select a folder visible to the mail operations team. Leaving the folder empty saves the file to My Drive.
3. **Check the contents** Set the capture schedule and open the first text file. Compare its MX priorities, SPF text and DMARC policy with Cloudflare. Repeating the same run creates another Drive file.

## Related integrations

- [Schedule trigger](https://www.fasthook.io/docs/triggers/schedule)
- [Cloudflare DNS integrations](https://www.fasthook.io/apps/cloudflare-dns/integrations)
- [Google Drive integrations](https://www.fasthook.io/apps/google-drive/integrations)

## Related workflow templates

- [Notify ntfy when a domain has no mail DNS records](https://www.fasthook.io/templates/cloudflare-dns-empty-mail-check-to-ntfy.md): Watch a domain that should have mail configured.
- [Alert Discord when DNSSEC is not active](https://www.fasthook.io/templates/cloudflare-dnssec-status-to-discord.md): Check the signing status Cloudflare reports for one zone.
- [Back up a DNS zone to Dropbox](https://www.fasthook.io/templates/cloudflare-dns-zone-backups-to-dropbox.md): Save a BIND zone file to a private Dropbox folder each day.
- [Archive DNS records to R2 on a schedule](https://www.fasthook.io/templates/cloudflare-dns-zone-exports-to-r2.md): Save a dated BIND zone file in a private R2 bucket.
