Skip to main content
Cloudflare logo

Overview

Add Cloudflare to any ModuleX agent or workflow. Cloudflare v4 API integration: DNS, WAF lists, zones, firewall rules, load balancer monitors & pools, account discovery. All against api.cloudflare.com/client/v4.
Categories: Developer Tools & Infrastructure · Security · Infrastructure · Networking · Auth: API Token · Actions: 13

Authentication

API Token Authentication

Authenticate using your Cloudflare API Token (recommended)

Required Credentials

FieldDescriptionRequiredFormat
Cloudflare API TokenYour Cloudflare API Token for authenticationYesxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

Available Actions

Parameters

name
string
Zone name filter
status
string
Zone status: active, pending, initializing, moved, deleted, deactivated
account_id
string
Account identifier filter
page
integer
Page number (Default: 1)
per_page
integer
Results per page (max 50 for most endpoints) (Default: 20)
order
string
Sort order: name, status, account.id, account.name
direction
string
Sort direction (asc/desc) (Default: asc)

Response

{
  "additionalProperties": false,
  "properties": {
    "success": {
      "title": "Success",
      "type": "boolean"
    },
    "error": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Error"
    },
    "result": {
      "default": null,
      "title": "Result"
    },
    "total": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Total"
    },
    "page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Page"
    },
    "per_page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Per Page"
    }
  },
  "required": [
    "success"
  ],
  "title": "ListZonesOutput",
  "type": "object"
}

Parameters

zone_id
string
required
Zone identifier
type
string
required
DNS record type (A, AAAA, CNAME, TXT, MX, NS, SRV, etc.)
name
string
required
DNS record name
content
string
required
DNS record content
ttl
integer
TTL (1 = automatic) (Default: 1)
priority
integer
Priority for MX/SRV records
proxied
boolean
Proxy through Cloudflare (Default: false)
comment
string
DNS record comment
tags
array
DNS record tags

Response

{
  "additionalProperties": false,
  "properties": {
    "success": {
      "title": "Success",
      "type": "boolean"
    },
    "error": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Error"
    },
    "result": {
      "default": null,
      "title": "Result"
    },
    "total": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Total"
    },
    "page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Page"
    },
    "per_page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Per Page"
    }
  },
  "required": [
    "success"
  ],
  "title": "CreateDNSRecordOutput",
  "type": "object"
}

Parameters

zone_id
string
required
Zone identifier
record_id
string
required
DNS record identifier
type
string
DNS record type
name
string
DNS record name
content
string
DNS record content
ttl
integer
TTL
priority
integer
Priority for MX/SRV records
proxied
boolean
Proxy through Cloudflare
comment
string
DNS record comment
tags
array
DNS record tags

Response

{
  "additionalProperties": false,
  "properties": {
    "success": {
      "title": "Success",
      "type": "boolean"
    },
    "error": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Error"
    },
    "result": {
      "default": null,
      "title": "Result"
    },
    "total": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Total"
    },
    "page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Page"
    },
    "per_page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Per Page"
    }
  },
  "required": [
    "success"
  ],
  "title": "UpdateDNSRecordOutput",
  "type": "object"
}

Parameters

zone_id
string
required
Zone identifier
record_id
string
required
DNS record identifier to delete

Response

{
  "additionalProperties": false,
  "properties": {
    "success": {
      "title": "Success",
      "type": "boolean"
    },
    "error": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Error"
    },
    "result": {
      "default": null,
      "title": "Result"
    },
    "total": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Total"
    },
    "page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Page"
    },
    "per_page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Per Page"
    }
  },
  "required": [
    "success"
  ],
  "title": "DeleteDNSRecordOutput",
  "type": "object"
}

Parameters

account_id
string
required
Account identifier

Response

{
  "additionalProperties": false,
  "properties": {
    "success": {
      "title": "Success",
      "type": "boolean"
    },
    "error": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Error"
    },
    "result": {
      "default": null,
      "title": "Result"
    },
    "total": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Total"
    },
    "page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Page"
    },
    "per_page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Per Page"
    }
  },
  "required": [
    "success"
  ],
  "title": "ListWAFListsOutput",
  "type": "object"
}

Parameters

account_id
string
required
Account identifier
name
string
required
Name of the list
kind
string
required
List type: ip, redirect, hostname, asn
description
string
Description of the list

Response

{
  "additionalProperties": false,
  "properties": {
    "success": {
      "title": "Success",
      "type": "boolean"
    },
    "error": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Error"
    },
    "result": {
      "default": null,
      "title": "Result"
    },
    "total": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Total"
    },
    "page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Page"
    },
    "per_page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Per Page"
    }
  },
  "required": [
    "success"
  ],
  "title": "CreateWAFListOutput",
  "type": "object"
}

Parameters

account_id
string
required
Account identifier
list_id
string
required
List identifier
description
string
required
New description for the list

