Calls
Call Recordings
Enabling Applet-Level Call Recording
10 min
enabling applet level call recording overview this guide demonstrates how enterprises can dynamically control call recording within their exotel applet flow using the passthru applet (get request) and recording api (post request) this setup enables selective, event driven recording control — for example, starting the recording before a greeting or ivr prompt and stopping it before agent transfer the implementation combines the passthru applet docid\ cq8k ivzybxezr3xysyps and call recordings docid 3ssnz3g1mgrr4dpdxihsh to allow real time backend triggered recording how it works use passthru applet (get) the passthru applet sends call information such as callsid, from, and to parameters to your backend via a get request backend triggers recording api (post) your backend receives the get request, extracts the callsid, and immediately makes a post call to the recording api to start recording continue call flow the call proceeds through the configured applets (greeting, ivr, gather, etc ) while recording remains active end of flow stop recording at the final stage, another passthru applet sends a get request to your backend endpoint (e g , /stop recording), which triggers a post api call to stop recording this ensures exotel only records the specific portion of the call you need, such as the main interaction, and not hold or transfer periods step by step implementation 1\ configure the passthru applet (start recording) add a passthru applet at the point in the flow where you want to begin recording set the passthru applet’s get url to a backend endpoint like https //yourdomain com/start recording when executed, exotel performs a get request to this endpoint with call details appended as query parameters https //yourdomain com/start recording?callsid=abcd1234efgh5678\&from=%2b919900112233\&to=08088919888\&calltype=outgoing your backend should capture the callsid from this get request quer params 2\ backend invoke start recording api (post) your backend now calls exotel’s recording api using the captured callsid post https //\<your api key> \<your api token>\<subdomain>/v1/accounts/\<your sid>/calls/\<callsid>/recording json example curl location 'https //\<base url>/v1/accounts/\<accountsid>/calls/\<callsid>/recording json' \\ \ header 'content type application/x www form urlencoded' \\ \ data urlencode 'action=start' \\ \ data urlencode 'recordingchannels=dual' \\ \ data urlencode 'recordingformat=mp3 hq' \\ \ data urlencode 'statuscallback=\<status callback url>' \\ \ data urlencode 'leg1recording=true' replace \<your api key> and \<your api token> with the api key and token created by you replace \<your sid> with your “account sid” replace \<subdomain> with the region of your account \<subdomain> of singapore cluster is @api exotel com \<subdomain> of mumbai cluster is @api in exotel com \<your api key> , \<your api token> and \<your sid> are available in the api settings page of your exotel dashboard parameter reference parameter type description action string start or stop to control recording recordingchannels string optional — audio channels • single (default) – both legs mixed • dual – caller/callee recorded separately recordingformat string optional — audio quality • mp3 (default) – standard bitrate • mp3 hq – high bitrate (32 kbps/channel) requires enablement via hello\@exotel com statuscallback url callback endpoint for recording status leg1recording boolean true to record only the first call leg 3\ continue with business applets after triggering the start recording api, your flow continues normally with applets such as greeting applet playback welcome message ivr applet capture user selections gather applet collect input connect applet transfer to agent example flow passthru (get → start recording) → backend (post → start recording api) → greeting → ivr → gather → passthru (get → stop recording) 4\ configure passthru applet (stop recording) at the end of the flow add another passthru applet configured to call a url like https //yourdomain com/stop recording this get request from exotel again includes the callsid your backend receives this get, extracts the callsid, and invokes curl location 'https //\<your api key> \<your api token>\<subdomain>/v1/accounts/\<your sid>/calls/\<callsid>/recording json' \\ \ header 'content type application/x www form urlencoded' \\ \ data urlencode 'action=stop' this cleanly terminates recording at the end of the call recording access dashboard under each call log call detail apis https //developer exotel com/api/make a call api#call details compliance notes the passthru applet always sends a get request to your backend; the enterprise must use post to trigger or stop recording obtain customer consent per regional compliance rules mp3 hq is an optional, on demand feature recordings are stored securely in exotel’s environment example use case scenario a customer support survey where only the ivr interaction is recorded passthru applet sends get to backend → backend triggers start recording (post) ivr runs and records customer input final passthru sends get → backend triggers stop recording (post) before agent connection this ensures only the main customer interaction is captured references passthru applet docid\ cq8k ivzybxezr3xysyps call recordings docid 3ssnz3g1mgrr4dpdxihsh secure call recording docid\ b89h wklywic8phkjcqtt
🤔
Have a question?
Our super-smart AI, knowledgeable support team and an awesome community will get you an answer in a flash.
To ask a question or participate in discussions, you'll need to authenticate first.
