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 @@ -64,6 +64,14 @@ public partial interface IStructuredOutputsClient
/// - number/integer: the first match parsed as a number<br/>
/// - array: all matches
/// </param>
/// <param name="compliancePlan">
/// Compliance configuration for this output. Only enable overrides if no sensitive data will be stored.<br/>
/// Example: {"forceStoreOnHipaaEnabled":false}
/// </param>
/// <param name="conditions">
/// These are the conditions that gate the execution of this structured output. Every condition must pass for the structured output to run (AND semantics). When omitted or empty, no user-defined conditions gate this output. Send null to clear a previously saved gate.<br/>
/// Example: [{"type":"minMessages","count":4}, {"type":"minCallDuration","seconds":10}]
/// </param>
/// <param name="model">
/// This is the model that will be used to extract the structured output.<br/>
/// To provide your own custom system and user prompts for structured output extraction, populate the messages array with your system and user messages. You can specify liquid templating in your system and user messages.<br/>
Expand All @@ -77,14 +85,6 @@ public partial interface IStructuredOutputsClient
/// If model is not specified, GPT-4.1 will be used by default for extraction, utilizing default system and user prompts.<br/>
/// If messages or required fields are not specified, the default system and user prompts will be used.
/// </param>
/// <param name="compliancePlan">
/// Compliance configuration for this output. Only enable overrides if no sensitive data will be stored.<br/>
/// Example: {"forceStoreOnHipaaEnabled":false}
/// </param>
/// <param name="conditions">
/// These are the conditions that gate the execution of this structured output. Every condition must pass for the structured output to run (AND semantics). When omitted or empty, no user-defined conditions gate this output. Send null to clear a previously saved gate.<br/>
/// Example: [{"type":"minMessages","count":4}, {"type":"minCallDuration","seconds":10}]
/// </param>
/// <param name="name">
/// This is the name of the structured output.
/// </param>
Expand Down Expand Up @@ -118,9 +118,9 @@ public partial interface IStructuredOutputsClient
string schemaOverride,
global::Vapi.UpdateStructuredOutputDTOType? type = default,
string? regex = default,
global::Vapi.OneOf<global::Vapi.WorkflowOpenAIModel, global::Vapi.WorkflowAnthropicModel, global::Vapi.WorkflowAnthropicBedrockModel, global::Vapi.WorkflowGoogleModel, global::Vapi.WorkflowCustomModel>? model = default,
global::Vapi.ComplianceOverride? compliancePlan = default,
global::System.Collections.Generic.IList<global::Vapi.OneOf<global::Vapi.MinMessagesCondition, global::Vapi.MinCallDurationCondition, global::Vapi.EndedReasonCondition>>? conditions = default,
global::Vapi.OneOf<global::Vapi.WorkflowOpenAIModel, global::Vapi.WorkflowAnthropicModel, global::Vapi.WorkflowAnthropicBedrockModel, global::Vapi.WorkflowGoogleModel, global::Vapi.WorkflowCustomModel>? model = default,
string? name = default,
string? description = default,
global::System.Collections.Generic.IList<string>? assistantIds = default,
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
#nullable enable

