Receive Live AI Insights
This example goes over how you can use the Symbl Streaming API to receive Insights, which are what the Symbl API determines to be the most important keywords or phrases used in a conversation. This example uses both the Symbl's Javascript SDK, which is meant to be run using Node.js, and native Javascript which can be run in the browser:
#
ConnectThe first thing we do is connect to the Web Socket using the SDK. If you're using the SDK you can use onInsightResponse
handler after the connection is established, otherwise you'll have to parse the response in the onmessage
callback for the WebSocket.
- Symbl SDK (Node.js)
- Native Javascript
#
TestingCreate 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 uuid
. Now in the terminal run
If successful you should receive a response in the console.
#
TestingOpen up your browser's deveolopment environment and copy this code into the console. Replace the placeholder values with the proper values.
If successful you should receive a response in the console.
#
Handlers Referencehandlers
: This object has the callback functions for different eventsonInsightResponse
: This callback provides you with any of the detected insights in real-time as they are detected. As with theonMessageCallback
this would also return every speaker's insights in case of multiple streams.