Completed download to trigger WakeOnLan (or batch file)

I want to run Sonarr on a VM and allow my main server to sleep. (and save $$$)
I need a way to wake the server up when Sonarr has some work for it.
Once a file has completed (or once it’s moved or what ever) I’d like to trigger Wake On Lan (maybe with a batch file)

Bonus:: A batch file option could be used for a few different things like e fixing permissions or running media scans in other apps or even alerts.

You can use a custom script (which can be triggered after import) for this, this isn’t something we’d add to Sonarr.

How would a script know what sonarr is doing?

Custom scripts are built into Sonarr, Sonarr can call them (when you configure them) when releases are grabbed or files are imported, etc.

Ok sounds great is there anywhere i can go to learn more?
As a point and click pleb i can’t imagine how i might go about this.

You might be able to find examples via google (including some on the forums), but the docs we have for it are on the wiki.