[Freeswitch-users] Variable issue for setting conference record via API?

Avi Marcus avi at avimarcus.net
Thu May 7 19:37:25 UTC 2020


I'm using javascript to trigger the conference API to record when the
moderator joins.

apiExecute("conference",argv[0] + " recording start
$${recordings_dir}/conf-"+argv[0]+"/${strftime(%Y-%m-%d-%H-%M)}.mp3");

Those variables should be automatically expanded by FS, just like if it was
used in the dialplan?
But it seems they are being treated literally:

2020-05-07 19:25:36.609713 [ERR] mod_shout.c:893 Error opening
$${recordings_dir}/conf-test/${strftime(%Y-%m-%d-%H-%M)}.mp3
2020-05-07 19:25:36.609713 [ERR] conference_record.c:277 Error Opening File
[$${recordings_dir}/conf-test/${strftime(%Y-%m-%d-%H-%M)}.mp3]

Ideas?
Should I expand them myself? I was wondering about wrapping it in an eval,
but that would probably have the same issue. So running an API to get the
results of an eval first...

Thanks,
-Avi Marcus
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20200507/11d586af/attachment.html>


More information about the FreeSWITCH-users mailing list