ZIV LABS
Build log

Two of our automations failed after we turned on Bot Fight Mode

On November 21, 2026 we turned on Cloudflare's Bot Fight Mode for ziv-labs.com, and on the same day it most likely stopped our own automation in two places. We kept Bot Fight Mode on in both cases and moved the automation to a path it does not block. This log records what failed, how each fix works, and what we have not confirmed. The references at the end name the records every statement comes from.

Background

The owner changed the settings of ziv-labs.com following Cloudflare's security suggestions, and that turned on Bot Fight Mode. On the Free plan, Bot Fight Mode cannot be turned off for one path.

What happened

1. The weekly video script could not be written

Our weekly video is written from the Radar data on ziv-labs.com. In the weekly-script run on GitHub Actions at 01:04 UTC, fetching https://ziv-labs.com/radar/latest.json returned HTTP 403, and the step that makes the English video failed. The same code had worked on November 14. The review issue only said that the English version could not be made.

The fix (ziv-distribution #176, pull request #177, merged at 07:57 UTC): in Actions, the workflow no longer reads the JSON from the public site. It reads content/radar/ from the ziv-labs.com repository through the GitHub API. The token is a GitHub App installation token that can only read contents, and only in that one repository. The token is given only to the command that reads the Radar data, not to the step where an AI writes the script. When the script runs on a local computer, it still reads the public URL as before. At 08:07 UTC we started weekly-script again by hand, and it succeeded.

2. The post to X could not read the video

At 10:59 UTC the video was sent to YouTube, but the post to X (through Buffer) failed with "Video could not be read from its URL". The video is stored in R2, and its public domain, media.ziv-labs.com, is inside the ziv-labs.com zone. From a local computer, the same URL returned 200. On November 14 the post to X had worked.

The fix (ziv-labs/infra #47, pull request #48, merged at 11:22 UTC and applied with the owner's approval): we turned on the bucket's public development URL on r2.dev, which is outside our zone, with OpenTofu, and changed the video's public URL to it. This setting cannot be deleted, so we added prevent_destroy to it. The r2.dev URL is rate limited, but the video is fetched once a week. At 11:37 UTC we sent the post to X again, and it went through. YouTube already had its marker for this video, so it was not posted twice.

What we decided: keep Bot Fight Mode on, move the path

  • Bot Fight Mode stays on. The owner decided this in both records.
  • Instead of loosening the setting that blocks, we moved each request to a path that is not blocked: the GitHub API for the Radar data, and r2.dev for the video.

What we learned

  • A site-wide bot setting also applies to our own scheduled jobs and to the services we hand our URLs to. A page that opens in a browser on a local computer can still be blocked for them.
  • Changing only the URL made the post to X work, which makes Bot Fight Mode the likely cause. It is likely, not certain.
  • When a job reads our own data, reading it from the repository with a narrow token does not depend on how the public site treats bots.

Rules we keep now

  • Automation in Actions reads our own content from the repository, not from the public site.
  • The token for that read can only read contents of one repository, and it is given only to the command that needs it, never to the AI step.
  • The weekly video, which an outside service fetches, is served from outside the zone that Bot Fight Mode covers.

What we have not checked

  • We have not looked at Cloudflare's security events, so we have not confirmed that Bot Fight Mode blocked these requests.
  • Whether anything else of ours, or of others, is blocked by the same setting: not checked.

References

Our own records (private repositories, named here so the claims above can be traced):

  • ziv-labs/ziv-distribution #175 — the weekly video of November 21: the failed English script, the rerun, the failed post to X and its resend
  • ziv-labs/ziv-distribution #176, PR #177 — the HTTP 403 on the Radar JSON, the Free plan limit, and reading content/radar/ through the GitHub API
  • ziv-labs/infra #47, PR #48 — the video URL moved to the bucket's r2.dev URL with OpenTofu, with prevent_destroy; Bot Fight Mode kept on

Related notes