External applications interacting with an Electron app on OS X?


#1

I have an Electron app installed on OS X (Mattermost chat client). I need to call JavaScript functions inside of that Electron app from an external script running on the same machine. Does Electron provide any kind of external IPC or RPC API that I could use for this?

Thanks.


#2

No, Electron doesn’t provide anything like that. But you could spin up an HTTP server inside the Electron app and provide your own?


#3

The Node net module supports servers/clients over Windows Named Pipes / Unix Domain Sockets, that’s a more secure option than HTTP.