We've Moved! Please visit our new and improved forum over at our new portal: https://portal.plumvoice.com/hc/en-us/community/topics

Plum issue with Record verbatim

Questions and answers about IVR programming for Plum DEV

Moderators: admin, support

Post Reply
hunghnguyen2015
Posts: 3
Joined: Wed Mar 25, 2015 12:50 pm

Plum issue with Record verbatim

Post by hunghnguyen2015 »

From Plum http://www.plumvoice.com/docs/dev/voicexml:tags:record

It says
type: The media format of the resulting recording. Defaults to “audio/basic”. Can also be set to “audio/x-alaw-basic” and “audio/x-wav”.

This is my code for <Record> step
<record name="callerMsg" beep="false" dtmfterm="false" maxtime="${callSession.ivrConfig.maxVoiceMessageLength}s" type="audio/basic" finalsilence="10s">

Expected result: it records successful to wav file and I can playback that file in Windows Media Player or use some tool like Sound Recorder (on Win XP) I can open file and see format

Actual result: it records successful to wav file but I cannot playback that file in Windows Media Player (it complains the codec is not supported...). I used Sound Recorder (on Win XP), open file but it says this is not valid wav format file

Workaround: if I use type of "audio/x-wav" in <record> step everything works fine

My question: is there any setting needed at Plum side to support type of “audio/basic” or “audio/x-alaw-basic”? So that it can record and playback successful

Thanks
Hung

support
Posts: 3632
Joined: Mon Jun 02, 2003 3:47 pm
Location: Boston, MA
Contact:

Re: Plum issue with Record verbatim

Post by support »

Hi Hung,

There is no work necessary to ensure any recordings will play back correctly during the course of a call. No matter what type of recording you create, the platform will always play it back. The issues you see with the encodings stem from when you download the file.

When the type is set to "audio/basic" the recording is a raw ulaw file, not a wav file. Similarly, the "audio/x-alaw-basic" type is a raw alaw file. When you use the "audio/x-wav" type, we convert the recording into a wav file before it is POSTed to you. Programs like Windows Media Player do not play raw files. They only play files have have a supported header-type, such as a wav header.

Regards,
Plum Support

hunghnguyen2015
Posts: 3
Joined: Wed Mar 25, 2015 12:50 pm

Re: Plum issue with Record verbatim

Post by hunghnguyen2015 »

Is there any option that Plum will convert it to wav file in any case (ulaw or alaw)?

support
Posts: 3632
Joined: Mon Jun 02, 2003 3:47 pm
Location: Boston, MA
Contact:

Re: Plum issue with Record verbatim

Post by support »

Hi Hung,

Setting the record's type to "audio/x-wav" will convert the file into a wav file when we would POST the file.

Regards,
Plum Support

hunghnguyen2015
Posts: 3
Joined: Wed Mar 25, 2015 12:50 pm

Re: Plum issue with Record verbatim

Post by hunghnguyen2015 »

I know it but if I want to use alaw but still want to have wav file. Is it possible?

support
Posts: 3632
Joined: Mon Jun 02, 2003 3:47 pm
Location: Boston, MA
Contact:

Re: Plum issue with Record verbatim

Post by support »

Hi Hung,

Unfortunately we do not support saving a-law audio that is packaged as a WAV file. We support saving in three formats:

WAV u-law
Raw headerless u-law
Raw headerless a-law

If you need to encode audio as an a-law WAV file you will need to post the recording to your web server and post process it using a tool such as SoX.

Regards,
Plum Support

Post Reply