Send Cloudflare logs to LogPulse

Cloudflare HTTP request logs, firewall events, audit logs, Zero Trust, DNS and healthchecks through the API, and Workers and Pages logs and traces through OTLP push.

In short
To send Cloudflare logs to LogPulse, add Cloudflare under Configure → Sources → Cloud. LogPulse reads the Cloudflare API and OTLP push itself, without an agent. Events land in the web, dns, firewall, audit, iam, network, application, cicd indexes with source cloudflare, cloudflare_workers, cloudflare_pages and fill the Application Logs, Security Event, Trace Event, CI/CD Pipeline, Observability Alert data models.

Overview

How Cloudflare data reaches LogPulse
Vendor
Cloudflare API and OTLP push
Collect
Integration pollerreads new events, maps the fields
Store
index=web
index=dns
index=firewall
index=audit
index=iam
index=network
index=application
index=cicd
  1. Cloudflare API and OTLP push to Integration poller
  2. Integration poller to index=web
  3. Integration poller to index=dns
  4. Integration poller to index=firewall
  5. Integration poller to index=audit
  6. Integration poller to index=iam
  7. Integration poller to index=network
  8. Integration poller to index=application
  9. Integration poller to index=cicd

LogPulse signs in to Cloudflare with the credential you give it and fetches new events every five minutes by default. You can set the interval per integration, from one minute to 24 hours.

What you need

  • OTLP push: no Cloudflare credentials needed, only Cloudflare Observability pointed at LogPulse
  • API polling: a Cloudflare API Token with read permission for the data sources you turn on
  • API polling: the Account ID (in the dashboard sidebar)
  • Optional: a Zone ID for the zone-level data sources (HTTP logs, firewall, DNS, healthchecks)
  • In LogPulse: a role that may manage API keys. Cloud integrations fall under that right.

1. Create a credential in Cloudflare

Field in LogPulseWhere you find it
Cloudflare API TokenOnly for API polling. In the Cloudflare dashboard: My Profile, API Tokens. Give it read permission for the data sources you turn on, such as Account Audit Logs: Read. Stored encrypted and never shown again.
Account IDOnly for API polling. In the Cloudflare dashboard sidebar under your account name.
Zone ID (optional)Needed for HTTP request logs, firewall events, DNS logs and healthchecks. On the overview page of the zone.

2. Add the integration in LogPulse

Go to Configure → Sources → Cloud and choose Cloudflare. Fill in the fields, tick the data sources you want and save. LogPulse first tests the connection with your credential and tells you what is wrong when it fails.

Workers & Pages Logs and Workers & Pages Traces are not polled but sent to LogPulse by Cloudflare. After you save, LogPulse shows the address and the key to set on the Cloudflare side.

Tip: Secrets are stored encrypted and never shown again. To change one, paste a new value; the rest stays.

What arrives

Data sourceIndexSourceSourcetypeWhat it holds
HTTP Request Logswebcloudflarecloudflare:httpEdge HTTP request logs with RayID tracing: client info, cache status, origin timing, WAF actions, and Worker subrequests.
DNS Query Logs (off by default)dnscloudflarecloudflare:dnsDNS query analytics: query name, type, response code, and resolver latency.
Firewall / WAF Eventsfirewallcloudflaresecurity_eventWeb Application Firewall events: blocked requests, challenges, bot detections, and rate limit triggers.
Account Audit Logsauditcloudflaresecurity_eventAccount-level audit trail: user logins, setting changes, API token usage, and zone modifications.
Zero Trust Access Logs (off by default)iamcloudflaresecurity_eventZero Trust Access authentication events: user access decisions, identity provider logins, and policy evaluations.
Zero Trust Gateway Logs (off by default)networkcloudflaresecurity_eventZero Trust Gateway activity: HTTP filtering, DNS filtering, network session logs, and DLP detections.
Workers & Pages Logsapplicationcloudflare_workerscloudflare:workers:logApplication logs from Cloudflare Workers and Pages via OTLP push. console.log output, exceptions, and custom log events streamed in real-time.
Workers & Pages Tracesapplicationcloudflare_workersobservability_traceCloudflare Workers and Pages execution traces: invocation timing, subrequests, KV/D1 operations, and errors. Received via OTLP push from Cloudflare Observability.
Pages Deployments (off by default)cicdcloudflare_pagescicd_pipelineCloudflare Pages deployment events: build status, deployment stages, environment, and commit info.
Healthcheck Events (off by default)applicationcloudflareobservability_alertOrigin health monitoring: healthcheck status changes, latency measurements, and failure reasons.

