@googleapis/youtube 30.3.0 → 32.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/v3.ts CHANGED
@@ -520,23 +520,6 @@ export namespace youtube_v3 {
520
520
  */
521
521
  type?: string | null;
522
522
  }
523
- /**
524
- * Response for the Videos.stats API. Returns VideoStat information about a batch of videos. VideoStat contains a subset of the information in Video that is relevant to statistics and content details.
525
- */
526
- export interface Schema$BatchGetStatsResponse {
527
- /**
528
- * Output only. Etag of this resource.
529
- */
530
- etag?: string | null;
531
- /**
532
- * Output only. The videos' stats information.
533
- */
534
- items?: Schema$VideoStat[];
535
- /**
536
- * Output only. Identifies what kind of resource this is. Value: the fixed string "youtube#batchGetStatsResponse".
537
- */
538
- kind?: string | null;
539
- }
540
523
  /**
541
524
  * A *caption* resource represents a YouTube caption track. A caption track is associated with exactly one YouTube video.
542
525
  */
@@ -2364,6 +2347,43 @@ export namespace youtube_v3 {
2364
2347
  */
2365
2348
  userComment?: string | null;
2366
2349
  }
2350
+ /**
2351
+ * Details about the gift event, this is only set if the type is 'giftEvent'.
2352
+ */
2353
+ export interface Schema$LiveChatGiftDetails {
2354
+ /**
2355
+ * The alternative text to be used for accessibility.
2356
+ */
2357
+ altText?: string | null;
2358
+ /**
2359
+ * The number of times the gift has been sent in a row.
2360
+ */
2361
+ comboCount?: number | null;
2362
+ /**
2363
+ * The duration of the gift.
2364
+ */
2365
+ giftDuration?: string | null;
2366
+ /**
2367
+ * The name of the gift.
2368
+ */
2369
+ giftName?: string | null;
2370
+ /**
2371
+ * The URL of the gift image.
2372
+ */
2373
+ giftUrl?: string | null;
2374
+ /**
2375
+ * Whether the gift involves a visual effect.
2376
+ */
2377
+ hasVisualEffect?: boolean | null;
2378
+ /**
2379
+ * The value of the gift in jewels.
2380
+ */
2381
+ jewelsAmount?: number | null;
2382
+ /**
2383
+ * The BCP-47 language code of the gift.
2384
+ */
2385
+ language?: string | null;
2386
+ }
2367
2387
  export interface Schema$LiveChatGiftMembershipReceivedDetails {
2368
2388
  /**
2369
2389
  * The ID of the membership gifting message that is related to this gift membership. This ID will always refer to a message whose type is 'membershipGiftingEvent'.
@@ -2505,7 +2525,7 @@ export namespace youtube_v3 {
2505
2525
  retractedMessageId?: string | null;
2506
2526
  }
2507
2527
  /**
2508
- * Next ID: 34
2528
+ * Next ID: 35
2509
2529
  */
2510
2530
  export interface Schema$LiveChatMessageSnippet {
2511
2531
  /**
@@ -2520,6 +2540,10 @@ export namespace youtube_v3 {
2520
2540
  * Details about the funding event, this is only set if the type is 'fanFundingEvent'.
2521
2541
  */
2522
2542
  fanFundingEventDetails?: Schema$LiveChatFanFundingEventDetails;
2543
+ /**
2544
+ * Details about the gift event, this is only set if the type is 'giftEvent'.
2545
+ */
2546
+ giftDetails?: Schema$LiveChatGiftDetails;
2523
2547
  /**
2524
2548
  * Details about the Gift Membership Received event, this is only set if the type is 'giftMembershipReceivedEvent'.
2525
2549
  */
@@ -4577,35 +4601,6 @@ export namespace youtube_v3 {
4577
4601
  */
4578
4602
  title?: string | null;
4579
4603
  }
4580
- /**
4581
- * A *VideoStat* resource represents a YouTube video's stats.
4582
- */
4583
- export interface Schema$VideoStat {
4584
- /**
4585
- * Output only. The VideoStatsContentDetails object contains information about the video content, including the length of the video.
4586
- */
4587
- contentDetails?: Schema$VideoStatsContentDetails;
4588
- /**
4589
- * Output only. Etag of this resource.
4590
- */
4591
- etag?: string | null;
4592
- /**
4593
- * Output only. The ID that YouTube uses to uniquely identify the video.
4594
- */
4595
- id?: string | null;
4596
- /**
4597
- * Output only. Identifies what kind of resource this is. Value: the fixed string "youtube#videoStats".
4598
- */
4599
- kind?: string | null;
4600
- /**
4601
- * Output only. The VideoStatsSnippet object contains basic details about the video, such publish time.
4602
- */
4603
- snippet?: Schema$VideoStatsSnippet;
4604
- /**
4605
- * Output only. The VideoStatsStatistics object contains statistics about the video.
4606
- */
4607
- statistics?: Schema$VideoStatsStatistics;
4608
- }
4609
4604
  /**
4610
4605
  * Statistics about the video, such as the number of times the video was viewed or liked.
4611
4606
  */
@@ -4631,41 +4626,6 @@ export namespace youtube_v3 {
4631
4626
  */
4632
4627
  viewCount?: string | null;
4633
4628
  }
4634
- /**
4635
- * Details about the content of a YouTube Video. This is a subset of the information in VideoContentDetails specifically for the Videos.stats API.
4636
- */
4637
- export interface Schema$VideoStatsContentDetails {
4638
- /**
4639
- * Output only. The length of the video. The property value is a [`google.protobuf.Duration`](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#duration) object.
4640
- */
4641
- duration?: string | null;
4642
- }
4643
- /**
4644
- * Basic details about a video. This is a subset of the information in VideoSnippet specifically for the Videos.stats API.
4645
- */
4646
- export interface Schema$VideoStatsSnippet {
4647
- /**
4648
- * Output only. The date and time that the video was uploaded. The property value is a [`google.protobuf.Timestamp`](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#timestamp) object.
4649
- */
4650
- publishTime?: string | null;
4651
- }
4652
- /**
4653
- * Statistics about the video, such as the number of times the video was viewed or liked.
4654
- */
4655
- export interface Schema$VideoStatsStatistics {
4656
- /**
4657
- * Output only. The number of comments for the video.
4658
- */
4659
- commentCount?: string | null;
4660
- /**
4661
- * Output only. The number of users who have indicated that they liked the video by giving it a positive rating.
4662
- */
4663
- likeCount?: string | null;
4664
- /**
4665
- * Output only. The number of times the video has been viewed.
4666
- */
4667
- viewCount?: string | null;
4668
- }
4669
4629
  /**
4670
4630
  * Basic details about a video category, such as its localized title. Next Id: 19
4671
4631
  */
@@ -16133,6 +16093,8 @@ export namespace youtube_v3 {
16133
16093
  * const res = await youtube.tests.insert({
16134
16094
  * externalChannelId: 'placeholder-value',
16135
16095
  *
16096
+ * onBehalfOfContentOwnerChannel: 'placeholder-value',
16097
+ *
16136
16098
  * part: 'placeholder-value',
16137
16099
  *
16138
16100
  * // Request body metadata
@@ -16256,6 +16218,10 @@ export namespace youtube_v3 {
16256
16218
  *
16257
16219
  */
16258
16220
  externalChannelId?: string;
16221
+ /**
16222
+ *
16223
+ */
16224
+ onBehalfOfContentOwnerChannel?: string;
16259
16225
  /**
16260
16226
  *
16261
16227
  */
@@ -19279,11 +19245,9 @@ export namespace youtube_v3 {
19279
19245
  export class Resource$Youtube$V3 {
19280
19246
  context: APIRequestContext;
19281
19247
  liveChat: Resource$Youtube$V3$Livechat;
19282
- videos: Resource$Youtube$V3$Videos;
19283
19248
  constructor(context: APIRequestContext) {
19284
19249
  this.context = context;
19285
19250
  this.liveChat = new Resource$Youtube$V3$Livechat(this.context);
19286
- this.videos = new Resource$Youtube$V3$Videos(this.context);
19287
19251
  }
19288
19252
 
19289
19253
  /**
@@ -19661,173 +19625,4 @@ export namespace youtube_v3 {
19661
19625
  */
19662
19626
  profileImageSize?: number;
19663
19627
  }
19664
-
19665
- export class Resource$Youtube$V3$Videos {
19666
- context: APIRequestContext;
19667
- constructor(context: APIRequestContext) {
19668
- this.context = context;
19669
- }
19670
-
19671
- /**
19672
- * Retrieves a batch of VideoStat resources, possibly filtered.
19673
- * @example
19674
- * ```js
19675
- * // Before running the sample:
19676
- * // - Enable the API at:
19677
- * // https://console.developers.google.com/apis/api/youtube.googleapis.com
19678
- * // - Login into gcloud by running:
19679
- * // ```sh
19680
- * // $ gcloud auth application-default login
19681
- * // ```
19682
- * // - Install the npm module by running:
19683
- * // ```sh
19684
- * // $ npm install googleapis
19685
- * // ```
19686
- *
19687
- * const {google} = require('googleapis');
19688
- * const youtube = google.youtube('v3');
19689
- *
19690
- * async function main() {
19691
- * const auth = new google.auth.GoogleAuth({
19692
- * // Scopes can be specified either as an array or as a single, space-delimited string.
19693
- * scopes: [],
19694
- * });
19695
- *
19696
- * // Acquire an auth client, and bind it to all future calls
19697
- * const authClient = await auth.getClient();
19698
- * google.options({auth: authClient});
19699
- *
19700
- * // Do the magic
19701
- * const res = await youtube.youtube.v3.videos.batchGetStats({
19702
- * // Required. Return videos with the given ids. The number of IDs specified cannot exceed 50.
19703
- * id: 'placeholder-value',
19704
- * // Optional. **Note:** This parameter is intended exclusively for YouTube content partners. The `onBehalfOfContentOwner` parameter indicates that the request's authorization credentials identify a YouTube CMS user who is acting on behalf of the content owner specified in the parameter value. This parameter is intended for YouTube content partners that own and manage many different YouTube channels. It allows content owners to authenticate once and get access to all their video and channel data, without having to provide authentication credentials for each individual channel. The CMS account that the user authenticates with must be linked to the specified YouTube content owner.
19705
- * onBehalfOfContentOwner: 'placeholder-value',
19706
- * // Required. The `**part**` parameter specifies a comma-separated list of one or more `videoStat` resource properties that the API response will include. If the parameter identifies a property that contains child properties, the child properties will be included in the response. For example, in a `videoStat` resource, the `statistics` property contains `view_count` and `like_count`. As such, if you set `**part=snippet**`, the API response will contain all of those properties.
19707
- * part: 'placeholder-value',
19708
- * });
19709
- * console.log(res.data);
19710
- *
19711
- * // Example response
19712
- * // {
19713
- * // "etag": "my_etag",
19714
- * // "items": [],
19715
- * // "kind": "my_kind"
19716
- * // }
19717
- * }
19718
- *
19719
- * main().catch(e => {
19720
- * console.error(e);
19721
- * throw e;
19722
- * });
19723
- *
19724
- * ```
19725
- *
19726
- * @param params - Parameters for request
19727
- * @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
19728
- * @param callback - Optional callback that handles the response.
19729
- * @returns A promise if used with async/await, or void if used with a callback.
19730
- */
19731
- batchGetStats(
19732
- params: Params$Resource$Youtube$V3$Videos$Batchgetstats,
19733
- options: StreamMethodOptions
19734
- ): Promise<GaxiosResponseWithHTTP2<Readable>>;
19735
- batchGetStats(
19736
- params?: Params$Resource$Youtube$V3$Videos$Batchgetstats,
19737
- options?: MethodOptions
19738
- ): Promise<GaxiosResponseWithHTTP2<Schema$BatchGetStatsResponse>>;
19739
- batchGetStats(
19740
- params: Params$Resource$Youtube$V3$Videos$Batchgetstats,
19741
- options: StreamMethodOptions | BodyResponseCallback<Readable>,
19742
- callback: BodyResponseCallback<Readable>
19743
- ): void;
19744
- batchGetStats(
19745
- params: Params$Resource$Youtube$V3$Videos$Batchgetstats,
19746
- options:
19747
- | MethodOptions
19748
- | BodyResponseCallback<Schema$BatchGetStatsResponse>,
19749
- callback: BodyResponseCallback<Schema$BatchGetStatsResponse>
19750
- ): void;
19751
- batchGetStats(
19752
- params: Params$Resource$Youtube$V3$Videos$Batchgetstats,
19753
- callback: BodyResponseCallback<Schema$BatchGetStatsResponse>
19754
- ): void;
19755
- batchGetStats(
19756
- callback: BodyResponseCallback<Schema$BatchGetStatsResponse>
19757
- ): void;
19758
- batchGetStats(
19759
- paramsOrCallback?:
19760
- | Params$Resource$Youtube$V3$Videos$Batchgetstats
19761
- | BodyResponseCallback<Schema$BatchGetStatsResponse>
19762
- | BodyResponseCallback<Readable>,
19763
- optionsOrCallback?:
19764
- | MethodOptions
19765
- | StreamMethodOptions
19766
- | BodyResponseCallback<Schema$BatchGetStatsResponse>
19767
- | BodyResponseCallback<Readable>,
19768
- callback?:
19769
- | BodyResponseCallback<Schema$BatchGetStatsResponse>
19770
- | BodyResponseCallback<Readable>
19771
- ):
19772
- | void
19773
- | Promise<GaxiosResponseWithHTTP2<Schema$BatchGetStatsResponse>>
19774
- | Promise<GaxiosResponseWithHTTP2<Readable>> {
19775
- let params = (paramsOrCallback ||
19776
- {}) as Params$Resource$Youtube$V3$Videos$Batchgetstats;
19777
- let options = (optionsOrCallback || {}) as MethodOptions;
19778
-
19779
- if (typeof paramsOrCallback === 'function') {
19780
- callback = paramsOrCallback;
19781
- params = {} as Params$Resource$Youtube$V3$Videos$Batchgetstats;
19782
- options = {};
19783
- }
19784
-
19785
- if (typeof optionsOrCallback === 'function') {
19786
- callback = optionsOrCallback;
19787
- options = {};
19788
- }
19789
-
19790
- const rootUrl = options.rootUrl || 'https://youtube.googleapis.com/';
19791
- const parameters = {
19792
- options: Object.assign(
19793
- {
19794
- url: (rootUrl + '/youtube/v3/videos:batchGetStats').replace(
19795
- /([^:]\/)\/+/g,
19796
- '$1'
19797
- ),
19798
- method: 'GET',
19799
- apiVersion: '',
19800
- },
19801
- options
19802
- ),
19803
- params,
19804
- requiredParams: [],
19805
- pathParams: [],
19806
- context: this.context,
19807
- };
19808
- if (callback) {
19809
- createAPIRequest<Schema$BatchGetStatsResponse>(
19810
- parameters,
19811
- callback as BodyResponseCallback<unknown>
19812
- );
19813
- } else {
19814
- return createAPIRequest<Schema$BatchGetStatsResponse>(parameters);
19815
- }
19816
- }
19817
- }
19818
-
19819
- export interface Params$Resource$Youtube$V3$Videos$Batchgetstats extends StandardParameters {
19820
- /**
19821
- * Required. Return videos with the given ids. The number of IDs specified cannot exceed 50.
19822
- */
19823
- id?: string[];
19824
- /**
19825
- * Optional. **Note:** This parameter is intended exclusively for YouTube content partners. The `onBehalfOfContentOwner` parameter indicates that the request's authorization credentials identify a YouTube CMS user who is acting on behalf of the content owner specified in the parameter value. This parameter is intended for YouTube content partners that own and manage many different YouTube channels. It allows content owners to authenticate once and get access to all their video and channel data, without having to provide authentication credentials for each individual channel. The CMS account that the user authenticates with must be linked to the specified YouTube content owner.
19826
- */
19827
- onBehalfOfContentOwner?: string;
19828
- /**
19829
- * Required. The `**part**` parameter specifies a comma-separated list of one or more `videoStat` resource properties that the API response will include. If the parameter identifies a property that contains child properties, the child properties will be included in the response. For example, in a `videoStat` resource, the `statistics` property contains `view_count` and `like_count`. As such, if you set `**part=snippet**`, the API response will contain all of those properties.
19830
- */
19831
- part?: string[];
19832
- }
19833
19628
  }