DEVOPS

Auto-open a removal PR when a flag hits 100% rollout

Triggered by a flag-management webhook the moment a flag reaches full rollout, it waits out a soak period, confirms no error spike.

CategoryDevOps
Enginesim
Difficultyadvanced
Triggerwebhook
Steps6
Setup~25 min

How it runs

The automated pipeline, trigger to output.

  • TriggerFlag-reached-100% webhookHTTP webhook
  • LogicHold for the soak window
  • ActionCheck Sentry for new errors on pathSentrySentry
  • LogicProceed only if error check is clean
  • ActionGenerate enabled-path removal diffOpenAI
  • OutputOpen removal PR with evidenceGitHubGitHub

What it does

Reacts to the exact event that makes a flag removable: full rollout. When a flag flips to 100% enabled, this workflow holds for a configured soak window, verifies the rollout did not introduce new errors, and only then opens a PR that deletes the flag and keeps the now-permanent behavior.

When to use it

When your flag platform emits rollout-state webhooks and you want removal PRs to appear automatically at the right moment rather than on a fixed schedule. The soak-plus-error-check guard keeps it from proposing removal of a flag you might still need to roll back.

How it works

  1. 1A webhook fires when a flag reaches 100% rollout.
  2. 2A logic step starts a soak timer for the configured window.
  3. 3After the soak, a Sentry query checks for any new error signature tied to the flagged code path.
  4. 4A logic gate proceeds only if the error check is clean.
  5. 5An OpenAI step generates the diff that removes the gate and keeps the enabled branch.
  6. 6A GitHub action opens the removal PR with the soak and error evidence in the description.

Set it up

What you configure once, before turning it on.

  1. 1
    Connect HTTP webhookTrigger any URL on agent actions.
  2. 2
    Connect SentryErrors, performance, releases.
  3. 3
    Connect OpenAIModels, embeddings, files.
  4. 4
    Connect GitHubRepos, issues, pull requests, actions.
  5. 5
    Set each agent's modelWe leave models unset so you pick the tier — fast + cheap, or top-quality.
  6. 6
    Tune it to your dataEdit the prompts, filters, and field mappings so it matches how your team works.
  7. 7
    Test, then turn it onRun once against a sample, confirm the output, then enable the trigger.

Run this workflow in your colony.

14-day trial. No DevOps. No Sales call. Provisioned in under a minute.