My concern is how, after LISTENing in psql, I can tell it what to do when the NOTItFY is received.
As far as I am aware you cannot. The docs for psql, and its feature set, with respect to LISTEN, are minimal and basically say psql will print out notifications to stdout (this I'm forced to assume or read the code) and will poll for notifications whenever it sends a query to the server.