Welcome to the community!
This FAQ might help get you started. It covers both scheduling and custom code: