Users of PortaSwitch voice calls services can record their conversations to play them back later.
Calls initiated from IP phones and via the Call Control API are recorded in the same way. When the call recording feature is activated for a phone line, PortaSIP writes a copy of the RTP stream to a local disk for each incoming or outgoing call. The media stream then passes to the call recording server (a dedicated server is recommended since voice conversion is a resource-intensive task) where it is transformed into the .wav/.mp3 format, playable on any computer or smartphone. When the conversion is completed (this may take a few minutes), a link for conversation playback is available on the xDRs panel.
The process happens as follows:
- Someone dials the phone number that is assigned to one of your customers. The call passes to your network and arrives at PortaSIP.
- PortaSIP sends a request to PortaBilling to obtain call authorization and routing.
- PortaBilling determines that the account set to receive the call has the Call Recording feature activated.
- PortaSIP proxies the media stream for this call (overriding the RTP Proxying policy for the incoming DID vendor) and stores a copy of it in a local file.
- Once the call disconnects, the call recording server retrieves the file and the audio conversion begins.
- When the conversion process finishes, the xDR information about this call updates in PortaBilling and a “Play” link appears on the xDRs panel.
- When a user clicks on the link, their browser redirects to download the converted .wav/.mp3 file from the call recording server.
The PBX end users can hide call recordings from their colleagues on the self-care interface. To do this they can enable the Show the call recording to myself only option on their self-care interface.
By default, this option is hidden from the end users on the self-care interface. To allow specific accounts to manage the Show the call recording to myself only option, the administrator performs the following steps:
- Creates a new access role for accounts with permission to modify the Show the call recording to myself only option.
- Assigns this access role to accounts who are authorized to hide call recordings on their self-care interface.
_solution/The%20Show%20the%20call%20recording%20to%20myself%20only%20option.png)
The end users can receive call recordings in the email notifications after the call is ended. To enable a specific account to receive call recordings in the email notifications, an administrator performs the following:
- Log in to the Configuration server web interface and set the RecordsDelivery.Enabled option to Yes.
- Log in to the PortaBilling web interface and enable the New call recording is available notification in the customer class assigned to a specific customer.
- Enable the Send the call recording via email option for a specific account: go to Voice call configuration > Call recording > turn on the Send the call recording via email toggle. Then the end user can manage the Send the call recording via email option on their self-care interface.
The end-users will receive email notifications if the email address is specified in the Account > Personal info > General info > Email.
Business customers may want to keep records of conversations within their CRM system to preserve the history of communication with their clients. To retrieve a call record from the system, and store it in the CRM, an external app can be used. The system will notify the external app when a new recording is ready by sending the corresponding event. To configure sending these events, create an event handler and subscribe it to the Notification/Reports/NewCallRecordingIsAvailable web event.
Note that the external app can be built using PortaOne Workflows or other methods, such as custom development.
You can find detailed information on how to configure the call recording functionality in the Call recording configuration handbook.
Monetization
To monetize the call recording service, you can:
- Charge your customers based on the total duration of recorded calls. Find the configuration steps here. Note that the instructions cover both call recording and transcription services. If you're offering only a recording, simply skip the transcription steps.
- Offer unlimited service as an add-on product for a subscription fee. Find the corresponding step-by-step instructions here.
Important notes
- The RTP stream must pass via the PortaSIP server in order for the server to record it, so please allocate sufficient bandwidth for PortaSIP to process these calls – without compromising sound quality.
- If a Call Recording instance isn’t configured to use .mp3, it converts the RTP stream to a .wav file, by default.
- A user who initiates an attended call transfer can obtain a recording of the transferred call and recordings of all subsequently transferred calls if:
- the Auto record redirected calls option is enabled for this user’s account (Account > Services > Service configuration > Voice calls > Call recording > Auto record redirected calls), and
- the recording started before the user transferred the call.For example, user A calls user B. User B has Allow to start/stop recording manually enabled and starts to record the call. Afterward, user B puts user A on hold, calls user C, and initiates the call transfer. When user A successfully connects to user C, user B is disconnected. When the call between users A and C ends, user B obtains the whole call recording: their call with user A and the call between users A and C (after user B has left the call).
- A user cannot obtain a call recording when CDR is not created for the corresponding account. For instance, in a call scenario when a user retrieves a parked call on a different IP phone, they cannot obtain a call record using the account where the call was retrieved because no CDR is generated for this account.
Let's consider a call between two users, account A and account B. One of the users (account B) decides to continue the conversation in another room and parks the call, retrieving it on another phone (account C). Now, even though the call recording feature is enabled for account C, the user cannot record this call.
In this case, to record such a call, the user needs to initiate call recording before parking the call, and the record will be available for account B.
- To record incoming calls that are forwarded outside the PortaSwitch network (calls from vendors), enable the Auto record redirected calls option for the account (either directly or at the product level). The recording will be attached to the CDR of the forwarded call.
- To record incoming calls that are forwarded within the PortaSwitch network (on-net calls), enable both the Auto record redirected calls and Auto record incoming calls options for the account (either directly or at the product level). Note that when both options are enabled:
- All incoming calls will be recorded, regardless of whether they are forwarded.
- For forwarded incoming calls from vendors, the same recording will be stored twice: once with the incoming call’s CDR and once with the forwarded call’s CDR.
- To convert the call, the system recognizes the codec used to transport the voice. Therefore, for conversations to record properly, IP phones must be configured to use one of the following suggested codecs: G.711, G.729, G.723, and Opus.
Another solution is to configure the Codec order list attribute in the SIP SDP attributes group in a service policy and then apply that service policy to the accounts. It is important that both IP phones use the same codec for voice transmission.
- Call recording is not available in stand-alone mode.
Single recording for calls with multiple audio streams
MR128Feature added in MR128
Some call scenarios produce multiple audio streams – for example, a transferred or pulled call. PortaSwitch automatically merges all audio streams of such a complex call into a single recording file. Users get one complete recording file, whether downloading it from the self-care web interface or receiving it by email. The same applies to transcriptions – a single, complete transcript is generated for the entire call.
John, a new employee at ABC Company, calls his colleague Sarah to discuss a new contract. While reviewing the terms, they reach the financial details, and Sarah transfers John to Mike from the finance department to go over the numbers.
After the call ends, John downloads a single recording file from the self-care portal. John navigates through the recording to find the specific figures Mike confirmed during the call.
Specifics
- Recordings made before MR128 are not merged and remain available as separate files.
- In a multi-node call recording setup, by default, any available node handles the call recording. To strictly assign each call to one specific call recording node, set the Strict_Call_Per_Node_Processing option to Yes on the Configuration server web interface. This prevents duplicate processing when multiple call recording nodes are active simultaneously.
- PortaSwitch uses internal metafiles to manage call recordings. The metafile format has been updated in MR128. Support for the earlier metafile format is planned to be discontinued in MR131.
- If one or more audio streams cannot be processed, the merged recording file is produced without those streams.
On-demand call recording
The on-demand call recording enables end users to start/stop a call recording at any time during a call. To enable the on-demand call recording, an administrator enables the Allow to start/stop recording manually option in the call recording configuration.
There are two approaches to activating the on-demand call recording:
- By pressing the "Record" button on the IP phone. This approach enables end users with particular IP phone models to activate the on-demand call recording at the push of one button. The main requirement for an IP phone is to send a special SIP INFO request with the header "Record" with "On" and "Off" content. Then you need to assign the call recording to a specific button on your IP phone (for example, Yealink SIP-T28P).
- By dialing DTMF codes. This approach is available for all end users, regardless of the IP phone model they use. To start/stop the recording, the end user dials DTMF codes. The DTMF codes are specified in the dialing rule of PBX type. For example,
the end user dials *44 to start recording during a call and *45 to stop the recording. The administrator can change the default DTMF codes by creating a new dialing rule and assigning it to a customer/account. To change the default prefixes and DTMF codes for on-demand call recording, an administrator performs the following steps:
- Create a customer/account record with enabled dialing rules.
- Create a new dialing rule of PBX type.
- Change the default prefixes and DTMF codes in the dialing rule.
_solution/Change%20service%20codes%20in%20the%20dialing%20rule.png)
The end users can edit default DTMF codes on their self-care interface. To do this, they need to switch to a custom rule on the dialing rules panel.
To play an announcement to users when the on-demand call recording starts/ends, set to “Yes” the MUB2bua.on_demand_CR_playing_prompt option on the Configuration server web interface. By default, the option is set to “Yes” when you install mr101 or a later version from scratch.
Call recording announcement
Businesses can notify everyone on the call that their conversation is being recorded, allowing them to comply with call recording regulations. When call recording starts, all parties hear the "Call recording started" announcement. This ensures that everyone on the call is aware that the call is being recorded.
For example, Mary calls ABC company, where all the calls are recorded automatically. The call is received by the auto attendant, and then it is transferred to the sales hunt group. Peter, the sales agent, picks up the call, and both Mary and Peter hear the "Call recording started" announcement. Later, Peter manually stops the recording during a call since Mary is going to provide some sensitive information such as credit card details. In this case, the "Call recording stopped" announcement is played.
The recording always contains the announcement, ensuring that the call parties are notified of the call recording.
To enable the call recording announcement option for all PBX users, the administrator needs to:
- Open a specific product/add-on product with call recording feature enabled.
- Go to Services > Voice calls > Call recording.
- Turn on the Play the call recording announcement to all toggle switch.
_solution/Call%20recording.png)
The administrator can enable the call recording announcement option for a specific account. To do this, the administrator follows these steps:
- Open a specific account.
- Go to Services > Service configuration > Voice calls > Call recording.
- Turn on the Play the call recording announcement to all toggle switch.
End users can manage whether to play the call recording announcement on their self-care interface (if the administrator enabled it for end users beforehand).
Note that the call recording announcement is available only in English. If you need the announcement in another language, contact PortaOne support team.
Benefit
Businesses comply with call recording regulations by playing a call recording announcement to all call parties.
Multiple call recording instances
You can speed up call recording conversion and reduce the delay between a completed call and the availability of its recording. You can also deploy multiple call recording instances to process calls from PortaSIP in a high-load environment. The load automatically distributes among instances and as a result, customers can access their call recordings earlier.
You can still configure a call recording instance to process calls from several PortaSIPs – and for even higher performance, you can add another call recording instance. There is no restriction on the number of call recording instances you can add. This flexibility helps you to effectively manage your computing resources.
With the update to the new release, your existing call recording service is automatically upgraded. The path to converted files remains unchanged so your administrators and resellers don’t have to adjust their custom applications.
This deployment of several call recording instances adds high availability to your call recording service: if one instance is down or unavailable, the remaining instances continue operations and distribute the load.
With this enhancement, CSPs benefit from increased performance as it enables them to offer their call recording service to more customers and extend their customer base.
CSPs can also deploy external storage for call recordings and offer the storage space as a VAS, which will result in additional revenue. They can also grant access to external storage via external apps such as CallCabinet and thereby offer additional features (e.g., voice analytics, reports, etc.) on top of the basic call recording service.
Deployment recommendations
Call recording requires significant CPU and HDD capacity. It involves media stream conversion, which is a resource-intensive task. Moreover, call recordings take up disk space (e.g., 1 hour of recorded conversation takes up 30MB of disk space). Therefore, we recommend that you deploy call recording on a dedicated physical server.
According to our lab tests, a single call recording instance can process approximately 13 hours of call records per minute. Let’s say that 5000 calls are completed simultaneously, with an average call length of 5 minutes. These calls would result in more than 400 hours of call records. In our tests, if just 7 call records can be processed simultaneously, users might wait up to 25 minutes to access call recordings. However, if you deploy three call recording instances, the maximum waiting time decreases to 3.5 minutes. The servers with these specs are used in our lab tests: 2-E5620 @2.40 GHz (8 core), 12GB RAM, RAID 1+0.
Each call recording instance increases performance by 1.5 times. Thus, if one instance processes, on average, 13 hours of call records per minute, then two instances process 20 hours of records, 3 instances – 26 hours of records, etc.
The actual performance greatly depends on the hardware specs and partially depends on the average call duration.
Integration with external call record storage platforms
Service providers often use third-party applications, such as Call Cabinet, to provide additional features for stored call recordings. For example, Call Cabinet is popular for its call encryption, which enhances the security of sensitive data and helps customers comply with local regulations. To use this and other advanced features of Call Cabinet, call recordings must be transferred to and stored within the Call Cabinet system. Call recordings and their metadata – such as call duration, direction, calling and called numbers, H323 conference ID, and custom fields – are first saved in one of PortaSwitch SFTP storages (deployed on dedicated physical or virtual servers). The recordings and metadata files are then securely copied from this SFTP storage to Call Cabinet via the SFTP protocol. This approach is used because transferring large amounts of data via SFTP is much faster than executing API calls for each file.
For service providers:
- Additional revenue by offering extra call recording storage as a value-added service (VAS).
- Compliance with local regulations for recording storage and management.
For customers:
- Long-term call recording storage with extra features.
How it works
- Calls made by users are recorded in PortaSwitch.
- The recordings (.wav or .mp3 files) are saved to the call recording server.
- Call recording files, along with their metadata in JSON format, are copied in bulk to the SFTP storage.
- Third-party applications (e.g., CallCabinet) fetch the recordings and metadata from the SFTP storage. End users can log in to the CallCabinet portal and listen to their recordings.
Configuration
PortaSwitch comes with a Docker image for SFTP storage. You can deploy it on a hardware server or in the cloud. Feel free to contact the PortaOne Support team for assistance.
Once deployed, configure the SFTP storage for the relevant billing environment(s). To do this:
- Go to the Configuration server web interface.
- Navigate to Call Recording > SFTPStorage group and fill in the following parameters:
- enabled – set Yes.
- file_permissions – define the permission mask of the files that are saved to the SFTP storage, e.g., 644.
- meta_file_items – configure this parameter if you wish to retrieve call metadata. These parameters are then analyzed by the Call Cabinet application to locate the relevant call recordings and retrieve them from the SFTP storage.
Entries have the format <name>:<PB_entity.parameter> where <name> is your description of the metadata, <PB_entity> is the name of the database table, and <parameter> is a table column, e.g., CalledParty:CDR_Accounts.CLD.
Supported tables are: CDR_Accounts, Accounts, Customers. Supported columns are: any column from the corresponding table. Select the entry from the list. Click
to add a new entry.
To send the call metadata about the custom fields, specify the entries in the Custom_Fields_Name.name format. For example, to send info about the CallCabinetCustomerGUID option, specify the CallCabinetCustomerGUID:Custom_Fields_Name.CallCabinet_CustomerID. - password – specify the password to access SFTP storage.
- port – specify the SFTP storage port. The default port is 22.
- root_path – specify the destination path on the SFTP storage for call recordings and metadata.
- host – specify the SFTP storage IP address.
- user – specify the user’s username to access SFTP storage.
- Click Verify to save and verify the configuration.
- Click Check/Apply to apply it.
When you apply the configuration, the call recording server restarts. Therefore, apply it during an off-peak period. To configure the call recording service for customers, please refer to the Call recording configuration handbook.
Transcription of call recordings
The transcription of call recordings is an AI-driven service available via the Add-On Mart, which can be offered to the customers who use the call recording feature. The speech-to-text integration allows you to connect to different AI transcription models based on your preferences or the language of the region where you provide your services.
The speech-to-text transcription may be helpful for cloud PBX and call center customers who need to save time when reviewing and noting important details of lengthy conversations.
Once a call is completed and the recording is ready, the conversation will be automatically transcribed and made available for download on the PortaBilling web UI. Additionally, you can use the PortaBilling API to integrate this functionality into your self-care portals, developed in-house or by a third party.
Monetization
To monetize the call transcription service, you can:
- Charge your customers based on the total duration of recorded and transcribed calls.
For example, you can offer "10 hours of recording and transcription for $10 per month." After the quota is depleted, you can charge on a pay-as-you-go basis, e.g., $0.03/minute for recording and $0.05/minute for transcription.
For detailed steps on setting up volume-based pricing, refer to the handbook.
- Offer unlimited service as an add-on product for a subscription fee.
To use the speech-to-text transcription, you need to:
- Sign up for an account with an external service (such as Whisper)
- Subscribe for the corresponding module in Add-on Mart
- Configure the integration:
- Obtain the API key from the external service and enter it on the Add-on Mart module’s Configuration UI
- If it’s the first module you activate, specify the Add-on Mart credentials in PortaBilling
You can find the configuration details for the Speech-to-text (Whisper) module here.
During a conversation with the customer, John, a sales manager, made a deal and promised а 10% discount for the first 3 months of subscription.
As John’s extension has call recording and transcription features enabled, the system immediately processes the recorded dialogue and runs it through the speech-to-text service as soon as their conversation ends. After some time, John needs to re-check the information on the deal he made, so he opens the service provider’s custom self-care portal and finds his call successfully transcribed. He downloads the file which contains the information provided by the customer during their conversation.
- Service providers can offer this feature for a subscription fee to their customers as an extra revenue source.
- End-users can conveniently access important call information in the text format for quick analysis.
_solution/Edit%20default%20DTMF%20codes%20on%20the%20customer%20self-care%20interface.png)

_solution/play%20call%20recording.png)
_solution/Account%20manages%20whether%20to%20play%20the%20call%20recording%20announcement.png)
_solution/External%20SFTP%20storage.png)