The index is the kind of data and the source is the product, so detection rules for that kind of data find Cloudflare without changes.

Note: Workers and Pages logs and traces are pushed by Cloudflare over OTLP. After you save, LogPulse shows the OTLP endpoints and an API key to set in Cloudflare Observability; no Cloudflare credential is needed for this part.
Note: API polling reads the infrastructure data sources every five minutes by default.

Fields and data models

Data modelWhat you get
Application LogsWorkers and Pages application logs pushed in real time over OTLP: console output, exceptions and custom events.
Security EventFirewall and WAF events, audit logs, Zero Trust Access and Gateway logs with standard security fields.
Trace EventWorkers and Pages execution traces and OTLP spans with service name, duration, status and error details.
CI/CD PipelinePages deployments with build status, stages, git trigger and environment.
Observability AlertHealthcheck status changes with origin address, failure reasons and check regions.

Events are mapped to the data models above, with the same field names as other sources of the same kind. See field names.

3. Check the data

The first events arrive within a few minutes. Check what came in:

earliest=-1h index IN (web, dns, firewall, audit, iam, network, application, cicd) source IN (cloudflare, cloudflare_workers, cloudflare_pages)
| stats count by index, source, sourcetype

The integration page in LogPulse shows when it last read events and the last error, if any.

Troubleshooting

The connection test names what is wrong. These are the answers you are most likely to see.

What you seeWhat to do
API Token is invalid, expired, or revoked.Create a new token at Cloudflare Dashboard, My Profile, API Tokens.
Token lacks "Account Audit Logs: Read" permission. Add this permission to the API token.Edit the token and add the read permission for each data source you turned on.
Zone not found or not accessible.Copy the Zone ID from the overview page of the zone, and include that zone in the resources of the token.
The test passes but no events arrive.Run the search above over a longer time. No results: check on the integration page that the data source is switched on and when it last read events. Cloudflare may also simply have had nothing new.

Frequently asked questions

How do I send Cloudflare logs to LogPulse?
Add the Cloudflare cloud integration under Configure, Sources, Cloud in LogPulse and fill in Cloudflare API Token, Account ID. LogPulse reads the Cloudflare API and OTLP push itself, every five minutes by default; there is nothing to install.
Which permissions does LogPulse need in Cloudflare?
OTLP push: no Cloudflare credentials needed, only Cloudflare Observability pointed at LogPulse. API polling: a Cloudflare API Token with read permission for the data sources you turn on. API polling: the Account ID (in the dashboard sidebar). Optional: a Zone ID for the zone-level data sources (HTTP logs, firewall, DNS, healthchecks). Read access is enough for collecting logs.
Which index does Cloudflare data go to?
The index is the kind of data: web, dns, firewall, audit, iam, network, application, cicd. The source is the product: cloudflare, cloudflare_workers, cloudflare_pages. Each data source has its own sourcetype, listed on this page.
Which data models does Cloudflare fill?
Application Logs, Security Event, Trace Event, CI/CD Pipeline, Observability Alert. Detection rules and dashboards written for a data model work on Cloudflare without changes.
Why is a data source off by default?
To keep your daily ingest down until you need it: DNS Query Logs, Zero Trust Access Logs, Zero Trust Gateway Logs, Pages Deployments, Healthcheck Events are high volume or of use to fewer teams. Tick the data source in the integration to switch it on.
Do I need a Cloudflare API token for Workers logs?
No. Workers and Pages logs and traces are pushed by Cloudflare over OTLP with an API key that LogPulse generates. The API token is only for the polled data sources such as HTTP request logs and firewall events.