Skip to content

VoiceML: <RecordCall>

The <RecordCall> action configures the call for call recording, either when the call is answered or when the call is bridged. This action executes immediately and does not block the call.

Only one call recording can be active on a call at once. If an existing call recording has started, this action will be silently ignored. If a call recording has not started and you call <RecordCall> more than once, the last set of attributes will be used.

To instead record one party of the call and wait until the recording is completed (eg for voicemail), use <Record> instead.

Compliance Notice

You need to comply with certain laws and regulations, including those regarding obtaining consent to record. Enfonica recommends that you consult with your legal counsel to make sure that you are complying with all applicable laws in connection with communications you record or store using Enfonica.

Attributes

The <RecordCall> action supports the following attributes.

Attribute Allowed Values Default
PostProcessing trim-silence
RecordingReadyUri absolute or relative URI
Trigger answer, bridge answer
Transcribe disabled, default disabled
TranscriptionReadyUri absolute or relative URI -

PostProcessing

The PostProcessing attribute can be used to instruct Enfonica to modify the recording. The following options are available.

Value Description
trim-silence Removes any silence from the start and end of the recording.

RecordingReadyUri

The RecordingReadyUri attribute specifies the URI to send the recording ready webhook to. As there is post-processing and other tasks that must run on the recording after completion, the recording may not be available immediately when the <RecordCall> action completes. You should use the recording ready webhook to be notified when the recording is available. It is typically available very quickly.

The recording ready webhook body contains a JSON serialized enfonica.voice.v1beta1.Recording instance. For successful recordings, this will contain the URIs where you can download the recording in WAV and MP3 formats.

Trigger

The Trigger attribute specifies when recording should start. The permitted values are:

  • answer - start recording when the call is answered. If the call is already answered, starts recording straight away.
  • bridge - start recording when the call is bridged (eg when two people are speaking with each other).

Transcribe

The Transcribe attribute specifies how the recording should be transcribed. To transcribe the recording, specify default as the value, which indicates that you would like to use Enfonica's default transcription service. Additional options may become available in the future.

Please note that transcription incurs additional charges.

TranscriptionReadyUri

The TranscriptionReadyUri attribute specifies the URI to send the transcription ready webhook to. As transcription can take some time to transcribe the audio, you should use this webhook to be notified when the transcription is available. It is typically available in 10-30 seconds for a short recording or several minutes for longer recordings.

Body

No actions can be nested within the <RecordCall> action.