It's possible to send a custom message (with HTML even) to someone with ejabberdctl, but it required an orgy of escaping foo.
Note that the resource (in this example "Psi+") has to be online.
Bug report: https://github.com/processone/ejabberd/issues/804
1 2 | $ ejabberdctl send_stanza_c2s alice example.org "Psi+"\ "<message' 'type=\"chat\"' 'to=\"bob@example.org\"' 'from=\"alice@example.org\"><body>World</body></message>" |