From 7f18f1ded78d905d37520a542652bb1d9a7c67cd Mon Sep 17 00:00:00 2001 From: Amanda Tarafa Mas Date: Mon, 14 Oct 2024 01:14:33 -0700 Subject: [PATCH] feat: Generate Google.Apis.YouTube.v3 version 1.68.0.3570 --- DiscoveryJson/youtube.v3.json | 65 +++++++- .../Google.Apis.YouTube.v3.cs | 157 +++++++++++++++++- .../Google.Apis.YouTube.v3.csproj | 2 +- 3 files changed, 220 insertions(+), 4 deletions(-) diff --git a/DiscoveryJson/youtube.v3.json b/DiscoveryJson/youtube.v3.json index 8bd10bceb9f..b63f47563fb 100644 --- a/DiscoveryJson/youtube.v3.json +++ b/DiscoveryJson/youtube.v3.json @@ -1757,7 +1757,7 @@ }, "maxResults": { "default": "500", - "description": "The *maxResults* parameter specifies the maximum number of items that should be returned in the result set.", + "description": "The *maxResults* parameter specifies the maximum number of items that should be returned in the result set. Not used in the streaming RPC.", "format": "uint32", "location": "query", "maximum": "2000", @@ -4067,12 +4067,73 @@ "$ref": "CommentThread" } } + }, + "resources": { + "liveChat": { + "resources": { + "messages": { + "methods": { + "stream": { + "description": "Allows a user to load live chat through a server-streamed RPC.", + "flatPath": "youtube/v3/liveChat/messages/stream", + "httpMethod": "GET", + "id": "youtube.youtube.v3.liveChat.messages.stream", + "parameterOrder": [], + "parameters": { + "hl": { + "description": "Specifies the localization language in which the system messages should be returned.", + "location": "query", + "type": "string" + }, + "liveChatId": { + "description": "The id of the live chat for which comments should be returned.", + "location": "query", + "type": "string" + }, + "maxResults": { + "default": "500", + "description": "The *maxResults* parameter specifies the maximum number of items that should be returned in the result set. Not used in the streaming RPC.", + "format": "uint32", + "location": "query", + "maximum": "2000", + "minimum": "200", + "type": "integer" + }, + "pageToken": { + "description": "The *pageToken* parameter identifies a specific page in the result set that should be returned. In an API response, the nextPageToken property identify other pages that could be retrieved.", + "location": "query", + "type": "string" + }, + "part": { + "description": "The *part* parameter specifies the liveChatComment resource parts that the API response will include. Supported values are id, snippet, and authorDetails.", + "location": "query", + "repeated": true, + "type": "string" + }, + "profileImageSize": { + "description": "Specifies the size of the profile image that should be returned for each user.", + "format": "uint32", + "location": "query", + "maximum": "720", + "minimum": "16", + "type": "integer" + } + }, + "path": "youtube/v3/liveChat/messages/stream", + "response": { + "$ref": "LiveChatMessageListResponse" + } + } + } + } + } + } } } } } }, - "revision": "20240926", + "revision": "20241010", "rootUrl": "https://youtube.googleapis.com/", "schemas": { "AbuseReport": { diff --git a/Src/Generated/Google.Apis.YouTube.v3/Google.Apis.YouTube.v3.cs b/Src/Generated/Google.Apis.YouTube.v3/Google.Apis.YouTube.v3.cs index 4b446cc1d4b..1cbce5b2608 100644 --- a/Src/Generated/Google.Apis.YouTube.v3/Google.Apis.YouTube.v3.cs +++ b/Src/Generated/Google.Apis.YouTube.v3/Google.Apis.YouTube.v3.cs @@ -4768,7 +4768,7 @@ public ListRequest(Google.Apis.Services.IClientService service, string liveChatI /// /// The *maxResults* parameter specifies the maximum number of items that should be returned in the result - /// set. + /// set. Not used in the streaming RPC. /// [Google.Apis.Util.RequestParameterAttribute("maxResults", Google.Apis.Util.RequestParameterType.Query)] public virtual System.Nullable MaxResults { get; set; } @@ -10738,6 +10738,161 @@ public class V3Resource public V3Resource(Google.Apis.Services.IClientService service) { this.service = service; + LiveChat = new LiveChatResource(service); + } + + /// Gets the LiveChat resource. + public virtual LiveChatResource LiveChat { get; } + + /// The "liveChat" collection of methods. + public class LiveChatResource + { + private const string Resource = "liveChat"; + + /// The service which this resource belongs to. + private readonly Google.Apis.Services.IClientService service; + + /// Constructs a new resource. + public LiveChatResource(Google.Apis.Services.IClientService service) + { + this.service = service; + Messages = new MessagesResource(service); + } + + /// Gets the Messages resource. + public virtual MessagesResource Messages { get; } + + /// The "messages" collection of methods. + public class MessagesResource + { + private const string Resource = "messages"; + + /// The service which this resource belongs to. + private readonly Google.Apis.Services.IClientService service; + + /// Constructs a new resource. + public MessagesResource(Google.Apis.Services.IClientService service) + { + this.service = service; + } + + /// Allows a user to load live chat through a server-streamed RPC. + public virtual StreamRequest Stream() + { + return new StreamRequest(this.service); + } + + /// Allows a user to load live chat through a server-streamed RPC. + public class StreamRequest : YouTubeBaseServiceRequest + { + /// Constructs a new Stream request. + public StreamRequest(Google.Apis.Services.IClientService service) : base(service) + { + InitParameters(); + } + + /// + /// Specifies the localization language in which the system messages should be returned. + /// + [Google.Apis.Util.RequestParameterAttribute("hl", Google.Apis.Util.RequestParameterType.Query)] + public virtual string Hl { get; set; } + + /// The id of the live chat for which comments should be returned. + [Google.Apis.Util.RequestParameterAttribute("liveChatId", Google.Apis.Util.RequestParameterType.Query)] + public virtual string LiveChatId { get; set; } + + /// + /// The *maxResults* parameter specifies the maximum number of items that should be returned in + /// the result set. Not used in the streaming RPC. + /// + [Google.Apis.Util.RequestParameterAttribute("maxResults", Google.Apis.Util.RequestParameterType.Query)] + public virtual System.Nullable MaxResults { get; set; } + + /// + /// The *pageToken* parameter identifies a specific page in the result set that should be + /// returned. In an API response, the nextPageToken property identify other pages that could be + /// retrieved. + /// + [Google.Apis.Util.RequestParameterAttribute("pageToken", Google.Apis.Util.RequestParameterType.Query)] + public virtual string PageToken { get; set; } + + /// + /// The *part* parameter specifies the liveChatComment resource parts that the API response will + /// include. Supported values are id, snippet, and authorDetails. + /// + [Google.Apis.Util.RequestParameterAttribute("part", Google.Apis.Util.RequestParameterType.Query)] + public virtual Google.Apis.Util.Repeatable Part { get; set; } + + /// + /// Specifies the size of the profile image that should be returned for each user. + /// + [Google.Apis.Util.RequestParameterAttribute("profileImageSize", Google.Apis.Util.RequestParameterType.Query)] + public virtual System.Nullable ProfileImageSize { get; set; } + + /// Gets the method name. + public override string MethodName => "stream"; + + /// Gets the HTTP method. + public override string HttpMethod => "GET"; + + /// Gets the REST path. + public override string RestPath => "youtube/v3/liveChat/messages/stream"; + + /// Initializes Stream parameter list. + protected override void InitParameters() + { + base.InitParameters(); + RequestParameters.Add("hl", new Google.Apis.Discovery.Parameter + { + Name = "hl", + IsRequired = false, + ParameterType = "query", + DefaultValue = null, + Pattern = null, + }); + RequestParameters.Add("liveChatId", new Google.Apis.Discovery.Parameter + { + Name = "liveChatId", + IsRequired = false, + ParameterType = "query", + DefaultValue = null, + Pattern = null, + }); + RequestParameters.Add("maxResults", new Google.Apis.Discovery.Parameter + { + Name = "maxResults", + IsRequired = false, + ParameterType = "query", + DefaultValue = "500", + Pattern = null, + }); + RequestParameters.Add("pageToken", new Google.Apis.Discovery.Parameter + { + Name = "pageToken", + IsRequired = false, + ParameterType = "query", + DefaultValue = null, + Pattern = null, + }); + RequestParameters.Add("part", new Google.Apis.Discovery.Parameter + { + Name = "part", + IsRequired = false, + ParameterType = "query", + DefaultValue = null, + Pattern = null, + }); + RequestParameters.Add("profileImageSize", new Google.Apis.Discovery.Parameter + { + Name = "profileImageSize", + IsRequired = false, + ParameterType = "query", + DefaultValue = null, + Pattern = null, + }); + } + } + } } /// Updates an existing resource. diff --git a/Src/Generated/Google.Apis.YouTube.v3/Google.Apis.YouTube.v3.csproj b/Src/Generated/Google.Apis.YouTube.v3/Google.Apis.YouTube.v3.csproj index 11dbe831164..03572960b2f 100644 --- a/Src/Generated/Google.Apis.YouTube.v3/Google.Apis.YouTube.v3.csproj +++ b/Src/Generated/Google.Apis.YouTube.v3/Google.Apis.YouTube.v3.csproj @@ -3,7 +3,7 @@ Google.Apis.YouTube.v3 Client Library - 1.68.0.3556 + 1.68.0.3570 Google LLC Copyright 2024 Google LLC Google