It's not currently supported. Further, as the concept of custom actions relates closely to picking in the event system, and since picking is not a concept that is built-in to JavaScript, it's not necessarily obvious how to design a script interface for calling a custom action. They operate in different paradigms.