Complex automations using purely code (javascript/nodejs), is there a way?

Hey all,

Does anyone know if there is some way to create automations using pure code? I dont mean configs like yaml, i mean actual code/script like using javascript.

Im aware of appdaemon which allows automation creation using python (havent used it yet, but i might give it a try if i cant find anything else), im looking for something similar with JavaScript/Typescript. I keep seeing this thwerks/NodeJS-Home-Assistant-Framework repo linked in few places, but it seems to be removed. Does anyone have any other suggestions for coding up automations?

Please note, this question is not actually about if coding automations is a good idea or not, how/if automation UI, yaml and alternatives like node red is so great or not. This is purely about trying to see what other options there are in terms of pure coding/scripting to be able to get more powerful automations (and more granular control) for those who are comfortable writing code.

Also aware of the HA wrapper: GitHub - mririgoyen/homeassistant_node: Home Assistant Node.js library

But is there an easy way to use the api and write automations that are running on the HA instance.

Easy and inside HA? Basically, no.

You can check out