Turnstile isn't just for HTML forms. This page shows how to protect a JSON API endpoint that a customer might expose (payment intents, account signup, password reset, etc.).
Solve the widget, then submit. The browser posts JSON to /api/verify, the Worker validates with siteverify, and returns a signed response.
Response will appear here.
A direct curl to /api/verify without a valid Turnstile token gets rejected. Copy-paste this into a terminal to see:
curl -X POST https://turnstile.paulscouncil.com/api/verify \
-H "Content-Type: application/json" \
-H "X-Turnstile-Token: fake-token" \
-d '{"payload":"attempt-from-cli"}'
You'll get {"success":false,"error":"invalid-turnstile-token"}. This is the point - even someone with valid API credentials can't hit the endpoint without proving they came through a real client.
See GET /api/gentle - open by default, but requires a Turnstile token if you've made more than 5 requests in the last minute from your IP.
Refresh /api/gentle 6+ times quickly to trip the escalation.