Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -691,6 +691,9 @@ namespace Speechify
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.IList<global::Speechify.TtsPutFlowRequestNodesItems>))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.IList<global::Speechify.TtsPutFlowRequestEdgesItems>))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.IList<global::Speechify.TtsPutFlowRequestVariablesItems>))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Speechify.TtsFlowValidationIssue))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Speechify.TtsFlowValidationError))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.IList<global::Speechify.TtsFlowValidationIssue>))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Speechify.TtsPublishFlowRequest))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Speechify.TtsRollbackFlowRequest))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Speechify.TtsListFlowVersionsResponse))]
Expand Down Expand Up @@ -822,6 +825,7 @@ namespace Speechify
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.List<global::Speechify.TtsPutFlowRequestNodesItems>))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.List<global::Speechify.TtsPutFlowRequestEdgesItems>))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.List<global::Speechify.TtsPutFlowRequestVariablesItems>))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.List<global::Speechify.TtsFlowValidationIssue>))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.List<global::Speechify.TtsFlowTemplate>))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.List<global::Speechify.TtsFlowGraphInputNodesItems>))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.List<global::Speechify.TtsFlowGraphInputEdgesItems>))]
Expand Down
182 changes: 99 additions & 83 deletions src/libs/Speechify/Generated/Speechify.JsonSerializerContextTypes.g.cs

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
#nullable enable

