Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added recording params #166

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Change Log

## [7.23.1](https://github.com/plivo/plivo-java/tree/v7.23.1) (2023-03-08)
**Feature - Recording API changes**
- Added `cost`, `rounded_duration`, and `days_of_storage` parameters to the response for [get single recording API](https://www.plivo.com/docs/voice/api/recording#retrieve-a-recording) and [get all recordings API](https://www.plivo.com/docs/voice/api/recording#list-all-recordings)
- Added `rounded_duration` parameter as a filter option for [get all recordings API](https://www.plivo.com/docs/voice/api/recording#list-all-recordings)

## [7.23.0](https://github.com/plivo/plivo-go/tree/v7.23.0) (2023-03-03)
**Feature - Added New Param 'is_domestic' in Get Message and List Message APIs**
- Add `is_domestic` to the response for the [list all messages API](https://www.plivo.com/docs/sms/api/message/list-all-messages/) and the [get message details API](https://www.plivo.com/docs/sms/api/message#retrieve-a-message)
Expand Down
2 changes: 1 addition & 1 deletion baseclient.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import (
"github.com/google/go-querystring/query"
)

const sdkVersion = "7.23.0"
const sdkVersion = "7.23.1"

const lookupBaseUrl = "lookup.plivo.com"

Expand Down
5 changes: 4 additions & 1 deletion fixtures/recordingGetResponse.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,8 @@
"recording_start_ms": "1407235163907.00000",
"recording_type": "conference",
"recording_url": "http://s3.amazonaws.com/recordings_2013/c2186400-1c8c-11e4-a664-0026b945b52x.mp3",
"resource_uri": "/v1/Account/MANWVLYTK4ZWU1YTY4ZT/Recording/c2186400-1c8c-11e4-a664-0026b945b52x/"
"resource_uri": "/v1/Account/MANWVLYTK4ZWU1YTY4ZT/Recording/c2186400-1c8c-11e4-a664-0026b945b52x/",
"cost": "0.0004",
"rounded_duration": "120",
"days_of_storage": "209"
}
15 changes: 12 additions & 3 deletions fixtures/recordingListResponse.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,10 @@
"recording_start_ms": "1407235163907.00000",
"recording_type": "conference",
"recording_url": "http://s3.amazonaws.com/recordings_2013/c2186400-1c8c-1124-a664-0026b945b522.mp3",
"resource_uri": "/v1/Account/MANWVLYTK4ZWU1YTY4ZT/Recording/c2186400-1c8c-1124-a664-0026b945b522/"
"resource_uri": "/v1/Account/MANWVLYTK4ZWU1YTY4ZT/Recording/c2186400-1c8c-1124-a664-0026b945b522/",
"cost": "0.0004",
"rounded_duration": "120",
"days_of_storage": "209"
},
{
"add_time": "2014-08-05 16:05:21.993853+05:30",
Expand All @@ -32,7 +35,10 @@
"recording_start_ms": "1407234829553.00000",
"recording_type": "conference",
"recording_url": "http://s3.amazonaws.com/recordings_2013/fc2716b0-1c8b-11e4-bwad-842b2b17453e.mp3",
"resource_uri": "/v1/Account/MANWVLYTK4ZWU1YTY4ZT/Recording/fc2716b0-1c8b-11e4-bwad-842b2b17453e/"
"resource_uri": "/v1/Account/MANWVLYTK4ZWU1YTY4ZT/Recording/fc2716b0-1c8b-11e4-bwad-842b2b17453e/",
"cost": "0.0004",
"rounded_duration": "120",
"days_of_storage": "209"
},
{
"add_time": "2014-08-05 15:51:56.582492+05:30",
Expand All @@ -45,7 +51,10 @@
"recording_start_ms": "1407234081443.00000",
"recording_type": "conference",
"recording_url": "http://s3.amazonaws.com/recordings_2013/3e701c9e-1c8a-11e4-bwad-842b2b17453e.mp3",
"resource_uri": "/v1/Account/MANWVLYTK4ZWU1YTY4ZT/Recording/3e701c9e-1c8a-11e4-bwad-842b2b17453e/"
"resource_uri": "/v1/Account/MANWVLYTK4ZWU1YTY4ZT/Recording/3e701c9e-1c8a-11e4-bwad-842b2b17453e/",
"cost": "0.0004",
"rounded_duration": "120",
"days_of_storage": "209"
}
]
}
4 changes: 4 additions & 0 deletions recordings.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ type RecordingService struct {
type Recording struct {
AddTime string `json:"add_time,omitempty" url:"add_time,omitempty"`
CallUUID string `json:"call_uuid,omitempty" url:"call_uuid,omitempty"`
Cost string `json:"cost,omitempty" url:"cost,omitempty"`
DaysOfStorage string `json:"days_of_storage,omitempty" url:"days_of_storage,omitempty"`
RecordingID string `json:"recording_id,omitempty" url:"recording_id,omitempty"`
RecordingType string `json:"recording_type,omitempty" url:"recording_type,omitempty"`
RecordingFormat string `json:"recording_format,omitempty" url:"recording_format,omitempty"`
Expand All @@ -16,6 +18,7 @@ type Recording struct {
RecordingStartMS string `json:"recording_start_ms,omitempty" url:"recording_start_ms,omitempty"`
RecordingEndMS string `json:"recording_end_ms,omitempty" url:"recording_end_ms,omitempty"`
RecordingDurationMS string `json:"recording_duration_ms,omitempty" url:"recording_duration_ms,omitempty"`
RoundedDuration string `json:"rounded_duration,omitempty" url:"rounded_duration,omitempty"`
FromNumber string `json:"from_number,omitempty" url:"from_number,omitempty"`
ToNumber string `json:"to_number,omitempty" url:"to_number,omitempty"`
}
Expand All @@ -37,6 +40,7 @@ type RecordingListParams struct {
MpcName string `json:"mpc_name,omitempty" url:"mpc_name,omitempty"`
ConferenceUuid string `json:"conference_uuid,omitempty" url:"conference_uuid,omitempty"`
MpcUuid string `json:"mpc_uuid,omitempty" url:"mpc_uuid,omitempty"`
RoundedDuration string `json:"rounded_duration,omitempty" url:"rounded_duration,omitempty"`
}

type RecordingListResponse struct {
Expand Down