Response

{
  "additionalProperties": false,
  "properties": {
    "success": {
      "title": "Success",
      "type": "boolean"
    },
    "error": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Error"
    },
    "result": {
      "default": null,
      "title": "Result"
    },
    "total": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Total"
    },
    "page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Page"
    },
    "per_page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Per Page"
    }
  },
  "required": [
    "success"
  ],
  "title": "UpdateWAFListOutput",
  "type": "object"
}

Parameters

account_id
string
required
Account identifier
list_id
string
required
List identifier to delete

Response

{
  "additionalProperties": false,
  "properties": {
    "success": {
      "title": "Success",
      "type": "boolean"
    },
    "error": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Error"
    },
    "result": {
      "default": null,
      "title": "Result"
    },
    "total": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Total"
    },
    "page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Page"
    },
    "per_page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Per Page"
    }
  },
  "required": [
    "success"
  ],
  "title": "DeleteWAFListOutput",
  "type": "object"
}

Parameters

page
integer
Page number (Default: 1)
per_page
integer
Results per page (max 50 for most endpoints) (Default: 20)
direction
string
Sort direction (asc/desc) (Default: asc)

Response

{
  "additionalProperties": false,
  "properties": {
    "success": {
      "title": "Success",
      "type": "boolean"
    },
    "error": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Error"
    },
    "result": {
      "default": null,
      "title": "Result"
    },
    "total": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Total"
    },
    "page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Page"
    },
    "per_page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Per Page"
    }
  },
  "required": [
    "success"
  ],
  "title": "ListAccountsOutput",
  "type": "object"
}

Parameters

account_id
string
required
Account identifier
page
integer
Page number (Default: 1)
per_page
integer
Results per page (max 50 for most endpoints) (Default: 20)
order
string
Sort: user.first_name, user.last_name, user.email, status (Default: status)
direction
string
Sort direction (asc/desc) (Default: asc)
status
string
Filter by status: accepted, pending, rejected

Response

{
  "additionalProperties": false,
  "properties": {
    "success": {
      "title": "Success",
      "type": "boolean"
    },
    "error": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Error"
    },
    "result": {
      "default": null,
      "title": "Result"
    },
    "total": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Total"
    },
    "page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Page"
    },
    "per_page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Per Page"
    }
  },
  "required": [
    "success"
  ],
  "title": "ListAccountMembersOutput",
  "type": "object"
}

Parameters

zone_id
string
required
Zone identifier
page
integer
Page number (Default: 1)
per_page
integer
Results per page (max 50 for most endpoints) (Default: 25)

Response

{
  "additionalProperties": false,
  "properties": {
    "success": {
      "title": "Success",
      "type": "boolean"
    },
    "error": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Error"
    },
    "result": {
      "default": null,
      "title": "Result"
    },
    "total": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Total"
    },
    "page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Page"
    },
    "per_page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Per Page"
    }
  },
  "required": [
    "success"
  ],
  "title": "ListFirewallRulesOutput",
  "type": "object"
}

Parameters

account_id
string
required
Account identifier
page
integer
Page number (Default: 1)
per_page
integer
Results per page (max 50 for most endpoints) (Default: 25)

Response

{
  "additionalProperties": false,
  "properties": {
    "success": {
      "title": "Success",
      "type": "boolean"
    },
    "error": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Error"
    },
    "result": {
      "default": null,
      "title": "Result"
    },
    "total": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Total"
    },
    "page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Page"
    },
    "per_page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Per Page"
    }
  },
  "required": [
    "success"
  ],
  "title": "ListMonitorsOutput",
  "type": "object"
}

Parameters

account_id
string
required
Account identifier
page
integer
Page number (Default: 1)
per_page
integer
Results per page (max 50 for most endpoints) (Default: 25)

Response

{
  "additionalProperties": false,
  "properties": {
    "success": {
      "title": "Success",
      "type": "boolean"
    },
    "error": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Error"
    },
    "result": {
      "default": null,
      "title": "Result"
    },
    "total": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Total"
    },
    "page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Page"
    },
    "per_page": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "default": null,
      "title": "Per Page"
    }
  },
  "required": [
    "success"
  ],
  "title": "ListPoolsOutput",
  "type": "object"
}

Limits & Quotas

  • Cloudflare wraps every response in {"success", "errors", "messages", "result", "result_info"}. The shared _call helper checks the envelope’s success flag (not just HTTP status), pulls errors[0].message on failure, and lifts result_info pagination (total_count, page, per_page) onto the output’s top-level total/page/per_page fields for list actions.
  • Most list endpoints cap per_page at 50; firewall rules cap at 100.
  • result is open: list endpoints return a JSON array; CRUD endpoints return the object directly. Mirrors the upstream shape.

Algolia

Amazon Web Services

Apify