From ae2db77d3f55bd87cc85fc84c640617083d68f36 Mon Sep 17 00:00:00 2001 From: olivierapivideo Date: Fri, 26 Jul 2024 13:48:19 +0000 Subject: [PATCH] Add new analytics endpoints & livestream complete() --- CHANGELOG.md | 4 + README.md | 32 +- api/openapi.yaml | 3068 +++++++++-------- api_analytics.go | 257 +- api_analytics_test.go | 254 -- api_live_streams.go | 75 + api_videos.go | 7 +- client.go | 44 +- docs/Analytics.md | 160 +- docs/AnalyticsAggregatedMetricsResponse.md | 72 + ...alyticsAggregatedMetricsResponseContext.md | 108 + ...gregatedMetricsResponseContextTimeframe.md | 82 + docs/AnalyticsMetricsBreakdownResponse.md | 93 + ...nalyticsMetricsBreakdownResponseContext.md | 108 + docs/AnalyticsMetricsBreakdownResponseData.md | 82 + docs/AnalyticsMetricsOverTimeResponse.md | 93 + ...AnalyticsMetricsOverTimeResponseContext.md | 108 + docs/AnalyticsMetricsOverTimeResponseData.md | 82 + docs/FilterBy.md | 238 ++ docs/FilterBy1.md | 238 ++ docs/FilterBy2.md | 238 ++ docs/LiveStream.md | 4 +- docs/LiveStreamCreationPayload.md | 4 +- docs/LiveStreamSession.md | 186 - docs/LiveStreamSessionClient.md | 108 - docs/LiveStreamSessionDevice.md | 108 - docs/LiveStreamSessionLocation.md | 82 - docs/LiveStreamSessionReferrer.md | 134 - docs/LiveStreamSessionSession.md | 108 - docs/LiveStreamUpdatePayload.md | 4 +- docs/LiveStreams.md | 62 + docs/RestreamsRequestObject.md | 2 +- docs/RestreamsResponseObject.md | 2 +- docs/UnrecognizedRequestUrl.md | 108 + docs/VideoCreationPayload.md | 2 +- docs/VideoSession.md | 186 - docs/VideoSessionClient.md | 108 - docs/VideoSessionDevice.md | 108 - docs/VideoSessionLocation.md | 92 - docs/VideoSessionOs.md | 108 - docs/VideoSessionReferrer.md | 144 - docs/VideoSessionSession.md | 134 - ...l_analytics_aggregated_metrics_response.go | 115 + ...ics_aggregated_metrics_response_context.go | 164 + ...ated_metrics_response_context_timeframe.go | 131 + model_analytics_metrics_breakdown_response.go | 142 + ...tics_metrics_breakdown_response_context.go | 164 + ...alytics_metrics_breakdown_response_data.go | 131 + model_analytics_metrics_over_time_response.go | 142 + ...tics_metrics_over_time_response_context.go | 164 + ...alytics_metrics_over_time_response_data.go | 131 + model_filter_by.go | 334 ++ model_filter_by_1.go | 334 ++ model_filter_by_2.go | 334 ++ model_live_stream.go | 4 +- model_live_stream_creation_payload.go | 4 +- model_live_stream_session.go | 261 -- model_live_stream_session_client.go | 165 - model_live_stream_session_device.go | 165 - model_live_stream_session_location.go | 131 - model_live_stream_session_referrer.go | 199 -- model_live_stream_session_session.go | 165 - model_live_stream_update_payload.go | 4 +- model_restreams_request_object.go | 2 +- model_restreams_response_object.go | 2 +- model_unrecognized_request_url.go | 165 + model_video_creation_payload.go | 2 +- model_video_session.go | 261 -- model_video_session_client.go | 165 - model_video_session_device.go | 165 - model_video_session_location.go | 142 - model_video_session_os.go | 165 - model_video_session_referrer.go | 210 -- model_video_session_session.go | 199 -- 74 files changed, 6280 insertions(+), 5819 deletions(-) delete mode 100644 api_analytics_test.go create mode 100644 docs/AnalyticsAggregatedMetricsResponse.md create mode 100644 docs/AnalyticsAggregatedMetricsResponseContext.md create mode 100644 docs/AnalyticsAggregatedMetricsResponseContextTimeframe.md create mode 100644 docs/AnalyticsMetricsBreakdownResponse.md create mode 100644 docs/AnalyticsMetricsBreakdownResponseContext.md create mode 100644 docs/AnalyticsMetricsBreakdownResponseData.md create mode 100644 docs/AnalyticsMetricsOverTimeResponse.md create mode 100644 docs/AnalyticsMetricsOverTimeResponseContext.md create mode 100644 docs/AnalyticsMetricsOverTimeResponseData.md create mode 100644 docs/FilterBy.md create mode 100644 docs/FilterBy1.md create mode 100644 docs/FilterBy2.md delete mode 100644 docs/LiveStreamSession.md delete mode 100644 docs/LiveStreamSessionClient.md delete mode 100644 docs/LiveStreamSessionDevice.md delete mode 100644 docs/LiveStreamSessionLocation.md delete mode 100644 docs/LiveStreamSessionReferrer.md delete mode 100644 docs/LiveStreamSessionSession.md create mode 100644 docs/UnrecognizedRequestUrl.md delete mode 100644 docs/VideoSession.md delete mode 100644 docs/VideoSessionClient.md delete mode 100644 docs/VideoSessionDevice.md delete mode 100644 docs/VideoSessionLocation.md delete mode 100644 docs/VideoSessionOs.md delete mode 100644 docs/VideoSessionReferrer.md delete mode 100644 docs/VideoSessionSession.md create mode 100644 model_analytics_aggregated_metrics_response.go create mode 100644 model_analytics_aggregated_metrics_response_context.go create mode 100644 model_analytics_aggregated_metrics_response_context_timeframe.go create mode 100644 model_analytics_metrics_breakdown_response.go create mode 100644 model_analytics_metrics_breakdown_response_context.go create mode 100644 model_analytics_metrics_breakdown_response_data.go create mode 100644 model_analytics_metrics_over_time_response.go create mode 100644 model_analytics_metrics_over_time_response_context.go create mode 100644 model_analytics_metrics_over_time_response_data.go create mode 100644 model_filter_by.go create mode 100644 model_filter_by_1.go create mode 100644 model_filter_by_2.go delete mode 100644 model_live_stream_session.go delete mode 100644 model_live_stream_session_client.go delete mode 100644 model_live_stream_session_device.go delete mode 100644 model_live_stream_session_location.go delete mode 100644 model_live_stream_session_referrer.go delete mode 100644 model_live_stream_session_session.go create mode 100644 model_unrecognized_request_url.go delete mode 100644 model_video_session.go delete mode 100644 model_video_session_client.go delete mode 100644 model_video_session_device.go delete mode 100644 model_video_session_location.go delete mode 100644 model_video_session_os.go delete mode 100644 model_video_session_referrer.go delete mode 100644 model_video_session_session.go diff --git a/CHANGELOG.md b/CHANGELOG.md index a47983a..0875cd3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,10 @@ # Changelog All changes to this project will be documented in this file. +## [1.4.0] - 2024-07-29 +- Add new analytics methods +- Add livestream complete() method + ## [1.3.1] - 2024-02-19 - Update VideoStatusIngest enum diff --git a/README.md b/README.md index e34a06d..2c6c2e9 100644 --- a/README.md +++ b/README.md @@ -141,8 +141,9 @@ analyticsApi := client.Analytics Method | HTTP request | Description ------------- | ------------- | ------------- -[**GetLiveStreamsPlays**](https://github.com/apivideo/api.video-go-client/blob/main/docs/Analytics.md#GetLiveStreamsPlays) | **Get** `/analytics/live-streams/plays` | Get play events for live stream -[**GetVideosPlays**](https://github.com/apivideo/api.video-go-client/blob/main/docs/Analytics.md#GetVideosPlays) | **Get** `/analytics/videos/plays` | Get play events for video +[**GetAggregatedMetrics**](https://github.com/apivideo/api.video-go-client/blob/main/docs/Analytics.md#GetAggregatedMetrics) | **Get** `/data/metrics/{metric}/{aggregation}` | Retrieve aggregated metrics +[**GetMetricsBreakdown**](https://github.com/apivideo/api.video-go-client/blob/main/docs/Analytics.md#GetMetricsBreakdown) | **Get** `/data/buckets/{metric}/{breakdown}` | Retrieve metrics in a breakdown of dimensions +[**GetMetricsOverTime**](https://github.com/apivideo/api.video-go-client/blob/main/docs/Analytics.md#GetMetricsOverTime) | **Get** `/data/timeseries/{metric}` | Retrieve metrics over time #### Captions @@ -204,6 +205,7 @@ Method | HTTP request | Description [**List**](https://github.com/apivideo/api.video-go-client/blob/main/docs/LiveStreams.md#List) | **Get** `/live-streams` | List all live streams [**UploadThumbnail**](https://github.com/apivideo/api.video-go-client/blob/main/docs/LiveStreams.md#UploadThumbnail) | **Post** `/live-streams/{liveStreamId}/thumbnail` | Upload a thumbnail [**DeleteThumbnail**](https://github.com/apivideo/api.video-go-client/blob/main/docs/LiveStreams.md#DeleteThumbnail) | **Delete** `/live-streams/{liveStreamId}/thumbnail` | Delete a thumbnail +[**Complete**](https://github.com/apivideo/api.video-go-client/blob/main/docs/LiveStreams.md#Complete) | **Put** `/live-streams/{liveStreamId}/complete` | Complete a live stream #### PlayerThemes @@ -315,7 +317,16 @@ Method | HTTP request | Description - [AccessToken](https://github.com/apivideo/api.video-go-client/blob/main/docs/AccessToken.md) - [AdditionalBadRequestErrors](https://github.com/apivideo/api.video-go-client/blob/main/docs/AdditionalBadRequestErrors.md) + - [AnalyticsAggregatedMetricsResponse](https://github.com/apivideo/api.video-go-client/blob/main/docs/AnalyticsAggregatedMetricsResponse.md) + - [AnalyticsAggregatedMetricsResponseContext](https://github.com/apivideo/api.video-go-client/blob/main/docs/AnalyticsAggregatedMetricsResponseContext.md) + - [AnalyticsAggregatedMetricsResponseContextTimeframe](https://github.com/apivideo/api.video-go-client/blob/main/docs/AnalyticsAggregatedMetricsResponseContextTimeframe.md) - [AnalyticsData](https://github.com/apivideo/api.video-go-client/blob/main/docs/AnalyticsData.md) + - [AnalyticsMetricsBreakdownResponse](https://github.com/apivideo/api.video-go-client/blob/main/docs/AnalyticsMetricsBreakdownResponse.md) + - [AnalyticsMetricsBreakdownResponseContext](https://github.com/apivideo/api.video-go-client/blob/main/docs/AnalyticsMetricsBreakdownResponseContext.md) + - [AnalyticsMetricsBreakdownResponseData](https://github.com/apivideo/api.video-go-client/blob/main/docs/AnalyticsMetricsBreakdownResponseData.md) + - [AnalyticsMetricsOverTimeResponse](https://github.com/apivideo/api.video-go-client/blob/main/docs/AnalyticsMetricsOverTimeResponse.md) + - [AnalyticsMetricsOverTimeResponseContext](https://github.com/apivideo/api.video-go-client/blob/main/docs/AnalyticsMetricsOverTimeResponseContext.md) + - [AnalyticsMetricsOverTimeResponseData](https://github.com/apivideo/api.video-go-client/blob/main/docs/AnalyticsMetricsOverTimeResponseData.md) - [AnalyticsPlays400Error](https://github.com/apivideo/api.video-go-client/blob/main/docs/AnalyticsPlays400Error.md) - [AnalyticsPlaysResponse](https://github.com/apivideo/api.video-go-client/blob/main/docs/AnalyticsPlaysResponse.md) - [AuthenticatePayload](https://github.com/apivideo/api.video-go-client/blob/main/docs/AuthenticatePayload.md) @@ -326,17 +337,14 @@ Method | HTTP request | Description - [CaptionsUpdatePayload](https://github.com/apivideo/api.video-go-client/blob/main/docs/CaptionsUpdatePayload.md) - [Chapter](https://github.com/apivideo/api.video-go-client/blob/main/docs/Chapter.md) - [ChaptersListResponse](https://github.com/apivideo/api.video-go-client/blob/main/docs/ChaptersListResponse.md) + - [FilterBy](https://github.com/apivideo/api.video-go-client/blob/main/docs/FilterBy.md) + - [FilterBy1](https://github.com/apivideo/api.video-go-client/blob/main/docs/FilterBy1.md) + - [FilterBy2](https://github.com/apivideo/api.video-go-client/blob/main/docs/FilterBy2.md) - [Link](https://github.com/apivideo/api.video-go-client/blob/main/docs/Link.md) - [LiveStream](https://github.com/apivideo/api.video-go-client/blob/main/docs/LiveStream.md) - [LiveStreamAssets](https://github.com/apivideo/api.video-go-client/blob/main/docs/LiveStreamAssets.md) - [LiveStreamCreationPayload](https://github.com/apivideo/api.video-go-client/blob/main/docs/LiveStreamCreationPayload.md) - [LiveStreamListResponse](https://github.com/apivideo/api.video-go-client/blob/main/docs/LiveStreamListResponse.md) - - [LiveStreamSession](https://github.com/apivideo/api.video-go-client/blob/main/docs/LiveStreamSession.md) - - [LiveStreamSessionClient](https://github.com/apivideo/api.video-go-client/blob/main/docs/LiveStreamSessionClient.md) - - [LiveStreamSessionDevice](https://github.com/apivideo/api.video-go-client/blob/main/docs/LiveStreamSessionDevice.md) - - [LiveStreamSessionLocation](https://github.com/apivideo/api.video-go-client/blob/main/docs/LiveStreamSessionLocation.md) - - [LiveStreamSessionReferrer](https://github.com/apivideo/api.video-go-client/blob/main/docs/LiveStreamSessionReferrer.md) - - [LiveStreamSessionSession](https://github.com/apivideo/api.video-go-client/blob/main/docs/LiveStreamSessionSession.md) - [LiveStreamUpdatePayload](https://github.com/apivideo/api.video-go-client/blob/main/docs/LiveStreamUpdatePayload.md) - [Metadata](https://github.com/apivideo/api.video-go-client/blob/main/docs/Metadata.md) - [Model403ErrorSchema](https://github.com/apivideo/api.video-go-client/blob/main/docs/Model403ErrorSchema.md) @@ -356,18 +364,12 @@ Method | HTTP request | Description - [TokenCreationPayload](https://github.com/apivideo/api.video-go-client/blob/main/docs/TokenCreationPayload.md) - [TokenListResponse](https://github.com/apivideo/api.video-go-client/blob/main/docs/TokenListResponse.md) - [TooManyRequests](https://github.com/apivideo/api.video-go-client/blob/main/docs/TooManyRequests.md) + - [UnrecognizedRequestUrl](https://github.com/apivideo/api.video-go-client/blob/main/docs/UnrecognizedRequestUrl.md) - [UploadToken](https://github.com/apivideo/api.video-go-client/blob/main/docs/UploadToken.md) - [Video](https://github.com/apivideo/api.video-go-client/blob/main/docs/Video.md) - [VideoAssets](https://github.com/apivideo/api.video-go-client/blob/main/docs/VideoAssets.md) - [VideoClip](https://github.com/apivideo/api.video-go-client/blob/main/docs/VideoClip.md) - [VideoCreationPayload](https://github.com/apivideo/api.video-go-client/blob/main/docs/VideoCreationPayload.md) - - [VideoSession](https://github.com/apivideo/api.video-go-client/blob/main/docs/VideoSession.md) - - [VideoSessionClient](https://github.com/apivideo/api.video-go-client/blob/main/docs/VideoSessionClient.md) - - [VideoSessionDevice](https://github.com/apivideo/api.video-go-client/blob/main/docs/VideoSessionDevice.md) - - [VideoSessionLocation](https://github.com/apivideo/api.video-go-client/blob/main/docs/VideoSessionLocation.md) - - [VideoSessionOs](https://github.com/apivideo/api.video-go-client/blob/main/docs/VideoSessionOs.md) - - [VideoSessionReferrer](https://github.com/apivideo/api.video-go-client/blob/main/docs/VideoSessionReferrer.md) - - [VideoSessionSession](https://github.com/apivideo/api.video-go-client/blob/main/docs/VideoSessionSession.md) - [VideoSource](https://github.com/apivideo/api.video-go-client/blob/main/docs/VideoSource.md) - [VideoSourceLiveStream](https://github.com/apivideo/api.video-go-client/blob/main/docs/VideoSourceLiveStream.md) - [VideoSourceLiveStreamLink](https://github.com/apivideo/api.video-go-client/blob/main/docs/VideoSourceLiveStreamLink.md) diff --git a/api/openapi.yaml b/api/openapi.yaml index 523f057..690b0ca 100644 --- a/api/openapi.yaml +++ b/api/openapi.yaml @@ -44,7 +44,7 @@ paths: examples: response: value: - type: https://docs.api.video/docs/authenticationinvalid_credentials + type: https://docs.api.video/reference/authentication-invalid-user-credentials title: The user credentials were incorrect. name: "" status: 400 @@ -120,7 +120,7 @@ paths: response: value: status: 400 - type: https://docs.api.video/docs/authenticationinvalid_credentials + type: https://docs.api.video/reference/authentication-invalid-user-credentials title: The user credentials were incorrect. name: "" schema: @@ -449,7 +449,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -685,21 +685,21 @@ paths: examples: response: value: - type: https://docs.api.video/docs/attributerequired + type: https://docs.api.video/reference/attribute-required title: This attribute is required. name: title status: 400 problems: - - type: https://docs.api.video/docs/attributerequired + - type: https://docs.api.video/reference/attribute-required title: This attribute is required. name: title - - type: https://docs.api.video/docs/attributeinvalid + - type: https://docs.api.video/reference/invalid-attribute title: This attribute must be a ISO8601 date. name: scheduledAt - - type: https://docs.api.video/docs/attributeinvalid + - type: https://docs.api.video/reference/invalid-attribute title: This attribute must be an array. name: tags - - type: https://docs.api.video/docs/attributeinvalid + - type: https://docs.api.video/reference/invalid-attribute title: This attribute must be an array. name: metadata schema: @@ -730,7 +730,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -1059,21 +1059,21 @@ paths: examples: response: value: - type: https://docs.api.video/docs/filealreadyuploaded + type: https://docs.api.video/reference/video-source-already-uploaded title: The source of the video is already uploaded. name: file status: 400 problems: - - type: https://docs.api.video/docs/filealreadyuploaded + - type: https://docs.api.video/reference/video-source-already-uploaded title: The source of the video is already uploaded. name: file - - type: https://docs.api.video/docs/filealreadyuploaded + - type: https://docs.api.video/reference/video-source-already-uploaded title: The video xxxx has already been uploaded. name: video - - type: https://docs.api.video/docs/filemissing + - type: https://docs.api.video/reference/uploaded-file-no-file title: There is no uploaded file in the request. name: file - - type: https://docs.api.video/docs/multiplefilesuploaded + - type: https://docs.api.video/reference/uploaded-file-multiple-files title: There is more than one uploaded file in the request. name: file schema: @@ -1106,7 +1106,7 @@ paths: examples: response: value: - type: https://docs.api.video/docs/resourcenot_found + type: https://docs.api.video/reference/resource-not-found title: The requested resource was not found. name: videoId status: 404 @@ -1138,7 +1138,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -1506,7 +1506,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -1632,7 +1632,7 @@ paths: response: value: status: 400 - type: https://docs.api.video/docs/fileextension + type: https://docs.api.video/reference/uploaded-file-extension-invalid title: Only [jpeg, jpg, JPG, JPEG, png, PNG] extensions are supported. name: file schema: @@ -1663,7 +1663,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -1892,7 +1892,7 @@ paths: examples: response: value: - type: https://docs.api.video/docs/resourcenot_found + type: https://docs.api.video/reference/resource-not-found title: The requested resource was not found. name: watermarkId status: 404 @@ -1924,7 +1924,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -2080,7 +2080,7 @@ paths: examples: response: value: - type: https://docs.api.video/docs/resourcenot_found + type: https://docs.api.video/reference/resource-not-found title: The requested resource was not found. name: videoId status: 404 @@ -2112,7 +2112,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -2345,7 +2345,7 @@ paths: response: value: status: 400 - type: https://docs.api.video/docs/fileextension + type: https://docs.api.video/reference/uploaded-file-extension-invalid title: Only [jpeg, jpg, JPG, JPEG] extensions are supported. name: file schema: @@ -2378,7 +2378,7 @@ paths: examples: response: value: - type: https://docs.api.video/docs/resourcenot_found + type: https://docs.api.video/reference/resource-not-found title: The requested resource was not found. name: videoId status: 404 @@ -2410,7 +2410,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -2594,7 +2594,7 @@ paths: examples: response: value: - type: https://docs.api.video/docs/resourcenot_found + type: https://docs.api.video/reference/resource-not-found title: The requested resource was not found. name: videoId status: 404 @@ -2626,7 +2626,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -2826,7 +2826,7 @@ paths: examples: response: value: - type: https://docs.api.video/docs/resourcenot_found + type: https://docs.api.video/reference/resource-not-found title: The requested resource was not found. name: videoId status: 404 @@ -2858,7 +2858,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -3076,18 +3076,18 @@ paths: examples: response: value: - type: https://docs.api.video/docs/attributeinvalid + type: https://docs.api.video/reference/invalid-attribute title: This attribute must be a ISO-8601 date. name: scheduledAt status: 400 problems: - - type: https://docs.api.video/docs/attributeinvalid + - type: https://docs.api.video/reference/invalid-attribute title: This attribute must be a ISO-8601 date. name: scheduledAt - - type: https://docs.api.video/docs/attributeinvalid + - type: https://docs.api.video/reference/invalid-attribute title: This attribute must be an array. name: tags - - type: https://docs.api.video/docs/attributeinvalid + - type: https://docs.api.video/reference/invalid-attribute title: This attribute must be an array. name: metadata schema: @@ -3120,7 +3120,7 @@ paths: examples: response: value: - type: https://docs.api.video/docs/resourcenot_found + type: https://docs.api.video/reference/resource-not-found title: The requested resource was not found. name: videoId status: 404 @@ -3152,7 +3152,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -3429,7 +3429,7 @@ paths: examples: response: value: - type: https://docs.api.video/docs/resourcenot_found + type: https://docs.api.video/reference/resource-not-found title: The requested resource was not found. name: videoId status: 404 @@ -3461,7 +3461,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -3725,7 +3725,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -3970,7 +3970,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -4168,7 +4168,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -4393,7 +4393,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -4665,7 +4665,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -4932,7 +4932,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -5188,22 +5188,22 @@ paths: detail: This value should not be blank. name: restreams[0][name] Missing app name in serverUrl: - description: This error occurs when the rtmp app name is missing - from `serverURL` in the `restreams` array. + description: This error occurs when the app name is missing from + `serverURL` in the `restreams` array. value: type: https://docs.api.video/reference/invalid-attribute title: An attribute is invalid. status: 400 - detail: 'Missing app name: rtmp://[host]/[app name].' + detail: 'Missing app name: [rtmp|rtmps]://[host]/[app name].' name: restreams[0][serverUrl] Incorrect URL in serverUrl: description: This error occurs when the URL you set in `serverURL` - is not `rtmp`. + is not `rtmps` or `rtmp`. value: type: https://docs.api.video/reference/invalid-attribute title: An attribute is invalid. status: 400 - detail: 'RTMP URL should have the following format: rtmp://[host]/[app + detail: 'RTMP URL should have the following format: [rtmp|rtmps]://[host]/[app name].' name: restreams[0][serverUrl] Too many restream destinations: @@ -5252,7 +5252,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -5448,7 +5448,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -5640,7 +5640,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -5873,22 +5873,22 @@ paths: detail: This value should not be blank. name: restreams[0][name] Missing app name in serverUrl: - description: This error occurs when the rtmp app name is missing - from `serverURL` in the `restreams` array. + description: This error occurs when the app name is missing from + `serverURL` in the `restreams` array. value: type: https://docs.api.video/reference/invalid-attribute title: An attribute is invalid. status: 400 - detail: 'Missing app name: rtmp://[host]/[app name].' + detail: 'Missing app name: [rtmp|rtmps]://[host]/[app name].' name: restreams[0][serverUrl] Incorrect URL in serverUrl: description: This error occurs when the URL you set in `serverURL` - is not `rtmp`. + is not `rtmps` or `rtmp`. value: type: https://docs.api.video/reference/invalid-attribute title: An attribute is invalid. status: 400 - detail: 'RTMP URL should have the following format: rtmp://[host]/[app + detail: 'RTMP URL should have the following format: [rtmp|rtmps]://[host]/[app name].' name: restreams[0][serverUrl] Too many restream destinations: @@ -5937,7 +5937,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -6189,7 +6189,7 @@ paths: examples: response: value: - type: https://docs.api.video/docs/resourcenot_found + type: https://docs.api.video/reference/resource-not-found title: The requested resource was not found. name: liveStreamId status: 404 @@ -6221,7 +6221,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -6398,7 +6398,7 @@ paths: response: value: status: 400 - type: https://docs.api.video/docs/fileextension + type: https://docs.api.video/reference/uploaded-file-extension-invalid title: Only [jpeg, jpg, JPG, JPEG] extensions are supported. name: file schema: @@ -6431,7 +6431,7 @@ paths: examples: response: value: - type: https://docs.api.video/docs/resourcenot_found + type: https://docs.api.video/reference/resource-not-found title: The requested resource was not found. name: liveStreamId status: 404 @@ -6463,7 +6463,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -6626,6 +6626,123 @@ paths: code: | // First install the api client: https://github.com/apivideo/api.video-swift-client#getting-started // Documentation: https://github.com/apivideo/api.video-swift-client/blob/main/docs/LiveStreamsAPI.md#uploadThumbnail + /live-streams/{liveStreamId}/complete: + put: + description: "Request the completion of a live stream that is currently running.\ + \ This operation is asynchronous and the live stream will stop after a few\ + \ seconds. \n\nThe API adds the `EXT-X-ENDLIST` tag to the live stream's HLS\ + \ manifest. This stops the live stream on the player and also stops the recording\ + \ of the live stream. The API keeps the incoming connection from the streamer\ + \ open for at most 1 minute, which can be used to terminate the stream.\n" + operationId: PUT_live-streams-liveStreamId-complete + parameters: + - description: The unique ID for the live stream you want to complete. + example: vi4k0jvEUuaTdRAEjQ4Jfrgz + explode: false + in: path + name: liveStreamId + required: true + schema: + type: string + style: simple + responses: + "202": + description: Accepted + headers: + X-RateLimit-Limit: + description: The request limit per minute. + explode: false + schema: + type: integer + style: simple + X-RateLimit-Remaining: + description: The number of available requests left for the current time + window. + explode: false + schema: + type: integer + style: simple + X-RateLimit-Retry-After: + description: The number of seconds left until the current rate limit + window resets. + explode: false + schema: + type: integer + style: simple + "404": + content: + application/json: + examples: + response: + value: + type: https://docs.api.video/reference/resource-not-found + title: The requested resource was not found. + name: liveStreamId + status: 404 + schema: + $ref: '#/components/schemas/not-found' + description: Not Found + headers: + X-RateLimit-Limit: + description: The request limit per minute. + explode: false + schema: + type: integer + style: simple + X-RateLimit-Remaining: + description: The number of available requests left for the current time + window. + explode: false + schema: + type: integer + style: simple + X-RateLimit-Retry-After: + description: The number of seconds left until the current rate limit + window resets. + explode: false + schema: + type: integer + style: simple + "429": + content: + application/json: + examples: + Too many requests: + value: + type: https://docs.api.video/reference/too-many-requests + title: Too many requests. + status: 429 + schema: + $ref: '#/components/schemas/too-many-requests' + description: Too Many Requests + headers: + X-RateLimit-Limit: + description: The request limit per minute. + explode: false + schema: + type: integer + style: simple + X-RateLimit-Remaining: + description: The number of available requests left for the current time + window. + explode: false + schema: + type: integer + style: simple + X-RateLimit-Retry-After: + description: The number of seconds left until the current rate limit + window resets. + explode: false + schema: + type: integer + style: simple + security: + - apiKey: [] + summary: Complete a live stream + tags: + - Live Streams + x-client-action: complete + x-doctave: {} /videos/{videoId}/captions/{language}: delete: description: Delete a caption in a specific language by by video id. @@ -6757,7 +6874,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -7056,7 +7173,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -7378,7 +7495,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -7682,7 +7799,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -7976,7 +8093,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -8221,7 +8338,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -8459,7 +8576,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -8738,7 +8855,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -9023,7 +9140,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -9367,7 +9484,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -9602,7 +9719,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -9855,7 +9972,7 @@ paths: examples: response: value: - type: https://docs.api.video/docs/resourcenot_found + type: https://docs.api.video/reference/resource-not-found title: The requested resource was not found. name: playerId status: 404 @@ -9887,7 +10004,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -10096,7 +10213,7 @@ paths: examples: response: value: - type: https://docs.api.video/docs/resourcenot_found + type: https://docs.api.video/reference/resource-not-found title: The requested resource was not found. name: playerId status: 404 @@ -10128,7 +10245,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -10323,7 +10440,7 @@ paths: examples: response: value: - type: https://docs.api.video/docs/resourcenot_found + type: https://docs.api.video/reference/resource-not-found title: The requested resource was not found. name: playerId status: 404 @@ -10355,7 +10472,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -10596,7 +10713,7 @@ paths: examples: response: value: - type: https://docs.api.video/docs/resourcenot_found + type: https://docs.api.video/reference/resource-not-found title: The requested resource was not found. name: playerId status: 404 @@ -10628,7 +10745,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -10826,7 +10943,7 @@ paths: response: value: status: 400 - type: https://docs.api.video/docs/fileextension + type: https://docs.api.video/reference/uploaded-file-extension-invalid title: Only ['jpg', 'JPG', 'jpeg', 'JPEG', 'png', 'PNG'] extensions are supported. name: file @@ -10860,7 +10977,7 @@ paths: examples: response: value: - type: https://docs.api.video/docs/resourcenot_found + type: https://docs.api.video/reference/resource-not-found title: The requested resource was not found. name: playerId status: 404 @@ -10892,7 +11009,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -11058,175 +11175,214 @@ paths: code: | // First install the api client: https://github.com/apivideo/api.video-swift-client#getting-started // Documentation: https://github.com/apivideo/api.video-swift-client/blob/main/docs/PlayerThemesAPI.md#uploadLogo - /analytics/videos/plays: + /data/metrics/{metric}/{aggregation}: get: - description: Retrieve filtered analytics about the number of plays for your - videos in a project. - operationId: GET_analytics-videos-plays + description: Retrieve time-based and countable metrics like average watch time + or the number of impressions over a certain period of time. + operationId: GET_aggregated-metrics parameters: - description: | - Use this query parameter to set the start date for the time period that you want analytics for. - - The API returns analytics data including the day you set in `from`. - - The date you set must be **within the last 30 days**. - - The value you provide must follow the `YYYY-MM-DD` format. - example: 2023-06-01 - explode: true - in: query - name: from + Use this path parameter to select a metric that you want analytics for. + + - `play` is the number of times your content has been played. You can use the aggregations `count`, `rate`, and `total` with the `play` metric. + - `start` is the number of times playback was started. You can use the aggregation `count` with this metric. + - `end` is the number of times playback has ended with the content watch until the end. You can use the aggregation `count` with this metric. + - `impression` is the number of times your content has been loaded and was ready for playback. You can use the aggregation `count` with this metric. + - `impression-time` is the time in milliseconds that your content was loading for until the first video frame is displayed. You can use the aggregations `average` and `sum` with this metric. + - `watch-time` is the cumulative time in seconds that the user has spent watching your content. You can use the aggregations `average` and `sum` with this metric. + explode: false + in: path + name: metric required: true schema: - format: date - type: string - style: form - - description: | - Use this optional query parameter to set the end date for the time period that you want analytics for. - - If you do not specify a `to` date, the API returns analytics data starting from the `from` date up until today, and excluding today. - - The date you set must be **within the last 30 days**. - - The value you provide must follow the `YYYY-MM-DD` format. - example: 2023-06-10 - explode: true - in: query - name: to - required: false - schema: - format: date + enum: + - play + - start + - end + - impression + - impression-time + - watch-time type: string - style: form - - description: |- - Use this query parameter to define the dimension that you want analytics for. - - `videoId`: Returns analytics based on the public video identifiers. - - `emittedAt`: Returns analytics based on the times of the play events. The API returns data in specific interval groups. When the date period you set in `from` and `to` is less than or equals to 2 days, the response for this dimension is grouped in hourly intervals. Otherwise, it is grouped in daily intervals. - - `country`: Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). - - `deviceType`: Returns analytics based on the type of device used by the viewers during the play event. Possible response values are: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. - - `operatingSystem`: Returns analytics based on the operating system used by the viewers during the play event. Response values include `windows`, `mac osx`, `android`, `ios`, `linux`. - - `browser`: Returns analytics based on the browser used by the viewers during the play event. Response values include `chrome`, `firefox`, `edge`, `opera`. - example: browser + style: simple + - description: "Use this path parameter to define a way of collecting data for\ + \ the metric that you want analytics for.\n\n- `count` returns the overall\ + \ number of events for the `play` metric.\n- `rate` returns the ratio that\ + \ calculates the number of plays your content receives divided by its impressions.\ + \ This aggregation can be used only with the `play` metric.\n- `total` calculates\ + \ the total number of events for the `play` metric. \n- `average` calculates\ + \ an average value for the selected metric.\n- `sum` adds up the total value\ + \ of the select metric.\n" explode: false - in: query - name: dimension + in: path + name: aggregation required: true schema: enum: - - videoId - - emittedAt - - country - - deviceType - - operatingSystem - - browser + - count + - rate + - total + - average + - sum type: string - style: form - - description: Use this query parameter to filter your results to a specific - video in a project that you want analytics for. You must use the `videoId:` - prefix when specifying a video ID. - example: videoId:vi3q7HxhApxRF1c8F8r6VeaI + style: simple + - description: | + Use this query parameter to define the starting date-time of the period you want analytics for. + + - If you do not set a value for `from`, the default assigned value is 1 day ago, based on the `to` parameter. + - The maximum value is 30 days ago. + - The value you provide should follow the ATOM date-time format: `2024-02-05T00:00:00+01:00` + - The API ignores this parameter when you call `/data/metrics/play/total`. + example: 2024-02-05T00:00:00+01:00 explode: false in: query - name: filter + name: from required: false schema: + format: date-time type: string style: form - - description: 'Choose the number of search results to return per page. Minimum - value: 1' - example: 2 - explode: true + - description: | + Use this query parameter to define the ending date-time of the period you want analytics for. + + - If you do not set a value for `to`, the default assigned value is `now`. + - The API ignores this parameter when you call `/data/metrics/play/total`. + - The value for `to` is a non-inclusive value: the API returns data **before** the date-time that you set. + example: 2024-02-06T00:00:00+01:00 + explode: false in: query - name: currentPage + name: to required: false schema: - default: 1 - type: integer + format: date-time + type: string style: form - - description: Results per page. Allowed values 1-100, default is 25. - example: 30 + - $ref: '#/components/parameters/filterBy_2' + description: "Use this parameter to filter the API's response based on different\ + \ data dimensions. You can serialize filters in your query to receive more\ + \ detailed breakdowns of your analytics.\n\n- If you do not set a value\ + \ for `filterBy`, the API returns the full dataset for your project.\n-\ + \ The API only accepts the `mediaId` and `mediaType` filters when you call\ + \ `/data/metrics/play/total` or `/data/buckets/play-total/media-id`.\n\n\ + These are the available breakdown dimensions:\n\n- `mediaId`: Returns analytics\ + \ based on the unique identifiers of a video or a live stream.\n- `mediaType`:\ + \ Returns analytics based on the type of content. Possible values: `video`\ + \ and `live-stream`. \n- `continent`: Returns analytics based on the viewers'\ + \ continent. The list of supported continents names are based on the [GeoNames\ + \ public database](https://www.geonames.org/countries/). You must use the\ + \ ISO-3166 alpha2 format, for example `EU`. Possible values are: `AS`, `AF`,\ + \ `NA`, `SA`, `AN`, `EU`, `AZ`. \n- `country`: Returns analytics based on\ + \ the viewers' country. The list of supported country names are based on\ + \ the [GeoNames public database](https://www.geonames.org/countries/). You\ + \ must use the ISO-3166 alpha2 format, for example `FR`.\n- `deviceType`:\ + \ Returns analytics based on the type of device used by the viewers. Response\ + \ values can include: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`,\ + \ `unknown`.\n- `operatingSystem`: Returns analytics based on the operating\ + \ system used by the viewers. Response values can include `windows`, `mac\ + \ osx`, `android`, `ios`, `linux`.\n- `browser`: Returns analytics based\ + \ on the browser used by the viewers. Response values can include `chrome`,\ + \ `firefox`, `edge`, `opera`.\n- `tag`: Returns analytics for videos using\ + \ this tag. This filter only accepts a single value and is case sensitive.\ + \ Read more about tagging your videos [here](https://docs.api.video/vod/tags-metadata).\n" + example: filterBy[country]=FR&filterBy[operatingSystem]=windows&filterBy[browser][]=firefox&filterBy[browser][]=chrome&filterBy[tag]=Cool + videos explode: true in: query - name: pageSize + name: filterBy required: false schema: - default: 25 - type: integer - style: form + properties: + mediaId: + description: Returns analytics based on the unique identifiers of a + video or a live stream. + example: + - vi4blUQJFrYWbaG44NChkH27 + items: + type: string + type: array + mediaType: + enum: + - video + - live-stream + example: video + type: string + continent: + description: Returns analytics based on the viewers' continent. The + list of supported continents names are based on the [GeoNames public + database](https://www.geonames.org/countries/). You must use the ISO-3166 + alpha2 format, for example `EU`. + example: + - EU + items: + enum: + - AS + - AF + - NA + - SA + - AN + - EU + - AZ + type: string + type: array + country: + description: Returns analytics based on the viewers' country. The list + of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). + You must use the ISO-3166 alpha2 format, for example `FR`. + example: + - FR + items: + type: string + type: array + deviceType: + description: 'Returns analytics based on the type of device used by + the viewers. Response values can include: `computer`, `phone`, `tablet`, + `tv`, `console`, `wearable`, `unknown`.' + example: + - computer + items: + type: string + type: array + operatingSystem: + description: Returns analytics based on the operating system used by + the viewers. Response values can include `windows`, `mac osx`, `android`, + `ios`, `linux`. + example: + - windows + items: + type: string + type: array + browser: + description: Returns analytics based on the browser used by the viewers. + Response values can include `chrome`, `firefox`, `edge`, `opera`. + example: + - firefox + items: + type: string + type: array + tag: + description: Returns analytics for videos using this tag. This filter + only accepts a single value and is case sensitive. Read more about + tagging your videos [here](https://docs.api.video/vod/tags-metadata). + example: Cool videos + type: string + type: object + style: deepObject + x-is-deep-object: true responses: "200": content: application/json: examples: - Dimension is videoId: - description: Breakdown video-plays by videoId for a project. + Impression time from a certain date: value: - data: - - value: vi3q7HxhApxRF1c8F8r6VeaI - plays: 100 - - value: vi3q7HxhApxRF1c8F8r6VeaF - plays: 10 - - value: vi3q7HxhApxRF1c8F8r6VeaH - plays: 1 - pagination: - currentPage: 1 - currentPageItems: 3 - pageSize: 25 - pagesTotal: 1 - itemsTotal: 3 - links: - - rel: self - uri: /analytics/videos/plays?dimension=videoId¤tPage=1&pageSize=25 - - rel: first - uri: /analytics/videos/plays?dimension=videoId¤tPage=1&pageSize=25 - - rel: last - uri: /analytics/videos/plays?dimension=videoId¤tPage=1&pageSize=25 - Dimension is country: - description: Breakdown video-plays by country for a project, with - pagination set. - value: - data: - - value: france - plays: 100 - - value: united states - plays: 10 - - value: spain - plays: 1 - pagination: - currentPage: 1 - currentPageItems: 2 - pageSize: 2 - pagesTotal: 2 - itemsTotal: 3 - links: - - rel: self - uri: /analytics/videos/plays?dimension=country¤tPage=1&pageSize=2 - - rel: first - uri: /analytics/videos/plays?dimension=country¤tPage=1&pageSize=2 - - rel: next - uri: /analytics/videos/plays?dimension=country¤tPage=2&pageSize=1 - - rel: last - uri: /analytics/videos/plays?dimension=country¤tPage=2&pageSize=1 - Dimension is emittedAt, filtered for a videoId: - description: Breakdown video-plays by the time of play events, for - a specific video. - value: - data: - - value: 2023-06-10T10:00:00.000Z - plays: 100 - - value: 2023-06-10T11:00:00.000Z - plays: 10 - - value: 2023-06-10T12:00:00.000Z - plays: 1 - pagination: - currentPage: 1 - currentPageItems: 3 - pageSize: 25 - pagesTotal: 1 - itemsTotal: 3 - links: - - rel: self - uri: /analytics/videos/plays?dimension=videoId&filter=videoId:vi3VooPMbQLWdPF26qfmNVX6¤tPage=1&pageSize=25 - - rel: first - uri: /analytics/videos/plays?dimension=videoId&filter=videoId:vi3VooPMbQLWdPF26qfmNVX6¤tPage=1&pageSize=25 - - rel: last - uri: /analytics/videos/plays?dimension=videoId&filter=videoId:vi3VooPMbQLWdPF26qfmNVX6¤tPage=1&pageSize=25 + context: + metric: impression + aggregation: count + timeframe: + from: 2024-05-28T11:15:07+00:00 + to: 2024-05-29T11:15:07+00:00 + data: 346.5 schema: - $ref: '#/components/schemas/analytics-plays-response' + $ref: '#/components/schemas/analytics-aggregated-metrics-response' description: Success headers: X-RateLimit-Limit: @@ -11253,61 +11409,26 @@ paths: content: application/json: examples: - Missing parameter: - description: This error occurs when a required query-parameter is - missing. + Invalid attribute: + description: This error occurs when a parameter you provided does + not exist, or isn't correct for this endpoint, has an invalid + value. value: type: https://docs.api.video/reference/invalid-attribute title: An attribute is invalid. status: 400 detail: This value must be of type string. - name: dimension - Invalid parameter: - description: This error occurs when a required query-parameter format - is invalid. - value: - type: https://docs.api.video/reference/request-invalid-query-parameter - title: A query parameter is invalid. - status: 400 - detail: 'This value must be of the following structure(s): videoId:{videoId}' - name: filter - Dimension not allowed: - description: This error occurs when the dimension you requested - is not allowed for the endpoint. For example, the dimension `videoId` - is not allowed for the `/live-streams` endpoint. - value: - type: https://docs.api.video/reference/request-invalid-query-parameter - title: A query parameter is invalid. - status: 400 - detail: 'This value must be part of the following values: emittedAt,videoId,country,deviceType,operatingSystem,browser' - name: dimension - Dimension unknown: - description: This error occurs when the dimension you requested - is unknown. - value: - type: https://docs.api.video/reference/request-invalid-query-parameter - title: A query parameter is invalid. - status: 400 - detail: 'This value must be part of the following values: emittedAt,videoId,country,deviceType,operatingSystem,browser' - name: dimension - Invalid filter: - description: This error occurs when the format of the filter you - requested is invalid. - value: - type: https://docs.api.video/reference/request-invalid-query-parameter - title: A query parameter is invalid. - status: 400 - detail: 'This value must be of the following structure(s): videoId:{videoId}' - name: filter - Invalid videoId: - description: This error occurs when the videoId you requested does - not refer to an existing video. + name: metric + Invalid query parameter: + description: This error occurs when a query parameter you provided + does not exist, isn't correct for this endpoint, or has an invalid + value. value: type: https://docs.api.video/reference/request-invalid-query-parameter title: A query parameter is invalid. status: 400 - detail: This value must refer to an existing video - name: filter + detail: This field was not expected. + name: from:2024-05-20T09:15:05+02:00 schema: $ref: '#/components/schemas/analytics-plays-400-error' description: Bad request error @@ -11332,18 +11453,18 @@ paths: schema: type: integer style: simple - "403": + "404": content: application/json: examples: - Analytics is disabled: + Unrecognized request URL: value: - type: https://docs.api.video/reference/authorization-disabled-analytics - title: You cannot get analytics from this project. - status: 403 + type: https://docs.api.video/reference/unrecognized-request-url + title: Unrecognized request URL. + status: 404 schema: - $ref: '#/components/schemas/403-error-schema' - description: Forbidden - Disabled Analytics + $ref: '#/components/schemas/unrecognized-request-url' + description: Unrecognized request URL headers: X-RateLimit-Limit: description: The request limit per minute. @@ -11365,19 +11486,18 @@ paths: schema: type: integer style: simple - "404": + "429": content: application/json: examples: - Endpoint not found: + Too many requests: value: - type: null - title: null - name: null - status: 404 + type: https://docs.api.video/reference/too-many-requests + title: Too many requests. + status: 429 schema: - $ref: '#/components/schemas/not-found' - description: Not Found + $ref: '#/components/schemas/too-many-requests' + description: Too Many Requests headers: X-RateLimit-Limit: description: The request limit per minute. @@ -11399,11 +11519,376 @@ paths: schema: type: integer style: simple - "429": - content: - application/json: + security: + - apiKey: [] + summary: Retrieve aggregated metrics + tags: + - Analytics + x-client-action: getAggregatedMetrics + x-group-parameters: true + x-doctave: {} + /data/buckets/{metric}/{breakdown}: + get: + description: Retrieve detailed analytics play-rate and number of impressions + segmented by dimensions like country or device type. + operationId: GET_metrics-breakdown + parameters: + - description: | + Use this path parameter to select a metric that you want analytics for. + + - `play` is the number of times your content has been played. + - `play-rate` is the ratio that calculates the number of plays your content receives divided by its impressions. + - `play-total` is the total number of times a specific content has been played. You can only use the `media-id` breakdown with this metric. + - `start` is the number of times playback was started. + - `end` is the number of times playback has ended with the content watch until the end. + - `impression` is the number of times your content has been loaded and was ready for playback. + explode: false + in: path + name: metric + required: true + schema: + enum: + - play + - play-rate + - play-total + - start + - end + - impression + type: string + style: simple + - description: "Use this path parameter to define a dimension for segmenting\ + \ analytics data. You must use `kebab-case` for path parameters.\n\nThese\ + \ are the available dimensions:\n\n- `media-id`: Returns analytics based\ + \ on the unique identifiers of a video or a live stream.\n- `media-type`:\ + \ Returns analytics based on the type of content. Possible values: `video`\ + \ and `live-stream`. \n- `continent`: Returns analytics based on the viewers'\ + \ continent. The list of supported continents names are based on the [GeoNames\ + \ public database](https://www.geonames.org/countries/). Possible values\ + \ are: `AS`, `AF`, `NA`, `SA`, `AN`, `EU`, `AZ`. \n- `country`: Returns\ + \ analytics based on the viewers' country. The list of supported country\ + \ names are based on the [GeoNames public database](https://www.geonames.org/countries/).\n\ + - `device-type`: Returns analytics based on the type of device used by the\ + \ viewers. Response values can include: `computer`, `phone`, `tablet`, `tv`,\ + \ `console`, `wearable`, `unknown`.\n- `operating-system`: Returns analytics\ + \ based on the operating system used by the viewers. Response values can\ + \ include `windows`, `mac osx`, `android`, `ios`, `linux`.\n- `browser`:\ + \ Returns analytics based on the browser used by the viewers. Response values\ + \ can include `chrome`, `firefox`, `edge`, `opera`.\n" + explode: false + in: path + name: breakdown + required: true + schema: + enum: + - media-id + - media-type + - continent + - country + - device-type + - operating-system + - browser + type: string + style: simple + - description: | + Use this query parameter to define the starting date-time of the period you want analytics for. + + - If you do not set a value for `from`, the default assigned value is 1 day ago, based on the `to` parameter. + - The maximum value is 30 days ago. + - The value you provide should follow the ATOM date-time format: `2024-02-05T00:00:00+01:00` + example: 2024-02-05T00:00:00+01:00 + explode: false + in: query + name: from + required: false + schema: + format: date-time + type: string + style: form + - description: | + Use this query parameter to define the ending date-time of the period you want analytics for. + + - If you do not set a value for `to`, the default assigned value is `now`. + - The value for `to` is a non-inclusive value: the API returns data **before** the date-time that you set. + example: 2024-02-06T00:00:00+01:00 + explode: false + in: query + name: to + required: false + schema: + format: date-time + type: string + style: form + - $ref: '#/components/parameters/filterBy_2' + description: "Use this parameter to filter the API's response based on different\ + \ data dimensions. You can serialize filters in your query to receive more\ + \ detailed breakdowns of your analytics.\n\n- If you do not set a value\ + \ for `filterBy`, the API returns the full dataset for your project.\n-\ + \ The API only accepts the `mediaId` and `mediaType` filters when you call\ + \ `/data/metrics/play/total` or `/data/buckets/play-total/media-id`.\n\n\ + These are the available breakdown dimensions:\n\n- `mediaId`: Returns analytics\ + \ based on the unique identifiers of a video or a live stream.\n- `mediaType`:\ + \ Returns analytics based on the type of content. Possible values: `video`\ + \ and `live-stream`. \n- `continent`: Returns analytics based on the viewers'\ + \ continent. The list of supported continents names are based on the [GeoNames\ + \ public database](https://www.geonames.org/countries/). You must use the\ + \ ISO-3166 alpha2 format, for example `EU`. Possible values are: `AS`, `AF`,\ + \ `NA`, `SA`, `AN`, `EU`, `AZ`. \n- `country`: Returns analytics based on\ + \ the viewers' country. The list of supported country names are based on\ + \ the [GeoNames public database](https://www.geonames.org/countries/). You\ + \ must use the ISO-3166 alpha2 format, for example `FR`.\n- `deviceType`:\ + \ Returns analytics based on the type of device used by the viewers. Response\ + \ values can include: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`,\ + \ `unknown`.\n- `operatingSystem`: Returns analytics based on the operating\ + \ system used by the viewers. Response values can include `windows`, `mac\ + \ osx`, `android`, `ios`, `linux`.\n- `browser`: Returns analytics based\ + \ on the browser used by the viewers. Response values can include `chrome`,\ + \ `firefox`, `edge`, `opera`.\n- `tag`: Returns analytics for videos using\ + \ this tag. This filter only accepts a single value and is case sensitive.\ + \ Read more about tagging your videos [here](https://docs.api.video/vod/tags-metadata).\n" + example: filterBy[country]=FR&filterBy[operatingSystem]=windows&filterBy[browser][]=firefox&filterBy[browser][]=chrome&filterBy[tag]=Cool + videos + explode: true + in: query + name: filterBy + required: false + schema: + properties: + mediaId: + description: Returns analytics based on the unique identifiers of a + video or a live stream. + example: + - vi4blUQJFrYWbaG44NChkH27 + items: + type: string + type: array + mediaType: + enum: + - video + - live-stream + example: video + type: string + continent: + description: Returns analytics based on the viewers' continent. The + list of supported continents names are based on the [GeoNames public + database](https://www.geonames.org/countries/). You must use the ISO-3166 + alpha2 format, for example `EU`. + example: + - EU + items: + enum: + - AS + - AF + - NA + - SA + - AN + - EU + - AZ + type: string + type: array + country: + description: Returns analytics based on the viewers' country. The list + of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). + You must use the ISO-3166 alpha2 format, for example `FR`. + example: + - FR + items: + type: string + type: array + deviceType: + description: 'Returns analytics based on the type of device used by + the viewers. Response values can include: `computer`, `phone`, `tablet`, + `tv`, `console`, `wearable`, `unknown`.' + example: + - computer + items: + type: string + type: array + operatingSystem: + description: Returns analytics based on the operating system used by + the viewers. Response values can include `windows`, `mac osx`, `android`, + `ios`, `linux`. + example: + - windows + items: + type: string + type: array + browser: + description: Returns analytics based on the browser used by the viewers. + Response values can include `chrome`, `firefox`, `edge`, `opera`. + example: + - firefox + items: + type: string + type: array + tag: + description: Returns analytics for videos using this tag. This filter + only accepts a single value and is case sensitive. Read more about + tagging your videos [here](https://docs.api.video/vod/tags-metadata). + example: Cool videos + type: string + type: object + style: deepObject + x-is-deep-object: true + - description: 'Choose the number of search results to return per page. Minimum + value: 1' + example: 2 + explode: true + in: query + name: currentPage + required: false + schema: + default: 1 + type: integer + style: form + - description: Results per page. Allowed values 1-100, default is 25. + example: 30 + explode: true + in: query + name: pageSize + required: false + schema: + default: 25 + type: integer + style: form + responses: + "200": + content: + application/json: examples: - response: + Number of plays in a country over a specific timeframe: + value: + context: + metric: play + breakdown: country + timeframe: + from: 2024-04-28T07:15:05+00:00 + to: 2024-05-29T11:25:37+00:00 + data: + - metricValue: 7 + dimensionValue: FR + pagination: + currentPage: 1 + currentPageItems: 1 + pageSize: 25 + pagesTotal: 1 + itemsTotal: 1 + links: + - rel: self + uri: /data/buckets/play/country?from=2024-04-28T09%3A15%3A05%2B02%3A00¤tPage=1&pageSize=25 + - rel: first + uri: /data/buckets/play/country?from=2024-04-28T09%3A15%3A05%2B02%3A00¤tPage=1&pageSize=25 + - rel: last + uri: /data/buckets/play/country?from=2024-04-28T09%3A15%3A05%2B02%3A00¤tPage=1&pageSize=25 + schema: + $ref: '#/components/schemas/analytics-metrics-breakdown-response' + description: Success + headers: + X-RateLimit-Limit: + description: The request limit per minute. + explode: false + schema: + type: integer + style: simple + X-RateLimit-Remaining: + description: The number of available requests left for the current time + window. + explode: false + schema: + type: integer + style: simple + X-RateLimit-Retry-After: + description: The number of seconds left until the current rate limit + window resets. + explode: false + schema: + type: integer + style: simple + "400": + content: + application/json: + examples: + Invalid attribute: + description: This error occurs when a parameter you provided does + not exist, or isn't correct for this endpoint, has an invalid + value. + value: + type: https://docs.api.video/reference/invalid-attribute + title: An attribute is invalid. + status: 400 + detail: This value must be of type string. + name: metric + Invalid query parameter: + description: This error occurs when a query parameter you provided + does not exist, isn't correct for this endpoint, or has an invalid + value. + value: + type: https://docs.api.video/reference/request-invalid-query-parameter + title: A query parameter is invalid. + status: 400 + detail: This field was not expected. + name: from:2024-05-20T09:15:05+02:00 + schema: + $ref: '#/components/schemas/analytics-plays-400-error' + description: Bad request error + headers: + X-RateLimit-Limit: + description: The request limit per minute. + explode: false + schema: + type: integer + style: simple + X-RateLimit-Remaining: + description: The number of available requests left for the current time + window. + explode: false + schema: + type: integer + style: simple + X-RateLimit-Retry-After: + description: The number of seconds left until the current rate limit + window resets. + explode: false + schema: + type: integer + style: simple + "404": + content: + application/json: + examples: + Unrecognized request URL: + value: + type: https://docs.api.video/reference/unrecognized-request-url + title: Unrecognized request URL. + status: 404 + schema: + $ref: '#/components/schemas/unrecognized-request-url' + description: Unrecognized request URL + headers: + X-RateLimit-Limit: + description: The request limit per minute. + explode: false + schema: + type: integer + style: simple + X-RateLimit-Remaining: + description: The number of available requests left for the current time + window. + explode: false + schema: + type: integer + style: simple + X-RateLimit-Retry-After: + description: The number of seconds left until the current rate limit + window resets. + explode: false + schema: + type: integer + style: simple + "429": + content: + application/json: + examples: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -11434,380 +11919,197 @@ paths: style: simple security: - apiKey: [] - summary: Get play events for video + summary: Retrieve metrics in a breakdown of dimensions tags: - Analytics - x-client-action: getVideosPlays + x-client-action: getMetricsBreakdown x-group-parameters: true x-client-paginated: true - x-doctave: - code-samples: - - language: go - code: "package main\n\nimport (\n \"context\"\n \"fmt\"\n \"os\"\ - \n \"time\"\n apivideosdk \"github.com/apivideo/api.video-go-client\"\ - \n)\n\nfunc main() {\n client := apivideosdk.ClientBuilder(\"YOUR_API_KEY\"\ - ).Build()\n // if you rather like to use the sandbox environment:\n\ - \ // client := apivideosdk.SandboxClientBuilder(\"YOU_SANDBOX_API_KEY\"\ - ).Build()\n req := apivideosdk.AnalyticsApiGetVideosPlaysRequest{}\n\ - \n req.From(time.Now()) // string | Use this query parameter to set\ - \ the start date for the time period that you want analytics for. - The\ - \ API returns analytics data including the day you set in `from`. - The\ - \ date you set must be **within the last 30 days**. - The value you provide\ - \ must follow the `YYYY-MM-DD` format. \n req.Dimension(\"browser\"\ - ) // string | Use this query parameter to define the dimension that you\ - \ want analytics for. - `videoId`: Returns analytics based on the public\ - \ video identifiers. - `emittedAt`: Returns analytics based on the times\ - \ of the play events. The API returns data in specific interval groups.\ - \ When the date period you set in `from` and `to` is less than or equals\ - \ to 2 days, the response for this dimension is grouped in hourly intervals.\ - \ Otherwise, it is grouped in daily intervals. - `country`: Returns analytics\ - \ based on the viewers' country. The list of supported country names are\ - \ based on the [GeoNames public database](https://www.geonames.org/countries/).\ - \ - `deviceType`: Returns analytics based on the type of device used by\ - \ the viewers during the play event. - `operatingSystem`: Returns analytics\ - \ based on the operating system used by the viewers during the play event.\ - \ - `browser`: Returns analytics based on the browser used by the viewers\ - \ during the play event.\n req.To(time.Now()) // string | Use this\ - \ optional query parameter to set the end date for the time period that\ - \ you want analytics for. - If you do not specify a `to` date, the API\ - \ returns analytics data starting from the `from` date up until today,\ - \ and excluding today. - The date you set must be **within the last 30\ - \ days**. - The value you provide must follow the `YYYY-MM-DD` format.\ - \ \n req.Filter(\"videoId:vi3q7HxhApxRF1c8F8r6VeaI\") // string | Use\ - \ this query parameter to filter your results to a specific video in a\ - \ project that you want analytics for. You must use the `videoId:` prefix\ - \ when specifying a video ID.\n req.CurrentPage(int32(2)) // int32\ - \ | Choose the number of search results to return per page. Minimum value:\ - \ 1 (default to 1)\n req.PageSize(int32(30)) // int32 | Results per\ - \ page. Allowed values 1-100, default is 25. (default to 25)\n\n res,\ - \ err := client.Analytics.GetVideosPlays(req)\n\n\n if err != nil {\n\ - \ fmt.Fprintf(os.Stderr, \"Error when calling `Analytics.GetVideosPlays``:\ - \ %v\\n\", err)\n }\n // response from `GetVideosPlays`: AnalyticsPlaysResponse\n\ - \ fmt.Fprintf(os.Stdout, \"Response from `Analytics.GetVideosPlays`:\ - \ %v\\n\", res)\n}\n" - - language: node - code: "// First install the \"@api.video/nodejs-client\" npm package\n//\ - \ Documentation: https://github.com/apivideo/api.video-nodejs-client/blob/main/doc/api/AnalyticsApi.md#getVideosPlays\n\ - \nconst client = new ApiVideoClient({ apiKey: \"YOUR_API_KEY\" });\n\n\ - const from = \"2023-06-01\"; // Use this query parameter to set the start\ - \ date for the time period that you want analytics for. - The API returns\ - \ analytics data including the day you set in `from`. - The date you set\ - \ must be **within the last 30 days**. - The value you provide must follow\ - \ the `YYYY-MM-DD` format. \nconst dimension = \"videoId\"; // Use this\ - \ query parameter to define the dimension that you want analytics for.\ - \ - `videoId`: Returns analytics based on the public video identifiers.\ - \ - `emittedAt`: Returns analytics based on the times of the play events.\ - \ The API returns data in specific interval groups. When the date period\ - \ you set in `from` and `to` is less than or equals to 2 days, the response\ - \ for this dimension is grouped in hourly intervals. Otherwise, it is\ - \ grouped in daily intervals. - `country`: Returns analytics based on\ - \ the viewers' country. The list of supported country names are based\ - \ on the [GeoNames public database](https://www.geonames.org/countries/).\ - \ - `deviceType`: Returns analytics based on the type of device used by\ - \ the viewers during the play event. - `operatingSystem`: Returns analytics\ - \ based on the operating system used by the viewers during the play event.\ - \ - `browser`: Returns analytics based on the browser used by the viewers\ - \ during the play event.\nconst to = \"2023-06-10\"; // Use this optional\ - \ query parameter to set the end date for the time period that you want\ - \ analytics for. - If you do not specify a `to` date, the API returns\ - \ analytics data starting from the `from` date up until today, and excluding\ - \ today. - The date you set must be **within the last 30 days**. - The\ - \ value you provide must follow the `YYYY-MM-DD` format. \nconst filter\ - \ = \"videoId:vi3q7HxhApxRF1c8F8r6VeaI\"; // Use this query parameter\ - \ to filter your results to a specific video in a project that you want\ - \ analytics for. You must use the `videoId:` prefix when specifying a\ - \ video ID.\nconst currentPage = 1; // Choose the number of search results\ - \ to return per page. Minimum value: 1\nconst pageSize = 25; // Results\ - \ per page. Allowed values 1-100, default is 25.\n\nconst videoPlays =\ - \ await client.analytics.getVideosPlays({\n from, dimension, to, filter,\ - \ currentPage, pageSize\n});" - - language: python - code: "import apivideo\nfrom apivideo.api import analytics_api\nfrom apivideo.model.analytics_plays_response\ - \ import AnalyticsPlaysResponse\nfrom apivideo.model.not_found import\ - \ NotFound\nfrom apivideo.model.analytics_plays400_error import AnalyticsPlays400Error\n\ - from pprint import pprint\n\n# Enter a context with an instance of the\ - \ API client\nwith apivideo.AuthenticatedApiClient(__API_KEY__) as api_client:\n\ - \ # Create an instance of the API class\n api_instance = analytics_api.AnalyticsApi(api_client)\n\ - \ _from = dateutil_parser('2023-06-01').date() # date | Use this query\ - \ parameter to set the start date for the time period that you want analytics\ - \ for. - The API returns analytics data including the day you set in `from`.\ - \ - The date you set must be **within the last 30 days**. - The value\ - \ you provide must follow the `YYYY-MM-DD` format. \n dimension = \"\ - browser\" # str | Use this query parameter to define the dimension that\ - \ you want analytics for. - `videoId`: Returns analytics based on the\ - \ public video identifiers. - `emittedAt`: Returns analytics based on\ - \ the times of the play events. The API returns data in specific interval\ - \ groups. When the date period you set in `from` and `to` is less than\ - \ or equals to 2 days, the response for this dimension is grouped in hourly\ - \ intervals. Otherwise, it is grouped in daily intervals. - `country`:\ - \ Returns analytics based on the viewers' country. The list of supported\ - \ country names are based on the [GeoNames public database](https://www.geonames.org/countries/).\ - \ - `deviceType`: Returns analytics based on the type of device used by\ - \ the viewers during the play event. - `operatingSystem`: Returns analytics\ - \ based on the operating system used by the viewers during the play event.\ - \ - `browser`: Returns analytics based on the browser used by the viewers\ - \ during the play event.\n to = dateutil_parser('2023-06-10').date()\ - \ # date | Use this optional query parameter to set the end date for the\ - \ time period that you want analytics for. - If you do not specify a `to`\ - \ date, the API returns analytics data starting from the `from` date up\ - \ until today, and excluding today. - The date you set must be **within\ - \ the last 30 days**. - The value you provide must follow the `YYYY-MM-DD`\ - \ format. (optional)\n filter = \"videoId:vi3q7HxhApxRF1c8F8r6VeaI\"\ - \ # str | Use this query parameter to filter your results to a specific\ - \ video in a project that you want analytics for. You must use the `videoId:`\ - \ prefix when specifying a video ID. (optional)\n current_page = 2\ - \ # int | Choose the number of search results to return per page. Minimum\ - \ value: 1 (optional) if omitted the server will use the default value\ - \ of 1\n page_size = 30 # int | Results per page. Allowed values 1-100,\ - \ default is 25. (optional) if omitted the server will use the default\ - \ value of 25\n\n # example passing only required values which don't\ - \ have defaults set\n try:\n # Get play events for video\n \ - \ api_response = api_instance.get_videos_plays(_from, dimension)\n\ - \ pprint(api_response)\n except apivideo.ApiException as e:\n\ - \ print(\"Exception when calling AnalyticsApi->get_videos_plays:\ - \ %s\\n\" % e)\n\n # example passing only required values which don't\ - \ have defaults set\n # and optional values\n try:\n # Get\ - \ play events for video\n api_response = api_instance.get_videos_plays(_from,\ - \ dimension, to=to, filter=filter, current_page=current_page, page_size=page_size)\n\ - \ pprint(api_response)\n except apivideo.ApiException as e:\n\ - \ print(\"Exception when calling AnalyticsApi->get_videos_plays:\ - \ %s\\n\" % e)\n" - - language: java - code: "// Import classes:\nimport video.api.client.ApiVideoClient;\nimport\ - \ video.api.client.api.ApiException;\nimport video.api.client.api.models.*;\n\ - import video.api.client.api.clients.AnalyticsApi;\nimport java.util.*;\n\ - \npublic class Example {\n public static void main(String[] args) {\n\ - \ ApiVideoClient client = new ApiVideoClient(\"YOUR_API_KEY\");\n \ - \ // if you rather like to use the sandbox environment:\n // ApiVideoClient\ - \ client = new ApiVideoClient(\"YOUR_SANDBOX_API_KEY\", Environment.SANDBOX);\n\ - \n AnalyticsApi apiInstance = client.analytics();\n\n LocalDate\ - \ from = LocalDate.parse(\"2023-06-01\"); // Use this query parameter\ - \ to set the start date for the time period that you want analytics for.\ - \ - The API returns analytics data including the day you set in `from`.\ - \ - The date you set must be **within the last 30 days**. - The value\ - \ you provide must follow the `YYYY-MM-DD` format. \n String dimension\ - \ = \"videoId\"; // Use this query parameter to define the dimension that\ - \ you want analytics for. - `videoId`: Returns analytics based on the\ - \ public video identifiers. - `emittedAt`: Returns analytics based on\ - \ the times of the play events. The API returns data in specific interval\ - \ groups. When the date period you set in `from` and `to` is less than\ - \ or equals to 2 days, the response for this dimension is grouped in hourly\ - \ intervals. Otherwise, it is grouped in daily intervals. - `country`:\ - \ Returns analytics based on the viewers' country. The list of supported\ - \ country names are based on the [GeoNames public database](https://www.geonames.org/countries/).\ - \ - `deviceType`: Returns analytics based on the type of device used by\ - \ the viewers during the play event. - `operatingSystem`: Returns analytics\ - \ based on the operating system used by the viewers during the play event.\ - \ - `browser`: Returns analytics based on the browser used by the viewers\ - \ during the play event.\n LocalDate to = LocalDate.parse(\"2023-06-10\"\ - ); // Use this optional query parameter to set the end date for the time\ - \ period that you want analytics for. - If you do not specify a `to` date,\ - \ the API returns analytics data starting from the `from` date up until\ - \ today, and excluding today. - The date you set must be **within the\ - \ last 30 days**. - The value you provide must follow the `YYYY-MM-DD`\ - \ format. \n String filter = \"videoId:vi3q7HxhApxRF1c8F8r6VeaI\";\ - \ // Use this query parameter to filter your results to a specific video\ - \ in a project that you want analytics for. You must use the `videoId:`\ - \ prefix when specifying a video ID.\n Integer currentPage = 1; //\ - \ Choose the number of search results to return per page. Minimum value:\ - \ 1\n Integer pageSize = 25; // Results per page. Allowed values 1-100,\ - \ default is 25.\n\n try {\n Page result = apiInstance.getVideosPlays(from,\ - \ dimension)\n .to(to)\n .filter(filter)\n \ - \ .currentPage(currentPage)\n .pageSize(pageSize)\n \ - \ .execute();\n System.out.println(result);\n } catch\ - \ (ApiException e) {\n System.err.println(\"Exception when calling\ - \ AnalyticsApi#getVideosPlays\");\n System.err.println(\"Status code:\ - \ \" + e.getCode());\n System.err.println(\"Reason: \" + e.getMessage());\n\ - \ System.err.println(\"Response headers: \" + e.getResponseHeaders());\n\ - \ e.printStackTrace();\n }\n }\n}\n" - - language: csharp - code: "using System.Diagnostics;\nusing ApiVideo.Client;\n\nnamespace Example\n\ - {\n public class getVideosPlaysExample\n {\n public static\ - \ void Main()\n {\n var basePath = ApiVideoClient.Client.Environment.SANDBOX;\n\ - \ var apiKey = \"YOUR_API_KEY\";\n\n var apiInstance\ - \ = new ApiVideoClient(apiKey,basePath);\n\n var from = 2023-06-01;\ - \ // DateTime | Use this query parameter to set the start date for the\ - \ time period that you want analytics for. - The API returns analytics\ - \ data including the day you set in `from`. - The date you set must be\ - \ **within the last 30 days**. - The value you provide must follow the\ - \ `YYYY-MM-DD` format. \n var dimension = browser; // string\ - \ | Use this query parameter to define the dimension that you want analytics\ - \ for. - `videoId`: Returns analytics based on the public video identifiers.\ - \ - `emittedAt`: Returns analytics based on the times of the play events.\ - \ The API returns data in specific interval groups. When the date period\ - \ you set in `from` and `to` is less than or equals to 2 days, the response\ - \ for this dimension is grouped in hourly intervals. Otherwise, it is\ - \ grouped in daily intervals. - `country`: Returns analytics based on\ - \ the viewers' country. The list of supported country names are based\ - \ on the [GeoNames public database](https://www.geonames.org/countries/).\ - \ - `deviceType`: Returns analytics based on the type of device used by\ - \ the viewers during the play event. - `operatingSystem`: Returns analytics\ - \ based on the operating system used by the viewers during the play event.\ - \ - `browser`: Returns analytics based on the browser used by the viewers\ - \ during the play event.\n var to = 2023-06-10; // DateTime?\ - \ | Use this optional query parameter to set the end date for the time\ - \ period that you want analytics for. - If you do not specify a `to` date,\ - \ the API returns analytics data starting from the `from` date up until\ - \ today, and excluding today. - The date you set must be **within the\ - \ last 30 days**. - The value you provide must follow the `YYYY-MM-DD`\ - \ format. (optional) \n var filter = videoId:vi3q7HxhApxRF1c8F8r6VeaI;\ - \ // string | Use this query parameter to filter your results to a specific\ - \ video in a project that you want analytics for. You must use the `videoId:`\ - \ prefix when specifying a video ID. (optional) \n var currentPage\ - \ = 2; // int? | Choose the number of search results to return per page.\ - \ Minimum value: 1 (optional) (default to 1)\n var pageSize\ - \ = 30; // int? | Results per page. Allowed values 1-100, default is\ - \ 25. (optional) (default to 25)\n var apiAnalyticsInstance\ - \ = apiInstance.Analytics();\n try\n {\n \ - \ // Get play events for video\n AnalyticsPlaysResponse\ - \ result = apiAnalyticsInstance.getVideosPlays(from, dimension, to, filter,\ - \ currentPage, pageSize);\n Debug.WriteLine(result);\n\ - \ }\n catch (ApiException e)\n {\n \ - \ Debug.Print(\"Exception when calling AnalyticsApi.getVideosPlays:\ - \ \" + e.Message );\n Debug.Print(\"Status Code: \"+ e.ErrorCode);\n\ - \ Debug.Print(e.StackTrace);\n }\n }\n\ - \ }\n}\n" - - language: php - code: "analytics()->getVideosPlays($from,\ - \ $dimension, array(\n 'to' => new \\DateTime('2023-06-10'), // Use\ - \ this optional query parameter to set the end date for the time period\ - \ that you want analytics for. - If you do not specify a `to` date, the\ - \ API returns analytics data starting from the `from` date up until today,\ - \ and excluding today. - The date you set must be **within the last 30\ - \ days**. - The value you provide must follow the `YYYY-MM-DD` format.\ - \ \n 'filter' => \"videoId:vi3q7HxhApxRF1c8F8r6VeaI\", // Use this\ - \ query parameter to filter your results to a specific video in a project\ - \ that you want analytics for. You must use the `videoId:` prefix when\ - \ specifying a video ID.\n 'currentPage' => 2, // Choose the number\ - \ of search results to return per page. Minimum ->setvalue(1)\n 'pageSize'\ - \ => 30 // Results per page. Allowed values 1-100, default is 25.\n)); " - - language: swift - code: "// The following code samples are still beta. For any issue, please\ - \ report via http://github.com/OpenAPITools/openapi-generator/issues/new\n\ - import ApiVideoClient\n\nlet from = Date() // Date | Use this query parameter\ - \ to set the start date for the time period that you want analytics for.\ - \ - The API returns analytics data including the day you set in `from`.\ - \ - The date you set must be **within the last 30 days**. - The value\ - \ you provide must follow the `YYYY-MM-DD` format. \nlet dimension = \"\ - dimension_example\" // String | Use this query parameter to define the\ - \ dimension that you want analytics for. - `videoId`: Returns analytics\ - \ based on the public video identifiers. - `emittedAt`: Returns analytics\ - \ based on the times of the play events. The API returns data in specific\ - \ interval groups. When the date period you set in `from` and `to` is\ - \ less than or equals to 2 days, the response for this dimension is grouped\ - \ in hourly intervals. Otherwise, it is grouped in daily intervals. -\ - \ `country`: Returns analytics based on the viewers' country. The list\ - \ of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/).\ - \ - `deviceType`: Returns analytics based on the type of device used by\ - \ the viewers during the play event. - `operatingSystem`: Returns analytics\ - \ based on the operating system used by the viewers during the play event.\ - \ - `browser`: Returns analytics based on the browser used by the viewers\ - \ during the play event.\nlet to = Date() // Date | Use this optional\ - \ query parameter to set the end date for the time period that you want\ - \ analytics for. - If you do not specify a `to` date, the API returns\ - \ analytics data starting from the `from` date up until today, and excluding\ - \ today. - The date you set must be **within the last 30 days**. - The\ - \ value you provide must follow the `YYYY-MM-DD` format. (optional)\n\ - let filter = \"filter_example\" // String | Use this query parameter to\ - \ filter your results to a specific video in a project that you want analytics\ - \ for. You must use the `videoId:` prefix when specifying a video ID.\ - \ (optional)\nlet currentPage = 987 // Int | Choose the number of search\ - \ results to return per page. Minimum value: 1 (optional) (default to\ - \ 1)\nlet pageSize = 987 // Int | Results per page. Allowed values 1-100,\ - \ default is 25. (optional) (default to 25)\n\n// Get play events for\ - \ video\nAnalyticsAPI.getVideosPlays(from: from, dimension: dimension,\ - \ to: to, filter: filter, currentPage: currentPage, pageSize: pageSize)\ - \ { (response, error) in\n guard error == nil else {\n print(error)\n\ - \ return\n }\n\n if (response) {\n dump(response)\n\ - \ }\n}\n" - /analytics/live-streams/plays: + x-doctave: {} + /data/timeseries/{metric}: get: - description: Retrieve filtered analytics about the number of plays for your - live streams in a project. - operationId: GET_analytics-live-streams-plays + description: Retrieve countable metrics like the number of plays or impressions, + grouped by the time at which they occurred + operationId: GET_metrics-over-time parameters: - description: | - Use this query parameter to set the start date for the time period that you want analytics for. - - The API returns analytics data including the day you set in `from`. - - The date you set must be **within the last 30 days**. - - The value you provide must follow the `YYYY-MM-DD` format. - example: 2023-06-01 - explode: true + Use this path parameter to select a metric that you want analytics for. + + - `play` is the number of times your content has been played. + - `play-rate` is the ratio that calculates the number of plays your content receives divided by its impressions. + - `start` is the number of times playback was started. + - `end` is the number of times playback has ended with the content watch until the end. + - `impression` is the number of times your content has been loaded and was ready for playback. + explode: false + in: path + name: metric + required: true + schema: + enum: + - play + - play-rate + - start + - end + - impression + type: string + style: simple + - description: | + Use this query parameter to define the starting date-time of the period you want analytics for. + + - If you do not set a value for `from`, the default assigned value is 1 day ago, based on the `to` parameter. + - The maximum value is 30 days ago. + - The value you provide should follow the ATOM date-time format: `2024-02-05T00:00:00+01:00` + example: 2024-02-05T00:00:00+01:00 + explode: false in: query name: from - required: true + required: false schema: - format: date + format: date-time type: string style: form - description: | - Use this optional query parameter to set the end date for the time period that you want analytics for. - - If you do not specify a `to` date, the API returns analytics data starting from the `from` date up until today, and excluding today. - - The date you set must be **within the last 30 days**. - - The value you provide must follow the `YYYY-MM-DD` format. - example: 2023-06-10 - explode: true + Use this query parameter to define the ending date-time of the period you want analytics for. + + - If you do not set a value for `to`, the default assigned value is `now`. + - The value for `to` is a non-inclusive value: the API returns data **before** the date-time that you set. + example: 2024-02-06T00:00:00+01:00 + explode: false in: query name: to required: false schema: - format: date + format: date-time type: string style: form - - description: |- - Use this query parameter to define the dimension that you want analytics for. - - `liveStreamId`: Returns analytics based on the public live stream identifiers. - - `emittedAt`: Returns analytics based on the times of the play events. The API returns data in specific interval groups. When the date period you set in `from` and `to` is less than or equals to 2 days, the response for this dimension is grouped in hourly intervals. Otherwise, it is grouped in daily intervals. - - `country`: Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). - - `deviceType`: Returns analytics based on the type of device used by the viewers during the play event. Possible response values are: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. - - `operatingSystem`: Returns analytics based on the operating system used by the viewers during the play event. Response values include `windows`, `mac osx`, `android`, `ios`, `linux`. - - `browser`: Returns analytics based on the browser used by the viewers during the play event. Response values include `chrome`, `firefox`, `edge`, `opera`. - example: browser + - description: | + Use this query parameter to define how granularity of the data. Possible values: `hour`, `day`. + + - Default: If no interval specified and the period (different between from and to) ≤ 2 days then hour, otherwise day. + + - If you do not set a value for `interval`, and the period you set using the `from` and `to` parameters is less than or equals to 2 days, then the default assigned value is `hour`. Otherwise the API sets it to `day`. + example: hour explode: false in: query - name: dimension - required: true + name: interval + required: false schema: enum: - - liveStreamId - - emittedAt - - country - - deviceType - - operatingSystem - - browser + - hour + - day type: string style: form - - description: Use this query parameter to filter your results to a specific - live stream in a project that you want analytics for. You must use the `liveStreamId:` - prefix when specifying a live stream ID. - example: liveStreamId:li3q7HxhApxRF1c8F8r6VeaI - explode: false + - $ref: '#/components/parameters/filterBy_2' + description: "Use this parameter to filter the API's response based on different\ + \ data dimensions. You can serialize filters in your query to receive more\ + \ detailed breakdowns of your analytics.\n\n- If you do not set a value\ + \ for `filterBy`, the API returns the full dataset for your project.\n-\ + \ The API only accepts the `mediaId` and `mediaType` filters when you call\ + \ `/data/metrics/play/total` or `/data/buckets/play-total/media-id`.\n\n\ + These are the available breakdown dimensions:\n\n- `mediaId`: Returns analytics\ + \ based on the unique identifiers of a video or a live stream.\n- `mediaType`:\ + \ Returns analytics based on the type of content. Possible values: `video`\ + \ and `live-stream`. \n- `continent`: Returns analytics based on the viewers'\ + \ continent. The list of supported continents names are based on the [GeoNames\ + \ public database](https://www.geonames.org/countries/). You must use the\ + \ ISO-3166 alpha2 format, for example `EU`. Possible values are: `AS`, `AF`,\ + \ `NA`, `SA`, `AN`, `EU`, `AZ`. \n- `country`: Returns analytics based on\ + \ the viewers' country. The list of supported country names are based on\ + \ the [GeoNames public database](https://www.geonames.org/countries/). You\ + \ must use the ISO-3166 alpha2 format, for example `FR`.\n- `deviceType`:\ + \ Returns analytics based on the type of device used by the viewers. Response\ + \ values can include: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`,\ + \ `unknown`.\n- `operatingSystem`: Returns analytics based on the operating\ + \ system used by the viewers. Response values can include `windows`, `mac\ + \ osx`, `android`, `ios`, `linux`.\n- `browser`: Returns analytics based\ + \ on the browser used by the viewers. Response values can include `chrome`,\ + \ `firefox`, `edge`, `opera`.\n- `tag`: Returns analytics for videos using\ + \ this tag. This filter only accepts a single value and is case sensitive.\ + \ Read more about tagging your videos [here](https://docs.api.video/vod/tags-metadata).\n" + example: filterBy[country]=FR&filterBy[operatingSystem]=windows&filterBy[browser][]=firefox&filterBy[browser][]=chrome&filterBy[tag]=Cool + videos + explode: true in: query - name: filter + name: filterBy required: false schema: - type: string - style: form + properties: + mediaId: + description: Returns analytics based on the unique identifiers of a + video or a live stream. + example: + - vi4blUQJFrYWbaG44NChkH27 + items: + type: string + type: array + mediaType: + enum: + - video + - live-stream + example: video + type: string + continent: + description: Returns analytics based on the viewers' continent. The + list of supported continents names are based on the [GeoNames public + database](https://www.geonames.org/countries/). You must use the ISO-3166 + alpha2 format, for example `EU`. + example: + - EU + items: + enum: + - AS + - AF + - NA + - SA + - AN + - EU + - AZ + type: string + type: array + country: + description: Returns analytics based on the viewers' country. The list + of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). + You must use the ISO-3166 alpha2 format, for example `FR`. + example: + - FR + items: + type: string + type: array + deviceType: + description: 'Returns analytics based on the type of device used by + the viewers. Response values can include: `computer`, `phone`, `tablet`, + `tv`, `console`, `wearable`, `unknown`.' + example: + - computer + items: + type: string + type: array + operatingSystem: + description: Returns analytics based on the operating system used by + the viewers. Response values can include `windows`, `mac osx`, `android`, + `ios`, `linux`. + example: + - windows + items: + type: string + type: array + browser: + description: Returns analytics based on the browser used by the viewers. + Response values can include `chrome`, `firefox`, `edge`, `opera`. + example: + - firefox + items: + type: string + type: array + tag: + description: Returns analytics for videos using this tag. This filter + only accepts a single value and is case sensitive. Read more about + tagging your videos [here](https://docs.api.video/vod/tags-metadata). + example: Cool videos + type: string + type: object + style: deepObject + x-is-deep-object: true - description: 'Choose the number of search results to return per page. Minimum value: 1' example: 2 @@ -11834,64 +12136,21 @@ paths: content: application/json: examples: - Dimension is liveStreamId: - description: Breakdown video-plays by liveStreamId for a project. - value: - data: - - value: li3q7HxhApxRF1c8F8r6VeaI - plays: 100 - - value: li3q7HxhApxRF1c8F8r6VeaB - plays: 10 - - value: li3q7HxhApxRF1c8F8r6VeaD - plays: 1 - pagination: - currentPage: 1 - currentPageItems: 2 - pageSize: 2 - pagesTotal: 2 - itemsTotal: 3 - links: - - rel: self - uri: /analytics/live-streams/plays?dimension=liveStreamId¤tPage=1&pageSize=2 - - rel: first - uri: /analytics/live-streams/plays?dimension=liveStreamId¤tPage=2&pageSize=1 - - rel: last - uri: /analytics/live-streams/plays?dimension=liveStreamId¤tPage=2&pageSize=1 - Dimension is country, paginated: - description: Breakdown video-plays by country for a project, with - pagination. - value: + Impression time from a certain date: + value: + context: + metric: play + interval: hour + timeframe: + from: 2024-05-28T11:08:39+00:00 + to: 2024-05-29T11:08:39+00:00 data: - - value: france - plays: 100 - - value: united states - plays: 10 - - value: spain - plays: 1 - pagination: - currentPage: 1 - currentPageItems: 2 - pageSize: 2 - pagesTotal: 2 - itemsTotal: 3 - links: - - rel: self - uri: /analytics/live-streams/plays?dimension=country¤tPage=1&pageSize=2 - - rel: first - uri: /analytics/live-streams/plays?dimension=country¤tPage=1&pageSize=2 - - rel: last - uri: /analytics/live-streams/plays?dimension=country¤tPage=2&pageSize=1 - Dimension is emittedAt, filtered for a liveStreamId: - description: Breakdown video-plays by the time of play events, for - a specific live stream. - value: - data: - - value: 2023-06-10T10:00:00.000Z - plays: 100 - - value: 2023-06-10T11:00:00.000Z - plays: 10 - - value: 2023-06-10T12:00:00.000Z - plays: 1 + - emittedAt: 2024-05-29T07:00:00+00:00 + metricValue: 2 + - emittedAt: 2024-05-29T08:00:00+00:00 + metricValue: 1 + - emittedAt: 2024-05-29T09:00:00+00:00 + metricValue: 1 pagination: currentPage: 1 currentPageItems: 3 @@ -11900,13 +12159,13 @@ paths: itemsTotal: 3 links: - rel: self - uri: /analytics/live-streams/plays?dimension=videoId&filter=liveStreamId:li3VooPMbQLWdPF26qfmNVX6¤tPage=1&pageSize=25 + uri: /data/timeseries/play?currentPage=1&pageSize=25 - rel: first - uri: /analytics/live-streams/plays?dimension=videoId&filter=liveStreamId:li3VooPMbQLWdPF26qfmNVX6¤tPage=1&pageSize=25 + uri: /data/timeseries/play?currentPage=1&pageSize=25 - rel: last - uri: /analytics/live-streams/plays?dimension=videoId&filter=liveStreamId:li3VooPMbQLWdPF26qfmNVX6¤tPage=1&pageSize=25 + uri: /data/timeseries/play?currentPage=1&pageSize=25 schema: - $ref: '#/components/schemas/analytics-plays-response' + $ref: '#/components/schemas/analytics-metrics-over-time-response' description: Success headers: X-RateLimit-Limit: @@ -11933,61 +12192,26 @@ paths: content: application/json: examples: - Missing parameter: - description: This error occurs when a required query-parameter is - missing. + Invalid attribute: + description: This error occurs when a parameter you provided does + not exist, or isn't correct for this endpoint, has an invalid + value. value: type: https://docs.api.video/reference/invalid-attribute title: An attribute is invalid. status: 400 detail: This value must be of type string. - name: dimension - Invalid parameter: - description: This error occurs when a required query-parameter format - is invalid. - value: - type: https://docs.api.video/reference/request-invalid-query-parameter - title: A query parameter is invalid. - status: 400 - detail: 'This value must be of the following structure(s): liveStreamId:{liveStreamId}' - name: filter - Dimension not allowed: - description: This error occurs when the dimension you requested - is not allowed for the endpoint. For example, the dimension `videoId` - is not allowed for the `/live-streams` endpoint. - value: - type: https://docs.api.video/reference/request-invalid-query-parameter - title: A query parameter is invalid. - status: 400 - detail: 'This value must be part of the following values: emittedAt,liveStreamId,country,deviceType,operatingSystem,browser' - name: dimension - Dimension unknown: - description: This error occurs when the dimension you requested - is unknown. - value: - type: https://docs.api.video/reference/request-invalid-query-parameter - title: A query parameter is invalid. - status: 400 - detail: 'This value must be part of the following values: emittedAt,liveStreamId,country,deviceType,operatingSystem,browser' - name: dimension - Invalid filter: - description: This error occurs when the format of the filter you - requested is invalid. + name: metric + Invalid query parameter: + description: This error occurs when a query parameter you provided + does not exist, isn't correct for this endpoint, or has an invalid + value. value: type: https://docs.api.video/reference/request-invalid-query-parameter title: A query parameter is invalid. status: 400 - detail: 'This value must be of the following structure(s): liveStreamId:{liveStreamId}' - name: filter - Invalid liveStreamId: - description: This error occurs when the liveStreamId you requested - does not refer to an existing live stream. - value: - type: https://docs.api.video/reference/request-invalid-query-parameter - title: A query parameter is invalid. - status: 400 - detail: This value must refer to an existing live stream - name: filter + detail: This field was not expected. + name: from:2024-05-20T09:15:05+02:00 schema: $ref: '#/components/schemas/analytics-plays-400-error' description: Bad request error @@ -12012,52 +12236,18 @@ paths: schema: type: integer style: simple - "403": - content: - application/json: - examples: - Analytics is disabled: - value: - type: https://docs.api.video/reference/authorization-disabled-analytics - title: You cannot get analytics from this project. - status: 403 - schema: - $ref: '#/components/schemas/403-error-schema' - description: Forbidden - Disabled Analytics - headers: - X-RateLimit-Limit: - description: The request limit per minute. - explode: false - schema: - type: integer - style: simple - X-RateLimit-Remaining: - description: The number of available requests left for the current time - window. - explode: false - schema: - type: integer - style: simple - X-RateLimit-Retry-After: - description: The number of seconds left until the current rate limit - window resets. - explode: false - schema: - type: integer - style: simple "404": content: application/json: examples: - Endpoint not found: + Unrecognized request URL: value: - type: null - title: null - name: null + type: https://docs.api.video/reference/unrecognized-request-url + title: Unrecognized request URL. status: 404 schema: - $ref: '#/components/schemas/not-found' - description: Not Found + $ref: '#/components/schemas/unrecognized-request-url' + description: Unrecognized request URL headers: X-RateLimit-Limit: description: The request limit per minute. @@ -12083,7 +12273,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -12114,314 +12304,45 @@ paths: style: simple security: - apiKey: [] - summary: Get play events for live stream + summary: Retrieve metrics over time tags: - Analytics - x-client-action: getLiveStreamsPlays + x-client-action: getMetricsOverTime x-group-parameters: true x-client-paginated: true x-doctave: code-samples: - - language: go - code: "package main\n\nimport (\n \"context\"\n \"fmt\"\n \"os\"\ - \n \"time\"\n apivideosdk \"github.com/apivideo/api.video-go-client\"\ - \n)\n\nfunc main() {\n client := apivideosdk.ClientBuilder(\"YOUR_API_KEY\"\ - ).Build()\n // if you rather like to use the sandbox environment:\n\ - \ // client := apivideosdk.SandboxClientBuilder(\"YOU_SANDBOX_API_KEY\"\ - ).Build()\n req := apivideosdk.AnalyticsApiGetLiveStreamsPlaysRequest{}\n\ - \n req.From(time.Now()) // string | Use this query parameter to set\ - \ the start date for the time period that you want analytics for. - The\ - \ API returns analytics data including the day you set in `from`. - The\ - \ date you set must be **within the last 30 days**. - The value you provide\ - \ must follow the `YYYY-MM-DD` format. \n req.Dimension(\"browser\"\ - ) // string | Use this query parameter to define the dimension that you\ - \ want analytics for. - `liveStreamId`: Returns analytics based on the\ - \ public live stream identifiers. - `emittedAt`: Returns analytics based\ - \ on the times of the play events. The API returns data in specific interval\ - \ groups. When the date period you set in `from` and `to` is less than\ - \ or equals to 2 days, the response for this dimension is grouped in hourly\ - \ intervals. Otherwise, it is grouped in daily intervals. - `country`:\ - \ Returns analytics based on the viewers' country. The list of supported\ - \ country names are based on the [GeoNames public database](https://www.geonames.org/countries/).\ - \ - `deviceType`: Returns analytics based on the type of device used by\ - \ the viewers during the play event. - `operatingSystem`: Returns analytics\ - \ based on the operating system used by the viewers during the play event.\ - \ - `browser`: Returns analytics based on the browser used by the viewers\ - \ during the play event.\n req.To(time.Now()) // string | Use this\ - \ optional query parameter to set the end date for the time period that\ - \ you want analytics for. - If you do not specify a `to` date, the API\ - \ returns analytics data starting from the `from` date up until today,\ - \ and excluding today. - The date you set must be **within the last 30\ - \ days**. - The value you provide must follow the `YYYY-MM-DD` format.\ - \ \n req.Filter(\"liveStreamId:li3q7HxhApxRF1c8F8r6VeaI\") // string\ - \ | Use this query parameter to filter your results to a specific live\ - \ stream in a project that you want analytics for. You must use the `liveStreamId:`\ - \ prefix when specifying a live stream ID.\n req.CurrentPage(int32(2))\ - \ // int32 | Choose the number of search results to return per page. Minimum\ - \ value: 1 (default to 1)\n req.PageSize(int32(30)) // int32 | Results\ - \ per page. Allowed values 1-100, default is 25. (default to 25)\n\n \ - \ res, err := client.Analytics.GetLiveStreamsPlays(req)\n\n\n if\ - \ err != nil {\n fmt.Fprintf(os.Stderr, \"Error when calling `Analytics.GetLiveStreamsPlays``:\ - \ %v\\n\", err)\n }\n // response from `GetLiveStreamsPlays`: AnalyticsPlaysResponse\n\ - \ fmt.Fprintf(os.Stdout, \"Response from `Analytics.GetLiveStreamsPlays`:\ - \ %v\\n\", res)\n}\n" - language: node - code: "// First install the \"@api.video/nodejs-client\" npm package\n//\ - \ Documentation: https://github.com/apivideo/api.video-nodejs-client/blob/main/doc/api/AnalyticsApi.md#getLiveStreamsPlays\n\ - \nconst client = new ApiVideoClient({ apiKey: \"YOUR_API_KEY\" });\n\n\ - const from = \"2023-06-01\"; // Use this query parameter to set the start\ - \ date for the time period that you want analytics for. - The API returns\ - \ analytics data including the day you set in `from`. - The date you set\ - \ must be **within the last 30 days**. - The value you provide must follow\ - \ the `YYYY-MM-DD` format. \nconst dimension = \"liveStreamId\"; // Use\ - \ this query parameter to define the dimension that you want analytics\ - \ for. - `liveStreamId`: Returns analytics based on the public live stream\ - \ identifiers. - `emittedAt`: Returns analytics based on the times of\ - \ the play events. The API returns data in specific interval groups. When\ - \ the date period you set in `from` and `to` is less than or equals to\ - \ 2 days, the response for this dimension is grouped in hourly intervals.\ - \ Otherwise, it is grouped in daily intervals. - `country`: Returns analytics\ - \ based on the viewers' country. The list of supported country names are\ - \ based on the [GeoNames public database](https://www.geonames.org/countries/).\ - \ - `deviceType`: Returns analytics based on the type of device used by\ - \ the viewers during the play event. - `operatingSystem`: Returns analytics\ - \ based on the operating system used by the viewers during the play event.\ - \ - `browser`: Returns analytics based on the browser used by the viewers\ - \ during the play event.\nconst to = \"2023-06-10\"; // Use this optional\ - \ query parameter to set the end date for the time period that you want\ - \ analytics for. - If you do not specify a `to` date, the API returns\ - \ analytics data starting from the `from` date up until today, and excluding\ - \ today. - The date you set must be **within the last 30 days**. - The\ - \ value you provide must follow the `YYYY-MM-DD` format. \nconst filter\ - \ = \"liveStreamId:li3q7HxhApxRF1c8F8r6VeaI\"; // Use this query parameter\ - \ to filter your results to a specific live stream in a project that you\ - \ want analytics for. You must use the `liveStreamId:` prefix when specifying\ - \ a live stream ID.\nconst currentPage = 1; // Choose the number of search\ - \ results to return per page. Minimum value: 1\nconst pageSize = 25; //\ - \ Results per page. Allowed values 1-100, default is 25.\n\nconst liveStreamsPlays\ - \ = await client.analytics.getLiveStreamsPlays({\n from, dimension, to,\ - \ filter, currentPage, pageSize\n});" - - language: python - code: "import apivideo\nfrom apivideo.api import analytics_api\nfrom apivideo.model.analytics_plays_response\ - \ import AnalyticsPlaysResponse\nfrom apivideo.model.not_found import\ - \ NotFound\nfrom apivideo.model.analytics_plays400_error import AnalyticsPlays400Error\n\ - from pprint import pprint\n\n# Enter a context with an instance of the\ - \ API client\nwith apivideo.AuthenticatedApiClient(__API_KEY__) as api_client:\n\ - \ # Create an instance of the API class\n api_instance = analytics_api.AnalyticsApi(api_client)\n\ - \ _from = dateutil_parser('2023-06-01').date() # date | Use this query\ - \ parameter to set the start date for the time period that you want analytics\ - \ for. - The API returns analytics data including the day you set in `from`.\ - \ - The date you set must be **within the last 30 days**. - The value\ - \ you provide must follow the `YYYY-MM-DD` format. \n dimension = \"\ - browser\" # str | Use this query parameter to define the dimension that\ - \ you want analytics for. - `liveStreamId`: Returns analytics based on\ - \ the public live stream identifiers. - `emittedAt`: Returns analytics\ - \ based on the times of the play events. The API returns data in specific\ - \ interval groups. When the date period you set in `from` and `to` is\ - \ less than or equals to 2 days, the response for this dimension is grouped\ - \ in hourly intervals. Otherwise, it is grouped in daily intervals. -\ - \ `country`: Returns analytics based on the viewers' country. The list\ - \ of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/).\ - \ - `deviceType`: Returns analytics based on the type of device used by\ - \ the viewers during the play event. - `operatingSystem`: Returns analytics\ - \ based on the operating system used by the viewers during the play event.\ - \ - `browser`: Returns analytics based on the browser used by the viewers\ - \ during the play event.\n to = dateutil_parser('2023-06-10').date()\ - \ # date | Use this optional query parameter to set the end date for the\ - \ time period that you want analytics for. - If you do not specify a `to`\ - \ date, the API returns analytics data starting from the `from` date up\ - \ until today, and excluding today. - The date you set must be **within\ - \ the last 30 days**. - The value you provide must follow the `YYYY-MM-DD`\ - \ format. (optional)\n filter = \"liveStreamId:li3q7HxhApxRF1c8F8r6VeaI\"\ - \ # str | Use this query parameter to filter your results to a specific\ - \ live stream in a project that you want analytics for. You must use the\ - \ `liveStreamId:` prefix when specifying a live stream ID. (optional)\n\ - \ current_page = 2 # int | Choose the number of search results to return\ - \ per page. Minimum value: 1 (optional) if omitted the server will use\ - \ the default value of 1\n page_size = 30 # int | Results per page.\ - \ Allowed values 1-100, default is 25. (optional) if omitted the server\ - \ will use the default value of 25\n\n # example passing only required\ - \ values which don't have defaults set\n try:\n # Get play events\ - \ for live stream\n api_response = api_instance.get_live_streams_plays(_from,\ - \ dimension)\n pprint(api_response)\n except apivideo.ApiException\ - \ as e:\n print(\"Exception when calling AnalyticsApi->get_live_streams_plays:\ - \ %s\\n\" % e)\n\n # example passing only required values which don't\ - \ have defaults set\n # and optional values\n try:\n # Get\ - \ play events for live stream\n api_response = api_instance.get_live_streams_plays(_from,\ - \ dimension, to=to, filter=filter, current_page=current_page, page_size=page_size)\n\ - \ pprint(api_response)\n except apivideo.ApiException as e:\n\ - \ print(\"Exception when calling AnalyticsApi->get_live_streams_plays:\ - \ %s\\n\" % e)\n" - - language: java - code: "// Import classes:\nimport video.api.client.ApiVideoClient;\nimport\ - \ video.api.client.api.ApiException;\nimport video.api.client.api.models.*;\n\ - import video.api.client.api.clients.AnalyticsApi;\nimport java.util.*;\n\ - \npublic class Example {\n public static void main(String[] args) {\n\ - \ ApiVideoClient client = new ApiVideoClient(\"YOUR_API_KEY\");\n \ - \ // if you rather like to use the sandbox environment:\n // ApiVideoClient\ - \ client = new ApiVideoClient(\"YOUR_SANDBOX_API_KEY\", Environment.SANDBOX);\n\ - \n AnalyticsApi apiInstance = client.analytics();\n\n LocalDate\ - \ from = LocalDate.parse(\"2023-06-01\"); // Use this query parameter\ - \ to set the start date for the time period that you want analytics for.\ - \ - The API returns analytics data including the day you set in `from`.\ - \ - The date you set must be **within the last 30 days**. - The value\ - \ you provide must follow the `YYYY-MM-DD` format. \n String dimension\ - \ = \"liveStreamId\"; // Use this query parameter to define the dimension\ - \ that you want analytics for. - `liveStreamId`: Returns analytics based\ - \ on the public live stream identifiers. - `emittedAt`: Returns analytics\ - \ based on the times of the play events. The API returns data in specific\ - \ interval groups. When the date period you set in `from` and `to` is\ - \ less than or equals to 2 days, the response for this dimension is grouped\ - \ in hourly intervals. Otherwise, it is grouped in daily intervals. -\ - \ `country`: Returns analytics based on the viewers' country. The list\ - \ of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/).\ - \ - `deviceType`: Returns analytics based on the type of device used by\ - \ the viewers during the play event. - `operatingSystem`: Returns analytics\ - \ based on the operating system used by the viewers during the play event.\ - \ - `browser`: Returns analytics based on the browser used by the viewers\ - \ during the play event.\n LocalDate to = LocalDate.parse(\"2023-06-10\"\ - ); // Use this optional query parameter to set the end date for the time\ - \ period that you want analytics for. - If you do not specify a `to` date,\ - \ the API returns analytics data starting from the `from` date up until\ - \ today, and excluding today. - The date you set must be **within the\ - \ last 30 days**. - The value you provide must follow the `YYYY-MM-DD`\ - \ format. \n String filter = \"liveStreamId:li3q7HxhApxRF1c8F8r6VeaI\"\ - ; // Use this query parameter to filter your results to a specific live\ - \ stream in a project that you want analytics for. You must use the `liveStreamId:`\ - \ prefix when specifying a live stream ID.\n Integer currentPage =\ - \ 1; // Choose the number of search results to return per page. Minimum\ - \ value: 1\n Integer pageSize = 25; // Results per page. Allowed values\ - \ 1-100, default is 25.\n\n try {\n Page result\ - \ = apiInstance.getLiveStreamsPlays(from, dimension)\n .to(to)\n\ - \ .filter(filter)\n .currentPage(currentPage)\n\ - \ .pageSize(pageSize)\n .execute();\n System.out.println(result);\n\ - \ } catch (ApiException e) {\n System.err.println(\"Exception\ - \ when calling AnalyticsApi#getLiveStreamsPlays\");\n System.err.println(\"\ - Status code: \" + e.getCode());\n System.err.println(\"Reason: \"\ - \ + e.getMessage());\n System.err.println(\"Response headers: \"\ - \ + e.getResponseHeaders());\n e.printStackTrace();\n }\n }\n\ - }\n" + code: | + const metrics = await client.analytics.getMetricsOverTime({ + metric: 'play', + filterBy: { + browser: ['chrome', 'firefox'], + continent: ['EU', 'AF'], + }, + }); - language: csharp - code: "using System.Diagnostics;\nusing ApiVideo.Client;\n\nnamespace Example\n\ - {\n public class getLiveStreamsPlaysExample\n {\n public\ - \ static void Main()\n {\n var basePath = ApiVideoClient.Client.Environment.SANDBOX;\n\ - \ var apiKey = \"YOUR_API_KEY\";\n\n var apiInstance\ - \ = new ApiVideoClient(apiKey,basePath);\n\n var from = 2023-06-01;\ - \ // DateTime | Use this query parameter to set the start date for the\ - \ time period that you want analytics for. - The API returns analytics\ - \ data including the day you set in `from`. - The date you set must be\ - \ **within the last 30 days**. - The value you provide must follow the\ - \ `YYYY-MM-DD` format. \n var dimension = browser; // string\ - \ | Use this query parameter to define the dimension that you want analytics\ - \ for. - `liveStreamId`: Returns analytics based on the public live stream\ - \ identifiers. - `emittedAt`: Returns analytics based on the times of\ - \ the play events. The API returns data in specific interval groups. When\ - \ the date period you set in `from` and `to` is less than or equals to\ - \ 2 days, the response for this dimension is grouped in hourly intervals.\ - \ Otherwise, it is grouped in daily intervals. - `country`: Returns analytics\ - \ based on the viewers' country. The list of supported country names are\ - \ based on the [GeoNames public database](https://www.geonames.org/countries/).\ - \ - `deviceType`: Returns analytics based on the type of device used by\ - \ the viewers during the play event. - `operatingSystem`: Returns analytics\ - \ based on the operating system used by the viewers during the play event.\ - \ - `browser`: Returns analytics based on the browser used by the viewers\ - \ during the play event.\n var to = 2023-06-10; // DateTime?\ - \ | Use this optional query parameter to set the end date for the time\ - \ period that you want analytics for. - If you do not specify a `to` date,\ - \ the API returns analytics data starting from the `from` date up until\ - \ today, and excluding today. - The date you set must be **within the\ - \ last 30 days**. - The value you provide must follow the `YYYY-MM-DD`\ - \ format. (optional) \n var filter = liveStreamId:li3q7HxhApxRF1c8F8r6VeaI;\ - \ // string | Use this query parameter to filter your results to a specific\ - \ live stream in a project that you want analytics for. You must use the\ - \ `liveStreamId:` prefix when specifying a live stream ID. (optional)\ - \ \n var currentPage = 2; // int? | Choose the number of search\ - \ results to return per page. Minimum value: 1 (optional) (default to\ - \ 1)\n var pageSize = 30; // int? | Results per page. Allowed\ - \ values 1-100, default is 25. (optional) (default to 25)\n \ - \ var apiAnalyticsInstance = apiInstance.Analytics();\n try\n\ - \ {\n // Get play events for live stream\n \ - \ AnalyticsPlaysResponse result = apiAnalyticsInstance.getLiveStreamsPlays(from,\ - \ dimension, to, filter, currentPage, pageSize);\n Debug.WriteLine(result);\n\ - \ }\n catch (ApiException e)\n {\n \ - \ Debug.Print(\"Exception when calling AnalyticsApi.getLiveStreamsPlays:\ - \ \" + e.Message );\n Debug.Print(\"Status Code: \"+ e.ErrorCode);\n\ - \ Debug.Print(e.StackTrace);\n }\n }\n\ - \ }\n}\n" - - language: php - code: "analytics()->getLiveStreamsPlays($from,\ - \ $dimension, array(\n 'to' => new \\DateTime('2023-06-10'), // Use\ - \ this optional query parameter to set the end date for the time period\ - \ that you want analytics for. - If you do not specify a `to` date, the\ - \ API returns analytics data starting from the `from` date up until today,\ - \ and excluding today. - The date you set must be **within the last 30\ - \ days**. - The value you provide must follow the `YYYY-MM-DD` format.\ - \ \n 'filter' => \"liveStreamId:li3q7HxhApxRF1c8F8r6VeaI\", // Use\ - \ this query parameter to filter your results to a specific live stream\ - \ in a project that you want analytics for. You must use the `liveStreamId:`\ - \ prefix when specifying a live stream ID.\n 'currentPage' => 2, //\ - \ Choose the number of search results to return per page. Minimum value:\ - \ 1\n 'pageSize' => 30 // Results per page. Allowed values 1-100, default\ - \ is 25.\n));" - - language: swift - code: "// The following code samples are still beta. For any issue, please\ - \ report via http://github.com/OpenAPITools/openapi-generator/issues/new\n\ - import ApiVideoClient\n\nlet from = Date() // Date | Use this query parameter\ - \ to set the start date for the time period that you want analytics for.\ - \ - The API returns analytics data including the day you set in `from`.\ - \ - The date you set must be **within the last 30 days**. - The value\ - \ you provide must follow the `YYYY-MM-DD` format. \nlet dimension = \"\ - dimension_example\" // String | Use this query parameter to define the\ - \ dimension that you want analytics for. - `liveStreamId`: Returns analytics\ - \ based on the public live stream identifiers. - `emittedAt`: Returns\ - \ analytics based on the times of the play events. The API returns data\ - \ in specific interval groups. When the date period you set in `from`\ - \ and `to` is less than or equals to 2 days, the response for this dimension\ - \ is grouped in hourly intervals. Otherwise, it is grouped in daily intervals.\ - \ - `country`: Returns analytics based on the viewers' country. The list\ - \ of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/).\ - \ - `deviceType`: Returns analytics based on the type of device used by\ - \ the viewers during the play event. - `operatingSystem`: Returns analytics\ - \ based on the operating system used by the viewers during the play event.\ - \ - `browser`: Returns analytics based on the browser used by the viewers\ - \ during the play event.\nlet to = Date() // Date | Use this optional\ - \ query parameter to set the end date for the time period that you want\ - \ analytics for. - If you do not specify a `to` date, the API returns\ - \ analytics data starting from the `from` date up until today, and excluding\ - \ today. - The date you set must be **within the last 30 days**. - The\ - \ value you provide must follow the `YYYY-MM-DD` format. (optional)\n\ - let filter = \"filter_example\" // String | Use this query parameter to\ - \ filter your results to a specific live stream in a project that you\ - \ want analytics for. You must use the `liveStreamId:` prefix when specifying\ - \ a live stream ID. (optional)\nlet currentPage = 987 // Int | Choose\ - \ the number of search results to return per page. Minimum value: 1 (optional)\ - \ (default to 1)\nlet pageSize = 987 // Int | Results per page. Allowed\ - \ values 1-100, default is 25. (optional) (default to 25)\n\n// Get play\ - \ events for live stream\nAnalyticsAPI.getLiveStreamsPlays(from: from,\ - \ dimension: dimension, to: to, filter: filter, currentPage: currentPage,\ - \ pageSize: pageSize) { (response, error) in\n guard error == nil else\ - \ {\n print(error)\n return\n }\n\n if (response)\ - \ {\n dump(response)\n }\n}\n" + code: | + FilterBy2 filterBy = new FilterBy2 + { + continent = new List { "EU", "US" }, + devicetype = new List { "phone" }, + tag = "test" + }; + Page page = apiClient.Analytics() + .getMetricsBreakdown("play", "continent").From(new DateTime(2024, 7, 1)).FilterBy(filterBy).execute(); + - language: go + code: "res, err := cl.Analytics.GetMetricsBreakdown(\"play\", \"continent\"\ + , AnalyticsApiGetMetricsBreakdownRequest{\n filterBy: &FilterBy2{\n \ + \ DeviceType: &[]string{\"computer\", \"phone\"},\n Tag: \tPtrString(\"\ + tag\"),\n },\n})\n" + - language: python + code: | + video_with_tags = self.api.get_metrics_breakdown(metric='play', breakdown='continent', filter_by=FilterBy2( + device_type=["computer", "phone"], + tag="test", + ), + ) /webhooks: get: description: Retrieve a list of all webhooks configured for the current workspace. @@ -12516,7 +12437,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -12733,18 +12654,18 @@ paths: examples: response: value: - type: https://docs.api.video/docs/attributerequired + type: https://docs.api.video/reference/attribute-required events: This attribute is required. name: events status: 400 problems: - - type: https://docs.api.video/docs/attributerequired + - type: https://docs.api.video/reference/attribute-required title: This attribute is required. name: events - - type: https://docs.api.video/docs/attributerequired + - type: https://docs.api.video/reference/attribute-required title: This attribute is required. name: url - - type: https://docs.api.video/docs/attributeinvalid + - type: https://docs.api.video/reference/invalid-attribute title: This attribute must be an array. name: events schema: @@ -12775,7 +12696,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -12974,7 +12895,7 @@ paths: examples: response: value: - type: https://docs.api.video/docs/resourcenot_found + type: https://docs.api.video/reference/resource-not-found title: The requested resource was not found. name: webhookId status: 404 @@ -13006,7 +12927,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -13199,7 +13120,7 @@ paths: content: application/json: examples: - response: + Too many requests: value: type: https://docs.api.video/reference/too-many-requests title: Too many requests. @@ -13368,6 +13289,116 @@ components: hls: https://live.api.video/li4pqNqGUkhKfWcBGpZVLRY5.m3u8 thumbnail: https://live.api.video/li4pqNqGUkhKfWcBGpZVLRY5/thumbnail.jpg parameters: + filterBy: + $ref: '#/components/parameters/filterBy_2' + description: "Use this parameter to filter the API's response based on different\ + \ data dimensions. You can serialize filters in your query to receive more\ + \ detailed breakdowns of your analytics.\n\n- If you do not set a value for\ + \ `filterBy`, the API returns the full dataset for your project.\n- The API\ + \ only accepts the `mediaId` and `mediaType` filters when you call `/data/metrics/play/total`\ + \ or `/data/buckets/play-total/media-id`.\n\nThese are the available breakdown\ + \ dimensions:\n\n- `mediaId`: Returns analytics based on the unique identifiers\ + \ of a video or a live stream.\n- `mediaType`: Returns analytics based on\ + \ the type of content. Possible values: `video` and `live-stream`. \n- `continent`:\ + \ Returns analytics based on the viewers' continent. The list of supported\ + \ continents names are based on the [GeoNames public database](https://www.geonames.org/countries/).\ + \ You must use the ISO-3166 alpha2 format, for example `EU`. Possible values\ + \ are: `AS`, `AF`, `NA`, `SA`, `AN`, `EU`, `AZ`. \n- `country`: Returns analytics\ + \ based on the viewers' country. The list of supported country names are based\ + \ on the [GeoNames public database](https://www.geonames.org/countries/).\ + \ You must use the ISO-3166 alpha2 format, for example `FR`.\n- `deviceType`:\ + \ Returns analytics based on the type of device used by the viewers. Response\ + \ values can include: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`,\ + \ `unknown`.\n- `operatingSystem`: Returns analytics based on the operating\ + \ system used by the viewers. Response values can include `windows`, `mac\ + \ osx`, `android`, `ios`, `linux`.\n- `browser`: Returns analytics based on\ + \ the browser used by the viewers. Response values can include `chrome`, `firefox`,\ + \ `edge`, `opera`.\n- `tag`: Returns analytics for videos using this tag.\ + \ This filter only accepts a single value and is case sensitive. Read more\ + \ about tagging your videos [here](https://docs.api.video/vod/tags-metadata).\n" + example: filterBy[country]=FR&filterBy[operatingSystem]=windows&filterBy[browser][]=firefox&filterBy[browser][]=chrome&filterBy[tag]=Cool + videos + explode: true + in: query + name: filterBy + required: false + schema: + properties: + mediaId: + description: Returns analytics based on the unique identifiers of a video + or a live stream. + example: + - vi4blUQJFrYWbaG44NChkH27 + items: + type: string + type: array + mediaType: + enum: + - video + - live-stream + example: video + type: string + continent: + description: Returns analytics based on the viewers' continent. The list + of supported continents names are based on the [GeoNames public database](https://www.geonames.org/countries/). + You must use the ISO-3166 alpha2 format, for example `EU`. + example: + - EU + items: + enum: + - AS + - AF + - NA + - SA + - AN + - EU + - AZ + type: string + type: array + country: + description: Returns analytics based on the viewers' country. The list + of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). + You must use the ISO-3166 alpha2 format, for example `FR`. + example: + - FR + items: + type: string + type: array + deviceType: + description: 'Returns analytics based on the type of device used by the + viewers. Response values can include: `computer`, `phone`, `tablet`, + `tv`, `console`, `wearable`, `unknown`.' + example: + - computer + items: + type: string + type: array + operatingSystem: + description: Returns analytics based on the operating system used by the + viewers. Response values can include `windows`, `mac osx`, `android`, + `ios`, `linux`. + example: + - windows + items: + type: string + type: array + browser: + description: Returns analytics based on the browser used by the viewers. + Response values can include `chrome`, `firefox`, `edge`, `opera`. + example: + - firefox + items: + type: string + type: array + tag: + description: Returns analytics for videos using this tag. This filter + only accepts a single value and is case sensitive. Read more about tagging + your videos [here](https://docs.api.video/vod/tags-metadata). + example: Cool videos + type: string + type: object + style: deepObject + x-is-deep-object: true current-page: description: 'Choose the number of search results to return per page. Minimum value: 1' @@ -13995,47 +14026,6 @@ components: type: boolean title: Caption type: object - video-session: - example: - session: - sessionId: psEmFwGQUAXR2lFHj5nDOpy - loadedAt: 2019-06-24T11:45:01.109Z - endedAt: 2019-06-24T11:49:19.243Z - location: - country: France - city: Paris - referrer: - url: https://api.video - medium: organic - source: https://google.com - searchTerm: video encoding hosting and delivery - device: - type: desktop - vendor: Dell - model: unknown - os: - name: Microsoft Windows - shortname: W10 - version: Windows10 - client: - type: browser - name: Firefox - version: "67.0" - properties: - session: - $ref: '#/components/schemas/video-session-session' - location: - $ref: '#/components/schemas/video-session-location' - referrer: - $ref: '#/components/schemas/video-session-referrer' - device: - $ref: '#/components/schemas/video-session-device' - os: - $ref: '#/components/schemas/video-session-os' - client: - $ref: '#/components/schemas/video-session-client' - title: VideoSession - type: object live-stream: example: streamKey: dw-dew8-q6w9-k67w-1ws8 @@ -14050,10 +14040,10 @@ components: restreams: - streamKey: dw-dew8-q6w9-k67w-1ws8 serverUrl: rtmp://my.broadcast.example.com/app - name: My RTMP server + name: My restream server - streamKey: dw-dew8-q6w9-k67w-1ws8 serverUrl: rtmp://my.broadcast.example.com/app - name: My RTMP server + name: My restream server liveStreamId: li400mYKSgQ6xs7taUeSaEKr name: My Live Stream playerId: pl45d5vFFGrfdsdsd156dGhh @@ -14076,7 +14066,7 @@ components: public: description: Whether your video can be viewed by everyone, or requires authentication to see it. A setting of false will require a unique token for each view. - Learn more about the Private Video feature [here](https://docs.api.video/delivery-analytics/video-privacy-access-management). + Learn more about the Private Video feature [here](https://docs.api.video/delivery/video-privacy-access-management). example: true type: boolean assets: @@ -14092,7 +14082,7 @@ components: example: true type: boolean restreams: - description: Returns the list of RTMP restream destinations. + description: Returns the list of restream destinations. items: $ref: '#/components/schemas/restreams-response-object' type: array @@ -14111,22 +14101,6 @@ components: - restreams title: LiveStream type: object - live-stream-session: - properties: - session: - $ref: '#/components/schemas/live-stream-session-session' - location: - $ref: '#/components/schemas/live-stream-session-location' - referrer: - $ref: '#/components/schemas/live-stream-session-referrer' - device: - $ref: '#/components/schemas/live-stream-session-device' - os: - $ref: '#/components/schemas/video-session-os' - client: - $ref: '#/components/schemas/live-stream-session-client' - title: LiveStreamSession - type: object player-session-event: properties: type: @@ -14471,7 +14445,7 @@ components: public: default: true description: 'Default: True. If set to `false` the video will become private. - More information on private videos can be found [here](https://docs.api.video/delivery-analytics/video-privacy-access-management)' + More information on private videos can be found [here](https://docs.api.video/delivery/video-privacy-access-management)' example: true type: boolean panoramic: @@ -14721,10 +14695,10 @@ components: restreams: - streamKey: dw-dew8-q6w9-k67w-1ws8 serverUrl: rtmp://my.broadcast.example.com/app - name: My RTMP server + name: My restream server - streamKey: dw-dew8-q6w9-k67w-1ws8 serverUrl: rtmp://my.broadcast.example.com/app - name: My RTMP server + name: My restream server liveStreamId: li400mYKSgQ6xs7taUeSaEKr name: My Live Stream playerId: pl45d5vFFGrfdsdsd156dGhh @@ -14742,10 +14716,10 @@ components: restreams: - streamKey: dw-dew8-q6w9-k67w-1ws8 serverUrl: rtmp://my.broadcast.example.com/app - name: My RTMP server + name: My restream server - streamKey: dw-dew8-q6w9-k67w-1ws8 serverUrl: rtmp://my.broadcast.example.com/app - name: My RTMP server + name: My restream server liveStreamId: li400mYKSgQ6xs7taUeSaEKr name: My Live Stream playerId: pl45d5vFFGrfdsdsd156dGhh @@ -14782,16 +14756,16 @@ components: public: description: Whether your video can be viewed by everyone, or requires authentication to see it. A setting of false will require a unique token for each view. - Learn more about the Private Video feature [here](https://docs.api.video/delivery-analytics/video-privacy-access-management). + Learn more about the Private Video feature [here](https://docs.api.video/delivery/video-privacy-access-management). type: boolean playerId: description: The unique identifier for the player. example: pl4f4ferf5erfr5zed4fsdd type: string restreams: - description: Use this parameter to add, edit, or remove RTMP services where - you want to restream a live stream. The list can only contain up to 5 - destinations. + description: Use this parameter to add, edit, or remove `RTMPS` or `RTMP` + services where you want to restream a live stream. The list can only contain + up to 5 destinations. items: $ref: '#/components/schemas/restreams-request-object' maxItems: 5 @@ -14809,7 +14783,7 @@ components: public: description: Whether your video can be viewed by everyone, or requires authentication to see it. A setting of false will require a unique token for each view. - Learn more about the Private Video feature [here](https://docs.api.video/delivery-analytics/video-privacy-access-management). + Learn more about the Private Video feature [here](https://docs.api.video/delivery/video-privacy-access-management). type: boolean playerId: description: The unique ID for the player associated with a live stream @@ -14817,11 +14791,11 @@ components: example: pl45KFKdlddgk654dspkze type: string restreams: - description: Use this parameter to add, edit, or remove RTMP services where - you want to restream a live stream. The list can only contain up to 5 - destinations. This operation updates all restream destinations in the - same request. If you do not want to modify an existing restream destination, - you need to include it in your request, otherwise it is removed. + description: Use this parameter to add, edit, or remove `RTMPS` or `RTMP` + services where you want to restream a live stream. The list can only contain + up to 5 destinations. This operation updates all restream destinations + in the same request. If you do not want to modify an existing restream + destination, you need to include it in your request, otherwise it is removed. items: $ref: '#/components/schemas/restreams-request-object' maxItems: 5 @@ -14834,10 +14808,11 @@ components: properties: name: description: Use this parameter to define a name for the restream destination. - example: My RTMP server + example: My restream server type: string serverUrl: - description: Use this parameter to set the RTMP URL of the restream destination. + description: Use this parameter to set the `RTMPS` or `RTMP` server URL + of the restream destination. example: rtmp://my.broadcast.example.com/app type: string streamKey: @@ -14855,14 +14830,14 @@ components: example: streamKey: dw-dew8-q6w9-k67w-1ws8 serverUrl: rtmp://my.broadcast.example.com/app - name: My RTMP server + name: My restream server properties: name: description: Returns the name of a restream destination. - example: My RTMP server + example: My restream server type: string serverUrl: - description: Returns the RTMP URL of a restream destination. + description: Returns the server URL of a restream destination. example: rtmp://my.broadcast.example.com/app type: string streamKey: @@ -15085,10 +15060,127 @@ components: format: string type: string required: - - file - title: PlayerThemeUploadLogoPayload + - file + title: PlayerThemeUploadLogoPayload + type: object + analytics-plays-response: + properties: + data: + items: + $ref: '#/components/schemas/analytics-data' + type: array + pagination: + $ref: '#/components/schemas/pagination' + required: + - data + - pagination + title: Play event analytics response + type: object + analytics-data: + properties: + value: + description: Shows a value for the property you have specified for `dimension` + in your request. For example, if you requested `dimension=videoId`, each + `value` field in the response returns a different videoId. + example: vi3q7HxhApxRF1c8F8r6VeaI + type: string + plays: + description: Shows the number of play events for one specific `value`. + example: 100 + type: integer + required: + - plays + - value + title: Play event analytics data + type: object + analytics-plays-400-error: + properties: + type: + description: A link to the error documentation. + type: string + title: + description: A description of the error that occurred. + type: string + status: + description: The HTTP status code. + type: integer + detail: + description: A solution for the error. + type: string + name: + description: The name of the parameter that caused the error. + type: string + type: object + analytics-aggregated-metrics-response: + example: + data: 356.2 + context: + timeframe: + from: 2024-05-28T11:15:07Z + to: 2024-05-29T11:15:07Z + metric: impression + aggregation: count + properties: + context: + $ref: '#/components/schemas/analytics_aggregated_metrics_response_context' + data: + example: 356.2 + format: float + type: number + required: + - context + - data + title: Analytics response for aggregated metrics + type: object + analytics-metrics-breakdown-response: + example: + pagination: + itemsTotal: 123 + pagesTotal: 7 + pageSize: 20 + currentPage: 3 + currentPageItems: 20 + links: + first: + rel: first + uri: /videos/search?currentPage=1&pageSize=20 + previous: + rel: previous + uri: /videos/search?currentPage=2&pageSize=20 + next: + rel: next + uri: /videos/search?currentPage=4&pageSize=20 + last: + rel: last + uri: /videos/search?currentPage=6&pageSize=20 + data: + - dimensionValue: dimensionValue + metricValue: 0.8008282 + - dimensionValue: dimensionValue + metricValue: 0.8008282 + context: + timeframe: + from: 2024-05-28T11:15:07Z + to: 2024-05-29T11:15:07Z + metric: impression + breakdown: country + properties: + context: + $ref: '#/components/schemas/analytics_metrics_breakdown_response_context' + data: + description: Returns an array of dimensions and their respective metrics. + items: + $ref: '#/components/schemas/analytics_metrics_breakdown_response_data' + type: array + pagination: + $ref: '#/components/schemas/pagination' + required: + - context + - data + - pagination + title: Analytics response for metrics breakdown by dimension type: object - analytics-plays-response: + analytics-metrics-over-time-response: example: pagination: itemsTotal: 123 @@ -15110,43 +15202,33 @@ components: rel: last uri: /videos/search?currentPage=6&pageSize=20 data: - - plays: 100 - value: vi3q7HxhApxRF1c8F8r6VeaI - - plays: 100 - value: vi3q7HxhApxRF1c8F8r6VeaI + - emittedAt: emittedAt + metricValue: 0.8008282 + - emittedAt: emittedAt + metricValue: 0.8008282 + context: + timeframe: + from: 2024-05-28T11:15:07Z + to: 2024-05-29T11:15:07Z + metric: impression + interval: day properties: + context: + $ref: '#/components/schemas/analytics_metrics_over_time_response_context' data: + description: Returns an array of metrics and the timestamps . items: - $ref: '#/components/schemas/analytics-data' + $ref: '#/components/schemas/analytics_metrics_over_time_response_data' type: array pagination: $ref: '#/components/schemas/pagination' required: + - context - data - pagination - title: Play event analytics response - type: object - analytics-data: - example: - plays: 100 - value: vi3q7HxhApxRF1c8F8r6VeaI - properties: - value: - description: Shows a value for the property you have specified for `dimension` - in your request. For example, if you requested `dimension=videoId`, each - `value` field in the response returns a different videoId. - example: vi3q7HxhApxRF1c8F8r6VeaI - type: string - plays: - description: Shows the number of play events for one specific `value`. - example: 100 - type: integer - required: - - plays - - value - title: Play event analytics data + title: Analytics response for metrics over time type: object - analytics-plays-400-error: + unrecognized-request-url: properties: type: description: A link to the error documentation. @@ -15157,12 +15239,7 @@ components: status: description: The HTTP status code. type: integer - detail: - description: A solution for the error. - type: string - name: - description: The name of the parameter that caused the error. - type: string + title: Unrecognized request URL type: object webhooks-list-response: example: @@ -15373,124 +15450,6 @@ components: type: string title: VideoAssets type: object - video-session-session: - properties: - sessionId: - description: The unique identifier for the session that you can use to track - what happens during it. - example: psEmFwGQUAXR2lFHj5nDOpy - type: string - loadedAt: - description: When the video session started, presented in ISO-8601 format. - example: 2019-06-24T11:45:01.109Z - format: date-time - type: string - endedAt: - description: When the video session ended, presented in ISO-8601 format. - example: 2019-06-24T12:45:01.109Z - format: date-time - type: string - metadata: - description: A list of key value pairs that you use to provide metadata - for your video. These pairs can be made dynamic, allowing you to segment - your audience. You can also just use the pairs as another way to tag and - categorize your videos. - example: '[{"key": "Author", "value": "John Doe"}]' - items: - $ref: '#/components/schemas/metadata' - type: array - title: VideoSessionSession - type: object - video-session-location: - description: The location of the viewer. - properties: - country: - description: The country of the viewer. - example: France - type: string - city: - description: The city of the viewer. - example: Paris - nullable: true - type: string - title: VideoSessionLocation - type: object - video-session-referrer: - properties: - url: - description: The link the viewer used to reach the video session. - example: https://api.video - nullable: true - type: string - medium: - description: How they arrived at the site, for example organic or paid. - Organic meaning they found it themselves and paid meaning they followed - a link from an advertisement. - example: organic - type: string - source: - description: The source the referrer came from to the video session. For - example if they searched through google to find the stream. - example: https://google.com - type: string - searchTerm: - description: The search term they typed to arrive at the video session. - type: string - title: VideoSessionReferrer - type: object - video-session-device: - description: What type of device the user is on when in the video session. - properties: - type: - description: What the type is like desktop, laptop, mobile. - example: desktop - type: string - vendor: - description: If known, what the brand of the device is, like Apple, Dell, - etc. - example: Dell - type: string - model: - description: The specific model of the device, if known. - example: unknown - type: string - title: VideoSessionDevice - type: object - video-session-os: - description: The operating system the viewer is on. - properties: - name: - description: The name of the operating system. - example: Microsoft Windows - type: string - shortname: - description: The nickname for the operating system, often representing the - version. - example: W10 - type: string - version: - description: The version of the operating system. - example: Windows 10 - type: string - title: VideoSessionOs - type: object - video-session-client: - description: What kind of browser the viewer is using for the video session. - properties: - name: - description: The name of the browser used to view the video session. - example: Firefox - type: string - version: - description: The version of the browser used to view the video session. - example: "67.0" - type: string - type: - description: The type of client used to view the video session. - example: browser - type: string - title: VideoSessionClient - type: object live-stream-assets: example: thumbnail: https://live.api.video/li400mYKSgQ6xs7taUeSaEKr/thumbnail.jpg @@ -15521,98 +15480,6 @@ components: type: string title: LiveStreamAssets type: object - live-stream-session-session: - properties: - sessionId: - description: A unique identifier for your session. You can use this to track - what happens during a specific session. - type: string - loadedAt: - description: When the session started, with the date and time presented - in ISO-8601 format. - example: 2019-06-24T11:45:01.109Z - format: date-time - type: string - endedAt: - description: When the session ended, with the date and time presented in - ISO-8601 format. - example: 2019-06-24T12:45:01.109Z - format: date-time - type: string - title: LiveStreamSessionSession - type: object - live-stream-session-location: - description: The location of the viewer of the live stream. - properties: - country: - description: The country of the viewer of the live stream. - example: France - type: string - city: - description: The city of the viewer of the live stream. - example: Paris - type: string - title: LiveStreamSessionLocation - type: object - live-stream-session-referrer: - properties: - url: - description: The website the viewer of the live stream was referred to in - order to view the live stream. - example: https://api.video - type: string - medium: - description: The type of search that brought the viewer to the live stream. - Organic would be they found it on their own, paid would be they found - it via an advertisement. - example: organic - type: string - source: - description: Where the viewer came from to see the live stream (usually - where they searched from). - example: https://google.com - type: string - searchTerm: - description: What term they searched for that led them to the live stream. - example: video stream - type: string - title: LiveStreamSessionReferrer - type: object - live-stream-session-device: - description: What type of device the user is on when in the live stream session. - properties: - type: - description: What the type is like desktop, laptop, mobile. - example: desktop - type: string - vendor: - description: If known, what the brand of the device is, like Apple, Dell, - etc. - example: Dell - type: string - model: - description: The specific model of the device, if known. - example: unknown - type: string - title: LiveStreamSessionDevice - type: object - live-stream-session-client: - description: What kind of browser the viewer is using for the live stream session. - properties: - name: - description: The name of the browser used to view the live stream session. - example: Firefox - type: string - version: - description: The version of the browser used to view the live stream session. - example: "67.0" - type: string - type: - description: The type of client used to view the live stream session. - example: browser - type: string - title: LiveStreamSessionClient - type: object video-status-ingest: description: Details about the capturing, transferring, and storing of your video for use immediately or in the future. @@ -15707,6 +15574,231 @@ components: $ref: '#/components/schemas/video-status-encoding-metadata' title: VideoStatusEncoding type: object + filterBy: + properties: + mediaId: + description: Returns analytics based on the unique identifiers of a video + or a live stream. + example: + - vi4blUQJFrYWbaG44NChkH27 + items: + type: string + type: array + mediaType: + enum: + - video + - live-stream + example: video + type: string + continent: + description: Returns analytics based on the viewers' continent. The list + of supported continents names are based on the [GeoNames public database](https://www.geonames.org/countries/). + You must use the ISO-3166 alpha2 format, for example `EU`. + example: + - EU + items: + enum: + - AS + - AF + - NA + - SA + - AN + - EU + - AZ + type: string + type: array + country: + description: Returns analytics based on the viewers' country. The list of + supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). + You must use the ISO-3166 alpha2 format, for example `FR`. + example: + - FR + items: + type: string + type: array + deviceType: + description: 'Returns analytics based on the type of device used by the + viewers. Response values can include: `computer`, `phone`, `tablet`, `tv`, + `console`, `wearable`, `unknown`.' + example: + - computer + items: + type: string + type: array + operatingSystem: + description: Returns analytics based on the operating system used by the + viewers. Response values can include `windows`, `mac osx`, `android`, + `ios`, `linux`. + example: + - windows + items: + type: string + type: array + browser: + description: Returns analytics based on the browser used by the viewers. + Response values can include `chrome`, `firefox`, `edge`, `opera`. + example: + - firefox + items: + type: string + type: array + tag: + description: Returns analytics for videos using this tag. This filter only + accepts a single value and is case sensitive. Read more about tagging + your videos [here](https://docs.api.video/vod/tags-metadata). + example: Cool videos + type: string + type: object + filterBy_1: + properties: + mediaId: + description: Returns analytics based on the unique identifiers of a video + or a live stream. + example: + - vi4blUQJFrYWbaG44NChkH27 + items: + type: string + type: array + mediaType: + enum: + - video + - live-stream + example: video + type: string + continent: + description: Returns analytics based on the viewers' continent. The list + of supported continents names are based on the [GeoNames public database](https://www.geonames.org/countries/). + You must use the ISO-3166 alpha2 format, for example `EU`. + example: + - EU + items: + enum: + - AS + - AF + - NA + - SA + - AN + - EU + - AZ + type: string + type: array + country: + description: Returns analytics based on the viewers' country. The list of + supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). + You must use the ISO-3166 alpha2 format, for example `FR`. + example: + - FR + items: + type: string + type: array + deviceType: + description: 'Returns analytics based on the type of device used by the + viewers. Response values can include: `computer`, `phone`, `tablet`, `tv`, + `console`, `wearable`, `unknown`.' + example: + - computer + items: + type: string + type: array + operatingSystem: + description: Returns analytics based on the operating system used by the + viewers. Response values can include `windows`, `mac osx`, `android`, + `ios`, `linux`. + example: + - windows + items: + type: string + type: array + browser: + description: Returns analytics based on the browser used by the viewers. + Response values can include `chrome`, `firefox`, `edge`, `opera`. + example: + - firefox + items: + type: string + type: array + tag: + description: Returns analytics for videos using this tag. This filter only + accepts a single value and is case sensitive. Read more about tagging + your videos [here](https://docs.api.video/vod/tags-metadata). + example: Cool videos + type: string + type: object + filterBy_2: + properties: + mediaId: + description: Returns analytics based on the unique identifiers of a video + or a live stream. + example: + - vi4blUQJFrYWbaG44NChkH27 + items: + type: string + type: array + mediaType: + enum: + - video + - live-stream + example: video + type: string + continent: + description: Returns analytics based on the viewers' continent. The list + of supported continents names are based on the [GeoNames public database](https://www.geonames.org/countries/). + You must use the ISO-3166 alpha2 format, for example `EU`. + example: + - EU + items: + enum: + - AS + - AF + - NA + - SA + - AN + - EU + - AZ + type: string + type: array + country: + description: Returns analytics based on the viewers' country. The list of + supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). + You must use the ISO-3166 alpha2 format, for example `FR`. + example: + - FR + items: + type: string + type: array + deviceType: + description: 'Returns analytics based on the type of device used by the + viewers. Response values can include: `computer`, `phone`, `tablet`, `tv`, + `console`, `wearable`, `unknown`.' + example: + - computer + items: + type: string + type: array + operatingSystem: + description: Returns analytics based on the operating system used by the + viewers. Response values can include `windows`, `mac osx`, `android`, + `ios`, `linux`. + example: + - windows + items: + type: string + type: array + browser: + description: Returns analytics based on the browser used by the viewers. + Response values can include `chrome`, `firefox`, `edge`, `opera`. + example: + - firefox + items: + type: string + type: array + tag: + description: Returns analytics for videos using this tag. This filter only + accepts a single value and is case sensitive. Read more about tagging + your videos [here](https://docs.api.video/vod/tags-metadata). + example: Cool videos + type: string + type: object player_theme_assets: example: link: path/to/my/logo/mylogo.jpg @@ -15721,6 +15813,150 @@ components: example: path/to/my/logo/mylogo.jpg type: string type: object + analytics_aggregated_metrics_response_context_timeframe: + description: Returns the starting and ending date-times of the period you want + analytics for. + example: + from: 2024-05-28T11:15:07Z + to: 2024-05-29T11:15:07Z + properties: + from: + description: Returns the starting date-time of the period you want analytics + for in ATOM date-time format. + example: 2024-05-28T11:15:07Z + format: date-time + type: string + to: + description: Returns the starting date-time of the period you want analytics + for in ATOM date-time format. + example: 2024-05-29T11:15:07Z + format: date-time + type: string + type: object + analytics_aggregated_metrics_response_context: + example: + timeframe: + from: 2024-05-28T11:15:07Z + to: 2024-05-29T11:15:07Z + metric: impression + aggregation: count + properties: + metric: + description: Returns the metric you selected. + enum: + - play + - start + - end + - impression + - impression-time + - watch-time + example: impression + type: string + aggregation: + description: Returns the aggregation you selected. + enum: + - count + - rate + - total + - average + - sum + example: count + type: string + timeframe: + $ref: '#/components/schemas/analytics_aggregated_metrics_response_context_timeframe' + type: object + analytics_metrics_breakdown_response_context: + example: + timeframe: + from: 2024-05-28T11:15:07Z + to: 2024-05-29T11:15:07Z + metric: impression + breakdown: country + properties: + metric: + description: Returns the metric you selected. + enum: + - play + - play-rate + - start + - end + - impression + example: impression + type: string + breakdown: + description: Returns the dimension you selected. + enum: + - media-id + - media-type + - continent + - country + - device-type + - operating-system + - browser + example: country + type: string + timeframe: + $ref: '#/components/schemas/analytics_aggregated_metrics_response_context_timeframe' + type: object + analytics_metrics_breakdown_response_data: + example: + dimensionValue: dimensionValue + metricValue: 0.8008282 + properties: + dimensionValue: + description: Returns a specific value for the dimension you selected, based + on the data. For example if you select `continent` as a dimension, then + `dimensionValue` returns values like `EU` or "AZ". + type: string + metricValue: + description: Returns the data for a specific dimension value. + format: float + type: number + type: object + analytics_metrics_over_time_response_context: + example: + timeframe: + from: 2024-05-28T11:15:07Z + to: 2024-05-29T11:15:07Z + metric: impression + interval: day + properties: + metric: + description: Returns the metric you selected. + enum: + - play + - play-rate + - start + - end + - impression + example: impression + type: string + interval: + description: Returns the interval you selected. + enum: + - hour + - day + example: day + type: string + timeframe: + $ref: '#/components/schemas/analytics_aggregated_metrics_response_context_timeframe' + type: object + analytics_metrics_over_time_response_data: + example: + emittedAt: emittedAt + metricValue: 0.8008282 + properties: + emittedAt: + description: Returns the timestamp of the event that belongs to a specific + metric in ATOM date-time format. For example, if you set `play` with an + `hour` interval in your request, then `emittedAt` returns the hourly timestamps + of every play event within the timeframe you defined. + type: string + metricValue: + description: Returns the data for a specific metric value. + format: float + type: number + type: object video_status_ingest_receivedParts: properties: parts: diff --git a/api_analytics.go b/api_analytics.go index c749010..cbdf333 100644 --- a/api_analytics.go +++ b/api_analytics.go @@ -14,6 +14,8 @@ import ( "context" "net/http" "net/url" + "strings" + "time" ) // Linger please @@ -21,104 +23,143 @@ var ( _ context.Context ) -type AnalyticsApiGetLiveStreamsPlaysRequest struct { - from *string - dimension *string - to *string - filter *string - currentPage *int32 - pageSize *int32 +type AnalyticsApiGetAggregatedMetricsRequest struct { + from *time.Time + to *time.Time + filterBy *FilterBy2 } -func (r AnalyticsApiGetLiveStreamsPlaysRequest) From(from string) AnalyticsApiGetLiveStreamsPlaysRequest { +func (r AnalyticsApiGetAggregatedMetricsRequest) From(from time.Time) AnalyticsApiGetAggregatedMetricsRequest { r.from = &from return r } -func (r AnalyticsApiGetLiveStreamsPlaysRequest) Dimension(dimension string) AnalyticsApiGetLiveStreamsPlaysRequest { - r.dimension = &dimension +func (r AnalyticsApiGetAggregatedMetricsRequest) To(to time.Time) AnalyticsApiGetAggregatedMetricsRequest { + r.to = &to + return r +} +func (r AnalyticsApiGetAggregatedMetricsRequest) FilterBy(filterBy FilterBy2) AnalyticsApiGetAggregatedMetricsRequest { + r.filterBy = &filterBy return r } -func (r AnalyticsApiGetLiveStreamsPlaysRequest) To(to string) AnalyticsApiGetLiveStreamsPlaysRequest { + +type AnalyticsApiGetMetricsBreakdownRequest struct { + from *time.Time + to *time.Time + filterBy *FilterBy2 + currentPage *int32 + pageSize *int32 +} + +func (r AnalyticsApiGetMetricsBreakdownRequest) From(from time.Time) AnalyticsApiGetMetricsBreakdownRequest { + r.from = &from + return r +} +func (r AnalyticsApiGetMetricsBreakdownRequest) To(to time.Time) AnalyticsApiGetMetricsBreakdownRequest { r.to = &to return r } -func (r AnalyticsApiGetLiveStreamsPlaysRequest) Filter(filter string) AnalyticsApiGetLiveStreamsPlaysRequest { - r.filter = &filter +func (r AnalyticsApiGetMetricsBreakdownRequest) FilterBy(filterBy FilterBy2) AnalyticsApiGetMetricsBreakdownRequest { + r.filterBy = &filterBy return r } -func (r AnalyticsApiGetLiveStreamsPlaysRequest) CurrentPage(currentPage int32) AnalyticsApiGetLiveStreamsPlaysRequest { +func (r AnalyticsApiGetMetricsBreakdownRequest) CurrentPage(currentPage int32) AnalyticsApiGetMetricsBreakdownRequest { r.currentPage = ¤tPage return r } -func (r AnalyticsApiGetLiveStreamsPlaysRequest) PageSize(pageSize int32) AnalyticsApiGetLiveStreamsPlaysRequest { +func (r AnalyticsApiGetMetricsBreakdownRequest) PageSize(pageSize int32) AnalyticsApiGetMetricsBreakdownRequest { r.pageSize = &pageSize return r } -type AnalyticsApiGetVideosPlaysRequest struct { - from *string - dimension *string - to *string - filter *string +type AnalyticsApiGetMetricsOverTimeRequest struct { + from *time.Time + to *time.Time + interval *string + filterBy *FilterBy2 currentPage *int32 pageSize *int32 } -func (r AnalyticsApiGetVideosPlaysRequest) From(from string) AnalyticsApiGetVideosPlaysRequest { +func (r AnalyticsApiGetMetricsOverTimeRequest) From(from time.Time) AnalyticsApiGetMetricsOverTimeRequest { r.from = &from return r } -func (r AnalyticsApiGetVideosPlaysRequest) Dimension(dimension string) AnalyticsApiGetVideosPlaysRequest { - r.dimension = &dimension +func (r AnalyticsApiGetMetricsOverTimeRequest) To(to time.Time) AnalyticsApiGetMetricsOverTimeRequest { + r.to = &to return r } -func (r AnalyticsApiGetVideosPlaysRequest) To(to string) AnalyticsApiGetVideosPlaysRequest { - r.to = &to +func (r AnalyticsApiGetMetricsOverTimeRequest) Interval(interval string) AnalyticsApiGetMetricsOverTimeRequest { + r.interval = &interval return r } -func (r AnalyticsApiGetVideosPlaysRequest) Filter(filter string) AnalyticsApiGetVideosPlaysRequest { - r.filter = &filter +func (r AnalyticsApiGetMetricsOverTimeRequest) FilterBy(filterBy FilterBy2) AnalyticsApiGetMetricsOverTimeRequest { + r.filterBy = &filterBy return r } -func (r AnalyticsApiGetVideosPlaysRequest) CurrentPage(currentPage int32) AnalyticsApiGetVideosPlaysRequest { +func (r AnalyticsApiGetMetricsOverTimeRequest) CurrentPage(currentPage int32) AnalyticsApiGetMetricsOverTimeRequest { r.currentPage = ¤tPage return r } -func (r AnalyticsApiGetVideosPlaysRequest) PageSize(pageSize int32) AnalyticsApiGetVideosPlaysRequest { +func (r AnalyticsApiGetMetricsOverTimeRequest) PageSize(pageSize int32) AnalyticsApiGetMetricsOverTimeRequest { r.pageSize = &pageSize return r } type AnalyticsServiceI interface { /* - * GetLiveStreamsPlays Get play events for live stream - * @return AnalyticsApiGetLiveStreamsPlaysRequest + * GetAggregatedMetrics Retrieve aggregated metrics + * @param metric Use this path parameter to select a metric that you want analytics for. - `play` is the number of times your content has been played. You can use the aggregations `count`, `rate`, and `total` with the `play` metric. - `start` is the number of times playback was started. You can use the aggregation `count` with this metric. - `end` is the number of times playback has ended with the content watch until the end. You can use the aggregation `count` with this metric. - `impression` is the number of times your content has been loaded and was ready for playback. You can use the aggregation `count` with this metric. - `impression-time` is the time in milliseconds that your content was loading for until the first video frame is displayed. You can use the aggregations `average` and `sum` with this metric. - `watch-time` is the cumulative time in seconds that the user has spent watching your content. You can use the aggregations `average` and `sum` with this metric. + * @param aggregation Use this path parameter to define a way of collecting data for the metric that you want analytics for. - `count` returns the overall number of events for the `play` metric. - `rate` returns the ratio that calculates the number of plays your content receives divided by its impressions. This aggregation can be used only with the `play` metric. - `total` calculates the total number of events for the `play` metric. - `average` calculates an average value for the selected metric. - `sum` adds up the total value of the select metric. + * @return AnalyticsApiGetAggregatedMetricsRequest */ - GetLiveStreamsPlays(r AnalyticsApiGetLiveStreamsPlaysRequest) (*AnalyticsPlaysResponse, error) + GetAggregatedMetrics(metric string, aggregation string, r AnalyticsApiGetAggregatedMetricsRequest) (*AnalyticsAggregatedMetricsResponse, error) /* - * GetLiveStreamsPlays Get play events for live stream + * GetAggregatedMetrics Retrieve aggregated metrics * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return AnalyticsApiGetLiveStreamsPlaysRequest + * @param metric Use this path parameter to select a metric that you want analytics for. - `play` is the number of times your content has been played. You can use the aggregations `count`, `rate`, and `total` with the `play` metric. - `start` is the number of times playback was started. You can use the aggregation `count` with this metric. - `end` is the number of times playback has ended with the content watch until the end. You can use the aggregation `count` with this metric. - `impression` is the number of times your content has been loaded and was ready for playback. You can use the aggregation `count` with this metric. - `impression-time` is the time in milliseconds that your content was loading for until the first video frame is displayed. You can use the aggregations `average` and `sum` with this metric. - `watch-time` is the cumulative time in seconds that the user has spent watching your content. You can use the aggregations `average` and `sum` with this metric. + * @param aggregation Use this path parameter to define a way of collecting data for the metric that you want analytics for. - `count` returns the overall number of events for the `play` metric. - `rate` returns the ratio that calculates the number of plays your content receives divided by its impressions. This aggregation can be used only with the `play` metric. - `total` calculates the total number of events for the `play` metric. - `average` calculates an average value for the selected metric. - `sum` adds up the total value of the select metric. + * @return AnalyticsApiGetAggregatedMetricsRequest */ - GetLiveStreamsPlaysWithContext(ctx context.Context, r AnalyticsApiGetLiveStreamsPlaysRequest) (*AnalyticsPlaysResponse, error) + GetAggregatedMetricsWithContext(ctx context.Context, metric string, aggregation string, r AnalyticsApiGetAggregatedMetricsRequest) (*AnalyticsAggregatedMetricsResponse, error) /* - * GetVideosPlays Get play events for video - * @return AnalyticsApiGetVideosPlaysRequest + * GetMetricsBreakdown Retrieve metrics in a breakdown of dimensions + * @param metric Use this path parameter to select a metric that you want analytics for. - `play` is the number of times your content has been played. - `play-rate` is the ratio that calculates the number of plays your content receives divided by its impressions. - `play-total` is the total number of times a specific content has been played. You can only use the `media-id` breakdown with this metric. - `start` is the number of times playback was started. - `end` is the number of times playback has ended with the content watch until the end. - `impression` is the number of times your content has been loaded and was ready for playback. + * @param breakdown Use this path parameter to define a dimension for segmenting analytics data. You must use `kebab-case` for path parameters. These are the available dimensions: - `media-id`: Returns analytics based on the unique identifiers of a video or a live stream. - `media-type`: Returns analytics based on the type of content. Possible values: `video` and `live-stream`. - `continent`: Returns analytics based on the viewers' continent. The list of supported continents names are based on the [GeoNames public database](https://www.geonames.org/countries/). Possible values are: `AS`, `AF`, `NA`, `SA`, `AN`, `EU`, `AZ`. - `country`: Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). - `device-type`: Returns analytics based on the type of device used by the viewers. Response values can include: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. - `operating-system`: Returns analytics based on the operating system used by the viewers. Response values can include `windows`, `mac osx`, `android`, `ios`, `linux`. - `browser`: Returns analytics based on the browser used by the viewers. Response values can include `chrome`, `firefox`, `edge`, `opera`. + * @return AnalyticsApiGetMetricsBreakdownRequest */ - GetVideosPlays(r AnalyticsApiGetVideosPlaysRequest) (*AnalyticsPlaysResponse, error) + GetMetricsBreakdown(metric string, breakdown string, r AnalyticsApiGetMetricsBreakdownRequest) (*AnalyticsMetricsBreakdownResponse, error) /* - * GetVideosPlays Get play events for video + * GetMetricsBreakdown Retrieve metrics in a breakdown of dimensions * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return AnalyticsApiGetVideosPlaysRequest + * @param metric Use this path parameter to select a metric that you want analytics for. - `play` is the number of times your content has been played. - `play-rate` is the ratio that calculates the number of plays your content receives divided by its impressions. - `play-total` is the total number of times a specific content has been played. You can only use the `media-id` breakdown with this metric. - `start` is the number of times playback was started. - `end` is the number of times playback has ended with the content watch until the end. - `impression` is the number of times your content has been loaded and was ready for playback. + * @param breakdown Use this path parameter to define a dimension for segmenting analytics data. You must use `kebab-case` for path parameters. These are the available dimensions: - `media-id`: Returns analytics based on the unique identifiers of a video or a live stream. - `media-type`: Returns analytics based on the type of content. Possible values: `video` and `live-stream`. - `continent`: Returns analytics based on the viewers' continent. The list of supported continents names are based on the [GeoNames public database](https://www.geonames.org/countries/). Possible values are: `AS`, `AF`, `NA`, `SA`, `AN`, `EU`, `AZ`. - `country`: Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). - `device-type`: Returns analytics based on the type of device used by the viewers. Response values can include: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. - `operating-system`: Returns analytics based on the operating system used by the viewers. Response values can include `windows`, `mac osx`, `android`, `ios`, `linux`. - `browser`: Returns analytics based on the browser used by the viewers. Response values can include `chrome`, `firefox`, `edge`, `opera`. + * @return AnalyticsApiGetMetricsBreakdownRequest */ - GetVideosPlaysWithContext(ctx context.Context, r AnalyticsApiGetVideosPlaysRequest) (*AnalyticsPlaysResponse, error) + GetMetricsBreakdownWithContext(ctx context.Context, metric string, breakdown string, r AnalyticsApiGetMetricsBreakdownRequest) (*AnalyticsMetricsBreakdownResponse, error) + + /* + * GetMetricsOverTime Retrieve metrics over time + * @param metric Use this path parameter to select a metric that you want analytics for. - `play` is the number of times your content has been played. - `play-rate` is the ratio that calculates the number of plays your content receives divided by its impressions. - `start` is the number of times playback was started. - `end` is the number of times playback has ended with the content watch until the end. - `impression` is the number of times your content has been loaded and was ready for playback. + * @return AnalyticsApiGetMetricsOverTimeRequest + */ + + GetMetricsOverTime(metric string, r AnalyticsApiGetMetricsOverTimeRequest) (*AnalyticsMetricsOverTimeResponse, error) + + /* + * GetMetricsOverTime Retrieve metrics over time + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param metric Use this path parameter to select a metric that you want analytics for. - `play` is the number of times your content has been played. - `play-rate` is the ratio that calculates the number of plays your content receives divided by its impressions. - `start` is the number of times playback was started. - `end` is the number of times playback has ended with the content watch until the end. - `impression` is the number of times your content has been loaded and was ready for playback. + * @return AnalyticsApiGetMetricsOverTimeRequest + */ + + GetMetricsOverTimeWithContext(ctx context.Context, metric string, r AnalyticsApiGetMetricsOverTimeRequest) (*AnalyticsMetricsOverTimeResponse, error) } // AnalyticsService communicating with the Analytics @@ -128,40 +169,107 @@ type AnalyticsService struct { } /* - * GetLiveStreamsPlays Get play events for live stream - * Retrieve filtered analytics about the number of plays for your live streams in a project. + * GetAggregatedMetrics Retrieve aggregated metrics + * Retrieve time-based and countable metrics like average watch time or the number of impressions over a certain period of time. + + * @param metric Use this path parameter to select a metric that you want analytics for. - `play` is the number of times your content has been played. You can use the aggregations `count`, `rate`, and `total` with the `play` metric. - `start` is the number of times playback was started. You can use the aggregation `count` with this metric. - `end` is the number of times playback has ended with the content watch until the end. You can use the aggregation `count` with this metric. - `impression` is the number of times your content has been loaded and was ready for playback. You can use the aggregation `count` with this metric. - `impression-time` is the time in milliseconds that your content was loading for until the first video frame is displayed. You can use the aggregations `average` and `sum` with this metric. - `watch-time` is the cumulative time in seconds that the user has spent watching your content. You can use the aggregations `average` and `sum` with this metric. + * @param aggregation Use this path parameter to define a way of collecting data for the metric that you want analytics for. - `count` returns the overall number of events for the `play` metric. - `rate` returns the ratio that calculates the number of plays your content receives divided by its impressions. This aggregation can be used only with the `play` metric. - `total` calculates the total number of events for the `play` metric. - `average` calculates an average value for the selected metric. - `sum` adds up the total value of the select metric. + * @return AnalyticsApiGetAggregatedMetricsRequest + */ + +func (s *AnalyticsService) GetAggregatedMetrics(metric string, aggregation string, r AnalyticsApiGetAggregatedMetricsRequest) (*AnalyticsAggregatedMetricsResponse, error) { + + return s.GetAggregatedMetricsWithContext(context.Background(), metric, aggregation, r) + +} + +/* + * GetAggregatedMetrics Retrieve aggregated metrics + * Retrieve time-based and countable metrics like average watch time or the number of impressions over a certain period of time. + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param metric Use this path parameter to select a metric that you want analytics for. - `play` is the number of times your content has been played. You can use the aggregations `count`, `rate`, and `total` with the `play` metric. - `start` is the number of times playback was started. You can use the aggregation `count` with this metric. - `end` is the number of times playback has ended with the content watch until the end. You can use the aggregation `count` with this metric. - `impression` is the number of times your content has been loaded and was ready for playback. You can use the aggregation `count` with this metric. - `impression-time` is the time in milliseconds that your content was loading for until the first video frame is displayed. You can use the aggregations `average` and `sum` with this metric. - `watch-time` is the cumulative time in seconds that the user has spent watching your content. You can use the aggregations `average` and `sum` with this metric. + * @param aggregation Use this path parameter to define a way of collecting data for the metric that you want analytics for. - `count` returns the overall number of events for the `play` metric. - `rate` returns the ratio that calculates the number of plays your content receives divided by its impressions. This aggregation can be used only with the `play` metric. - `total` calculates the total number of events for the `play` metric. - `average` calculates an average value for the selected metric. - `sum` adds up the total value of the select metric. + * @return AnalyticsApiGetAggregatedMetricsRequest + */ + +func (s *AnalyticsService) GetAggregatedMetricsWithContext(ctx context.Context, metric string, aggregation string, r AnalyticsApiGetAggregatedMetricsRequest) (*AnalyticsAggregatedMetricsResponse, error) { + var localVarPostBody interface{} + + localVarPath := "/data/metrics/{metric}/{aggregation}" + localVarPath = strings.Replace(localVarPath, "{"+"metric"+"}", url.PathEscape(parameterToString(metric, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"aggregation"+"}", url.PathEscape(parameterToString(aggregation, "")), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + + if r.from != nil { + localVarQueryParams.Add("from", parameterToString(*r.from, "")) + } + if r.to != nil { + localVarQueryParams.Add("to", parameterToString(*r.to, "")) + } + if r.filterBy != nil { + addDeepQueryParams(r.filterBy, "filterBy", localVarQueryParams) + } + + req, err := s.client.prepareRequest(ctx, http.MethodGet, localVarPath, localVarPostBody, localVarHeaderParams, localVarQueryParams) + if err != nil { + return nil, err + } + + res := new(AnalyticsAggregatedMetricsResponse) + _, err = s.client.do(req, res) + + if err != nil { + return nil, err + } + + return res, nil + +} + +/* + * GetMetricsBreakdown Retrieve metrics in a breakdown of dimensions + * Retrieve detailed analytics play-rate and number of impressions segmented by dimensions like country or device type. - * @return AnalyticsApiGetLiveStreamsPlaysRequest + * @param metric Use this path parameter to select a metric that you want analytics for. - `play` is the number of times your content has been played. - `play-rate` is the ratio that calculates the number of plays your content receives divided by its impressions. - `play-total` is the total number of times a specific content has been played. You can only use the `media-id` breakdown with this metric. - `start` is the number of times playback was started. - `end` is the number of times playback has ended with the content watch until the end. - `impression` is the number of times your content has been loaded and was ready for playback. + * @param breakdown Use this path parameter to define a dimension for segmenting analytics data. You must use `kebab-case` for path parameters. These are the available dimensions: - `media-id`: Returns analytics based on the unique identifiers of a video or a live stream. - `media-type`: Returns analytics based on the type of content. Possible values: `video` and `live-stream`. - `continent`: Returns analytics based on the viewers' continent. The list of supported continents names are based on the [GeoNames public database](https://www.geonames.org/countries/). Possible values are: `AS`, `AF`, `NA`, `SA`, `AN`, `EU`, `AZ`. - `country`: Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). - `device-type`: Returns analytics based on the type of device used by the viewers. Response values can include: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. - `operating-system`: Returns analytics based on the operating system used by the viewers. Response values can include `windows`, `mac osx`, `android`, `ios`, `linux`. - `browser`: Returns analytics based on the browser used by the viewers. Response values can include `chrome`, `firefox`, `edge`, `opera`. + * @return AnalyticsApiGetMetricsBreakdownRequest */ -func (s *AnalyticsService) GetLiveStreamsPlays(r AnalyticsApiGetLiveStreamsPlaysRequest) (*AnalyticsPlaysResponse, error) { +func (s *AnalyticsService) GetMetricsBreakdown(metric string, breakdown string, r AnalyticsApiGetMetricsBreakdownRequest) (*AnalyticsMetricsBreakdownResponse, error) { - return s.GetLiveStreamsPlaysWithContext(context.Background(), r) + return s.GetMetricsBreakdownWithContext(context.Background(), metric, breakdown, r) } /* - * GetLiveStreamsPlays Get play events for live stream - * Retrieve filtered analytics about the number of plays for your live streams in a project. + * GetMetricsBreakdown Retrieve metrics in a breakdown of dimensions + * Retrieve detailed analytics play-rate and number of impressions segmented by dimensions like country or device type. * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return AnalyticsApiGetLiveStreamsPlaysRequest + * @param metric Use this path parameter to select a metric that you want analytics for. - `play` is the number of times your content has been played. - `play-rate` is the ratio that calculates the number of plays your content receives divided by its impressions. - `play-total` is the total number of times a specific content has been played. You can only use the `media-id` breakdown with this metric. - `start` is the number of times playback was started. - `end` is the number of times playback has ended with the content watch until the end. - `impression` is the number of times your content has been loaded and was ready for playback. + * @param breakdown Use this path parameter to define a dimension for segmenting analytics data. You must use `kebab-case` for path parameters. These are the available dimensions: - `media-id`: Returns analytics based on the unique identifiers of a video or a live stream. - `media-type`: Returns analytics based on the type of content. Possible values: `video` and `live-stream`. - `continent`: Returns analytics based on the viewers' continent. The list of supported continents names are based on the [GeoNames public database](https://www.geonames.org/countries/). Possible values are: `AS`, `AF`, `NA`, `SA`, `AN`, `EU`, `AZ`. - `country`: Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). - `device-type`: Returns analytics based on the type of device used by the viewers. Response values can include: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. - `operating-system`: Returns analytics based on the operating system used by the viewers. Response values can include `windows`, `mac osx`, `android`, `ios`, `linux`. - `browser`: Returns analytics based on the browser used by the viewers. Response values can include `chrome`, `firefox`, `edge`, `opera`. + * @return AnalyticsApiGetMetricsBreakdownRequest */ -func (s *AnalyticsService) GetLiveStreamsPlaysWithContext(ctx context.Context, r AnalyticsApiGetLiveStreamsPlaysRequest) (*AnalyticsPlaysResponse, error) { +func (s *AnalyticsService) GetMetricsBreakdownWithContext(ctx context.Context, metric string, breakdown string, r AnalyticsApiGetMetricsBreakdownRequest) (*AnalyticsMetricsBreakdownResponse, error) { var localVarPostBody interface{} - localVarPath := "/analytics/live-streams/plays" + localVarPath := "/data/buckets/{metric}/{breakdown}" + localVarPath = strings.Replace(localVarPath, "{"+"metric"+"}", url.PathEscape(parameterToString(metric, "")), -1) + localVarPath = strings.Replace(localVarPath, "{"+"breakdown"+"}", url.PathEscape(parameterToString(breakdown, "")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := url.Values{} - localVarQueryParams.Add("from", parameterToString(*r.from, "")) + if r.from != nil { + localVarQueryParams.Add("from", parameterToString(*r.from, "")) + } if r.to != nil { localVarQueryParams.Add("to", parameterToString(*r.to, "")) } - localVarQueryParams.Add("dimension", parameterToString(*r.dimension, "")) - if r.filter != nil { - localVarQueryParams.Add("filter", parameterToString(*r.filter, "")) + if r.filterBy != nil { + addDeepQueryParams(r.filterBy, "filterBy", localVarQueryParams) } if r.currentPage != nil { localVarQueryParams.Add("currentPage", parameterToString(*r.currentPage, "")) @@ -175,7 +283,7 @@ func (s *AnalyticsService) GetLiveStreamsPlaysWithContext(ctx context.Context, r return nil, err } - res := new(AnalyticsPlaysResponse) + res := new(AnalyticsMetricsBreakdownResponse) _, err = s.client.do(req, res) if err != nil { @@ -187,40 +295,47 @@ func (s *AnalyticsService) GetLiveStreamsPlaysWithContext(ctx context.Context, r } /* - * GetVideosPlays Get play events for video - * Retrieve filtered analytics about the number of plays for your videos in a project. + * GetMetricsOverTime Retrieve metrics over time + * Retrieve countable metrics like the number of plays or impressions, grouped by the time at which they occurred - * @return AnalyticsApiGetVideosPlaysRequest + * @param metric Use this path parameter to select a metric that you want analytics for. - `play` is the number of times your content has been played. - `play-rate` is the ratio that calculates the number of plays your content receives divided by its impressions. - `start` is the number of times playback was started. - `end` is the number of times playback has ended with the content watch until the end. - `impression` is the number of times your content has been loaded and was ready for playback. + * @return AnalyticsApiGetMetricsOverTimeRequest */ -func (s *AnalyticsService) GetVideosPlays(r AnalyticsApiGetVideosPlaysRequest) (*AnalyticsPlaysResponse, error) { +func (s *AnalyticsService) GetMetricsOverTime(metric string, r AnalyticsApiGetMetricsOverTimeRequest) (*AnalyticsMetricsOverTimeResponse, error) { - return s.GetVideosPlaysWithContext(context.Background(), r) + return s.GetMetricsOverTimeWithContext(context.Background(), metric, r) } /* - * GetVideosPlays Get play events for video - * Retrieve filtered analytics about the number of plays for your videos in a project. + * GetMetricsOverTime Retrieve metrics over time + * Retrieve countable metrics like the number of plays or impressions, grouped by the time at which they occurred * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @return AnalyticsApiGetVideosPlaysRequest + * @param metric Use this path parameter to select a metric that you want analytics for. - `play` is the number of times your content has been played. - `play-rate` is the ratio that calculates the number of plays your content receives divided by its impressions. - `start` is the number of times playback was started. - `end` is the number of times playback has ended with the content watch until the end. - `impression` is the number of times your content has been loaded and was ready for playback. + * @return AnalyticsApiGetMetricsOverTimeRequest */ -func (s *AnalyticsService) GetVideosPlaysWithContext(ctx context.Context, r AnalyticsApiGetVideosPlaysRequest) (*AnalyticsPlaysResponse, error) { +func (s *AnalyticsService) GetMetricsOverTimeWithContext(ctx context.Context, metric string, r AnalyticsApiGetMetricsOverTimeRequest) (*AnalyticsMetricsOverTimeResponse, error) { var localVarPostBody interface{} - localVarPath := "/analytics/videos/plays" + localVarPath := "/data/timeseries/{metric}" + localVarPath = strings.Replace(localVarPath, "{"+"metric"+"}", url.PathEscape(parameterToString(metric, "")), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := url.Values{} - localVarQueryParams.Add("from", parameterToString(*r.from, "")) + if r.from != nil { + localVarQueryParams.Add("from", parameterToString(*r.from, "")) + } if r.to != nil { localVarQueryParams.Add("to", parameterToString(*r.to, "")) } - localVarQueryParams.Add("dimension", parameterToString(*r.dimension, "")) - if r.filter != nil { - localVarQueryParams.Add("filter", parameterToString(*r.filter, "")) + if r.interval != nil { + localVarQueryParams.Add("interval", parameterToString(*r.interval, "")) + } + if r.filterBy != nil { + addDeepQueryParams(r.filterBy, "filterBy", localVarQueryParams) } if r.currentPage != nil { localVarQueryParams.Add("currentPage", parameterToString(*r.currentPage, "")) @@ -234,7 +349,7 @@ func (s *AnalyticsService) GetVideosPlaysWithContext(ctx context.Context, r Anal return nil, err } - res := new(AnalyticsPlaysResponse) + res := new(AnalyticsMetricsOverTimeResponse) _, err = s.client.do(req, res) if err != nil { diff --git a/api_analytics_test.go b/api_analytics_test.go deleted file mode 100644 index f39216a..0000000 --- a/api_analytics_test.go +++ /dev/null @@ -1,254 +0,0 @@ -package apivideosdk - -import ( - "fmt" - "net/http" - "reflect" - "testing" -) - -var liveStreamsPlaysResponses = []string{ - `{ - "data" : [ { - "value" : "li3q7HxhApxRF1c8F8r6VeaI", - "plays" : 100 - }, { - "value" : "li3q7HxhApxRF1c8F8r6VeaB", - "plays" : 10 - }, { - "value" : "li3q7HxhApxRF1c8F8r6VeaD", - "plays" : 1 - } - ] - }`, - `{ - "data" : [ { - "value" : "france", - "plays" : 100 - }, { - "value" : "united states", - "plays" : 10 - }, { - "value" : "spain", - "plays" : 1 - } - ] - }`, - `{ - "data" : [ { - "value" : "2023-06-10T10:00:00.000Z", - "plays" : 100 - }, { - "value" : "2023-06-10T11:00:00.000Z", - "plays" : 10 - }, { - "value" : "2023-06-10T12:00:00.000Z", - "plays" : 1 - } - ] - }`, -} - -var liveStreamsPlaysStructs = []AnalyticsPlaysResponse{ - { - Data: []AnalyticsData{ - {Value: "li3q7HxhApxRF1c8F8r6VeaI", Plays: 100}, - {Value: "li3q7HxhApxRF1c8F8r6VeaB", Plays: 10}, - {Value: "li3q7HxhApxRF1c8F8r6VeaD", Plays: 1}, - }, - }, - { - Data: []AnalyticsData{ - {Value: "france", Plays: 100}, - {Value: "united states", Plays: 10}, - {Value: "spain", Plays: 1}, - }, - }, - { - Data: []AnalyticsData{ - {Value: "2023-06-10T10:00:00.000Z", Plays: 100}, - {Value: "2023-06-10T11:00:00.000Z", Plays: 10}, - {Value: "2023-06-10T12:00:00.000Z", Plays: 1}, - }, - }, -} - -func TestAnalytics_GetLiveStreamsPlaysByLiveStreamId(t *testing.T) { - setup() - defer teardown() - mux.HandleFunc("/analytics/live-streams/plays", func(w http.ResponseWriter, r *http.Request) { - testMethod(t, r, http.MethodGet) - fmt.Fprint(w, liveStreamsPlaysResponses[0]) - }) - - plays, err := client.Analytics.GetLiveStreamsPlays(AnalyticsApiGetLiveStreamsPlaysRequest{}.From("2023-04-01").Dimension("liveStreamId")) - if err != nil { - t.Errorf("Analytics.GetLiveStreamsPlays error: %v", err) - } - - expected := &liveStreamsPlaysStructs[0] - if !reflect.DeepEqual(plays, expected) { - t.Errorf("Analytics.GetLiveStreamsPlays\n got=%#v\nwant=%#v", plays, expected) - } -} - -func TestAnalytics_GetLiveStreamsPlaysByCountry(t *testing.T) { - setup() - defer teardown() - mux.HandleFunc("/analytics/live-streams/plays", func(w http.ResponseWriter, r *http.Request) { - testMethod(t, r, http.MethodGet) - fmt.Fprint(w, liveStreamsPlaysResponses[1]) - }) - - plays, err := client.Analytics.GetLiveStreamsPlays(AnalyticsApiGetLiveStreamsPlaysRequest{}.From("2023-04-01").Dimension("country")) - if err != nil { - t.Errorf("Analytics.GetLiveStreamsPlays error: %v", err) - } - - expected := &liveStreamsPlaysStructs[1] - if !reflect.DeepEqual(plays, expected) { - t.Errorf("Analytics.GetLiveStreamsPlays\n got=%#v\nwant=%#v", plays, expected) - } -} - -func TestAnalytics_GetLiveStreamsPlaysByEmittedAt(t *testing.T) { - setup() - defer teardown() - mux.HandleFunc("/analytics/live-streams/plays", func(w http.ResponseWriter, r *http.Request) { - testMethod(t, r, http.MethodGet) - fmt.Fprint(w, liveStreamsPlaysResponses[2]) - }) - - plays, err := client.Analytics.GetLiveStreamsPlays(AnalyticsApiGetLiveStreamsPlaysRequest{}.From("2023-04-01").Dimension("emittedAt")) - if err != nil { - t.Errorf("Analytics.GetLiveStreamsPlays error: %v", err) - } - - expected := &liveStreamsPlaysStructs[2] - if !reflect.DeepEqual(plays, expected) { - t.Errorf("Analytics.GetLiveStreamsPlays\n got=%#v\nwant=%#v", plays, expected) - } -} - -var videosPlaysResponses = []string{ - `{ - "data" : [ { - "value" : "vi3q7HxhApxRF1c8F8r6VeaI", - "plays" : 100 - }, { - "value" : "vi3q7HxhApxRF1c8F8r6VeaF", - "plays" : 10 - }, { - "value" : "vi3q7HxhApxRF1c8F8r6VeaH", - "plays" : 1 - } - ] - }`, - `{ - "data" : [ { - "value" : "france", - "plays" : 100 - }, { - "value" : "united states", - "plays" : 10 - }, { - "value" : "spain", - "plays" : 1 - } - ] - }`, - `{ - "data" : [ { - "value" : "2023-06-10T10:00:00.000Z", - "plays" : 100 - }, { - "value" : "2023-06-10T11:00:00.000Z", - "plays" : 10 - }, { - "value" : "2023-06-10T12:00:00.000Z", - "plays" : 1 - } - ] - }`, -} - -var videosPlaysStructs = []AnalyticsPlaysResponse{ - { - Data: []AnalyticsData{ - {Value: "vi3q7HxhApxRF1c8F8r6VeaI", Plays: 100}, - {Value: "vi3q7HxhApxRF1c8F8r6VeaF", Plays: 10}, - {Value: "vi3q7HxhApxRF1c8F8r6VeaH", Plays: 1}, - }, - }, - { - Data: []AnalyticsData{ - {Value: "france", Plays: 100}, - {Value: "united states", Plays: 10}, - {Value: "spain", Plays: 1}, - }, - }, - { - Data: []AnalyticsData{ - {Value: "2023-06-10T10:00:00.000Z", Plays: 100}, - {Value: "2023-06-10T11:00:00.000Z", Plays: 10}, - {Value: "2023-06-10T12:00:00.000Z", Plays: 1}, - }, - }, -} - -func TestAnalytics_GetVideosPlaysByVideoId(t *testing.T) { - setup() - defer teardown() - mux.HandleFunc("/analytics/videos/plays", func(w http.ResponseWriter, r *http.Request) { - testMethod(t, r, http.MethodGet) - fmt.Fprint(w, videosPlaysResponses[0]) - }) - - plays, err := client.Analytics.GetVideosPlays(AnalyticsApiGetVideosPlaysRequest{}.From("2023-04-01").Dimension("videoId")) - if err != nil { - t.Errorf("Analytics.GetVideosPlays error: %v", err) - } - - expected := &videosPlaysStructs[0] - if !reflect.DeepEqual(plays, expected) { - t.Errorf("Analytics.GetVideosPlays\n got=%#v\nwant=%#v", plays, expected) - } -} - -func TestAnalytics_GetVideosPlaysByCountry(t *testing.T) { - setup() - defer teardown() - mux.HandleFunc("/analytics/videos/plays", func(w http.ResponseWriter, r *http.Request) { - testMethod(t, r, http.MethodGet) - fmt.Fprint(w, videosPlaysResponses[1]) - }) - - plays, err := client.Analytics.GetVideosPlays(AnalyticsApiGetVideosPlaysRequest{}.From("2023-04-01").Dimension("country")) - if err != nil { - t.Errorf("Analytics.GetVideosPlays error: %v", err) - } - - expected := &videosPlaysStructs[1] - if !reflect.DeepEqual(plays, expected) { - t.Errorf("Analytics.GetVideosPlays\n got=%#v\nwant=%#v", plays, expected) - } -} - -func TestAnalytics_GetVideosPlaysByEmittedAt(t *testing.T) { - setup() - defer teardown() - mux.HandleFunc("/analytics/videos/plays", func(w http.ResponseWriter, r *http.Request) { - testMethod(t, r, http.MethodGet) - fmt.Fprint(w, videosPlaysResponses[2]) - }) - - plays, err := client.Analytics.GetVideosPlays(AnalyticsApiGetVideosPlaysRequest{}.From("2023-04-01").Dimension("emittedAt")) - if err != nil { - t.Errorf("Analytics.GetVideosPlays error: %v", err) - } - - expected := &videosPlaysStructs[2] - if !reflect.DeepEqual(plays, expected) { - t.Errorf("Analytics.GetVideosPlays\n got=%#v\nwant=%#v", plays, expected) - } -} diff --git a/api_live_streams.go b/api_live_streams.go index e2af08e..a9bb31a 100644 --- a/api_live_streams.go +++ b/api_live_streams.go @@ -185,6 +185,23 @@ type LiveStreamsServiceI interface { */ DeleteThumbnailWithContext(ctx context.Context, liveStreamId string) (*LiveStream, error) + + /* + * Complete Complete a live stream + * @param liveStreamId The unique ID for the live stream you want to complete. + * @return LiveStreamsApiCompleteRequest + */ + + Complete(liveStreamId string) error + + /* + * Complete Complete a live stream + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param liveStreamId The unique ID for the live stream you want to complete. + * @return LiveStreamsApiCompleteRequest + */ + + CompleteWithContext(ctx context.Context, liveStreamId string) error } // LiveStreamsService communicating with the LiveStreams @@ -559,3 +576,61 @@ func (s *LiveStreamsService) DeleteThumbnailWithContext(ctx context.Context, liv return res, nil } + +/* + * Complete Complete a live stream + * Request the completion of a live stream that is currently running. This operation is asynchronous and the live stream will stop after a few seconds. + + + +The API adds the `EXT-X-ENDLIST` tag to the live stream's HLS manifest. This stops the live stream on the player and also stops the recording of the live stream. The API keeps the incoming connection from the streamer open for at most 1 minute, which can be used to terminate the stream. + + + + * @param liveStreamId The unique ID for the live stream you want to complete. + * @return LiveStreamsApiCompleteRequest +*/ + +func (s *LiveStreamsService) Complete(liveStreamId string) error { + + return s.CompleteWithContext(context.Background(), liveStreamId) + +} + +/* + * Complete Complete a live stream + * Request the completion of a live stream that is currently running. This operation is asynchronous and the live stream will stop after a few seconds. + + + +The API adds the `EXT-X-ENDLIST` tag to the live stream's HLS manifest. This stops the live stream on the player and also stops the recording of the live stream. The API keeps the incoming connection from the streamer open for at most 1 minute, which can be used to terminate the stream. + + + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param liveStreamId The unique ID for the live stream you want to complete. + * @return LiveStreamsApiCompleteRequest +*/ + +func (s *LiveStreamsService) CompleteWithContext(ctx context.Context, liveStreamId string) error { + var localVarPostBody interface{} + + localVarPath := "/live-streams/{liveStreamId}/complete" + localVarPath = strings.Replace(localVarPath, "{"+"liveStreamId"+"}", url.PathEscape(parameterToString(liveStreamId, "")), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + + req, err := s.client.prepareRequest(ctx, http.MethodPut, localVarPath, localVarPostBody, localVarHeaderParams, localVarQueryParams) + if err != nil { + return err + } + + _, err = s.client.do(req, nil) + + if err != nil { + return err + } + + return nil + +} diff --git a/api_videos.go b/api_videos.go index 53c5e09..4b0106f 100644 --- a/api_videos.go +++ b/api_videos.go @@ -12,7 +12,6 @@ package apivideosdk import ( "context" - "fmt" "io" "net/http" "net/url" @@ -985,11 +984,7 @@ func (s *VideosService) ListWithContext(ctx context.Context, r VideosApiListRequ } } if r.metadata != nil { - if r.metadata != nil && len(*r.metadata) > 0 { - for k, v := range *r.metadata { - localVarQueryParams.Add(fmt.Sprintf("metadata[%s]", k), v) - } - } + addDeepQueryParams(r.metadata, "metadata", localVarQueryParams) } if r.description != nil { localVarQueryParams.Add("description", parameterToString(*r.description, "")) diff --git a/client.go b/client.go index 5f15b26..0a4f538 100644 --- a/client.go +++ b/client.go @@ -255,7 +255,7 @@ func (c *Client) prepareRequest( req.Header.Set("AV-Origin-Sdk", originSdkHeaderValue) } - req.Header.Set("AV-Origin-Client", "go:1.3.1") + req.Header.Set("AV-Origin-Client", "go:1.4.0") for headerName := range headerParams { req.Header.Set(headerName, headerParams[headerName]) @@ -530,7 +530,7 @@ func (c *Client) auth(req *http.Request) (*http.Request, error) { req.Header.Set("AV-Origin-Sdk", originSdkHeaderValue) } - req.Header.Set("AV-Origin-Client", "go:1.3.1") + req.Header.Set("AV-Origin-Client", "go:1.4.0") resp, err := c.httpClient.Do(req) @@ -596,3 +596,43 @@ func parameterToString(obj interface{}, collectionFormat string) string { return fmt.Sprintf("%v", obj) } + +func addDeepQueryParams(filter interface{}, prefix string, queryParams url.Values) { + v := reflect.ValueOf(filter) + if v.Kind() == reflect.Ptr && !v.IsNil() { + v = v.Elem() + } + switch v.Kind() { + case reflect.Struct: + t := v.Type() + + for i := 0; i < v.NumField(); i++ { + field := v.Field(i) + fieldType := t.Field(i) + + if field.Kind() == reflect.Ptr && !field.IsNil() { + field = field.Elem() + } + + lowercaseFirstChar := strings.ToLower(string(fieldType.Name[0])) + restOfString := fieldType.Name[1:] + lowercaseName := lowercaseFirstChar + restOfString + + if field.Kind() == reflect.Slice { + for j := 0; j < field.Len(); j++ { + item := field.Index(j) + queryParams.Add(fmt.Sprintf("%s[%s][%d]", prefix, lowercaseName, j), item.String()) + } + } else if field.Kind() == reflect.String { + queryParams.Add(fmt.Sprintf("%s[%s]", prefix, lowercaseName), field.String()) + } + } + case reflect.Map: + for _, key := range v.MapKeys() { + val := v.MapIndex(key) + queryParams.Add(fmt.Sprintf("%s[%s]", prefix, key.String()), fmt.Sprintf("%v", val)) + } + default: + fmt.Println("Unsupported type") + } +} diff --git a/docs/Analytics.md b/docs/Analytics.md index a6580b6..8feb233 100644 --- a/docs/Analytics.md +++ b/docs/Analytics.md @@ -4,21 +4,22 @@ All URIs are relative to *https://ws.api.video* Method | HTTP request | Description ------------- | ------------- | ------------- -[**GetLiveStreamsPlays**](Analytics.md#GetLiveStreamsPlays) | **Get** /analytics/live-streams/plays | Get play events for live stream -[**GetVideosPlays**](Analytics.md#GetVideosPlays) | **Get** /analytics/videos/plays | Get play events for video +[**GetAggregatedMetrics**](Analytics.md#GetAggregatedMetrics) | **Get** /data/metrics/{metric}/{aggregation} | Retrieve aggregated metrics +[**GetMetricsBreakdown**](Analytics.md#GetMetricsBreakdown) | **Get** /data/buckets/{metric}/{breakdown} | Retrieve metrics in a breakdown of dimensions +[**GetMetricsOverTime**](Analytics.md#GetMetricsOverTime) | **Get** /data/timeseries/{metric} | Retrieve metrics over time -## GetLiveStreamsPlays +## GetAggregatedMetrics -> GetLiveStreamsPlays(r AnalyticsApiGetLiveStreamsPlaysRequest) (*AnalyticsPlaysResponse, error) +> GetAggregatedMetrics(metric string, aggregation string, r AnalyticsApiGetAggregatedMetricsRequest) (*AnalyticsAggregatedMetricsResponse, error) -> GetLiveStreamsPlaysWithContext(ctx context.Context, r AnalyticsApiGetLiveStreamsPlaysRequest) (*AnalyticsPlaysResponse, error) +> GetAggregatedMetricsWithContext(ctx context.Context, metric string, aggregation string, r AnalyticsApiGetAggregatedMetricsRequest) (*AnalyticsAggregatedMetricsResponse, error) -Get play events for live stream +Retrieve aggregated metrics @@ -39,28 +40,108 @@ func main() { client := apivideosdk.ClientBuilder("YOUR_API_KEY").Build() // if you rather like to use the sandbox environment: // client := apivideosdk.SandboxClientBuilder("YOU_SANDBOX_API_KEY").Build() - req := apivideosdk.AnalyticsApiGetLiveStreamsPlaysRequest{} + req := apivideosdk.AnalyticsApiGetAggregatedMetricsRequest{} - req.From(time.Now()) // string | Use this query parameter to set the start date for the time period that you want analytics for. - The API returns analytics data including the day you set in `from`. - The date you set must be **within the last 30 days**. - The value you provide must follow the `YYYY-MM-DD` format. - req.Dimension("browser") // string | Use this query parameter to define the dimension that you want analytics for. - `liveStreamId`: Returns analytics based on the public live stream identifiers. - `emittedAt`: Returns analytics based on the times of the play events. The API returns data in specific interval groups. When the date period you set in `from` and `to` is less than or equals to 2 days, the response for this dimension is grouped in hourly intervals. Otherwise, it is grouped in daily intervals. - `country`: Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). - `deviceType`: Returns analytics based on the type of device used by the viewers during the play event. Possible response values are: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. - `operatingSystem`: Returns analytics based on the operating system used by the viewers during the play event. Response values include `windows`, `mac osx`, `android`, `ios`, `linux`. - `browser`: Returns analytics based on the browser used by the viewers during the play event. Response values include `chrome`, `firefox`, `edge`, `opera`. - req.To(time.Now()) // string | Use this optional query parameter to set the end date for the time period that you want analytics for. - If you do not specify a `to` date, the API returns analytics data starting from the `from` date up until today, and excluding today. - The date you set must be **within the last 30 days**. - The value you provide must follow the `YYYY-MM-DD` format. - req.Filter("liveStreamId:li3q7HxhApxRF1c8F8r6VeaI") // string | Use this query parameter to filter your results to a specific live stream in a project that you want analytics for. You must use the `liveStreamId:` prefix when specifying a live stream ID. + req.Metric("metric_example") // string | Use this path parameter to select a metric that you want analytics for. - `play` is the number of times your content has been played. You can use the aggregations `count`, `rate`, and `total` with the `play` metric. - `start` is the number of times playback was started. You can use the aggregation `count` with this metric. - `end` is the number of times playback has ended with the content watch until the end. You can use the aggregation `count` with this metric. - `impression` is the number of times your content has been loaded and was ready for playback. You can use the aggregation `count` with this metric. - `impression-time` is the time in milliseconds that your content was loading for until the first video frame is displayed. You can use the aggregations `average` and `sum` with this metric. - `watch-time` is the cumulative time in seconds that the user has spent watching your content. You can use the aggregations `average` and `sum` with this metric. + req.Aggregation("aggregation_example") // string | Use this path parameter to define a way of collecting data for the metric that you want analytics for. - `count` returns the overall number of events for the `play` metric. - `rate` returns the ratio that calculates the number of plays your content receives divided by its impressions. This aggregation can be used only with the `play` metric. - `total` calculates the total number of events for the `play` metric. - `average` calculates an average value for the selected metric. - `sum` adds up the total value of the select metric. + req.From(time.Now()) // time.Time | Use this query parameter to define the starting date-time of the period you want analytics for. - If you do not set a value for `from`, the default assigned value is 1 day ago, based on the `to` parameter. - The maximum value is 30 days ago. - The value you provide should follow the ATOM date-time format: `2024-02-05T00:00:00+01:00` - The API ignores this parameter when you call `/data/metrics/play/total`. + req.To(time.Now()) // time.Time | Use this query parameter to define the ending date-time of the period you want analytics for. - If you do not set a value for `to`, the default assigned value is `now`. - The API ignores this parameter when you call `/data/metrics/play/total`. - The value for `to` is a non-inclusive value: the API returns data **before** the date-time that you set. + req.FilterBy(map[string][]apivideosdk.FilterBy2{"key": "TODO"}) // FilterBy2 | Use this parameter to filter the API's response based on different data dimensions. You can serialize filters in your query to receive more detailed breakdowns of your analytics. - If you do not set a value for `filterBy`, the API returns the full dataset for your project. - The API only accepts the `mediaId` and `mediaType` filters when you call `/data/metrics/play/total` or `/data/buckets/play-total/media-id`. These are the available breakdown dimensions: - `mediaId`: Returns analytics based on the unique identifiers of a video or a live stream. - `mediaType`: Returns analytics based on the type of content. Possible values: `video` and `live-stream`. - `continent`: Returns analytics based on the viewers' continent. The list of supported continents names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `EU`. Possible values are: `AS`, `AF`, `NA`, `SA`, `AN`, `EU`, `AZ`. - `country`: Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `FR`. - `deviceType`: Returns analytics based on the type of device used by the viewers. Response values can include: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. - `operatingSystem`: Returns analytics based on the operating system used by the viewers. Response values can include `windows`, `mac osx`, `android`, `ios`, `linux`. - `browser`: Returns analytics based on the browser used by the viewers. Response values can include `chrome`, `firefox`, `edge`, `opera`. - `tag`: Returns analytics for videos using this tag. This filter only accepts a single value and is case sensitive. Read more about tagging your videos [here](https://docs.api.video/vod/tags-metadata). + + res, err := client.Analytics.GetAggregatedMetrics(metric string, aggregation string, req) + + + if err != nil { + fmt.Fprintf(os.Stderr, "Error when calling `Analytics.GetAggregatedMetrics``: %v\n", err) + } + // response from `GetAggregatedMetrics`: AnalyticsAggregatedMetricsResponse + fmt.Fprintf(os.Stdout, "Response from `Analytics.GetAggregatedMetrics`: %v\n", res) +} +``` +### Path Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- +**metric** | **string** | Use this path parameter to select a metric that you want analytics for. - `play` is the number of times your content has been played. You can use the aggregations `count`, `rate`, and `total` with the `play` metric. - `start` is the number of times playback was started. You can use the aggregation `count` with this metric. - `end` is the number of times playback has ended with the content watch until the end. You can use the aggregation `count` with this metric. - `impression` is the number of times your content has been loaded and was ready for playback. You can use the aggregation `count` with this metric. - `impression-time` is the time in milliseconds that your content was loading for until the first video frame is displayed. You can use the aggregations `average` and `sum` with this metric. - `watch-time` is the cumulative time in seconds that the user has spent watching your content. You can use the aggregations `average` and `sum` with this metric. | +**aggregation** | **string** | Use this path parameter to define a way of collecting data for the metric that you want analytics for. - `count` returns the overall number of events for the `play` metric. - `rate` returns the ratio that calculates the number of plays your content receives divided by its impressions. This aggregation can be used only with the `play` metric. - `total` calculates the total number of events for the `play` metric. - `average` calculates an average value for the selected metric. - `sum` adds up the total value of the select metric. | + +### Other Parameters + + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- +**from** | **time.Time** | Use this query parameter to define the starting date-time of the period you want analytics for. - If you do not set a value for `from`, the default assigned value is 1 day ago, based on the `to` parameter. - The maximum value is 30 days ago. - The value you provide should follow the ATOM date-time format: `2024-02-05T00:00:00+01:00` - The API ignores this parameter when you call `/data/metrics/play/total`. | +**to** | **time.Time** | Use this query parameter to define the ending date-time of the period you want analytics for. - If you do not set a value for `to`, the default assigned value is `now`. - The API ignores this parameter when you call `/data/metrics/play/total`. - The value for `to` is a non-inclusive value: the API returns data **before** the date-time that you set. | +**filterBy** | [**FilterBy2**](FilterBy2.md) | Use this parameter to filter the API's response based on different data dimensions. You can serialize filters in your query to receive more detailed breakdowns of your analytics. - If you do not set a value for `filterBy`, the API returns the full dataset for your project. - The API only accepts the `mediaId` and `mediaType` filters when you call `/data/metrics/play/total` or `/data/buckets/play-total/media-id`. These are the available breakdown dimensions: - `mediaId`: Returns analytics based on the unique identifiers of a video or a live stream. - `mediaType`: Returns analytics based on the type of content. Possible values: `video` and `live-stream`. - `continent`: Returns analytics based on the viewers' continent. The list of supported continents names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `EU`. Possible values are: `AS`, `AF`, `NA`, `SA`, `AN`, `EU`, `AZ`. - `country`: Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `FR`. - `deviceType`: Returns analytics based on the type of device used by the viewers. Response values can include: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. - `operatingSystem`: Returns analytics based on the operating system used by the viewers. Response values can include `windows`, `mac osx`, `android`, `ios`, `linux`. - `browser`: Returns analytics based on the browser used by the viewers. Response values can include `chrome`, `firefox`, `edge`, `opera`. - `tag`: Returns analytics for videos using this tag. This filter only accepts a single value and is case sensitive. Read more about tagging your videos [here](https://docs.api.video/vod/tags-metadata). | + +### Return type + +[**AnalyticsAggregatedMetricsResponse**](AnalyticsAggregatedMetricsResponse.md) + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + + +## GetMetricsBreakdown + +> GetMetricsBreakdown(metric string, breakdown string, r AnalyticsApiGetMetricsBreakdownRequest) (*AnalyticsMetricsBreakdownResponse, error) + + +> GetMetricsBreakdownWithContext(ctx context.Context, metric string, breakdown string, r AnalyticsApiGetMetricsBreakdownRequest) (*AnalyticsMetricsBreakdownResponse, error) + + + +Retrieve metrics in a breakdown of dimensions + + + +### Example + +```go +package main + +import ( + "context" + "fmt" + "os" + "time" + apivideosdk "github.com/apivideo/api.video-go-client" +) + +func main() { + client := apivideosdk.ClientBuilder("YOUR_API_KEY").Build() + // if you rather like to use the sandbox environment: + // client := apivideosdk.SandboxClientBuilder("YOU_SANDBOX_API_KEY").Build() + req := apivideosdk.AnalyticsApiGetMetricsBreakdownRequest{} + + req.Metric("metric_example") // string | Use this path parameter to select a metric that you want analytics for. - `play` is the number of times your content has been played. - `play-rate` is the ratio that calculates the number of plays your content receives divided by its impressions. - `play-total` is the total number of times a specific content has been played. You can only use the `media-id` breakdown with this metric. - `start` is the number of times playback was started. - `end` is the number of times playback has ended with the content watch until the end. - `impression` is the number of times your content has been loaded and was ready for playback. + req.Breakdown("breakdown_example") // string | Use this path parameter to define a dimension for segmenting analytics data. You must use `kebab-case` for path parameters. These are the available dimensions: - `media-id`: Returns analytics based on the unique identifiers of a video or a live stream. - `media-type`: Returns analytics based on the type of content. Possible values: `video` and `live-stream`. - `continent`: Returns analytics based on the viewers' continent. The list of supported continents names are based on the [GeoNames public database](https://www.geonames.org/countries/). Possible values are: `AS`, `AF`, `NA`, `SA`, `AN`, `EU`, `AZ`. - `country`: Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). - `device-type`: Returns analytics based on the type of device used by the viewers. Response values can include: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. - `operating-system`: Returns analytics based on the operating system used by the viewers. Response values can include `windows`, `mac osx`, `android`, `ios`, `linux`. - `browser`: Returns analytics based on the browser used by the viewers. Response values can include `chrome`, `firefox`, `edge`, `opera`. + req.From(time.Now()) // time.Time | Use this query parameter to define the starting date-time of the period you want analytics for. - If you do not set a value for `from`, the default assigned value is 1 day ago, based on the `to` parameter. - The maximum value is 30 days ago. - The value you provide should follow the ATOM date-time format: `2024-02-05T00:00:00+01:00` + req.To(time.Now()) // time.Time | Use this query parameter to define the ending date-time of the period you want analytics for. - If you do not set a value for `to`, the default assigned value is `now`. - The value for `to` is a non-inclusive value: the API returns data **before** the date-time that you set. + req.FilterBy(map[string][]apivideosdk.FilterBy2{"key": "TODO"}) // FilterBy2 | Use this parameter to filter the API's response based on different data dimensions. You can serialize filters in your query to receive more detailed breakdowns of your analytics. - If you do not set a value for `filterBy`, the API returns the full dataset for your project. - The API only accepts the `mediaId` and `mediaType` filters when you call `/data/metrics/play/total` or `/data/buckets/play-total/media-id`. These are the available breakdown dimensions: - `mediaId`: Returns analytics based on the unique identifiers of a video or a live stream. - `mediaType`: Returns analytics based on the type of content. Possible values: `video` and `live-stream`. - `continent`: Returns analytics based on the viewers' continent. The list of supported continents names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `EU`. Possible values are: `AS`, `AF`, `NA`, `SA`, `AN`, `EU`, `AZ`. - `country`: Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `FR`. - `deviceType`: Returns analytics based on the type of device used by the viewers. Response values can include: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. - `operatingSystem`: Returns analytics based on the operating system used by the viewers. Response values can include `windows`, `mac osx`, `android`, `ios`, `linux`. - `browser`: Returns analytics based on the browser used by the viewers. Response values can include `chrome`, `firefox`, `edge`, `opera`. - `tag`: Returns analytics for videos using this tag. This filter only accepts a single value and is case sensitive. Read more about tagging your videos [here](https://docs.api.video/vod/tags-metadata). req.CurrentPage(int32(2)) // int32 | Choose the number of search results to return per page. Minimum value: 1 (default to 1) req.PageSize(int32(30)) // int32 | Results per page. Allowed values 1-100, default is 25. (default to 25) - res, err := client.Analytics.GetLiveStreamsPlays(req) + res, err := client.Analytics.GetMetricsBreakdown(metric string, breakdown string, req) if err != nil { - fmt.Fprintf(os.Stderr, "Error when calling `Analytics.GetLiveStreamsPlays``: %v\n", err) + fmt.Fprintf(os.Stderr, "Error when calling `Analytics.GetMetricsBreakdown``: %v\n", err) } - // response from `GetLiveStreamsPlays`: AnalyticsPlaysResponse - fmt.Fprintf(os.Stdout, "Response from `Analytics.GetLiveStreamsPlays`: %v\n", res) + // response from `GetMetricsBreakdown`: AnalyticsMetricsBreakdownResponse + fmt.Fprintf(os.Stdout, "Response from `Analytics.GetMetricsBreakdown`: %v\n", res) } ``` ### Path Parameters +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- +**metric** | **string** | Use this path parameter to select a metric that you want analytics for. - `play` is the number of times your content has been played. - `play-rate` is the ratio that calculates the number of plays your content receives divided by its impressions. - `play-total` is the total number of times a specific content has been played. You can only use the `media-id` breakdown with this metric. - `start` is the number of times playback was started. - `end` is the number of times playback has ended with the content watch until the end. - `impression` is the number of times your content has been loaded and was ready for playback. | +**breakdown** | **string** | Use this path parameter to define a dimension for segmenting analytics data. You must use `kebab-case` for path parameters. These are the available dimensions: - `media-id`: Returns analytics based on the unique identifiers of a video or a live stream. - `media-type`: Returns analytics based on the type of content. Possible values: `video` and `live-stream`. - `continent`: Returns analytics based on the viewers' continent. The list of supported continents names are based on the [GeoNames public database](https://www.geonames.org/countries/). Possible values are: `AS`, `AF`, `NA`, `SA`, `AN`, `EU`, `AZ`. - `country`: Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). - `device-type`: Returns analytics based on the type of device used by the viewers. Response values can include: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. - `operating-system`: Returns analytics based on the operating system used by the viewers. Response values can include `windows`, `mac osx`, `android`, `ios`, `linux`. - `browser`: Returns analytics based on the browser used by the viewers. Response values can include `chrome`, `firefox`, `edge`, `opera`. | ### Other Parameters @@ -68,32 +149,31 @@ func main() { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**from** | **string** | Use this query parameter to set the start date for the time period that you want analytics for. - The API returns analytics data including the day you set in `from`. - The date you set must be **within the last 30 days**. - The value you provide must follow the `YYYY-MM-DD` format. | -**dimension** | **string** | Use this query parameter to define the dimension that you want analytics for. - `liveStreamId`: Returns analytics based on the public live stream identifiers. - `emittedAt`: Returns analytics based on the times of the play events. The API returns data in specific interval groups. When the date period you set in `from` and `to` is less than or equals to 2 days, the response for this dimension is grouped in hourly intervals. Otherwise, it is grouped in daily intervals. - `country`: Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). - `deviceType`: Returns analytics based on the type of device used by the viewers during the play event. Possible response values are: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. - `operatingSystem`: Returns analytics based on the operating system used by the viewers during the play event. Response values include `windows`, `mac osx`, `android`, `ios`, `linux`. - `browser`: Returns analytics based on the browser used by the viewers during the play event. Response values include `chrome`, `firefox`, `edge`, `opera`. | -**to** | **string** | Use this optional query parameter to set the end date for the time period that you want analytics for. - If you do not specify a `to` date, the API returns analytics data starting from the `from` date up until today, and excluding today. - The date you set must be **within the last 30 days**. - The value you provide must follow the `YYYY-MM-DD` format. | -**filter** | **string** | Use this query parameter to filter your results to a specific live stream in a project that you want analytics for. You must use the `liveStreamId:` prefix when specifying a live stream ID. | +**from** | **time.Time** | Use this query parameter to define the starting date-time of the period you want analytics for. - If you do not set a value for `from`, the default assigned value is 1 day ago, based on the `to` parameter. - The maximum value is 30 days ago. - The value you provide should follow the ATOM date-time format: `2024-02-05T00:00:00+01:00` | +**to** | **time.Time** | Use this query parameter to define the ending date-time of the period you want analytics for. - If you do not set a value for `to`, the default assigned value is `now`. - The value for `to` is a non-inclusive value: the API returns data **before** the date-time that you set. | +**filterBy** | [**FilterBy2**](FilterBy2.md) | Use this parameter to filter the API's response based on different data dimensions. You can serialize filters in your query to receive more detailed breakdowns of your analytics. - If you do not set a value for `filterBy`, the API returns the full dataset for your project. - The API only accepts the `mediaId` and `mediaType` filters when you call `/data/metrics/play/total` or `/data/buckets/play-total/media-id`. These are the available breakdown dimensions: - `mediaId`: Returns analytics based on the unique identifiers of a video or a live stream. - `mediaType`: Returns analytics based on the type of content. Possible values: `video` and `live-stream`. - `continent`: Returns analytics based on the viewers' continent. The list of supported continents names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `EU`. Possible values are: `AS`, `AF`, `NA`, `SA`, `AN`, `EU`, `AZ`. - `country`: Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `FR`. - `deviceType`: Returns analytics based on the type of device used by the viewers. Response values can include: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. - `operatingSystem`: Returns analytics based on the operating system used by the viewers. Response values can include `windows`, `mac osx`, `android`, `ios`, `linux`. - `browser`: Returns analytics based on the browser used by the viewers. Response values can include `chrome`, `firefox`, `edge`, `opera`. - `tag`: Returns analytics for videos using this tag. This filter only accepts a single value and is case sensitive. Read more about tagging your videos [here](https://docs.api.video/vod/tags-metadata). | **currentPage** | **int32** | Choose the number of search results to return per page. Minimum value: 1 | [default to 1] **pageSize** | **int32** | Results per page. Allowed values 1-100, default is 25. | [default to 25] ### Return type -[**AnalyticsPlaysResponse**](AnalyticsPlaysResponse.md) +[**AnalyticsMetricsBreakdownResponse**](AnalyticsMetricsBreakdownResponse.md) [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) -## GetVideosPlays +## GetMetricsOverTime -> GetVideosPlays(r AnalyticsApiGetVideosPlaysRequest) (*AnalyticsPlaysResponse, error) +> GetMetricsOverTime(metric string, r AnalyticsApiGetMetricsOverTimeRequest) (*AnalyticsMetricsOverTimeResponse, error) -> GetVideosPlaysWithContext(ctx context.Context, r AnalyticsApiGetVideosPlaysRequest) (*AnalyticsPlaysResponse, error) +> GetMetricsOverTimeWithContext(ctx context.Context, metric string, r AnalyticsApiGetMetricsOverTimeRequest) (*AnalyticsMetricsOverTimeResponse, error) -Get play events for video +Retrieve metrics over time @@ -114,28 +194,32 @@ func main() { client := apivideosdk.ClientBuilder("YOUR_API_KEY").Build() // if you rather like to use the sandbox environment: // client := apivideosdk.SandboxClientBuilder("YOU_SANDBOX_API_KEY").Build() - req := apivideosdk.AnalyticsApiGetVideosPlaysRequest{} + req := apivideosdk.AnalyticsApiGetMetricsOverTimeRequest{} - req.From(time.Now()) // string | Use this query parameter to set the start date for the time period that you want analytics for. - The API returns analytics data including the day you set in `from`. - The date you set must be **within the last 30 days**. - The value you provide must follow the `YYYY-MM-DD` format. - req.Dimension("browser") // string | Use this query parameter to define the dimension that you want analytics for. - `videoId`: Returns analytics based on the public video identifiers. - `emittedAt`: Returns analytics based on the times of the play events. The API returns data in specific interval groups. When the date period you set in `from` and `to` is less than or equals to 2 days, the response for this dimension is grouped in hourly intervals. Otherwise, it is grouped in daily intervals. - `country`: Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). - `deviceType`: Returns analytics based on the type of device used by the viewers during the play event. Possible response values are: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. - `operatingSystem`: Returns analytics based on the operating system used by the viewers during the play event. Response values include `windows`, `mac osx`, `android`, `ios`, `linux`. - `browser`: Returns analytics based on the browser used by the viewers during the play event. Response values include `chrome`, `firefox`, `edge`, `opera`. - req.To(time.Now()) // string | Use this optional query parameter to set the end date for the time period that you want analytics for. - If you do not specify a `to` date, the API returns analytics data starting from the `from` date up until today, and excluding today. - The date you set must be **within the last 30 days**. - The value you provide must follow the `YYYY-MM-DD` format. - req.Filter("videoId:vi3q7HxhApxRF1c8F8r6VeaI") // string | Use this query parameter to filter your results to a specific video in a project that you want analytics for. You must use the `videoId:` prefix when specifying a video ID. + req.Metric("metric_example") // string | Use this path parameter to select a metric that you want analytics for. - `play` is the number of times your content has been played. - `play-rate` is the ratio that calculates the number of plays your content receives divided by its impressions. - `start` is the number of times playback was started. - `end` is the number of times playback has ended with the content watch until the end. - `impression` is the number of times your content has been loaded and was ready for playback. + req.From(time.Now()) // time.Time | Use this query parameter to define the starting date-time of the period you want analytics for. - If you do not set a value for `from`, the default assigned value is 1 day ago, based on the `to` parameter. - The maximum value is 30 days ago. - The value you provide should follow the ATOM date-time format: `2024-02-05T00:00:00+01:00` + req.To(time.Now()) // time.Time | Use this query parameter to define the ending date-time of the period you want analytics for. - If you do not set a value for `to`, the default assigned value is `now`. - The value for `to` is a non-inclusive value: the API returns data **before** the date-time that you set. + req.Interval("hour") // string | Use this query parameter to define how granularity of the data. Possible values: `hour`, `day`. - Default: If no interval specified and the period (different between from and to) ≤ 2 days then hour, otherwise day. - If you do not set a value for `interval`, and the period you set using the `from` and `to` parameters is less than or equals to 2 days, then the default assigned value is `hour`. Otherwise the API sets it to `day`. + req.FilterBy(map[string][]apivideosdk.FilterBy2{"key": "TODO"}) // FilterBy2 | Use this parameter to filter the API's response based on different data dimensions. You can serialize filters in your query to receive more detailed breakdowns of your analytics. - If you do not set a value for `filterBy`, the API returns the full dataset for your project. - The API only accepts the `mediaId` and `mediaType` filters when you call `/data/metrics/play/total` or `/data/buckets/play-total/media-id`. These are the available breakdown dimensions: - `mediaId`: Returns analytics based on the unique identifiers of a video or a live stream. - `mediaType`: Returns analytics based on the type of content. Possible values: `video` and `live-stream`. - `continent`: Returns analytics based on the viewers' continent. The list of supported continents names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `EU`. Possible values are: `AS`, `AF`, `NA`, `SA`, `AN`, `EU`, `AZ`. - `country`: Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `FR`. - `deviceType`: Returns analytics based on the type of device used by the viewers. Response values can include: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. - `operatingSystem`: Returns analytics based on the operating system used by the viewers. Response values can include `windows`, `mac osx`, `android`, `ios`, `linux`. - `browser`: Returns analytics based on the browser used by the viewers. Response values can include `chrome`, `firefox`, `edge`, `opera`. - `tag`: Returns analytics for videos using this tag. This filter only accepts a single value and is case sensitive. Read more about tagging your videos [here](https://docs.api.video/vod/tags-metadata). req.CurrentPage(int32(2)) // int32 | Choose the number of search results to return per page. Minimum value: 1 (default to 1) req.PageSize(int32(30)) // int32 | Results per page. Allowed values 1-100, default is 25. (default to 25) - res, err := client.Analytics.GetVideosPlays(req) + res, err := client.Analytics.GetMetricsOverTime(metric string, req) if err != nil { - fmt.Fprintf(os.Stderr, "Error when calling `Analytics.GetVideosPlays``: %v\n", err) + fmt.Fprintf(os.Stderr, "Error when calling `Analytics.GetMetricsOverTime``: %v\n", err) } - // response from `GetVideosPlays`: AnalyticsPlaysResponse - fmt.Fprintf(os.Stdout, "Response from `Analytics.GetVideosPlays`: %v\n", res) + // response from `GetMetricsOverTime`: AnalyticsMetricsOverTimeResponse + fmt.Fprintf(os.Stdout, "Response from `Analytics.GetMetricsOverTime`: %v\n", res) } ``` ### Path Parameters +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- +**metric** | **string** | Use this path parameter to select a metric that you want analytics for. - `play` is the number of times your content has been played. - `play-rate` is the ratio that calculates the number of plays your content receives divided by its impressions. - `start` is the number of times playback was started. - `end` is the number of times playback has ended with the content watch until the end. - `impression` is the number of times your content has been loaded and was ready for playback. | ### Other Parameters @@ -143,16 +227,16 @@ func main() { Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**from** | **string** | Use this query parameter to set the start date for the time period that you want analytics for. - The API returns analytics data including the day you set in `from`. - The date you set must be **within the last 30 days**. - The value you provide must follow the `YYYY-MM-DD` format. | -**dimension** | **string** | Use this query parameter to define the dimension that you want analytics for. - `videoId`: Returns analytics based on the public video identifiers. - `emittedAt`: Returns analytics based on the times of the play events. The API returns data in specific interval groups. When the date period you set in `from` and `to` is less than or equals to 2 days, the response for this dimension is grouped in hourly intervals. Otherwise, it is grouped in daily intervals. - `country`: Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). - `deviceType`: Returns analytics based on the type of device used by the viewers during the play event. Possible response values are: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. - `operatingSystem`: Returns analytics based on the operating system used by the viewers during the play event. Response values include `windows`, `mac osx`, `android`, `ios`, `linux`. - `browser`: Returns analytics based on the browser used by the viewers during the play event. Response values include `chrome`, `firefox`, `edge`, `opera`. | -**to** | **string** | Use this optional query parameter to set the end date for the time period that you want analytics for. - If you do not specify a `to` date, the API returns analytics data starting from the `from` date up until today, and excluding today. - The date you set must be **within the last 30 days**. - The value you provide must follow the `YYYY-MM-DD` format. | -**filter** | **string** | Use this query parameter to filter your results to a specific video in a project that you want analytics for. You must use the `videoId:` prefix when specifying a video ID. | +**from** | **time.Time** | Use this query parameter to define the starting date-time of the period you want analytics for. - If you do not set a value for `from`, the default assigned value is 1 day ago, based on the `to` parameter. - The maximum value is 30 days ago. - The value you provide should follow the ATOM date-time format: `2024-02-05T00:00:00+01:00` | +**to** | **time.Time** | Use this query parameter to define the ending date-time of the period you want analytics for. - If you do not set a value for `to`, the default assigned value is `now`. - The value for `to` is a non-inclusive value: the API returns data **before** the date-time that you set. | +**interval** | **string** | Use this query parameter to define how granularity of the data. Possible values: `hour`, `day`. - Default: If no interval specified and the period (different between from and to) ≤ 2 days then hour, otherwise day. - If you do not set a value for `interval`, and the period you set using the `from` and `to` parameters is less than or equals to 2 days, then the default assigned value is `hour`. Otherwise the API sets it to `day`. | +**filterBy** | [**FilterBy2**](FilterBy2.md) | Use this parameter to filter the API's response based on different data dimensions. You can serialize filters in your query to receive more detailed breakdowns of your analytics. - If you do not set a value for `filterBy`, the API returns the full dataset for your project. - The API only accepts the `mediaId` and `mediaType` filters when you call `/data/metrics/play/total` or `/data/buckets/play-total/media-id`. These are the available breakdown dimensions: - `mediaId`: Returns analytics based on the unique identifiers of a video or a live stream. - `mediaType`: Returns analytics based on the type of content. Possible values: `video` and `live-stream`. - `continent`: Returns analytics based on the viewers' continent. The list of supported continents names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `EU`. Possible values are: `AS`, `AF`, `NA`, `SA`, `AN`, `EU`, `AZ`. - `country`: Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `FR`. - `deviceType`: Returns analytics based on the type of device used by the viewers. Response values can include: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. - `operatingSystem`: Returns analytics based on the operating system used by the viewers. Response values can include `windows`, `mac osx`, `android`, `ios`, `linux`. - `browser`: Returns analytics based on the browser used by the viewers. Response values can include `chrome`, `firefox`, `edge`, `opera`. - `tag`: Returns analytics for videos using this tag. This filter only accepts a single value and is case sensitive. Read more about tagging your videos [here](https://docs.api.video/vod/tags-metadata). | **currentPage** | **int32** | Choose the number of search results to return per page. Minimum value: 1 | [default to 1] **pageSize** | **int32** | Results per page. Allowed values 1-100, default is 25. | [default to 25] ### Return type -[**AnalyticsPlaysResponse**](AnalyticsPlaysResponse.md) +[**AnalyticsMetricsOverTimeResponse**](AnalyticsMetricsOverTimeResponse.md) [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) diff --git a/docs/AnalyticsAggregatedMetricsResponse.md b/docs/AnalyticsAggregatedMetricsResponse.md new file mode 100644 index 0000000..08be642 --- /dev/null +++ b/docs/AnalyticsAggregatedMetricsResponse.md @@ -0,0 +1,72 @@ +# AnalyticsAggregatedMetricsResponse + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Context** | [**AnalyticsAggregatedMetricsResponseContext**](AnalyticsAggregatedMetricsResponseContext.md) | | +**Data** | **float32** | | + +## Methods + +### NewAnalyticsAggregatedMetricsResponse + +`func NewAnalyticsAggregatedMetricsResponse(context AnalyticsAggregatedMetricsResponseContext, data float32, ) *AnalyticsAggregatedMetricsResponse` + +NewAnalyticsAggregatedMetricsResponse instantiates a new AnalyticsAggregatedMetricsResponse object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewAnalyticsAggregatedMetricsResponseWithDefaults + +`func NewAnalyticsAggregatedMetricsResponseWithDefaults() *AnalyticsAggregatedMetricsResponse` + +NewAnalyticsAggregatedMetricsResponseWithDefaults instantiates a new AnalyticsAggregatedMetricsResponse object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetContext + +`func (o *AnalyticsAggregatedMetricsResponse) GetContext() AnalyticsAggregatedMetricsResponseContext` + +GetContext returns the Context field if non-nil, zero value otherwise. + +### GetContextOk + +`func (o *AnalyticsAggregatedMetricsResponse) GetContextOk() (*AnalyticsAggregatedMetricsResponseContext, bool)` + +GetContextOk returns a tuple with the Context field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetContext + +`func (o *AnalyticsAggregatedMetricsResponse) SetContext(v AnalyticsAggregatedMetricsResponseContext)` + +SetContext sets Context field to given value. + + +### GetData + +`func (o *AnalyticsAggregatedMetricsResponse) GetData() float32` + +GetData returns the Data field if non-nil, zero value otherwise. + +### GetDataOk + +`func (o *AnalyticsAggregatedMetricsResponse) GetDataOk() (*float32, bool)` + +GetDataOk returns a tuple with the Data field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetData + +`func (o *AnalyticsAggregatedMetricsResponse) SetData(v float32)` + +SetData sets Data field to given value. + + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AnalyticsAggregatedMetricsResponseContext.md b/docs/AnalyticsAggregatedMetricsResponseContext.md new file mode 100644 index 0000000..60b1728 --- /dev/null +++ b/docs/AnalyticsAggregatedMetricsResponseContext.md @@ -0,0 +1,108 @@ +# AnalyticsAggregatedMetricsResponseContext + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Metric** | Pointer to **string** | Returns the metric you selected. | [optional] +**Aggregation** | Pointer to **string** | Returns the aggregation you selected. | [optional] +**Timeframe** | Pointer to [**AnalyticsAggregatedMetricsResponseContextTimeframe**](AnalyticsAggregatedMetricsResponseContextTimeframe.md) | | [optional] + +## Methods + +### NewAnalyticsAggregatedMetricsResponseContext + +`func NewAnalyticsAggregatedMetricsResponseContext() *AnalyticsAggregatedMetricsResponseContext` + +NewAnalyticsAggregatedMetricsResponseContext instantiates a new AnalyticsAggregatedMetricsResponseContext object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewAnalyticsAggregatedMetricsResponseContextWithDefaults + +`func NewAnalyticsAggregatedMetricsResponseContextWithDefaults() *AnalyticsAggregatedMetricsResponseContext` + +NewAnalyticsAggregatedMetricsResponseContextWithDefaults instantiates a new AnalyticsAggregatedMetricsResponseContext object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetMetric + +`func (o *AnalyticsAggregatedMetricsResponseContext) GetMetric() string` + +GetMetric returns the Metric field if non-nil, zero value otherwise. + +### GetMetricOk + +`func (o *AnalyticsAggregatedMetricsResponseContext) GetMetricOk() (*string, bool)` + +GetMetricOk returns a tuple with the Metric field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetMetric + +`func (o *AnalyticsAggregatedMetricsResponseContext) SetMetric(v string)` + +SetMetric sets Metric field to given value. + +### HasMetric + +`func (o *AnalyticsAggregatedMetricsResponseContext) HasMetric() bool` + +HasMetric returns a boolean if a field has been set. + +### GetAggregation + +`func (o *AnalyticsAggregatedMetricsResponseContext) GetAggregation() string` + +GetAggregation returns the Aggregation field if non-nil, zero value otherwise. + +### GetAggregationOk + +`func (o *AnalyticsAggregatedMetricsResponseContext) GetAggregationOk() (*string, bool)` + +GetAggregationOk returns a tuple with the Aggregation field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetAggregation + +`func (o *AnalyticsAggregatedMetricsResponseContext) SetAggregation(v string)` + +SetAggregation sets Aggregation field to given value. + +### HasAggregation + +`func (o *AnalyticsAggregatedMetricsResponseContext) HasAggregation() bool` + +HasAggregation returns a boolean if a field has been set. + +### GetTimeframe + +`func (o *AnalyticsAggregatedMetricsResponseContext) GetTimeframe() AnalyticsAggregatedMetricsResponseContextTimeframe` + +GetTimeframe returns the Timeframe field if non-nil, zero value otherwise. + +### GetTimeframeOk + +`func (o *AnalyticsAggregatedMetricsResponseContext) GetTimeframeOk() (*AnalyticsAggregatedMetricsResponseContextTimeframe, bool)` + +GetTimeframeOk returns a tuple with the Timeframe field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetTimeframe + +`func (o *AnalyticsAggregatedMetricsResponseContext) SetTimeframe(v AnalyticsAggregatedMetricsResponseContextTimeframe)` + +SetTimeframe sets Timeframe field to given value. + +### HasTimeframe + +`func (o *AnalyticsAggregatedMetricsResponseContext) HasTimeframe() bool` + +HasTimeframe returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AnalyticsAggregatedMetricsResponseContextTimeframe.md b/docs/AnalyticsAggregatedMetricsResponseContextTimeframe.md new file mode 100644 index 0000000..354c5e0 --- /dev/null +++ b/docs/AnalyticsAggregatedMetricsResponseContextTimeframe.md @@ -0,0 +1,82 @@ +# AnalyticsAggregatedMetricsResponseContextTimeframe + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**From** | Pointer to **string** | Returns the starting date-time of the period you want analytics for in ATOM date-time format. | [optional] +**To** | Pointer to **string** | Returns the starting date-time of the period you want analytics for in ATOM date-time format. | [optional] + +## Methods + +### NewAnalyticsAggregatedMetricsResponseContextTimeframe + +`func NewAnalyticsAggregatedMetricsResponseContextTimeframe() *AnalyticsAggregatedMetricsResponseContextTimeframe` + +NewAnalyticsAggregatedMetricsResponseContextTimeframe instantiates a new AnalyticsAggregatedMetricsResponseContextTimeframe object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewAnalyticsAggregatedMetricsResponseContextTimeframeWithDefaults + +`func NewAnalyticsAggregatedMetricsResponseContextTimeframeWithDefaults() *AnalyticsAggregatedMetricsResponseContextTimeframe` + +NewAnalyticsAggregatedMetricsResponseContextTimeframeWithDefaults instantiates a new AnalyticsAggregatedMetricsResponseContextTimeframe object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetFrom + +`func (o *AnalyticsAggregatedMetricsResponseContextTimeframe) GetFrom() string` + +GetFrom returns the From field if non-nil, zero value otherwise. + +### GetFromOk + +`func (o *AnalyticsAggregatedMetricsResponseContextTimeframe) GetFromOk() (*string, bool)` + +GetFromOk returns a tuple with the From field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetFrom + +`func (o *AnalyticsAggregatedMetricsResponseContextTimeframe) SetFrom(v string)` + +SetFrom sets From field to given value. + +### HasFrom + +`func (o *AnalyticsAggregatedMetricsResponseContextTimeframe) HasFrom() bool` + +HasFrom returns a boolean if a field has been set. + +### GetTo + +`func (o *AnalyticsAggregatedMetricsResponseContextTimeframe) GetTo() string` + +GetTo returns the To field if non-nil, zero value otherwise. + +### GetToOk + +`func (o *AnalyticsAggregatedMetricsResponseContextTimeframe) GetToOk() (*string, bool)` + +GetToOk returns a tuple with the To field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetTo + +`func (o *AnalyticsAggregatedMetricsResponseContextTimeframe) SetTo(v string)` + +SetTo sets To field to given value. + +### HasTo + +`func (o *AnalyticsAggregatedMetricsResponseContextTimeframe) HasTo() bool` + +HasTo returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AnalyticsMetricsBreakdownResponse.md b/docs/AnalyticsMetricsBreakdownResponse.md new file mode 100644 index 0000000..3968666 --- /dev/null +++ b/docs/AnalyticsMetricsBreakdownResponse.md @@ -0,0 +1,93 @@ +# AnalyticsMetricsBreakdownResponse + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Context** | [**AnalyticsMetricsBreakdownResponseContext**](AnalyticsMetricsBreakdownResponseContext.md) | | +**Data** | [**[]AnalyticsMetricsBreakdownResponseData**](AnalyticsMetricsBreakdownResponseData.md) | Returns an array of dimensions and their respective metrics. | +**Pagination** | [**Pagination**](Pagination.md) | | + +## Methods + +### NewAnalyticsMetricsBreakdownResponse + +`func NewAnalyticsMetricsBreakdownResponse(context AnalyticsMetricsBreakdownResponseContext, data []AnalyticsMetricsBreakdownResponseData, pagination Pagination, ) *AnalyticsMetricsBreakdownResponse` + +NewAnalyticsMetricsBreakdownResponse instantiates a new AnalyticsMetricsBreakdownResponse object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewAnalyticsMetricsBreakdownResponseWithDefaults + +`func NewAnalyticsMetricsBreakdownResponseWithDefaults() *AnalyticsMetricsBreakdownResponse` + +NewAnalyticsMetricsBreakdownResponseWithDefaults instantiates a new AnalyticsMetricsBreakdownResponse object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetContext + +`func (o *AnalyticsMetricsBreakdownResponse) GetContext() AnalyticsMetricsBreakdownResponseContext` + +GetContext returns the Context field if non-nil, zero value otherwise. + +### GetContextOk + +`func (o *AnalyticsMetricsBreakdownResponse) GetContextOk() (*AnalyticsMetricsBreakdownResponseContext, bool)` + +GetContextOk returns a tuple with the Context field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetContext + +`func (o *AnalyticsMetricsBreakdownResponse) SetContext(v AnalyticsMetricsBreakdownResponseContext)` + +SetContext sets Context field to given value. + + +### GetData + +`func (o *AnalyticsMetricsBreakdownResponse) GetData() []AnalyticsMetricsBreakdownResponseData` + +GetData returns the Data field if non-nil, zero value otherwise. + +### GetDataOk + +`func (o *AnalyticsMetricsBreakdownResponse) GetDataOk() (*[]AnalyticsMetricsBreakdownResponseData, bool)` + +GetDataOk returns a tuple with the Data field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetData + +`func (o *AnalyticsMetricsBreakdownResponse) SetData(v []AnalyticsMetricsBreakdownResponseData)` + +SetData sets Data field to given value. + + +### GetPagination + +`func (o *AnalyticsMetricsBreakdownResponse) GetPagination() Pagination` + +GetPagination returns the Pagination field if non-nil, zero value otherwise. + +### GetPaginationOk + +`func (o *AnalyticsMetricsBreakdownResponse) GetPaginationOk() (*Pagination, bool)` + +GetPaginationOk returns a tuple with the Pagination field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetPagination + +`func (o *AnalyticsMetricsBreakdownResponse) SetPagination(v Pagination)` + +SetPagination sets Pagination field to given value. + + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AnalyticsMetricsBreakdownResponseContext.md b/docs/AnalyticsMetricsBreakdownResponseContext.md new file mode 100644 index 0000000..20081f0 --- /dev/null +++ b/docs/AnalyticsMetricsBreakdownResponseContext.md @@ -0,0 +1,108 @@ +# AnalyticsMetricsBreakdownResponseContext + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Metric** | Pointer to **string** | Returns the metric you selected. | [optional] +**Breakdown** | Pointer to **string** | Returns the dimension you selected. | [optional] +**Timeframe** | Pointer to [**AnalyticsAggregatedMetricsResponseContextTimeframe**](AnalyticsAggregatedMetricsResponseContextTimeframe.md) | | [optional] + +## Methods + +### NewAnalyticsMetricsBreakdownResponseContext + +`func NewAnalyticsMetricsBreakdownResponseContext() *AnalyticsMetricsBreakdownResponseContext` + +NewAnalyticsMetricsBreakdownResponseContext instantiates a new AnalyticsMetricsBreakdownResponseContext object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewAnalyticsMetricsBreakdownResponseContextWithDefaults + +`func NewAnalyticsMetricsBreakdownResponseContextWithDefaults() *AnalyticsMetricsBreakdownResponseContext` + +NewAnalyticsMetricsBreakdownResponseContextWithDefaults instantiates a new AnalyticsMetricsBreakdownResponseContext object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetMetric + +`func (o *AnalyticsMetricsBreakdownResponseContext) GetMetric() string` + +GetMetric returns the Metric field if non-nil, zero value otherwise. + +### GetMetricOk + +`func (o *AnalyticsMetricsBreakdownResponseContext) GetMetricOk() (*string, bool)` + +GetMetricOk returns a tuple with the Metric field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetMetric + +`func (o *AnalyticsMetricsBreakdownResponseContext) SetMetric(v string)` + +SetMetric sets Metric field to given value. + +### HasMetric + +`func (o *AnalyticsMetricsBreakdownResponseContext) HasMetric() bool` + +HasMetric returns a boolean if a field has been set. + +### GetBreakdown + +`func (o *AnalyticsMetricsBreakdownResponseContext) GetBreakdown() string` + +GetBreakdown returns the Breakdown field if non-nil, zero value otherwise. + +### GetBreakdownOk + +`func (o *AnalyticsMetricsBreakdownResponseContext) GetBreakdownOk() (*string, bool)` + +GetBreakdownOk returns a tuple with the Breakdown field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetBreakdown + +`func (o *AnalyticsMetricsBreakdownResponseContext) SetBreakdown(v string)` + +SetBreakdown sets Breakdown field to given value. + +### HasBreakdown + +`func (o *AnalyticsMetricsBreakdownResponseContext) HasBreakdown() bool` + +HasBreakdown returns a boolean if a field has been set. + +### GetTimeframe + +`func (o *AnalyticsMetricsBreakdownResponseContext) GetTimeframe() AnalyticsAggregatedMetricsResponseContextTimeframe` + +GetTimeframe returns the Timeframe field if non-nil, zero value otherwise. + +### GetTimeframeOk + +`func (o *AnalyticsMetricsBreakdownResponseContext) GetTimeframeOk() (*AnalyticsAggregatedMetricsResponseContextTimeframe, bool)` + +GetTimeframeOk returns a tuple with the Timeframe field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetTimeframe + +`func (o *AnalyticsMetricsBreakdownResponseContext) SetTimeframe(v AnalyticsAggregatedMetricsResponseContextTimeframe)` + +SetTimeframe sets Timeframe field to given value. + +### HasTimeframe + +`func (o *AnalyticsMetricsBreakdownResponseContext) HasTimeframe() bool` + +HasTimeframe returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AnalyticsMetricsBreakdownResponseData.md b/docs/AnalyticsMetricsBreakdownResponseData.md new file mode 100644 index 0000000..8ebeac0 --- /dev/null +++ b/docs/AnalyticsMetricsBreakdownResponseData.md @@ -0,0 +1,82 @@ +# AnalyticsMetricsBreakdownResponseData + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**DimensionValue** | Pointer to **string** | Returns a specific value for the dimension you selected, based on the data. For example if you select `continent` as a dimension, then `dimensionValue` returns values like `EU` or \"AZ\". | [optional] +**MetricValue** | Pointer to **float32** | Returns the data for a specific dimension value. | [optional] + +## Methods + +### NewAnalyticsMetricsBreakdownResponseData + +`func NewAnalyticsMetricsBreakdownResponseData() *AnalyticsMetricsBreakdownResponseData` + +NewAnalyticsMetricsBreakdownResponseData instantiates a new AnalyticsMetricsBreakdownResponseData object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewAnalyticsMetricsBreakdownResponseDataWithDefaults + +`func NewAnalyticsMetricsBreakdownResponseDataWithDefaults() *AnalyticsMetricsBreakdownResponseData` + +NewAnalyticsMetricsBreakdownResponseDataWithDefaults instantiates a new AnalyticsMetricsBreakdownResponseData object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetDimensionValue + +`func (o *AnalyticsMetricsBreakdownResponseData) GetDimensionValue() string` + +GetDimensionValue returns the DimensionValue field if non-nil, zero value otherwise. + +### GetDimensionValueOk + +`func (o *AnalyticsMetricsBreakdownResponseData) GetDimensionValueOk() (*string, bool)` + +GetDimensionValueOk returns a tuple with the DimensionValue field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetDimensionValue + +`func (o *AnalyticsMetricsBreakdownResponseData) SetDimensionValue(v string)` + +SetDimensionValue sets DimensionValue field to given value. + +### HasDimensionValue + +`func (o *AnalyticsMetricsBreakdownResponseData) HasDimensionValue() bool` + +HasDimensionValue returns a boolean if a field has been set. + +### GetMetricValue + +`func (o *AnalyticsMetricsBreakdownResponseData) GetMetricValue() float32` + +GetMetricValue returns the MetricValue field if non-nil, zero value otherwise. + +### GetMetricValueOk + +`func (o *AnalyticsMetricsBreakdownResponseData) GetMetricValueOk() (*float32, bool)` + +GetMetricValueOk returns a tuple with the MetricValue field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetMetricValue + +`func (o *AnalyticsMetricsBreakdownResponseData) SetMetricValue(v float32)` + +SetMetricValue sets MetricValue field to given value. + +### HasMetricValue + +`func (o *AnalyticsMetricsBreakdownResponseData) HasMetricValue() bool` + +HasMetricValue returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AnalyticsMetricsOverTimeResponse.md b/docs/AnalyticsMetricsOverTimeResponse.md new file mode 100644 index 0000000..68d18ae --- /dev/null +++ b/docs/AnalyticsMetricsOverTimeResponse.md @@ -0,0 +1,93 @@ +# AnalyticsMetricsOverTimeResponse + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Context** | [**AnalyticsMetricsOverTimeResponseContext**](AnalyticsMetricsOverTimeResponseContext.md) | | +**Data** | [**[]AnalyticsMetricsOverTimeResponseData**](AnalyticsMetricsOverTimeResponseData.md) | Returns an array of metrics and the timestamps . | +**Pagination** | [**Pagination**](Pagination.md) | | + +## Methods + +### NewAnalyticsMetricsOverTimeResponse + +`func NewAnalyticsMetricsOverTimeResponse(context AnalyticsMetricsOverTimeResponseContext, data []AnalyticsMetricsOverTimeResponseData, pagination Pagination, ) *AnalyticsMetricsOverTimeResponse` + +NewAnalyticsMetricsOverTimeResponse instantiates a new AnalyticsMetricsOverTimeResponse object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewAnalyticsMetricsOverTimeResponseWithDefaults + +`func NewAnalyticsMetricsOverTimeResponseWithDefaults() *AnalyticsMetricsOverTimeResponse` + +NewAnalyticsMetricsOverTimeResponseWithDefaults instantiates a new AnalyticsMetricsOverTimeResponse object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetContext + +`func (o *AnalyticsMetricsOverTimeResponse) GetContext() AnalyticsMetricsOverTimeResponseContext` + +GetContext returns the Context field if non-nil, zero value otherwise. + +### GetContextOk + +`func (o *AnalyticsMetricsOverTimeResponse) GetContextOk() (*AnalyticsMetricsOverTimeResponseContext, bool)` + +GetContextOk returns a tuple with the Context field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetContext + +`func (o *AnalyticsMetricsOverTimeResponse) SetContext(v AnalyticsMetricsOverTimeResponseContext)` + +SetContext sets Context field to given value. + + +### GetData + +`func (o *AnalyticsMetricsOverTimeResponse) GetData() []AnalyticsMetricsOverTimeResponseData` + +GetData returns the Data field if non-nil, zero value otherwise. + +### GetDataOk + +`func (o *AnalyticsMetricsOverTimeResponse) GetDataOk() (*[]AnalyticsMetricsOverTimeResponseData, bool)` + +GetDataOk returns a tuple with the Data field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetData + +`func (o *AnalyticsMetricsOverTimeResponse) SetData(v []AnalyticsMetricsOverTimeResponseData)` + +SetData sets Data field to given value. + + +### GetPagination + +`func (o *AnalyticsMetricsOverTimeResponse) GetPagination() Pagination` + +GetPagination returns the Pagination field if non-nil, zero value otherwise. + +### GetPaginationOk + +`func (o *AnalyticsMetricsOverTimeResponse) GetPaginationOk() (*Pagination, bool)` + +GetPaginationOk returns a tuple with the Pagination field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetPagination + +`func (o *AnalyticsMetricsOverTimeResponse) SetPagination(v Pagination)` + +SetPagination sets Pagination field to given value. + + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AnalyticsMetricsOverTimeResponseContext.md b/docs/AnalyticsMetricsOverTimeResponseContext.md new file mode 100644 index 0000000..5cd5ddf --- /dev/null +++ b/docs/AnalyticsMetricsOverTimeResponseContext.md @@ -0,0 +1,108 @@ +# AnalyticsMetricsOverTimeResponseContext + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Metric** | Pointer to **string** | Returns the metric you selected. | [optional] +**Interval** | Pointer to **string** | Returns the interval you selected. | [optional] +**Timeframe** | Pointer to [**AnalyticsAggregatedMetricsResponseContextTimeframe**](AnalyticsAggregatedMetricsResponseContextTimeframe.md) | | [optional] + +## Methods + +### NewAnalyticsMetricsOverTimeResponseContext + +`func NewAnalyticsMetricsOverTimeResponseContext() *AnalyticsMetricsOverTimeResponseContext` + +NewAnalyticsMetricsOverTimeResponseContext instantiates a new AnalyticsMetricsOverTimeResponseContext object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewAnalyticsMetricsOverTimeResponseContextWithDefaults + +`func NewAnalyticsMetricsOverTimeResponseContextWithDefaults() *AnalyticsMetricsOverTimeResponseContext` + +NewAnalyticsMetricsOverTimeResponseContextWithDefaults instantiates a new AnalyticsMetricsOverTimeResponseContext object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetMetric + +`func (o *AnalyticsMetricsOverTimeResponseContext) GetMetric() string` + +GetMetric returns the Metric field if non-nil, zero value otherwise. + +### GetMetricOk + +`func (o *AnalyticsMetricsOverTimeResponseContext) GetMetricOk() (*string, bool)` + +GetMetricOk returns a tuple with the Metric field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetMetric + +`func (o *AnalyticsMetricsOverTimeResponseContext) SetMetric(v string)` + +SetMetric sets Metric field to given value. + +### HasMetric + +`func (o *AnalyticsMetricsOverTimeResponseContext) HasMetric() bool` + +HasMetric returns a boolean if a field has been set. + +### GetInterval + +`func (o *AnalyticsMetricsOverTimeResponseContext) GetInterval() string` + +GetInterval returns the Interval field if non-nil, zero value otherwise. + +### GetIntervalOk + +`func (o *AnalyticsMetricsOverTimeResponseContext) GetIntervalOk() (*string, bool)` + +GetIntervalOk returns a tuple with the Interval field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetInterval + +`func (o *AnalyticsMetricsOverTimeResponseContext) SetInterval(v string)` + +SetInterval sets Interval field to given value. + +### HasInterval + +`func (o *AnalyticsMetricsOverTimeResponseContext) HasInterval() bool` + +HasInterval returns a boolean if a field has been set. + +### GetTimeframe + +`func (o *AnalyticsMetricsOverTimeResponseContext) GetTimeframe() AnalyticsAggregatedMetricsResponseContextTimeframe` + +GetTimeframe returns the Timeframe field if non-nil, zero value otherwise. + +### GetTimeframeOk + +`func (o *AnalyticsMetricsOverTimeResponseContext) GetTimeframeOk() (*AnalyticsAggregatedMetricsResponseContextTimeframe, bool)` + +GetTimeframeOk returns a tuple with the Timeframe field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetTimeframe + +`func (o *AnalyticsMetricsOverTimeResponseContext) SetTimeframe(v AnalyticsAggregatedMetricsResponseContextTimeframe)` + +SetTimeframe sets Timeframe field to given value. + +### HasTimeframe + +`func (o *AnalyticsMetricsOverTimeResponseContext) HasTimeframe() bool` + +HasTimeframe returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/AnalyticsMetricsOverTimeResponseData.md b/docs/AnalyticsMetricsOverTimeResponseData.md new file mode 100644 index 0000000..1c58eb3 --- /dev/null +++ b/docs/AnalyticsMetricsOverTimeResponseData.md @@ -0,0 +1,82 @@ +# AnalyticsMetricsOverTimeResponseData + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**EmittedAt** | Pointer to **string** | Returns the timestamp of the event that belongs to a specific metric in ATOM date-time format. For example, if you set `play` with an `hour` interval in your request, then `emittedAt` returns the hourly timestamps of every play event within the timeframe you defined. | [optional] +**MetricValue** | Pointer to **float32** | Returns the data for a specific metric value. | [optional] + +## Methods + +### NewAnalyticsMetricsOverTimeResponseData + +`func NewAnalyticsMetricsOverTimeResponseData() *AnalyticsMetricsOverTimeResponseData` + +NewAnalyticsMetricsOverTimeResponseData instantiates a new AnalyticsMetricsOverTimeResponseData object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewAnalyticsMetricsOverTimeResponseDataWithDefaults + +`func NewAnalyticsMetricsOverTimeResponseDataWithDefaults() *AnalyticsMetricsOverTimeResponseData` + +NewAnalyticsMetricsOverTimeResponseDataWithDefaults instantiates a new AnalyticsMetricsOverTimeResponseData object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetEmittedAt + +`func (o *AnalyticsMetricsOverTimeResponseData) GetEmittedAt() string` + +GetEmittedAt returns the EmittedAt field if non-nil, zero value otherwise. + +### GetEmittedAtOk + +`func (o *AnalyticsMetricsOverTimeResponseData) GetEmittedAtOk() (*string, bool)` + +GetEmittedAtOk returns a tuple with the EmittedAt field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetEmittedAt + +`func (o *AnalyticsMetricsOverTimeResponseData) SetEmittedAt(v string)` + +SetEmittedAt sets EmittedAt field to given value. + +### HasEmittedAt + +`func (o *AnalyticsMetricsOverTimeResponseData) HasEmittedAt() bool` + +HasEmittedAt returns a boolean if a field has been set. + +### GetMetricValue + +`func (o *AnalyticsMetricsOverTimeResponseData) GetMetricValue() float32` + +GetMetricValue returns the MetricValue field if non-nil, zero value otherwise. + +### GetMetricValueOk + +`func (o *AnalyticsMetricsOverTimeResponseData) GetMetricValueOk() (*float32, bool)` + +GetMetricValueOk returns a tuple with the MetricValue field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetMetricValue + +`func (o *AnalyticsMetricsOverTimeResponseData) SetMetricValue(v float32)` + +SetMetricValue sets MetricValue field to given value. + +### HasMetricValue + +`func (o *AnalyticsMetricsOverTimeResponseData) HasMetricValue() bool` + +HasMetricValue returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/FilterBy.md b/docs/FilterBy.md new file mode 100644 index 0000000..8620ff6 --- /dev/null +++ b/docs/FilterBy.md @@ -0,0 +1,238 @@ +# FilterBy + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**MediaId** | Pointer to **[]string** | Returns analytics based on the unique identifiers of a video or a live stream. | [optional] +**MediaType** | Pointer to **string** | | [optional] +**Continent** | Pointer to **[]string** | Returns analytics based on the viewers' continent. The list of supported continents names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `EU`. | [optional] +**Country** | Pointer to **[]string** | Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `FR`. | [optional] +**DeviceType** | Pointer to **[]string** | Returns analytics based on the type of device used by the viewers. Response values can include: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. | [optional] +**OperatingSystem** | Pointer to **[]string** | Returns analytics based on the operating system used by the viewers. Response values can include `windows`, `mac osx`, `android`, `ios`, `linux`. | [optional] +**Browser** | Pointer to **[]string** | Returns analytics based on the browser used by the viewers. Response values can include `chrome`, `firefox`, `edge`, `opera`. | [optional] +**Tag** | Pointer to **string** | Returns analytics for videos using this tag. This filter only accepts a single value and is case sensitive. Read more about tagging your videos [here](https://docs.api.video/vod/tags-metadata). | [optional] + +## Methods + +### NewFilterBy + +`func NewFilterBy() *FilterBy` + +NewFilterBy instantiates a new FilterBy object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewFilterByWithDefaults + +`func NewFilterByWithDefaults() *FilterBy` + +NewFilterByWithDefaults instantiates a new FilterBy object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetMediaId + +`func (o *FilterBy) GetMediaId() []string` + +GetMediaId returns the MediaId field if non-nil, zero value otherwise. + +### GetMediaIdOk + +`func (o *FilterBy) GetMediaIdOk() (*[]string, bool)` + +GetMediaIdOk returns a tuple with the MediaId field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetMediaId + +`func (o *FilterBy) SetMediaId(v []string)` + +SetMediaId sets MediaId field to given value. + +### HasMediaId + +`func (o *FilterBy) HasMediaId() bool` + +HasMediaId returns a boolean if a field has been set. + +### GetMediaType + +`func (o *FilterBy) GetMediaType() string` + +GetMediaType returns the MediaType field if non-nil, zero value otherwise. + +### GetMediaTypeOk + +`func (o *FilterBy) GetMediaTypeOk() (*string, bool)` + +GetMediaTypeOk returns a tuple with the MediaType field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetMediaType + +`func (o *FilterBy) SetMediaType(v string)` + +SetMediaType sets MediaType field to given value. + +### HasMediaType + +`func (o *FilterBy) HasMediaType() bool` + +HasMediaType returns a boolean if a field has been set. + +### GetContinent + +`func (o *FilterBy) GetContinent() []string` + +GetContinent returns the Continent field if non-nil, zero value otherwise. + +### GetContinentOk + +`func (o *FilterBy) GetContinentOk() (*[]string, bool)` + +GetContinentOk returns a tuple with the Continent field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetContinent + +`func (o *FilterBy) SetContinent(v []string)` + +SetContinent sets Continent field to given value. + +### HasContinent + +`func (o *FilterBy) HasContinent() bool` + +HasContinent returns a boolean if a field has been set. + +### GetCountry + +`func (o *FilterBy) GetCountry() []string` + +GetCountry returns the Country field if non-nil, zero value otherwise. + +### GetCountryOk + +`func (o *FilterBy) GetCountryOk() (*[]string, bool)` + +GetCountryOk returns a tuple with the Country field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetCountry + +`func (o *FilterBy) SetCountry(v []string)` + +SetCountry sets Country field to given value. + +### HasCountry + +`func (o *FilterBy) HasCountry() bool` + +HasCountry returns a boolean if a field has been set. + +### GetDeviceType + +`func (o *FilterBy) GetDeviceType() []string` + +GetDeviceType returns the DeviceType field if non-nil, zero value otherwise. + +### GetDeviceTypeOk + +`func (o *FilterBy) GetDeviceTypeOk() (*[]string, bool)` + +GetDeviceTypeOk returns a tuple with the DeviceType field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetDeviceType + +`func (o *FilterBy) SetDeviceType(v []string)` + +SetDeviceType sets DeviceType field to given value. + +### HasDeviceType + +`func (o *FilterBy) HasDeviceType() bool` + +HasDeviceType returns a boolean if a field has been set. + +### GetOperatingSystem + +`func (o *FilterBy) GetOperatingSystem() []string` + +GetOperatingSystem returns the OperatingSystem field if non-nil, zero value otherwise. + +### GetOperatingSystemOk + +`func (o *FilterBy) GetOperatingSystemOk() (*[]string, bool)` + +GetOperatingSystemOk returns a tuple with the OperatingSystem field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetOperatingSystem + +`func (o *FilterBy) SetOperatingSystem(v []string)` + +SetOperatingSystem sets OperatingSystem field to given value. + +### HasOperatingSystem + +`func (o *FilterBy) HasOperatingSystem() bool` + +HasOperatingSystem returns a boolean if a field has been set. + +### GetBrowser + +`func (o *FilterBy) GetBrowser() []string` + +GetBrowser returns the Browser field if non-nil, zero value otherwise. + +### GetBrowserOk + +`func (o *FilterBy) GetBrowserOk() (*[]string, bool)` + +GetBrowserOk returns a tuple with the Browser field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetBrowser + +`func (o *FilterBy) SetBrowser(v []string)` + +SetBrowser sets Browser field to given value. + +### HasBrowser + +`func (o *FilterBy) HasBrowser() bool` + +HasBrowser returns a boolean if a field has been set. + +### GetTag + +`func (o *FilterBy) GetTag() string` + +GetTag returns the Tag field if non-nil, zero value otherwise. + +### GetTagOk + +`func (o *FilterBy) GetTagOk() (*string, bool)` + +GetTagOk returns a tuple with the Tag field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetTag + +`func (o *FilterBy) SetTag(v string)` + +SetTag sets Tag field to given value. + +### HasTag + +`func (o *FilterBy) HasTag() bool` + +HasTag returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/FilterBy1.md b/docs/FilterBy1.md new file mode 100644 index 0000000..7a96d6c --- /dev/null +++ b/docs/FilterBy1.md @@ -0,0 +1,238 @@ +# FilterBy1 + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**MediaId** | Pointer to **[]string** | Returns analytics based on the unique identifiers of a video or a live stream. | [optional] +**MediaType** | Pointer to **string** | | [optional] +**Continent** | Pointer to **[]string** | Returns analytics based on the viewers' continent. The list of supported continents names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `EU`. | [optional] +**Country** | Pointer to **[]string** | Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `FR`. | [optional] +**DeviceType** | Pointer to **[]string** | Returns analytics based on the type of device used by the viewers. Response values can include: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. | [optional] +**OperatingSystem** | Pointer to **[]string** | Returns analytics based on the operating system used by the viewers. Response values can include `windows`, `mac osx`, `android`, `ios`, `linux`. | [optional] +**Browser** | Pointer to **[]string** | Returns analytics based on the browser used by the viewers. Response values can include `chrome`, `firefox`, `edge`, `opera`. | [optional] +**Tag** | Pointer to **string** | Returns analytics for videos using this tag. This filter only accepts a single value and is case sensitive. Read more about tagging your videos [here](https://docs.api.video/vod/tags-metadata). | [optional] + +## Methods + +### NewFilterBy1 + +`func NewFilterBy1() *FilterBy1` + +NewFilterBy1 instantiates a new FilterBy1 object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewFilterBy1WithDefaults + +`func NewFilterBy1WithDefaults() *FilterBy1` + +NewFilterBy1WithDefaults instantiates a new FilterBy1 object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetMediaId + +`func (o *FilterBy1) GetMediaId() []string` + +GetMediaId returns the MediaId field if non-nil, zero value otherwise. + +### GetMediaIdOk + +`func (o *FilterBy1) GetMediaIdOk() (*[]string, bool)` + +GetMediaIdOk returns a tuple with the MediaId field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetMediaId + +`func (o *FilterBy1) SetMediaId(v []string)` + +SetMediaId sets MediaId field to given value. + +### HasMediaId + +`func (o *FilterBy1) HasMediaId() bool` + +HasMediaId returns a boolean if a field has been set. + +### GetMediaType + +`func (o *FilterBy1) GetMediaType() string` + +GetMediaType returns the MediaType field if non-nil, zero value otherwise. + +### GetMediaTypeOk + +`func (o *FilterBy1) GetMediaTypeOk() (*string, bool)` + +GetMediaTypeOk returns a tuple with the MediaType field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetMediaType + +`func (o *FilterBy1) SetMediaType(v string)` + +SetMediaType sets MediaType field to given value. + +### HasMediaType + +`func (o *FilterBy1) HasMediaType() bool` + +HasMediaType returns a boolean if a field has been set. + +### GetContinent + +`func (o *FilterBy1) GetContinent() []string` + +GetContinent returns the Continent field if non-nil, zero value otherwise. + +### GetContinentOk + +`func (o *FilterBy1) GetContinentOk() (*[]string, bool)` + +GetContinentOk returns a tuple with the Continent field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetContinent + +`func (o *FilterBy1) SetContinent(v []string)` + +SetContinent sets Continent field to given value. + +### HasContinent + +`func (o *FilterBy1) HasContinent() bool` + +HasContinent returns a boolean if a field has been set. + +### GetCountry + +`func (o *FilterBy1) GetCountry() []string` + +GetCountry returns the Country field if non-nil, zero value otherwise. + +### GetCountryOk + +`func (o *FilterBy1) GetCountryOk() (*[]string, bool)` + +GetCountryOk returns a tuple with the Country field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetCountry + +`func (o *FilterBy1) SetCountry(v []string)` + +SetCountry sets Country field to given value. + +### HasCountry + +`func (o *FilterBy1) HasCountry() bool` + +HasCountry returns a boolean if a field has been set. + +### GetDeviceType + +`func (o *FilterBy1) GetDeviceType() []string` + +GetDeviceType returns the DeviceType field if non-nil, zero value otherwise. + +### GetDeviceTypeOk + +`func (o *FilterBy1) GetDeviceTypeOk() (*[]string, bool)` + +GetDeviceTypeOk returns a tuple with the DeviceType field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetDeviceType + +`func (o *FilterBy1) SetDeviceType(v []string)` + +SetDeviceType sets DeviceType field to given value. + +### HasDeviceType + +`func (o *FilterBy1) HasDeviceType() bool` + +HasDeviceType returns a boolean if a field has been set. + +### GetOperatingSystem + +`func (o *FilterBy1) GetOperatingSystem() []string` + +GetOperatingSystem returns the OperatingSystem field if non-nil, zero value otherwise. + +### GetOperatingSystemOk + +`func (o *FilterBy1) GetOperatingSystemOk() (*[]string, bool)` + +GetOperatingSystemOk returns a tuple with the OperatingSystem field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetOperatingSystem + +`func (o *FilterBy1) SetOperatingSystem(v []string)` + +SetOperatingSystem sets OperatingSystem field to given value. + +### HasOperatingSystem + +`func (o *FilterBy1) HasOperatingSystem() bool` + +HasOperatingSystem returns a boolean if a field has been set. + +### GetBrowser + +`func (o *FilterBy1) GetBrowser() []string` + +GetBrowser returns the Browser field if non-nil, zero value otherwise. + +### GetBrowserOk + +`func (o *FilterBy1) GetBrowserOk() (*[]string, bool)` + +GetBrowserOk returns a tuple with the Browser field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetBrowser + +`func (o *FilterBy1) SetBrowser(v []string)` + +SetBrowser sets Browser field to given value. + +### HasBrowser + +`func (o *FilterBy1) HasBrowser() bool` + +HasBrowser returns a boolean if a field has been set. + +### GetTag + +`func (o *FilterBy1) GetTag() string` + +GetTag returns the Tag field if non-nil, zero value otherwise. + +### GetTagOk + +`func (o *FilterBy1) GetTagOk() (*string, bool)` + +GetTagOk returns a tuple with the Tag field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetTag + +`func (o *FilterBy1) SetTag(v string)` + +SetTag sets Tag field to given value. + +### HasTag + +`func (o *FilterBy1) HasTag() bool` + +HasTag returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/FilterBy2.md b/docs/FilterBy2.md new file mode 100644 index 0000000..9b367fc --- /dev/null +++ b/docs/FilterBy2.md @@ -0,0 +1,238 @@ +# FilterBy2 + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**MediaId** | Pointer to **[]string** | Returns analytics based on the unique identifiers of a video or a live stream. | [optional] +**MediaType** | Pointer to **string** | | [optional] +**Continent** | Pointer to **[]string** | Returns analytics based on the viewers' continent. The list of supported continents names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `EU`. | [optional] +**Country** | Pointer to **[]string** | Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `FR`. | [optional] +**DeviceType** | Pointer to **[]string** | Returns analytics based on the type of device used by the viewers. Response values can include: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. | [optional] +**OperatingSystem** | Pointer to **[]string** | Returns analytics based on the operating system used by the viewers. Response values can include `windows`, `mac osx`, `android`, `ios`, `linux`. | [optional] +**Browser** | Pointer to **[]string** | Returns analytics based on the browser used by the viewers. Response values can include `chrome`, `firefox`, `edge`, `opera`. | [optional] +**Tag** | Pointer to **string** | Returns analytics for videos using this tag. This filter only accepts a single value and is case sensitive. Read more about tagging your videos [here](https://docs.api.video/vod/tags-metadata). | [optional] + +## Methods + +### NewFilterBy2 + +`func NewFilterBy2() *FilterBy2` + +NewFilterBy2 instantiates a new FilterBy2 object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewFilterBy2WithDefaults + +`func NewFilterBy2WithDefaults() *FilterBy2` + +NewFilterBy2WithDefaults instantiates a new FilterBy2 object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetMediaId + +`func (o *FilterBy2) GetMediaId() []string` + +GetMediaId returns the MediaId field if non-nil, zero value otherwise. + +### GetMediaIdOk + +`func (o *FilterBy2) GetMediaIdOk() (*[]string, bool)` + +GetMediaIdOk returns a tuple with the MediaId field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetMediaId + +`func (o *FilterBy2) SetMediaId(v []string)` + +SetMediaId sets MediaId field to given value. + +### HasMediaId + +`func (o *FilterBy2) HasMediaId() bool` + +HasMediaId returns a boolean if a field has been set. + +### GetMediaType + +`func (o *FilterBy2) GetMediaType() string` + +GetMediaType returns the MediaType field if non-nil, zero value otherwise. + +### GetMediaTypeOk + +`func (o *FilterBy2) GetMediaTypeOk() (*string, bool)` + +GetMediaTypeOk returns a tuple with the MediaType field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetMediaType + +`func (o *FilterBy2) SetMediaType(v string)` + +SetMediaType sets MediaType field to given value. + +### HasMediaType + +`func (o *FilterBy2) HasMediaType() bool` + +HasMediaType returns a boolean if a field has been set. + +### GetContinent + +`func (o *FilterBy2) GetContinent() []string` + +GetContinent returns the Continent field if non-nil, zero value otherwise. + +### GetContinentOk + +`func (o *FilterBy2) GetContinentOk() (*[]string, bool)` + +GetContinentOk returns a tuple with the Continent field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetContinent + +`func (o *FilterBy2) SetContinent(v []string)` + +SetContinent sets Continent field to given value. + +### HasContinent + +`func (o *FilterBy2) HasContinent() bool` + +HasContinent returns a boolean if a field has been set. + +### GetCountry + +`func (o *FilterBy2) GetCountry() []string` + +GetCountry returns the Country field if non-nil, zero value otherwise. + +### GetCountryOk + +`func (o *FilterBy2) GetCountryOk() (*[]string, bool)` + +GetCountryOk returns a tuple with the Country field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetCountry + +`func (o *FilterBy2) SetCountry(v []string)` + +SetCountry sets Country field to given value. + +### HasCountry + +`func (o *FilterBy2) HasCountry() bool` + +HasCountry returns a boolean if a field has been set. + +### GetDeviceType + +`func (o *FilterBy2) GetDeviceType() []string` + +GetDeviceType returns the DeviceType field if non-nil, zero value otherwise. + +### GetDeviceTypeOk + +`func (o *FilterBy2) GetDeviceTypeOk() (*[]string, bool)` + +GetDeviceTypeOk returns a tuple with the DeviceType field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetDeviceType + +`func (o *FilterBy2) SetDeviceType(v []string)` + +SetDeviceType sets DeviceType field to given value. + +### HasDeviceType + +`func (o *FilterBy2) HasDeviceType() bool` + +HasDeviceType returns a boolean if a field has been set. + +### GetOperatingSystem + +`func (o *FilterBy2) GetOperatingSystem() []string` + +GetOperatingSystem returns the OperatingSystem field if non-nil, zero value otherwise. + +### GetOperatingSystemOk + +`func (o *FilterBy2) GetOperatingSystemOk() (*[]string, bool)` + +GetOperatingSystemOk returns a tuple with the OperatingSystem field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetOperatingSystem + +`func (o *FilterBy2) SetOperatingSystem(v []string)` + +SetOperatingSystem sets OperatingSystem field to given value. + +### HasOperatingSystem + +`func (o *FilterBy2) HasOperatingSystem() bool` + +HasOperatingSystem returns a boolean if a field has been set. + +### GetBrowser + +`func (o *FilterBy2) GetBrowser() []string` + +GetBrowser returns the Browser field if non-nil, zero value otherwise. + +### GetBrowserOk + +`func (o *FilterBy2) GetBrowserOk() (*[]string, bool)` + +GetBrowserOk returns a tuple with the Browser field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetBrowser + +`func (o *FilterBy2) SetBrowser(v []string)` + +SetBrowser sets Browser field to given value. + +### HasBrowser + +`func (o *FilterBy2) HasBrowser() bool` + +HasBrowser returns a boolean if a field has been set. + +### GetTag + +`func (o *FilterBy2) GetTag() string` + +GetTag returns the Tag field if non-nil, zero value otherwise. + +### GetTagOk + +`func (o *FilterBy2) GetTagOk() (*string, bool)` + +GetTagOk returns a tuple with the Tag field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetTag + +`func (o *FilterBy2) SetTag(v string)` + +SetTag sets Tag field to given value. + +### HasTag + +`func (o *FilterBy2) HasTag() bool` + +HasTag returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/LiveStream.md b/docs/LiveStream.md index 42d5046..71af06d 100644 --- a/docs/LiveStream.md +++ b/docs/LiveStream.md @@ -7,11 +7,11 @@ Name | Type | Description | Notes **LiveStreamId** | **string** | The unique identifier for the live stream. Live stream IDs begin with \"li.\" | **Name** | Pointer to **string** | The name of your live stream. | [optional] **StreamKey** | Pointer to **string** | The unique, private stream key that you use to begin streaming. | [optional] -**Public** | Pointer to **bool** | Whether your video can be viewed by everyone, or requires authentication to see it. A setting of false will require a unique token for each view. Learn more about the Private Video feature [here](https://docs.api.video/delivery-analytics/video-privacy-access-management). | [optional] +**Public** | Pointer to **bool** | Whether your video can be viewed by everyone, or requires authentication to see it. A setting of false will require a unique token for each view. Learn more about the Private Video feature [here](https://docs.api.video/delivery/video-privacy-access-management). | [optional] **Assets** | Pointer to [**LiveStreamAssets**](LiveStreamAssets.md) | | [optional] **PlayerId** | Pointer to **string** | The unique identifier for the player. | [optional] **Broadcasting** | Pointer to **bool** | Whether or not you are broadcasting the live video you recorded for others to see. True means you are broadcasting to viewers, false means you are not. | [optional] -**Restreams** | [**[]RestreamsResponseObject**](RestreamsResponseObject.md) | Returns the list of RTMP restream destinations. | +**Restreams** | [**[]RestreamsResponseObject**](RestreamsResponseObject.md) | Returns the list of restream destinations. | **CreatedAt** | Pointer to **string** | When the player was created, presented in ISO-8601 format. | [optional] **UpdatedAt** | Pointer to **string** | When the player was last updated, presented in ISO-8601 format. | [optional] diff --git a/docs/LiveStreamCreationPayload.md b/docs/LiveStreamCreationPayload.md index f396adb..0fe0269 100644 --- a/docs/LiveStreamCreationPayload.md +++ b/docs/LiveStreamCreationPayload.md @@ -5,9 +5,9 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **Name** | **string** | Add a name for your live stream here. | -**Public** | Pointer to **bool** | Whether your video can be viewed by everyone, or requires authentication to see it. A setting of false will require a unique token for each view. Learn more about the Private Video feature [here](https://docs.api.video/delivery-analytics/video-privacy-access-management). | [optional] +**Public** | Pointer to **bool** | Whether your video can be viewed by everyone, or requires authentication to see it. A setting of false will require a unique token for each view. Learn more about the Private Video feature [here](https://docs.api.video/delivery/video-privacy-access-management). | [optional] **PlayerId** | Pointer to **string** | The unique identifier for the player. | [optional] -**Restreams** | Pointer to [**[]RestreamsRequestObject**](RestreamsRequestObject.md) | Use this parameter to add, edit, or remove RTMP services where you want to restream a live stream. The list can only contain up to 5 destinations. | [optional] +**Restreams** | Pointer to [**[]RestreamsRequestObject**](RestreamsRequestObject.md) | Use this parameter to add, edit, or remove `RTMPS` or `RTMP` services where you want to restream a live stream. The list can only contain up to 5 destinations. | [optional] ## Methods diff --git a/docs/LiveStreamSession.md b/docs/LiveStreamSession.md deleted file mode 100644 index 51a6571..0000000 --- a/docs/LiveStreamSession.md +++ /dev/null @@ -1,186 +0,0 @@ -# LiveStreamSession - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**Session** | Pointer to [**LiveStreamSessionSession**](LiveStreamSessionSession.md) | | [optional] -**Location** | Pointer to [**LiveStreamSessionLocation**](LiveStreamSessionLocation.md) | | [optional] -**Referrer** | Pointer to [**LiveStreamSessionReferrer**](LiveStreamSessionReferrer.md) | | [optional] -**Device** | Pointer to [**LiveStreamSessionDevice**](LiveStreamSessionDevice.md) | | [optional] -**Os** | Pointer to [**VideoSessionOs**](VideoSessionOs.md) | | [optional] -**Client** | Pointer to [**LiveStreamSessionClient**](LiveStreamSessionClient.md) | | [optional] - -## Methods - -### NewLiveStreamSession - -`func NewLiveStreamSession() *LiveStreamSession` - -NewLiveStreamSession instantiates a new LiveStreamSession object -This constructor will assign default values to properties that have it defined, -and makes sure properties required by API are set, but the set of arguments -will change when the set of required properties is changed - -### NewLiveStreamSessionWithDefaults - -`func NewLiveStreamSessionWithDefaults() *LiveStreamSession` - -NewLiveStreamSessionWithDefaults instantiates a new LiveStreamSession object -This constructor will only assign default values to properties that have it defined, -but it doesn't guarantee that properties required by API are set - -### GetSession - -`func (o *LiveStreamSession) GetSession() LiveStreamSessionSession` - -GetSession returns the Session field if non-nil, zero value otherwise. - -### GetSessionOk - -`func (o *LiveStreamSession) GetSessionOk() (*LiveStreamSessionSession, bool)` - -GetSessionOk returns a tuple with the Session field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetSession - -`func (o *LiveStreamSession) SetSession(v LiveStreamSessionSession)` - -SetSession sets Session field to given value. - -### HasSession - -`func (o *LiveStreamSession) HasSession() bool` - -HasSession returns a boolean if a field has been set. - -### GetLocation - -`func (o *LiveStreamSession) GetLocation() LiveStreamSessionLocation` - -GetLocation returns the Location field if non-nil, zero value otherwise. - -### GetLocationOk - -`func (o *LiveStreamSession) GetLocationOk() (*LiveStreamSessionLocation, bool)` - -GetLocationOk returns a tuple with the Location field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetLocation - -`func (o *LiveStreamSession) SetLocation(v LiveStreamSessionLocation)` - -SetLocation sets Location field to given value. - -### HasLocation - -`func (o *LiveStreamSession) HasLocation() bool` - -HasLocation returns a boolean if a field has been set. - -### GetReferrer - -`func (o *LiveStreamSession) GetReferrer() LiveStreamSessionReferrer` - -GetReferrer returns the Referrer field if non-nil, zero value otherwise. - -### GetReferrerOk - -`func (o *LiveStreamSession) GetReferrerOk() (*LiveStreamSessionReferrer, bool)` - -GetReferrerOk returns a tuple with the Referrer field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetReferrer - -`func (o *LiveStreamSession) SetReferrer(v LiveStreamSessionReferrer)` - -SetReferrer sets Referrer field to given value. - -### HasReferrer - -`func (o *LiveStreamSession) HasReferrer() bool` - -HasReferrer returns a boolean if a field has been set. - -### GetDevice - -`func (o *LiveStreamSession) GetDevice() LiveStreamSessionDevice` - -GetDevice returns the Device field if non-nil, zero value otherwise. - -### GetDeviceOk - -`func (o *LiveStreamSession) GetDeviceOk() (*LiveStreamSessionDevice, bool)` - -GetDeviceOk returns a tuple with the Device field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetDevice - -`func (o *LiveStreamSession) SetDevice(v LiveStreamSessionDevice)` - -SetDevice sets Device field to given value. - -### HasDevice - -`func (o *LiveStreamSession) HasDevice() bool` - -HasDevice returns a boolean if a field has been set. - -### GetOs - -`func (o *LiveStreamSession) GetOs() VideoSessionOs` - -GetOs returns the Os field if non-nil, zero value otherwise. - -### GetOsOk - -`func (o *LiveStreamSession) GetOsOk() (*VideoSessionOs, bool)` - -GetOsOk returns a tuple with the Os field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetOs - -`func (o *LiveStreamSession) SetOs(v VideoSessionOs)` - -SetOs sets Os field to given value. - -### HasOs - -`func (o *LiveStreamSession) HasOs() bool` - -HasOs returns a boolean if a field has been set. - -### GetClient - -`func (o *LiveStreamSession) GetClient() LiveStreamSessionClient` - -GetClient returns the Client field if non-nil, zero value otherwise. - -### GetClientOk - -`func (o *LiveStreamSession) GetClientOk() (*LiveStreamSessionClient, bool)` - -GetClientOk returns a tuple with the Client field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetClient - -`func (o *LiveStreamSession) SetClient(v LiveStreamSessionClient)` - -SetClient sets Client field to given value. - -### HasClient - -`func (o *LiveStreamSession) HasClient() bool` - -HasClient returns a boolean if a field has been set. - - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/docs/LiveStreamSessionClient.md b/docs/LiveStreamSessionClient.md deleted file mode 100644 index d7e41e9..0000000 --- a/docs/LiveStreamSessionClient.md +++ /dev/null @@ -1,108 +0,0 @@ -# LiveStreamSessionClient - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**Name** | Pointer to **string** | The name of the browser used to view the live stream session. | [optional] -**Version** | Pointer to **string** | The version of the browser used to view the live stream session. | [optional] -**Type** | Pointer to **string** | The type of client used to view the live stream session. | [optional] - -## Methods - -### NewLiveStreamSessionClient - -`func NewLiveStreamSessionClient() *LiveStreamSessionClient` - -NewLiveStreamSessionClient instantiates a new LiveStreamSessionClient object -This constructor will assign default values to properties that have it defined, -and makes sure properties required by API are set, but the set of arguments -will change when the set of required properties is changed - -### NewLiveStreamSessionClientWithDefaults - -`func NewLiveStreamSessionClientWithDefaults() *LiveStreamSessionClient` - -NewLiveStreamSessionClientWithDefaults instantiates a new LiveStreamSessionClient object -This constructor will only assign default values to properties that have it defined, -but it doesn't guarantee that properties required by API are set - -### GetName - -`func (o *LiveStreamSessionClient) GetName() string` - -GetName returns the Name field if non-nil, zero value otherwise. - -### GetNameOk - -`func (o *LiveStreamSessionClient) GetNameOk() (*string, bool)` - -GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetName - -`func (o *LiveStreamSessionClient) SetName(v string)` - -SetName sets Name field to given value. - -### HasName - -`func (o *LiveStreamSessionClient) HasName() bool` - -HasName returns a boolean if a field has been set. - -### GetVersion - -`func (o *LiveStreamSessionClient) GetVersion() string` - -GetVersion returns the Version field if non-nil, zero value otherwise. - -### GetVersionOk - -`func (o *LiveStreamSessionClient) GetVersionOk() (*string, bool)` - -GetVersionOk returns a tuple with the Version field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetVersion - -`func (o *LiveStreamSessionClient) SetVersion(v string)` - -SetVersion sets Version field to given value. - -### HasVersion - -`func (o *LiveStreamSessionClient) HasVersion() bool` - -HasVersion returns a boolean if a field has been set. - -### GetType - -`func (o *LiveStreamSessionClient) GetType() string` - -GetType returns the Type field if non-nil, zero value otherwise. - -### GetTypeOk - -`func (o *LiveStreamSessionClient) GetTypeOk() (*string, bool)` - -GetTypeOk returns a tuple with the Type field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetType - -`func (o *LiveStreamSessionClient) SetType(v string)` - -SetType sets Type field to given value. - -### HasType - -`func (o *LiveStreamSessionClient) HasType() bool` - -HasType returns a boolean if a field has been set. - - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/docs/LiveStreamSessionDevice.md b/docs/LiveStreamSessionDevice.md deleted file mode 100644 index bb4cfe5..0000000 --- a/docs/LiveStreamSessionDevice.md +++ /dev/null @@ -1,108 +0,0 @@ -# LiveStreamSessionDevice - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**Type** | Pointer to **string** | What the type is like desktop, laptop, mobile. | [optional] -**Vendor** | Pointer to **string** | If known, what the brand of the device is, like Apple, Dell, etc. | [optional] -**Model** | Pointer to **string** | The specific model of the device, if known. | [optional] - -## Methods - -### NewLiveStreamSessionDevice - -`func NewLiveStreamSessionDevice() *LiveStreamSessionDevice` - -NewLiveStreamSessionDevice instantiates a new LiveStreamSessionDevice object -This constructor will assign default values to properties that have it defined, -and makes sure properties required by API are set, but the set of arguments -will change when the set of required properties is changed - -### NewLiveStreamSessionDeviceWithDefaults - -`func NewLiveStreamSessionDeviceWithDefaults() *LiveStreamSessionDevice` - -NewLiveStreamSessionDeviceWithDefaults instantiates a new LiveStreamSessionDevice object -This constructor will only assign default values to properties that have it defined, -but it doesn't guarantee that properties required by API are set - -### GetType - -`func (o *LiveStreamSessionDevice) GetType() string` - -GetType returns the Type field if non-nil, zero value otherwise. - -### GetTypeOk - -`func (o *LiveStreamSessionDevice) GetTypeOk() (*string, bool)` - -GetTypeOk returns a tuple with the Type field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetType - -`func (o *LiveStreamSessionDevice) SetType(v string)` - -SetType sets Type field to given value. - -### HasType - -`func (o *LiveStreamSessionDevice) HasType() bool` - -HasType returns a boolean if a field has been set. - -### GetVendor - -`func (o *LiveStreamSessionDevice) GetVendor() string` - -GetVendor returns the Vendor field if non-nil, zero value otherwise. - -### GetVendorOk - -`func (o *LiveStreamSessionDevice) GetVendorOk() (*string, bool)` - -GetVendorOk returns a tuple with the Vendor field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetVendor - -`func (o *LiveStreamSessionDevice) SetVendor(v string)` - -SetVendor sets Vendor field to given value. - -### HasVendor - -`func (o *LiveStreamSessionDevice) HasVendor() bool` - -HasVendor returns a boolean if a field has been set. - -### GetModel - -`func (o *LiveStreamSessionDevice) GetModel() string` - -GetModel returns the Model field if non-nil, zero value otherwise. - -### GetModelOk - -`func (o *LiveStreamSessionDevice) GetModelOk() (*string, bool)` - -GetModelOk returns a tuple with the Model field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetModel - -`func (o *LiveStreamSessionDevice) SetModel(v string)` - -SetModel sets Model field to given value. - -### HasModel - -`func (o *LiveStreamSessionDevice) HasModel() bool` - -HasModel returns a boolean if a field has been set. - - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/docs/LiveStreamSessionLocation.md b/docs/LiveStreamSessionLocation.md deleted file mode 100644 index 8d72eac..0000000 --- a/docs/LiveStreamSessionLocation.md +++ /dev/null @@ -1,82 +0,0 @@ -# LiveStreamSessionLocation - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**Country** | Pointer to **string** | The country of the viewer of the live stream. | [optional] -**City** | Pointer to **string** | The city of the viewer of the live stream. | [optional] - -## Methods - -### NewLiveStreamSessionLocation - -`func NewLiveStreamSessionLocation() *LiveStreamSessionLocation` - -NewLiveStreamSessionLocation instantiates a new LiveStreamSessionLocation object -This constructor will assign default values to properties that have it defined, -and makes sure properties required by API are set, but the set of arguments -will change when the set of required properties is changed - -### NewLiveStreamSessionLocationWithDefaults - -`func NewLiveStreamSessionLocationWithDefaults() *LiveStreamSessionLocation` - -NewLiveStreamSessionLocationWithDefaults instantiates a new LiveStreamSessionLocation object -This constructor will only assign default values to properties that have it defined, -but it doesn't guarantee that properties required by API are set - -### GetCountry - -`func (o *LiveStreamSessionLocation) GetCountry() string` - -GetCountry returns the Country field if non-nil, zero value otherwise. - -### GetCountryOk - -`func (o *LiveStreamSessionLocation) GetCountryOk() (*string, bool)` - -GetCountryOk returns a tuple with the Country field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetCountry - -`func (o *LiveStreamSessionLocation) SetCountry(v string)` - -SetCountry sets Country field to given value. - -### HasCountry - -`func (o *LiveStreamSessionLocation) HasCountry() bool` - -HasCountry returns a boolean if a field has been set. - -### GetCity - -`func (o *LiveStreamSessionLocation) GetCity() string` - -GetCity returns the City field if non-nil, zero value otherwise. - -### GetCityOk - -`func (o *LiveStreamSessionLocation) GetCityOk() (*string, bool)` - -GetCityOk returns a tuple with the City field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetCity - -`func (o *LiveStreamSessionLocation) SetCity(v string)` - -SetCity sets City field to given value. - -### HasCity - -`func (o *LiveStreamSessionLocation) HasCity() bool` - -HasCity returns a boolean if a field has been set. - - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/docs/LiveStreamSessionReferrer.md b/docs/LiveStreamSessionReferrer.md deleted file mode 100644 index af297f3..0000000 --- a/docs/LiveStreamSessionReferrer.md +++ /dev/null @@ -1,134 +0,0 @@ -# LiveStreamSessionReferrer - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**Url** | Pointer to **string** | The website the viewer of the live stream was referred to in order to view the live stream. | [optional] -**Medium** | Pointer to **string** | The type of search that brought the viewer to the live stream. Organic would be they found it on their own, paid would be they found it via an advertisement. | [optional] -**Source** | Pointer to **string** | Where the viewer came from to see the live stream (usually where they searched from). | [optional] -**SearchTerm** | Pointer to **string** | What term they searched for that led them to the live stream. | [optional] - -## Methods - -### NewLiveStreamSessionReferrer - -`func NewLiveStreamSessionReferrer() *LiveStreamSessionReferrer` - -NewLiveStreamSessionReferrer instantiates a new LiveStreamSessionReferrer object -This constructor will assign default values to properties that have it defined, -and makes sure properties required by API are set, but the set of arguments -will change when the set of required properties is changed - -### NewLiveStreamSessionReferrerWithDefaults - -`func NewLiveStreamSessionReferrerWithDefaults() *LiveStreamSessionReferrer` - -NewLiveStreamSessionReferrerWithDefaults instantiates a new LiveStreamSessionReferrer object -This constructor will only assign default values to properties that have it defined, -but it doesn't guarantee that properties required by API are set - -### GetUrl - -`func (o *LiveStreamSessionReferrer) GetUrl() string` - -GetUrl returns the Url field if non-nil, zero value otherwise. - -### GetUrlOk - -`func (o *LiveStreamSessionReferrer) GetUrlOk() (*string, bool)` - -GetUrlOk returns a tuple with the Url field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetUrl - -`func (o *LiveStreamSessionReferrer) SetUrl(v string)` - -SetUrl sets Url field to given value. - -### HasUrl - -`func (o *LiveStreamSessionReferrer) HasUrl() bool` - -HasUrl returns a boolean if a field has been set. - -### GetMedium - -`func (o *LiveStreamSessionReferrer) GetMedium() string` - -GetMedium returns the Medium field if non-nil, zero value otherwise. - -### GetMediumOk - -`func (o *LiveStreamSessionReferrer) GetMediumOk() (*string, bool)` - -GetMediumOk returns a tuple with the Medium field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetMedium - -`func (o *LiveStreamSessionReferrer) SetMedium(v string)` - -SetMedium sets Medium field to given value. - -### HasMedium - -`func (o *LiveStreamSessionReferrer) HasMedium() bool` - -HasMedium returns a boolean if a field has been set. - -### GetSource - -`func (o *LiveStreamSessionReferrer) GetSource() string` - -GetSource returns the Source field if non-nil, zero value otherwise. - -### GetSourceOk - -`func (o *LiveStreamSessionReferrer) GetSourceOk() (*string, bool)` - -GetSourceOk returns a tuple with the Source field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetSource - -`func (o *LiveStreamSessionReferrer) SetSource(v string)` - -SetSource sets Source field to given value. - -### HasSource - -`func (o *LiveStreamSessionReferrer) HasSource() bool` - -HasSource returns a boolean if a field has been set. - -### GetSearchTerm - -`func (o *LiveStreamSessionReferrer) GetSearchTerm() string` - -GetSearchTerm returns the SearchTerm field if non-nil, zero value otherwise. - -### GetSearchTermOk - -`func (o *LiveStreamSessionReferrer) GetSearchTermOk() (*string, bool)` - -GetSearchTermOk returns a tuple with the SearchTerm field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetSearchTerm - -`func (o *LiveStreamSessionReferrer) SetSearchTerm(v string)` - -SetSearchTerm sets SearchTerm field to given value. - -### HasSearchTerm - -`func (o *LiveStreamSessionReferrer) HasSearchTerm() bool` - -HasSearchTerm returns a boolean if a field has been set. - - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/docs/LiveStreamSessionSession.md b/docs/LiveStreamSessionSession.md deleted file mode 100644 index 2f80eb1..0000000 --- a/docs/LiveStreamSessionSession.md +++ /dev/null @@ -1,108 +0,0 @@ -# LiveStreamSessionSession - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**SessionId** | Pointer to **string** | A unique identifier for your session. You can use this to track what happens during a specific session. | [optional] -**LoadedAt** | Pointer to **string** | When the session started, with the date and time presented in ISO-8601 format. | [optional] -**EndedAt** | Pointer to **string** | When the session ended, with the date and time presented in ISO-8601 format. | [optional] - -## Methods - -### NewLiveStreamSessionSession - -`func NewLiveStreamSessionSession() *LiveStreamSessionSession` - -NewLiveStreamSessionSession instantiates a new LiveStreamSessionSession object -This constructor will assign default values to properties that have it defined, -and makes sure properties required by API are set, but the set of arguments -will change when the set of required properties is changed - -### NewLiveStreamSessionSessionWithDefaults - -`func NewLiveStreamSessionSessionWithDefaults() *LiveStreamSessionSession` - -NewLiveStreamSessionSessionWithDefaults instantiates a new LiveStreamSessionSession object -This constructor will only assign default values to properties that have it defined, -but it doesn't guarantee that properties required by API are set - -### GetSessionId - -`func (o *LiveStreamSessionSession) GetSessionId() string` - -GetSessionId returns the SessionId field if non-nil, zero value otherwise. - -### GetSessionIdOk - -`func (o *LiveStreamSessionSession) GetSessionIdOk() (*string, bool)` - -GetSessionIdOk returns a tuple with the SessionId field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetSessionId - -`func (o *LiveStreamSessionSession) SetSessionId(v string)` - -SetSessionId sets SessionId field to given value. - -### HasSessionId - -`func (o *LiveStreamSessionSession) HasSessionId() bool` - -HasSessionId returns a boolean if a field has been set. - -### GetLoadedAt - -`func (o *LiveStreamSessionSession) GetLoadedAt() string` - -GetLoadedAt returns the LoadedAt field if non-nil, zero value otherwise. - -### GetLoadedAtOk - -`func (o *LiveStreamSessionSession) GetLoadedAtOk() (*string, bool)` - -GetLoadedAtOk returns a tuple with the LoadedAt field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetLoadedAt - -`func (o *LiveStreamSessionSession) SetLoadedAt(v string)` - -SetLoadedAt sets LoadedAt field to given value. - -### HasLoadedAt - -`func (o *LiveStreamSessionSession) HasLoadedAt() bool` - -HasLoadedAt returns a boolean if a field has been set. - -### GetEndedAt - -`func (o *LiveStreamSessionSession) GetEndedAt() string` - -GetEndedAt returns the EndedAt field if non-nil, zero value otherwise. - -### GetEndedAtOk - -`func (o *LiveStreamSessionSession) GetEndedAtOk() (*string, bool)` - -GetEndedAtOk returns a tuple with the EndedAt field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetEndedAt - -`func (o *LiveStreamSessionSession) SetEndedAt(v string)` - -SetEndedAt sets EndedAt field to given value. - -### HasEndedAt - -`func (o *LiveStreamSessionSession) HasEndedAt() bool` - -HasEndedAt returns a boolean if a field has been set. - - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/docs/LiveStreamUpdatePayload.md b/docs/LiveStreamUpdatePayload.md index 9e67c05..529432a 100644 --- a/docs/LiveStreamUpdatePayload.md +++ b/docs/LiveStreamUpdatePayload.md @@ -5,9 +5,9 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **Name** | Pointer to **string** | The name you want to use for your live stream. | [optional] -**Public** | Pointer to **bool** | Whether your video can be viewed by everyone, or requires authentication to see it. A setting of false will require a unique token for each view. Learn more about the Private Video feature [here](https://docs.api.video/delivery-analytics/video-privacy-access-management). | [optional] +**Public** | Pointer to **bool** | Whether your video can be viewed by everyone, or requires authentication to see it. A setting of false will require a unique token for each view. Learn more about the Private Video feature [here](https://docs.api.video/delivery/video-privacy-access-management). | [optional] **PlayerId** | Pointer to **string** | The unique ID for the player associated with a live stream that you want to update. | [optional] -**Restreams** | Pointer to [**[]RestreamsRequestObject**](RestreamsRequestObject.md) | Use this parameter to add, edit, or remove RTMP services where you want to restream a live stream. The list can only contain up to 5 destinations. This operation updates all restream destinations in the same request. If you do not want to modify an existing restream destination, you need to include it in your request, otherwise it is removed. | [optional] +**Restreams** | Pointer to [**[]RestreamsRequestObject**](RestreamsRequestObject.md) | Use this parameter to add, edit, or remove `RTMPS` or `RTMP` services where you want to restream a live stream. The list can only contain up to 5 destinations. This operation updates all restream destinations in the same request. If you do not want to modify an existing restream destination, you need to include it in your request, otherwise it is removed. | [optional] ## Methods diff --git a/docs/LiveStreams.md b/docs/LiveStreams.md index cf42cf8..472f081 100644 --- a/docs/LiveStreams.md +++ b/docs/LiveStreams.md @@ -11,6 +11,7 @@ Method | HTTP request | Description [**List**](LiveStreams.md#List) | **Get** /live-streams | List all live streams [**UploadThumbnail**](LiveStreams.md#UploadThumbnail) | **Post** /live-streams/{liveStreamId}/thumbnail | Upload a thumbnail [**DeleteThumbnail**](LiveStreams.md#DeleteThumbnail) | **Delete** /live-streams/{liveStreamId}/thumbnail | Delete a thumbnail +[**Complete**](LiveStreams.md#Complete) | **Put** /live-streams/{liveStreamId}/complete | Complete a live stream @@ -468,3 +469,64 @@ Name | Type | Description | Notes [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +## Complete + +> Complete(liveStreamId string) (error) + +> CompleteWithContext(ctx context.Context, liveStreamId string) (error) + + +Complete a live stream + + + +### Example + +```go +package main + +import ( + "context" + "fmt" + "os" + apivideosdk "github.com/apivideo/api.video-go-client" +) + +func main() { + client := apivideosdk.ClientBuilder("YOUR_API_KEY").Build() + // if you rather like to use the sandbox environment: + // client := apivideosdk.SandboxClientBuilder("YOU_SANDBOX_API_KEY").Build() + + liveStreamId := "vi4k0jvEUuaTdRAEjQ4Jfrgz" // string | The unique ID for the live stream you want to complete. + + + err := client.LiveStreams.Complete(liveStreamId) + + if err != nil { + fmt.Fprintf(os.Stderr, "Error when calling `LiveStreams.Complete``: %v\n", err) + } +} +``` +### Path Parameters + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- +**liveStreamId** | **string** | The unique ID for the live stream you want to complete. | + +### Other Parameters + + + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + +### Return type + + (empty response body) + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) +[[Back to Model list]](../README.md#documentation-for-models) +[[Back to README]](../README.md) + diff --git a/docs/RestreamsRequestObject.md b/docs/RestreamsRequestObject.md index b5f2368..3b60348 100644 --- a/docs/RestreamsRequestObject.md +++ b/docs/RestreamsRequestObject.md @@ -5,7 +5,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **Name** | **string** | Use this parameter to define a name for the restream destination. | -**ServerUrl** | **string** | Use this parameter to set the RTMP URL of the restream destination. | +**ServerUrl** | **string** | Use this parameter to set the `RTMPS` or `RTMP` server URL of the restream destination. | **StreamKey** | **string** | Use this parameter to provide the unique key of the live stream that you want to restream. | ## Methods diff --git a/docs/RestreamsResponseObject.md b/docs/RestreamsResponseObject.md index 7ed0435..6a50c9d 100644 --- a/docs/RestreamsResponseObject.md +++ b/docs/RestreamsResponseObject.md @@ -5,7 +5,7 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **Name** | Pointer to **string** | Returns the name of a restream destination. | [optional] -**ServerUrl** | Pointer to **string** | Returns the RTMP URL of a restream destination. | [optional] +**ServerUrl** | Pointer to **string** | Returns the server URL of a restream destination. | [optional] **StreamKey** | Pointer to **string** | Returns the unique key of the live stream that is set up for restreaming. | [optional] ## Methods diff --git a/docs/UnrecognizedRequestUrl.md b/docs/UnrecognizedRequestUrl.md new file mode 100644 index 0000000..6418e4a --- /dev/null +++ b/docs/UnrecognizedRequestUrl.md @@ -0,0 +1,108 @@ +# UnrecognizedRequestUrl + +## Properties + +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**Type** | Pointer to **string** | A link to the error documentation. | [optional] +**Title** | Pointer to **string** | A description of the error that occurred. | [optional] +**Status** | Pointer to **int32** | The HTTP status code. | [optional] + +## Methods + +### NewUnrecognizedRequestUrl + +`func NewUnrecognizedRequestUrl() *UnrecognizedRequestUrl` + +NewUnrecognizedRequestUrl instantiates a new UnrecognizedRequestUrl object +This constructor will assign default values to properties that have it defined, +and makes sure properties required by API are set, but the set of arguments +will change when the set of required properties is changed + +### NewUnrecognizedRequestUrlWithDefaults + +`func NewUnrecognizedRequestUrlWithDefaults() *UnrecognizedRequestUrl` + +NewUnrecognizedRequestUrlWithDefaults instantiates a new UnrecognizedRequestUrl object +This constructor will only assign default values to properties that have it defined, +but it doesn't guarantee that properties required by API are set + +### GetType + +`func (o *UnrecognizedRequestUrl) GetType() string` + +GetType returns the Type field if non-nil, zero value otherwise. + +### GetTypeOk + +`func (o *UnrecognizedRequestUrl) GetTypeOk() (*string, bool)` + +GetTypeOk returns a tuple with the Type field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetType + +`func (o *UnrecognizedRequestUrl) SetType(v string)` + +SetType sets Type field to given value. + +### HasType + +`func (o *UnrecognizedRequestUrl) HasType() bool` + +HasType returns a boolean if a field has been set. + +### GetTitle + +`func (o *UnrecognizedRequestUrl) GetTitle() string` + +GetTitle returns the Title field if non-nil, zero value otherwise. + +### GetTitleOk + +`func (o *UnrecognizedRequestUrl) GetTitleOk() (*string, bool)` + +GetTitleOk returns a tuple with the Title field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetTitle + +`func (o *UnrecognizedRequestUrl) SetTitle(v string)` + +SetTitle sets Title field to given value. + +### HasTitle + +`func (o *UnrecognizedRequestUrl) HasTitle() bool` + +HasTitle returns a boolean if a field has been set. + +### GetStatus + +`func (o *UnrecognizedRequestUrl) GetStatus() int32` + +GetStatus returns the Status field if non-nil, zero value otherwise. + +### GetStatusOk + +`func (o *UnrecognizedRequestUrl) GetStatusOk() (*int32, bool)` + +GetStatusOk returns a tuple with the Status field if it's non-nil, zero value otherwise +and a boolean to check if the value has been set. + +### SetStatus + +`func (o *UnrecognizedRequestUrl) SetStatus(v int32)` + +SetStatus sets Status field to given value. + +### HasStatus + +`func (o *UnrecognizedRequestUrl) HasStatus() bool` + +HasStatus returns a boolean if a field has been set. + + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/docs/VideoCreationPayload.md b/docs/VideoCreationPayload.md index 33c6d7a..c6f5efe 100644 --- a/docs/VideoCreationPayload.md +++ b/docs/VideoCreationPayload.md @@ -7,7 +7,7 @@ Name | Type | Description | Notes **Title** | **string** | The title of your new video. | **Description** | Pointer to **string** | A brief description of your video. | [optional] **Source** | Pointer to **string** | You can either add a video already on the web, by entering the URL of the video, or you can also enter the `videoId` of one of the videos you already have on your api.video acccount, and this will generate a copy of your video. Creating a copy of a video can be especially useful if you want to keep your original video and trim or apply a watermark onto the copy you would create. | [optional] -**Public** | Pointer to **bool** | Default: True. If set to `false` the video will become private. More information on private videos can be found [here](https://docs.api.video/delivery-analytics/video-privacy-access-management) | [optional] [default to true] +**Public** | Pointer to **bool** | Default: True. If set to `false` the video will become private. More information on private videos can be found [here](https://docs.api.video/delivery/video-privacy-access-management) | [optional] [default to true] **Panoramic** | Pointer to **bool** | Indicates if your video is a 360/immersive video. | [optional] [default to false] **Mp4Support** | Pointer to **bool** | Enables mp4 version in addition to streamed version. | [optional] [default to true] **PlayerId** | Pointer to **string** | The unique identification number for your video player. | [optional] diff --git a/docs/VideoSession.md b/docs/VideoSession.md deleted file mode 100644 index 2956ba1..0000000 --- a/docs/VideoSession.md +++ /dev/null @@ -1,186 +0,0 @@ -# VideoSession - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**Session** | Pointer to [**VideoSessionSession**](VideoSessionSession.md) | | [optional] -**Location** | Pointer to [**VideoSessionLocation**](VideoSessionLocation.md) | | [optional] -**Referrer** | Pointer to [**VideoSessionReferrer**](VideoSessionReferrer.md) | | [optional] -**Device** | Pointer to [**VideoSessionDevice**](VideoSessionDevice.md) | | [optional] -**Os** | Pointer to [**VideoSessionOs**](VideoSessionOs.md) | | [optional] -**Client** | Pointer to [**VideoSessionClient**](VideoSessionClient.md) | | [optional] - -## Methods - -### NewVideoSession - -`func NewVideoSession() *VideoSession` - -NewVideoSession instantiates a new VideoSession object -This constructor will assign default values to properties that have it defined, -and makes sure properties required by API are set, but the set of arguments -will change when the set of required properties is changed - -### NewVideoSessionWithDefaults - -`func NewVideoSessionWithDefaults() *VideoSession` - -NewVideoSessionWithDefaults instantiates a new VideoSession object -This constructor will only assign default values to properties that have it defined, -but it doesn't guarantee that properties required by API are set - -### GetSession - -`func (o *VideoSession) GetSession() VideoSessionSession` - -GetSession returns the Session field if non-nil, zero value otherwise. - -### GetSessionOk - -`func (o *VideoSession) GetSessionOk() (*VideoSessionSession, bool)` - -GetSessionOk returns a tuple with the Session field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetSession - -`func (o *VideoSession) SetSession(v VideoSessionSession)` - -SetSession sets Session field to given value. - -### HasSession - -`func (o *VideoSession) HasSession() bool` - -HasSession returns a boolean if a field has been set. - -### GetLocation - -`func (o *VideoSession) GetLocation() VideoSessionLocation` - -GetLocation returns the Location field if non-nil, zero value otherwise. - -### GetLocationOk - -`func (o *VideoSession) GetLocationOk() (*VideoSessionLocation, bool)` - -GetLocationOk returns a tuple with the Location field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetLocation - -`func (o *VideoSession) SetLocation(v VideoSessionLocation)` - -SetLocation sets Location field to given value. - -### HasLocation - -`func (o *VideoSession) HasLocation() bool` - -HasLocation returns a boolean if a field has been set. - -### GetReferrer - -`func (o *VideoSession) GetReferrer() VideoSessionReferrer` - -GetReferrer returns the Referrer field if non-nil, zero value otherwise. - -### GetReferrerOk - -`func (o *VideoSession) GetReferrerOk() (*VideoSessionReferrer, bool)` - -GetReferrerOk returns a tuple with the Referrer field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetReferrer - -`func (o *VideoSession) SetReferrer(v VideoSessionReferrer)` - -SetReferrer sets Referrer field to given value. - -### HasReferrer - -`func (o *VideoSession) HasReferrer() bool` - -HasReferrer returns a boolean if a field has been set. - -### GetDevice - -`func (o *VideoSession) GetDevice() VideoSessionDevice` - -GetDevice returns the Device field if non-nil, zero value otherwise. - -### GetDeviceOk - -`func (o *VideoSession) GetDeviceOk() (*VideoSessionDevice, bool)` - -GetDeviceOk returns a tuple with the Device field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetDevice - -`func (o *VideoSession) SetDevice(v VideoSessionDevice)` - -SetDevice sets Device field to given value. - -### HasDevice - -`func (o *VideoSession) HasDevice() bool` - -HasDevice returns a boolean if a field has been set. - -### GetOs - -`func (o *VideoSession) GetOs() VideoSessionOs` - -GetOs returns the Os field if non-nil, zero value otherwise. - -### GetOsOk - -`func (o *VideoSession) GetOsOk() (*VideoSessionOs, bool)` - -GetOsOk returns a tuple with the Os field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetOs - -`func (o *VideoSession) SetOs(v VideoSessionOs)` - -SetOs sets Os field to given value. - -### HasOs - -`func (o *VideoSession) HasOs() bool` - -HasOs returns a boolean if a field has been set. - -### GetClient - -`func (o *VideoSession) GetClient() VideoSessionClient` - -GetClient returns the Client field if non-nil, zero value otherwise. - -### GetClientOk - -`func (o *VideoSession) GetClientOk() (*VideoSessionClient, bool)` - -GetClientOk returns a tuple with the Client field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetClient - -`func (o *VideoSession) SetClient(v VideoSessionClient)` - -SetClient sets Client field to given value. - -### HasClient - -`func (o *VideoSession) HasClient() bool` - -HasClient returns a boolean if a field has been set. - - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/docs/VideoSessionClient.md b/docs/VideoSessionClient.md deleted file mode 100644 index e482e77..0000000 --- a/docs/VideoSessionClient.md +++ /dev/null @@ -1,108 +0,0 @@ -# VideoSessionClient - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**Name** | Pointer to **string** | The name of the browser used to view the video session. | [optional] -**Version** | Pointer to **string** | The version of the browser used to view the video session. | [optional] -**Type** | Pointer to **string** | The type of client used to view the video session. | [optional] - -## Methods - -### NewVideoSessionClient - -`func NewVideoSessionClient() *VideoSessionClient` - -NewVideoSessionClient instantiates a new VideoSessionClient object -This constructor will assign default values to properties that have it defined, -and makes sure properties required by API are set, but the set of arguments -will change when the set of required properties is changed - -### NewVideoSessionClientWithDefaults - -`func NewVideoSessionClientWithDefaults() *VideoSessionClient` - -NewVideoSessionClientWithDefaults instantiates a new VideoSessionClient object -This constructor will only assign default values to properties that have it defined, -but it doesn't guarantee that properties required by API are set - -### GetName - -`func (o *VideoSessionClient) GetName() string` - -GetName returns the Name field if non-nil, zero value otherwise. - -### GetNameOk - -`func (o *VideoSessionClient) GetNameOk() (*string, bool)` - -GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetName - -`func (o *VideoSessionClient) SetName(v string)` - -SetName sets Name field to given value. - -### HasName - -`func (o *VideoSessionClient) HasName() bool` - -HasName returns a boolean if a field has been set. - -### GetVersion - -`func (o *VideoSessionClient) GetVersion() string` - -GetVersion returns the Version field if non-nil, zero value otherwise. - -### GetVersionOk - -`func (o *VideoSessionClient) GetVersionOk() (*string, bool)` - -GetVersionOk returns a tuple with the Version field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetVersion - -`func (o *VideoSessionClient) SetVersion(v string)` - -SetVersion sets Version field to given value. - -### HasVersion - -`func (o *VideoSessionClient) HasVersion() bool` - -HasVersion returns a boolean if a field has been set. - -### GetType - -`func (o *VideoSessionClient) GetType() string` - -GetType returns the Type field if non-nil, zero value otherwise. - -### GetTypeOk - -`func (o *VideoSessionClient) GetTypeOk() (*string, bool)` - -GetTypeOk returns a tuple with the Type field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetType - -`func (o *VideoSessionClient) SetType(v string)` - -SetType sets Type field to given value. - -### HasType - -`func (o *VideoSessionClient) HasType() bool` - -HasType returns a boolean if a field has been set. - - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/docs/VideoSessionDevice.md b/docs/VideoSessionDevice.md deleted file mode 100644 index 79b0c30..0000000 --- a/docs/VideoSessionDevice.md +++ /dev/null @@ -1,108 +0,0 @@ -# VideoSessionDevice - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**Type** | Pointer to **string** | What the type is like desktop, laptop, mobile. | [optional] -**Vendor** | Pointer to **string** | If known, what the brand of the device is, like Apple, Dell, etc. | [optional] -**Model** | Pointer to **string** | The specific model of the device, if known. | [optional] - -## Methods - -### NewVideoSessionDevice - -`func NewVideoSessionDevice() *VideoSessionDevice` - -NewVideoSessionDevice instantiates a new VideoSessionDevice object -This constructor will assign default values to properties that have it defined, -and makes sure properties required by API are set, but the set of arguments -will change when the set of required properties is changed - -### NewVideoSessionDeviceWithDefaults - -`func NewVideoSessionDeviceWithDefaults() *VideoSessionDevice` - -NewVideoSessionDeviceWithDefaults instantiates a new VideoSessionDevice object -This constructor will only assign default values to properties that have it defined, -but it doesn't guarantee that properties required by API are set - -### GetType - -`func (o *VideoSessionDevice) GetType() string` - -GetType returns the Type field if non-nil, zero value otherwise. - -### GetTypeOk - -`func (o *VideoSessionDevice) GetTypeOk() (*string, bool)` - -GetTypeOk returns a tuple with the Type field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetType - -`func (o *VideoSessionDevice) SetType(v string)` - -SetType sets Type field to given value. - -### HasType - -`func (o *VideoSessionDevice) HasType() bool` - -HasType returns a boolean if a field has been set. - -### GetVendor - -`func (o *VideoSessionDevice) GetVendor() string` - -GetVendor returns the Vendor field if non-nil, zero value otherwise. - -### GetVendorOk - -`func (o *VideoSessionDevice) GetVendorOk() (*string, bool)` - -GetVendorOk returns a tuple with the Vendor field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetVendor - -`func (o *VideoSessionDevice) SetVendor(v string)` - -SetVendor sets Vendor field to given value. - -### HasVendor - -`func (o *VideoSessionDevice) HasVendor() bool` - -HasVendor returns a boolean if a field has been set. - -### GetModel - -`func (o *VideoSessionDevice) GetModel() string` - -GetModel returns the Model field if non-nil, zero value otherwise. - -### GetModelOk - -`func (o *VideoSessionDevice) GetModelOk() (*string, bool)` - -GetModelOk returns a tuple with the Model field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetModel - -`func (o *VideoSessionDevice) SetModel(v string)` - -SetModel sets Model field to given value. - -### HasModel - -`func (o *VideoSessionDevice) HasModel() bool` - -HasModel returns a boolean if a field has been set. - - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/docs/VideoSessionLocation.md b/docs/VideoSessionLocation.md deleted file mode 100644 index 932b0e2..0000000 --- a/docs/VideoSessionLocation.md +++ /dev/null @@ -1,92 +0,0 @@ -# VideoSessionLocation - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**Country** | Pointer to **string** | The country of the viewer. | [optional] -**City** | Pointer to **NullableString** | The city of the viewer. | [optional] - -## Methods - -### NewVideoSessionLocation - -`func NewVideoSessionLocation() *VideoSessionLocation` - -NewVideoSessionLocation instantiates a new VideoSessionLocation object -This constructor will assign default values to properties that have it defined, -and makes sure properties required by API are set, but the set of arguments -will change when the set of required properties is changed - -### NewVideoSessionLocationWithDefaults - -`func NewVideoSessionLocationWithDefaults() *VideoSessionLocation` - -NewVideoSessionLocationWithDefaults instantiates a new VideoSessionLocation object -This constructor will only assign default values to properties that have it defined, -but it doesn't guarantee that properties required by API are set - -### GetCountry - -`func (o *VideoSessionLocation) GetCountry() string` - -GetCountry returns the Country field if non-nil, zero value otherwise. - -### GetCountryOk - -`func (o *VideoSessionLocation) GetCountryOk() (*string, bool)` - -GetCountryOk returns a tuple with the Country field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetCountry - -`func (o *VideoSessionLocation) SetCountry(v string)` - -SetCountry sets Country field to given value. - -### HasCountry - -`func (o *VideoSessionLocation) HasCountry() bool` - -HasCountry returns a boolean if a field has been set. - -### GetCity - -`func (o *VideoSessionLocation) GetCity() string` - -GetCity returns the City field if non-nil, zero value otherwise. - -### GetCityOk - -`func (o *VideoSessionLocation) GetCityOk() (*string, bool)` - -GetCityOk returns a tuple with the City field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetCity - -`func (o *VideoSessionLocation) SetCity(v string)` - -SetCity sets City field to given value. - -### HasCity - -`func (o *VideoSessionLocation) HasCity() bool` - -HasCity returns a boolean if a field has been set. - -### SetCityNil - -`func (o *VideoSessionLocation) SetCityNil(b bool)` - - SetCityNil sets the value for City to be an explicit nil - -### UnsetCity -`func (o *VideoSessionLocation) UnsetCity()` - -UnsetCity ensures that no value is present for City, not even an explicit nil - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/docs/VideoSessionOs.md b/docs/VideoSessionOs.md deleted file mode 100644 index f36abd4..0000000 --- a/docs/VideoSessionOs.md +++ /dev/null @@ -1,108 +0,0 @@ -# VideoSessionOs - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**Name** | Pointer to **string** | The name of the operating system. | [optional] -**Shortname** | Pointer to **string** | The nickname for the operating system, often representing the version. | [optional] -**Version** | Pointer to **string** | The version of the operating system. | [optional] - -## Methods - -### NewVideoSessionOs - -`func NewVideoSessionOs() *VideoSessionOs` - -NewVideoSessionOs instantiates a new VideoSessionOs object -This constructor will assign default values to properties that have it defined, -and makes sure properties required by API are set, but the set of arguments -will change when the set of required properties is changed - -### NewVideoSessionOsWithDefaults - -`func NewVideoSessionOsWithDefaults() *VideoSessionOs` - -NewVideoSessionOsWithDefaults instantiates a new VideoSessionOs object -This constructor will only assign default values to properties that have it defined, -but it doesn't guarantee that properties required by API are set - -### GetName - -`func (o *VideoSessionOs) GetName() string` - -GetName returns the Name field if non-nil, zero value otherwise. - -### GetNameOk - -`func (o *VideoSessionOs) GetNameOk() (*string, bool)` - -GetNameOk returns a tuple with the Name field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetName - -`func (o *VideoSessionOs) SetName(v string)` - -SetName sets Name field to given value. - -### HasName - -`func (o *VideoSessionOs) HasName() bool` - -HasName returns a boolean if a field has been set. - -### GetShortname - -`func (o *VideoSessionOs) GetShortname() string` - -GetShortname returns the Shortname field if non-nil, zero value otherwise. - -### GetShortnameOk - -`func (o *VideoSessionOs) GetShortnameOk() (*string, bool)` - -GetShortnameOk returns a tuple with the Shortname field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetShortname - -`func (o *VideoSessionOs) SetShortname(v string)` - -SetShortname sets Shortname field to given value. - -### HasShortname - -`func (o *VideoSessionOs) HasShortname() bool` - -HasShortname returns a boolean if a field has been set. - -### GetVersion - -`func (o *VideoSessionOs) GetVersion() string` - -GetVersion returns the Version field if non-nil, zero value otherwise. - -### GetVersionOk - -`func (o *VideoSessionOs) GetVersionOk() (*string, bool)` - -GetVersionOk returns a tuple with the Version field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetVersion - -`func (o *VideoSessionOs) SetVersion(v string)` - -SetVersion sets Version field to given value. - -### HasVersion - -`func (o *VideoSessionOs) HasVersion() bool` - -HasVersion returns a boolean if a field has been set. - - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/docs/VideoSessionReferrer.md b/docs/VideoSessionReferrer.md deleted file mode 100644 index a8152d9..0000000 --- a/docs/VideoSessionReferrer.md +++ /dev/null @@ -1,144 +0,0 @@ -# VideoSessionReferrer - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**Url** | Pointer to **NullableString** | The link the viewer used to reach the video session. | [optional] -**Medium** | Pointer to **string** | How they arrived at the site, for example organic or paid. Organic meaning they found it themselves and paid meaning they followed a link from an advertisement. | [optional] -**Source** | Pointer to **string** | The source the referrer came from to the video session. For example if they searched through google to find the stream. | [optional] -**SearchTerm** | Pointer to **string** | The search term they typed to arrive at the video session. | [optional] - -## Methods - -### NewVideoSessionReferrer - -`func NewVideoSessionReferrer() *VideoSessionReferrer` - -NewVideoSessionReferrer instantiates a new VideoSessionReferrer object -This constructor will assign default values to properties that have it defined, -and makes sure properties required by API are set, but the set of arguments -will change when the set of required properties is changed - -### NewVideoSessionReferrerWithDefaults - -`func NewVideoSessionReferrerWithDefaults() *VideoSessionReferrer` - -NewVideoSessionReferrerWithDefaults instantiates a new VideoSessionReferrer object -This constructor will only assign default values to properties that have it defined, -but it doesn't guarantee that properties required by API are set - -### GetUrl - -`func (o *VideoSessionReferrer) GetUrl() string` - -GetUrl returns the Url field if non-nil, zero value otherwise. - -### GetUrlOk - -`func (o *VideoSessionReferrer) GetUrlOk() (*string, bool)` - -GetUrlOk returns a tuple with the Url field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetUrl - -`func (o *VideoSessionReferrer) SetUrl(v string)` - -SetUrl sets Url field to given value. - -### HasUrl - -`func (o *VideoSessionReferrer) HasUrl() bool` - -HasUrl returns a boolean if a field has been set. - -### SetUrlNil - -`func (o *VideoSessionReferrer) SetUrlNil(b bool)` - - SetUrlNil sets the value for Url to be an explicit nil - -### UnsetUrl -`func (o *VideoSessionReferrer) UnsetUrl()` - -UnsetUrl ensures that no value is present for Url, not even an explicit nil -### GetMedium - -`func (o *VideoSessionReferrer) GetMedium() string` - -GetMedium returns the Medium field if non-nil, zero value otherwise. - -### GetMediumOk - -`func (o *VideoSessionReferrer) GetMediumOk() (*string, bool)` - -GetMediumOk returns a tuple with the Medium field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetMedium - -`func (o *VideoSessionReferrer) SetMedium(v string)` - -SetMedium sets Medium field to given value. - -### HasMedium - -`func (o *VideoSessionReferrer) HasMedium() bool` - -HasMedium returns a boolean if a field has been set. - -### GetSource - -`func (o *VideoSessionReferrer) GetSource() string` - -GetSource returns the Source field if non-nil, zero value otherwise. - -### GetSourceOk - -`func (o *VideoSessionReferrer) GetSourceOk() (*string, bool)` - -GetSourceOk returns a tuple with the Source field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetSource - -`func (o *VideoSessionReferrer) SetSource(v string)` - -SetSource sets Source field to given value. - -### HasSource - -`func (o *VideoSessionReferrer) HasSource() bool` - -HasSource returns a boolean if a field has been set. - -### GetSearchTerm - -`func (o *VideoSessionReferrer) GetSearchTerm() string` - -GetSearchTerm returns the SearchTerm field if non-nil, zero value otherwise. - -### GetSearchTermOk - -`func (o *VideoSessionReferrer) GetSearchTermOk() (*string, bool)` - -GetSearchTermOk returns a tuple with the SearchTerm field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetSearchTerm - -`func (o *VideoSessionReferrer) SetSearchTerm(v string)` - -SetSearchTerm sets SearchTerm field to given value. - -### HasSearchTerm - -`func (o *VideoSessionReferrer) HasSearchTerm() bool` - -HasSearchTerm returns a boolean if a field has been set. - - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/docs/VideoSessionSession.md b/docs/VideoSessionSession.md deleted file mode 100644 index 838b31b..0000000 --- a/docs/VideoSessionSession.md +++ /dev/null @@ -1,134 +0,0 @@ -# VideoSessionSession - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**SessionId** | Pointer to **string** | The unique identifier for the session that you can use to track what happens during it. | [optional] -**LoadedAt** | Pointer to **string** | When the video session started, presented in ISO-8601 format. | [optional] -**EndedAt** | Pointer to **string** | When the video session ended, presented in ISO-8601 format. | [optional] -**Metadata** | Pointer to [**[]Metadata**](Metadata.md) | A list of key value pairs that you use to provide metadata for your video. These pairs can be made dynamic, allowing you to segment your audience. You can also just use the pairs as another way to tag and categorize your videos. | [optional] - -## Methods - -### NewVideoSessionSession - -`func NewVideoSessionSession() *VideoSessionSession` - -NewVideoSessionSession instantiates a new VideoSessionSession object -This constructor will assign default values to properties that have it defined, -and makes sure properties required by API are set, but the set of arguments -will change when the set of required properties is changed - -### NewVideoSessionSessionWithDefaults - -`func NewVideoSessionSessionWithDefaults() *VideoSessionSession` - -NewVideoSessionSessionWithDefaults instantiates a new VideoSessionSession object -This constructor will only assign default values to properties that have it defined, -but it doesn't guarantee that properties required by API are set - -### GetSessionId - -`func (o *VideoSessionSession) GetSessionId() string` - -GetSessionId returns the SessionId field if non-nil, zero value otherwise. - -### GetSessionIdOk - -`func (o *VideoSessionSession) GetSessionIdOk() (*string, bool)` - -GetSessionIdOk returns a tuple with the SessionId field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetSessionId - -`func (o *VideoSessionSession) SetSessionId(v string)` - -SetSessionId sets SessionId field to given value. - -### HasSessionId - -`func (o *VideoSessionSession) HasSessionId() bool` - -HasSessionId returns a boolean if a field has been set. - -### GetLoadedAt - -`func (o *VideoSessionSession) GetLoadedAt() string` - -GetLoadedAt returns the LoadedAt field if non-nil, zero value otherwise. - -### GetLoadedAtOk - -`func (o *VideoSessionSession) GetLoadedAtOk() (*string, bool)` - -GetLoadedAtOk returns a tuple with the LoadedAt field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetLoadedAt - -`func (o *VideoSessionSession) SetLoadedAt(v string)` - -SetLoadedAt sets LoadedAt field to given value. - -### HasLoadedAt - -`func (o *VideoSessionSession) HasLoadedAt() bool` - -HasLoadedAt returns a boolean if a field has been set. - -### GetEndedAt - -`func (o *VideoSessionSession) GetEndedAt() string` - -GetEndedAt returns the EndedAt field if non-nil, zero value otherwise. - -### GetEndedAtOk - -`func (o *VideoSessionSession) GetEndedAtOk() (*string, bool)` - -GetEndedAtOk returns a tuple with the EndedAt field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetEndedAt - -`func (o *VideoSessionSession) SetEndedAt(v string)` - -SetEndedAt sets EndedAt field to given value. - -### HasEndedAt - -`func (o *VideoSessionSession) HasEndedAt() bool` - -HasEndedAt returns a boolean if a field has been set. - -### GetMetadata - -`func (o *VideoSessionSession) GetMetadata() []Metadata` - -GetMetadata returns the Metadata field if non-nil, zero value otherwise. - -### GetMetadataOk - -`func (o *VideoSessionSession) GetMetadataOk() (*[]Metadata, bool)` - -GetMetadataOk returns a tuple with the Metadata field if it's non-nil, zero value otherwise -and a boolean to check if the value has been set. - -### SetMetadata - -`func (o *VideoSessionSession) SetMetadata(v []Metadata)` - -SetMetadata sets Metadata field to given value. - -### HasMetadata - -`func (o *VideoSessionSession) HasMetadata() bool` - -HasMetadata returns a boolean if a field has been set. - - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/model_analytics_aggregated_metrics_response.go b/model_analytics_aggregated_metrics_response.go new file mode 100644 index 0000000..c246401 --- /dev/null +++ b/model_analytics_aggregated_metrics_response.go @@ -0,0 +1,115 @@ +/* + * api.video + * + * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. + * + * API version: 1 + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package apivideosdk + +import ( +//"encoding/json" +) + +// AnalyticsAggregatedMetricsResponse struct for AnalyticsAggregatedMetricsResponse +type AnalyticsAggregatedMetricsResponse struct { + Context AnalyticsAggregatedMetricsResponseContext `json:"context"` + Data float32 `json:"data"` +} + +// NewAnalyticsAggregatedMetricsResponse instantiates a new AnalyticsAggregatedMetricsResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewAnalyticsAggregatedMetricsResponse(context AnalyticsAggregatedMetricsResponseContext, data float32) *AnalyticsAggregatedMetricsResponse { + this := AnalyticsAggregatedMetricsResponse{} + this.Context = context + this.Data = data + return &this +} + +// NewAnalyticsAggregatedMetricsResponseWithDefaults instantiates a new AnalyticsAggregatedMetricsResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewAnalyticsAggregatedMetricsResponseWithDefaults() *AnalyticsAggregatedMetricsResponse { + this := AnalyticsAggregatedMetricsResponse{} + return &this +} + +// GetContext returns the Context field value +func (o *AnalyticsAggregatedMetricsResponse) GetContext() AnalyticsAggregatedMetricsResponseContext { + if o == nil { + var ret AnalyticsAggregatedMetricsResponseContext + return ret + } + + return o.Context +} + +// GetContextOk returns a tuple with the Context field value +// and a boolean to check if the value has been set. +func (o *AnalyticsAggregatedMetricsResponse) GetContextOk() (*AnalyticsAggregatedMetricsResponseContext, bool) { + if o == nil { + return nil, false + } + return &o.Context, true +} + +// SetContext sets field value +func (o *AnalyticsAggregatedMetricsResponse) SetContext(v AnalyticsAggregatedMetricsResponseContext) { + o.Context = v +} + +// GetData returns the Data field value +func (o *AnalyticsAggregatedMetricsResponse) GetData() float32 { + if o == nil { + var ret float32 + return ret + } + + return o.Data +} + +// GetDataOk returns a tuple with the Data field value +// and a boolean to check if the value has been set. +func (o *AnalyticsAggregatedMetricsResponse) GetDataOk() (*float32, bool) { + if o == nil { + return nil, false + } + return &o.Data, true +} + +// SetData sets field value +func (o *AnalyticsAggregatedMetricsResponse) SetData(v float32) { + o.Data = v +} + +type NullableAnalyticsAggregatedMetricsResponse struct { + value *AnalyticsAggregatedMetricsResponse + isSet bool +} + +func (v NullableAnalyticsAggregatedMetricsResponse) Get() *AnalyticsAggregatedMetricsResponse { + return v.value +} + +func (v *NullableAnalyticsAggregatedMetricsResponse) Set(val *AnalyticsAggregatedMetricsResponse) { + v.value = val + v.isSet = true +} + +func (v NullableAnalyticsAggregatedMetricsResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableAnalyticsAggregatedMetricsResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableAnalyticsAggregatedMetricsResponse(val *AnalyticsAggregatedMetricsResponse) *NullableAnalyticsAggregatedMetricsResponse { + return &NullableAnalyticsAggregatedMetricsResponse{value: val, isSet: true} +} diff --git a/model_analytics_aggregated_metrics_response_context.go b/model_analytics_aggregated_metrics_response_context.go new file mode 100644 index 0000000..9234109 --- /dev/null +++ b/model_analytics_aggregated_metrics_response_context.go @@ -0,0 +1,164 @@ +/* + * api.video + * + * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. + * + * API version: 1 + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package apivideosdk + +import ( +//"encoding/json" +) + +// AnalyticsAggregatedMetricsResponseContext struct for AnalyticsAggregatedMetricsResponseContext +type AnalyticsAggregatedMetricsResponseContext struct { + // Returns the metric you selected. + Metric *string `json:"metric,omitempty"` + // Returns the aggregation you selected. + Aggregation *string `json:"aggregation,omitempty"` + Timeframe *AnalyticsAggregatedMetricsResponseContextTimeframe `json:"timeframe,omitempty"` +} + +// NewAnalyticsAggregatedMetricsResponseContext instantiates a new AnalyticsAggregatedMetricsResponseContext object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewAnalyticsAggregatedMetricsResponseContext() *AnalyticsAggregatedMetricsResponseContext { + this := AnalyticsAggregatedMetricsResponseContext{} + return &this +} + +// NewAnalyticsAggregatedMetricsResponseContextWithDefaults instantiates a new AnalyticsAggregatedMetricsResponseContext object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewAnalyticsAggregatedMetricsResponseContextWithDefaults() *AnalyticsAggregatedMetricsResponseContext { + this := AnalyticsAggregatedMetricsResponseContext{} + return &this +} + +// GetMetric returns the Metric field value if set, zero value otherwise. +func (o *AnalyticsAggregatedMetricsResponseContext) GetMetric() string { + if o == nil || o.Metric == nil { + var ret string + return ret + } + return *o.Metric +} + +// GetMetricOk returns a tuple with the Metric field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AnalyticsAggregatedMetricsResponseContext) GetMetricOk() (*string, bool) { + if o == nil || o.Metric == nil { + return nil, false + } + return o.Metric, true +} + +// HasMetric returns a boolean if a field has been set. +func (o *AnalyticsAggregatedMetricsResponseContext) HasMetric() bool { + if o != nil && o.Metric != nil { + return true + } + + return false +} + +// SetMetric gets a reference to the given string and assigns it to the Metric field. +func (o *AnalyticsAggregatedMetricsResponseContext) SetMetric(v string) { + o.Metric = &v +} + +// GetAggregation returns the Aggregation field value if set, zero value otherwise. +func (o *AnalyticsAggregatedMetricsResponseContext) GetAggregation() string { + if o == nil || o.Aggregation == nil { + var ret string + return ret + } + return *o.Aggregation +} + +// GetAggregationOk returns a tuple with the Aggregation field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AnalyticsAggregatedMetricsResponseContext) GetAggregationOk() (*string, bool) { + if o == nil || o.Aggregation == nil { + return nil, false + } + return o.Aggregation, true +} + +// HasAggregation returns a boolean if a field has been set. +func (o *AnalyticsAggregatedMetricsResponseContext) HasAggregation() bool { + if o != nil && o.Aggregation != nil { + return true + } + + return false +} + +// SetAggregation gets a reference to the given string and assigns it to the Aggregation field. +func (o *AnalyticsAggregatedMetricsResponseContext) SetAggregation(v string) { + o.Aggregation = &v +} + +// GetTimeframe returns the Timeframe field value if set, zero value otherwise. +func (o *AnalyticsAggregatedMetricsResponseContext) GetTimeframe() AnalyticsAggregatedMetricsResponseContextTimeframe { + if o == nil || o.Timeframe == nil { + var ret AnalyticsAggregatedMetricsResponseContextTimeframe + return ret + } + return *o.Timeframe +} + +// GetTimeframeOk returns a tuple with the Timeframe field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AnalyticsAggregatedMetricsResponseContext) GetTimeframeOk() (*AnalyticsAggregatedMetricsResponseContextTimeframe, bool) { + if o == nil || o.Timeframe == nil { + return nil, false + } + return o.Timeframe, true +} + +// HasTimeframe returns a boolean if a field has been set. +func (o *AnalyticsAggregatedMetricsResponseContext) HasTimeframe() bool { + if o != nil && o.Timeframe != nil { + return true + } + + return false +} + +// SetTimeframe gets a reference to the given AnalyticsAggregatedMetricsResponseContextTimeframe and assigns it to the Timeframe field. +func (o *AnalyticsAggregatedMetricsResponseContext) SetTimeframe(v AnalyticsAggregatedMetricsResponseContextTimeframe) { + o.Timeframe = &v +} + +type NullableAnalyticsAggregatedMetricsResponseContext struct { + value *AnalyticsAggregatedMetricsResponseContext + isSet bool +} + +func (v NullableAnalyticsAggregatedMetricsResponseContext) Get() *AnalyticsAggregatedMetricsResponseContext { + return v.value +} + +func (v *NullableAnalyticsAggregatedMetricsResponseContext) Set(val *AnalyticsAggregatedMetricsResponseContext) { + v.value = val + v.isSet = true +} + +func (v NullableAnalyticsAggregatedMetricsResponseContext) IsSet() bool { + return v.isSet +} + +func (v *NullableAnalyticsAggregatedMetricsResponseContext) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableAnalyticsAggregatedMetricsResponseContext(val *AnalyticsAggregatedMetricsResponseContext) *NullableAnalyticsAggregatedMetricsResponseContext { + return &NullableAnalyticsAggregatedMetricsResponseContext{value: val, isSet: true} +} diff --git a/model_analytics_aggregated_metrics_response_context_timeframe.go b/model_analytics_aggregated_metrics_response_context_timeframe.go new file mode 100644 index 0000000..f19102f --- /dev/null +++ b/model_analytics_aggregated_metrics_response_context_timeframe.go @@ -0,0 +1,131 @@ +/* + * api.video + * + * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. + * + * API version: 1 + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package apivideosdk + +import ( +//"encoding/json" +) + +// AnalyticsAggregatedMetricsResponseContextTimeframe Returns the starting and ending date-times of the period you want analytics for. +type AnalyticsAggregatedMetricsResponseContextTimeframe struct { + // Returns the starting date-time of the period you want analytics for in ATOM date-time format. + From *string `json:"from,omitempty"` + // Returns the starting date-time of the period you want analytics for in ATOM date-time format. + To *string `json:"to,omitempty"` +} + +// NewAnalyticsAggregatedMetricsResponseContextTimeframe instantiates a new AnalyticsAggregatedMetricsResponseContextTimeframe object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewAnalyticsAggregatedMetricsResponseContextTimeframe() *AnalyticsAggregatedMetricsResponseContextTimeframe { + this := AnalyticsAggregatedMetricsResponseContextTimeframe{} + return &this +} + +// NewAnalyticsAggregatedMetricsResponseContextTimeframeWithDefaults instantiates a new AnalyticsAggregatedMetricsResponseContextTimeframe object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewAnalyticsAggregatedMetricsResponseContextTimeframeWithDefaults() *AnalyticsAggregatedMetricsResponseContextTimeframe { + this := AnalyticsAggregatedMetricsResponseContextTimeframe{} + return &this +} + +// GetFrom returns the From field value if set, zero value otherwise. +func (o *AnalyticsAggregatedMetricsResponseContextTimeframe) GetFrom() string { + if o == nil || o.From == nil { + var ret string + return ret + } + return *o.From +} + +// GetFromOk returns a tuple with the From field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AnalyticsAggregatedMetricsResponseContextTimeframe) GetFromOk() (*string, bool) { + if o == nil || o.From == nil { + return nil, false + } + return o.From, true +} + +// HasFrom returns a boolean if a field has been set. +func (o *AnalyticsAggregatedMetricsResponseContextTimeframe) HasFrom() bool { + if o != nil && o.From != nil { + return true + } + + return false +} + +// SetFrom gets a reference to the given string and assigns it to the From field. +func (o *AnalyticsAggregatedMetricsResponseContextTimeframe) SetFrom(v string) { + o.From = &v +} + +// GetTo returns the To field value if set, zero value otherwise. +func (o *AnalyticsAggregatedMetricsResponseContextTimeframe) GetTo() string { + if o == nil || o.To == nil { + var ret string + return ret + } + return *o.To +} + +// GetToOk returns a tuple with the To field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AnalyticsAggregatedMetricsResponseContextTimeframe) GetToOk() (*string, bool) { + if o == nil || o.To == nil { + return nil, false + } + return o.To, true +} + +// HasTo returns a boolean if a field has been set. +func (o *AnalyticsAggregatedMetricsResponseContextTimeframe) HasTo() bool { + if o != nil && o.To != nil { + return true + } + + return false +} + +// SetTo gets a reference to the given string and assigns it to the To field. +func (o *AnalyticsAggregatedMetricsResponseContextTimeframe) SetTo(v string) { + o.To = &v +} + +type NullableAnalyticsAggregatedMetricsResponseContextTimeframe struct { + value *AnalyticsAggregatedMetricsResponseContextTimeframe + isSet bool +} + +func (v NullableAnalyticsAggregatedMetricsResponseContextTimeframe) Get() *AnalyticsAggregatedMetricsResponseContextTimeframe { + return v.value +} + +func (v *NullableAnalyticsAggregatedMetricsResponseContextTimeframe) Set(val *AnalyticsAggregatedMetricsResponseContextTimeframe) { + v.value = val + v.isSet = true +} + +func (v NullableAnalyticsAggregatedMetricsResponseContextTimeframe) IsSet() bool { + return v.isSet +} + +func (v *NullableAnalyticsAggregatedMetricsResponseContextTimeframe) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableAnalyticsAggregatedMetricsResponseContextTimeframe(val *AnalyticsAggregatedMetricsResponseContextTimeframe) *NullableAnalyticsAggregatedMetricsResponseContextTimeframe { + return &NullableAnalyticsAggregatedMetricsResponseContextTimeframe{value: val, isSet: true} +} diff --git a/model_analytics_metrics_breakdown_response.go b/model_analytics_metrics_breakdown_response.go new file mode 100644 index 0000000..d06551b --- /dev/null +++ b/model_analytics_metrics_breakdown_response.go @@ -0,0 +1,142 @@ +/* + * api.video + * + * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. + * + * API version: 1 + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package apivideosdk + +import ( +//"encoding/json" +) + +// AnalyticsMetricsBreakdownResponse struct for AnalyticsMetricsBreakdownResponse +type AnalyticsMetricsBreakdownResponse struct { + Context AnalyticsMetricsBreakdownResponseContext `json:"context"` + // Returns an array of dimensions and their respective metrics. + Data []AnalyticsMetricsBreakdownResponseData `json:"data"` + Pagination Pagination `json:"pagination"` +} + +// NewAnalyticsMetricsBreakdownResponse instantiates a new AnalyticsMetricsBreakdownResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewAnalyticsMetricsBreakdownResponse(context AnalyticsMetricsBreakdownResponseContext, data []AnalyticsMetricsBreakdownResponseData, pagination Pagination) *AnalyticsMetricsBreakdownResponse { + this := AnalyticsMetricsBreakdownResponse{} + this.Context = context + this.Data = data + this.Pagination = pagination + return &this +} + +// NewAnalyticsMetricsBreakdownResponseWithDefaults instantiates a new AnalyticsMetricsBreakdownResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewAnalyticsMetricsBreakdownResponseWithDefaults() *AnalyticsMetricsBreakdownResponse { + this := AnalyticsMetricsBreakdownResponse{} + return &this +} + +// GetContext returns the Context field value +func (o *AnalyticsMetricsBreakdownResponse) GetContext() AnalyticsMetricsBreakdownResponseContext { + if o == nil { + var ret AnalyticsMetricsBreakdownResponseContext + return ret + } + + return o.Context +} + +// GetContextOk returns a tuple with the Context field value +// and a boolean to check if the value has been set. +func (o *AnalyticsMetricsBreakdownResponse) GetContextOk() (*AnalyticsMetricsBreakdownResponseContext, bool) { + if o == nil { + return nil, false + } + return &o.Context, true +} + +// SetContext sets field value +func (o *AnalyticsMetricsBreakdownResponse) SetContext(v AnalyticsMetricsBreakdownResponseContext) { + o.Context = v +} + +// GetData returns the Data field value +func (o *AnalyticsMetricsBreakdownResponse) GetData() []AnalyticsMetricsBreakdownResponseData { + if o == nil { + var ret []AnalyticsMetricsBreakdownResponseData + return ret + } + + return o.Data +} + +// GetDataOk returns a tuple with the Data field value +// and a boolean to check if the value has been set. +func (o *AnalyticsMetricsBreakdownResponse) GetDataOk() (*[]AnalyticsMetricsBreakdownResponseData, bool) { + if o == nil { + return nil, false + } + return &o.Data, true +} + +// SetData sets field value +func (o *AnalyticsMetricsBreakdownResponse) SetData(v []AnalyticsMetricsBreakdownResponseData) { + o.Data = v +} + +// GetPagination returns the Pagination field value +func (o *AnalyticsMetricsBreakdownResponse) GetPagination() Pagination { + if o == nil { + var ret Pagination + return ret + } + + return o.Pagination +} + +// GetPaginationOk returns a tuple with the Pagination field value +// and a boolean to check if the value has been set. +func (o *AnalyticsMetricsBreakdownResponse) GetPaginationOk() (*Pagination, bool) { + if o == nil { + return nil, false + } + return &o.Pagination, true +} + +// SetPagination sets field value +func (o *AnalyticsMetricsBreakdownResponse) SetPagination(v Pagination) { + o.Pagination = v +} + +type NullableAnalyticsMetricsBreakdownResponse struct { + value *AnalyticsMetricsBreakdownResponse + isSet bool +} + +func (v NullableAnalyticsMetricsBreakdownResponse) Get() *AnalyticsMetricsBreakdownResponse { + return v.value +} + +func (v *NullableAnalyticsMetricsBreakdownResponse) Set(val *AnalyticsMetricsBreakdownResponse) { + v.value = val + v.isSet = true +} + +func (v NullableAnalyticsMetricsBreakdownResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableAnalyticsMetricsBreakdownResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableAnalyticsMetricsBreakdownResponse(val *AnalyticsMetricsBreakdownResponse) *NullableAnalyticsMetricsBreakdownResponse { + return &NullableAnalyticsMetricsBreakdownResponse{value: val, isSet: true} +} diff --git a/model_analytics_metrics_breakdown_response_context.go b/model_analytics_metrics_breakdown_response_context.go new file mode 100644 index 0000000..479fcc5 --- /dev/null +++ b/model_analytics_metrics_breakdown_response_context.go @@ -0,0 +1,164 @@ +/* + * api.video + * + * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. + * + * API version: 1 + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package apivideosdk + +import ( +//"encoding/json" +) + +// AnalyticsMetricsBreakdownResponseContext struct for AnalyticsMetricsBreakdownResponseContext +type AnalyticsMetricsBreakdownResponseContext struct { + // Returns the metric you selected. + Metric *string `json:"metric,omitempty"` + // Returns the dimension you selected. + Breakdown *string `json:"breakdown,omitempty"` + Timeframe *AnalyticsAggregatedMetricsResponseContextTimeframe `json:"timeframe,omitempty"` +} + +// NewAnalyticsMetricsBreakdownResponseContext instantiates a new AnalyticsMetricsBreakdownResponseContext object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewAnalyticsMetricsBreakdownResponseContext() *AnalyticsMetricsBreakdownResponseContext { + this := AnalyticsMetricsBreakdownResponseContext{} + return &this +} + +// NewAnalyticsMetricsBreakdownResponseContextWithDefaults instantiates a new AnalyticsMetricsBreakdownResponseContext object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewAnalyticsMetricsBreakdownResponseContextWithDefaults() *AnalyticsMetricsBreakdownResponseContext { + this := AnalyticsMetricsBreakdownResponseContext{} + return &this +} + +// GetMetric returns the Metric field value if set, zero value otherwise. +func (o *AnalyticsMetricsBreakdownResponseContext) GetMetric() string { + if o == nil || o.Metric == nil { + var ret string + return ret + } + return *o.Metric +} + +// GetMetricOk returns a tuple with the Metric field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AnalyticsMetricsBreakdownResponseContext) GetMetricOk() (*string, bool) { + if o == nil || o.Metric == nil { + return nil, false + } + return o.Metric, true +} + +// HasMetric returns a boolean if a field has been set. +func (o *AnalyticsMetricsBreakdownResponseContext) HasMetric() bool { + if o != nil && o.Metric != nil { + return true + } + + return false +} + +// SetMetric gets a reference to the given string and assigns it to the Metric field. +func (o *AnalyticsMetricsBreakdownResponseContext) SetMetric(v string) { + o.Metric = &v +} + +// GetBreakdown returns the Breakdown field value if set, zero value otherwise. +func (o *AnalyticsMetricsBreakdownResponseContext) GetBreakdown() string { + if o == nil || o.Breakdown == nil { + var ret string + return ret + } + return *o.Breakdown +} + +// GetBreakdownOk returns a tuple with the Breakdown field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AnalyticsMetricsBreakdownResponseContext) GetBreakdownOk() (*string, bool) { + if o == nil || o.Breakdown == nil { + return nil, false + } + return o.Breakdown, true +} + +// HasBreakdown returns a boolean if a field has been set. +func (o *AnalyticsMetricsBreakdownResponseContext) HasBreakdown() bool { + if o != nil && o.Breakdown != nil { + return true + } + + return false +} + +// SetBreakdown gets a reference to the given string and assigns it to the Breakdown field. +func (o *AnalyticsMetricsBreakdownResponseContext) SetBreakdown(v string) { + o.Breakdown = &v +} + +// GetTimeframe returns the Timeframe field value if set, zero value otherwise. +func (o *AnalyticsMetricsBreakdownResponseContext) GetTimeframe() AnalyticsAggregatedMetricsResponseContextTimeframe { + if o == nil || o.Timeframe == nil { + var ret AnalyticsAggregatedMetricsResponseContextTimeframe + return ret + } + return *o.Timeframe +} + +// GetTimeframeOk returns a tuple with the Timeframe field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AnalyticsMetricsBreakdownResponseContext) GetTimeframeOk() (*AnalyticsAggregatedMetricsResponseContextTimeframe, bool) { + if o == nil || o.Timeframe == nil { + return nil, false + } + return o.Timeframe, true +} + +// HasTimeframe returns a boolean if a field has been set. +func (o *AnalyticsMetricsBreakdownResponseContext) HasTimeframe() bool { + if o != nil && o.Timeframe != nil { + return true + } + + return false +} + +// SetTimeframe gets a reference to the given AnalyticsAggregatedMetricsResponseContextTimeframe and assigns it to the Timeframe field. +func (o *AnalyticsMetricsBreakdownResponseContext) SetTimeframe(v AnalyticsAggregatedMetricsResponseContextTimeframe) { + o.Timeframe = &v +} + +type NullableAnalyticsMetricsBreakdownResponseContext struct { + value *AnalyticsMetricsBreakdownResponseContext + isSet bool +} + +func (v NullableAnalyticsMetricsBreakdownResponseContext) Get() *AnalyticsMetricsBreakdownResponseContext { + return v.value +} + +func (v *NullableAnalyticsMetricsBreakdownResponseContext) Set(val *AnalyticsMetricsBreakdownResponseContext) { + v.value = val + v.isSet = true +} + +func (v NullableAnalyticsMetricsBreakdownResponseContext) IsSet() bool { + return v.isSet +} + +func (v *NullableAnalyticsMetricsBreakdownResponseContext) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableAnalyticsMetricsBreakdownResponseContext(val *AnalyticsMetricsBreakdownResponseContext) *NullableAnalyticsMetricsBreakdownResponseContext { + return &NullableAnalyticsMetricsBreakdownResponseContext{value: val, isSet: true} +} diff --git a/model_analytics_metrics_breakdown_response_data.go b/model_analytics_metrics_breakdown_response_data.go new file mode 100644 index 0000000..a280e91 --- /dev/null +++ b/model_analytics_metrics_breakdown_response_data.go @@ -0,0 +1,131 @@ +/* + * api.video + * + * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. + * + * API version: 1 + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package apivideosdk + +import ( +//"encoding/json" +) + +// AnalyticsMetricsBreakdownResponseData struct for AnalyticsMetricsBreakdownResponseData +type AnalyticsMetricsBreakdownResponseData struct { + // Returns a specific value for the dimension you selected, based on the data. For example if you select `continent` as a dimension, then `dimensionValue` returns values like `EU` or \"AZ\". + DimensionValue *string `json:"dimensionValue,omitempty"` + // Returns the data for a specific dimension value. + MetricValue *float32 `json:"metricValue,omitempty"` +} + +// NewAnalyticsMetricsBreakdownResponseData instantiates a new AnalyticsMetricsBreakdownResponseData object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewAnalyticsMetricsBreakdownResponseData() *AnalyticsMetricsBreakdownResponseData { + this := AnalyticsMetricsBreakdownResponseData{} + return &this +} + +// NewAnalyticsMetricsBreakdownResponseDataWithDefaults instantiates a new AnalyticsMetricsBreakdownResponseData object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewAnalyticsMetricsBreakdownResponseDataWithDefaults() *AnalyticsMetricsBreakdownResponseData { + this := AnalyticsMetricsBreakdownResponseData{} + return &this +} + +// GetDimensionValue returns the DimensionValue field value if set, zero value otherwise. +func (o *AnalyticsMetricsBreakdownResponseData) GetDimensionValue() string { + if o == nil || o.DimensionValue == nil { + var ret string + return ret + } + return *o.DimensionValue +} + +// GetDimensionValueOk returns a tuple with the DimensionValue field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AnalyticsMetricsBreakdownResponseData) GetDimensionValueOk() (*string, bool) { + if o == nil || o.DimensionValue == nil { + return nil, false + } + return o.DimensionValue, true +} + +// HasDimensionValue returns a boolean if a field has been set. +func (o *AnalyticsMetricsBreakdownResponseData) HasDimensionValue() bool { + if o != nil && o.DimensionValue != nil { + return true + } + + return false +} + +// SetDimensionValue gets a reference to the given string and assigns it to the DimensionValue field. +func (o *AnalyticsMetricsBreakdownResponseData) SetDimensionValue(v string) { + o.DimensionValue = &v +} + +// GetMetricValue returns the MetricValue field value if set, zero value otherwise. +func (o *AnalyticsMetricsBreakdownResponseData) GetMetricValue() float32 { + if o == nil || o.MetricValue == nil { + var ret float32 + return ret + } + return *o.MetricValue +} + +// GetMetricValueOk returns a tuple with the MetricValue field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AnalyticsMetricsBreakdownResponseData) GetMetricValueOk() (*float32, bool) { + if o == nil || o.MetricValue == nil { + return nil, false + } + return o.MetricValue, true +} + +// HasMetricValue returns a boolean if a field has been set. +func (o *AnalyticsMetricsBreakdownResponseData) HasMetricValue() bool { + if o != nil && o.MetricValue != nil { + return true + } + + return false +} + +// SetMetricValue gets a reference to the given float32 and assigns it to the MetricValue field. +func (o *AnalyticsMetricsBreakdownResponseData) SetMetricValue(v float32) { + o.MetricValue = &v +} + +type NullableAnalyticsMetricsBreakdownResponseData struct { + value *AnalyticsMetricsBreakdownResponseData + isSet bool +} + +func (v NullableAnalyticsMetricsBreakdownResponseData) Get() *AnalyticsMetricsBreakdownResponseData { + return v.value +} + +func (v *NullableAnalyticsMetricsBreakdownResponseData) Set(val *AnalyticsMetricsBreakdownResponseData) { + v.value = val + v.isSet = true +} + +func (v NullableAnalyticsMetricsBreakdownResponseData) IsSet() bool { + return v.isSet +} + +func (v *NullableAnalyticsMetricsBreakdownResponseData) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableAnalyticsMetricsBreakdownResponseData(val *AnalyticsMetricsBreakdownResponseData) *NullableAnalyticsMetricsBreakdownResponseData { + return &NullableAnalyticsMetricsBreakdownResponseData{value: val, isSet: true} +} diff --git a/model_analytics_metrics_over_time_response.go b/model_analytics_metrics_over_time_response.go new file mode 100644 index 0000000..eb2c48c --- /dev/null +++ b/model_analytics_metrics_over_time_response.go @@ -0,0 +1,142 @@ +/* + * api.video + * + * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. + * + * API version: 1 + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package apivideosdk + +import ( +//"encoding/json" +) + +// AnalyticsMetricsOverTimeResponse struct for AnalyticsMetricsOverTimeResponse +type AnalyticsMetricsOverTimeResponse struct { + Context AnalyticsMetricsOverTimeResponseContext `json:"context"` + // Returns an array of metrics and the timestamps . + Data []AnalyticsMetricsOverTimeResponseData `json:"data"` + Pagination Pagination `json:"pagination"` +} + +// NewAnalyticsMetricsOverTimeResponse instantiates a new AnalyticsMetricsOverTimeResponse object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewAnalyticsMetricsOverTimeResponse(context AnalyticsMetricsOverTimeResponseContext, data []AnalyticsMetricsOverTimeResponseData, pagination Pagination) *AnalyticsMetricsOverTimeResponse { + this := AnalyticsMetricsOverTimeResponse{} + this.Context = context + this.Data = data + this.Pagination = pagination + return &this +} + +// NewAnalyticsMetricsOverTimeResponseWithDefaults instantiates a new AnalyticsMetricsOverTimeResponse object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewAnalyticsMetricsOverTimeResponseWithDefaults() *AnalyticsMetricsOverTimeResponse { + this := AnalyticsMetricsOverTimeResponse{} + return &this +} + +// GetContext returns the Context field value +func (o *AnalyticsMetricsOverTimeResponse) GetContext() AnalyticsMetricsOverTimeResponseContext { + if o == nil { + var ret AnalyticsMetricsOverTimeResponseContext + return ret + } + + return o.Context +} + +// GetContextOk returns a tuple with the Context field value +// and a boolean to check if the value has been set. +func (o *AnalyticsMetricsOverTimeResponse) GetContextOk() (*AnalyticsMetricsOverTimeResponseContext, bool) { + if o == nil { + return nil, false + } + return &o.Context, true +} + +// SetContext sets field value +func (o *AnalyticsMetricsOverTimeResponse) SetContext(v AnalyticsMetricsOverTimeResponseContext) { + o.Context = v +} + +// GetData returns the Data field value +func (o *AnalyticsMetricsOverTimeResponse) GetData() []AnalyticsMetricsOverTimeResponseData { + if o == nil { + var ret []AnalyticsMetricsOverTimeResponseData + return ret + } + + return o.Data +} + +// GetDataOk returns a tuple with the Data field value +// and a boolean to check if the value has been set. +func (o *AnalyticsMetricsOverTimeResponse) GetDataOk() (*[]AnalyticsMetricsOverTimeResponseData, bool) { + if o == nil { + return nil, false + } + return &o.Data, true +} + +// SetData sets field value +func (o *AnalyticsMetricsOverTimeResponse) SetData(v []AnalyticsMetricsOverTimeResponseData) { + o.Data = v +} + +// GetPagination returns the Pagination field value +func (o *AnalyticsMetricsOverTimeResponse) GetPagination() Pagination { + if o == nil { + var ret Pagination + return ret + } + + return o.Pagination +} + +// GetPaginationOk returns a tuple with the Pagination field value +// and a boolean to check if the value has been set. +func (o *AnalyticsMetricsOverTimeResponse) GetPaginationOk() (*Pagination, bool) { + if o == nil { + return nil, false + } + return &o.Pagination, true +} + +// SetPagination sets field value +func (o *AnalyticsMetricsOverTimeResponse) SetPagination(v Pagination) { + o.Pagination = v +} + +type NullableAnalyticsMetricsOverTimeResponse struct { + value *AnalyticsMetricsOverTimeResponse + isSet bool +} + +func (v NullableAnalyticsMetricsOverTimeResponse) Get() *AnalyticsMetricsOverTimeResponse { + return v.value +} + +func (v *NullableAnalyticsMetricsOverTimeResponse) Set(val *AnalyticsMetricsOverTimeResponse) { + v.value = val + v.isSet = true +} + +func (v NullableAnalyticsMetricsOverTimeResponse) IsSet() bool { + return v.isSet +} + +func (v *NullableAnalyticsMetricsOverTimeResponse) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableAnalyticsMetricsOverTimeResponse(val *AnalyticsMetricsOverTimeResponse) *NullableAnalyticsMetricsOverTimeResponse { + return &NullableAnalyticsMetricsOverTimeResponse{value: val, isSet: true} +} diff --git a/model_analytics_metrics_over_time_response_context.go b/model_analytics_metrics_over_time_response_context.go new file mode 100644 index 0000000..7e23f32 --- /dev/null +++ b/model_analytics_metrics_over_time_response_context.go @@ -0,0 +1,164 @@ +/* + * api.video + * + * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. + * + * API version: 1 + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package apivideosdk + +import ( +//"encoding/json" +) + +// AnalyticsMetricsOverTimeResponseContext struct for AnalyticsMetricsOverTimeResponseContext +type AnalyticsMetricsOverTimeResponseContext struct { + // Returns the metric you selected. + Metric *string `json:"metric,omitempty"` + // Returns the interval you selected. + Interval *string `json:"interval,omitempty"` + Timeframe *AnalyticsAggregatedMetricsResponseContextTimeframe `json:"timeframe,omitempty"` +} + +// NewAnalyticsMetricsOverTimeResponseContext instantiates a new AnalyticsMetricsOverTimeResponseContext object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewAnalyticsMetricsOverTimeResponseContext() *AnalyticsMetricsOverTimeResponseContext { + this := AnalyticsMetricsOverTimeResponseContext{} + return &this +} + +// NewAnalyticsMetricsOverTimeResponseContextWithDefaults instantiates a new AnalyticsMetricsOverTimeResponseContext object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewAnalyticsMetricsOverTimeResponseContextWithDefaults() *AnalyticsMetricsOverTimeResponseContext { + this := AnalyticsMetricsOverTimeResponseContext{} + return &this +} + +// GetMetric returns the Metric field value if set, zero value otherwise. +func (o *AnalyticsMetricsOverTimeResponseContext) GetMetric() string { + if o == nil || o.Metric == nil { + var ret string + return ret + } + return *o.Metric +} + +// GetMetricOk returns a tuple with the Metric field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AnalyticsMetricsOverTimeResponseContext) GetMetricOk() (*string, bool) { + if o == nil || o.Metric == nil { + return nil, false + } + return o.Metric, true +} + +// HasMetric returns a boolean if a field has been set. +func (o *AnalyticsMetricsOverTimeResponseContext) HasMetric() bool { + if o != nil && o.Metric != nil { + return true + } + + return false +} + +// SetMetric gets a reference to the given string and assigns it to the Metric field. +func (o *AnalyticsMetricsOverTimeResponseContext) SetMetric(v string) { + o.Metric = &v +} + +// GetInterval returns the Interval field value if set, zero value otherwise. +func (o *AnalyticsMetricsOverTimeResponseContext) GetInterval() string { + if o == nil || o.Interval == nil { + var ret string + return ret + } + return *o.Interval +} + +// GetIntervalOk returns a tuple with the Interval field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AnalyticsMetricsOverTimeResponseContext) GetIntervalOk() (*string, bool) { + if o == nil || o.Interval == nil { + return nil, false + } + return o.Interval, true +} + +// HasInterval returns a boolean if a field has been set. +func (o *AnalyticsMetricsOverTimeResponseContext) HasInterval() bool { + if o != nil && o.Interval != nil { + return true + } + + return false +} + +// SetInterval gets a reference to the given string and assigns it to the Interval field. +func (o *AnalyticsMetricsOverTimeResponseContext) SetInterval(v string) { + o.Interval = &v +} + +// GetTimeframe returns the Timeframe field value if set, zero value otherwise. +func (o *AnalyticsMetricsOverTimeResponseContext) GetTimeframe() AnalyticsAggregatedMetricsResponseContextTimeframe { + if o == nil || o.Timeframe == nil { + var ret AnalyticsAggregatedMetricsResponseContextTimeframe + return ret + } + return *o.Timeframe +} + +// GetTimeframeOk returns a tuple with the Timeframe field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AnalyticsMetricsOverTimeResponseContext) GetTimeframeOk() (*AnalyticsAggregatedMetricsResponseContextTimeframe, bool) { + if o == nil || o.Timeframe == nil { + return nil, false + } + return o.Timeframe, true +} + +// HasTimeframe returns a boolean if a field has been set. +func (o *AnalyticsMetricsOverTimeResponseContext) HasTimeframe() bool { + if o != nil && o.Timeframe != nil { + return true + } + + return false +} + +// SetTimeframe gets a reference to the given AnalyticsAggregatedMetricsResponseContextTimeframe and assigns it to the Timeframe field. +func (o *AnalyticsMetricsOverTimeResponseContext) SetTimeframe(v AnalyticsAggregatedMetricsResponseContextTimeframe) { + o.Timeframe = &v +} + +type NullableAnalyticsMetricsOverTimeResponseContext struct { + value *AnalyticsMetricsOverTimeResponseContext + isSet bool +} + +func (v NullableAnalyticsMetricsOverTimeResponseContext) Get() *AnalyticsMetricsOverTimeResponseContext { + return v.value +} + +func (v *NullableAnalyticsMetricsOverTimeResponseContext) Set(val *AnalyticsMetricsOverTimeResponseContext) { + v.value = val + v.isSet = true +} + +func (v NullableAnalyticsMetricsOverTimeResponseContext) IsSet() bool { + return v.isSet +} + +func (v *NullableAnalyticsMetricsOverTimeResponseContext) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableAnalyticsMetricsOverTimeResponseContext(val *AnalyticsMetricsOverTimeResponseContext) *NullableAnalyticsMetricsOverTimeResponseContext { + return &NullableAnalyticsMetricsOverTimeResponseContext{value: val, isSet: true} +} diff --git a/model_analytics_metrics_over_time_response_data.go b/model_analytics_metrics_over_time_response_data.go new file mode 100644 index 0000000..f815902 --- /dev/null +++ b/model_analytics_metrics_over_time_response_data.go @@ -0,0 +1,131 @@ +/* + * api.video + * + * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. + * + * API version: 1 + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package apivideosdk + +import ( +//"encoding/json" +) + +// AnalyticsMetricsOverTimeResponseData struct for AnalyticsMetricsOverTimeResponseData +type AnalyticsMetricsOverTimeResponseData struct { + // Returns the timestamp of the event that belongs to a specific metric in ATOM date-time format. For example, if you set `play` with an `hour` interval in your request, then `emittedAt` returns the hourly timestamps of every play event within the timeframe you defined. + EmittedAt *string `json:"emittedAt,omitempty"` + // Returns the data for a specific metric value. + MetricValue *float32 `json:"metricValue,omitempty"` +} + +// NewAnalyticsMetricsOverTimeResponseData instantiates a new AnalyticsMetricsOverTimeResponseData object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewAnalyticsMetricsOverTimeResponseData() *AnalyticsMetricsOverTimeResponseData { + this := AnalyticsMetricsOverTimeResponseData{} + return &this +} + +// NewAnalyticsMetricsOverTimeResponseDataWithDefaults instantiates a new AnalyticsMetricsOverTimeResponseData object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewAnalyticsMetricsOverTimeResponseDataWithDefaults() *AnalyticsMetricsOverTimeResponseData { + this := AnalyticsMetricsOverTimeResponseData{} + return &this +} + +// GetEmittedAt returns the EmittedAt field value if set, zero value otherwise. +func (o *AnalyticsMetricsOverTimeResponseData) GetEmittedAt() string { + if o == nil || o.EmittedAt == nil { + var ret string + return ret + } + return *o.EmittedAt +} + +// GetEmittedAtOk returns a tuple with the EmittedAt field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AnalyticsMetricsOverTimeResponseData) GetEmittedAtOk() (*string, bool) { + if o == nil || o.EmittedAt == nil { + return nil, false + } + return o.EmittedAt, true +} + +// HasEmittedAt returns a boolean if a field has been set. +func (o *AnalyticsMetricsOverTimeResponseData) HasEmittedAt() bool { + if o != nil && o.EmittedAt != nil { + return true + } + + return false +} + +// SetEmittedAt gets a reference to the given string and assigns it to the EmittedAt field. +func (o *AnalyticsMetricsOverTimeResponseData) SetEmittedAt(v string) { + o.EmittedAt = &v +} + +// GetMetricValue returns the MetricValue field value if set, zero value otherwise. +func (o *AnalyticsMetricsOverTimeResponseData) GetMetricValue() float32 { + if o == nil || o.MetricValue == nil { + var ret float32 + return ret + } + return *o.MetricValue +} + +// GetMetricValueOk returns a tuple with the MetricValue field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *AnalyticsMetricsOverTimeResponseData) GetMetricValueOk() (*float32, bool) { + if o == nil || o.MetricValue == nil { + return nil, false + } + return o.MetricValue, true +} + +// HasMetricValue returns a boolean if a field has been set. +func (o *AnalyticsMetricsOverTimeResponseData) HasMetricValue() bool { + if o != nil && o.MetricValue != nil { + return true + } + + return false +} + +// SetMetricValue gets a reference to the given float32 and assigns it to the MetricValue field. +func (o *AnalyticsMetricsOverTimeResponseData) SetMetricValue(v float32) { + o.MetricValue = &v +} + +type NullableAnalyticsMetricsOverTimeResponseData struct { + value *AnalyticsMetricsOverTimeResponseData + isSet bool +} + +func (v NullableAnalyticsMetricsOverTimeResponseData) Get() *AnalyticsMetricsOverTimeResponseData { + return v.value +} + +func (v *NullableAnalyticsMetricsOverTimeResponseData) Set(val *AnalyticsMetricsOverTimeResponseData) { + v.value = val + v.isSet = true +} + +func (v NullableAnalyticsMetricsOverTimeResponseData) IsSet() bool { + return v.isSet +} + +func (v *NullableAnalyticsMetricsOverTimeResponseData) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableAnalyticsMetricsOverTimeResponseData(val *AnalyticsMetricsOverTimeResponseData) *NullableAnalyticsMetricsOverTimeResponseData { + return &NullableAnalyticsMetricsOverTimeResponseData{value: val, isSet: true} +} diff --git a/model_filter_by.go b/model_filter_by.go new file mode 100644 index 0000000..aca134e --- /dev/null +++ b/model_filter_by.go @@ -0,0 +1,334 @@ +/* + * api.video + * + * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. + * + * API version: 1 + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package apivideosdk + +import ( +//"encoding/json" +) + +// FilterBy struct for FilterBy +type FilterBy struct { + // Returns analytics based on the unique identifiers of a video or a live stream. + MediaId *[]string `json:"mediaId,omitempty"` + MediaType *string `json:"mediaType,omitempty"` + // Returns analytics based on the viewers' continent. The list of supported continents names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `EU`. + Continent *[]string `json:"continent,omitempty"` + // Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `FR`. + Country *[]string `json:"country,omitempty"` + // Returns analytics based on the type of device used by the viewers. Response values can include: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. + DeviceType *[]string `json:"deviceType,omitempty"` + // Returns analytics based on the operating system used by the viewers. Response values can include `windows`, `mac osx`, `android`, `ios`, `linux`. + OperatingSystem *[]string `json:"operatingSystem,omitempty"` + // Returns analytics based on the browser used by the viewers. Response values can include `chrome`, `firefox`, `edge`, `opera`. + Browser *[]string `json:"browser,omitempty"` + // Returns analytics for videos using this tag. This filter only accepts a single value and is case sensitive. Read more about tagging your videos [here](https://docs.api.video/vod/tags-metadata). + Tag *string `json:"tag,omitempty"` +} + +// NewFilterBy instantiates a new FilterBy object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFilterBy() *FilterBy { + this := FilterBy{} + return &this +} + +// NewFilterByWithDefaults instantiates a new FilterBy object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFilterByWithDefaults() *FilterBy { + this := FilterBy{} + return &this +} + +// GetMediaId returns the MediaId field value if set, zero value otherwise. +func (o *FilterBy) GetMediaId() []string { + if o == nil || o.MediaId == nil { + var ret []string + return ret + } + return *o.MediaId +} + +// GetMediaIdOk returns a tuple with the MediaId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy) GetMediaIdOk() (*[]string, bool) { + if o == nil || o.MediaId == nil { + return nil, false + } + return o.MediaId, true +} + +// HasMediaId returns a boolean if a field has been set. +func (o *FilterBy) HasMediaId() bool { + if o != nil && o.MediaId != nil { + return true + } + + return false +} + +// SetMediaId gets a reference to the given []string and assigns it to the MediaId field. +func (o *FilterBy) SetMediaId(v []string) { + o.MediaId = &v +} + +// GetMediaType returns the MediaType field value if set, zero value otherwise. +func (o *FilterBy) GetMediaType() string { + if o == nil || o.MediaType == nil { + var ret string + return ret + } + return *o.MediaType +} + +// GetMediaTypeOk returns a tuple with the MediaType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy) GetMediaTypeOk() (*string, bool) { + if o == nil || o.MediaType == nil { + return nil, false + } + return o.MediaType, true +} + +// HasMediaType returns a boolean if a field has been set. +func (o *FilterBy) HasMediaType() bool { + if o != nil && o.MediaType != nil { + return true + } + + return false +} + +// SetMediaType gets a reference to the given string and assigns it to the MediaType field. +func (o *FilterBy) SetMediaType(v string) { + o.MediaType = &v +} + +// GetContinent returns the Continent field value if set, zero value otherwise. +func (o *FilterBy) GetContinent() []string { + if o == nil || o.Continent == nil { + var ret []string + return ret + } + return *o.Continent +} + +// GetContinentOk returns a tuple with the Continent field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy) GetContinentOk() (*[]string, bool) { + if o == nil || o.Continent == nil { + return nil, false + } + return o.Continent, true +} + +// HasContinent returns a boolean if a field has been set. +func (o *FilterBy) HasContinent() bool { + if o != nil && o.Continent != nil { + return true + } + + return false +} + +// SetContinent gets a reference to the given []string and assigns it to the Continent field. +func (o *FilterBy) SetContinent(v []string) { + o.Continent = &v +} + +// GetCountry returns the Country field value if set, zero value otherwise. +func (o *FilterBy) GetCountry() []string { + if o == nil || o.Country == nil { + var ret []string + return ret + } + return *o.Country +} + +// GetCountryOk returns a tuple with the Country field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy) GetCountryOk() (*[]string, bool) { + if o == nil || o.Country == nil { + return nil, false + } + return o.Country, true +} + +// HasCountry returns a boolean if a field has been set. +func (o *FilterBy) HasCountry() bool { + if o != nil && o.Country != nil { + return true + } + + return false +} + +// SetCountry gets a reference to the given []string and assigns it to the Country field. +func (o *FilterBy) SetCountry(v []string) { + o.Country = &v +} + +// GetDeviceType returns the DeviceType field value if set, zero value otherwise. +func (o *FilterBy) GetDeviceType() []string { + if o == nil || o.DeviceType == nil { + var ret []string + return ret + } + return *o.DeviceType +} + +// GetDeviceTypeOk returns a tuple with the DeviceType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy) GetDeviceTypeOk() (*[]string, bool) { + if o == nil || o.DeviceType == nil { + return nil, false + } + return o.DeviceType, true +} + +// HasDeviceType returns a boolean if a field has been set. +func (o *FilterBy) HasDeviceType() bool { + if o != nil && o.DeviceType != nil { + return true + } + + return false +} + +// SetDeviceType gets a reference to the given []string and assigns it to the DeviceType field. +func (o *FilterBy) SetDeviceType(v []string) { + o.DeviceType = &v +} + +// GetOperatingSystem returns the OperatingSystem field value if set, zero value otherwise. +func (o *FilterBy) GetOperatingSystem() []string { + if o == nil || o.OperatingSystem == nil { + var ret []string + return ret + } + return *o.OperatingSystem +} + +// GetOperatingSystemOk returns a tuple with the OperatingSystem field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy) GetOperatingSystemOk() (*[]string, bool) { + if o == nil || o.OperatingSystem == nil { + return nil, false + } + return o.OperatingSystem, true +} + +// HasOperatingSystem returns a boolean if a field has been set. +func (o *FilterBy) HasOperatingSystem() bool { + if o != nil && o.OperatingSystem != nil { + return true + } + + return false +} + +// SetOperatingSystem gets a reference to the given []string and assigns it to the OperatingSystem field. +func (o *FilterBy) SetOperatingSystem(v []string) { + o.OperatingSystem = &v +} + +// GetBrowser returns the Browser field value if set, zero value otherwise. +func (o *FilterBy) GetBrowser() []string { + if o == nil || o.Browser == nil { + var ret []string + return ret + } + return *o.Browser +} + +// GetBrowserOk returns a tuple with the Browser field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy) GetBrowserOk() (*[]string, bool) { + if o == nil || o.Browser == nil { + return nil, false + } + return o.Browser, true +} + +// HasBrowser returns a boolean if a field has been set. +func (o *FilterBy) HasBrowser() bool { + if o != nil && o.Browser != nil { + return true + } + + return false +} + +// SetBrowser gets a reference to the given []string and assigns it to the Browser field. +func (o *FilterBy) SetBrowser(v []string) { + o.Browser = &v +} + +// GetTag returns the Tag field value if set, zero value otherwise. +func (o *FilterBy) GetTag() string { + if o == nil || o.Tag == nil { + var ret string + return ret + } + return *o.Tag +} + +// GetTagOk returns a tuple with the Tag field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy) GetTagOk() (*string, bool) { + if o == nil || o.Tag == nil { + return nil, false + } + return o.Tag, true +} + +// HasTag returns a boolean if a field has been set. +func (o *FilterBy) HasTag() bool { + if o != nil && o.Tag != nil { + return true + } + + return false +} + +// SetTag gets a reference to the given string and assigns it to the Tag field. +func (o *FilterBy) SetTag(v string) { + o.Tag = &v +} + +type NullableFilterBy struct { + value *FilterBy + isSet bool +} + +func (v NullableFilterBy) Get() *FilterBy { + return v.value +} + +func (v *NullableFilterBy) Set(val *FilterBy) { + v.value = val + v.isSet = true +} + +func (v NullableFilterBy) IsSet() bool { + return v.isSet +} + +func (v *NullableFilterBy) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFilterBy(val *FilterBy) *NullableFilterBy { + return &NullableFilterBy{value: val, isSet: true} +} diff --git a/model_filter_by_1.go b/model_filter_by_1.go new file mode 100644 index 0000000..100f7d2 --- /dev/null +++ b/model_filter_by_1.go @@ -0,0 +1,334 @@ +/* + * api.video + * + * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. + * + * API version: 1 + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package apivideosdk + +import ( +//"encoding/json" +) + +// FilterBy1 struct for FilterBy1 +type FilterBy1 struct { + // Returns analytics based on the unique identifiers of a video or a live stream. + MediaId *[]string `json:"mediaId,omitempty"` + MediaType *string `json:"mediaType,omitempty"` + // Returns analytics based on the viewers' continent. The list of supported continents names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `EU`. + Continent *[]string `json:"continent,omitempty"` + // Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `FR`. + Country *[]string `json:"country,omitempty"` + // Returns analytics based on the type of device used by the viewers. Response values can include: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. + DeviceType *[]string `json:"deviceType,omitempty"` + // Returns analytics based on the operating system used by the viewers. Response values can include `windows`, `mac osx`, `android`, `ios`, `linux`. + OperatingSystem *[]string `json:"operatingSystem,omitempty"` + // Returns analytics based on the browser used by the viewers. Response values can include `chrome`, `firefox`, `edge`, `opera`. + Browser *[]string `json:"browser,omitempty"` + // Returns analytics for videos using this tag. This filter only accepts a single value and is case sensitive. Read more about tagging your videos [here](https://docs.api.video/vod/tags-metadata). + Tag *string `json:"tag,omitempty"` +} + +// NewFilterBy1 instantiates a new FilterBy1 object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFilterBy1() *FilterBy1 { + this := FilterBy1{} + return &this +} + +// NewFilterBy1WithDefaults instantiates a new FilterBy1 object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFilterBy1WithDefaults() *FilterBy1 { + this := FilterBy1{} + return &this +} + +// GetMediaId returns the MediaId field value if set, zero value otherwise. +func (o *FilterBy1) GetMediaId() []string { + if o == nil || o.MediaId == nil { + var ret []string + return ret + } + return *o.MediaId +} + +// GetMediaIdOk returns a tuple with the MediaId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy1) GetMediaIdOk() (*[]string, bool) { + if o == nil || o.MediaId == nil { + return nil, false + } + return o.MediaId, true +} + +// HasMediaId returns a boolean if a field has been set. +func (o *FilterBy1) HasMediaId() bool { + if o != nil && o.MediaId != nil { + return true + } + + return false +} + +// SetMediaId gets a reference to the given []string and assigns it to the MediaId field. +func (o *FilterBy1) SetMediaId(v []string) { + o.MediaId = &v +} + +// GetMediaType returns the MediaType field value if set, zero value otherwise. +func (o *FilterBy1) GetMediaType() string { + if o == nil || o.MediaType == nil { + var ret string + return ret + } + return *o.MediaType +} + +// GetMediaTypeOk returns a tuple with the MediaType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy1) GetMediaTypeOk() (*string, bool) { + if o == nil || o.MediaType == nil { + return nil, false + } + return o.MediaType, true +} + +// HasMediaType returns a boolean if a field has been set. +func (o *FilterBy1) HasMediaType() bool { + if o != nil && o.MediaType != nil { + return true + } + + return false +} + +// SetMediaType gets a reference to the given string and assigns it to the MediaType field. +func (o *FilterBy1) SetMediaType(v string) { + o.MediaType = &v +} + +// GetContinent returns the Continent field value if set, zero value otherwise. +func (o *FilterBy1) GetContinent() []string { + if o == nil || o.Continent == nil { + var ret []string + return ret + } + return *o.Continent +} + +// GetContinentOk returns a tuple with the Continent field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy1) GetContinentOk() (*[]string, bool) { + if o == nil || o.Continent == nil { + return nil, false + } + return o.Continent, true +} + +// HasContinent returns a boolean if a field has been set. +func (o *FilterBy1) HasContinent() bool { + if o != nil && o.Continent != nil { + return true + } + + return false +} + +// SetContinent gets a reference to the given []string and assigns it to the Continent field. +func (o *FilterBy1) SetContinent(v []string) { + o.Continent = &v +} + +// GetCountry returns the Country field value if set, zero value otherwise. +func (o *FilterBy1) GetCountry() []string { + if o == nil || o.Country == nil { + var ret []string + return ret + } + return *o.Country +} + +// GetCountryOk returns a tuple with the Country field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy1) GetCountryOk() (*[]string, bool) { + if o == nil || o.Country == nil { + return nil, false + } + return o.Country, true +} + +// HasCountry returns a boolean if a field has been set. +func (o *FilterBy1) HasCountry() bool { + if o != nil && o.Country != nil { + return true + } + + return false +} + +// SetCountry gets a reference to the given []string and assigns it to the Country field. +func (o *FilterBy1) SetCountry(v []string) { + o.Country = &v +} + +// GetDeviceType returns the DeviceType field value if set, zero value otherwise. +func (o *FilterBy1) GetDeviceType() []string { + if o == nil || o.DeviceType == nil { + var ret []string + return ret + } + return *o.DeviceType +} + +// GetDeviceTypeOk returns a tuple with the DeviceType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy1) GetDeviceTypeOk() (*[]string, bool) { + if o == nil || o.DeviceType == nil { + return nil, false + } + return o.DeviceType, true +} + +// HasDeviceType returns a boolean if a field has been set. +func (o *FilterBy1) HasDeviceType() bool { + if o != nil && o.DeviceType != nil { + return true + } + + return false +} + +// SetDeviceType gets a reference to the given []string and assigns it to the DeviceType field. +func (o *FilterBy1) SetDeviceType(v []string) { + o.DeviceType = &v +} + +// GetOperatingSystem returns the OperatingSystem field value if set, zero value otherwise. +func (o *FilterBy1) GetOperatingSystem() []string { + if o == nil || o.OperatingSystem == nil { + var ret []string + return ret + } + return *o.OperatingSystem +} + +// GetOperatingSystemOk returns a tuple with the OperatingSystem field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy1) GetOperatingSystemOk() (*[]string, bool) { + if o == nil || o.OperatingSystem == nil { + return nil, false + } + return o.OperatingSystem, true +} + +// HasOperatingSystem returns a boolean if a field has been set. +func (o *FilterBy1) HasOperatingSystem() bool { + if o != nil && o.OperatingSystem != nil { + return true + } + + return false +} + +// SetOperatingSystem gets a reference to the given []string and assigns it to the OperatingSystem field. +func (o *FilterBy1) SetOperatingSystem(v []string) { + o.OperatingSystem = &v +} + +// GetBrowser returns the Browser field value if set, zero value otherwise. +func (o *FilterBy1) GetBrowser() []string { + if o == nil || o.Browser == nil { + var ret []string + return ret + } + return *o.Browser +} + +// GetBrowserOk returns a tuple with the Browser field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy1) GetBrowserOk() (*[]string, bool) { + if o == nil || o.Browser == nil { + return nil, false + } + return o.Browser, true +} + +// HasBrowser returns a boolean if a field has been set. +func (o *FilterBy1) HasBrowser() bool { + if o != nil && o.Browser != nil { + return true + } + + return false +} + +// SetBrowser gets a reference to the given []string and assigns it to the Browser field. +func (o *FilterBy1) SetBrowser(v []string) { + o.Browser = &v +} + +// GetTag returns the Tag field value if set, zero value otherwise. +func (o *FilterBy1) GetTag() string { + if o == nil || o.Tag == nil { + var ret string + return ret + } + return *o.Tag +} + +// GetTagOk returns a tuple with the Tag field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy1) GetTagOk() (*string, bool) { + if o == nil || o.Tag == nil { + return nil, false + } + return o.Tag, true +} + +// HasTag returns a boolean if a field has been set. +func (o *FilterBy1) HasTag() bool { + if o != nil && o.Tag != nil { + return true + } + + return false +} + +// SetTag gets a reference to the given string and assigns it to the Tag field. +func (o *FilterBy1) SetTag(v string) { + o.Tag = &v +} + +type NullableFilterBy1 struct { + value *FilterBy1 + isSet bool +} + +func (v NullableFilterBy1) Get() *FilterBy1 { + return v.value +} + +func (v *NullableFilterBy1) Set(val *FilterBy1) { + v.value = val + v.isSet = true +} + +func (v NullableFilterBy1) IsSet() bool { + return v.isSet +} + +func (v *NullableFilterBy1) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFilterBy1(val *FilterBy1) *NullableFilterBy1 { + return &NullableFilterBy1{value: val, isSet: true} +} diff --git a/model_filter_by_2.go b/model_filter_by_2.go new file mode 100644 index 0000000..323281f --- /dev/null +++ b/model_filter_by_2.go @@ -0,0 +1,334 @@ +/* + * api.video + * + * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. + * + * API version: 1 + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package apivideosdk + +import ( +//"encoding/json" +) + +// FilterBy2 struct for FilterBy2 +type FilterBy2 struct { + // Returns analytics based on the unique identifiers of a video or a live stream. + MediaId *[]string `json:"mediaId,omitempty"` + MediaType *string `json:"mediaType,omitempty"` + // Returns analytics based on the viewers' continent. The list of supported continents names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `EU`. + Continent *[]string `json:"continent,omitempty"` + // Returns analytics based on the viewers' country. The list of supported country names are based on the [GeoNames public database](https://www.geonames.org/countries/). You must use the ISO-3166 alpha2 format, for example `FR`. + Country *[]string `json:"country,omitempty"` + // Returns analytics based on the type of device used by the viewers. Response values can include: `computer`, `phone`, `tablet`, `tv`, `console`, `wearable`, `unknown`. + DeviceType *[]string `json:"deviceType,omitempty"` + // Returns analytics based on the operating system used by the viewers. Response values can include `windows`, `mac osx`, `android`, `ios`, `linux`. + OperatingSystem *[]string `json:"operatingSystem,omitempty"` + // Returns analytics based on the browser used by the viewers. Response values can include `chrome`, `firefox`, `edge`, `opera`. + Browser *[]string `json:"browser,omitempty"` + // Returns analytics for videos using this tag. This filter only accepts a single value and is case sensitive. Read more about tagging your videos [here](https://docs.api.video/vod/tags-metadata). + Tag *string `json:"tag,omitempty"` +} + +// NewFilterBy2 instantiates a new FilterBy2 object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewFilterBy2() *FilterBy2 { + this := FilterBy2{} + return &this +} + +// NewFilterBy2WithDefaults instantiates a new FilterBy2 object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewFilterBy2WithDefaults() *FilterBy2 { + this := FilterBy2{} + return &this +} + +// GetMediaId returns the MediaId field value if set, zero value otherwise. +func (o *FilterBy2) GetMediaId() []string { + if o == nil || o.MediaId == nil { + var ret []string + return ret + } + return *o.MediaId +} + +// GetMediaIdOk returns a tuple with the MediaId field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy2) GetMediaIdOk() (*[]string, bool) { + if o == nil || o.MediaId == nil { + return nil, false + } + return o.MediaId, true +} + +// HasMediaId returns a boolean if a field has been set. +func (o *FilterBy2) HasMediaId() bool { + if o != nil && o.MediaId != nil { + return true + } + + return false +} + +// SetMediaId gets a reference to the given []string and assigns it to the MediaId field. +func (o *FilterBy2) SetMediaId(v []string) { + o.MediaId = &v +} + +// GetMediaType returns the MediaType field value if set, zero value otherwise. +func (o *FilterBy2) GetMediaType() string { + if o == nil || o.MediaType == nil { + var ret string + return ret + } + return *o.MediaType +} + +// GetMediaTypeOk returns a tuple with the MediaType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy2) GetMediaTypeOk() (*string, bool) { + if o == nil || o.MediaType == nil { + return nil, false + } + return o.MediaType, true +} + +// HasMediaType returns a boolean if a field has been set. +func (o *FilterBy2) HasMediaType() bool { + if o != nil && o.MediaType != nil { + return true + } + + return false +} + +// SetMediaType gets a reference to the given string and assigns it to the MediaType field. +func (o *FilterBy2) SetMediaType(v string) { + o.MediaType = &v +} + +// GetContinent returns the Continent field value if set, zero value otherwise. +func (o *FilterBy2) GetContinent() []string { + if o == nil || o.Continent == nil { + var ret []string + return ret + } + return *o.Continent +} + +// GetContinentOk returns a tuple with the Continent field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy2) GetContinentOk() (*[]string, bool) { + if o == nil || o.Continent == nil { + return nil, false + } + return o.Continent, true +} + +// HasContinent returns a boolean if a field has been set. +func (o *FilterBy2) HasContinent() bool { + if o != nil && o.Continent != nil { + return true + } + + return false +} + +// SetContinent gets a reference to the given []string and assigns it to the Continent field. +func (o *FilterBy2) SetContinent(v []string) { + o.Continent = &v +} + +// GetCountry returns the Country field value if set, zero value otherwise. +func (o *FilterBy2) GetCountry() []string { + if o == nil || o.Country == nil { + var ret []string + return ret + } + return *o.Country +} + +// GetCountryOk returns a tuple with the Country field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy2) GetCountryOk() (*[]string, bool) { + if o == nil || o.Country == nil { + return nil, false + } + return o.Country, true +} + +// HasCountry returns a boolean if a field has been set. +func (o *FilterBy2) HasCountry() bool { + if o != nil && o.Country != nil { + return true + } + + return false +} + +// SetCountry gets a reference to the given []string and assigns it to the Country field. +func (o *FilterBy2) SetCountry(v []string) { + o.Country = &v +} + +// GetDeviceType returns the DeviceType field value if set, zero value otherwise. +func (o *FilterBy2) GetDeviceType() []string { + if o == nil || o.DeviceType == nil { + var ret []string + return ret + } + return *o.DeviceType +} + +// GetDeviceTypeOk returns a tuple with the DeviceType field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy2) GetDeviceTypeOk() (*[]string, bool) { + if o == nil || o.DeviceType == nil { + return nil, false + } + return o.DeviceType, true +} + +// HasDeviceType returns a boolean if a field has been set. +func (o *FilterBy2) HasDeviceType() bool { + if o != nil && o.DeviceType != nil { + return true + } + + return false +} + +// SetDeviceType gets a reference to the given []string and assigns it to the DeviceType field. +func (o *FilterBy2) SetDeviceType(v []string) { + o.DeviceType = &v +} + +// GetOperatingSystem returns the OperatingSystem field value if set, zero value otherwise. +func (o *FilterBy2) GetOperatingSystem() []string { + if o == nil || o.OperatingSystem == nil { + var ret []string + return ret + } + return *o.OperatingSystem +} + +// GetOperatingSystemOk returns a tuple with the OperatingSystem field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy2) GetOperatingSystemOk() (*[]string, bool) { + if o == nil || o.OperatingSystem == nil { + return nil, false + } + return o.OperatingSystem, true +} + +// HasOperatingSystem returns a boolean if a field has been set. +func (o *FilterBy2) HasOperatingSystem() bool { + if o != nil && o.OperatingSystem != nil { + return true + } + + return false +} + +// SetOperatingSystem gets a reference to the given []string and assigns it to the OperatingSystem field. +func (o *FilterBy2) SetOperatingSystem(v []string) { + o.OperatingSystem = &v +} + +// GetBrowser returns the Browser field value if set, zero value otherwise. +func (o *FilterBy2) GetBrowser() []string { + if o == nil || o.Browser == nil { + var ret []string + return ret + } + return *o.Browser +} + +// GetBrowserOk returns a tuple with the Browser field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy2) GetBrowserOk() (*[]string, bool) { + if o == nil || o.Browser == nil { + return nil, false + } + return o.Browser, true +} + +// HasBrowser returns a boolean if a field has been set. +func (o *FilterBy2) HasBrowser() bool { + if o != nil && o.Browser != nil { + return true + } + + return false +} + +// SetBrowser gets a reference to the given []string and assigns it to the Browser field. +func (o *FilterBy2) SetBrowser(v []string) { + o.Browser = &v +} + +// GetTag returns the Tag field value if set, zero value otherwise. +func (o *FilterBy2) GetTag() string { + if o == nil || o.Tag == nil { + var ret string + return ret + } + return *o.Tag +} + +// GetTagOk returns a tuple with the Tag field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *FilterBy2) GetTagOk() (*string, bool) { + if o == nil || o.Tag == nil { + return nil, false + } + return o.Tag, true +} + +// HasTag returns a boolean if a field has been set. +func (o *FilterBy2) HasTag() bool { + if o != nil && o.Tag != nil { + return true + } + + return false +} + +// SetTag gets a reference to the given string and assigns it to the Tag field. +func (o *FilterBy2) SetTag(v string) { + o.Tag = &v +} + +type NullableFilterBy2 struct { + value *FilterBy2 + isSet bool +} + +func (v NullableFilterBy2) Get() *FilterBy2 { + return v.value +} + +func (v *NullableFilterBy2) Set(val *FilterBy2) { + v.value = val + v.isSet = true +} + +func (v NullableFilterBy2) IsSet() bool { + return v.isSet +} + +func (v *NullableFilterBy2) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableFilterBy2(val *FilterBy2) *NullableFilterBy2 { + return &NullableFilterBy2{value: val, isSet: true} +} diff --git a/model_live_stream.go b/model_live_stream.go index 16dabbf..524b310 100644 --- a/model_live_stream.go +++ b/model_live_stream.go @@ -22,14 +22,14 @@ type LiveStream struct { Name *string `json:"name,omitempty"` // The unique, private stream key that you use to begin streaming. StreamKey *string `json:"streamKey,omitempty"` - // Whether your video can be viewed by everyone, or requires authentication to see it. A setting of false will require a unique token for each view. Learn more about the Private Video feature [here](https://docs.api.video/delivery-analytics/video-privacy-access-management). + // Whether your video can be viewed by everyone, or requires authentication to see it. A setting of false will require a unique token for each view. Learn more about the Private Video feature [here](https://docs.api.video/delivery/video-privacy-access-management). Public *bool `json:"public,omitempty"` Assets *LiveStreamAssets `json:"assets,omitempty"` // The unique identifier for the player. PlayerId *string `json:"playerId,omitempty"` // Whether or not you are broadcasting the live video you recorded for others to see. True means you are broadcasting to viewers, false means you are not. Broadcasting *bool `json:"broadcasting,omitempty"` - // Returns the list of RTMP restream destinations. + // Returns the list of restream destinations. Restreams []RestreamsResponseObject `json:"restreams"` // When the player was created, presented in ISO-8601 format. CreatedAt *string `json:"createdAt,omitempty"` diff --git a/model_live_stream_creation_payload.go b/model_live_stream_creation_payload.go index 62d131a..0a8b561 100644 --- a/model_live_stream_creation_payload.go +++ b/model_live_stream_creation_payload.go @@ -18,11 +18,11 @@ import ( type LiveStreamCreationPayload struct { // Add a name for your live stream here. Name string `json:"name"` - // Whether your video can be viewed by everyone, or requires authentication to see it. A setting of false will require a unique token for each view. Learn more about the Private Video feature [here](https://docs.api.video/delivery-analytics/video-privacy-access-management). + // Whether your video can be viewed by everyone, or requires authentication to see it. A setting of false will require a unique token for each view. Learn more about the Private Video feature [here](https://docs.api.video/delivery/video-privacy-access-management). Public *bool `json:"public,omitempty"` // The unique identifier for the player. PlayerId *string `json:"playerId,omitempty"` - // Use this parameter to add, edit, or remove RTMP services where you want to restream a live stream. The list can only contain up to 5 destinations. + // Use this parameter to add, edit, or remove `RTMPS` or `RTMP` services where you want to restream a live stream. The list can only contain up to 5 destinations. Restreams *[]RestreamsRequestObject `json:"restreams,omitempty"` } diff --git a/model_live_stream_session.go b/model_live_stream_session.go deleted file mode 100644 index c6e5b0a..0000000 --- a/model_live_stream_session.go +++ /dev/null @@ -1,261 +0,0 @@ -/* - * api.video - * - * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. - * - * API version: 1 - */ - -// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. - -package apivideosdk - -import ( -//"encoding/json" -) - -// LiveStreamSession struct for LiveStreamSession -type LiveStreamSession struct { - Session *LiveStreamSessionSession `json:"session,omitempty"` - Location *LiveStreamSessionLocation `json:"location,omitempty"` - Referrer *LiveStreamSessionReferrer `json:"referrer,omitempty"` - Device *LiveStreamSessionDevice `json:"device,omitempty"` - Os *VideoSessionOs `json:"os,omitempty"` - Client *LiveStreamSessionClient `json:"client,omitempty"` -} - -// NewLiveStreamSession instantiates a new LiveStreamSession object -// This constructor will assign default values to properties that have it defined, -// and makes sure properties required by API are set, but the set of arguments -// will change when the set of required properties is changed -func NewLiveStreamSession() *LiveStreamSession { - this := LiveStreamSession{} - return &this -} - -// NewLiveStreamSessionWithDefaults instantiates a new LiveStreamSession object -// This constructor will only assign default values to properties that have it defined, -// but it doesn't guarantee that properties required by API are set -func NewLiveStreamSessionWithDefaults() *LiveStreamSession { - this := LiveStreamSession{} - return &this -} - -// GetSession returns the Session field value if set, zero value otherwise. -func (o *LiveStreamSession) GetSession() LiveStreamSessionSession { - if o == nil || o.Session == nil { - var ret LiveStreamSessionSession - return ret - } - return *o.Session -} - -// GetSessionOk returns a tuple with the Session field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *LiveStreamSession) GetSessionOk() (*LiveStreamSessionSession, bool) { - if o == nil || o.Session == nil { - return nil, false - } - return o.Session, true -} - -// HasSession returns a boolean if a field has been set. -func (o *LiveStreamSession) HasSession() bool { - if o != nil && o.Session != nil { - return true - } - - return false -} - -// SetSession gets a reference to the given LiveStreamSessionSession and assigns it to the Session field. -func (o *LiveStreamSession) SetSession(v LiveStreamSessionSession) { - o.Session = &v -} - -// GetLocation returns the Location field value if set, zero value otherwise. -func (o *LiveStreamSession) GetLocation() LiveStreamSessionLocation { - if o == nil || o.Location == nil { - var ret LiveStreamSessionLocation - return ret - } - return *o.Location -} - -// GetLocationOk returns a tuple with the Location field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *LiveStreamSession) GetLocationOk() (*LiveStreamSessionLocation, bool) { - if o == nil || o.Location == nil { - return nil, false - } - return o.Location, true -} - -// HasLocation returns a boolean if a field has been set. -func (o *LiveStreamSession) HasLocation() bool { - if o != nil && o.Location != nil { - return true - } - - return false -} - -// SetLocation gets a reference to the given LiveStreamSessionLocation and assigns it to the Location field. -func (o *LiveStreamSession) SetLocation(v LiveStreamSessionLocation) { - o.Location = &v -} - -// GetReferrer returns the Referrer field value if set, zero value otherwise. -func (o *LiveStreamSession) GetReferrer() LiveStreamSessionReferrer { - if o == nil || o.Referrer == nil { - var ret LiveStreamSessionReferrer - return ret - } - return *o.Referrer -} - -// GetReferrerOk returns a tuple with the Referrer field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *LiveStreamSession) GetReferrerOk() (*LiveStreamSessionReferrer, bool) { - if o == nil || o.Referrer == nil { - return nil, false - } - return o.Referrer, true -} - -// HasReferrer returns a boolean if a field has been set. -func (o *LiveStreamSession) HasReferrer() bool { - if o != nil && o.Referrer != nil { - return true - } - - return false -} - -// SetReferrer gets a reference to the given LiveStreamSessionReferrer and assigns it to the Referrer field. -func (o *LiveStreamSession) SetReferrer(v LiveStreamSessionReferrer) { - o.Referrer = &v -} - -// GetDevice returns the Device field value if set, zero value otherwise. -func (o *LiveStreamSession) GetDevice() LiveStreamSessionDevice { - if o == nil || o.Device == nil { - var ret LiveStreamSessionDevice - return ret - } - return *o.Device -} - -// GetDeviceOk returns a tuple with the Device field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *LiveStreamSession) GetDeviceOk() (*LiveStreamSessionDevice, bool) { - if o == nil || o.Device == nil { - return nil, false - } - return o.Device, true -} - -// HasDevice returns a boolean if a field has been set. -func (o *LiveStreamSession) HasDevice() bool { - if o != nil && o.Device != nil { - return true - } - - return false -} - -// SetDevice gets a reference to the given LiveStreamSessionDevice and assigns it to the Device field. -func (o *LiveStreamSession) SetDevice(v LiveStreamSessionDevice) { - o.Device = &v -} - -// GetOs returns the Os field value if set, zero value otherwise. -func (o *LiveStreamSession) GetOs() VideoSessionOs { - if o == nil || o.Os == nil { - var ret VideoSessionOs - return ret - } - return *o.Os -} - -// GetOsOk returns a tuple with the Os field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *LiveStreamSession) GetOsOk() (*VideoSessionOs, bool) { - if o == nil || o.Os == nil { - return nil, false - } - return o.Os, true -} - -// HasOs returns a boolean if a field has been set. -func (o *LiveStreamSession) HasOs() bool { - if o != nil && o.Os != nil { - return true - } - - return false -} - -// SetOs gets a reference to the given VideoSessionOs and assigns it to the Os field. -func (o *LiveStreamSession) SetOs(v VideoSessionOs) { - o.Os = &v -} - -// GetClient returns the Client field value if set, zero value otherwise. -func (o *LiveStreamSession) GetClient() LiveStreamSessionClient { - if o == nil || o.Client == nil { - var ret LiveStreamSessionClient - return ret - } - return *o.Client -} - -// GetClientOk returns a tuple with the Client field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *LiveStreamSession) GetClientOk() (*LiveStreamSessionClient, bool) { - if o == nil || o.Client == nil { - return nil, false - } - return o.Client, true -} - -// HasClient returns a boolean if a field has been set. -func (o *LiveStreamSession) HasClient() bool { - if o != nil && o.Client != nil { - return true - } - - return false -} - -// SetClient gets a reference to the given LiveStreamSessionClient and assigns it to the Client field. -func (o *LiveStreamSession) SetClient(v LiveStreamSessionClient) { - o.Client = &v -} - -type NullableLiveStreamSession struct { - value *LiveStreamSession - isSet bool -} - -func (v NullableLiveStreamSession) Get() *LiveStreamSession { - return v.value -} - -func (v *NullableLiveStreamSession) Set(val *LiveStreamSession) { - v.value = val - v.isSet = true -} - -func (v NullableLiveStreamSession) IsSet() bool { - return v.isSet -} - -func (v *NullableLiveStreamSession) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableLiveStreamSession(val *LiveStreamSession) *NullableLiveStreamSession { - return &NullableLiveStreamSession{value: val, isSet: true} -} diff --git a/model_live_stream_session_client.go b/model_live_stream_session_client.go deleted file mode 100644 index 232d407..0000000 --- a/model_live_stream_session_client.go +++ /dev/null @@ -1,165 +0,0 @@ -/* - * api.video - * - * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. - * - * API version: 1 - */ - -// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. - -package apivideosdk - -import ( -//"encoding/json" -) - -// LiveStreamSessionClient What kind of browser the viewer is using for the live stream session. -type LiveStreamSessionClient struct { - // The name of the browser used to view the live stream session. - Name *string `json:"name,omitempty"` - // The version of the browser used to view the live stream session. - Version *string `json:"version,omitempty"` - // The type of client used to view the live stream session. - Type *string `json:"type,omitempty"` -} - -// NewLiveStreamSessionClient instantiates a new LiveStreamSessionClient object -// This constructor will assign default values to properties that have it defined, -// and makes sure properties required by API are set, but the set of arguments -// will change when the set of required properties is changed -func NewLiveStreamSessionClient() *LiveStreamSessionClient { - this := LiveStreamSessionClient{} - return &this -} - -// NewLiveStreamSessionClientWithDefaults instantiates a new LiveStreamSessionClient object -// This constructor will only assign default values to properties that have it defined, -// but it doesn't guarantee that properties required by API are set -func NewLiveStreamSessionClientWithDefaults() *LiveStreamSessionClient { - this := LiveStreamSessionClient{} - return &this -} - -// GetName returns the Name field value if set, zero value otherwise. -func (o *LiveStreamSessionClient) GetName() string { - if o == nil || o.Name == nil { - var ret string - return ret - } - return *o.Name -} - -// GetNameOk returns a tuple with the Name field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *LiveStreamSessionClient) GetNameOk() (*string, bool) { - if o == nil || o.Name == nil { - return nil, false - } - return o.Name, true -} - -// HasName returns a boolean if a field has been set. -func (o *LiveStreamSessionClient) HasName() bool { - if o != nil && o.Name != nil { - return true - } - - return false -} - -// SetName gets a reference to the given string and assigns it to the Name field. -func (o *LiveStreamSessionClient) SetName(v string) { - o.Name = &v -} - -// GetVersion returns the Version field value if set, zero value otherwise. -func (o *LiveStreamSessionClient) GetVersion() string { - if o == nil || o.Version == nil { - var ret string - return ret - } - return *o.Version -} - -// GetVersionOk returns a tuple with the Version field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *LiveStreamSessionClient) GetVersionOk() (*string, bool) { - if o == nil || o.Version == nil { - return nil, false - } - return o.Version, true -} - -// HasVersion returns a boolean if a field has been set. -func (o *LiveStreamSessionClient) HasVersion() bool { - if o != nil && o.Version != nil { - return true - } - - return false -} - -// SetVersion gets a reference to the given string and assigns it to the Version field. -func (o *LiveStreamSessionClient) SetVersion(v string) { - o.Version = &v -} - -// GetType returns the Type field value if set, zero value otherwise. -func (o *LiveStreamSessionClient) GetType() string { - if o == nil || o.Type == nil { - var ret string - return ret - } - return *o.Type -} - -// GetTypeOk returns a tuple with the Type field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *LiveStreamSessionClient) GetTypeOk() (*string, bool) { - if o == nil || o.Type == nil { - return nil, false - } - return o.Type, true -} - -// HasType returns a boolean if a field has been set. -func (o *LiveStreamSessionClient) HasType() bool { - if o != nil && o.Type != nil { - return true - } - - return false -} - -// SetType gets a reference to the given string and assigns it to the Type field. -func (o *LiveStreamSessionClient) SetType(v string) { - o.Type = &v -} - -type NullableLiveStreamSessionClient struct { - value *LiveStreamSessionClient - isSet bool -} - -func (v NullableLiveStreamSessionClient) Get() *LiveStreamSessionClient { - return v.value -} - -func (v *NullableLiveStreamSessionClient) Set(val *LiveStreamSessionClient) { - v.value = val - v.isSet = true -} - -func (v NullableLiveStreamSessionClient) IsSet() bool { - return v.isSet -} - -func (v *NullableLiveStreamSessionClient) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableLiveStreamSessionClient(val *LiveStreamSessionClient) *NullableLiveStreamSessionClient { - return &NullableLiveStreamSessionClient{value: val, isSet: true} -} diff --git a/model_live_stream_session_device.go b/model_live_stream_session_device.go deleted file mode 100644 index c06e11c..0000000 --- a/model_live_stream_session_device.go +++ /dev/null @@ -1,165 +0,0 @@ -/* - * api.video - * - * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. - * - * API version: 1 - */ - -// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. - -package apivideosdk - -import ( -//"encoding/json" -) - -// LiveStreamSessionDevice What type of device the user is on when in the live stream session. -type LiveStreamSessionDevice struct { - // What the type is like desktop, laptop, mobile. - Type *string `json:"type,omitempty"` - // If known, what the brand of the device is, like Apple, Dell, etc. - Vendor *string `json:"vendor,omitempty"` - // The specific model of the device, if known. - Model *string `json:"model,omitempty"` -} - -// NewLiveStreamSessionDevice instantiates a new LiveStreamSessionDevice object -// This constructor will assign default values to properties that have it defined, -// and makes sure properties required by API are set, but the set of arguments -// will change when the set of required properties is changed -func NewLiveStreamSessionDevice() *LiveStreamSessionDevice { - this := LiveStreamSessionDevice{} - return &this -} - -// NewLiveStreamSessionDeviceWithDefaults instantiates a new LiveStreamSessionDevice object -// This constructor will only assign default values to properties that have it defined, -// but it doesn't guarantee that properties required by API are set -func NewLiveStreamSessionDeviceWithDefaults() *LiveStreamSessionDevice { - this := LiveStreamSessionDevice{} - return &this -} - -// GetType returns the Type field value if set, zero value otherwise. -func (o *LiveStreamSessionDevice) GetType() string { - if o == nil || o.Type == nil { - var ret string - return ret - } - return *o.Type -} - -// GetTypeOk returns a tuple with the Type field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *LiveStreamSessionDevice) GetTypeOk() (*string, bool) { - if o == nil || o.Type == nil { - return nil, false - } - return o.Type, true -} - -// HasType returns a boolean if a field has been set. -func (o *LiveStreamSessionDevice) HasType() bool { - if o != nil && o.Type != nil { - return true - } - - return false -} - -// SetType gets a reference to the given string and assigns it to the Type field. -func (o *LiveStreamSessionDevice) SetType(v string) { - o.Type = &v -} - -// GetVendor returns the Vendor field value if set, zero value otherwise. -func (o *LiveStreamSessionDevice) GetVendor() string { - if o == nil || o.Vendor == nil { - var ret string - return ret - } - return *o.Vendor -} - -// GetVendorOk returns a tuple with the Vendor field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *LiveStreamSessionDevice) GetVendorOk() (*string, bool) { - if o == nil || o.Vendor == nil { - return nil, false - } - return o.Vendor, true -} - -// HasVendor returns a boolean if a field has been set. -func (o *LiveStreamSessionDevice) HasVendor() bool { - if o != nil && o.Vendor != nil { - return true - } - - return false -} - -// SetVendor gets a reference to the given string and assigns it to the Vendor field. -func (o *LiveStreamSessionDevice) SetVendor(v string) { - o.Vendor = &v -} - -// GetModel returns the Model field value if set, zero value otherwise. -func (o *LiveStreamSessionDevice) GetModel() string { - if o == nil || o.Model == nil { - var ret string - return ret - } - return *o.Model -} - -// GetModelOk returns a tuple with the Model field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *LiveStreamSessionDevice) GetModelOk() (*string, bool) { - if o == nil || o.Model == nil { - return nil, false - } - return o.Model, true -} - -// HasModel returns a boolean if a field has been set. -func (o *LiveStreamSessionDevice) HasModel() bool { - if o != nil && o.Model != nil { - return true - } - - return false -} - -// SetModel gets a reference to the given string and assigns it to the Model field. -func (o *LiveStreamSessionDevice) SetModel(v string) { - o.Model = &v -} - -type NullableLiveStreamSessionDevice struct { - value *LiveStreamSessionDevice - isSet bool -} - -func (v NullableLiveStreamSessionDevice) Get() *LiveStreamSessionDevice { - return v.value -} - -func (v *NullableLiveStreamSessionDevice) Set(val *LiveStreamSessionDevice) { - v.value = val - v.isSet = true -} - -func (v NullableLiveStreamSessionDevice) IsSet() bool { - return v.isSet -} - -func (v *NullableLiveStreamSessionDevice) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableLiveStreamSessionDevice(val *LiveStreamSessionDevice) *NullableLiveStreamSessionDevice { - return &NullableLiveStreamSessionDevice{value: val, isSet: true} -} diff --git a/model_live_stream_session_location.go b/model_live_stream_session_location.go deleted file mode 100644 index 5e135f4..0000000 --- a/model_live_stream_session_location.go +++ /dev/null @@ -1,131 +0,0 @@ -/* - * api.video - * - * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. - * - * API version: 1 - */ - -// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. - -package apivideosdk - -import ( -//"encoding/json" -) - -// LiveStreamSessionLocation The location of the viewer of the live stream. -type LiveStreamSessionLocation struct { - // The country of the viewer of the live stream. - Country *string `json:"country,omitempty"` - // The city of the viewer of the live stream. - City *string `json:"city,omitempty"` -} - -// NewLiveStreamSessionLocation instantiates a new LiveStreamSessionLocation object -// This constructor will assign default values to properties that have it defined, -// and makes sure properties required by API are set, but the set of arguments -// will change when the set of required properties is changed -func NewLiveStreamSessionLocation() *LiveStreamSessionLocation { - this := LiveStreamSessionLocation{} - return &this -} - -// NewLiveStreamSessionLocationWithDefaults instantiates a new LiveStreamSessionLocation object -// This constructor will only assign default values to properties that have it defined, -// but it doesn't guarantee that properties required by API are set -func NewLiveStreamSessionLocationWithDefaults() *LiveStreamSessionLocation { - this := LiveStreamSessionLocation{} - return &this -} - -// GetCountry returns the Country field value if set, zero value otherwise. -func (o *LiveStreamSessionLocation) GetCountry() string { - if o == nil || o.Country == nil { - var ret string - return ret - } - return *o.Country -} - -// GetCountryOk returns a tuple with the Country field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *LiveStreamSessionLocation) GetCountryOk() (*string, bool) { - if o == nil || o.Country == nil { - return nil, false - } - return o.Country, true -} - -// HasCountry returns a boolean if a field has been set. -func (o *LiveStreamSessionLocation) HasCountry() bool { - if o != nil && o.Country != nil { - return true - } - - return false -} - -// SetCountry gets a reference to the given string and assigns it to the Country field. -func (o *LiveStreamSessionLocation) SetCountry(v string) { - o.Country = &v -} - -// GetCity returns the City field value if set, zero value otherwise. -func (o *LiveStreamSessionLocation) GetCity() string { - if o == nil || o.City == nil { - var ret string - return ret - } - return *o.City -} - -// GetCityOk returns a tuple with the City field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *LiveStreamSessionLocation) GetCityOk() (*string, bool) { - if o == nil || o.City == nil { - return nil, false - } - return o.City, true -} - -// HasCity returns a boolean if a field has been set. -func (o *LiveStreamSessionLocation) HasCity() bool { - if o != nil && o.City != nil { - return true - } - - return false -} - -// SetCity gets a reference to the given string and assigns it to the City field. -func (o *LiveStreamSessionLocation) SetCity(v string) { - o.City = &v -} - -type NullableLiveStreamSessionLocation struct { - value *LiveStreamSessionLocation - isSet bool -} - -func (v NullableLiveStreamSessionLocation) Get() *LiveStreamSessionLocation { - return v.value -} - -func (v *NullableLiveStreamSessionLocation) Set(val *LiveStreamSessionLocation) { - v.value = val - v.isSet = true -} - -func (v NullableLiveStreamSessionLocation) IsSet() bool { - return v.isSet -} - -func (v *NullableLiveStreamSessionLocation) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableLiveStreamSessionLocation(val *LiveStreamSessionLocation) *NullableLiveStreamSessionLocation { - return &NullableLiveStreamSessionLocation{value: val, isSet: true} -} diff --git a/model_live_stream_session_referrer.go b/model_live_stream_session_referrer.go deleted file mode 100644 index cd1fc0c..0000000 --- a/model_live_stream_session_referrer.go +++ /dev/null @@ -1,199 +0,0 @@ -/* - * api.video - * - * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. - * - * API version: 1 - */ - -// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. - -package apivideosdk - -import ( -//"encoding/json" -) - -// LiveStreamSessionReferrer struct for LiveStreamSessionReferrer -type LiveStreamSessionReferrer struct { - // The website the viewer of the live stream was referred to in order to view the live stream. - Url *string `json:"url,omitempty"` - // The type of search that brought the viewer to the live stream. Organic would be they found it on their own, paid would be they found it via an advertisement. - Medium *string `json:"medium,omitempty"` - // Where the viewer came from to see the live stream (usually where they searched from). - Source *string `json:"source,omitempty"` - // What term they searched for that led them to the live stream. - SearchTerm *string `json:"searchTerm,omitempty"` -} - -// NewLiveStreamSessionReferrer instantiates a new LiveStreamSessionReferrer object -// This constructor will assign default values to properties that have it defined, -// and makes sure properties required by API are set, but the set of arguments -// will change when the set of required properties is changed -func NewLiveStreamSessionReferrer() *LiveStreamSessionReferrer { - this := LiveStreamSessionReferrer{} - return &this -} - -// NewLiveStreamSessionReferrerWithDefaults instantiates a new LiveStreamSessionReferrer object -// This constructor will only assign default values to properties that have it defined, -// but it doesn't guarantee that properties required by API are set -func NewLiveStreamSessionReferrerWithDefaults() *LiveStreamSessionReferrer { - this := LiveStreamSessionReferrer{} - return &this -} - -// GetUrl returns the Url field value if set, zero value otherwise. -func (o *LiveStreamSessionReferrer) GetUrl() string { - if o == nil || o.Url == nil { - var ret string - return ret - } - return *o.Url -} - -// GetUrlOk returns a tuple with the Url field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *LiveStreamSessionReferrer) GetUrlOk() (*string, bool) { - if o == nil || o.Url == nil { - return nil, false - } - return o.Url, true -} - -// HasUrl returns a boolean if a field has been set. -func (o *LiveStreamSessionReferrer) HasUrl() bool { - if o != nil && o.Url != nil { - return true - } - - return false -} - -// SetUrl gets a reference to the given string and assigns it to the Url field. -func (o *LiveStreamSessionReferrer) SetUrl(v string) { - o.Url = &v -} - -// GetMedium returns the Medium field value if set, zero value otherwise. -func (o *LiveStreamSessionReferrer) GetMedium() string { - if o == nil || o.Medium == nil { - var ret string - return ret - } - return *o.Medium -} - -// GetMediumOk returns a tuple with the Medium field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *LiveStreamSessionReferrer) GetMediumOk() (*string, bool) { - if o == nil || o.Medium == nil { - return nil, false - } - return o.Medium, true -} - -// HasMedium returns a boolean if a field has been set. -func (o *LiveStreamSessionReferrer) HasMedium() bool { - if o != nil && o.Medium != nil { - return true - } - - return false -} - -// SetMedium gets a reference to the given string and assigns it to the Medium field. -func (o *LiveStreamSessionReferrer) SetMedium(v string) { - o.Medium = &v -} - -// GetSource returns the Source field value if set, zero value otherwise. -func (o *LiveStreamSessionReferrer) GetSource() string { - if o == nil || o.Source == nil { - var ret string - return ret - } - return *o.Source -} - -// GetSourceOk returns a tuple with the Source field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *LiveStreamSessionReferrer) GetSourceOk() (*string, bool) { - if o == nil || o.Source == nil { - return nil, false - } - return o.Source, true -} - -// HasSource returns a boolean if a field has been set. -func (o *LiveStreamSessionReferrer) HasSource() bool { - if o != nil && o.Source != nil { - return true - } - - return false -} - -// SetSource gets a reference to the given string and assigns it to the Source field. -func (o *LiveStreamSessionReferrer) SetSource(v string) { - o.Source = &v -} - -// GetSearchTerm returns the SearchTerm field value if set, zero value otherwise. -func (o *LiveStreamSessionReferrer) GetSearchTerm() string { - if o == nil || o.SearchTerm == nil { - var ret string - return ret - } - return *o.SearchTerm -} - -// GetSearchTermOk returns a tuple with the SearchTerm field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *LiveStreamSessionReferrer) GetSearchTermOk() (*string, bool) { - if o == nil || o.SearchTerm == nil { - return nil, false - } - return o.SearchTerm, true -} - -// HasSearchTerm returns a boolean if a field has been set. -func (o *LiveStreamSessionReferrer) HasSearchTerm() bool { - if o != nil && o.SearchTerm != nil { - return true - } - - return false -} - -// SetSearchTerm gets a reference to the given string and assigns it to the SearchTerm field. -func (o *LiveStreamSessionReferrer) SetSearchTerm(v string) { - o.SearchTerm = &v -} - -type NullableLiveStreamSessionReferrer struct { - value *LiveStreamSessionReferrer - isSet bool -} - -func (v NullableLiveStreamSessionReferrer) Get() *LiveStreamSessionReferrer { - return v.value -} - -func (v *NullableLiveStreamSessionReferrer) Set(val *LiveStreamSessionReferrer) { - v.value = val - v.isSet = true -} - -func (v NullableLiveStreamSessionReferrer) IsSet() bool { - return v.isSet -} - -func (v *NullableLiveStreamSessionReferrer) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableLiveStreamSessionReferrer(val *LiveStreamSessionReferrer) *NullableLiveStreamSessionReferrer { - return &NullableLiveStreamSessionReferrer{value: val, isSet: true} -} diff --git a/model_live_stream_session_session.go b/model_live_stream_session_session.go deleted file mode 100644 index b40c942..0000000 --- a/model_live_stream_session_session.go +++ /dev/null @@ -1,165 +0,0 @@ -/* - * api.video - * - * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. - * - * API version: 1 - */ - -// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. - -package apivideosdk - -import ( -//"encoding/json" -) - -// LiveStreamSessionSession struct for LiveStreamSessionSession -type LiveStreamSessionSession struct { - // A unique identifier for your session. You can use this to track what happens during a specific session. - SessionId *string `json:"sessionId,omitempty"` - // When the session started, with the date and time presented in ISO-8601 format. - LoadedAt *string `json:"loadedAt,omitempty"` - // When the session ended, with the date and time presented in ISO-8601 format. - EndedAt *string `json:"endedAt,omitempty"` -} - -// NewLiveStreamSessionSession instantiates a new LiveStreamSessionSession object -// This constructor will assign default values to properties that have it defined, -// and makes sure properties required by API are set, but the set of arguments -// will change when the set of required properties is changed -func NewLiveStreamSessionSession() *LiveStreamSessionSession { - this := LiveStreamSessionSession{} - return &this -} - -// NewLiveStreamSessionSessionWithDefaults instantiates a new LiveStreamSessionSession object -// This constructor will only assign default values to properties that have it defined, -// but it doesn't guarantee that properties required by API are set -func NewLiveStreamSessionSessionWithDefaults() *LiveStreamSessionSession { - this := LiveStreamSessionSession{} - return &this -} - -// GetSessionId returns the SessionId field value if set, zero value otherwise. -func (o *LiveStreamSessionSession) GetSessionId() string { - if o == nil || o.SessionId == nil { - var ret string - return ret - } - return *o.SessionId -} - -// GetSessionIdOk returns a tuple with the SessionId field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *LiveStreamSessionSession) GetSessionIdOk() (*string, bool) { - if o == nil || o.SessionId == nil { - return nil, false - } - return o.SessionId, true -} - -// HasSessionId returns a boolean if a field has been set. -func (o *LiveStreamSessionSession) HasSessionId() bool { - if o != nil && o.SessionId != nil { - return true - } - - return false -} - -// SetSessionId gets a reference to the given string and assigns it to the SessionId field. -func (o *LiveStreamSessionSession) SetSessionId(v string) { - o.SessionId = &v -} - -// GetLoadedAt returns the LoadedAt field value if set, zero value otherwise. -func (o *LiveStreamSessionSession) GetLoadedAt() string { - if o == nil || o.LoadedAt == nil { - var ret string - return ret - } - return *o.LoadedAt -} - -// GetLoadedAtOk returns a tuple with the LoadedAt field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *LiveStreamSessionSession) GetLoadedAtOk() (*string, bool) { - if o == nil || o.LoadedAt == nil { - return nil, false - } - return o.LoadedAt, true -} - -// HasLoadedAt returns a boolean if a field has been set. -func (o *LiveStreamSessionSession) HasLoadedAt() bool { - if o != nil && o.LoadedAt != nil { - return true - } - - return false -} - -// SetLoadedAt gets a reference to the given string and assigns it to the LoadedAt field. -func (o *LiveStreamSessionSession) SetLoadedAt(v string) { - o.LoadedAt = &v -} - -// GetEndedAt returns the EndedAt field value if set, zero value otherwise. -func (o *LiveStreamSessionSession) GetEndedAt() string { - if o == nil || o.EndedAt == nil { - var ret string - return ret - } - return *o.EndedAt -} - -// GetEndedAtOk returns a tuple with the EndedAt field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *LiveStreamSessionSession) GetEndedAtOk() (*string, bool) { - if o == nil || o.EndedAt == nil { - return nil, false - } - return o.EndedAt, true -} - -// HasEndedAt returns a boolean if a field has been set. -func (o *LiveStreamSessionSession) HasEndedAt() bool { - if o != nil && o.EndedAt != nil { - return true - } - - return false -} - -// SetEndedAt gets a reference to the given string and assigns it to the EndedAt field. -func (o *LiveStreamSessionSession) SetEndedAt(v string) { - o.EndedAt = &v -} - -type NullableLiveStreamSessionSession struct { - value *LiveStreamSessionSession - isSet bool -} - -func (v NullableLiveStreamSessionSession) Get() *LiveStreamSessionSession { - return v.value -} - -func (v *NullableLiveStreamSessionSession) Set(val *LiveStreamSessionSession) { - v.value = val - v.isSet = true -} - -func (v NullableLiveStreamSessionSession) IsSet() bool { - return v.isSet -} - -func (v *NullableLiveStreamSessionSession) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableLiveStreamSessionSession(val *LiveStreamSessionSession) *NullableLiveStreamSessionSession { - return &NullableLiveStreamSessionSession{value: val, isSet: true} -} diff --git a/model_live_stream_update_payload.go b/model_live_stream_update_payload.go index 15a8ca1..4e0a104 100644 --- a/model_live_stream_update_payload.go +++ b/model_live_stream_update_payload.go @@ -18,11 +18,11 @@ import ( type LiveStreamUpdatePayload struct { // The name you want to use for your live stream. Name *string `json:"name,omitempty"` - // Whether your video can be viewed by everyone, or requires authentication to see it. A setting of false will require a unique token for each view. Learn more about the Private Video feature [here](https://docs.api.video/delivery-analytics/video-privacy-access-management). + // Whether your video can be viewed by everyone, or requires authentication to see it. A setting of false will require a unique token for each view. Learn more about the Private Video feature [here](https://docs.api.video/delivery/video-privacy-access-management). Public *bool `json:"public,omitempty"` // The unique ID for the player associated with a live stream that you want to update. PlayerId *string `json:"playerId,omitempty"` - // Use this parameter to add, edit, or remove RTMP services where you want to restream a live stream. The list can only contain up to 5 destinations. This operation updates all restream destinations in the same request. If you do not want to modify an existing restream destination, you need to include it in your request, otherwise it is removed. + // Use this parameter to add, edit, or remove `RTMPS` or `RTMP` services where you want to restream a live stream. The list can only contain up to 5 destinations. This operation updates all restream destinations in the same request. If you do not want to modify an existing restream destination, you need to include it in your request, otherwise it is removed. Restreams *[]RestreamsRequestObject `json:"restreams,omitempty"` } diff --git a/model_restreams_request_object.go b/model_restreams_request_object.go index bfc76f3..d5cc2da 100644 --- a/model_restreams_request_object.go +++ b/model_restreams_request_object.go @@ -18,7 +18,7 @@ import ( type RestreamsRequestObject struct { // Use this parameter to define a name for the restream destination. Name string `json:"name"` - // Use this parameter to set the RTMP URL of the restream destination. + // Use this parameter to set the `RTMPS` or `RTMP` server URL of the restream destination. ServerUrl string `json:"serverUrl"` // Use this parameter to provide the unique key of the live stream that you want to restream. StreamKey string `json:"streamKey"` diff --git a/model_restreams_response_object.go b/model_restreams_response_object.go index 27a3270..8ba14d7 100644 --- a/model_restreams_response_object.go +++ b/model_restreams_response_object.go @@ -18,7 +18,7 @@ import ( type RestreamsResponseObject struct { // Returns the name of a restream destination. Name *string `json:"name,omitempty"` - // Returns the RTMP URL of a restream destination. + // Returns the server URL of a restream destination. ServerUrl *string `json:"serverUrl,omitempty"` // Returns the unique key of the live stream that is set up for restreaming. StreamKey *string `json:"streamKey,omitempty"` diff --git a/model_unrecognized_request_url.go b/model_unrecognized_request_url.go new file mode 100644 index 0000000..3c4d6f8 --- /dev/null +++ b/model_unrecognized_request_url.go @@ -0,0 +1,165 @@ +/* + * api.video + * + * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. + * + * API version: 1 + */ + +// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. + +package apivideosdk + +import ( +//"encoding/json" +) + +// UnrecognizedRequestUrl struct for UnrecognizedRequestUrl +type UnrecognizedRequestUrl struct { + // A link to the error documentation. + Type *string `json:"type,omitempty"` + // A description of the error that occurred. + Title *string `json:"title,omitempty"` + // The HTTP status code. + Status *int32 `json:"status,omitempty"` +} + +// NewUnrecognizedRequestUrl instantiates a new UnrecognizedRequestUrl object +// This constructor will assign default values to properties that have it defined, +// and makes sure properties required by API are set, but the set of arguments +// will change when the set of required properties is changed +func NewUnrecognizedRequestUrl() *UnrecognizedRequestUrl { + this := UnrecognizedRequestUrl{} + return &this +} + +// NewUnrecognizedRequestUrlWithDefaults instantiates a new UnrecognizedRequestUrl object +// This constructor will only assign default values to properties that have it defined, +// but it doesn't guarantee that properties required by API are set +func NewUnrecognizedRequestUrlWithDefaults() *UnrecognizedRequestUrl { + this := UnrecognizedRequestUrl{} + return &this +} + +// GetType returns the Type field value if set, zero value otherwise. +func (o *UnrecognizedRequestUrl) GetType() string { + if o == nil || o.Type == nil { + var ret string + return ret + } + return *o.Type +} + +// GetTypeOk returns a tuple with the Type field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UnrecognizedRequestUrl) GetTypeOk() (*string, bool) { + if o == nil || o.Type == nil { + return nil, false + } + return o.Type, true +} + +// HasType returns a boolean if a field has been set. +func (o *UnrecognizedRequestUrl) HasType() bool { + if o != nil && o.Type != nil { + return true + } + + return false +} + +// SetType gets a reference to the given string and assigns it to the Type field. +func (o *UnrecognizedRequestUrl) SetType(v string) { + o.Type = &v +} + +// GetTitle returns the Title field value if set, zero value otherwise. +func (o *UnrecognizedRequestUrl) GetTitle() string { + if o == nil || o.Title == nil { + var ret string + return ret + } + return *o.Title +} + +// GetTitleOk returns a tuple with the Title field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UnrecognizedRequestUrl) GetTitleOk() (*string, bool) { + if o == nil || o.Title == nil { + return nil, false + } + return o.Title, true +} + +// HasTitle returns a boolean if a field has been set. +func (o *UnrecognizedRequestUrl) HasTitle() bool { + if o != nil && o.Title != nil { + return true + } + + return false +} + +// SetTitle gets a reference to the given string and assigns it to the Title field. +func (o *UnrecognizedRequestUrl) SetTitle(v string) { + o.Title = &v +} + +// GetStatus returns the Status field value if set, zero value otherwise. +func (o *UnrecognizedRequestUrl) GetStatus() int32 { + if o == nil || o.Status == nil { + var ret int32 + return ret + } + return *o.Status +} + +// GetStatusOk returns a tuple with the Status field value if set, nil otherwise +// and a boolean to check if the value has been set. +func (o *UnrecognizedRequestUrl) GetStatusOk() (*int32, bool) { + if o == nil || o.Status == nil { + return nil, false + } + return o.Status, true +} + +// HasStatus returns a boolean if a field has been set. +func (o *UnrecognizedRequestUrl) HasStatus() bool { + if o != nil && o.Status != nil { + return true + } + + return false +} + +// SetStatus gets a reference to the given int32 and assigns it to the Status field. +func (o *UnrecognizedRequestUrl) SetStatus(v int32) { + o.Status = &v +} + +type NullableUnrecognizedRequestUrl struct { + value *UnrecognizedRequestUrl + isSet bool +} + +func (v NullableUnrecognizedRequestUrl) Get() *UnrecognizedRequestUrl { + return v.value +} + +func (v *NullableUnrecognizedRequestUrl) Set(val *UnrecognizedRequestUrl) { + v.value = val + v.isSet = true +} + +func (v NullableUnrecognizedRequestUrl) IsSet() bool { + return v.isSet +} + +func (v *NullableUnrecognizedRequestUrl) Unset() { + v.value = nil + v.isSet = false +} + +func NewNullableUnrecognizedRequestUrl(val *UnrecognizedRequestUrl) *NullableUnrecognizedRequestUrl { + return &NullableUnrecognizedRequestUrl{value: val, isSet: true} +} diff --git a/model_video_creation_payload.go b/model_video_creation_payload.go index 55c72ac..2dcf82c 100644 --- a/model_video_creation_payload.go +++ b/model_video_creation_payload.go @@ -22,7 +22,7 @@ type VideoCreationPayload struct { Description *string `json:"description,omitempty"` // You can either add a video already on the web, by entering the URL of the video, or you can also enter the `videoId` of one of the videos you already have on your api.video acccount, and this will generate a copy of your video. Creating a copy of a video can be especially useful if you want to keep your original video and trim or apply a watermark onto the copy you would create. Source *string `json:"source,omitempty"` - // Default: True. If set to `false` the video will become private. More information on private videos can be found [here](https://docs.api.video/delivery-analytics/video-privacy-access-management) + // Default: True. If set to `false` the video will become private. More information on private videos can be found [here](https://docs.api.video/delivery/video-privacy-access-management) Public *bool `json:"public,omitempty"` // Indicates if your video is a 360/immersive video. Panoramic *bool `json:"panoramic,omitempty"` diff --git a/model_video_session.go b/model_video_session.go deleted file mode 100644 index 3401c25..0000000 --- a/model_video_session.go +++ /dev/null @@ -1,261 +0,0 @@ -/* - * api.video - * - * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. - * - * API version: 1 - */ - -// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. - -package apivideosdk - -import ( -//"encoding/json" -) - -// VideoSession struct for VideoSession -type VideoSession struct { - Session *VideoSessionSession `json:"session,omitempty"` - Location *VideoSessionLocation `json:"location,omitempty"` - Referrer *VideoSessionReferrer `json:"referrer,omitempty"` - Device *VideoSessionDevice `json:"device,omitempty"` - Os *VideoSessionOs `json:"os,omitempty"` - Client *VideoSessionClient `json:"client,omitempty"` -} - -// NewVideoSession instantiates a new VideoSession object -// This constructor will assign default values to properties that have it defined, -// and makes sure properties required by API are set, but the set of arguments -// will change when the set of required properties is changed -func NewVideoSession() *VideoSession { - this := VideoSession{} - return &this -} - -// NewVideoSessionWithDefaults instantiates a new VideoSession object -// This constructor will only assign default values to properties that have it defined, -// but it doesn't guarantee that properties required by API are set -func NewVideoSessionWithDefaults() *VideoSession { - this := VideoSession{} - return &this -} - -// GetSession returns the Session field value if set, zero value otherwise. -func (o *VideoSession) GetSession() VideoSessionSession { - if o == nil || o.Session == nil { - var ret VideoSessionSession - return ret - } - return *o.Session -} - -// GetSessionOk returns a tuple with the Session field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VideoSession) GetSessionOk() (*VideoSessionSession, bool) { - if o == nil || o.Session == nil { - return nil, false - } - return o.Session, true -} - -// HasSession returns a boolean if a field has been set. -func (o *VideoSession) HasSession() bool { - if o != nil && o.Session != nil { - return true - } - - return false -} - -// SetSession gets a reference to the given VideoSessionSession and assigns it to the Session field. -func (o *VideoSession) SetSession(v VideoSessionSession) { - o.Session = &v -} - -// GetLocation returns the Location field value if set, zero value otherwise. -func (o *VideoSession) GetLocation() VideoSessionLocation { - if o == nil || o.Location == nil { - var ret VideoSessionLocation - return ret - } - return *o.Location -} - -// GetLocationOk returns a tuple with the Location field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VideoSession) GetLocationOk() (*VideoSessionLocation, bool) { - if o == nil || o.Location == nil { - return nil, false - } - return o.Location, true -} - -// HasLocation returns a boolean if a field has been set. -func (o *VideoSession) HasLocation() bool { - if o != nil && o.Location != nil { - return true - } - - return false -} - -// SetLocation gets a reference to the given VideoSessionLocation and assigns it to the Location field. -func (o *VideoSession) SetLocation(v VideoSessionLocation) { - o.Location = &v -} - -// GetReferrer returns the Referrer field value if set, zero value otherwise. -func (o *VideoSession) GetReferrer() VideoSessionReferrer { - if o == nil || o.Referrer == nil { - var ret VideoSessionReferrer - return ret - } - return *o.Referrer -} - -// GetReferrerOk returns a tuple with the Referrer field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VideoSession) GetReferrerOk() (*VideoSessionReferrer, bool) { - if o == nil || o.Referrer == nil { - return nil, false - } - return o.Referrer, true -} - -// HasReferrer returns a boolean if a field has been set. -func (o *VideoSession) HasReferrer() bool { - if o != nil && o.Referrer != nil { - return true - } - - return false -} - -// SetReferrer gets a reference to the given VideoSessionReferrer and assigns it to the Referrer field. -func (o *VideoSession) SetReferrer(v VideoSessionReferrer) { - o.Referrer = &v -} - -// GetDevice returns the Device field value if set, zero value otherwise. -func (o *VideoSession) GetDevice() VideoSessionDevice { - if o == nil || o.Device == nil { - var ret VideoSessionDevice - return ret - } - return *o.Device -} - -// GetDeviceOk returns a tuple with the Device field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VideoSession) GetDeviceOk() (*VideoSessionDevice, bool) { - if o == nil || o.Device == nil { - return nil, false - } - return o.Device, true -} - -// HasDevice returns a boolean if a field has been set. -func (o *VideoSession) HasDevice() bool { - if o != nil && o.Device != nil { - return true - } - - return false -} - -// SetDevice gets a reference to the given VideoSessionDevice and assigns it to the Device field. -func (o *VideoSession) SetDevice(v VideoSessionDevice) { - o.Device = &v -} - -// GetOs returns the Os field value if set, zero value otherwise. -func (o *VideoSession) GetOs() VideoSessionOs { - if o == nil || o.Os == nil { - var ret VideoSessionOs - return ret - } - return *o.Os -} - -// GetOsOk returns a tuple with the Os field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VideoSession) GetOsOk() (*VideoSessionOs, bool) { - if o == nil || o.Os == nil { - return nil, false - } - return o.Os, true -} - -// HasOs returns a boolean if a field has been set. -func (o *VideoSession) HasOs() bool { - if o != nil && o.Os != nil { - return true - } - - return false -} - -// SetOs gets a reference to the given VideoSessionOs and assigns it to the Os field. -func (o *VideoSession) SetOs(v VideoSessionOs) { - o.Os = &v -} - -// GetClient returns the Client field value if set, zero value otherwise. -func (o *VideoSession) GetClient() VideoSessionClient { - if o == nil || o.Client == nil { - var ret VideoSessionClient - return ret - } - return *o.Client -} - -// GetClientOk returns a tuple with the Client field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VideoSession) GetClientOk() (*VideoSessionClient, bool) { - if o == nil || o.Client == nil { - return nil, false - } - return o.Client, true -} - -// HasClient returns a boolean if a field has been set. -func (o *VideoSession) HasClient() bool { - if o != nil && o.Client != nil { - return true - } - - return false -} - -// SetClient gets a reference to the given VideoSessionClient and assigns it to the Client field. -func (o *VideoSession) SetClient(v VideoSessionClient) { - o.Client = &v -} - -type NullableVideoSession struct { - value *VideoSession - isSet bool -} - -func (v NullableVideoSession) Get() *VideoSession { - return v.value -} - -func (v *NullableVideoSession) Set(val *VideoSession) { - v.value = val - v.isSet = true -} - -func (v NullableVideoSession) IsSet() bool { - return v.isSet -} - -func (v *NullableVideoSession) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableVideoSession(val *VideoSession) *NullableVideoSession { - return &NullableVideoSession{value: val, isSet: true} -} diff --git a/model_video_session_client.go b/model_video_session_client.go deleted file mode 100644 index 25e484b..0000000 --- a/model_video_session_client.go +++ /dev/null @@ -1,165 +0,0 @@ -/* - * api.video - * - * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. - * - * API version: 1 - */ - -// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. - -package apivideosdk - -import ( -//"encoding/json" -) - -// VideoSessionClient What kind of browser the viewer is using for the video session. -type VideoSessionClient struct { - // The name of the browser used to view the video session. - Name *string `json:"name,omitempty"` - // The version of the browser used to view the video session. - Version *string `json:"version,omitempty"` - // The type of client used to view the video session. - Type *string `json:"type,omitempty"` -} - -// NewVideoSessionClient instantiates a new VideoSessionClient object -// This constructor will assign default values to properties that have it defined, -// and makes sure properties required by API are set, but the set of arguments -// will change when the set of required properties is changed -func NewVideoSessionClient() *VideoSessionClient { - this := VideoSessionClient{} - return &this -} - -// NewVideoSessionClientWithDefaults instantiates a new VideoSessionClient object -// This constructor will only assign default values to properties that have it defined, -// but it doesn't guarantee that properties required by API are set -func NewVideoSessionClientWithDefaults() *VideoSessionClient { - this := VideoSessionClient{} - return &this -} - -// GetName returns the Name field value if set, zero value otherwise. -func (o *VideoSessionClient) GetName() string { - if o == nil || o.Name == nil { - var ret string - return ret - } - return *o.Name -} - -// GetNameOk returns a tuple with the Name field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VideoSessionClient) GetNameOk() (*string, bool) { - if o == nil || o.Name == nil { - return nil, false - } - return o.Name, true -} - -// HasName returns a boolean if a field has been set. -func (o *VideoSessionClient) HasName() bool { - if o != nil && o.Name != nil { - return true - } - - return false -} - -// SetName gets a reference to the given string and assigns it to the Name field. -func (o *VideoSessionClient) SetName(v string) { - o.Name = &v -} - -// GetVersion returns the Version field value if set, zero value otherwise. -func (o *VideoSessionClient) GetVersion() string { - if o == nil || o.Version == nil { - var ret string - return ret - } - return *o.Version -} - -// GetVersionOk returns a tuple with the Version field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VideoSessionClient) GetVersionOk() (*string, bool) { - if o == nil || o.Version == nil { - return nil, false - } - return o.Version, true -} - -// HasVersion returns a boolean if a field has been set. -func (o *VideoSessionClient) HasVersion() bool { - if o != nil && o.Version != nil { - return true - } - - return false -} - -// SetVersion gets a reference to the given string and assigns it to the Version field. -func (o *VideoSessionClient) SetVersion(v string) { - o.Version = &v -} - -// GetType returns the Type field value if set, zero value otherwise. -func (o *VideoSessionClient) GetType() string { - if o == nil || o.Type == nil { - var ret string - return ret - } - return *o.Type -} - -// GetTypeOk returns a tuple with the Type field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VideoSessionClient) GetTypeOk() (*string, bool) { - if o == nil || o.Type == nil { - return nil, false - } - return o.Type, true -} - -// HasType returns a boolean if a field has been set. -func (o *VideoSessionClient) HasType() bool { - if o != nil && o.Type != nil { - return true - } - - return false -} - -// SetType gets a reference to the given string and assigns it to the Type field. -func (o *VideoSessionClient) SetType(v string) { - o.Type = &v -} - -type NullableVideoSessionClient struct { - value *VideoSessionClient - isSet bool -} - -func (v NullableVideoSessionClient) Get() *VideoSessionClient { - return v.value -} - -func (v *NullableVideoSessionClient) Set(val *VideoSessionClient) { - v.value = val - v.isSet = true -} - -func (v NullableVideoSessionClient) IsSet() bool { - return v.isSet -} - -func (v *NullableVideoSessionClient) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableVideoSessionClient(val *VideoSessionClient) *NullableVideoSessionClient { - return &NullableVideoSessionClient{value: val, isSet: true} -} diff --git a/model_video_session_device.go b/model_video_session_device.go deleted file mode 100644 index b5bd96d..0000000 --- a/model_video_session_device.go +++ /dev/null @@ -1,165 +0,0 @@ -/* - * api.video - * - * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. - * - * API version: 1 - */ - -// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. - -package apivideosdk - -import ( -//"encoding/json" -) - -// VideoSessionDevice What type of device the user is on when in the video session. -type VideoSessionDevice struct { - // What the type is like desktop, laptop, mobile. - Type *string `json:"type,omitempty"` - // If known, what the brand of the device is, like Apple, Dell, etc. - Vendor *string `json:"vendor,omitempty"` - // The specific model of the device, if known. - Model *string `json:"model,omitempty"` -} - -// NewVideoSessionDevice instantiates a new VideoSessionDevice object -// This constructor will assign default values to properties that have it defined, -// and makes sure properties required by API are set, but the set of arguments -// will change when the set of required properties is changed -func NewVideoSessionDevice() *VideoSessionDevice { - this := VideoSessionDevice{} - return &this -} - -// NewVideoSessionDeviceWithDefaults instantiates a new VideoSessionDevice object -// This constructor will only assign default values to properties that have it defined, -// but it doesn't guarantee that properties required by API are set -func NewVideoSessionDeviceWithDefaults() *VideoSessionDevice { - this := VideoSessionDevice{} - return &this -} - -// GetType returns the Type field value if set, zero value otherwise. -func (o *VideoSessionDevice) GetType() string { - if o == nil || o.Type == nil { - var ret string - return ret - } - return *o.Type -} - -// GetTypeOk returns a tuple with the Type field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VideoSessionDevice) GetTypeOk() (*string, bool) { - if o == nil || o.Type == nil { - return nil, false - } - return o.Type, true -} - -// HasType returns a boolean if a field has been set. -func (o *VideoSessionDevice) HasType() bool { - if o != nil && o.Type != nil { - return true - } - - return false -} - -// SetType gets a reference to the given string and assigns it to the Type field. -func (o *VideoSessionDevice) SetType(v string) { - o.Type = &v -} - -// GetVendor returns the Vendor field value if set, zero value otherwise. -func (o *VideoSessionDevice) GetVendor() string { - if o == nil || o.Vendor == nil { - var ret string - return ret - } - return *o.Vendor -} - -// GetVendorOk returns a tuple with the Vendor field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VideoSessionDevice) GetVendorOk() (*string, bool) { - if o == nil || o.Vendor == nil { - return nil, false - } - return o.Vendor, true -} - -// HasVendor returns a boolean if a field has been set. -func (o *VideoSessionDevice) HasVendor() bool { - if o != nil && o.Vendor != nil { - return true - } - - return false -} - -// SetVendor gets a reference to the given string and assigns it to the Vendor field. -func (o *VideoSessionDevice) SetVendor(v string) { - o.Vendor = &v -} - -// GetModel returns the Model field value if set, zero value otherwise. -func (o *VideoSessionDevice) GetModel() string { - if o == nil || o.Model == nil { - var ret string - return ret - } - return *o.Model -} - -// GetModelOk returns a tuple with the Model field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VideoSessionDevice) GetModelOk() (*string, bool) { - if o == nil || o.Model == nil { - return nil, false - } - return o.Model, true -} - -// HasModel returns a boolean if a field has been set. -func (o *VideoSessionDevice) HasModel() bool { - if o != nil && o.Model != nil { - return true - } - - return false -} - -// SetModel gets a reference to the given string and assigns it to the Model field. -func (o *VideoSessionDevice) SetModel(v string) { - o.Model = &v -} - -type NullableVideoSessionDevice struct { - value *VideoSessionDevice - isSet bool -} - -func (v NullableVideoSessionDevice) Get() *VideoSessionDevice { - return v.value -} - -func (v *NullableVideoSessionDevice) Set(val *VideoSessionDevice) { - v.value = val - v.isSet = true -} - -func (v NullableVideoSessionDevice) IsSet() bool { - return v.isSet -} - -func (v *NullableVideoSessionDevice) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableVideoSessionDevice(val *VideoSessionDevice) *NullableVideoSessionDevice { - return &NullableVideoSessionDevice{value: val, isSet: true} -} diff --git a/model_video_session_location.go b/model_video_session_location.go deleted file mode 100644 index 9f4e5db..0000000 --- a/model_video_session_location.go +++ /dev/null @@ -1,142 +0,0 @@ -/* - * api.video - * - * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. - * - * API version: 1 - */ - -// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. - -package apivideosdk - -import ( -//"encoding/json" -) - -// VideoSessionLocation The location of the viewer. -type VideoSessionLocation struct { - // The country of the viewer. - Country *string `json:"country,omitempty"` - // The city of the viewer. - City *NullableString `json:"city,omitempty"` -} - -// NewVideoSessionLocation instantiates a new VideoSessionLocation object -// This constructor will assign default values to properties that have it defined, -// and makes sure properties required by API are set, but the set of arguments -// will change when the set of required properties is changed -func NewVideoSessionLocation() *VideoSessionLocation { - this := VideoSessionLocation{} - return &this -} - -// NewVideoSessionLocationWithDefaults instantiates a new VideoSessionLocation object -// This constructor will only assign default values to properties that have it defined, -// but it doesn't guarantee that properties required by API are set -func NewVideoSessionLocationWithDefaults() *VideoSessionLocation { - this := VideoSessionLocation{} - return &this -} - -// GetCountry returns the Country field value if set, zero value otherwise. -func (o *VideoSessionLocation) GetCountry() string { - if o == nil || o.Country == nil { - var ret string - return ret - } - return *o.Country -} - -// GetCountryOk returns a tuple with the Country field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VideoSessionLocation) GetCountryOk() (*string, bool) { - if o == nil || o.Country == nil { - return nil, false - } - return o.Country, true -} - -// HasCountry returns a boolean if a field has been set. -func (o *VideoSessionLocation) HasCountry() bool { - if o != nil && o.Country != nil { - return true - } - - return false -} - -// SetCountry gets a reference to the given string and assigns it to the Country field. -func (o *VideoSessionLocation) SetCountry(v string) { - o.Country = &v -} - -// GetCity returns the City field value if set, zero value otherwise (both if not set or set to explicit null). -func (o *VideoSessionLocation) GetCity() string { - if o == nil || o.City.Get() == nil { - var ret string - return ret - } - return *o.City.Get() -} - -// GetCityOk returns a tuple with the City field value if set, nil otherwise -// and a boolean to check if the value has been set. -// NOTE: If the value is an explicit nil, `nil, true` will be returned -func (o *VideoSessionLocation) GetCityOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.City.Get(), o.City.IsSet() -} - -// HasCity returns a boolean if a field has been set. -func (o *VideoSessionLocation) HasCity() bool { - if o != nil && o.City.IsSet() { - return true - } - - return false -} - -// SetCity gets a reference to the given NullableString and assigns it to the City field. -func (o *VideoSessionLocation) SetCity(v string) { - o.City.Set(&v) -} - -// SetCityNil sets the value for City to be an explicit nil -func (o *VideoSessionLocation) SetCityNil() { - o.City.Set(nil) -} - -// UnsetCity ensures that no value is present for City, not even an explicit nil -func (o *VideoSessionLocation) UnsetCity() { - o.City.Unset() -} - -type NullableVideoSessionLocation struct { - value *VideoSessionLocation - isSet bool -} - -func (v NullableVideoSessionLocation) Get() *VideoSessionLocation { - return v.value -} - -func (v *NullableVideoSessionLocation) Set(val *VideoSessionLocation) { - v.value = val - v.isSet = true -} - -func (v NullableVideoSessionLocation) IsSet() bool { - return v.isSet -} - -func (v *NullableVideoSessionLocation) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableVideoSessionLocation(val *VideoSessionLocation) *NullableVideoSessionLocation { - return &NullableVideoSessionLocation{value: val, isSet: true} -} diff --git a/model_video_session_os.go b/model_video_session_os.go deleted file mode 100644 index da9d209..0000000 --- a/model_video_session_os.go +++ /dev/null @@ -1,165 +0,0 @@ -/* - * api.video - * - * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. - * - * API version: 1 - */ - -// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. - -package apivideosdk - -import ( -//"encoding/json" -) - -// VideoSessionOs The operating system the viewer is on. -type VideoSessionOs struct { - // The name of the operating system. - Name *string `json:"name,omitempty"` - // The nickname for the operating system, often representing the version. - Shortname *string `json:"shortname,omitempty"` - // The version of the operating system. - Version *string `json:"version,omitempty"` -} - -// NewVideoSessionOs instantiates a new VideoSessionOs object -// This constructor will assign default values to properties that have it defined, -// and makes sure properties required by API are set, but the set of arguments -// will change when the set of required properties is changed -func NewVideoSessionOs() *VideoSessionOs { - this := VideoSessionOs{} - return &this -} - -// NewVideoSessionOsWithDefaults instantiates a new VideoSessionOs object -// This constructor will only assign default values to properties that have it defined, -// but it doesn't guarantee that properties required by API are set -func NewVideoSessionOsWithDefaults() *VideoSessionOs { - this := VideoSessionOs{} - return &this -} - -// GetName returns the Name field value if set, zero value otherwise. -func (o *VideoSessionOs) GetName() string { - if o == nil || o.Name == nil { - var ret string - return ret - } - return *o.Name -} - -// GetNameOk returns a tuple with the Name field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VideoSessionOs) GetNameOk() (*string, bool) { - if o == nil || o.Name == nil { - return nil, false - } - return o.Name, true -} - -// HasName returns a boolean if a field has been set. -func (o *VideoSessionOs) HasName() bool { - if o != nil && o.Name != nil { - return true - } - - return false -} - -// SetName gets a reference to the given string and assigns it to the Name field. -func (o *VideoSessionOs) SetName(v string) { - o.Name = &v -} - -// GetShortname returns the Shortname field value if set, zero value otherwise. -func (o *VideoSessionOs) GetShortname() string { - if o == nil || o.Shortname == nil { - var ret string - return ret - } - return *o.Shortname -} - -// GetShortnameOk returns a tuple with the Shortname field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VideoSessionOs) GetShortnameOk() (*string, bool) { - if o == nil || o.Shortname == nil { - return nil, false - } - return o.Shortname, true -} - -// HasShortname returns a boolean if a field has been set. -func (o *VideoSessionOs) HasShortname() bool { - if o != nil && o.Shortname != nil { - return true - } - - return false -} - -// SetShortname gets a reference to the given string and assigns it to the Shortname field. -func (o *VideoSessionOs) SetShortname(v string) { - o.Shortname = &v -} - -// GetVersion returns the Version field value if set, zero value otherwise. -func (o *VideoSessionOs) GetVersion() string { - if o == nil || o.Version == nil { - var ret string - return ret - } - return *o.Version -} - -// GetVersionOk returns a tuple with the Version field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VideoSessionOs) GetVersionOk() (*string, bool) { - if o == nil || o.Version == nil { - return nil, false - } - return o.Version, true -} - -// HasVersion returns a boolean if a field has been set. -func (o *VideoSessionOs) HasVersion() bool { - if o != nil && o.Version != nil { - return true - } - - return false -} - -// SetVersion gets a reference to the given string and assigns it to the Version field. -func (o *VideoSessionOs) SetVersion(v string) { - o.Version = &v -} - -type NullableVideoSessionOs struct { - value *VideoSessionOs - isSet bool -} - -func (v NullableVideoSessionOs) Get() *VideoSessionOs { - return v.value -} - -func (v *NullableVideoSessionOs) Set(val *VideoSessionOs) { - v.value = val - v.isSet = true -} - -func (v NullableVideoSessionOs) IsSet() bool { - return v.isSet -} - -func (v *NullableVideoSessionOs) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableVideoSessionOs(val *VideoSessionOs) *NullableVideoSessionOs { - return &NullableVideoSessionOs{value: val, isSet: true} -} diff --git a/model_video_session_referrer.go b/model_video_session_referrer.go deleted file mode 100644 index 6c67559..0000000 --- a/model_video_session_referrer.go +++ /dev/null @@ -1,210 +0,0 @@ -/* - * api.video - * - * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. - * - * API version: 1 - */ - -// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. - -package apivideosdk - -import ( -//"encoding/json" -) - -// VideoSessionReferrer struct for VideoSessionReferrer -type VideoSessionReferrer struct { - // The link the viewer used to reach the video session. - Url *NullableString `json:"url,omitempty"` - // How they arrived at the site, for example organic or paid. Organic meaning they found it themselves and paid meaning they followed a link from an advertisement. - Medium *string `json:"medium,omitempty"` - // The source the referrer came from to the video session. For example if they searched through google to find the stream. - Source *string `json:"source,omitempty"` - // The search term they typed to arrive at the video session. - SearchTerm *string `json:"searchTerm,omitempty"` -} - -// NewVideoSessionReferrer instantiates a new VideoSessionReferrer object -// This constructor will assign default values to properties that have it defined, -// and makes sure properties required by API are set, but the set of arguments -// will change when the set of required properties is changed -func NewVideoSessionReferrer() *VideoSessionReferrer { - this := VideoSessionReferrer{} - return &this -} - -// NewVideoSessionReferrerWithDefaults instantiates a new VideoSessionReferrer object -// This constructor will only assign default values to properties that have it defined, -// but it doesn't guarantee that properties required by API are set -func NewVideoSessionReferrerWithDefaults() *VideoSessionReferrer { - this := VideoSessionReferrer{} - return &this -} - -// GetUrl returns the Url field value if set, zero value otherwise (both if not set or set to explicit null). -func (o *VideoSessionReferrer) GetUrl() string { - if o == nil || o.Url.Get() == nil { - var ret string - return ret - } - return *o.Url.Get() -} - -// GetUrlOk returns a tuple with the Url field value if set, nil otherwise -// and a boolean to check if the value has been set. -// NOTE: If the value is an explicit nil, `nil, true` will be returned -func (o *VideoSessionReferrer) GetUrlOk() (*string, bool) { - if o == nil { - return nil, false - } - return o.Url.Get(), o.Url.IsSet() -} - -// HasUrl returns a boolean if a field has been set. -func (o *VideoSessionReferrer) HasUrl() bool { - if o != nil && o.Url.IsSet() { - return true - } - - return false -} - -// SetUrl gets a reference to the given NullableString and assigns it to the Url field. -func (o *VideoSessionReferrer) SetUrl(v string) { - o.Url.Set(&v) -} - -// SetUrlNil sets the value for Url to be an explicit nil -func (o *VideoSessionReferrer) SetUrlNil() { - o.Url.Set(nil) -} - -// UnsetUrl ensures that no value is present for Url, not even an explicit nil -func (o *VideoSessionReferrer) UnsetUrl() { - o.Url.Unset() -} - -// GetMedium returns the Medium field value if set, zero value otherwise. -func (o *VideoSessionReferrer) GetMedium() string { - if o == nil || o.Medium == nil { - var ret string - return ret - } - return *o.Medium -} - -// GetMediumOk returns a tuple with the Medium field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VideoSessionReferrer) GetMediumOk() (*string, bool) { - if o == nil || o.Medium == nil { - return nil, false - } - return o.Medium, true -} - -// HasMedium returns a boolean if a field has been set. -func (o *VideoSessionReferrer) HasMedium() bool { - if o != nil && o.Medium != nil { - return true - } - - return false -} - -// SetMedium gets a reference to the given string and assigns it to the Medium field. -func (o *VideoSessionReferrer) SetMedium(v string) { - o.Medium = &v -} - -// GetSource returns the Source field value if set, zero value otherwise. -func (o *VideoSessionReferrer) GetSource() string { - if o == nil || o.Source == nil { - var ret string - return ret - } - return *o.Source -} - -// GetSourceOk returns a tuple with the Source field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VideoSessionReferrer) GetSourceOk() (*string, bool) { - if o == nil || o.Source == nil { - return nil, false - } - return o.Source, true -} - -// HasSource returns a boolean if a field has been set. -func (o *VideoSessionReferrer) HasSource() bool { - if o != nil && o.Source != nil { - return true - } - - return false -} - -// SetSource gets a reference to the given string and assigns it to the Source field. -func (o *VideoSessionReferrer) SetSource(v string) { - o.Source = &v -} - -// GetSearchTerm returns the SearchTerm field value if set, zero value otherwise. -func (o *VideoSessionReferrer) GetSearchTerm() string { - if o == nil || o.SearchTerm == nil { - var ret string - return ret - } - return *o.SearchTerm -} - -// GetSearchTermOk returns a tuple with the SearchTerm field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VideoSessionReferrer) GetSearchTermOk() (*string, bool) { - if o == nil || o.SearchTerm == nil { - return nil, false - } - return o.SearchTerm, true -} - -// HasSearchTerm returns a boolean if a field has been set. -func (o *VideoSessionReferrer) HasSearchTerm() bool { - if o != nil && o.SearchTerm != nil { - return true - } - - return false -} - -// SetSearchTerm gets a reference to the given string and assigns it to the SearchTerm field. -func (o *VideoSessionReferrer) SetSearchTerm(v string) { - o.SearchTerm = &v -} - -type NullableVideoSessionReferrer struct { - value *VideoSessionReferrer - isSet bool -} - -func (v NullableVideoSessionReferrer) Get() *VideoSessionReferrer { - return v.value -} - -func (v *NullableVideoSessionReferrer) Set(val *VideoSessionReferrer) { - v.value = val - v.isSet = true -} - -func (v NullableVideoSessionReferrer) IsSet() bool { - return v.isSet -} - -func (v *NullableVideoSessionReferrer) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableVideoSessionReferrer(val *VideoSessionReferrer) *NullableVideoSessionReferrer { - return &NullableVideoSessionReferrer{value: val, isSet: true} -} diff --git a/model_video_session_session.go b/model_video_session_session.go deleted file mode 100644 index b592fdd..0000000 --- a/model_video_session_session.go +++ /dev/null @@ -1,199 +0,0 @@ -/* - * api.video - * - * api.video is an API that encodes on the go to facilitate immediate playback, enhancing viewer streaming experiences across multiple devices and platforms. You can stream live or on-demand online videos within minutes. - * - * API version: 1 - */ - -// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT. - -package apivideosdk - -import ( -//"encoding/json" -) - -// VideoSessionSession struct for VideoSessionSession -type VideoSessionSession struct { - // The unique identifier for the session that you can use to track what happens during it. - SessionId *string `json:"sessionId,omitempty"` - // When the video session started, presented in ISO-8601 format. - LoadedAt *string `json:"loadedAt,omitempty"` - // When the video session ended, presented in ISO-8601 format. - EndedAt *string `json:"endedAt,omitempty"` - // A list of key value pairs that you use to provide metadata for your video. These pairs can be made dynamic, allowing you to segment your audience. You can also just use the pairs as another way to tag and categorize your videos. - Metadata *[]Metadata `json:"metadata,omitempty"` -} - -// NewVideoSessionSession instantiates a new VideoSessionSession object -// This constructor will assign default values to properties that have it defined, -// and makes sure properties required by API are set, but the set of arguments -// will change when the set of required properties is changed -func NewVideoSessionSession() *VideoSessionSession { - this := VideoSessionSession{} - return &this -} - -// NewVideoSessionSessionWithDefaults instantiates a new VideoSessionSession object -// This constructor will only assign default values to properties that have it defined, -// but it doesn't guarantee that properties required by API are set -func NewVideoSessionSessionWithDefaults() *VideoSessionSession { - this := VideoSessionSession{} - return &this -} - -// GetSessionId returns the SessionId field value if set, zero value otherwise. -func (o *VideoSessionSession) GetSessionId() string { - if o == nil || o.SessionId == nil { - var ret string - return ret - } - return *o.SessionId -} - -// GetSessionIdOk returns a tuple with the SessionId field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VideoSessionSession) GetSessionIdOk() (*string, bool) { - if o == nil || o.SessionId == nil { - return nil, false - } - return o.SessionId, true -} - -// HasSessionId returns a boolean if a field has been set. -func (o *VideoSessionSession) HasSessionId() bool { - if o != nil && o.SessionId != nil { - return true - } - - return false -} - -// SetSessionId gets a reference to the given string and assigns it to the SessionId field. -func (o *VideoSessionSession) SetSessionId(v string) { - o.SessionId = &v -} - -// GetLoadedAt returns the LoadedAt field value if set, zero value otherwise. -func (o *VideoSessionSession) GetLoadedAt() string { - if o == nil || o.LoadedAt == nil { - var ret string - return ret - } - return *o.LoadedAt -} - -// GetLoadedAtOk returns a tuple with the LoadedAt field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VideoSessionSession) GetLoadedAtOk() (*string, bool) { - if o == nil || o.LoadedAt == nil { - return nil, false - } - return o.LoadedAt, true -} - -// HasLoadedAt returns a boolean if a field has been set. -func (o *VideoSessionSession) HasLoadedAt() bool { - if o != nil && o.LoadedAt != nil { - return true - } - - return false -} - -// SetLoadedAt gets a reference to the given string and assigns it to the LoadedAt field. -func (o *VideoSessionSession) SetLoadedAt(v string) { - o.LoadedAt = &v -} - -// GetEndedAt returns the EndedAt field value if set, zero value otherwise. -func (o *VideoSessionSession) GetEndedAt() string { - if o == nil || o.EndedAt == nil { - var ret string - return ret - } - return *o.EndedAt -} - -// GetEndedAtOk returns a tuple with the EndedAt field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VideoSessionSession) GetEndedAtOk() (*string, bool) { - if o == nil || o.EndedAt == nil { - return nil, false - } - return o.EndedAt, true -} - -// HasEndedAt returns a boolean if a field has been set. -func (o *VideoSessionSession) HasEndedAt() bool { - if o != nil && o.EndedAt != nil { - return true - } - - return false -} - -// SetEndedAt gets a reference to the given string and assigns it to the EndedAt field. -func (o *VideoSessionSession) SetEndedAt(v string) { - o.EndedAt = &v -} - -// GetMetadata returns the Metadata field value if set, zero value otherwise. -func (o *VideoSessionSession) GetMetadata() []Metadata { - if o == nil || o.Metadata == nil { - var ret []Metadata - return ret - } - return *o.Metadata -} - -// GetMetadataOk returns a tuple with the Metadata field value if set, nil otherwise -// and a boolean to check if the value has been set. -func (o *VideoSessionSession) GetMetadataOk() (*[]Metadata, bool) { - if o == nil || o.Metadata == nil { - return nil, false - } - return o.Metadata, true -} - -// HasMetadata returns a boolean if a field has been set. -func (o *VideoSessionSession) HasMetadata() bool { - if o != nil && o.Metadata != nil { - return true - } - - return false -} - -// SetMetadata gets a reference to the given []Metadata and assigns it to the Metadata field. -func (o *VideoSessionSession) SetMetadata(v []Metadata) { - o.Metadata = &v -} - -type NullableVideoSessionSession struct { - value *VideoSessionSession - isSet bool -} - -func (v NullableVideoSessionSession) Get() *VideoSessionSession { - return v.value -} - -func (v *NullableVideoSessionSession) Set(val *VideoSessionSession) { - v.value = val - v.isSet = true -} - -func (v NullableVideoSessionSession) IsSet() bool { - return v.isSet -} - -func (v *NullableVideoSessionSession) Unset() { - v.value = nil - v.isSet = false -} - -func NewNullableVideoSessionSession(val *VideoSessionSession) *NullableVideoSessionSession { - return &NullableVideoSessionSession{value: val, isSet: true} -}