Skip to content

Commit

Permalink
Merge pull request #221 from plivo/VT-3196
Browse files Browse the repository at this point in the history
Added stirVerification field as part of get CDR / live call API response
  • Loading branch information
nixonsam authored Jun 23, 2021
2 parents 7e098b2 + f25d6f1 commit 1e7e432
Show file tree
Hide file tree
Showing 7 changed files with 18 additions and 8 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
# Change Log

## [v4.19.0](https://github.com/plivo/plivo-php/releases/tag/v4.19.0) - 2021-06-15
- Add stir verification param as part of Get CDR and live call APIs

## [v4.18.3](https://github.com/plivo/plivo-php/releases/tag/v4.18.3) - 2021-05-12
- Fixing the listMedia function invoke to fetch the media detail on message_uuid

Expand Down
4 changes: 3 additions & 1 deletion src/Plivo/Resources/Call/Call.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
* @property string $hangupCauseCode Hangup Cause Code
* @property string $hangupCauseName Hangup Cause Name
* @property string $hangupSource Hangup Source
* @property string $stirVerification Stir Verification
*/
class Call extends Resource
{
Expand Down Expand Up @@ -59,7 +60,8 @@ function __construct(
'totalRate' => $response['total_rate'],
'hangupCauseCode' => $response['hangup_cause_code'],
'hangupCauseName' => $response['hangup_cause_name'],
'hangupSource' => $response['hangup_source']
'hangupSource' => $response['hangup_source'],
'stirVerification' => $response['stir_verification']
];

$this->pathParams = [
Expand Down
3 changes: 2 additions & 1 deletion src/Plivo/Resources/Call/CallLive.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,8 @@ function __construct(BaseClient $client, $response, $authId)
'to' => $response['to'],
'callName' => $response['caller_name'],
'callUuid' => $response['call_uuid'],
'sessionStart' => $response['session_start']
'sessionStart' => $response['session_start'],
'stirVerification' => $response['stir_verification']
];

$this->pathParams = [
Expand Down
4 changes: 2 additions & 2 deletions src/Plivo/Version.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,11 @@ class Version
/**
* @const int PHP helper library minor version number
*/
const MINOR = 18;
const MINOR = 19;
/**
* @const int PHP helper library patch number
*/
const PATCH = 3;
const PATCH = 0;
/**
* @return string
*/
Expand Down
3 changes: 2 additions & 1 deletion tests/Mocks/callGetResponse.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,6 @@
"resource_uri": "/v1/Account/MAXXXXXXXXXXXXXXXXXX/Call/4d04c52e-cea3-4458-bbdb-0bfc314ee7cd/",
"to_number": "919686218339",
"total_amount": "0.02770",
"total_rate": "0.02770"
"total_rate": "0.02770",
"stir_verification": "Not Applicable"
}
6 changes: 4 additions & 2 deletions tests/Mocks/callListResponse.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@
"resource_uri": "/v1/Account/MAXXXXXXXXXXXXXXXXXX/Call/73b3b6cc-2d6c-4566-8d19-10e6fda55df8/",
"to_number": "919686218339",
"total_amount": "0.02770",
"total_rate": "0.02770"
"total_rate": "0.02770",
"stir_verification": "Verified"
},
{
"answer_time": null,
Expand All @@ -46,7 +47,8 @@
"resource_uri": "/v1/Account/MAXXXXXXXXXXXXXXXXXX/Call/7dddc9ac-db63-11e8-bd1f-2da0e9cc90d8/",
"to_number": "19792014278",
"total_amount": "0.00000",
"total_rate": "0.00000"
"total_rate": "0.00000",
"stir_verification": "Not Verified"
}
]
}
3 changes: 2 additions & 1 deletion tests/Mocks/liveCallGetResponse.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,6 @@
"from": "+918687888990",
"request_uuid": "d0a87a1a-b0e9-4ab2-ac07-c22ee87cd04a",
"session_start": "2017-05-22 13:17:49.050872",
"to": "919798990001"
"to": "919798990001",
"stir_verification": "Not Applicable"
}

0 comments on commit 1e7e432

Please sign in to comment.