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 @@ -87,6 +87,8 @@ namespace Browserbase

typeof(global::Browserbase.JsonConverters.AnyOfJsonConverter<global::Browserbase.BrowserbaseProxyConfig, global::Browserbase.ExternalProxyConfig, global::Browserbase.NoneProxyConfig>),

typeof(global::Browserbase.JsonConverters.AnyOfJsonConverter<string, object>),

typeof(global::Browserbase.JsonConverters.AllOfJsonConverter<global::Browserbase.Invocation, global::Browserbase.InvocationsGetResponse2>),

typeof(global::Browserbase.JsonConverters.AllOfJsonConverter<global::Browserbase.Session, global::Browserbase.SessionsCreateResponse2>),
Expand Down Expand Up @@ -179,6 +181,7 @@ namespace Browserbase
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Browserbase.DownloadsGetResponse))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Browserbase.FetchCreateResponse))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.Dictionary<string, string>))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Browserbase.AnyOf<string, object>), TypeInfoPropertyName = "AnyOfStringObject2")]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Browserbase.FetchCreateResponse2))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Browserbase.FetchCreateResponse3))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::Browserbase.FetchCreateResponse4))]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -360,139 +360,143 @@ public sealed partial class JsonSerializerContextTypes
/// <summary>
///
/// </summary>
public global::Browserbase.FetchCreateResponse2? Type83 { get; set; }
public global::Browserbase.AnyOf<string, object>? Type83 { get; set; }
/// <summary>
///
/// </summary>
public global::Browserbase.FetchCreateResponse3? Type84 { get; set; }
public global::Browserbase.FetchCreateResponse2? Type84 { get; set; }
/// <summary>
///
/// </summary>
public global::Browserbase.FetchCreateResponse4? Type85 { get; set; }
public global::Browserbase.FetchCreateResponse3? Type85 { get; set; }
/// <summary>
///
/// </summary>
public global::Browserbase.FetchCreateResponse5? Type86 { get; set; }
public global::Browserbase.FetchCreateResponse4? Type86 { get; set; }
/// <summary>
///
/// </summary>
public global::Browserbase.FunctionsListResponse? Type87 { get; set; }
public global::Browserbase.FetchCreateResponse5? Type87 { get; set; }
/// <summary>
///
/// </summary>
public global::System.Collections.Generic.IList<global::Browserbase.Function>? Type88 { get; set; }
public global::Browserbase.FunctionsListResponse? Type88 { get; set; }
/// <summary>
///
/// </summary>
public global::Browserbase.FunctionBuildsListResponse? Type89 { get; set; }
public global::System.Collections.Generic.IList<global::Browserbase.Function>? Type89 { get; set; }
/// <summary>
///
/// </summary>
public global::System.Collections.Generic.IList<global::Browserbase.FunctionBuild>? Type90 { get; set; }
public global::Browserbase.FunctionBuildsListResponse? Type90 { get; set; }
/// <summary>
///
/// </summary>
public global::Browserbase.FunctionBuildsGetLogsResponse? Type91 { get; set; }
public global::System.Collections.Generic.IList<global::Browserbase.FunctionBuild>? Type91 { get; set; }
/// <summary>
///
/// </summary>
public global::System.Collections.Generic.IList<global::Browserbase.FunctionBuildLog>? Type92 { get; set; }
public global::Browserbase.FunctionBuildsGetLogsResponse? Type92 { get; set; }
/// <summary>
///
/// </summary>
public global::Browserbase.AllOf<global::Browserbase.Invocation, global::Browserbase.InvocationsGetResponse2>? Type93 { get; set; }
public global::System.Collections.Generic.IList<global::Browserbase.FunctionBuildLog>? Type93 { get; set; }
/// <summary>
///
/// </summary>
public global::Browserbase.InvocationsGetResponse2? Type94 { get; set; }
public global::Browserbase.AllOf<global::Browserbase.Invocation, global::Browserbase.InvocationsGetResponse2>? Type94 { get; set; }
/// <summary>
///
/// </summary>
public global::Browserbase.InvocationsGetResponseCause? Type95 { get; set; }
public global::Browserbase.InvocationsGetResponse2? Type95 { get; set; }
/// <summary>
///
/// </summary>
public global::Browserbase.InvocationsGetResponseCauseCode? Type96 { get; set; }
public global::Browserbase.InvocationsGetResponseCause? Type96 { get; set; }
/// <summary>
///
/// </summary>
public global::Browserbase.InvocationsGetLogsResponse? Type97 { get; set; }
public global::Browserbase.InvocationsGetResponseCauseCode? Type97 { get; set; }
/// <summary>
///
/// </summary>
public global::System.Collections.Generic.IList<global::Browserbase.InvocationLog>? Type98 { get; set; }
public global::Browserbase.InvocationsGetLogsResponse? Type98 { get; set; }
/// <summary>
///
/// </summary>
public global::Browserbase.FunctionVersionsListInvocationsResponse? Type99 { get; set; }
public global::System.Collections.Generic.IList<global::Browserbase.InvocationLog>? Type99 { get; set; }
/// <summary>
///
/// </summary>
public global::System.Collections.Generic.IList<global::Browserbase.Invocation>? Type100 { get; set; }
public global::Browserbase.FunctionVersionsListInvocationsResponse? Type100 { get; set; }
/// <summary>
///
/// </summary>
public global::Browserbase.FunctionsListVersionsResponse? Type101 { get; set; }
public global::System.Collections.Generic.IList<global::Browserbase.Invocation>? Type101 { get; set; }
/// <summary>
///
/// </summary>
public global::System.Collections.Generic.IList<global::Browserbase.FunctionVersion>? Type102 { get; set; }
public global::Browserbase.FunctionsListVersionsResponse? Type102 { get; set; }
/// <summary>
///
/// </summary>
public global::System.Collections.Generic.IList<global::Browserbase.Project>? Type103 { get; set; }
public global::System.Collections.Generic.IList<global::Browserbase.FunctionVersion>? Type103 { get; set; }
/// <summary>
///
/// </summary>
public global::Browserbase.SearchWebResponse? Type104 { get; set; }
public global::System.Collections.Generic.IList<global::Browserbase.Project>? Type104 { get; set; }
/// <summary>
///
/// </summary>
public global::System.Collections.Generic.IList<global::Browserbase.SearchWebResponseResult>? Type105 { get; set; }
public global::Browserbase.SearchWebResponse? Type105 { get; set; }
/// <summary>
///
/// </summary>
public global::Browserbase.SearchWebResponseResult? Type106 { get; set; }
public global::System.Collections.Generic.IList<global::Browserbase.SearchWebResponseResult>? Type106 { get; set; }
/// <summary>
///
/// </summary>
public global::System.Collections.Generic.IList<global::Browserbase.Session>? Type107 { get; set; }
public global::Browserbase.SearchWebResponseResult? Type107 { get; set; }
/// <summary>
///
/// </summary>
public global::Browserbase.AllOf<global::Browserbase.Session, global::Browserbase.SessionsCreateResponse2>? Type108 { get; set; }
public global::System.Collections.Generic.IList<global::Browserbase.Session>? Type108 { get; set; }
/// <summary>
///
/// </summary>
public global::Browserbase.SessionsCreateResponse2? Type109 { get; set; }
public global::Browserbase.AllOf<global::Browserbase.Session, global::Browserbase.SessionsCreateResponse2>? Type109 { get; set; }
/// <summary>
///
/// </summary>
public global::Browserbase.AllOf<global::Browserbase.Session, global::Browserbase.SessionsGetResponse2>? Type110 { get; set; }
public global::Browserbase.SessionsCreateResponse2? Type110 { get; set; }
/// <summary>
///
/// </summary>
public global::Browserbase.SessionsGetResponse2? Type111 { get; set; }
public global::Browserbase.AllOf<global::Browserbase.Session, global::Browserbase.SessionsGetResponse2>? Type111 { get; set; }
/// <summary>
///
/// </summary>
public global::System.Collections.Generic.IList<global::Browserbase.SessionLog>? Type112 { get; set; }
public global::Browserbase.SessionsGetResponse2? Type112 { get; set; }
/// <summary>
///
/// </summary>
public global::System.Collections.Generic.IList<global::Browserbase.SessionRecording>? Type113 { get; set; }
public global::System.Collections.Generic.IList<global::Browserbase.SessionLog>? Type113 { get; set; }
/// <summary>
///
/// </summary>
public global::Browserbase.SessionsGetReplayResponse? Type114 { get; set; }
public global::System.Collections.Generic.IList<global::Browserbase.SessionRecording>? Type114 { get; set; }
/// <summary>
///
/// </summary>
public global::System.Collections.Generic.IList<global::Browserbase.ReplayPage>? Type115 { get; set; }
public global::Browserbase.SessionsGetReplayResponse? Type115 { get; set; }
/// <summary>
///
/// </summary>
public global::Browserbase.SessionsUploadFileResponse? Type116 { get; set; }
public global::System.Collections.Generic.IList<global::Browserbase.ReplayPage>? Type116 { get; set; }
/// <summary>
///
/// </summary>
public global::Browserbase.SessionsUploadFileResponse? Type117 { get; set; }

