These methods allow setting/getting pseudo variable values from Python module.
doc/
subfolder, the README file is autogenerated)Two new methods msg_get_pv and msg_set_pv are added to app_python/python_msgobj.c
In python script, we can call msg.set_pv or msg.get_pv to set/get value from a pseudo variable
class RouteHelper:
def normalize_number(self, msg, number):
ret = number
if number.startswith('00'):
ret = '+' + number[2:]
elif number.startswith('0'):
ret = '+33' + number[1:]
msg.set_pv("$var(normalized_number)", ret)
return 1
def mod_init():
return RouteHelper()
https://github.com/kamailio/kamailio/pull/1612
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or mute the thread.