Discussions

Ask a Question
Back to All

Streaming API - session start error

Hi, I am getting the following response when I try to start a session

{"code":400,"message":"peer start failed,please check the answer"}, below is my code for your reference


peerConnection.createAnswer().then(createdDescription).catch(errorHandler);

createdDescription = function(description) {

peerConnection.setLocalDescription(description).then(() => {


	me.syncCall('<https://api.heygen.com/v1/streaming.start'>, 'post', JSON.stringify({ session_id: me.session.data.session_id, sdp : peerConnection.localDescription }))  
  }).catch(errorHandler);  
}