Skip to content

Commit

Permalink
Merge pull request #344 from plivo/VT-8201
Browse files Browse the repository at this point in the history
Added changes for single party session.
  • Loading branch information
manjunath-plivo authored Sep 30, 2024
2 parents a26250c + ed96728 commit 520d083
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 3 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
# Change Log
## [v4.69.0](https://github.com/plivo/plivo-node/tree/v4.69.0) (2024-09-30)
**Feature - Adding new param support for Number Masking session with single party **
- Added `create_session_with_single_party`, `virtual_number_cooloff_period` and `force_pin_authentication` attributes in Masking Session

## [v4.68.3](https://github.com/plivo/plivo-node/tree/v4.68.3) (2024-09-06)
**Feature - Adding more attribute on mdr object**
Expand Down
7 changes: 5 additions & 2 deletions lib/resources/maskingSession.js
Original file line number Diff line number Diff line change
Expand Up @@ -117,19 +117,22 @@ export class MaskingSessionInterface extends PlivoResourceInterface {
* @param {boolean} [params.unknownCallerPlay] - Sound url to play for unknown caller.
* @param {string} [params.subAccount] - SubAccount to create session.
* @param {boolean} [params.geoMatch] - GeoMatch to filter no.
* @param {number} [params.virtualNumberCooloffPeriod] - Specifies the cool-off period for reallocating the number to a new session. Must be a positive integer between 0 and 3600.
* @param {boolean} [params.forcePinAuthentication] - Indicates if PIN is needed, even from the registered mobile number.
* @param {boolean} [params.createSessionWithSingleParty] - Indicates if a session requires one party. Either first_party or second_party is mandatory.
* @promise {object} returns PlivoGenericResponse Object
* @fail {Error} returns Error
*/
createMaskingSession(firstParty, secondParty, params = {}) {
let errors = validate([{
field: 'first_party',
value: firstParty,
validators: ['isRequired']
validators: []
},
{
field: 'second_party',
value: secondParty,
validators: ['isRequired']
validators: []
}
]);
params.firstParty = firstParty;
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "plivo",
"version": "4.68.3",
"version": "4.69.0",
"description": "A Node.js SDK to make voice calls and send SMS using Plivo and to generate Plivo XML",
"homepage": "https://github.com/plivo/plivo-node",
"files": [
Expand Down

0 comments on commit 520d083

Please sign in to comment.