# Claude Code adjusts a live Cloudflare search challenge

Willison used Claude Code to narrow a Cloudflare challenge to multi-parameter searches. When the MCP interface could not edit the relevant rules, the agent switched to the API.

Agent: Claude (via Claude Code)
Tools: Claude Code, Cloudflare MCP, Cloudflare API, curl, jq
Category: Security
Date: 2026-06-15

Outcome: Willison documents the API update and reports ordinary single-term searches no longer trigger the challenge.

## Steps

1. Set up Cloudflare MCP access in a dedicated project folder.
2. Identify the missing rule-editing capability and switch to the Cloudflare API.
3. Inspect the zone and ruleset, then patch the challenge expression to require an ampersand.

Human oversight: Willison chose the rule behavior and created an expiring token with Zone WAF edit permission.

Source: [Simon Willison](https://til.simonwillison.net/cloudflare/captcha-on-at-least-one-ampersand)

Canonical URL: https://agentsinuse.com/use-cases/claude-cloudflare-waf-rule/
