From f5d9175c5c7afa0d87911c8bbb6097c32ad704f8 Mon Sep 17 00:00:00 2001 From: Octokit Bot Date: Mon, 30 Dec 2024 00:32:52 +0000 Subject: [PATCH 01/21] New updates to generated code --- src/GitHub/Models/Users.cs | 54 +++++++++++++++------ src/GitHub/Models/Users_matches.cs | 75 ++++++++++++++++++++++++++++++ 2 files changed, 115 insertions(+), 14 deletions(-) create mode 100644 src/GitHub/Models/Users_matches.cs diff --git a/src/GitHub/Models/Users.cs b/src/GitHub/Models/Users.cs index 1353411f7..ee1970b91 100644 --- a/src/GitHub/Models/Users.cs +++ b/src/GitHub/Models/Users.cs @@ -14,23 +14,45 @@ public partial class Users : IAdditionalDataHolder, IParsable { /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. public IDictionary AdditionalData { get; set; } - /// Whether this email address is the primary address. - public bool? Primary { get; set; } - /// The type of email address. + /// The fragment property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable - public string? Type { get; set; } + public string? Fragment { get; set; } #nullable restore #else - public string Type { get; set; } + public string Fragment { get; set; } #endif - /// The email address. + /// The matches property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable - public string? Value { get; set; } + public List? Matches { get; set; } #nullable restore #else - public string Value { get; set; } + public List Matches { get; set; } +#endif + /// The object_type property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? ObjectType { get; set; } +#nullable restore +#else + public string ObjectType { get; set; } +#endif + /// The object_url property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? ObjectUrl { get; set; } +#nullable restore +#else + public string ObjectUrl { get; set; } +#endif + /// The property property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Property { get; set; } +#nullable restore +#else + public string Property { get; set; } #endif /// /// Instantiates a new and sets the default values. @@ -57,9 +79,11 @@ public virtual IDictionary> GetFieldDeserializers() { return new Dictionary> { - { "primary", n => { Primary = n.GetBoolValue(); } }, - { "type", n => { Type = n.GetStringValue(); } }, - { "value", n => { Value = n.GetStringValue(); } }, + { "fragment", n => { Fragment = n.GetStringValue(); } }, + { "matches", n => { Matches = n.GetCollectionOfObjectValues(global::GitHub.Models.Users_matches.CreateFromDiscriminatorValue)?.AsList(); } }, + { "object_type", n => { ObjectType = n.GetStringValue(); } }, + { "object_url", n => { ObjectUrl = n.GetStringValue(); } }, + { "property", n => { Property = n.GetStringValue(); } }, }; } /// @@ -69,9 +93,11 @@ public virtual IDictionary> GetFieldDeserializers() public virtual void Serialize(ISerializationWriter writer) { _ = writer ?? throw new ArgumentNullException(nameof(writer)); - writer.WriteBoolValue("primary", Primary); - writer.WriteStringValue("type", Type); - writer.WriteStringValue("value", Value); + writer.WriteStringValue("fragment", Fragment); + writer.WriteCollectionOfObjectValues("matches", Matches); + writer.WriteStringValue("object_type", ObjectType); + writer.WriteStringValue("object_url", ObjectUrl); + writer.WriteStringValue("property", Property); writer.WriteAdditionalData(AdditionalData); } } diff --git a/src/GitHub/Models/Users_matches.cs b/src/GitHub/Models/Users_matches.cs new file mode 100644 index 000000000..02c4f2f4d --- /dev/null +++ b/src/GitHub/Models/Users_matches.cs @@ -0,0 +1,75 @@ +// +#pragma warning disable CS0618 +using Microsoft.Kiota.Abstractions.Extensions; +using Microsoft.Kiota.Abstractions.Serialization; +using System.Collections.Generic; +using System.IO; +using System; +namespace GitHub.Models +{ + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.19.0")] + #pragma warning disable CS1591 + public partial class Users_matches : IAdditionalDataHolder, IParsable + #pragma warning restore CS1591 + { + /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. + public IDictionary AdditionalData { get; set; } + /// The indices property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public List? Indices { get; set; } +#nullable restore +#else + public List Indices { get; set; } +#endif + /// The text property +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public string? Text { get; set; } +#nullable restore +#else + public string Text { get; set; } +#endif + /// + /// Instantiates a new and sets the default values. + /// + public Users_matches() + { + AdditionalData = new Dictionary(); + } + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static global::GitHub.Models.Users_matches CreateFromDiscriminatorValue(IParseNode parseNode) + { + _ = parseNode ?? throw new ArgumentNullException(nameof(parseNode)); + return new global::GitHub.Models.Users_matches(); + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public virtual IDictionary> GetFieldDeserializers() + { + return new Dictionary> + { + { "indices", n => { Indices = n.GetCollectionOfPrimitiveValues()?.AsList(); } }, + { "text", n => { Text = n.GetStringValue(); } }, + }; + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public virtual void Serialize(ISerializationWriter writer) + { + _ = writer ?? throw new ArgumentNullException(nameof(writer)); + writer.WriteCollectionOfPrimitiveValues("indices", Indices); + writer.WriteStringValue("text", Text); + writer.WriteAdditionalData(AdditionalData); + } + } +} +#pragma warning restore CS0618 From adfe2f98700b077adc5ae2393c07902ce7768e20 Mon Sep 17 00:00:00 2001 From: Octokit Bot Date: Tue, 7 Jan 2025 00:31:47 +0000 Subject: [PATCH 02/21] New updates to generated code --- src/GitHub/kiota-lock.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/GitHub/kiota-lock.json b/src/GitHub/kiota-lock.json index dd9bf77fd..d3630603b 100644 --- a/src/GitHub/kiota-lock.json +++ b/src/GitHub/kiota-lock.json @@ -1,5 +1,5 @@ { - "descriptionHash": "EA9CDA22EB51812185B6B695BB3F1928DD60725D16BDF71B6005E69337FE830B584C7FAA62F396BD65FCAA0B9635FF61A4984DDEF8EA78488CE3AAE3A3A042A7", + "descriptionHash": "A1019990CE033B3D1E100FA90BC588F066AFA94B505C75A76BEC659B32306B4EA461CA7E60877293E1BD02E5976CAF3D8AA019BCC099F0EF5BF481DBA73D9FDF", "descriptionLocation": "../../../../../schemas/ghes-3.14.json", "lockFileVersion": "1.0.0", "kiotaVersion": "1.19.0", From f33f864e6ebf9760296db0f433592970411b5ffd Mon Sep 17 00:00:00 2001 From: Octokit Bot Date: Thu, 9 Jan 2025 00:31:27 +0000 Subject: [PATCH 03/21] New updates to generated code --- src/GitHub/Repos/Item/Item/Topics/TopicsPutRequestBody.cs | 2 +- src/GitHub/kiota-lock.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/GitHub/Repos/Item/Item/Topics/TopicsPutRequestBody.cs b/src/GitHub/Repos/Item/Item/Topics/TopicsPutRequestBody.cs index 9f6bf03ac..600f4f6ef 100644 --- a/src/GitHub/Repos/Item/Item/Topics/TopicsPutRequestBody.cs +++ b/src/GitHub/Repos/Item/Item/Topics/TopicsPutRequestBody.cs @@ -14,7 +14,7 @@ public partial class TopicsPutRequestBody : IAdditionalDataHolder, IParsable { /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. public IDictionary AdditionalData { get; set; } - /// An array of topics to add to the repository. Pass one or more topics to _replace_ the set of existing topics. Send an empty array (`[]`) to clear all topics from the repository. **Note:** Topic `names` cannot contain uppercase letters. + /// An array of topics to add to the repository. Pass one or more topics to _replace_ the set of existing topics. Send an empty array (`[]`) to clear all topics from the repository. **Note:** Topic `names` will be saved as lowercase. #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public List? Names { get; set; } diff --git a/src/GitHub/kiota-lock.json b/src/GitHub/kiota-lock.json index d3630603b..a3c432658 100644 --- a/src/GitHub/kiota-lock.json +++ b/src/GitHub/kiota-lock.json @@ -1,5 +1,5 @@ { - "descriptionHash": "A1019990CE033B3D1E100FA90BC588F066AFA94B505C75A76BEC659B32306B4EA461CA7E60877293E1BD02E5976CAF3D8AA019BCC099F0EF5BF481DBA73D9FDF", + "descriptionHash": "AD5D02FEC05DB19A1067E5E3E972077E6091C7C0E57821F647849B76B06D5E6C3950FA03FC2A0E87366F0A4E79479828058799ADBEF426569FAF45B43EA07689", "descriptionLocation": "../../../../../schemas/ghes-3.14.json", "lockFileVersion": "1.0.0", "kiotaVersion": "1.19.0", From 712b4e1e32e19a956e8bb4d7e887402a069c1ee3 Mon Sep 17 00:00:00 2001 From: Octokit Bot Date: Fri, 10 Jan 2025 00:32:14 +0000 Subject: [PATCH 04/21] New updates to generated code --- src/GitHub/kiota-lock.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/GitHub/kiota-lock.json b/src/GitHub/kiota-lock.json index a3c432658..cc3be5c6c 100644 --- a/src/GitHub/kiota-lock.json +++ b/src/GitHub/kiota-lock.json @@ -1,5 +1,5 @@ { - "descriptionHash": "AD5D02FEC05DB19A1067E5E3E972077E6091C7C0E57821F647849B76B06D5E6C3950FA03FC2A0E87366F0A4E79479828058799ADBEF426569FAF45B43EA07689", + "descriptionHash": "BB4FB125D6890ACC879A2D7FB6CFDAC33FA525555B1B3FBB5C285E9853319703706BE30639CE38986AFC2A1FCE1416EB4D658570B7E726FF24166775F57E33E0", "descriptionLocation": "../../../../../schemas/ghes-3.14.json", "lockFileVersion": "1.0.0", "kiotaVersion": "1.19.0", From 662e2868c1d452c113e88b0c1dc9ec8ca8f25fea Mon Sep 17 00:00:00 2001 From: Octokit Bot Date: Wed, 15 Jan 2025 00:31:03 +0000 Subject: [PATCH 05/21] New updates to generated code --- src/GitHub/Models/CheckAutomatedSecurityFixes.cs | 6 +++--- .../AutomatedSecurityFixesRequestBuilder.cs | 6 +++--- src/GitHub/kiota-lock.json | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/GitHub/Models/CheckAutomatedSecurityFixes.cs b/src/GitHub/Models/CheckAutomatedSecurityFixes.cs index 9457d532c..16d0540f6 100644 --- a/src/GitHub/Models/CheckAutomatedSecurityFixes.cs +++ b/src/GitHub/Models/CheckAutomatedSecurityFixes.cs @@ -8,16 +8,16 @@ namespace GitHub.Models { /// - /// Check Automated Security Fixes + /// Check Dependabot security updates /// [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.19.0")] public partial class CheckAutomatedSecurityFixes : IAdditionalDataHolder, IParsable { /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. public IDictionary AdditionalData { get; set; } - /// Whether automated security fixes are enabled for the repository. + /// Whether Dependabot security updates are enabled for the repository. public bool? Enabled { get; set; } - /// Whether automated security fixes are paused for the repository. + /// Whether Dependabot security updates are paused for the repository. public bool? Paused { get; set; } /// /// Instantiates a new and sets the default values. diff --git a/src/GitHub/Repos/Item/Item/AutomatedSecurityFixes/AutomatedSecurityFixesRequestBuilder.cs b/src/GitHub/Repos/Item/Item/AutomatedSecurityFixes/AutomatedSecurityFixesRequestBuilder.cs index 9c1c3e6c7..68df6e37e 100644 --- a/src/GitHub/Repos/Item/Item/AutomatedSecurityFixes/AutomatedSecurityFixesRequestBuilder.cs +++ b/src/GitHub/Repos/Item/Item/AutomatedSecurityFixes/AutomatedSecurityFixesRequestBuilder.cs @@ -34,8 +34,8 @@ public AutomatedSecurityFixesRequestBuilder(string rawUrl, IRequestAdapter reque { } /// - /// Shows whether automated security fixes are enabled, disabled or paused for a repository. The authenticated user must have admin read access to the repository. For more information, see "[Configuring automated security fixes](https://docs.github.com/enterprise-server@3.14/articles/configuring-automated-security-fixes)". - /// API method documentation + /// Shows whether Dependabot security updates are enabled, disabled or paused for a repository. The authenticated user must have admin read access to the repository. For more information, see "[Configuring Dependabot security updates](https://docs.github.com/enterprise-server@3.14/articles/configuring-automated-security-fixes)". + /// API method documentation /// /// A /// Cancellation token to use when cancelling requests @@ -53,7 +53,7 @@ public AutomatedSecurityFixesRequestBuilder(string rawUrl, IRequestAdapter reque return await RequestAdapter.SendAsync(requestInfo, global::GitHub.Models.CheckAutomatedSecurityFixes.CreateFromDiscriminatorValue, default, cancellationToken).ConfigureAwait(false); } /// - /// Shows whether automated security fixes are enabled, disabled or paused for a repository. The authenticated user must have admin read access to the repository. For more information, see "[Configuring automated security fixes](https://docs.github.com/enterprise-server@3.14/articles/configuring-automated-security-fixes)". + /// Shows whether Dependabot security updates are enabled, disabled or paused for a repository. The authenticated user must have admin read access to the repository. For more information, see "[Configuring Dependabot security updates](https://docs.github.com/enterprise-server@3.14/articles/configuring-automated-security-fixes)". /// /// A /// Configuration for the request such as headers, query parameters, and middleware options. diff --git a/src/GitHub/kiota-lock.json b/src/GitHub/kiota-lock.json index cc3be5c6c..fe1c5938f 100644 --- a/src/GitHub/kiota-lock.json +++ b/src/GitHub/kiota-lock.json @@ -1,5 +1,5 @@ { - "descriptionHash": "BB4FB125D6890ACC879A2D7FB6CFDAC33FA525555B1B3FBB5C285E9853319703706BE30639CE38986AFC2A1FCE1416EB4D658570B7E726FF24166775F57E33E0", + "descriptionHash": "EE108032A8C8F81CB6824F8597F73BA8C76BF9F567C23F7902154B17C08728CAEBD103A4DC6ABFFA17CA70328908EEC58B1C5825D8B591F815830EE6B8A3D1D2", "descriptionLocation": "../../../../../schemas/ghes-3.14.json", "lockFileVersion": "1.0.0", "kiotaVersion": "1.19.0", From 7f0c42235e1f05546da8076fa4d2f1779911d7f1 Mon Sep 17 00:00:00 2001 From: Octokit Bot Date: Fri, 17 Jan 2025 00:30:32 +0000 Subject: [PATCH 06/21] New updates to generated code --- .../Item/Dependabot/Alerts/AlertsRequestBuilder.cs | 2 +- .../Item/Dependabot/Alerts/GetSortQueryParameterType.cs | 4 ++++ .../Orgs/Item/Dependabot/Alerts/AlertsRequestBuilder.cs | 2 +- .../Orgs/Item/Dependabot/Alerts/GetSortQueryParameterType.cs | 4 ++++ .../Repos/Item/Item/Dependabot/Alerts/AlertsRequestBuilder.cs | 2 +- .../Item/Item/Dependabot/Alerts/GetSortQueryParameterType.cs | 4 ++++ src/GitHub/User/Item/WithAccount_ItemRequestBuilder.cs | 4 ++-- src/GitHub/Users/Item/WithUsernameItemRequestBuilder.cs | 4 ++-- src/GitHub/kiota-lock.json | 2 +- 9 files changed, 20 insertions(+), 8 deletions(-) diff --git a/src/GitHub/Enterprises/Item/Dependabot/Alerts/AlertsRequestBuilder.cs b/src/GitHub/Enterprises/Item/Dependabot/Alerts/AlertsRequestBuilder.cs index 239359f35..0c443eb04 100644 --- a/src/GitHub/Enterprises/Item/Dependabot/Alerts/AlertsRequestBuilder.cs +++ b/src/GitHub/Enterprises/Item/Dependabot/Alerts/AlertsRequestBuilder.cs @@ -161,7 +161,7 @@ public partial class AlertsRequestBuilderGetQueryParameters [QueryParameter("severity")] public string Severity { get; set; } #endif - /// The property by which to sort the results.`created` means when the alert was created.`updated` means when the alert's state last changed. + /// The property by which to sort the results.`created` means when the alert was created.`updated` means when the alert's state last changed.`epss_percentage` sorts alerts by the Exploit Prediction Scoring System (EPSS) percentage. [QueryParameter("sort")] public global::GitHub.Enterprises.Item.Dependabot.Alerts.GetSortQueryParameterType? Sort { get; set; } /// A comma-separated list of states. If specified, only alerts with these states will be returned.Can be: `auto_dismissed`, `dismissed`, `fixed`, `open` diff --git a/src/GitHub/Enterprises/Item/Dependabot/Alerts/GetSortQueryParameterType.cs b/src/GitHub/Enterprises/Item/Dependabot/Alerts/GetSortQueryParameterType.cs index 27dfb7da8..7f5ee3a4f 100644 --- a/src/GitHub/Enterprises/Item/Dependabot/Alerts/GetSortQueryParameterType.cs +++ b/src/GitHub/Enterprises/Item/Dependabot/Alerts/GetSortQueryParameterType.cs @@ -16,5 +16,9 @@ public enum GetSortQueryParameterType #pragma warning disable CS1591 Updated, #pragma warning restore CS1591 + [EnumMember(Value = "epss_percentage")] + #pragma warning disable CS1591 + Epss_percentage, + #pragma warning restore CS1591 } } diff --git a/src/GitHub/Orgs/Item/Dependabot/Alerts/AlertsRequestBuilder.cs b/src/GitHub/Orgs/Item/Dependabot/Alerts/AlertsRequestBuilder.cs index 3b021935d..94b138688 100644 --- a/src/GitHub/Orgs/Item/Dependabot/Alerts/AlertsRequestBuilder.cs +++ b/src/GitHub/Orgs/Item/Dependabot/Alerts/AlertsRequestBuilder.cs @@ -163,7 +163,7 @@ public partial class AlertsRequestBuilderGetQueryParameters [QueryParameter("severity")] public string Severity { get; set; } #endif - /// The property by which to sort the results.`created` means when the alert was created.`updated` means when the alert's state last changed. + /// The property by which to sort the results.`created` means when the alert was created.`updated` means when the alert's state last changed.`epss_percentage` sorts alerts by the Exploit Prediction Scoring System (EPSS) percentage. [QueryParameter("sort")] public global::GitHub.Orgs.Item.Dependabot.Alerts.GetSortQueryParameterType? Sort { get; set; } /// A comma-separated list of states. If specified, only alerts with these states will be returned.Can be: `auto_dismissed`, `dismissed`, `fixed`, `open` diff --git a/src/GitHub/Orgs/Item/Dependabot/Alerts/GetSortQueryParameterType.cs b/src/GitHub/Orgs/Item/Dependabot/Alerts/GetSortQueryParameterType.cs index b2e540eee..84826934e 100644 --- a/src/GitHub/Orgs/Item/Dependabot/Alerts/GetSortQueryParameterType.cs +++ b/src/GitHub/Orgs/Item/Dependabot/Alerts/GetSortQueryParameterType.cs @@ -16,5 +16,9 @@ public enum GetSortQueryParameterType #pragma warning disable CS1591 Updated, #pragma warning restore CS1591 + [EnumMember(Value = "epss_percentage")] + #pragma warning disable CS1591 + Epss_percentage, + #pragma warning restore CS1591 } } diff --git a/src/GitHub/Repos/Item/Item/Dependabot/Alerts/AlertsRequestBuilder.cs b/src/GitHub/Repos/Item/Item/Dependabot/Alerts/AlertsRequestBuilder.cs index f6aa1451b..4d65b4472 100644 --- a/src/GitHub/Repos/Item/Item/Dependabot/Alerts/AlertsRequestBuilder.cs +++ b/src/GitHub/Repos/Item/Item/Dependabot/Alerts/AlertsRequestBuilder.cs @@ -191,7 +191,7 @@ public partial class AlertsRequestBuilderGetQueryParameters [QueryParameter("severity")] public string Severity { get; set; } #endif - /// The property by which to sort the results.`created` means when the alert was created.`updated` means when the alert's state last changed. + /// The property by which to sort the results.`created` means when the alert was created.`updated` means when the alert's state last changed.`epss_percentage` sorts alerts by the Exploit Prediction Scoring System (EPSS) percentage. [QueryParameter("sort")] public global::GitHub.Repos.Item.Item.Dependabot.Alerts.GetSortQueryParameterType? Sort { get; set; } /// A comma-separated list of states. If specified, only alerts with these states will be returned.Can be: `auto_dismissed`, `dismissed`, `fixed`, `open` diff --git a/src/GitHub/Repos/Item/Item/Dependabot/Alerts/GetSortQueryParameterType.cs b/src/GitHub/Repos/Item/Item/Dependabot/Alerts/GetSortQueryParameterType.cs index 76fafa859..f227723e0 100644 --- a/src/GitHub/Repos/Item/Item/Dependabot/Alerts/GetSortQueryParameterType.cs +++ b/src/GitHub/Repos/Item/Item/Dependabot/Alerts/GetSortQueryParameterType.cs @@ -16,5 +16,9 @@ public enum GetSortQueryParameterType #pragma warning disable CS1591 Updated, #pragma warning restore CS1591 + [EnumMember(Value = "epss_percentage")] + #pragma warning disable CS1591 + Epss_percentage, + #pragma warning restore CS1591 } } diff --git a/src/GitHub/User/Item/WithAccount_ItemRequestBuilder.cs b/src/GitHub/User/Item/WithAccount_ItemRequestBuilder.cs index 05beb70f7..fa405a7c0 100644 --- a/src/GitHub/User/Item/WithAccount_ItemRequestBuilder.cs +++ b/src/GitHub/User/Item/WithAccount_ItemRequestBuilder.cs @@ -34,7 +34,7 @@ public WithAccount_ItemRequestBuilder(string rawUrl, IRequestAdapter requestAdap { } /// - /// Provides publicly available information about someone with a GitHub account. This method takes their durable user `ID` instead of their `login`, which can change over time.The `email` key in the following response is the publicly visible email address from your GitHub Enterprise Server [profile page](https://github.com/settings/profile). When setting up your profile, you can select a primary email address to be “public” which provides an email entry for this endpoint. If you do not set a public email address for `email`, then it will have a value of `null`. You only see publicly visible email addresses when authenticated with GitHub Enterprise Server. For more information, see [Authentication](https://docs.github.com/enterprise-server@3.14/rest/guides/getting-started-with-the-rest-api#authentication).The Emails API enables you to list all of your email addresses, and toggle a primary email to be visible publicly. For more information, see "[Emails API](https://docs.github.com/enterprise-server@3.14/rest/users/emails)". + /// Provides publicly available information about someone with a GitHub account. This method takes their durable user `ID` instead of their `login`, which can change over time.The `email` key in the following response is the publicly visible email address from your GitHub Enterprise Server [profile page](https://github.com/settings/profile). When setting up your profile, you can select a primary email address to be public which provides an email entry for this endpoint. If you do not set a public email address for `email`, then it will have a value of `null`. You only see publicly visible email addresses when authenticated with GitHub Enterprise Server. For more information, see [Authentication](https://docs.github.com/enterprise-server@3.14/rest/guides/getting-started-with-the-rest-api#authentication).The Emails API enables you to list all of your email addresses, and toggle a primary email to be visible publicly. For more information, see [Emails API](https://docs.github.com/enterprise-server@3.14/rest/users/emails). /// API method documentation /// /// A @@ -58,7 +58,7 @@ public WithAccount_ItemRequestBuilder(string rawUrl, IRequestAdapter requestAdap return await RequestAdapter.SendAsync(requestInfo, global::GitHub.User.Item.WithAccount_ItemRequestBuilder.WithAccount_GetResponse.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); } /// - /// Provides publicly available information about someone with a GitHub account. This method takes their durable user `ID` instead of their `login`, which can change over time.The `email` key in the following response is the publicly visible email address from your GitHub Enterprise Server [profile page](https://github.com/settings/profile). When setting up your profile, you can select a primary email address to be “public” which provides an email entry for this endpoint. If you do not set a public email address for `email`, then it will have a value of `null`. You only see publicly visible email addresses when authenticated with GitHub Enterprise Server. For more information, see [Authentication](https://docs.github.com/enterprise-server@3.14/rest/guides/getting-started-with-the-rest-api#authentication).The Emails API enables you to list all of your email addresses, and toggle a primary email to be visible publicly. For more information, see "[Emails API](https://docs.github.com/enterprise-server@3.14/rest/users/emails)". + /// Provides publicly available information about someone with a GitHub account. This method takes their durable user `ID` instead of their `login`, which can change over time.The `email` key in the following response is the publicly visible email address from your GitHub Enterprise Server [profile page](https://github.com/settings/profile). When setting up your profile, you can select a primary email address to be public which provides an email entry for this endpoint. If you do not set a public email address for `email`, then it will have a value of `null`. You only see publicly visible email addresses when authenticated with GitHub Enterprise Server. For more information, see [Authentication](https://docs.github.com/enterprise-server@3.14/rest/guides/getting-started-with-the-rest-api#authentication).The Emails API enables you to list all of your email addresses, and toggle a primary email to be visible publicly. For more information, see [Emails API](https://docs.github.com/enterprise-server@3.14/rest/users/emails). /// /// A /// Configuration for the request such as headers, query parameters, and middleware options. diff --git a/src/GitHub/Users/Item/WithUsernameItemRequestBuilder.cs b/src/GitHub/Users/Item/WithUsernameItemRequestBuilder.cs index f9d79571c..1ad26981f 100644 --- a/src/GitHub/Users/Item/WithUsernameItemRequestBuilder.cs +++ b/src/GitHub/Users/Item/WithUsernameItemRequestBuilder.cs @@ -154,7 +154,7 @@ public WithUsernameItemRequestBuilder(string rawUrl, IRequestAdapter requestAdap { } /// - /// Provides publicly available information about someone with a GitHub account.The `email` key in the following response is the publicly visible email address from your GitHub Enterprise Server [profile page](https://github.com/settings/profile). When setting up your profile, you can select a primary email address to be “public” which provides an email entry for this endpoint. If you do not set a public email address for `email`, then it will have a value of `null`. You only see publicly visible email addresses when authenticated with GitHub Enterprise Server. For more information, see [Authentication](https://docs.github.com/enterprise-server@3.14/rest/guides/getting-started-with-the-rest-api#authentication).The Emails API enables you to list all of your email addresses, and toggle a primary email to be visible publicly. For more information, see "[Emails API](https://docs.github.com/enterprise-server@3.14/rest/users/emails)". + /// Provides publicly available information about someone with a GitHub account.The `email` key in the following response is the publicly visible email address from your GitHub Enterprise Server [profile page](https://github.com/settings/profile). When setting up your profile, you can select a primary email address to be public which provides an email entry for this endpoint. If you do not set a public email address for `email`, then it will have a value of `null`. You only see publicly visible email addresses when authenticated with GitHub Enterprise Server. For more information, see [Authentication](https://docs.github.com/enterprise-server@3.14/rest/guides/getting-started-with-the-rest-api#authentication).The Emails API enables you to list all of your email addresses, and toggle a primary email to be visible publicly. For more information, see [Emails API](https://docs.github.com/enterprise-server@3.14/rest/users/emails). /// API method documentation /// /// A @@ -178,7 +178,7 @@ public WithUsernameItemRequestBuilder(string rawUrl, IRequestAdapter requestAdap return await RequestAdapter.SendAsync(requestInfo, global::GitHub.Users.Item.WithUsernameItemRequestBuilder.WithUsernameGetResponse.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); } /// - /// Provides publicly available information about someone with a GitHub account.The `email` key in the following response is the publicly visible email address from your GitHub Enterprise Server [profile page](https://github.com/settings/profile). When setting up your profile, you can select a primary email address to be “public” which provides an email entry for this endpoint. If you do not set a public email address for `email`, then it will have a value of `null`. You only see publicly visible email addresses when authenticated with GitHub Enterprise Server. For more information, see [Authentication](https://docs.github.com/enterprise-server@3.14/rest/guides/getting-started-with-the-rest-api#authentication).The Emails API enables you to list all of your email addresses, and toggle a primary email to be visible publicly. For more information, see "[Emails API](https://docs.github.com/enterprise-server@3.14/rest/users/emails)". + /// Provides publicly available information about someone with a GitHub account.The `email` key in the following response is the publicly visible email address from your GitHub Enterprise Server [profile page](https://github.com/settings/profile). When setting up your profile, you can select a primary email address to be public which provides an email entry for this endpoint. If you do not set a public email address for `email`, then it will have a value of `null`. You only see publicly visible email addresses when authenticated with GitHub Enterprise Server. For more information, see [Authentication](https://docs.github.com/enterprise-server@3.14/rest/guides/getting-started-with-the-rest-api#authentication).The Emails API enables you to list all of your email addresses, and toggle a primary email to be visible publicly. For more information, see [Emails API](https://docs.github.com/enterprise-server@3.14/rest/users/emails). /// /// A /// Configuration for the request such as headers, query parameters, and middleware options. diff --git a/src/GitHub/kiota-lock.json b/src/GitHub/kiota-lock.json index fe1c5938f..b40170844 100644 --- a/src/GitHub/kiota-lock.json +++ b/src/GitHub/kiota-lock.json @@ -1,5 +1,5 @@ { - "descriptionHash": "EE108032A8C8F81CB6824F8597F73BA8C76BF9F567C23F7902154B17C08728CAEBD103A4DC6ABFFA17CA70328908EEC58B1C5825D8B591F815830EE6B8A3D1D2", + "descriptionHash": "4F19E818A8DF3861F13D87F08F3B9F958BCE6ECF92C5175CD8FDBF4F46A10BC4DB50D33E2A1EBDABF2C18B10D75BB8EB2351A4596B5149B07BBE126211C8CB6D", "descriptionLocation": "../../../../../schemas/ghes-3.14.json", "lockFileVersion": "1.0.0", "kiotaVersion": "1.19.0", From 760ccba9caa5a6d717173e039bed2ffbc9606b0c Mon Sep 17 00:00:00 2001 From: Octokit Bot Date: Sat, 18 Jan 2025 00:29:28 +0000 Subject: [PATCH 07/21] New updates to generated code --- src/GitHub/Models/Integration.cs | 85 +++++++++++++++++-- src/GitHub/Models/NullableIntegration.cs | 85 +++++++++++++++++-- .../Item/WithUsernameItemRequestBuilder.cs | 4 +- src/GitHub/kiota-lock.json | 2 +- 4 files changed, 163 insertions(+), 13 deletions(-) diff --git a/src/GitHub/Models/Integration.cs b/src/GitHub/Models/Integration.cs index 87f60b821..cfdd039d7 100644 --- a/src/GitHub/Models/Integration.cs +++ b/src/GitHub/Models/Integration.cs @@ -77,13 +77,13 @@ public partial class Integration : IAdditionalDataHolder, IParsable #else public string NodeId { get; set; } #endif - /// A GitHub user. + /// The owner property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable - public global::GitHub.Models.NullableSimpleUser? Owner { get; set; } + public global::GitHub.Models.Integration.Integration_owner? Owner { get; set; } #nullable restore #else - public global::GitHub.Models.NullableSimpleUser Owner { get; set; } + public global::GitHub.Models.Integration.Integration_owner Owner { get; set; } #endif /// The pem property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER @@ -154,7 +154,7 @@ public virtual IDictionary> GetFieldDeserializers() { "installations_count", n => { InstallationsCount = n.GetIntValue(); } }, { "name", n => { Name = n.GetStringValue(); } }, { "node_id", n => { NodeId = n.GetStringValue(); } }, - { "owner", n => { Owner = n.GetObjectValue(global::GitHub.Models.NullableSimpleUser.CreateFromDiscriminatorValue); } }, + { "owner", n => { Owner = n.GetObjectValue(global::GitHub.Models.Integration.Integration_owner.CreateFromDiscriminatorValue); } }, { "pem", n => { Pem = n.GetStringValue(); } }, { "permissions", n => { Permissions = n.GetObjectValue(global::GitHub.Models.Integration_permissions.CreateFromDiscriminatorValue); } }, { "slug", n => { Slug = n.GetStringValue(); } }, @@ -179,7 +179,7 @@ public virtual void Serialize(ISerializationWriter writer) writer.WriteIntValue("installations_count", InstallationsCount); writer.WriteStringValue("name", Name); writer.WriteStringValue("node_id", NodeId); - writer.WriteObjectValue("owner", Owner); + writer.WriteObjectValue("owner", Owner); writer.WriteStringValue("pem", Pem); writer.WriteObjectValue("permissions", Permissions); writer.WriteStringValue("slug", Slug); @@ -187,6 +187,81 @@ public virtual void Serialize(ISerializationWriter writer) writer.WriteStringValue("webhook_secret", WebhookSecret); writer.WriteAdditionalData(AdditionalData); } + /// + /// Composed type wrapper for classes , + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.19.0")] + public partial class Integration_owner : IComposedTypeWrapper, IParsable + { + /// Composed type representation for type +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::GitHub.Models.Enterprise? Enterprise { get; set; } +#nullable restore +#else + public global::GitHub.Models.Enterprise Enterprise { get; set; } +#endif + /// Composed type representation for type +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::GitHub.Models.SimpleUser? SimpleUser { get; set; } +#nullable restore +#else + public global::GitHub.Models.SimpleUser SimpleUser { get; set; } +#endif + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static global::GitHub.Models.Integration.Integration_owner CreateFromDiscriminatorValue(IParseNode parseNode) + { + _ = parseNode ?? throw new ArgumentNullException(nameof(parseNode)); + var mappingValue = parseNode.GetChildNode("")?.GetStringValue(); + var result = new global::GitHub.Models.Integration.Integration_owner(); + if("enterprise".Equals(mappingValue, StringComparison.OrdinalIgnoreCase)) + { + result.Enterprise = new global::GitHub.Models.Enterprise(); + } + else if("simple-user".Equals(mappingValue, StringComparison.OrdinalIgnoreCase)) + { + result.SimpleUser = new global::GitHub.Models.SimpleUser(); + } + return result; + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public virtual IDictionary> GetFieldDeserializers() + { + if(Enterprise != null) + { + return Enterprise.GetFieldDeserializers(); + } + else if(SimpleUser != null) + { + return SimpleUser.GetFieldDeserializers(); + } + return new Dictionary>(); + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public virtual void Serialize(ISerializationWriter writer) + { + _ = writer ?? throw new ArgumentNullException(nameof(writer)); + if(Enterprise != null) + { + writer.WriteObjectValue(null, Enterprise); + } + else if(SimpleUser != null) + { + writer.WriteObjectValue(null, SimpleUser); + } + } + } } } #pragma warning restore CS0618 diff --git a/src/GitHub/Models/NullableIntegration.cs b/src/GitHub/Models/NullableIntegration.cs index 0fa01e6ef..f335b35bf 100644 --- a/src/GitHub/Models/NullableIntegration.cs +++ b/src/GitHub/Models/NullableIntegration.cs @@ -77,13 +77,13 @@ public partial class NullableIntegration : IAdditionalDataHolder, IParsable #else public string NodeId { get; set; } #endif - /// A GitHub user. + /// The owner property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable - public global::GitHub.Models.NullableSimpleUser? Owner { get; set; } + public global::GitHub.Models.NullableIntegration.NullableIntegration_owner? Owner { get; set; } #nullable restore #else - public global::GitHub.Models.NullableSimpleUser Owner { get; set; } + public global::GitHub.Models.NullableIntegration.NullableIntegration_owner Owner { get; set; } #endif /// The pem property #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER @@ -154,7 +154,7 @@ public virtual IDictionary> GetFieldDeserializers() { "installations_count", n => { InstallationsCount = n.GetIntValue(); } }, { "name", n => { Name = n.GetStringValue(); } }, { "node_id", n => { NodeId = n.GetStringValue(); } }, - { "owner", n => { Owner = n.GetObjectValue(global::GitHub.Models.NullableSimpleUser.CreateFromDiscriminatorValue); } }, + { "owner", n => { Owner = n.GetObjectValue(global::GitHub.Models.NullableIntegration.NullableIntegration_owner.CreateFromDiscriminatorValue); } }, { "pem", n => { Pem = n.GetStringValue(); } }, { "permissions", n => { Permissions = n.GetObjectValue(global::GitHub.Models.NullableIntegration_permissions.CreateFromDiscriminatorValue); } }, { "slug", n => { Slug = n.GetStringValue(); } }, @@ -179,7 +179,7 @@ public virtual void Serialize(ISerializationWriter writer) writer.WriteIntValue("installations_count", InstallationsCount); writer.WriteStringValue("name", Name); writer.WriteStringValue("node_id", NodeId); - writer.WriteObjectValue("owner", Owner); + writer.WriteObjectValue("owner", Owner); writer.WriteStringValue("pem", Pem); writer.WriteObjectValue("permissions", Permissions); writer.WriteStringValue("slug", Slug); @@ -187,6 +187,81 @@ public virtual void Serialize(ISerializationWriter writer) writer.WriteStringValue("webhook_secret", WebhookSecret); writer.WriteAdditionalData(AdditionalData); } + /// + /// Composed type wrapper for classes , + /// + [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.19.0")] + public partial class NullableIntegration_owner : IComposedTypeWrapper, IParsable + { + /// Composed type representation for type +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::GitHub.Models.Enterprise? Enterprise { get; set; } +#nullable restore +#else + public global::GitHub.Models.Enterprise Enterprise { get; set; } +#endif + /// Composed type representation for type +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::GitHub.Models.SimpleUser? SimpleUser { get; set; } +#nullable restore +#else + public global::GitHub.Models.SimpleUser SimpleUser { get; set; } +#endif + /// + /// Creates a new instance of the appropriate class based on discriminator value + /// + /// A + /// The parse node to use to read the discriminator value and create the object + public static global::GitHub.Models.NullableIntegration.NullableIntegration_owner CreateFromDiscriminatorValue(IParseNode parseNode) + { + _ = parseNode ?? throw new ArgumentNullException(nameof(parseNode)); + var mappingValue = parseNode.GetChildNode("")?.GetStringValue(); + var result = new global::GitHub.Models.NullableIntegration.NullableIntegration_owner(); + if("enterprise".Equals(mappingValue, StringComparison.OrdinalIgnoreCase)) + { + result.Enterprise = new global::GitHub.Models.Enterprise(); + } + else if("simple-user".Equals(mappingValue, StringComparison.OrdinalIgnoreCase)) + { + result.SimpleUser = new global::GitHub.Models.SimpleUser(); + } + return result; + } + /// + /// The deserialization information for the current model + /// + /// A IDictionary<string, Action<IParseNode>> + public virtual IDictionary> GetFieldDeserializers() + { + if(Enterprise != null) + { + return Enterprise.GetFieldDeserializers(); + } + else if(SimpleUser != null) + { + return SimpleUser.GetFieldDeserializers(); + } + return new Dictionary>(); + } + /// + /// Serializes information the current object + /// + /// Serialization writer to use to serialize this model + public virtual void Serialize(ISerializationWriter writer) + { + _ = writer ?? throw new ArgumentNullException(nameof(writer)); + if(Enterprise != null) + { + writer.WriteObjectValue(null, Enterprise); + } + else if(SimpleUser != null) + { + writer.WriteObjectValue(null, SimpleUser); + } + } + } } } #pragma warning restore CS0618 diff --git a/src/GitHub/Orgs/Item/Memberships/Item/WithUsernameItemRequestBuilder.cs b/src/GitHub/Orgs/Item/Memberships/Item/WithUsernameItemRequestBuilder.cs index 78d746f37..72a8766b8 100644 --- a/src/GitHub/Orgs/Item/Memberships/Item/WithUsernameItemRequestBuilder.cs +++ b/src/GitHub/Orgs/Item/Memberships/Item/WithUsernameItemRequestBuilder.cs @@ -85,7 +85,7 @@ public async Task DeleteAsync(Action(requestInfo, global::GitHub.Models.OrgMembership.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); } /// - /// Only authenticated organization owners can add a member to the organization or update the member's role.* If the authenticated user is _adding_ a member to the organization, the invited user will receive an email inviting them to the organization. The user's [membership status](https://docs.github.com/enterprise-server@3.14/rest/orgs/members#get-organization-membership-for-a-user) will be `pending` until they accept the invitation. * Authenticated users can _update_ a user's membership by passing the `role` parameter. If the authenticated user changes a member's role to `admin`, the affected user will receive an email notifying them that they've been made an organization owner. If the authenticated user changes an owner's role to `member`, no email will be sent.**Rate limits**To prevent abuse, organization owners are limited to creating 50 organization invitations for an organization within a 24 hour period. If the organization is more than one month old or on a paid plan, the limit is 500 invitations per 24 hour period. + /// Only authenticated organization owners can add a member to the organization or update the member's role. If the authenticated user is _adding_ a member to the organization, the invited user will receive an email inviting them to the organization. The user's [membership status](https://docs.github.com/enterprise-server@3.14/rest/orgs/members#get-organization-membership-for-a-user) will be `pending` until they accept the invitation. Authenticated users can _update_ a user's membership by passing the `role` parameter. If the authenticated user changes a member's role to `admin`, the affected user will receive an email notifying them that they've been made an organization owner. If the authenticated user changes an owner's role to `member`, no email will be sent. The same rate limits as set on the appliance are applied to this endpoint. Most commonly, you will hit the secondary rate limit (if configured) due to CPU usage. /// API method documentation /// /// A @@ -151,7 +151,7 @@ public RequestInformation ToGetRequestInformation(Action - /// Only authenticated organization owners can add a member to the organization or update the member's role.* If the authenticated user is _adding_ a member to the organization, the invited user will receive an email inviting them to the organization. The user's [membership status](https://docs.github.com/enterprise-server@3.14/rest/orgs/members#get-organization-membership-for-a-user) will be `pending` until they accept the invitation. * Authenticated users can _update_ a user's membership by passing the `role` parameter. If the authenticated user changes a member's role to `admin`, the affected user will receive an email notifying them that they've been made an organization owner. If the authenticated user changes an owner's role to `member`, no email will be sent.**Rate limits**To prevent abuse, organization owners are limited to creating 50 organization invitations for an organization within a 24 hour period. If the organization is more than one month old or on a paid plan, the limit is 500 invitations per 24 hour period. + /// Only authenticated organization owners can add a member to the organization or update the member's role. If the authenticated user is _adding_ a member to the organization, the invited user will receive an email inviting them to the organization. The user's [membership status](https://docs.github.com/enterprise-server@3.14/rest/orgs/members#get-organization-membership-for-a-user) will be `pending` until they accept the invitation. Authenticated users can _update_ a user's membership by passing the `role` parameter. If the authenticated user changes a member's role to `admin`, the affected user will receive an email notifying them that they've been made an organization owner. If the authenticated user changes an owner's role to `member`, no email will be sent. The same rate limits as set on the appliance are applied to this endpoint. Most commonly, you will hit the secondary rate limit (if configured) due to CPU usage. /// /// A /// The request body diff --git a/src/GitHub/kiota-lock.json b/src/GitHub/kiota-lock.json index b40170844..ef975ad71 100644 --- a/src/GitHub/kiota-lock.json +++ b/src/GitHub/kiota-lock.json @@ -1,5 +1,5 @@ { - "descriptionHash": "4F19E818A8DF3861F13D87F08F3B9F958BCE6ECF92C5175CD8FDBF4F46A10BC4DB50D33E2A1EBDABF2C18B10D75BB8EB2351A4596B5149B07BBE126211C8CB6D", + "descriptionHash": "D5D1AC1F67F93A2B070B68802EC8500D19F64F2D36F7A0123D522F374F0267BF8135955654CFA0EDAAF50ACBC99405C73FE4F3ABD6B729493E8DF04F019E75D6", "descriptionLocation": "../../../../../schemas/ghes-3.14.json", "lockFileVersion": "1.0.0", "kiotaVersion": "1.19.0", From 45f23d476d00fd0a8b26dfbe28366d2ed95939e3 Mon Sep 17 00:00:00 2001 From: Octokit Bot Date: Tue, 21 Jan 2025 00:30:25 +0000 Subject: [PATCH 08/21] New updates to generated code --- .../Dependabot/Alerts/AlertsRequestBuilder.cs | 38 +------------------ src/GitHub/kiota-lock.json | 2 +- 2 files changed, 3 insertions(+), 37 deletions(-) diff --git a/src/GitHub/Repos/Item/Item/Dependabot/Alerts/AlertsRequestBuilder.cs b/src/GitHub/Repos/Item/Item/Dependabot/Alerts/AlertsRequestBuilder.cs index 4d65b4472..b89102c86 100644 --- a/src/GitHub/Repos/Item/Item/Dependabot/Alerts/AlertsRequestBuilder.cs +++ b/src/GitHub/Repos/Item/Item/Dependabot/Alerts/AlertsRequestBuilder.cs @@ -35,7 +35,7 @@ public partial class AlertsRequestBuilder : BaseRequestBuilder /// /// Path parameters for the request /// The request adapter to use to execute the requests. - public AlertsRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/repos/{owner%2Did}/{repo%2Did}/dependabot/alerts{?after*,before*,direction*,ecosystem*,first*,last*,manifest*,package*,page*,per_page*,scope*,severity*,sort*,state*}", pathParameters) + public AlertsRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/repos/{owner%2Did}/{repo%2Did}/dependabot/alerts{?direction*,ecosystem*,manifest*,package*,scope*,severity*,sort*,state*}", pathParameters) { } /// @@ -43,7 +43,7 @@ public AlertsRequestBuilder(Dictionary pathParameters, IRequestA /// /// The raw URL to use for the request builder. /// The request adapter to use to execute the requests. - public AlertsRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/repos/{owner%2Did}/{repo%2Did}/dependabot/alerts{?after*,before*,direction*,ecosystem*,first*,last*,manifest*,package*,page*,per_page*,scope*,severity*,sort*,state*}", rawUrl) + public AlertsRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/repos/{owner%2Did}/{repo%2Did}/dependabot/alerts{?direction*,ecosystem*,manifest*,package*,scope*,severity*,sort*,state*}", rawUrl) { } /// @@ -111,26 +111,6 @@ public RequestInformation ToGetRequestInformation(ActionA cursor, as given in the [Link header](https://docs.github.com/enterprise-server@3.14/rest/guides/using-pagination-in-the-rest-api#using-link-headers). If specified, the query only searches for results after this cursor. For more information, see "[Using pagination in the REST API](https://docs.github.com/enterprise-server@3.14/rest/using-the-rest-api/using-pagination-in-the-rest-api)." -#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER -#nullable enable - [QueryParameter("after")] - public string? After { get; set; } -#nullable restore -#else - [QueryParameter("after")] - public string After { get; set; } -#endif - /// A cursor, as given in the [Link header](https://docs.github.com/enterprise-server@3.14/rest/guides/using-pagination-in-the-rest-api#using-link-headers). If specified, the query only searches for results before this cursor. For more information, see "[Using pagination in the REST API](https://docs.github.com/enterprise-server@3.14/rest/using-the-rest-api/using-pagination-in-the-rest-api)." -#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER -#nullable enable - [QueryParameter("before")] - public string? Before { get; set; } -#nullable restore -#else - [QueryParameter("before")] - public string Before { get; set; } -#endif /// The direction to sort the results by. [QueryParameter("direction")] public global::GitHub.Repos.Item.Item.Dependabot.Alerts.GetDirectionQueryParameterType? Direction { get; set; } @@ -144,12 +124,6 @@ public partial class AlertsRequestBuilderGetQueryParameters [QueryParameter("ecosystem")] public string Ecosystem { get; set; } #endif - /// **Deprecated**. The number of results per page (max 100), starting from the first matching result.This parameter must not be used in combination with `last`.Instead, use `per_page` in combination with `after` to fetch the first page of results. - [QueryParameter("first")] - public int? First { get; set; } - /// **Deprecated**. The number of results per page (max 100), starting from the last matching result.This parameter must not be used in combination with `first`.Instead, use `per_page` in combination with `before` to fetch the last page of results. - [QueryParameter("last")] - public int? Last { get; set; } /// A comma-separated list of full manifest paths. If specified, only alerts for these manifests will be returned. #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable @@ -170,14 +144,6 @@ public partial class AlertsRequestBuilderGetQueryParameters [QueryParameter("package")] public string Package { get; set; } #endif - /// **Closing down notice**. Page number of the results to fetch. Use cursor-based pagination with `before` or `after` instead. - [Obsolete("")] - [QueryParameter("page")] - public int? Page { get; set; } - /// The number of results per page (max 100). For more information, see "[Using pagination in the REST API](https://docs.github.com/enterprise-server@3.14/rest/using-the-rest-api/using-pagination-in-the-rest-api)." - [Obsolete("")] - [QueryParameter("per_page")] - public int? PerPage { get; set; } /// The scope of the vulnerable dependency. If specified, only alerts with this scope will be returned. [QueryParameter("scope")] public global::GitHub.Repos.Item.Item.Dependabot.Alerts.GetScopeQueryParameterType? Scope { get; set; } diff --git a/src/GitHub/kiota-lock.json b/src/GitHub/kiota-lock.json index ef975ad71..4e7c8ae0d 100644 --- a/src/GitHub/kiota-lock.json +++ b/src/GitHub/kiota-lock.json @@ -1,5 +1,5 @@ { - "descriptionHash": "D5D1AC1F67F93A2B070B68802EC8500D19F64F2D36F7A0123D522F374F0267BF8135955654CFA0EDAAF50ACBC99405C73FE4F3ABD6B729493E8DF04F019E75D6", + "descriptionHash": "B985ADA950A78C590AAD7E574663508954E02FAF4BD5CB03B4942A4A267BE7F83D625C1888C71327B5B2E1F9B39F70CC7BE29D0A68B003F86D472EA9E1B84B6C", "descriptionLocation": "../../../../../schemas/ghes-3.14.json", "lockFileVersion": "1.0.0", "kiotaVersion": "1.19.0", From 5bbdec991cb244c8e981d5b0096a9d5556c4bf48 Mon Sep 17 00:00:00 2001 From: Octokit Bot Date: Sat, 25 Jan 2025 00:30:08 +0000 Subject: [PATCH 09/21] New updates to generated code --- src/GitHub/Models/GlobalAdvisory.cs | 9 ++++----- ...Advisory_epss.cs => SecurityAdvisoryEpss.cs} | 17 +++++++++-------- src/GitHub/kiota-lock.json | 2 +- 3 files changed, 14 insertions(+), 14 deletions(-) rename src/GitHub/Models/{GlobalAdvisory_epss.cs => SecurityAdvisoryEpss.cs} (80%) diff --git a/src/GitHub/Models/GlobalAdvisory.cs b/src/GitHub/Models/GlobalAdvisory.cs index 38675c4a8..eac00422d 100644 --- a/src/GitHub/Models/GlobalAdvisory.cs +++ b/src/GitHub/Models/GlobalAdvisory.cs @@ -61,13 +61,13 @@ public partial class GlobalAdvisory : IParsable #else public string Description { get; set; } #endif - /// The epss property + /// The EPSS scores as calculated by the [Exploit Prediction Scoring System](https://www.first.org/epss). #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable - public global::GitHub.Models.GlobalAdvisory_epss? Epss { get; set; } + public global::GitHub.Models.SecurityAdvisoryEpss? Epss { get; private set; } #nullable restore #else - public global::GitHub.Models.GlobalAdvisory_epss Epss { get; set; } + public global::GitHub.Models.SecurityAdvisoryEpss Epss { get; private set; } #endif /// The GitHub Security Advisory ID. #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER @@ -179,7 +179,7 @@ public virtual IDictionary> GetFieldDeserializers() { "cvss_severities", n => { CvssSeverities = n.GetObjectValue(global::GitHub.Models.CvssSeverities.CreateFromDiscriminatorValue); } }, { "cwes", n => { Cwes = n.GetCollectionOfObjectValues(global::GitHub.Models.GlobalAdvisory_cwes.CreateFromDiscriminatorValue)?.AsList(); } }, { "description", n => { Description = n.GetStringValue(); } }, - { "epss", n => { Epss = n.GetObjectValue(global::GitHub.Models.GlobalAdvisory_epss.CreateFromDiscriminatorValue); } }, + { "epss", n => { Epss = n.GetObjectValue(global::GitHub.Models.SecurityAdvisoryEpss.CreateFromDiscriminatorValue); } }, { "ghsa_id", n => { GhsaId = n.GetStringValue(); } }, { "github_reviewed_at", n => { GithubReviewedAt = n.GetDateTimeOffsetValue(); } }, { "html_url", n => { HtmlUrl = n.GetStringValue(); } }, @@ -209,7 +209,6 @@ public virtual void Serialize(ISerializationWriter writer) writer.WriteObjectValue("cvss_severities", CvssSeverities); writer.WriteCollectionOfObjectValues("cwes", Cwes); writer.WriteStringValue("description", Description); - writer.WriteObjectValue("epss", Epss); writer.WriteCollectionOfPrimitiveValues("references", References); writer.WriteEnumValue("severity", Severity); writer.WriteStringValue("source_code_location", SourceCodeLocation); diff --git a/src/GitHub/Models/GlobalAdvisory_epss.cs b/src/GitHub/Models/SecurityAdvisoryEpss.cs similarity index 80% rename from src/GitHub/Models/GlobalAdvisory_epss.cs rename to src/GitHub/Models/SecurityAdvisoryEpss.cs index d504c5644..55ae7876b 100644 --- a/src/GitHub/Models/GlobalAdvisory_epss.cs +++ b/src/GitHub/Models/SecurityAdvisoryEpss.cs @@ -7,10 +7,11 @@ using System; namespace GitHub.Models { + /// + /// The EPSS scores as calculated by the [Exploit Prediction Scoring System](https://www.first.org/epss). + /// [global::System.CodeDom.Compiler.GeneratedCode("Kiota", "1.19.0")] - #pragma warning disable CS1591 - public partial class GlobalAdvisory_epss : IAdditionalDataHolder, IParsable - #pragma warning restore CS1591 + public partial class SecurityAdvisoryEpss : IAdditionalDataHolder, IParsable { /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. public IDictionary AdditionalData { get; set; } @@ -19,21 +20,21 @@ public partial class GlobalAdvisory_epss : IAdditionalDataHolder, IParsable /// The percentile property public double? Percentile { get; set; } /// - /// Instantiates a new and sets the default values. + /// Instantiates a new and sets the default values. /// - public GlobalAdvisory_epss() + public SecurityAdvisoryEpss() { AdditionalData = new Dictionary(); } /// /// Creates a new instance of the appropriate class based on discriminator value /// - /// A + /// A /// The parse node to use to read the discriminator value and create the object - public static global::GitHub.Models.GlobalAdvisory_epss CreateFromDiscriminatorValue(IParseNode parseNode) + public static global::GitHub.Models.SecurityAdvisoryEpss CreateFromDiscriminatorValue(IParseNode parseNode) { _ = parseNode ?? throw new ArgumentNullException(nameof(parseNode)); - return new global::GitHub.Models.GlobalAdvisory_epss(); + return new global::GitHub.Models.SecurityAdvisoryEpss(); } /// /// The deserialization information for the current model diff --git a/src/GitHub/kiota-lock.json b/src/GitHub/kiota-lock.json index 4e7c8ae0d..f9a708dba 100644 --- a/src/GitHub/kiota-lock.json +++ b/src/GitHub/kiota-lock.json @@ -1,5 +1,5 @@ { - "descriptionHash": "B985ADA950A78C590AAD7E574663508954E02FAF4BD5CB03B4942A4A267BE7F83D625C1888C71327B5B2E1F9B39F70CC7BE29D0A68B003F86D472EA9E1B84B6C", + "descriptionHash": "7742F3383A3A4FA822356395BA968E9D39E4BEB5364EFE66548BCEA25AF058B3A35A9348A70AF7395EB5689ED699E0E2C7A784CD48EEA4DC767EF22B62DCA663", "descriptionLocation": "../../../../../schemas/ghes-3.14.json", "lockFileVersion": "1.0.0", "kiotaVersion": "1.19.0", From 202b01408101dee868396eee5a1c4c04e790aa0c Mon Sep 17 00:00:00 2001 From: Octokit Bot Date: Fri, 31 Jan 2025 00:30:57 +0000 Subject: [PATCH 10/21] New updates to generated code --- src/GitHub/Models/GhesLicenseInfo.cs | 2 +- src/GitHub/kiota-lock.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/GitHub/Models/GhesLicenseInfo.cs b/src/GitHub/Models/GhesLicenseInfo.cs index 5d745d3d2..d9997b424 100644 --- a/src/GitHub/Models/GhesLicenseInfo.cs +++ b/src/GitHub/Models/GhesLicenseInfo.cs @@ -28,7 +28,7 @@ public partial class GhesLicenseInfo : IAdditionalDataHolder, IParsable #else public string Company { get; set; } #endif - /// Whether the Github Connect feature is enabled. + /// Whether the GitHub Connect feature is enabled. public bool? CroquetSupport { get; set; } /// Whether this license is issued under custom terms. public bool? CustomTerms { get; set; } diff --git a/src/GitHub/kiota-lock.json b/src/GitHub/kiota-lock.json index f9a708dba..3ab06c710 100644 --- a/src/GitHub/kiota-lock.json +++ b/src/GitHub/kiota-lock.json @@ -1,5 +1,5 @@ { - "descriptionHash": "7742F3383A3A4FA822356395BA968E9D39E4BEB5364EFE66548BCEA25AF058B3A35A9348A70AF7395EB5689ED699E0E2C7A784CD48EEA4DC767EF22B62DCA663", + "descriptionHash": "96D8273EE0DE252B122D0DEC8BEB2AF1103D701FC63C024918128023D044D7674346DB2BAEF5ED71B7DB7A9B271D29F670563E7726269BC715CBB7C0A84CA1B3", "descriptionLocation": "../../../../../schemas/ghes-3.14.json", "lockFileVersion": "1.0.0", "kiotaVersion": "1.19.0", From 37e94e950973b8055fc546e89eee506c9f005ebc Mon Sep 17 00:00:00 2001 From: Octokit Bot Date: Thu, 6 Feb 2025 00:31:30 +0000 Subject: [PATCH 11/21] New updates to generated code --- .../GenerateJitconfig/GenerateJitconfigRequestBuilder.cs | 2 ++ src/GitHub/Models/Runner.cs | 4 ++++ .../GenerateJitconfig/GenerateJitconfigRequestBuilder.cs | 2 ++ .../GenerateJitconfig/GenerateJitconfigRequestBuilder.cs | 2 ++ src/GitHub/kiota-lock.json | 2 +- 5 files changed, 11 insertions(+), 1 deletion(-) diff --git a/src/GitHub/Enterprises/Item/Actions/Runners/GenerateJitconfig/GenerateJitconfigRequestBuilder.cs b/src/GitHub/Enterprises/Item/Actions/Runners/GenerateJitconfig/GenerateJitconfigRequestBuilder.cs index 327c1c2c5..ecbc6226b 100644 --- a/src/GitHub/Enterprises/Item/Actions/Runners/GenerateJitconfig/GenerateJitconfigRequestBuilder.cs +++ b/src/GitHub/Enterprises/Item/Actions/Runners/GenerateJitconfig/GenerateJitconfigRequestBuilder.cs @@ -42,6 +42,7 @@ public GenerateJitconfigRequestBuilder(string rawUrl, IRequestAdapter requestAda /// Cancellation token to use when cancelling requests /// Configuration for the request such as headers, query parameters, and middleware options. /// When receiving a 404 status code + /// When receiving a 409 status code /// When receiving a 422 status code #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable @@ -57,6 +58,7 @@ public GenerateJitconfigRequestBuilder(string rawUrl, IRequestAdapter requestAda var errorMapping = new Dictionary> { { "404", global::GitHub.Models.BasicError.CreateFromDiscriminatorValue }, + { "409", global::GitHub.Models.BasicError.CreateFromDiscriminatorValue }, { "422", global::GitHub.Models.ValidationErrorSimple.CreateFromDiscriminatorValue }, }; return await RequestAdapter.SendAsync(requestInfo, global::GitHub.Enterprises.Item.Actions.Runners.GenerateJitconfig.GenerateJitconfigPostResponse.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); diff --git a/src/GitHub/Models/Runner.cs b/src/GitHub/Models/Runner.cs index aa051bb82..e5a75c87f 100644 --- a/src/GitHub/Models/Runner.cs +++ b/src/GitHub/Models/Runner.cs @@ -17,6 +17,8 @@ public partial class Runner : IAdditionalDataHolder, IParsable public IDictionary AdditionalData { get; set; } /// The busy property public bool? Busy { get; set; } + /// The ephemeral property + public bool? Ephemeral { get; set; } /// The id of the runner. public int? Id { get; set; } /// The labels property @@ -79,6 +81,7 @@ public virtual IDictionary> GetFieldDeserializers() return new Dictionary> { { "busy", n => { Busy = n.GetBoolValue(); } }, + { "ephemeral", n => { Ephemeral = n.GetBoolValue(); } }, { "id", n => { Id = n.GetIntValue(); } }, { "labels", n => { Labels = n.GetCollectionOfObjectValues(global::GitHub.Models.RunnerLabel.CreateFromDiscriminatorValue)?.AsList(); } }, { "name", n => { Name = n.GetStringValue(); } }, @@ -95,6 +98,7 @@ public virtual void Serialize(ISerializationWriter writer) { _ = writer ?? throw new ArgumentNullException(nameof(writer)); writer.WriteBoolValue("busy", Busy); + writer.WriteBoolValue("ephemeral", Ephemeral); writer.WriteIntValue("id", Id); writer.WriteCollectionOfObjectValues("labels", Labels); writer.WriteStringValue("name", Name); diff --git a/src/GitHub/Orgs/Item/Actions/Runners/GenerateJitconfig/GenerateJitconfigRequestBuilder.cs b/src/GitHub/Orgs/Item/Actions/Runners/GenerateJitconfig/GenerateJitconfigRequestBuilder.cs index 950da1df5..45252f6fb 100644 --- a/src/GitHub/Orgs/Item/Actions/Runners/GenerateJitconfig/GenerateJitconfigRequestBuilder.cs +++ b/src/GitHub/Orgs/Item/Actions/Runners/GenerateJitconfig/GenerateJitconfigRequestBuilder.cs @@ -42,6 +42,7 @@ public GenerateJitconfigRequestBuilder(string rawUrl, IRequestAdapter requestAda /// Cancellation token to use when cancelling requests /// Configuration for the request such as headers, query parameters, and middleware options. /// When receiving a 404 status code + /// When receiving a 409 status code /// When receiving a 422 status code #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable @@ -57,6 +58,7 @@ public GenerateJitconfigRequestBuilder(string rawUrl, IRequestAdapter requestAda var errorMapping = new Dictionary> { { "404", global::GitHub.Models.BasicError.CreateFromDiscriminatorValue }, + { "409", global::GitHub.Models.BasicError.CreateFromDiscriminatorValue }, { "422", global::GitHub.Models.ValidationErrorSimple.CreateFromDiscriminatorValue }, }; return await RequestAdapter.SendAsync(requestInfo, global::GitHub.Orgs.Item.Actions.Runners.GenerateJitconfig.GenerateJitconfigPostResponse.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); diff --git a/src/GitHub/Repos/Item/Item/Actions/Runners/GenerateJitconfig/GenerateJitconfigRequestBuilder.cs b/src/GitHub/Repos/Item/Item/Actions/Runners/GenerateJitconfig/GenerateJitconfigRequestBuilder.cs index 5581fa5ff..dd5fd95e0 100644 --- a/src/GitHub/Repos/Item/Item/Actions/Runners/GenerateJitconfig/GenerateJitconfigRequestBuilder.cs +++ b/src/GitHub/Repos/Item/Item/Actions/Runners/GenerateJitconfig/GenerateJitconfigRequestBuilder.cs @@ -42,6 +42,7 @@ public GenerateJitconfigRequestBuilder(string rawUrl, IRequestAdapter requestAda /// Cancellation token to use when cancelling requests /// Configuration for the request such as headers, query parameters, and middleware options. /// When receiving a 404 status code + /// When receiving a 409 status code /// When receiving a 422 status code #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable @@ -57,6 +58,7 @@ public GenerateJitconfigRequestBuilder(string rawUrl, IRequestAdapter requestAda var errorMapping = new Dictionary> { { "404", global::GitHub.Models.BasicError.CreateFromDiscriminatorValue }, + { "409", global::GitHub.Models.BasicError.CreateFromDiscriminatorValue }, { "422", global::GitHub.Models.ValidationErrorSimple.CreateFromDiscriminatorValue }, }; return await RequestAdapter.SendAsync(requestInfo, global::GitHub.Repos.Item.Item.Actions.Runners.GenerateJitconfig.GenerateJitconfigPostResponse.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); diff --git a/src/GitHub/kiota-lock.json b/src/GitHub/kiota-lock.json index 3ab06c710..58ad7e463 100644 --- a/src/GitHub/kiota-lock.json +++ b/src/GitHub/kiota-lock.json @@ -1,5 +1,5 @@ { - "descriptionHash": "96D8273EE0DE252B122D0DEC8BEB2AF1103D701FC63C024918128023D044D7674346DB2BAEF5ED71B7DB7A9B271D29F670563E7726269BC715CBB7C0A84CA1B3", + "descriptionHash": "492DED165CBE3207F99C24E854F2D4C09FC4CCC3BC88AE561E88A23B9AE58F5F5B15A4C55F2E61AE5667F8B23994E44CFF1AFD6F2573C5B82D72866F3C3F849E", "descriptionLocation": "../../../../../schemas/ghes-3.14.json", "lockFileVersion": "1.0.0", "kiotaVersion": "1.19.0", From 2f5673d494738f120f3df8d3a2d5e67c51c0206b Mon Sep 17 00:00:00 2001 From: Octokit Bot Date: Fri, 7 Feb 2025 00:31:20 +0000 Subject: [PATCH 12/21] New updates to generated code --- .../Scim/V2/Enterprises/Item/Groups/GroupsRequestBuilder.cs | 2 +- .../Scim/V2/Enterprises/Item/Users/UsersRequestBuilder.cs | 2 +- src/GitHub/kiota-lock.json | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/GitHub/Scim/V2/Enterprises/Item/Groups/GroupsRequestBuilder.cs b/src/GitHub/Scim/V2/Enterprises/Item/Groups/GroupsRequestBuilder.cs index 3f586ca7f..b61cee529 100644 --- a/src/GitHub/Scim/V2/Enterprises/Item/Groups/GroupsRequestBuilder.cs +++ b/src/GitHub/Scim/V2/Enterprises/Item/Groups/GroupsRequestBuilder.cs @@ -173,7 +173,7 @@ public partial class GroupsRequestBuilderGetQueryParameters [QueryParameter("excludedAttributes")] public string ExcludedAttributes { get; set; } #endif - /// If specified, only results that match the specified filter will be returned. Multiple filters are not supported. Possible filters are `externalId`, `id`, and `displayName`. For example, `?filter="externalId eq '9138790-10932-109120392-12321'"`. + /// If specified, only results that match the specified filter will be returned. Multiple filters are not supported. Possible filters are `externalId`, `id`, and `displayName`. For example, `?filter='externalId eq "9138790-10932-109120392-12321"'`. #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable [QueryParameter("filter")] diff --git a/src/GitHub/Scim/V2/Enterprises/Item/Users/UsersRequestBuilder.cs b/src/GitHub/Scim/V2/Enterprises/Item/Users/UsersRequestBuilder.cs index d80f88c8e..04ad0e13f 100644 --- a/src/GitHub/Scim/V2/Enterprises/Item/Users/UsersRequestBuilder.cs +++ b/src/GitHub/Scim/V2/Enterprises/Item/Users/UsersRequestBuilder.cs @@ -163,7 +163,7 @@ public partial class UsersRequestBuilderGetQueryParameters /// Used for pagination: the number of results to return per page. [QueryParameter("count")] public int? Count { get; set; } - /// If specified, only results that match the specified filter will be returned. Multiple filters are not supported. Possible filters are `userName`, `externalId`, `id`, and `displayName`. For example, `?filter="externalId eq '9138790-10932-109120392-12321'"`. + /// If specified, only results that match the specified filter will be returned. Multiple filters are not supported. Possible filters are `userName`, `externalId`, `id`, and `displayName`. For example, `?filter='externalId eq "9138790-10932-109120392-12321"'`. #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable [QueryParameter("filter")] diff --git a/src/GitHub/kiota-lock.json b/src/GitHub/kiota-lock.json index 58ad7e463..c4a9f32d5 100644 --- a/src/GitHub/kiota-lock.json +++ b/src/GitHub/kiota-lock.json @@ -1,5 +1,5 @@ { - "descriptionHash": "492DED165CBE3207F99C24E854F2D4C09FC4CCC3BC88AE561E88A23B9AE58F5F5B15A4C55F2E61AE5667F8B23994E44CFF1AFD6F2573C5B82D72866F3C3F849E", + "descriptionHash": "B9B16113802FBB991BB09A04685B76AE935A3D626732B45717F1E8AB8CFF3A135BE6EB941E281EDAEB3982E1CE079CBDF754155D1292407610B11EA630EB6FAB", "descriptionLocation": "../../../../../schemas/ghes-3.14.json", "lockFileVersion": "1.0.0", "kiotaVersion": "1.19.0", From 77a43f126a2f1b5ced2e51cba179f10782abdb3f Mon Sep 17 00:00:00 2001 From: Octokit Bot Date: Sat, 8 Feb 2025 00:30:30 +0000 Subject: [PATCH 13/21] New updates to generated code --- src/GitHub/kiota-lock.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/GitHub/kiota-lock.json b/src/GitHub/kiota-lock.json index c4a9f32d5..234e80273 100644 --- a/src/GitHub/kiota-lock.json +++ b/src/GitHub/kiota-lock.json @@ -1,5 +1,5 @@ { - "descriptionHash": "B9B16113802FBB991BB09A04685B76AE935A3D626732B45717F1E8AB8CFF3A135BE6EB941E281EDAEB3982E1CE079CBDF754155D1292407610B11EA630EB6FAB", + "descriptionHash": "BCDAFD07869D71D468D4D2E62B0A13414EF21D97301681B6B92FB5884BD6983090B627D4A1764BE426CFC9689E1300B76F563D984B4BB27D0A3E94C2393BED94", "descriptionLocation": "../../../../../schemas/ghes-3.14.json", "lockFileVersion": "1.0.0", "kiotaVersion": "1.19.0", From 7020db78bb262b8648b8e98b5934e97360cd1527 Mon Sep 17 00:00:00 2001 From: Octokit Bot Date: Wed, 12 Feb 2025 00:31:08 +0000 Subject: [PATCH 14/21] New updates to generated code --- src/GitHub/Models/Announcement.cs | 4 ++++ src/GitHub/kiota-lock.json | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/GitHub/Models/Announcement.cs b/src/GitHub/Models/Announcement.cs index e43ac6c62..9c9137242 100644 --- a/src/GitHub/Models/Announcement.cs +++ b/src/GitHub/Models/Announcement.cs @@ -25,6 +25,8 @@ public partial class Announcement : IAdditionalDataHolder, IParsable #endif /// The time at which the announcement expires. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`. To set an announcement that never expires, omit this parameter, set it to `null`, or set it to an empty string. public DateTimeOffset? ExpiresAt { get; set; } + /// Whether an announcement can be dismissed by the user. + public bool? UserDismissible { get; set; } /// /// Instantiates a new and sets the default values. /// @@ -52,6 +54,7 @@ public virtual IDictionary> GetFieldDeserializers() { { "announcement", n => { AnnouncementProp = n.GetStringValue(); } }, { "expires_at", n => { ExpiresAt = n.GetDateTimeOffsetValue(); } }, + { "user_dismissible", n => { UserDismissible = n.GetBoolValue(); } }, }; } /// @@ -63,6 +66,7 @@ public virtual void Serialize(ISerializationWriter writer) _ = writer ?? throw new ArgumentNullException(nameof(writer)); writer.WriteStringValue("announcement", AnnouncementProp); writer.WriteDateTimeOffsetValue("expires_at", ExpiresAt); + writer.WriteBoolValue("user_dismissible", UserDismissible); writer.WriteAdditionalData(AdditionalData); } } diff --git a/src/GitHub/kiota-lock.json b/src/GitHub/kiota-lock.json index 234e80273..fe3d32b77 100644 --- a/src/GitHub/kiota-lock.json +++ b/src/GitHub/kiota-lock.json @@ -1,5 +1,5 @@ { - "descriptionHash": "BCDAFD07869D71D468D4D2E62B0A13414EF21D97301681B6B92FB5884BD6983090B627D4A1764BE426CFC9689E1300B76F563D984B4BB27D0A3E94C2393BED94", + "descriptionHash": "94064940D156935BA3C0C2F86EC43BD9FA7EBC5CB917FD3DE8721DCBCEAFC3DA9FF3BD3F0ABEE2E824278C3282E8EBB879FA1BE9C4090191E9766A5E5A2BF24E", "descriptionLocation": "../../../../../schemas/ghes-3.14.json", "lockFileVersion": "1.0.0", "kiotaVersion": "1.19.0", From aa3a320d6f950af686f905e8d17f10709ea43a83 Mon Sep 17 00:00:00 2001 From: Octokit Bot Date: Thu, 13 Feb 2025 00:31:24 +0000 Subject: [PATCH 15/21] New updates to generated code --- src/GitHub/Models/CodeScanningAlert.cs | 10 ++++++++++ src/GitHub/Models/CodeScanningAlertItems.cs | 10 ++++++++++ .../Models/CodeScanningOrganizationAlertItems.cs | 10 ++++++++++ .../V2/Enterprises/Item/Groups/GroupsRequestBuilder.cs | 2 +- .../V2/Enterprises/Item/Users/UsersRequestBuilder.cs | 2 +- src/GitHub/kiota-lock.json | 2 +- 6 files changed, 33 insertions(+), 3 deletions(-) diff --git a/src/GitHub/Models/CodeScanningAlert.cs b/src/GitHub/Models/CodeScanningAlert.cs index b7e9dc4aa..0e55c240b 100644 --- a/src/GitHub/Models/CodeScanningAlert.cs +++ b/src/GitHub/Models/CodeScanningAlert.cs @@ -16,6 +16,14 @@ public partial class CodeScanningAlert : IAdditionalDataHolder, IParsable public IDictionary AdditionalData { get; set; } /// The time that the alert was created in ISO 8601 format: `YYYY-MM-DDTHH:MM:SSZ`. public DateTimeOffset? CreatedAt { get; private set; } + /// A GitHub user. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::GitHub.Models.NullableSimpleUser? DismissalApprovedBy { get; set; } +#nullable restore +#else + public global::GitHub.Models.NullableSimpleUser DismissalApprovedBy { get; set; } +#endif /// The time that the alert was dismissed in ISO 8601 format: `YYYY-MM-DDTHH:MM:SSZ`. public DateTimeOffset? DismissedAt { get; private set; } /// A GitHub user. @@ -118,6 +126,7 @@ public virtual IDictionary> GetFieldDeserializers() return new Dictionary> { { "created_at", n => { CreatedAt = n.GetDateTimeOffsetValue(); } }, + { "dismissal_approved_by", n => { DismissalApprovedBy = n.GetObjectValue(global::GitHub.Models.NullableSimpleUser.CreateFromDiscriminatorValue); } }, { "dismissed_at", n => { DismissedAt = n.GetDateTimeOffsetValue(); } }, { "dismissed_by", n => { DismissedBy = n.GetObjectValue(global::GitHub.Models.NullableSimpleUser.CreateFromDiscriminatorValue); } }, { "dismissed_comment", n => { DismissedComment = n.GetStringValue(); } }, @@ -141,6 +150,7 @@ public virtual IDictionary> GetFieldDeserializers() public virtual void Serialize(ISerializationWriter writer) { _ = writer ?? throw new ArgumentNullException(nameof(writer)); + writer.WriteObjectValue("dismissal_approved_by", DismissalApprovedBy); writer.WriteObjectValue("dismissed_by", DismissedBy); writer.WriteStringValue("dismissed_comment", DismissedComment); writer.WriteEnumValue("dismissed_reason", DismissedReason); diff --git a/src/GitHub/Models/CodeScanningAlertItems.cs b/src/GitHub/Models/CodeScanningAlertItems.cs index 113118784..e590bf58f 100644 --- a/src/GitHub/Models/CodeScanningAlertItems.cs +++ b/src/GitHub/Models/CodeScanningAlertItems.cs @@ -16,6 +16,14 @@ public partial class CodeScanningAlertItems : IAdditionalDataHolder, IParsable public IDictionary AdditionalData { get; set; } /// The time that the alert was created in ISO 8601 format: `YYYY-MM-DDTHH:MM:SSZ`. public DateTimeOffset? CreatedAt { get; private set; } + /// A GitHub user. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::GitHub.Models.NullableSimpleUser? DismissalApprovedBy { get; set; } +#nullable restore +#else + public global::GitHub.Models.NullableSimpleUser DismissalApprovedBy { get; set; } +#endif /// The time that the alert was dismissed in ISO 8601 format: `YYYY-MM-DDTHH:MM:SSZ`. public DateTimeOffset? DismissedAt { get; private set; } /// A GitHub user. @@ -118,6 +126,7 @@ public virtual IDictionary> GetFieldDeserializers() return new Dictionary> { { "created_at", n => { CreatedAt = n.GetDateTimeOffsetValue(); } }, + { "dismissal_approved_by", n => { DismissalApprovedBy = n.GetObjectValue(global::GitHub.Models.NullableSimpleUser.CreateFromDiscriminatorValue); } }, { "dismissed_at", n => { DismissedAt = n.GetDateTimeOffsetValue(); } }, { "dismissed_by", n => { DismissedBy = n.GetObjectValue(global::GitHub.Models.NullableSimpleUser.CreateFromDiscriminatorValue); } }, { "dismissed_comment", n => { DismissedComment = n.GetStringValue(); } }, @@ -141,6 +150,7 @@ public virtual IDictionary> GetFieldDeserializers() public virtual void Serialize(ISerializationWriter writer) { _ = writer ?? throw new ArgumentNullException(nameof(writer)); + writer.WriteObjectValue("dismissal_approved_by", DismissalApprovedBy); writer.WriteObjectValue("dismissed_by", DismissedBy); writer.WriteStringValue("dismissed_comment", DismissedComment); writer.WriteEnumValue("dismissed_reason", DismissedReason); diff --git a/src/GitHub/Models/CodeScanningOrganizationAlertItems.cs b/src/GitHub/Models/CodeScanningOrganizationAlertItems.cs index 7ea9dbff0..f83a06a38 100644 --- a/src/GitHub/Models/CodeScanningOrganizationAlertItems.cs +++ b/src/GitHub/Models/CodeScanningOrganizationAlertItems.cs @@ -16,6 +16,14 @@ public partial class CodeScanningOrganizationAlertItems : IAdditionalDataHolder, public IDictionary AdditionalData { get; set; } /// The time that the alert was created in ISO 8601 format: `YYYY-MM-DDTHH:MM:SSZ`. public DateTimeOffset? CreatedAt { get; private set; } + /// A GitHub user. +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + public global::GitHub.Models.NullableSimpleUser? DismissalApprovedBy { get; set; } +#nullable restore +#else + public global::GitHub.Models.NullableSimpleUser DismissalApprovedBy { get; set; } +#endif /// The time that the alert was dismissed in ISO 8601 format: `YYYY-MM-DDTHH:MM:SSZ`. public DateTimeOffset? DismissedAt { get; private set; } /// A GitHub user. @@ -126,6 +134,7 @@ public virtual IDictionary> GetFieldDeserializers() return new Dictionary> { { "created_at", n => { CreatedAt = n.GetDateTimeOffsetValue(); } }, + { "dismissal_approved_by", n => { DismissalApprovedBy = n.GetObjectValue(global::GitHub.Models.NullableSimpleUser.CreateFromDiscriminatorValue); } }, { "dismissed_at", n => { DismissedAt = n.GetDateTimeOffsetValue(); } }, { "dismissed_by", n => { DismissedBy = n.GetObjectValue(global::GitHub.Models.NullableSimpleUser.CreateFromDiscriminatorValue); } }, { "dismissed_comment", n => { DismissedComment = n.GetStringValue(); } }, @@ -150,6 +159,7 @@ public virtual IDictionary> GetFieldDeserializers() public virtual void Serialize(ISerializationWriter writer) { _ = writer ?? throw new ArgumentNullException(nameof(writer)); + writer.WriteObjectValue("dismissal_approved_by", DismissalApprovedBy); writer.WriteObjectValue("dismissed_by", DismissedBy); writer.WriteStringValue("dismissed_comment", DismissedComment); writer.WriteEnumValue("dismissed_reason", DismissedReason); diff --git a/src/GitHub/Scim/V2/Enterprises/Item/Groups/GroupsRequestBuilder.cs b/src/GitHub/Scim/V2/Enterprises/Item/Groups/GroupsRequestBuilder.cs index b61cee529..6b5e1a6cf 100644 --- a/src/GitHub/Scim/V2/Enterprises/Item/Groups/GroupsRequestBuilder.cs +++ b/src/GitHub/Scim/V2/Enterprises/Item/Groups/GroupsRequestBuilder.cs @@ -173,7 +173,7 @@ public partial class GroupsRequestBuilderGetQueryParameters [QueryParameter("excludedAttributes")] public string ExcludedAttributes { get; set; } #endif - /// If specified, only results that match the specified filter will be returned. Multiple filters are not supported. Possible filters are `externalId`, `id`, and `displayName`. For example, `?filter='externalId eq "9138790-10932-109120392-12321"'`. + /// If specified, only results that match the specified filter will be returned. Multiple filters are not supported. Possible filters are `externalId`, `id`, and `displayName`. For example, `?filter=externalId eq "9138790-10932-109120392-12321"`. #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable [QueryParameter("filter")] diff --git a/src/GitHub/Scim/V2/Enterprises/Item/Users/UsersRequestBuilder.cs b/src/GitHub/Scim/V2/Enterprises/Item/Users/UsersRequestBuilder.cs index 04ad0e13f..44c887900 100644 --- a/src/GitHub/Scim/V2/Enterprises/Item/Users/UsersRequestBuilder.cs +++ b/src/GitHub/Scim/V2/Enterprises/Item/Users/UsersRequestBuilder.cs @@ -163,7 +163,7 @@ public partial class UsersRequestBuilderGetQueryParameters /// Used for pagination: the number of results to return per page. [QueryParameter("count")] public int? Count { get; set; } - /// If specified, only results that match the specified filter will be returned. Multiple filters are not supported. Possible filters are `userName`, `externalId`, `id`, and `displayName`. For example, `?filter='externalId eq "9138790-10932-109120392-12321"'`. + /// If specified, only results that match the specified filter will be returned. Multiple filters are not supported. Possible filters are `userName`, `externalId`, `id`, and `displayName`. For example, `?filter=externalId eq "9138790-10932-109120392-12321"`. #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable [QueryParameter("filter")] diff --git a/src/GitHub/kiota-lock.json b/src/GitHub/kiota-lock.json index fe3d32b77..424b2ce9b 100644 --- a/src/GitHub/kiota-lock.json +++ b/src/GitHub/kiota-lock.json @@ -1,5 +1,5 @@ { - "descriptionHash": "94064940D156935BA3C0C2F86EC43BD9FA7EBC5CB917FD3DE8721DCBCEAFC3DA9FF3BD3F0ABEE2E824278C3282E8EBB879FA1BE9C4090191E9766A5E5A2BF24E", + "descriptionHash": "82FC38F2C714C469BF10E83EB7E840A9E35C06D0DB1A2E743AF58C44FB951AA930AB45BAAE5D35D5977F841E75278F0C9DE31D2F604560C6E4E19D0FFFF82839", "descriptionLocation": "../../../../../schemas/ghes-3.14.json", "lockFileVersion": "1.0.0", "kiotaVersion": "1.19.0", From e289558142f4dd5a11454697e1ba9bcbe6a075de Mon Sep 17 00:00:00 2001 From: Octokit Bot Date: Thu, 27 Feb 2025 00:32:10 +0000 Subject: [PATCH 16/21] New updates to generated code --- src/GitHub/Orgs/Item/WithOrgItemRequestBuilder.cs | 4 ++-- src/GitHub/kiota-lock.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/GitHub/Orgs/Item/WithOrgItemRequestBuilder.cs b/src/GitHub/Orgs/Item/WithOrgItemRequestBuilder.cs index 476b7ba2a..44355bf9b 100644 --- a/src/GitHub/Orgs/Item/WithOrgItemRequestBuilder.cs +++ b/src/GitHub/Orgs/Item/WithOrgItemRequestBuilder.cs @@ -277,7 +277,7 @@ public WithOrgItemRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) return await RequestAdapter.SendAsync(requestInfo, global::GitHub.Orgs.Item.WithOrgDeleteResponse.CreateFromDiscriminatorValue, errorMapping, cancellationToken).ConfigureAwait(false); } /// - /// Gets information about an organization.When the value of `two_factor_requirement_enabled` is `true`, the organization requires all members, billing managers, and outside collaborators to enable [two-factor authentication](https://docs.github.com/enterprise-server@3.14/articles/securing-your-account-with-two-factor-authentication-2fa/).To see the full details about an organization, the authenticated user must be an organization owner.OAuth app tokens and personal access tokens (classic) need the `admin:org` scope to see the full details about an organization.To see information about an organization's GitHub Enterprise Server plan, GitHub Apps need the `Organization plan` permission. + /// Gets information about an organization.When the value of `two_factor_requirement_enabled` is `true`, the organization requires all members, billing managers, outside collaborators, guest collaborators, repository collaborators, or everyone with access to any repository within the organization to enable [two-factor authentication](https://docs.github.com/enterprise-server@3.14/articles/securing-your-account-with-two-factor-authentication-2fa/).To see the full details about an organization, the authenticated user must be an organization owner.OAuth app tokens and personal access tokens (classic) need the `admin:org` scope to see the full details about an organization.To see information about an organization's GitHub Enterprise Server plan, GitHub Apps need the `Organization plan` permission. /// API method documentation /// /// A @@ -346,7 +346,7 @@ public RequestInformation ToDeleteRequestInformation(Action - /// Gets information about an organization.When the value of `two_factor_requirement_enabled` is `true`, the organization requires all members, billing managers, and outside collaborators to enable [two-factor authentication](https://docs.github.com/enterprise-server@3.14/articles/securing-your-account-with-two-factor-authentication-2fa/).To see the full details about an organization, the authenticated user must be an organization owner.OAuth app tokens and personal access tokens (classic) need the `admin:org` scope to see the full details about an organization.To see information about an organization's GitHub Enterprise Server plan, GitHub Apps need the `Organization plan` permission. + /// Gets information about an organization.When the value of `two_factor_requirement_enabled` is `true`, the organization requires all members, billing managers, outside collaborators, guest collaborators, repository collaborators, or everyone with access to any repository within the organization to enable [two-factor authentication](https://docs.github.com/enterprise-server@3.14/articles/securing-your-account-with-two-factor-authentication-2fa/).To see the full details about an organization, the authenticated user must be an organization owner.OAuth app tokens and personal access tokens (classic) need the `admin:org` scope to see the full details about an organization.To see information about an organization's GitHub Enterprise Server plan, GitHub Apps need the `Organization plan` permission. /// /// A /// Configuration for the request such as headers, query parameters, and middleware options. diff --git a/src/GitHub/kiota-lock.json b/src/GitHub/kiota-lock.json index 424b2ce9b..42e4c78e2 100644 --- a/src/GitHub/kiota-lock.json +++ b/src/GitHub/kiota-lock.json @@ -1,5 +1,5 @@ { - "descriptionHash": "82FC38F2C714C469BF10E83EB7E840A9E35C06D0DB1A2E743AF58C44FB951AA930AB45BAAE5D35D5977F841E75278F0C9DE31D2F604560C6E4E19D0FFFF82839", + "descriptionHash": "954CB59C03D20377C51D82B85C60038ED051C625247CB0E85F5A3CDA2D57EA4430ABDE059C2361C369755D568ECB3BED0A60DCBC45F9F791693FB4D8D0AA060D", "descriptionLocation": "../../../../../schemas/ghes-3.14.json", "lockFileVersion": "1.0.0", "kiotaVersion": "1.19.0", From 0c123f9ca130f56f0936ad8af3d16a45daf838e8 Mon Sep 17 00:00:00 2001 From: Octokit Bot Date: Fri, 28 Feb 2025 00:32:04 +0000 Subject: [PATCH 17/21] New updates to generated code --- src/GitHub/Models/RepositoryRulePullRequest_parameters.cs | 2 +- src/GitHub/kiota-lock.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/GitHub/Models/RepositoryRulePullRequest_parameters.cs b/src/GitHub/Models/RepositoryRulePullRequest_parameters.cs index 679b59017..026d7e9d5 100644 --- a/src/GitHub/Models/RepositoryRulePullRequest_parameters.cs +++ b/src/GitHub/Models/RepositoryRulePullRequest_parameters.cs @@ -14,7 +14,7 @@ public partial class RepositoryRulePullRequest_parameters : IAdditionalDataHolde { /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. public IDictionary AdditionalData { get; set; } - /// When merging pull requests, you can allow any combination of merge commits, squashing, or rebasing. At least one option must be enabled. + /// Array of allowed merge methods. Allowed values include `merge`, `squash`, and `rebase`. At least one option must be enabled. #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable public List? AllowedMergeMethods { get; set; } diff --git a/src/GitHub/kiota-lock.json b/src/GitHub/kiota-lock.json index 42e4c78e2..14b349772 100644 --- a/src/GitHub/kiota-lock.json +++ b/src/GitHub/kiota-lock.json @@ -1,5 +1,5 @@ { - "descriptionHash": "954CB59C03D20377C51D82B85C60038ED051C625247CB0E85F5A3CDA2D57EA4430ABDE059C2361C369755D568ECB3BED0A60DCBC45F9F791693FB4D8D0AA060D", + "descriptionHash": "EDCE4B2847FEBA6D77B9EB303A8D892AE39F55C27F9F6FBE317DBD1DD57661D9F4B37A5723A81311802AA7A6B51E6147EEC2CC911C7883BCA7D4EAB4B31790EC", "descriptionLocation": "../../../../../schemas/ghes-3.14.json", "lockFileVersion": "1.0.0", "kiotaVersion": "1.19.0", From 3c17bc8ffdaf1195f344521beb2847a0a530630c Mon Sep 17 00:00:00 2001 From: Octokit Bot Date: Sat, 1 Mar 2025 00:35:23 +0000 Subject: [PATCH 18/21] New updates to generated code --- src/GitHub/Search/Issues/IssuesRequestBuilder.cs | 14 ++++++++++++-- src/GitHub/Zen/ZenRequestBuilder.cs | 2 +- src/GitHub/kiota-lock.json | 2 +- 3 files changed, 14 insertions(+), 4 deletions(-) diff --git a/src/GitHub/Search/Issues/IssuesRequestBuilder.cs b/src/GitHub/Search/Issues/IssuesRequestBuilder.cs index 9fc6d65bb..5e4be13b7 100644 --- a/src/GitHub/Search/Issues/IssuesRequestBuilder.cs +++ b/src/GitHub/Search/Issues/IssuesRequestBuilder.cs @@ -22,7 +22,7 @@ public partial class IssuesRequestBuilder : BaseRequestBuilder /// /// Path parameters for the request /// The request adapter to use to execute the requests. - public IssuesRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/search/issues?q={q}{&order*,page*,per_page*,sort*}", pathParameters) + public IssuesRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/search/issues?q={q}{&advanced_search*,order*,page*,per_page*,sort*}", pathParameters) { } /// @@ -30,7 +30,7 @@ public IssuesRequestBuilder(Dictionary pathParameters, IRequestA /// /// The raw URL to use for the request builder. /// The request adapter to use to execute the requests. - public IssuesRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/search/issues?q={q}{&order*,page*,per_page*,sort*}", rawUrl) + public IssuesRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/search/issues?q={q}{&advanced_search*,order*,page*,per_page*,sort*}", rawUrl) { } /// @@ -95,6 +95,16 @@ public RequestInformation ToGetRequestInformation(ActionSet to `true` to use advanced search.Example: `http://api.github.com/search/issues?q={query}&advanced_search=true` +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("advanced_search")] + public string? AdvancedSearch { get; set; } +#nullable restore +#else + [QueryParameter("advanced_search")] + public string AdvancedSearch { get; set; } +#endif /// Determines whether the first search result returned is the highest number of matches (`desc`) or lowest number of matches (`asc`). This parameter is ignored unless you provide `sort`. [QueryParameter("order")] public global::GitHub.Search.Issues.GetOrderQueryParameterType? Order { get; set; } diff --git a/src/GitHub/Zen/ZenRequestBuilder.cs b/src/GitHub/Zen/ZenRequestBuilder.cs index f86733804..c39854599 100644 --- a/src/GitHub/Zen/ZenRequestBuilder.cs +++ b/src/GitHub/Zen/ZenRequestBuilder.cs @@ -67,7 +67,7 @@ public RequestInformation ToGetRequestInformation(Action diff --git a/src/GitHub/kiota-lock.json b/src/GitHub/kiota-lock.json index 14b349772..00fe7721f 100644 --- a/src/GitHub/kiota-lock.json +++ b/src/GitHub/kiota-lock.json @@ -1,5 +1,5 @@ { - "descriptionHash": "EDCE4B2847FEBA6D77B9EB303A8D892AE39F55C27F9F6FBE317DBD1DD57661D9F4B37A5723A81311802AA7A6B51E6147EEC2CC911C7883BCA7D4EAB4B31790EC", + "descriptionHash": "37A226F67D7687299E5E6152D422A338BCE5E7C4AF59D11A5398344E5056349101F3D5201F2F67A0F506EF443F0D114CE5E7A12FFCE236028F467CE2322219D8", "descriptionLocation": "../../../../../schemas/ghes-3.14.json", "lockFileVersion": "1.0.0", "kiotaVersion": "1.19.0", From 681d6835feea8fb76186f0d3c4d4e42375f492a2 Mon Sep 17 00:00:00 2001 From: Octokit Bot Date: Tue, 4 Mar 2025 00:32:22 +0000 Subject: [PATCH 19/21] New updates to generated code --- src/GitHub/kiota-lock.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/GitHub/kiota-lock.json b/src/GitHub/kiota-lock.json index 00fe7721f..332a496d0 100644 --- a/src/GitHub/kiota-lock.json +++ b/src/GitHub/kiota-lock.json @@ -1,5 +1,5 @@ { - "descriptionHash": "37A226F67D7687299E5E6152D422A338BCE5E7C4AF59D11A5398344E5056349101F3D5201F2F67A0F506EF443F0D114CE5E7A12FFCE236028F467CE2322219D8", + "descriptionHash": "DD30EA24FA68FF8B77874CD272ADFC5F2BEDE40FDA5ABBE0E747992D474FAD770B88F82B986FEAA625E084EA4B65B78D75CBE8EBF7B103FC389892A42B9BF775", "descriptionLocation": "../../../../../schemas/ghes-3.14.json", "lockFileVersion": "1.0.0", "kiotaVersion": "1.19.0", From d0c9aa1bccd3194690f4e682c80a9d0d8f853d2c Mon Sep 17 00:00:00 2001 From: Octokit Bot Date: Sat, 8 Mar 2025 00:26:45 +0000 Subject: [PATCH 20/21] New updates to generated code --- .../Alerts/Item/WithAlert_numberItemRequestBuilder.cs | 2 ++ .../Alerts/Item/WithAlert_numberPatchRequestBody.cs | 4 ++++ src/GitHub/kiota-lock.json | 2 +- 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/GitHub/Repos/Item/Item/CodeScanning/Alerts/Item/WithAlert_numberItemRequestBuilder.cs b/src/GitHub/Repos/Item/Item/CodeScanning/Alerts/Item/WithAlert_numberItemRequestBuilder.cs index 4133d2456..de63f4d4e 100644 --- a/src/GitHub/Repos/Item/Item/CodeScanning/Alerts/Item/WithAlert_numberItemRequestBuilder.cs +++ b/src/GitHub/Repos/Item/Item/CodeScanning/Alerts/Item/WithAlert_numberItemRequestBuilder.cs @@ -75,6 +75,7 @@ public WithAlert_numberItemRequestBuilder(string rawUrl, IRequestAdapter request /// The request body /// Cancellation token to use when cancelling requests /// Configuration for the request such as headers, query parameters, and middleware options. + /// When receiving a 400 status code /// When receiving a 403 status code /// When receiving a 404 status code /// When receiving a 503 status code @@ -91,6 +92,7 @@ public WithAlert_numberItemRequestBuilder(string rawUrl, IRequestAdapter request var requestInfo = ToPatchRequestInformation(body, requestConfiguration); var errorMapping = new Dictionary> { + { "400", global::GitHub.Models.BasicError.CreateFromDiscriminatorValue }, { "403", global::GitHub.Models.BasicError.CreateFromDiscriminatorValue }, { "404", global::GitHub.Models.BasicError.CreateFromDiscriminatorValue }, { "503", global::GitHub.Models.CodeScanningAlert503Error.CreateFromDiscriminatorValue }, diff --git a/src/GitHub/Repos/Item/Item/CodeScanning/Alerts/Item/WithAlert_numberPatchRequestBody.cs b/src/GitHub/Repos/Item/Item/CodeScanning/Alerts/Item/WithAlert_numberPatchRequestBody.cs index a23ff2874..77b156a26 100644 --- a/src/GitHub/Repos/Item/Item/CodeScanning/Alerts/Item/WithAlert_numberPatchRequestBody.cs +++ b/src/GitHub/Repos/Item/Item/CodeScanning/Alerts/Item/WithAlert_numberPatchRequestBody.cs @@ -15,6 +15,8 @@ public partial class WithAlert_numberPatchRequestBody : IAdditionalDataHolder, I { /// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. public IDictionary AdditionalData { get; set; } + /// If `true`, attempt to create an alert dismissal request. + public bool? CreateRequest { get; set; } /// The dismissal comment associated with the dismissal of the alert. #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable @@ -52,6 +54,7 @@ public virtual IDictionary> GetFieldDeserializers() { return new Dictionary> { + { "create_request", n => { CreateRequest = n.GetBoolValue(); } }, { "dismissed_comment", n => { DismissedComment = n.GetStringValue(); } }, { "dismissed_reason", n => { DismissedReason = n.GetEnumValue(); } }, { "state", n => { State = n.GetEnumValue(); } }, @@ -64,6 +67,7 @@ public virtual IDictionary> GetFieldDeserializers() public virtual void Serialize(ISerializationWriter writer) { _ = writer ?? throw new ArgumentNullException(nameof(writer)); + writer.WriteBoolValue("create_request", CreateRequest); writer.WriteStringValue("dismissed_comment", DismissedComment); writer.WriteEnumValue("dismissed_reason", DismissedReason); writer.WriteEnumValue("state", State); diff --git a/src/GitHub/kiota-lock.json b/src/GitHub/kiota-lock.json index 332a496d0..8f6ba41a1 100644 --- a/src/GitHub/kiota-lock.json +++ b/src/GitHub/kiota-lock.json @@ -1,5 +1,5 @@ { - "descriptionHash": "DD30EA24FA68FF8B77874CD272ADFC5F2BEDE40FDA5ABBE0E747992D474FAD770B88F82B986FEAA625E084EA4B65B78D75CBE8EBF7B103FC389892A42B9BF775", + "descriptionHash": "DAFA79F781B4EE8FCBD6B0BFF61BEE508B14151C486056F46A84FA4A29CAB07EEC5EDBA82654C8543E286B6762174C338F9979D27842F0F1988C3CB898C079A4", "descriptionLocation": "../../../../../schemas/ghes-3.14.json", "lockFileVersion": "1.0.0", "kiotaVersion": "1.19.0", From e68c708a323e75bb301f2d3d46541e79cb1906b8 Mon Sep 17 00:00:00 2001 From: Octokit Bot Date: Thu, 13 Mar 2025 00:33:09 +0000 Subject: [PATCH 21/21] New updates to generated code --- src/GitHub/Models/HookDeliveryItem.cs | 18 +++++++++--------- ...ersonalAccessTokenRequestsRequestBuilder.cs | 14 ++++++++++++-- .../PersonalAccessTokensRequestBuilder.cs | 14 ++++++++++++-- ...eployment_protection_rulesRequestBuilder.cs | 4 ++-- src/GitHub/kiota-lock.json | 2 +- 5 files changed, 36 insertions(+), 16 deletions(-) diff --git a/src/GitHub/Models/HookDeliveryItem.cs b/src/GitHub/Models/HookDeliveryItem.cs index 8aaaa2b22..8f2a14bc8 100644 --- a/src/GitHub/Models/HookDeliveryItem.cs +++ b/src/GitHub/Models/HookDeliveryItem.cs @@ -44,13 +44,13 @@ public partial class HookDeliveryItem : IAdditionalDataHolder, IParsable public string Guid { get; set; } #endif /// Unique identifier of the webhook delivery. - public int? Id { get; set; } + public long? Id { get; set; } /// The id of the GitHub App installation associated with this event. - public int? InstallationId { get; set; } + public long? InstallationId { get; set; } /// Whether the webhook delivery is a redelivery. public bool? Redelivery { get; set; } /// The id of the repository associated with this event. - public int? RepositoryId { get; set; } + public long? RepositoryId { get; set; } /// Describes the response returned after attempting the delivery. #if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER #nullable enable @@ -93,10 +93,10 @@ public virtual IDictionary> GetFieldDeserializers() { "duration", n => { Duration = n.GetDoubleValue(); } }, { "event", n => { Event = n.GetStringValue(); } }, { "guid", n => { Guid = n.GetStringValue(); } }, - { "id", n => { Id = n.GetIntValue(); } }, - { "installation_id", n => { InstallationId = n.GetIntValue(); } }, + { "id", n => { Id = n.GetLongValue(); } }, + { "installation_id", n => { InstallationId = n.GetLongValue(); } }, { "redelivery", n => { Redelivery = n.GetBoolValue(); } }, - { "repository_id", n => { RepositoryId = n.GetIntValue(); } }, + { "repository_id", n => { RepositoryId = n.GetLongValue(); } }, { "status", n => { Status = n.GetStringValue(); } }, { "status_code", n => { StatusCode = n.GetIntValue(); } }, { "throttled_at", n => { ThrottledAt = n.GetDateTimeOffsetValue(); } }, @@ -114,10 +114,10 @@ public virtual void Serialize(ISerializationWriter writer) writer.WriteDoubleValue("duration", Duration); writer.WriteStringValue("event", Event); writer.WriteStringValue("guid", Guid); - writer.WriteIntValue("id", Id); - writer.WriteIntValue("installation_id", InstallationId); + writer.WriteLongValue("id", Id); + writer.WriteLongValue("installation_id", InstallationId); writer.WriteBoolValue("redelivery", Redelivery); - writer.WriteIntValue("repository_id", RepositoryId); + writer.WriteLongValue("repository_id", RepositoryId); writer.WriteStringValue("status", Status); writer.WriteIntValue("status_code", StatusCode); writer.WriteDateTimeOffsetValue("throttled_at", ThrottledAt); diff --git a/src/GitHub/Orgs/Item/PersonalAccessTokenRequests/PersonalAccessTokenRequestsRequestBuilder.cs b/src/GitHub/Orgs/Item/PersonalAccessTokenRequests/PersonalAccessTokenRequestsRequestBuilder.cs index e3028f8a7..5d6350dbc 100644 --- a/src/GitHub/Orgs/Item/PersonalAccessTokenRequests/PersonalAccessTokenRequestsRequestBuilder.cs +++ b/src/GitHub/Orgs/Item/PersonalAccessTokenRequests/PersonalAccessTokenRequestsRequestBuilder.cs @@ -35,7 +35,7 @@ public partial class PersonalAccessTokenRequestsRequestBuilder : BaseRequestBuil /// /// Path parameters for the request /// The request adapter to use to execute the requests. - public PersonalAccessTokenRequestsRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/orgs/{org}/personal-access-token-requests{?direction*,last_used_after*,last_used_before*,owner*,page*,per_page*,permission*,repository*,sort*}", pathParameters) + public PersonalAccessTokenRequestsRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/orgs/{org}/personal-access-token-requests{?direction*,last_used_after*,last_used_before*,owner*,page*,per_page*,permission*,repository*,sort*,token_id*}", pathParameters) { } /// @@ -43,7 +43,7 @@ public PersonalAccessTokenRequestsRequestBuilder(Dictionary path /// /// The raw URL to use for the request builder. /// The request adapter to use to execute the requests. - public PersonalAccessTokenRequestsRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/orgs/{org}/personal-access-token-requests{?direction*,last_used_after*,last_used_before*,owner*,page*,per_page*,permission*,repository*,sort*}", rawUrl) + public PersonalAccessTokenRequestsRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/orgs/{org}/personal-access-token-requests{?direction*,last_used_after*,last_used_before*,owner*,page*,per_page*,permission*,repository*,sort*,token_id*}", rawUrl) { } /// @@ -213,6 +213,16 @@ public partial class PersonalAccessTokenRequestsRequestBuilderGetQueryParameters /// The property by which to sort the results. [QueryParameter("sort")] public global::GitHub.Orgs.Item.PersonalAccessTokenRequests.GetSortQueryParameterType? Sort { get; set; } + /// The ID of the token +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("token_id")] + public string[]? TokenId { get; set; } +#nullable restore +#else + [QueryParameter("token_id")] + public string[] TokenId { get; set; } +#endif } } } diff --git a/src/GitHub/Orgs/Item/PersonalAccessTokens/PersonalAccessTokensRequestBuilder.cs b/src/GitHub/Orgs/Item/PersonalAccessTokens/PersonalAccessTokensRequestBuilder.cs index aa83198ee..8dc8a1ab8 100644 --- a/src/GitHub/Orgs/Item/PersonalAccessTokens/PersonalAccessTokensRequestBuilder.cs +++ b/src/GitHub/Orgs/Item/PersonalAccessTokens/PersonalAccessTokensRequestBuilder.cs @@ -35,7 +35,7 @@ public partial class PersonalAccessTokensRequestBuilder : BaseRequestBuilder /// /// Path parameters for the request /// The request adapter to use to execute the requests. - public PersonalAccessTokensRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/orgs/{org}/personal-access-tokens{?direction*,last_used_after*,last_used_before*,owner*,page*,per_page*,permission*,repository*,sort*}", pathParameters) + public PersonalAccessTokensRequestBuilder(Dictionary pathParameters, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/orgs/{org}/personal-access-tokens{?direction*,last_used_after*,last_used_before*,owner*,page*,per_page*,permission*,repository*,sort*,token_id*}", pathParameters) { } /// @@ -43,7 +43,7 @@ public PersonalAccessTokensRequestBuilder(Dictionary pathParamet /// /// The raw URL to use for the request builder. /// The request adapter to use to execute the requests. - public PersonalAccessTokensRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/orgs/{org}/personal-access-tokens{?direction*,last_used_after*,last_used_before*,owner*,page*,per_page*,permission*,repository*,sort*}", rawUrl) + public PersonalAccessTokensRequestBuilder(string rawUrl, IRequestAdapter requestAdapter) : base(requestAdapter, "{+baseurl}/orgs/{org}/personal-access-tokens{?direction*,last_used_after*,last_used_before*,owner*,page*,per_page*,permission*,repository*,sort*,token_id*}", rawUrl) { } /// @@ -213,6 +213,16 @@ public partial class PersonalAccessTokensRequestBuilderGetQueryParameters /// The property by which to sort the results. [QueryParameter("sort")] public global::GitHub.Orgs.Item.PersonalAccessTokens.GetSortQueryParameterType? Sort { get; set; } + /// The ID of the token +#if NETSTANDARD2_1_OR_GREATER || NETCOREAPP3_1_OR_GREATER +#nullable enable + [QueryParameter("token_id")] + public string[]? TokenId { get; set; } +#nullable restore +#else + [QueryParameter("token_id")] + public string[] TokenId { get; set; } +#endif } } } diff --git a/src/GitHub/Repos/Item/Item/Environments/Item/Deployment_protection_rules/Deployment_protection_rulesRequestBuilder.cs b/src/GitHub/Repos/Item/Item/Environments/Item/Deployment_protection_rules/Deployment_protection_rulesRequestBuilder.cs index 07d9b39c6..e7a427734 100644 --- a/src/GitHub/Repos/Item/Item/Environments/Item/Deployment_protection_rules/Deployment_protection_rulesRequestBuilder.cs +++ b/src/GitHub/Repos/Item/Item/Environments/Item/Deployment_protection_rules/Deployment_protection_rulesRequestBuilder.cs @@ -72,7 +72,7 @@ public Deployment_protection_rulesRequestBuilder(string rawUrl, IRequestAdapter return await RequestAdapter.SendAsync(requestInfo, global::GitHub.Repos.Item.Item.Environments.Item.Deployment_protection_rules.Deployment_protection_rulesGetResponse.CreateFromDiscriminatorValue, default, cancellationToken).ConfigureAwait(false); } /// - /// Enable a custom deployment protection rule for an environment.The authenticated user must have admin or owner permissions to the repository to use this endpoint.For more information about the app that is providing this custom deployment rule, see the [documentation for the `GET /apps/{app_slug}` endpoint](https://docs.github.com/enterprise-server@3.14/rest/apps/apps#get-an-app).OAuth app tokens and personal access tokens (classic) need the `repo` scope to use this endpoint. + /// Enable a custom deployment protection rule for an environment.The authenticated user must have admin or owner permissions to the repository to use this endpoint.For more information about the app that is providing this custom deployment rule, see the [documentation for the `GET /apps/{app_slug}` endpoint](https://docs.github.com/enterprise-server@3.14/rest/apps/apps#get-an-app), as well as the [guide to creating custom deployment protection rules](https://docs.github.com/enterprise-server@3.14/actions/managing-workflow-runs-and-deployments/managing-deployments/creating-custom-deployment-protection-rules).OAuth app tokens and personal access tokens (classic) need the `repo` scope to use this endpoint. /// API method documentation /// /// A @@ -112,7 +112,7 @@ public RequestInformation ToGetRequestInformation(Action - /// Enable a custom deployment protection rule for an environment.The authenticated user must have admin or owner permissions to the repository to use this endpoint.For more information about the app that is providing this custom deployment rule, see the [documentation for the `GET /apps/{app_slug}` endpoint](https://docs.github.com/enterprise-server@3.14/rest/apps/apps#get-an-app).OAuth app tokens and personal access tokens (classic) need the `repo` scope to use this endpoint. + /// Enable a custom deployment protection rule for an environment.The authenticated user must have admin or owner permissions to the repository to use this endpoint.For more information about the app that is providing this custom deployment rule, see the [documentation for the `GET /apps/{app_slug}` endpoint](https://docs.github.com/enterprise-server@3.14/rest/apps/apps#get-an-app), as well as the [guide to creating custom deployment protection rules](https://docs.github.com/enterprise-server@3.14/actions/managing-workflow-runs-and-deployments/managing-deployments/creating-custom-deployment-protection-rules).OAuth app tokens and personal access tokens (classic) need the `repo` scope to use this endpoint. /// /// A /// The request body diff --git a/src/GitHub/kiota-lock.json b/src/GitHub/kiota-lock.json index 8f6ba41a1..51bbda09a 100644 --- a/src/GitHub/kiota-lock.json +++ b/src/GitHub/kiota-lock.json @@ -1,5 +1,5 @@ { - "descriptionHash": "DAFA79F781B4EE8FCBD6B0BFF61BEE508B14151C486056F46A84FA4A29CAB07EEC5EDBA82654C8543E286B6762174C338F9979D27842F0F1988C3CB898C079A4", + "descriptionHash": "CEC7AD55BE85F766CCC12943636A2F5B59E985D3731321C5027900B4D5BC269775F3227FA18705E4146814B9CDBCE9B4E95D09D795E2D894CBFB07DD24F787CF", "descriptionLocation": "../../../../../schemas/ghes-3.14.json", "lockFileVersion": "1.0.0", "kiotaVersion": "1.19.0",