Skip to content

Commit

Permalink
feat: siprect custom headers (#95)
Browse files Browse the repository at this point in the history
* feat: siprect custom headers

* update siprec client utils

* wip
  • Loading branch information
xquanluu authored and Matt Preskett committed Aug 17, 2023
1 parent bb17137 commit 85c7192
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 9 deletions.
4 changes: 3 additions & 1 deletion lib/call-session.js
Original file line number Diff line number Diff line change
Expand Up @@ -733,6 +733,7 @@ Duration=${payload.duration} `
const to = this.req.getParsedHeader('To');
const aorFrom = from.uri;
const aorTo = to.uri;
const headers = contentType === 'application/json' && req.body ? JSON.parse(req.body) : {};
this.logger.info({to, from}, 'startCallRecording request for an outbound call');

const srsUrl = req.get('X-Srs-Url');
Expand Down Expand Up @@ -771,7 +772,8 @@ Duration=${payload.duration} `
del: this.del,
blockMedia: this.blockMedia,
unblockMedia: this.unblockMedia,
unsubscribe: this.unsubscribe
unsubscribe: this.unsubscribe,
headers
}));
try {
succeeded = (await Promise.all(
Expand Down
14 changes: 7 additions & 7 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
"@jambonz/http-health-check": "^0.0.1",
"@jambonz/mw-registrar": "0.2.4",
"@jambonz/rtpengine-utils": "^0.4.3",
"@jambonz/siprec-client-utils": "^0.2.5",
"@jambonz/siprec-client-utils": "^0.2.6",
"@jambonz/stats-collector": "^0.1.8",
"@jambonz/time-series": "^0.2.5",
"cidr-matcher": "^2.1.1",
Expand Down

0 comments on commit 85c7192

Please sign in to comment.