How To Pass Different Audio Codecs To Symbl Endpoint
Sometimes you need to pass different audio codecs when passing the audio. This example shows how to pass them. The codecs currently supported are:
info
We recommend using OPUS as compared to other codecs because it provides the most flexibility in terms of audio transportation and also has packet retransmission mechanisms like FEC which work well, especially in low-bandwidth scenarios.
Throughout the documentation you'll find various references to these variable names, which you will have to replace with your values:
Key | Description |
---|---|
APP_ID | The application ID you get from the home page of the platform. |
APP_SECRET | The application secret you get from the home page of the platform. |
AUTH_TOKEN | The JWT you get after authentication with Sybml. |
DEFAULT_PHONE_NUMBER | A phone number that you want the API to connect to. Be sure to include the country code. |
EMAIL_ADDRESS | The email address you wish to send the summary email to. |
#
Getting startedThis example runs on node server, so we will use symbl-node
package.
Open .env
file and add your APP_ID
, APP_SECRET
, EMAIL_ADDRESS
.
#
Initialize the SDKLet's start by initialising symbl-node
sdk
#
Connect to EndpointNow after we initialized, we need to start the connection by running
#
Set Up Configuration OptionsSo how do you pass custom codecs? It's as simple as passing custom audio config
If you have a requirement to use a codec not included in the ones above or have any other queries, please drop an e-mail to support@symbl.ai.
info
If you have any questions or concerns about our API, you can join our Support Slack or send us an email at developer@symbl.ai
#
Full Code Example#
Running The ExampleCreate a javascript file named app.js and copy this code into the file. Fill in the placeholder values with the proper values. Use npm to install the required libraries: npm install symbl-node. Now in the terminal run
If successful you should receive a response in the console.
info
If you have any questions or concerns about our API, you can join our Support Slack or send us an email at developer@symbl.ai