Using Kamailio 4.2-dev and MSILO, is it possible to "toggle" the auto- notification reply MESSAGE using something similar to the following where "$var(msilo_reply)" is emtpy at startup (or are there suggestions for a better method):
modparam("msilo", "from_address", "$var(msilo_reply)") ...
if(CONDITION WHERE I WANT THE AUTO-REPLY RETURNS POSITIVE) { $var(msilo_reply)="$rU@example.net"; } m_store($rU) ...
My use case is that I would like the auto-notification reply to occur in some instances, but not others. I also do not want to create a loop where the auto-notification replies are also stored. I was originally using a simple test: if(src_ip!=myself), but I have begun to use the IMC module as well as the EXEC module and these MESSAGEs appear to originate from "myself."
Looking at the MSILO documentation I see there is "extra_hdrs(string)," but this appears to be designed to add headers to dumped MESSAGEs. I was hoping there would be a way to add a custom header to the auto-notification, on which I could filter/drop generated replies earlier in the route, but it doesn't appear that this exists.
My preference for the best-case scenario would be to control the generation of the auto-notification reply in the first place rather than having to add a control to detect the reply and drop it.
Thanks in advance for any recommendations.