namespace Speechify
{
public sealed partial class TtsFlowValidationError
{
/// <summary>
/// Serializes the current instance to a JSON string using the provided JsonSerializerContext.
/// </summary>
public string ToJson(
global::System.Text.Json.Serialization.JsonSerializerContext jsonSerializerContext)
{
return global::System.Text.Json.JsonSerializer.Serialize(
this,
this.GetType(),
jsonSerializerContext);
}

/// <summary>
/// Serializes the current instance to a JSON string using the provided JsonSerializerOptions.
/// </summary>
#if NET8_0_OR_GREATER
[global::System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("JSON serialization and deserialization might require types that cannot be statically analyzed. Use the overload that takes a JsonTypeInfo or JsonSerializerContext, or make sure all of the required types are preserved.")]
[global::System.Diagnostics.CodeAnalysis.RequiresDynamicCode("JSON serialization and deserialization might require types that cannot be statically analyzed and might need runtime code generation. Use System.Text.Json source generation for native AOT applications.")]
#endif
public string ToJson(
global::System.Text.Json.JsonSerializerOptions? jsonSerializerOptions = null)
{
return global::System.Text.Json.JsonSerializer.Serialize(
this,
jsonSerializerOptions);
}

/// <summary>
/// Deserializes a JSON string using the provided JsonSerializerContext.
/// </summary>
public static global::Speechify.TtsFlowValidationError? FromJson(
string json,
global::System.Text.Json.Serialization.JsonSerializerContext jsonSerializerContext)
{
return global::System.Text.Json.JsonSerializer.Deserialize(
json,
typeof(global::Speechify.TtsFlowValidationError),
jsonSerializerContext) as global::Speechify.TtsFlowValidationError;
}

/// <summary>
/// Deserializes a JSON string using the provided JsonSerializerOptions.
/// </summary>
#if NET8_0_OR_GREATER
[global::System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("JSON serialization and deserialization might require types that cannot be statically analyzed. Use the overload that takes a JsonTypeInfo or JsonSerializerContext, or make sure all of the required types are preserved.")]
[global::System.Diagnostics.CodeAnalysis.RequiresDynamicCode("JSON serialization and deserialization might require types that cannot be statically analyzed and might need runtime code generation. Use System.Text.Json source generation for native AOT applications.")]
#endif
public static global::Speechify.TtsFlowValidationError? FromJson(
string json,
global::System.Text.Json.JsonSerializerOptions? jsonSerializerOptions = null)
{
return global::System.Text.Json.JsonSerializer.Deserialize<global::Speechify.TtsFlowValidationError>(
json,
jsonSerializerOptions);
}

/// <summary>
/// Deserializes a JSON stream using the provided JsonSerializerContext.
/// </summary>
public static async global::System.Threading.Tasks.ValueTask<global::Speechify.TtsFlowValidationError?> FromJsonStreamAsync(
global::System.IO.Stream jsonStream,
global::System.Text.Json.Serialization.JsonSerializerContext jsonSerializerContext)
{
return (await global::System.Text.Json.JsonSerializer.DeserializeAsync(
jsonStream,
typeof(global::Speechify.TtsFlowValidationError),
jsonSerializerContext).ConfigureAwait(false)) as global::Speechify.TtsFlowValidationError;
}

/// <summary>
/// Deserializes a JSON stream using the provided JsonSerializerOptions.
/// </summary>
#if NET8_0_OR_GREATER
[global::System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("JSON serialization and deserialization might require types that cannot be statically analyzed. Use the overload that takes a JsonTypeInfo or JsonSerializerContext, or make sure all of the required types are preserved.")]
[global::System.Diagnostics.CodeAnalysis.RequiresDynamicCode("JSON serialization and deserialization might require types that cannot be statically analyzed and might need runtime code generation. Use System.Text.Json source generation for native AOT applications.")]
#endif
public static global::System.Threading.Tasks.ValueTask<global::Speechify.TtsFlowValidationError?> FromJsonStreamAsync(
global::System.IO.Stream jsonStream,
global::System.Text.Json.JsonSerializerOptions? jsonSerializerOptions = null)
{
return global::System.Text.Json.JsonSerializer.DeserializeAsync<global::Speechify.TtsFlowValidationError?>(
jsonStream,
jsonSerializerOptions);
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@

#nullable enable

namespace Speechify
{
/// <summary>
/// 400 body for flow save / publish / template operations. The standard<br/>
/// `Error` envelope (so clients read `error.code` = `validation_failed`<br/>
/// and `request_id`) plus the per-issue `issues` array the flow editor<br/>
/// uses for node highlighting and the Validator-tab list. `issues` is<br/>
/// absent on a plain bad request (e.g. an undecodable body, code<br/>
/// `bad_request`).
/// </summary>
public sealed partial class TtsFlowValidationError
{
/// <summary>
///
/// </summary>
[global::System.Text.Json.Serialization.JsonPropertyName("error")]
[global::System.Text.Json.Serialization.JsonRequired]
public required global::Speechify.TtsErrorDetail Error { get; set; }

/// <summary>
///
/// </summary>
[global::System.Text.Json.Serialization.JsonPropertyName("request_id")]
public string? RequestId { get; set; }

/// <summary>
///
/// </summary>
[global::System.Text.Json.Serialization.JsonPropertyName("issues")]
public global::System.Collections.Generic.IList<global::Speechify.TtsFlowValidationIssue>? Issues { get; set; }

/// <summary>
/// Additional properties that are not explicitly defined in the schema
/// </summary>
[global::System.Text.Json.Serialization.JsonExtensionData]
public global::System.Collections.Generic.IDictionary<string, object> AdditionalProperties { get; set; } = new global::System.Collections.Generic.Dictionary<string, object>();

/// <summary>
/// Initializes a new instance of the <see cref="TtsFlowValidationError" /> class.
/// </summary>
/// <param name="error"></param>
/// <param name="requestId"></param>
/// <param name="issues"></param>
#if NET7_0_OR_GREATER
[global::System.Diagnostics.CodeAnalysis.SetsRequiredMembers]
#endif
public TtsFlowValidationError(
global::Speechify.TtsErrorDetail error,
string? requestId,
global::System.Collections.Generic.IList<global::Speechify.TtsFlowValidationIssue>? issues)
{
this.Error = error ?? throw new global::System.ArgumentNullException(nameof(error));
this.RequestId = requestId;
this.Issues = issues;
}

/// <summary>
/// Initializes a new instance of the <see cref="TtsFlowValidationError" /> class.
/// </summary>
public TtsFlowValidationError()
{
}

}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
#nullable enable

namespace Speechify
{
public sealed partial class TtsFlowValidationIssue
{
/// <summary>
/// Serializes the current instance to a JSON string using the provided JsonSerializerContext.
/// </summary>
public string ToJson(
global::System.Text.Json.Serialization.JsonSerializerContext jsonSerializerContext)
{
return global::System.Text.Json.JsonSerializer.Serialize(
this,
this.GetType(),
jsonSerializerContext);
}

/// <summary>
/// Serializes the current instance to a JSON string using the provided JsonSerializerOptions.
/// </summary>
#if NET8_0_OR_GREATER
[global::System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("JSON serialization and deserialization might require types that cannot be statically analyzed. Use the overload that takes a JsonTypeInfo or JsonSerializerContext, or make sure all of the required types are preserved.")]
[global::System.Diagnostics.CodeAnalysis.RequiresDynamicCode("JSON serialization and deserialization might require types that cannot be statically analyzed and might need runtime code generation. Use System.Text.Json source generation for native AOT applications.")]
#endif
public string ToJson(
global::System.Text.Json.JsonSerializerOptions? jsonSerializerOptions = null)
{
return global::System.Text.Json.JsonSerializer.Serialize(
this,
jsonSerializerOptions);
}

/// <summary>
/// Deserializes a JSON string using the provided JsonSerializerContext.
/// </summary>
public static global::Speechify.TtsFlowValidationIssue? FromJson(
string json,
global::System.Text.Json.Serialization.JsonSerializerContext jsonSerializerContext)
{
return global::System.Text.Json.JsonSerializer.Deserialize(
json,
typeof(global::Speechify.TtsFlowValidationIssue),
jsonSerializerContext) as global::Speechify.TtsFlowValidationIssue;
}

/// <summary>
/// Deserializes a JSON string using the provided JsonSerializerOptions.
/// </summary>
#if NET8_0_OR_GREATER
[global::System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("JSON serialization and deserialization might require types that cannot be statically analyzed. Use the overload that takes a JsonTypeInfo or JsonSerializerContext, or make sure all of the required types are preserved.")]
[global::System.Diagnostics.CodeAnalysis.RequiresDynamicCode("JSON serialization and deserialization might require types that cannot be statically analyzed and might need runtime code generation. Use System.Text.Json source generation for native AOT applications.")]
#endif
public static global::Speechify.TtsFlowValidationIssue? FromJson(
string json,
global::System.Text.Json.JsonSerializerOptions? jsonSerializerOptions = null)
{
return global::System.Text.Json.JsonSerializer.Deserialize<global::Speechify.TtsFlowValidationIssue>(
json,
jsonSerializerOptions);
}

/// <summary>
/// Deserializes a JSON stream using the provided JsonSerializerContext.
/// </summary>
public static async global::System.Threading.Tasks.ValueTask<global::Speechify.TtsFlowValidationIssue?> FromJsonStreamAsync(
global::System.IO.Stream jsonStream,
global::System.Text.Json.Serialization.JsonSerializerContext jsonSerializerContext)
{
return (await global::System.Text.Json.JsonSerializer.DeserializeAsync(
jsonStream,
typeof(global::Speechify.TtsFlowValidationIssue),
jsonSerializerContext).ConfigureAwait(false)) as global::Speechify.TtsFlowValidationIssue;
}

/// <summary>
/// Deserializes a JSON stream using the provided JsonSerializerOptions.
/// </summary>
#if NET8_0_OR_GREATER
[global::System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("JSON serialization and deserialization might require types that cannot be statically analyzed. Use the overload that takes a JsonTypeInfo or JsonSerializerContext, or make sure all of the required types are preserved.")]
[global::System.Diagnostics.CodeAnalysis.RequiresDynamicCode("JSON serialization and deserialization might require types that cannot be statically analyzed and might need runtime code generation. Use System.Text.Json source generation for native AOT applications.")]
#endif
public static global::System.Threading.Tasks.ValueTask<global::Speechify.TtsFlowValidationIssue?> FromJsonStreamAsync(
global::System.IO.Stream jsonStream,
global::System.Text.Json.JsonSerializerOptions? jsonSerializerOptions = null)
{
return global::System.Text.Json.JsonSerializer.DeserializeAsync<global::Speechify.TtsFlowValidationIssue?>(
jsonStream,
jsonSerializerOptions);
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@

#nullable enable

namespace Speechify
{
/// <summary>
/// One flow-graph validation problem, located by node/edge/field path.
/// </summary>
public sealed partial class TtsFlowValidationIssue
{
/// <summary>
/// Node / edge / field path the issue applies to; drives editor highlighting.
/// </summary>
[global::System.Text.Json.Serialization.JsonPropertyName("path")]
[global::System.Text.Json.Serialization.JsonRequired]
public required string Path { get; set; }

/// <summary>
/// Stable per-issue code, e.g. `tool_call.tool_id.invalid`.
/// </summary>
[global::System.Text.Json.Serialization.JsonPropertyName("code")]
[global::System.Text.Json.Serialization.JsonRequired]
public required string Code { get; set; }

/// <summary>
///
/// </summary>
[global::System.Text.Json.Serialization.JsonPropertyName("message")]
[global::System.Text.Json.Serialization.JsonRequired]
public required string Message { get; set; }

/// <summary>
/// Additional properties that are not explicitly defined in the schema
/// </summary>
[global::System.Text.Json.Serialization.JsonExtensionData]
public global::System.Collections.Generic.IDictionary<string, object> AdditionalProperties { get; set; } = new global::System.Collections.Generic.Dictionary<string, object>();

/// <summary>
/// Initializes a new instance of the <see cref="TtsFlowValidationIssue" /> class.
/// </summary>
/// <param name="path">
/// Node / edge / field path the issue applies to; drives editor highlighting.
/// </param>
/// <param name="code">
/// Stable per-issue code, e.g. `tool_call.tool_id.invalid`.
/// </param>
/// <param name="message"></param>
#if NET7_0_OR_GREATER
[global::System.Diagnostics.CodeAnalysis.SetsRequiredMembers]
#endif
public TtsFlowValidationIssue(
string path,
string code,
string message)
{
this.Path = path ?? throw new global::System.ArgumentNullException(nameof(path));
this.Code = code ?? throw new global::System.ArgumentNullException(nameof(code));
this.Message = message ?? throw new global::System.ArgumentNullException(nameof(message));
}

/// <summary>
/// Initializes a new instance of the <see cref="TtsFlowValidationIssue" /> class.
/// </summary>
public TtsFlowValidationIssue()
{
}

}
}
Loading