Skip to content

Commit f174be5

Browse files
HavenDVgithub-actions[bot]
andauthored
feat: Updated OpenAPI spec (#9)
Co-authored-by: github-actions[bot] <dependabot@bot.com>
1 parent 5fe8da1 commit f174be5

7 files changed

Lines changed: 14 additions & 36 deletions

src/libs/V0/Generated/V0.AllOf.2.g.cs

Lines changed: 6 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ namespace V0
66
/// <summary>
77
///
88
/// </summary>
9-
public readonly partial struct AllOf<[global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMembers(global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMemberTypes.PublicProperties)] T1, [global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMembers(global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMemberTypes.PublicProperties)] T2> : global::System.IEquatable<AllOf<T1, T2>>
9+
public readonly partial struct AllOf<T1, T2> : global::System.IEquatable<AllOf<T1, T2>>
1010
{
1111
/// <summary>
1212
///
@@ -105,42 +105,17 @@ Value1 as object
105105
Value2?.ToString()
106106
;
107107

108-
private static bool RequiresValue<[global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMembers(global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMemberTypes.PublicProperties)] TValue>() => RequirementCache<TValue>.Value;
109-
110-
private static bool DetermineRequiresValue([global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMembers(global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMemberTypes.PublicProperties)] global::System.Type type)
108+
private static bool RequiresValue<TValue>()
111109
{
110+
var type = typeof(TValue);
112111
if (global::System.Nullable.GetUnderlyingType(type) != null)
113112
{
114113
return false;
115114
}
116115

117-
if (type.IsValueType ||
118-
type == typeof(string) ||
119-
type.IsArray)
120-
{
121-
return true;
122-
}
123-
124-
foreach (var property in type.GetProperties(global::System.Reflection.BindingFlags.Instance | global::System.Reflection.BindingFlags.Public))
125-
{
126-
foreach (var attributeData in property.CustomAttributes)
127-
{
128-
var attributeTypeName = attributeData.AttributeType.FullName;
129-
if (attributeTypeName == "System.Text.Json.Serialization.JsonRequiredAttribute" ||
130-
attributeTypeName == "Newtonsoft.Json.JsonRequiredAttribute" ||
131-
attributeTypeName == "System.Runtime.CompilerServices.RequiredMemberAttribute")
132-
{
133-
return true;
134-
}
135-
}
136-
}
137-
138-
return false;
139-
}
140-
141-
private static class RequirementCache<[global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMembers(global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMemberTypes.PublicProperties)] TValue>
142-
{
143-
public static readonly bool Value = DetermineRequiresValue(typeof(TValue));
116+
return type.IsValueType ||
117+
type == typeof(string) ||
118+
type.IsArray;
144119
}
145120

146121

src/libs/V0/Generated/V0.JsonConverters.AllOf2.g.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
namespace V0.JsonConverters
44
{
55
/// <inheritdoc />
6-
public class AllOfJsonConverter<[global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMembers(global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMemberTypes.PublicProperties)] T1, [global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMembers(global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMemberTypes.PublicProperties)] T2> : global::System.Text.Json.Serialization.JsonConverter<global::V0.AllOf<T1, T2>>
6+
public class AllOfJsonConverter<T1, T2> : global::System.Text.Json.Serialization.JsonConverter<global::V0.AllOf<T1, T2>>
77
{
88
/// <inheritdoc />
99
public override global::V0.AllOf<T1, T2> Read(

src/libs/V0/Generated/V0.JsonConverters.AnyOf2.g.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
namespace V0.JsonConverters
44
{
55
/// <inheritdoc />
6-
public class AnyOfJsonConverter<[global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMembers(global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMemberTypes.PublicProperties)] T1, [global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMembers(global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMemberTypes.PublicProperties)] T2> : global::System.Text.Json.Serialization.JsonConverter<global::V0.AnyOf<T1, T2>>
6+
public class AnyOfJsonConverter<T1, T2> : global::System.Text.Json.Serialization.JsonConverter<global::V0.AnyOf<T1, T2>>
77
{
88
/// <inheritdoc />
99
public override global::V0.AnyOf<T1, T2> Read(

src/libs/V0/Generated/V0.JsonConverters.AnyOf3.g.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
namespace V0.JsonConverters
44
{
55
/// <inheritdoc />
6-
public class AnyOfJsonConverter<[global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMembers(global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMemberTypes.PublicProperties)] T1, [global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMembers(global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMemberTypes.PublicProperties)] T2, [global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMembers(global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMemberTypes.PublicProperties)] T3> : global::System.Text.Json.Serialization.JsonConverter<global::V0.AnyOf<T1, T2, T3>>
6+
public class AnyOfJsonConverter<T1, T2, T3> : global::System.Text.Json.Serialization.JsonConverter<global::V0.AnyOf<T1, T2, T3>>
77
{
88
/// <inheritdoc />
99
public override global::V0.AnyOf<T1, T2, T3> Read(

src/libs/V0/Generated/V0.JsonConverters.AnyOf4.g.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
namespace V0.JsonConverters
44
{
55
/// <inheritdoc />
6-
public class AnyOfJsonConverter<[global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMembers(global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMemberTypes.PublicProperties)] T1, [global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMembers(global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMemberTypes.PublicProperties)] T2, [global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMembers(global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMemberTypes.PublicProperties)] T3, [global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMembers(global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMemberTypes.PublicProperties)] T4> : global::System.Text.Json.Serialization.JsonConverter<global::V0.AnyOf<T1, T2, T3, T4>>
6+
public class AnyOfJsonConverter<T1, T2, T3, T4> : global::System.Text.Json.Serialization.JsonConverter<global::V0.AnyOf<T1, T2, T3, T4>>
77
{
88
/// <inheritdoc />
99
public override global::V0.AnyOf<T1, T2, T3, T4> Read(

src/libs/V0/Generated/V0.JsonConverters.AnyOf5.g.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
namespace V0.JsonConverters
44
{
55
/// <inheritdoc />
6-
public class AnyOfJsonConverter<[global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMembers(global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMemberTypes.PublicProperties)] T1, [global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMembers(global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMemberTypes.PublicProperties)] T2, [global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMembers(global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMemberTypes.PublicProperties)] T3, [global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMembers(global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMemberTypes.PublicProperties)] T4, [global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMembers(global::System.Diagnostics.CodeAnalysis.DynamicallyAccessedMemberTypes.PublicProperties)] T5> : global::System.Text.Json.Serialization.JsonConverter<global::V0.AnyOf<T1, T2, T3, T4, T5>>
6+
public class AnyOfJsonConverter<T1, T2, T3, T4, T5> : global::System.Text.Json.Serialization.JsonConverter<global::V0.AnyOf<T1, T2, T3, T4, T5>>
77
{
88
/// <inheritdoc />
99
public override global::V0.AnyOf<T1, T2, T3, T4, T5> Read(

src/libs/V0/Generated/V0.JsonSerializerContext.g.cs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -653,6 +653,9 @@ namespace V0
653653
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::V0.McpServersUpdateResponseAuthType), TypeInfoPropertyName = "McpServersUpdateResponseAuthType2")]
654654
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::V0.McpServersUpdateResponseScope), TypeInfoPropertyName = "McpServersUpdateResponseScope2")]
655655
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::V0.McpServersDeleteResponse))]
656+
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::V0.AllOf<global::V0.ChatsInitRequest2, global::V0.AnyOf<global::V0.ChatsInitRequestVariant1, global::V0.ChatsInitRequestVariant22, global::V0.ChatsInitRequestVariant3, global::V0.ChatsInitRequestVariant4, global::V0.ChatsInitRequestVariant5>?>?), TypeInfoPropertyName = "ChatsInitRequestVariant5_37d682f35fad2e9d")]
657+
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::V0.AnyOf<global::V0.ChatsInitRequestVariant1, global::V0.ChatsInitRequestVariant22, global::V0.ChatsInitRequestVariant3, global::V0.ChatsInitRequestVariant4, global::V0.ChatsInitRequestVariant5>?), TypeInfoPropertyName = "ChatsInitRequestVariant5_81f724b881d7ba5b")]
658+
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::V0.AnyOf<global::V0.ChatsResolveTaskRequestTaskVariant1, global::V0.ChatsResolveTaskRequestTaskVariant2, global::V0.ChatsResolveTaskRequestTaskVariant3, global::V0.ChatsResolveTaskRequestTaskVariant4>?), TypeInfoPropertyName = "ChatsResolveTaskRequestTaskVariant4_a1ad15825c1305f0")]
656659
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.List<global::V0.ChatDetailLatestVersionFile>))]
657660
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.List<global::V0.ChatDetailMessage>))]
658661
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.List<byte[]>))]

0 commit comments

Comments
 (0)