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
10 changes: 5 additions & 5 deletions src/cli/AI21.CLI/Commands/DefaultApiGroupCommand.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -104,11 +104,11 @@ public static Command Create()
command.Subcommands.Add(ParsePdfStudioV1DemosDocumentModifierParsePdfPostCommandApiCommand.Create());
command.Subcommands.Add(ProcessRfiDocumentStudioV1DemosRfiProcessRfiPostCommandApiCommand.Create());
command.Subcommands.Add(ProxyCliConfigHarnessApiAuthCliConfigGetCommandApiCommand.Create());
command.Subcommands.Add(ProxyHarnessApiHarnessApiPathPatchCommandApiCommand.Create());
command.Subcommands.Add(ProxyHarnessApiHarnessApiPathPatch2CommandApiCommand.Create());
command.Subcommands.Add(ProxyHarnessApiHarnessApiPathPatch3CommandApiCommand.Create());
command.Subcommands.Add(ProxyHarnessApiHarnessApiPathPatch4CommandApiCommand.Create());
command.Subcommands.Add(ProxyHarnessApiHarnessApiPathPatch5CommandApiCommand.Create());
command.Subcommands.Add(ProxyHarnessApiHarnessApiPathGetCommandApiCommand.Create());
command.Subcommands.Add(ProxyHarnessApiHarnessApiPathGet2CommandApiCommand.Create());
command.Subcommands.Add(ProxyHarnessApiHarnessApiPathGet3CommandApiCommand.Create());
command.Subcommands.Add(ProxyHarnessApiHarnessApiPathGet4CommandApiCommand.Create());
command.Subcommands.Add(ProxyHarnessApiHarnessApiPathGet5CommandApiCommand.Create());
command.Subcommands.Add(ProxyOffV1GatewayOffV1PathOptionsCommandApiCommand.Create());
command.Subcommands.Add(ProxyOffV1GatewayOffV1PathOptions2CommandApiCommand.Create());
command.Subcommands.Add(ProxyOffV1GatewayOffV1PathOptions3CommandApiCommand.Create());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

namespace AI21.CLI.Commands;