namespace Vapi.JsonConverters
{
/// <inheritdoc />
public sealed class ClientMessageTranscriptConfidenceSourceJsonConverter : global::System.Text.Json.Serialization.JsonConverter<global::Vapi.ClientMessageTranscriptConfidenceSource>
{
/// <inheritdoc />
public override global::Vapi.ClientMessageTranscriptConfidenceSource Read(
ref global::System.Text.Json.Utf8JsonReader reader,
global::System.Type typeToConvert,
global::System.Text.Json.JsonSerializerOptions options)
{
switch (reader.TokenType)
{
case global::System.Text.Json.JsonTokenType.String:
{
var stringValue = reader.GetString();
if (stringValue != null)
{
return global::Vapi.ClientMessageTranscriptConfidenceSourceExtensions.ToEnum(stringValue) ?? default;
}

break;
}
case global::System.Text.Json.JsonTokenType.Number:
{
var numValue = reader.GetInt32();
return (global::Vapi.ClientMessageTranscriptConfidenceSource)numValue;
}
case global::System.Text.Json.JsonTokenType.Null:
{
return default(global::Vapi.ClientMessageTranscriptConfidenceSource);
}
default:
throw new global::System.ArgumentOutOfRangeException(nameof(reader));
}

return default;
}

/// <inheritdoc />
public override void Write(
global::System.Text.Json.Utf8JsonWriter writer,
global::Vapi.ClientMessageTranscriptConfidenceSource value,
global::System.Text.Json.JsonSerializerOptions options)
{
writer = writer ?? throw new global::System.ArgumentNullException(nameof(writer));

writer.WriteStringValue(global::Vapi.ClientMessageTranscriptConfidenceSourceExtensions.ToValueString(value));
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
#nullable enable

namespace Vapi.JsonConverters
{
/// <inheritdoc />
public sealed class ClientMessageTranscriptConfidenceSourceNullableJsonConverter : global::System.Text.Json.Serialization.JsonConverter<global::Vapi.ClientMessageTranscriptConfidenceSource?>
{
/// <inheritdoc />
public override global::Vapi.ClientMessageTranscriptConfidenceSource? Read(
ref global::System.Text.Json.Utf8JsonReader reader,
global::System.Type typeToConvert,
global::System.Text.Json.JsonSerializerOptions options)
{
switch (reader.TokenType)
{
case global::System.Text.Json.JsonTokenType.String:
{
var stringValue = reader.GetString();
if (stringValue != null)
{
return global::Vapi.ClientMessageTranscriptConfidenceSourceExtensions.ToEnum(stringValue);
}

break;
}
case global::System.Text.Json.JsonTokenType.Number:
{
var numValue = reader.GetInt32();
return (global::Vapi.ClientMessageTranscriptConfidenceSource)numValue;
}
case global::System.Text.Json.JsonTokenType.Null:
{
return default(global::Vapi.ClientMessageTranscriptConfidenceSource?);
}
default:
throw new global::System.ArgumentOutOfRangeException(nameof(reader));
}

return default;
}

/// <inheritdoc />
public override void Write(
global::System.Text.Json.Utf8JsonWriter writer,
global::Vapi.ClientMessageTranscriptConfidenceSource? value,
global::System.Text.Json.JsonSerializerOptions options)
{
writer = writer ?? throw new global::System.ArgumentNullException(nameof(writer));

if (value == null)
{
writer.WriteNullValue();
}
else
{
writer.WriteStringValue(global::Vapi.ClientMessageTranscriptConfidenceSourceExtensions.ToValueString(value.Value));
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
#nullable enable

namespace Vapi.JsonConverters
{
/// <inheritdoc />
public sealed class ServerMessageTranscriptConfidenceSourceJsonConverter : global::System.Text.Json.Serialization.JsonConverter<global::Vapi.ServerMessageTranscriptConfidenceSource>
{
/// <inheritdoc />
public override global::Vapi.ServerMessageTranscriptConfidenceSource Read(
ref global::System.Text.Json.Utf8JsonReader reader,
global::System.Type typeToConvert,
global::System.Text.Json.JsonSerializerOptions options)
{
switch (reader.TokenType)
{
case global::System.Text.Json.JsonTokenType.String:
{
var stringValue = reader.GetString();
if (stringValue != null)
{
return global::Vapi.ServerMessageTranscriptConfidenceSourceExtensions.ToEnum(stringValue) ?? default;
}

break;
}
case global::System.Text.Json.JsonTokenType.Number:
{
var numValue = reader.GetInt32();
return (global::Vapi.ServerMessageTranscriptConfidenceSource)numValue;
}
case global::System.Text.Json.JsonTokenType.Null:
{
return default(global::Vapi.ServerMessageTranscriptConfidenceSource);
}
default:
throw new global::System.ArgumentOutOfRangeException(nameof(reader));
}

return default;
}

/// <inheritdoc />
public override void Write(
global::System.Text.Json.Utf8JsonWriter writer,
global::Vapi.ServerMessageTranscriptConfidenceSource value,
global::System.Text.Json.JsonSerializerOptions options)
{
writer = writer ?? throw new global::System.ArgumentNullException(nameof(writer));

writer.WriteStringValue(global::Vapi.ServerMessageTranscriptConfidenceSourceExtensions.ToValueString(value));
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
#nullable enable

namespace Vapi.JsonConverters
{
/// <inheritdoc />
public sealed class ServerMessageTranscriptConfidenceSourceNullableJsonConverter : global::System.Text.Json.Serialization.JsonConverter<global::Vapi.ServerMessageTranscriptConfidenceSource?>
{
/// <inheritdoc />
public override global::Vapi.ServerMessageTranscriptConfidenceSource? Read(
ref global::System.Text.Json.Utf8JsonReader reader,
global::System.Type typeToConvert,
global::System.Text.Json.JsonSerializerOptions options)
{
switch (reader.TokenType)
{
case global::System.Text.Json.JsonTokenType.String:
{
var stringValue = reader.GetString();
if (stringValue != null)
{
return global::Vapi.ServerMessageTranscriptConfidenceSourceExtensions.ToEnum(stringValue);
}

break;
}
case global::System.Text.Json.JsonTokenType.Number:
{
var numValue = reader.GetInt32();
return (global::Vapi.ServerMessageTranscriptConfidenceSource)numValue;
}
case global::System.Text.Json.JsonTokenType.Null:
{
return default(global::Vapi.ServerMessageTranscriptConfidenceSource?);
}
default:
throw new global::System.ArgumentOutOfRangeException(nameof(reader));
}

return default;
}

/// <inheritdoc />
public override void Write(
global::System.Text.Json.Utf8JsonWriter writer,
global::Vapi.ServerMessageTranscriptConfidenceSource? value,
global::System.Text.Json.JsonSerializerOptions options)
{
writer = writer ?? throw new global::System.ArgumentNullException(nameof(writer));

if (value == null)
{
writer.WriteNullValue();
}
else
{
writer.WriteStringValue(global::Vapi.ServerMessageTranscriptConfidenceSourceExtensions.ToValueString(value.Value));
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
#nullable enable

namespace Vapi.JsonConverters
{
/// <inheritdoc />
public sealed class UserMessageConfidenceSourceJsonConverter : global::System.Text.Json.Serialization.JsonConverter<global::Vapi.UserMessageConfidenceSource>
{
/// <inheritdoc />
public override global::Vapi.UserMessageConfidenceSource Read(
ref global::System.Text.Json.Utf8JsonReader reader,
global::System.Type typeToConvert,
global::System.Text.Json.JsonSerializerOptions options)
{
switch (reader.TokenType)
{
case global::System.Text.Json.JsonTokenType.String:
{
var stringValue = reader.GetString();
if (stringValue != null)
{
return global::Vapi.UserMessageConfidenceSourceExtensions.ToEnum(stringValue) ?? default;
}

break;
}
case global::System.Text.Json.JsonTokenType.Number:
{
var numValue = reader.GetInt32();
return (global::Vapi.UserMessageConfidenceSource)numValue;
}
case global::System.Text.Json.JsonTokenType.Null:
{
return default(global::Vapi.UserMessageConfidenceSource);
}
default:
throw new global::System.ArgumentOutOfRangeException(nameof(reader));
}

return default;
}

/// <inheritdoc />
public override void Write(
global::System.Text.Json.Utf8JsonWriter writer,
global::Vapi.UserMessageConfidenceSource value,
global::System.Text.Json.JsonSerializerOptions options)
{
writer = writer ?? throw new global::System.ArgumentNullException(nameof(writer));

writer.WriteStringValue(global::Vapi.UserMessageConfidenceSourceExtensions.ToValueString(value));
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
#nullable enable

namespace Vapi.JsonConverters
{
/// <inheritdoc />
public sealed class UserMessageConfidenceSourceNullableJsonConverter : global::System.Text.Json.Serialization.JsonConverter<global::Vapi.UserMessageConfidenceSource?>
{
/// <inheritdoc />
public override global::Vapi.UserMessageConfidenceSource? Read(
ref global::System.Text.Json.Utf8JsonReader reader,
global::System.Type typeToConvert,
global::System.Text.Json.JsonSerializerOptions options)
{
switch (reader.TokenType)
{
case global::System.Text.Json.JsonTokenType.String:
{
var stringValue = reader.GetString();
if (stringValue != null)
{
return global::Vapi.UserMessageConfidenceSourceExtensions.ToEnum(stringValue);
}

break;
}
case global::System.Text.Json.JsonTokenType.Number:
{
var numValue = reader.GetInt32();
return (global::Vapi.UserMessageConfidenceSource)numValue;
}
case global::System.Text.Json.JsonTokenType.Null:
{
return default(global::Vapi.UserMessageConfidenceSource?);
}
default:
throw new global::System.ArgumentOutOfRangeException(nameof(reader));
}

return default;
}

/// <inheritdoc />
public override void Write(
global::System.Text.Json.Utf8JsonWriter writer,
global::Vapi.UserMessageConfidenceSource? value,
global::System.Text.Json.JsonSerializerOptions options)
{
writer = writer ?? throw new global::System.ArgumentNullException(nameof(writer));

if (value == null)
{
writer.WriteNullValue();
}
else
{
writer.WriteStringValue(global::Vapi.UserMessageConfidenceSourceExtensions.ToValueString(value.Value));
}
}
}
}
Loading
Loading