const holdOptions = {
sessionDescriptionHandlerOptions: {
constraints: {
audio: false, // Set audio to false to put the session on hold
video: false
},
sessionDescriptionHandlerModifiers:false
}
};
session.invite(holdOptions)
.then(() => {
console.log("Session held successfully.");
})
.catch((error) => {
console.error("Failed to hold the session:", error);
});