include additional params on SIP INFO to start recording

This commit is contained in:
Dave Horton
2022-06-22 10:08:20 -04:00
parent 16284b58a3
commit 72913560af

View File

@@ -94,6 +94,10 @@ class CallSession extends Emitter {
return this.callInfo.direction;
}
get applicationSid() {
return this.callInfo.applicationSid;
}
/**
* SIP call-id for the call
*/
@@ -302,7 +306,10 @@ class CallSession extends Emitter {
headers: {
'X-Reason': 'startCallRecording',
'X-Srs-Url': siprecServerURL,
'X-Srs-Recording-ID': recordingID
'X-Srs-Recording-ID': recordingID,
'X-Call-Sid': this.callSid,
'X-Account-Sid': this.accountSid,
'X-Application-Sid': this.applicationSid,
}
});
if (res.status === 200) return true;