/// <summary>
///
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,12 @@ public sealed partial class FetchCreateResponse
public required global::System.Collections.Generic.Dictionary<string, string> Headers { get; set; }

/// <summary>
/// The response body content
/// The response body content. A string for `raw` and `markdown` formats; a structured object for `json` format (the schema-extracted result).
/// </summary>
[global::System.Text.Json.Serialization.JsonPropertyName("content")]
[global::System.Text.Json.Serialization.JsonConverter(typeof(global::Browserbase.JsonConverters.AnyOfJsonConverter<string, object>))]
[global::System.Text.Json.Serialization.JsonRequired]
public required string Content { get; set; }
public required global::Browserbase.AnyOf<string, object> Content { get; set; }

/// <summary>
/// The MIME type of the response
Expand Down Expand Up @@ -69,7 +70,7 @@ public sealed partial class FetchCreateResponse
/// Response headers as key-value pairs
/// </param>
/// <param name="content">
/// The response body content
/// The response body content. A string for `raw` and `markdown` formats; a structured object for `json` format (the schema-extracted result).
/// </param>
/// <param name="contentType">
/// The MIME type of the response
Expand All @@ -84,14 +85,14 @@ public FetchCreateResponse(
string id,
int statusCode,
global::System.Collections.Generic.Dictionary<string, string> headers,
string content,
global::Browserbase.AnyOf<string, object> content,
string contentType,
string encoding)
{
this.Id = id ?? throw new global::System.ArgumentNullException(nameof(id));
this.StatusCode = statusCode;
this.Headers = headers ?? throw new global::System.ArgumentNullException(nameof(headers));
this.Content = content ?? throw new global::System.ArgumentNullException(nameof(content));
this.Content = content;
this.ContentType = contentType ?? throw new global::System.ArgumentNullException(nameof(contentType));
this.Encoding = encoding ?? throw new global::System.ArgumentNullException(nameof(encoding));
}
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
#nullable enable

