I have been trying to make a raffle platform with the Chainlink automation.

I can see the time-based upkeep can have only one cron job, But when the raffles are created in the platform, each of them has different deadline to generate a random number with chainlink VRF.

Would you guys have any idea of how to register multiple cron jobs ? or any solution for that?

1 Answer 1


One option is to have a couple of values for the raffles, a hasRun boolean and a runsAt time.

You could create one automation job that checks all the raffles that haven't run and then runs them if they have met their runsAt time.

Alternatively, if you want a unique automation for each raffle, you should look into registering the upkeeps programmatically.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.