[Freeswitch-users] Voice to email

Karl Schmidt karl at xtronics.com
Thu Jul 25 23:34:53 MSD 2013


This turns out to be utterly simple - no need for an external script - much better than phone based 
voicemail:

  <include>
  <extension name="my_voicemail">
     <condition field="destination_number" expression="^.*$">
       <action application="playback" data="mysounds/answer.wav"/>
       <action application="set" data="file=/home/freeswitch/voicemail/${strepoch()}.wav"/>
       <action application="record" data="${file} 300 100 5"/>
       <action application="sleep" data="30"/>
<action application="system" data='echo "See attached Voice-mail message" | mutt -a ${file} -s 
"Voicemail Message" -- user at example.com' />
     </condition>
  </extension>
  </include>

You can add a second system call to delete after you send if it makes your day.

<action application="system" data='rm -f ${file}'/>


--------------------------------------------------------------------------------
Karl Schmidt                                  EMail Karl at xtronics.com
Transtronics, Inc.                              WEB http://secure.transtronics.com
3209 West 9th Street                             Ph (785) 841-3089
Lawrence, KS 66049                              FAX (785) 841-0434

The only valid market survey is a signed purchase order. -- Jay Last
--------------------------------------------------------------------------------



Join us at ClueCon 2011 Aug 9-11, 2011
More information about the FreeSWITCH-users mailing list