Hello,
Is there any way in Kamailio to get the profile values the current dialog is part of?
For example, I have one dialog with the following profiles:
profiles: { { test: abcd } test: 1234 }
I need in the reply route to get the values for the test dialog profile. (abcd, 1234). I know I can use get_profile_size, but that will give the number of profiles of the current dialog, but I need the values to loop through.
Thanks.
Hello,
if there is a rpc command for it, then maybe you can leverage the jsonrpc_exec() from jsonrpcs module and walk through json using jansson.
If not, then such feature has to be added within the c code and exported as function to config.
Cheers, Daniel
On 18.06.20 13:44, Ilie Soltanici wrote:
Hello,
Is there any way in Kamailio to get the profile values the current dialog is part of?
For example, I have one dialog with the following profiles:
profiles: { { test: abcd } test: 1234 }
I need in the reply route to get the values for the test dialog profile. (abcd, 1234). I know I can use get_profile_size, but that will give the number of profiles of the current dialog, but I need the values to loop through.
Thanks.
Kamailio (SER) - Users Mailing List sr-users@lists.kamailio.org https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
Very good idea with rpc command or json module, never mind about it. For the moment I will try with that, but any way will be good to have a function in the dialog module for that.
Thanks.
În mie., 24 iun. 2020 la 09:45, Daniel-Constantin Mierla miconda@gmail.com a scris:
Hello,
if there is a rpc command for it, then maybe you can leverage the jsonrpc_exec() from jsonrpcs module and walk through json using jansson.
If not, then such feature has to be added within the c code and exported as function to config.
Cheers, Daniel On 18.06.20 13:44, Ilie Soltanici wrote:
Hello,
Is there any way in Kamailio to get the profile values the current dialog is part of?
For example, I have one dialog with the following profiles:
profiles: { { test: abcd } test: 1234 }
I need in the reply route to get the values for the test dialog profile. (abcd, 1234). I know I can use get_profile_size, but that will give the number of profiles of the current dialog, but I need the values to loop through.
Thanks.
Kamailio (SER) - Users Mailing Listsr-users@lists.kamailio.orghttps://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
-- Daniel-Constantin Mierla -- www.asipto.comwww.twitter.com/miconda -- www.linkedin.com/in/miconda Funding: https://www.paypal.me/dcmierla