<record>
Role: <record> gives an option to record the message
Use: The use of <record> is to prompt the user for recording their voice message.
- Number not answered – Say when the number that caller has dialed in is unanswered, then the system will prompt them to leave a voicemail.
Below is a list of recommended attributes that can be used with <record>, each attribute has a specific function and can use certain values.
Attributes
Attribute |
Value |
Default |
action | Callback URL | None |
Method | POST | None |
fileID | VARCHAR | UUID (Universal Unique Identifier |
maxlength (Seconds) | Integer | 180 seconds |
confirmrecording | 0 or 1 | 0 |
If action URL is passed, we will send the recording information in the response to the Callback URL. The recording will be stored on our server and we will provide the link (recordingurl)
“RecordingUrl=”..recordingurl..”&callid=”..UUID..”dialednumber=”..DIALED_NUMBER..”&callerid=”..caller_id_number..”&callername=”..caller_id_name
Example Code to prompt user to record their message:
1 2 3 4 |
<Response> <Say>Please Record your message.</Say> <Record maxLength="30" action="playrecording.xml"/> </Response> |
1 2 3 4 5 |
<Response> <Say>Now listen to what you just recorded.</Say> <Play>http://example.com/recording.mp3</Play> <Say>Goodbye.</Say> </Response> |
1 2 3 4 |
<Response> <Say>Please Record your message.</Say> <Record maxLength="30" confirmrecording ="1" action="playrecording.xml"/> </Response> |