internal static partial class ProxyHarnessApiHarnessApiPathPatchCommandApiCommand
internal static partial class ProxyHarnessApiHarnessApiPathGet2CommandApiCommand
{
private static Argument<string> Path { get; } = new(
name: @"path")
Expand Down Expand Up @@ -37,7 +37,7 @@ private static string FormatResponse(ParseResult parseResult, string value, glob

public static Command Create(string? commandName = null)
{
var command = new Command(commandName ?? @"proxy-harness-api-harness-api-path-patch", @"Proxy Harness Api");
var command = new Command(commandName ?? @"proxy-harness-api-harness-api-path-get2", @"Proxy Harness Api");
command.Arguments.Add(Path);


Expand All @@ -48,7 +48,7 @@ await CliRuntime.RunAsync(async () =>
using var client = await CliRuntime.CreateClientAsync(parseResult, cancellationToken).ConfigureAwait(false);


var response = await client.ProxyHarnessApiHarnessApiPathPatchAsync(
var response = await client.ProxyHarnessApiHarnessApiPathGet2Async(
path: path,
cancellationToken: cancellationToken).ConfigureAwait(false);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

namespace AI21.CLI.Commands;

internal static partial class ProxyHarnessApiHarnessApiPathPatch3CommandApiCommand
internal static partial class ProxyHarnessApiHarnessApiPathGet3CommandApiCommand
{
private static Argument<string> Path { get; } = new(
name: @"path")
Expand Down Expand Up @@ -37,7 +37,7 @@ private static string FormatResponse(ParseResult parseResult, string value, glob

public static Command Create(string? commandName = null)
{
var command = new Command(commandName ?? @"proxy-harness-api-harness-api-path-patch3", @"Proxy Harness Api");
var command = new Command(commandName ?? @"proxy-harness-api-harness-api-path-get3", @"Proxy Harness Api");
command.Arguments.Add(Path);


Expand All @@ -48,7 +48,7 @@ await CliRuntime.RunAsync(async () =>
using var client = await CliRuntime.CreateClientAsync(parseResult, cancellationToken).ConfigureAwait(false);


var response = await client.ProxyHarnessApiHarnessApiPathPatch3Async(
var response = await client.ProxyHarnessApiHarnessApiPathGet3Async(
path: path,
cancellationToken: cancellationToken).ConfigureAwait(false);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

namespace AI21.CLI.Commands;

internal static partial class ProxyHarnessApiHarnessApiPathPatch4CommandApiCommand
internal static partial class ProxyHarnessApiHarnessApiPathGet4CommandApiCommand
{
private static Argument<string> Path { get; } = new(
name: @"path")
Expand Down Expand Up @@ -37,7 +37,7 @@ private static string FormatResponse(ParseResult parseResult, string value, glob

public static Command Create(string? commandName = null)
{
var command = new Command(commandName ?? @"proxy-harness-api-harness-api-path-patch4", @"Proxy Harness Api");
var command = new Command(commandName ?? @"proxy-harness-api-harness-api-path-get4", @"Proxy Harness Api");
command.Arguments.Add(Path);


Expand All @@ -48,7 +48,7 @@ await CliRuntime.RunAsync(async () =>
using var client = await CliRuntime.CreateClientAsync(parseResult, cancellationToken).ConfigureAwait(false);


var response = await client.ProxyHarnessApiHarnessApiPathPatch4Async(
var response = await client.ProxyHarnessApiHarnessApiPathGet4Async(
path: path,
cancellationToken: cancellationToken).ConfigureAwait(false);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

namespace AI21.CLI.Commands;

internal static partial class ProxyHarnessApiHarnessApiPathPatch5CommandApiCommand
internal static partial class ProxyHarnessApiHarnessApiPathGet5CommandApiCommand
{
private static Argument<string> Path { get; } = new(
name: @"path")
Expand Down Expand Up @@ -37,7 +37,7 @@ private static string FormatResponse(ParseResult parseResult, string value, glob

public static Command Create(string? commandName = null)
{
var command = new Command(commandName ?? @"proxy-harness-api-harness-api-path-patch5", @"Proxy Harness Api");
var command = new Command(commandName ?? @"proxy-harness-api-harness-api-path-get5", @"Proxy Harness Api");
command.Arguments.Add(Path);


Expand All @@ -48,7 +48,7 @@ await CliRuntime.RunAsync(async () =>
using var client = await CliRuntime.CreateClientAsync(parseResult, cancellationToken).ConfigureAwait(false);


var response = await client.ProxyHarnessApiHarnessApiPathPatch5Async(
var response = await client.ProxyHarnessApiHarnessApiPathGet5Async(
path: path,
cancellationToken: cancellationToken).ConfigureAwait(false);

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
#nullable enable
#pragma warning disable CS0618

using System.CommandLine;

namespace AI21.CLI.Commands;

internal static partial class ProxyHarnessApiHarnessApiPathGetCommandApiCommand
{
private static Argument<string> Path { get; } = new(
name: @"path")
{
Description = @"",
};

private static string FormatResponse(ParseResult parseResult, string value, global::System.Text.Json.Serialization.JsonSerializerContext context, bool truncateLongStrings)
{
string? text = null;
CustomizeResponseText(parseResult, value, ref text);
if (!string.IsNullOrWhiteSpace(text))
{
return text;
}

var hints = new Dictionary<string, CliFormatHint>(StringComparer.OrdinalIgnoreCase)
{
};
CustomizeResponseFormatHints(hints);
return CliRuntime.FormatHumanReadable(value, context, truncateLongStrings, hints);
}

static partial void CustomizeResponseText(ParseResult parseResult, string value, ref string? text);
static partial void CustomizeResponseFormatHints(Dictionary<string, CliFormatHint> hints);


static partial void CustomizeCommand(ref Command command);

public static Command Create(string? commandName = null)
{
var command = new Command(commandName ?? @"proxy-harness-api-harness-api-path-get", @"Proxy Harness Api");
command.Arguments.Add(Path);


command.SetAction(async (ParseResult parseResult, CancellationToken cancellationToken) =>
await CliRuntime.RunAsync(async () =>
{
var path = parseResult.GetRequiredValue(Path);
using var client = await CliRuntime.CreateClientAsync(parseResult, cancellationToken).ConfigureAwait(false);


var response = await client.ProxyHarnessApiHarnessApiPathGetAsync(
path: path,
cancellationToken: cancellationToken).ConfigureAwait(false);


await CliRuntime.WriteResponseAsync(
parseResult,
response,
global::AI21.SourceGenerationContext.Default,
FormatResponse,
cancellationToken).ConfigureAwait(false);
}, cancellationToken).ConfigureAwait(false));
CustomizeCommand(ref command);
return command;
}
}

This file was deleted.

Loading
Loading