Skip to content

Commit

Permalink
feat: [video-stitcher] add apis for Create, Read, Update, Delete for …
Browse files Browse the repository at this point in the history
…VODConfigs (#5378)

* feat: add apis for Create, Read, Update, Delete for VODConfigs
feat: allowed usage for VODConfigs in VODSession
feat: added token config for MediaCdnKey
feat: added targetting parameter support to Livesession
feat: added adtracking to Livesession
feat: added fetchoptions with custom headers for Live and VODConfigs

docs: Added apis for Create, Read, Update, Delete For VODConfigs. Added vodConfig usage in VODSession. Added TokenConfig for MediaCdnKey. Added targeting_parameter and ad_tracking for Livesession. Added FetchOptions for Live and VOD configs.
PiperOrigin-RevId: 636368401

Source-Link: googleapis/googleapis@30717c0

Source-Link: googleapis/googleapis-gen@cc30711
Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLXZpZGVvLXN0aXRjaGVyLy5Pd2xCb3QueWFtbCIsImgiOiJjYzMwNzExZWY4ZTE2ZDQ4ODdkMTlmNjc3YjkzODJkZjBhZTYwZWQ4In0=

* 🦉 Updates from OwlBot post-processor

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

---------

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
Co-authored-by: Daniel Bankhead <[email protected]>
Co-authored-by: danieljbruce <[email protected]>
  • Loading branch information
4 people authored May 29, 2024
1 parent 81e759d commit 10d9310
Show file tree
Hide file tree
Showing 26 changed files with 16,105 additions and 7,605 deletions.
6 changes: 6 additions & 0 deletions packages/google-cloud-video-stitcher/README.md

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,9 @@ option java_multiple_files = true;
option java_outer_classname = "AdTagDetailsProto";
option java_package = "com.google.cloud.video.stitcher.v1";

// Container for a live session's ad tag detail.
// Information related to the details for one ad tag. This resource is only
// available for live sessions that do not implement Google Ad Manager ad
// insertion.
message LiveAdTagDetail {
option (google.api.resource) = {
type: "videostitcher.googleapis.com/LiveAdTagDetail"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,9 +71,26 @@ message AkamaiCdnKey {

// Configuration for a Media CDN key.
message MediaCdnKey {
// Configuration for a Media CDN token.
message TokenConfig {
// Optional. The query parameter in which to find the token.
//
// The name must be 1-64 characters long and match
// the regular expression `[a-zA-Z]([a-zA-Z0-9_-])*` which means the
// first character must be a letter, and all following characters
// must be a dash, underscore, letter or digit.
//
// Defaults to `edge-cache-token`.
string query_parameter = 1 [(google.api.field_behavior) = OPTIONAL];
}

// Input only. 64-byte ed25519 private key for this Media CDN key.
bytes private_key = 1 [(google.api.field_behavior) = INPUT_ONLY];

// The keyset name of the Media CDN key.
string key_name = 2;

// Optional. If set, the URL will be signed using the Media CDN token.
// Otherwise, the URL would be signed using the standard Media CDN signature.
TokenConfig token_config = 3 [(google.api.field_behavior) = OPTIONAL];
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
// Copyright 2024 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

syntax = "proto3";

package google.cloud.video.stitcher.v1;

option go_package = "cloud.google.com/go/video/stitcher/apiv1/stitcherpb;stitcherpb";
option java_multiple_files = true;
option java_outer_classname = "FetchOptionsProto";
option java_package = "com.google.cloud.video.stitcher.v1";

// Options on how fetches should be made.
message FetchOptions {
// Custom headers to pass into fetch request.
// Headers must have a maximum of 3 key value pairs.
// Each key value pair must have a maximum of 256 characters per key and 256
// characters per value.
map<string, string> headers = 1;
}
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ package google.cloud.video.stitcher.v1;

import "google/api/field_behavior.proto";
import "google/api/resource.proto";
import "google/cloud/video/stitcher/v1/fetch_options.proto";
import "google/protobuf/duration.proto";

option go_package = "cloud.google.com/go/video/stitcher/apiv1/stitcherpb;stitcherpb";
Expand Down Expand Up @@ -92,9 +93,7 @@ message LiveConfig {
// Output only. State of the live config.
State state = 5 [(google.api.field_behavior) = OUTPUT_ONLY];

// Required. Determines how the ads are tracked. If
// [gam_live_config][google.cloud.video.stitcher.v1.LiveConfig.gam_live_config]
// is set, the value must be `CLIENT` because the IMA SDK handles ad tracking.
// Required. Determines how the ads are tracked.
AdTracking ad_tracking = 6 [(google.api.field_behavior) = REQUIRED];

// This must refer to a slate in the same
Expand All @@ -111,6 +110,9 @@ message LiveConfig {

// The configuration for prefetching ads.
PrefetchConfig prefetch_config = 10;

// Options for fetching source manifests and segments.
FetchOptions source_fetch_options = 16;
}

// The configuration for prefetch ads.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,24 +55,29 @@ message VodSession {
// Output only. The playback URI of the stitched content.
string play_uri = 4 [(google.api.field_behavior) = OUTPUT_ONLY];

// Required. URI of the media to stitch.
string source_uri = 5 [(google.api.field_behavior) = REQUIRED];

// Required. Ad tag URI.
string ad_tag_uri = 6 [(google.api.field_behavior) = REQUIRED];

// Key value pairs for ad tag macro replacement. If the
// specified ad tag URI has macros, this field provides the mapping
// to the value that will replace the macro in the ad tag URI.
// Macros are designated by square brackets.
// For example:
// URI of the media to stitch. For most use cases, you should create a
// [VodConfig][google.cloud.video.stitcher.v1.VodConfig] with this information
// rather than setting this field directly.
string source_uri = 5;

// Ad tag URI. For most use cases, you should create a
// [VodConfig][google.cloud.video.stitcher.v1.VodConfig] with this information
// rather than setting this field directly.
string ad_tag_uri = 6;

// Key value pairs for ad tag macro replacement, only available for VOD
// sessions that do not implement Google Ad manager ad insertion. If the
// specified ad tag URI has macros, this field provides the mapping to the
// value that will replace the macro in the ad tag URI.
//
// Macros are designated by square brackets, for example:
//
// Ad tag URI: `"https://doubleclick.google.com/ad/1?geo_id=[geoId]"`
//
// Ad tag macro map: `{"geoId": "123"}`
//
// Fully qualified ad tag:
// `"`https://doubleclick.google.com/ad/1?geo_id=123"`
// `"https://doubleclick.google.com/ad/1?geo_id=123"`
map<string, string> ad_tag_macro_map = 7;

// Additional options that affect the output of the manifest.
Expand All @@ -87,6 +92,12 @@ message VodSession {
// This field should be set with appropriate values if GAM is being used for
// ads.
GamSettings gam_settings = 13;

// The resource name of the VOD config for this session, in the form of
// `projects/{project}/locations/{location}/vodConfigs/{id}`.
string vod_config = 14 [(google.api.resource_reference) = {
type: "videostitcher.googleapis.com/VodConfig"
}];
}

// Describes what was stitched into a VOD session's manifest.
Expand Down Expand Up @@ -144,11 +155,17 @@ message LiveSession {
pattern: "projects/{project}/locations/{location}/liveSessions/{live_session}"
};

// Defines fields related to Google Ad Manager (GAM). This should be set if
// GAM is being used for ads.
// Defines fields related to Google Ad Manager (GAM).
message GamSettings {
// Required. The stream ID generated by Ad Manager.
// Required. The stream ID generated by Ad Manager. This must be set if GAM
// is being used for ads and the session uses client-side ad tracking.
string stream_id = 1 [(google.api.field_behavior) = REQUIRED];

// [Targeting
// parameters](https://support.google.com/admanager/answer/7320899) to send
// to Ad Manager to generate a stream ID. This should only be set if the
// session uses server-side ad tracking.
map<string, string> targeting_parameters = 4;
}

// Output only. The name of the live session, in the form of
Expand All @@ -158,12 +175,12 @@ message LiveSession {
// Output only. The URI to play the live session's ad-stitched stream.
string play_uri = 2 [(google.api.field_behavior) = OUTPUT_ONLY];

// Key value pairs for ad tag macro replacement. If the
// specified ad tag URI has macros, this field provides the mapping
// to the value that will replace the macro in the ad tag URI.
// Macros are designated by square brackets.
// Key value pairs for ad tag macro replacement, only available for live
// sessions that do not implement Google Ad manager ad insertion. If the
// specified ad tag URI has macros, this field provides the mapping to the
// value that will replace the macro in the ad tag URI.
//
// For example:
// Macros are designated by square brackets, for example:
//
// Ad tag URI: "https://doubleclick.google.com/ad/1?geo_id=[geoId]"
//
Expand All @@ -188,6 +205,10 @@ message LiveSession {
type: "videostitcher.googleapis.com/LiveConfig"
}
];

// Determines how the ad should be tracked. This overrides the value set in
// the live config for this session.
AdTracking ad_tracking = 17;
}

// Options for manifest generation.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ option java_multiple_files = true;
option java_outer_classname = "StitchDetailsProto";
option java_package = "com.google.cloud.video.stitcher.v1";

// Detailed information related to the interstitial of a VOD session. This
// resource is only available for VOD sessions that do not implement Google Ad
// Manager ad insertion.
// Information related to the interstitial of a VOD session. This resource is
// only available for VOD sessions that do not implement Google Ad Manager ad
// insertion.
message VodStitchDetail {
option (google.api.resource) = {
type: "videostitcher.googleapis.com/VodStitchDetail"
Expand Down
Loading

0 comments on commit 10d9310

Please sign in to comment.