Is it possible to include a randomness in an expression to trigger a transform header or URL re-write rules.
e.g. when conditions are met, I want apply re-write to a URL 50% of the time
it feels like this should be possible, as the cf.random_seed is available to transform rules. can anyone give me a pointer in how to add randomness to the trigger.
I don’t think it is going to be that easy to do with Transform rules. You might be better using Workers to do this. The best I got with Transform rules was starts_with(to_string(uuidv4(cf.random_seed)), "1") which only would redirect if the generated UUID starts with a 1.