Cloudflare Traffic
Monitor Cloudflare traffic for sudden changes and anomalies
What is Cloudflare Traffic Anomaly Monitoring?
Cloudflare Traffic Anomaly Monitoring is a feature that allows you to track sudden changes in your website’s traffic patterns. It analyzes the number of requests to your Cloudflare-protected website and alerts you when there are significant increases or decreases in traffic volume.
Why Monitor Traffic Anomalies?
Monitoring traffic anomalies can help you:
- Detect and respond to potential DDoS attacks
- Identify sudden spikes in legitimate traffic (e.g., from a successful marketing campaign)
- Spot unexpected drops in traffic that might indicate technical issues
How do I set up Cloudflare Traffic Anomaly Monitoring?
Add the Cloudflare resource to your Alerty inventory, and Alerty will begin monitoring it automatically! When Alerty detects a significant change in your traffic patterns, it will send you an alert.
Setting up Cloudflare Traffic Anomaly Monitoring
To monitor Cloudflare traffic anomalies, you’ll need to provide some information:
- Zone ID: You’ll need to provide your Cloudflare Zone ID.
- API Token: You’ll need to create an API token with the appropriate permissions.
Finding Your Zone ID
- Log in to your Cloudflare account.
- Go to the overview page for the domain you want to monitor.
- Scroll down to find your Zone ID.
- Copy this ID and paste it into Alerty when prompted.
Creating an API Token
- Log in to your Cloudflare account.
- Navigate to “My Profile” > “API Tokens”.
- Click “Create Token”.
- Select the “Read all resources” template. This is the recommended option for most users as it provides the necessary permissions with minimal setup.
- (Optional) Adjust the token’s permissions if needed.
- Copy the generated token and paste it into Alerty when prompted.
How It Works
Once set up, Alerty will continuously monitor your Cloudflare traffic data. It uses advanced algorithms to detect:
- Rapid increases in traffic, which could indicate a traffic spike or potential DDoS attack.
- Sudden decreases in traffic, which might suggest technical issues or content problems.
When an anomaly is detected, Alerty will send you an alert with details about the traffic change, allowing you to investigate and respond promptly.
Fine-Grained Access (Advanced)
While we recommend using the “Read all resources” template for most users, Cloudflare does offer options for more granular control over API permissions. This is useful for users who need to restrict access to specific zones or resources.
To create a fine-grained access token:
- Instead of selecting the “Read all resources” template, choose “Create custom token”.
- Under “Permissions”, add the following:
- Zone - Analytics: Read
- Zone - Traffic: Read
- Under “Zone Resources”, you can choose to apply the token to:
- All zones
- Specific zones (you’ll need to enter the Zone IDs)
This approach allows you to create a token with the minimum necessary permissions, enhancing security by limiting the scope of what the token can access. However, it requires more setup and you’ll need to ensure you’ve included all the zones you want to monitor.
Remember, if you use a fine-grained access token, you’ll need to make sure it has access to all the zones you want to monitor in Alerty. If you add new zones later, you may need to update your API token permissions.
For most users, the “Read all resources” template will be simpler to set up and maintain, especially if you’re monitoring multiple zones or frequently add new ones.