namespace Browserbase
{
public sealed partial class FetchCreateResponseContent
{
/// <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::Browserbase.FetchCreateResponseContent? FromJson(
string json,
global::System.Text.Json.Serialization.JsonSerializerContext jsonSerializerContext)
{
return global::System.Text.Json.JsonSerializer.Deserialize(
json,
typeof(global::Browserbase.FetchCreateResponseContent),
jsonSerializerContext) as global::Browserbase.FetchCreateResponseContent;
}

/// <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::Browserbase.FetchCreateResponseContent? FromJson(
string json,
global::System.Text.Json.JsonSerializerOptions? jsonSerializerOptions = null)
{
return global::System.Text.Json.JsonSerializer.Deserialize<global::Browserbase.FetchCreateResponseContent>(
json,
jsonSerializerOptions);
}

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

/// <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::Browserbase.FetchCreateResponseContent?> FromJsonStreamAsync(
global::System.IO.Stream jsonStream,
global::System.Text.Json.JsonSerializerOptions? jsonSerializerOptions = null)
{
return global::System.Text.Json.JsonSerializer.DeserializeAsync<global::Browserbase.FetchCreateResponseContent?>(
jsonStream,
jsonSerializerOptions);
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@

#nullable enable

namespace Browserbase
{
/// <summary>
///
/// </summary>
public sealed partial class FetchCreateResponseContent
{

/// <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>();

}
}
Loading