Skip to main content

Cloudflare: Permissions and setup

Learn how to connect Cloudflare with Atomicwork to automate alerts, policies, and team onboarding.

R
Written by Riya Sebastian
Updated over a week ago

The Atomicwork-Cloudflare integration brings powerful infrastructure monitoring and alerting capabilities directly to your IT service management workflows. This integration allows your team to automate incident response, manage notification policies, and streamline team onboarding by connecting Cloudflare's Alerting API with Atomicwork's workflow engine.

Permissions

To set up the integration, you need a scoped Cloudflare API Token. Do not use a Global API Key. The API token must be generated from the Cloudflare dashboard with the following specific permissions:

Permission

Level

Needed For

Account Settings

Read

Listing accounts and validating the connection.

Notifications

Read

Listing alert types, alert history, policies, webhooks, and PagerDuty services.

Notifications

Write

Creating, updating, and deleting notification policies.

Member

Read

Listing account members and roles.

Member

Write

Inviting new members to the account.

Setup

Create a Cloudflare API token

  1. Log in to the Cloudflare dashboard.

  2. Navigate to My Profile > API Tokens > Create Token.

  3. Choose Create Custom Token.

  4. Configure the permissions listed in the table above.

  5. Set the Account Resources to include the specific accounts you want to manage through Atomicwork.

  6. Click Continue to summary, and then click Create Token.

  7. Copy the generated token immediately and store it securely. You will not be able to view this token again.

Connect Cloudflare in Atomicwork

  1. Navigate to the Integrations page in your Atomicwork workspace.

  2. Find Cloudflare under the Security & Infrastructure category.

  3. Enter your copied API Token in the setup form.

  4. Click Connect to authenticate and complete the setup.

Supported workflow actions

  • List Accounts: Retrieve all Cloudflare accounts accessible with the API token.

  • Alert Management: Use List Alert Types and List Alert History to monitor infrastructure alerts and automatically create internal tickets or escalate issues.

  • Notification Policies: Use List Notification Policies, Get Notification Policy, Create Notification Policy, Update Notification Policy, and Delete Notification Policy to allow DevOps teams to manage routing rules via self-service requests.

  • List Webhooks: Retrieve webhook destinations for notifications.

  • Member Management: Use List Members and Invite Member to automate adding new engineers to the Cloudflare account during employee onboarding.

  • Call API: A generic action to make custom API calls to any Cloudflare v4 endpoint (supports GET, POST, PUT, PATCH, DELETE) for advanced requirements like DNS record management or firewall rules.

Troubleshooting

If you encounter issues while setting up or using the Cloudflare integration, refer to the common errors below:

Error Message

Cause

Resolution

Invalid Cloudflare API token

The API token is incorrect, expired, or revoked.

Generate a new API token in the Cloudflare dashboard and reconnect.

Invalid Cloudflare configuration. Please verify your API token has Account Settings (Read) permission.

The token is valid but lacks the minimum required permission to validate the connection.

Edit the API token in Cloudflare and add the Account > Account Settings > Read permission.

Cloudflare ping failed

The Cloudflare API returned a 5xx server error.

This is a transient Cloudflare issue. Retry the connection after a few minutes.

Account not found / Policy not found

The specified ID does not exist or the token lacks access.

Verify the account or policy ID and ensure your token permissions cover the requested resource.

Did this answer your question?