GenServer is the typical Actor abstraction in Erlang and Elixir. I’ve used one for talking to my Elgato Keylights in the lightswitch project. I made it sort of dumb. It was a quick job so I want to improve it in a few ways. Make it not need to pull the new state from lights before sending commands. Pull state in the background occasionally to keep relatively up-to-date. Always fetch status after sending commands.