Just for reference, if someone else stumbles across this post, here is the background of my problem:
I am using AppDaemon for all automations. The reason is that I feel comfortable programming in Python, and that it is quite easy to produce relatively complex automations with this. For me this is easier that writing complex yaml files.
AppDaemon runs in a separate docker container, and HomeAssistant already uses Mosquitto for some devices that are integrated using mqtt. So the link to the broker already is established in HA.
In principle, AppDaemon can access the Mosquitto broker directly. However, this requires multiple inheritance with its own complications, and the docker network configuration would become more complicated in my particular case (AD cannot access the broker as it is now). So listening to the HA-forwarded events (which I need to do anyways) is easier.