This repository was archived by the owner on May 13, 2025. It is now read-only.
This repository was archived by the owner on May 13, 2025. It is now read-only.
TypeError: device.audio.addProcessor is not a function #255
Open
Description
When i am trying to add new audio processor show the following error
TypeError: device.audio.addProcessor is not a function
see example code:
function intitializeDevice() {
logDiv.classList.remove("hide");
log("Initializing device");
device = new Twilio.Device(token, {
logLevel:1,
// Set Opus as our preferred codec. Opus generally performs better, requiring less bandwidth and
// providing better audio quality in restrained network conditions.
codecPreferences: ["opus", "pcmu"],
});
addDeviceListeners(device);
const audioProcessor = new CustomAudioProcessor(openAiWs);
device.audio.addProcessor(audioProcessor);
// Device must be registered in order to receive incoming calls
device.register();
}
Metadata
Metadata
Assignees
Labels
No labels