[SR-Users] Presence module with external MWI

PICCORO McKAY Lenz mckaygerhard at gmail.com
Mon Feb 18 22:58:49 CET 2019


umm that sounds interesting: i have in my cfg file presence
configured, and also configure asterisk realtime,  and my led in
phones does not get on and only works if i setup the phones only with
asterisk!

here my configuration:

route[PRESENCE] {
    if(!is_method("PUBLISH|SUBSCRIBE")) {
    xlog("[$Tf] presence rule: not forwarding sub/pub requests??????\n");
    return;
    }

    if(is_method("SUBSCRIBE") && $hdr(Event)=="message-summary") {
    route(TOVOICEMAIL);
    # returns here if no voicemail server is configured
    sl_send_reply("404", "No voicemail service");
    xlog("[$Tf] presence rule: not forwarding voicemail requests??????\n");
    exit;
    }

#!ifdef WITH_PRESENCE
    if (!t_newtran()) {
    sl_reply_error();
    xlog("[$Tf] presence rule: error??????\n");
    exit;
    }

    if(is_method("PUBLISH")) {
    handle_publish();
    t_release();
    } else if(is_method("SUBSCRIBE")) {
    handle_subscribe();
    t_release();
    }
    exit;
#!endif

    # if presence enabled, this part will not be executed
    if (is_method("PUBLISH") || $rU==$null) {
    sl_send_reply("404", "Not here");
    xlog("[$Tf] presence rule:  nothere publish requests??????\n");
    exit;
    }
    return;
}


Lenz McKAY Gerardo (PICCORO)
http://qgqlochekone.blogspot.com

El lun., 18 de feb. de 2019 a la(s) 17:48, Charles Chance
(charles.chance at sipcentric.com) escribió:
>
> Hi Trevor,
>
> Typically, your voicemail server would send a publish to Kamailio, which would then notify each of the watchers.
>
> A call to handle_publish() should be all that’s required.
>
> https://www.kamailio.org/docs/modules/stable/modules/presence.html#presence.f.handle_publish
>
> Cheers,
>
> Charles
>
> On Mon, 18 Feb 2019 at 21:07, Trevor Peirce <tpeirce-lists at acrovoice.ca> wrote:
>>
>> Hello,
>>
>> Looking for pointers as to what I'm missing here.
>>
>> I'm using the presence module to allow UAs to subscribe to
>> message-summary events.  I can see the entries appearing in the
>> active_watchers table and I see subscription renewals increment the cseq
>> columns so I'm satisfied this part is working well.
>>
>> I'm having trouble finding out how to tell Kamailio about a change to
>> the message-summary so that it can notify the watchers.
>>
>> The pua module seems to provide a way but it doesn't seem to work with
>> the subscriptions set up by the presence module.  The presence module
>> itself does not seem to offer any RPCs capable of doing this.
>>
>> Appreciate any pointers!
>>
>> Thanks,
>>
>> --
>> Trevor Peirce
>> AcroVoice Solutions Inc
>>
>>
>> _______________________________________________
>> Kamailio (SER) - Users Mailing List
>> sr-users at lists.kamailio.org
>> https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
>
> --
> Charles Chance
> Managing Director
>
> t. 0330 120 1200    m. 07932 063 891
>
> Sipcentric Ltd. Company registered in England & Wales no. 7365592. Registered office: Faraday Wharf, Innovation Birmingham Campus, Holt Street, Birmingham Science Park, Birmingham B7 4BB.
> _______________________________________________
> Kamailio (SER) - Users Mailing List
> sr-users at lists.kamailio.org
> https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users



More information about the sr-users mailing list