Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat:@coderabbitai #85

Merged
merged 1 commit into from
Dec 23, 2024
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 @@ -7,12 +7,10 @@ public partial class Ai21Api
{
partial void PrepareConvertDocumentFileStudioV1ChatFilesConvertPostArguments(
global::System.Net.Http.HttpClient httpClient,
ref int? requestStartTime,
global::AI21.BodyConvertDocumentFileStudioV1ChatFilesConvertPost request);
partial void PrepareConvertDocumentFileStudioV1ChatFilesConvertPostRequest(
global::System.Net.Http.HttpClient httpClient,
global::System.Net.Http.HttpRequestMessage httpRequestMessage,
int? requestStartTime,
global::AI21.BodyConvertDocumentFileStudioV1ChatFilesConvertPost request);
partial void ProcessConvertDocumentFileStudioV1ChatFilesConvertPostResponse(
global::System.Net.Http.HttpClient httpClient,
Expand All @@ -26,15 +24,11 @@ partial void ProcessConvertDocumentFileStudioV1ChatFilesConvertPostResponseConte
/// <summary>
/// Convert Document File
/// </summary>
/// <param name="requestStartTime">
/// Default Value: 1730898900272
/// </param>
/// <param name="request"></param>
/// <param name="cancellationToken">The token to cancel the operation with</param>
/// <exception cref="global::AI21.ApiException"></exception>
public async global::System.Threading.Tasks.Task<string> ConvertDocumentFileStudioV1ChatFilesConvertPostAsync(
global::AI21.BodyConvertDocumentFileStudioV1ChatFilesConvertPost request,
int? requestStartTime = default,
global::System.Threading.CancellationToken cancellationToken = default)
{
request = request ?? throw new global::System.ArgumentNullException(nameof(request));
Expand All @@ -43,15 +37,11 @@ partial void ProcessConvertDocumentFileStudioV1ChatFilesConvertPostResponseConte
client: HttpClient);
PrepareConvertDocumentFileStudioV1ChatFilesConvertPostArguments(
httpClient: HttpClient,
requestStartTime: ref requestStartTime,
request: request);

var __pathBuilder = new PathBuilder(
path: "/studio/v1/chat/files/convert",
baseUri: HttpClient.BaseAddress);
__pathBuilder
.AddOptionalParameter("request_start_time", requestStartTime?.ToString())
;
var __path = __pathBuilder.ToString();
using var __httpRequest = new global::System.Net.Http.HttpRequestMessage(
method: global::System.Net.Http.HttpMethod.Post,
Expand All @@ -77,12 +67,6 @@ partial void ProcessConvertDocumentFileStudioV1ChatFilesConvertPostResponseConte
}
}
using var __httpRequestContent = new global::System.Net.Http.MultipartFormDataContent();
if (requestStartTime != default)
{
__httpRequestContent.Add(
content: new global::System.Net.Http.StringContent($"{requestStartTime}"),
name: "request_start_time");
}
__httpRequestContent.Add(
content: new global::System.Net.Http.StringContent($"[{string.Join(",", global::System.Linq.Enumerable.Select(request.Files, x => x))}]"),
name: "files");
Expand All @@ -94,7 +78,6 @@ partial void ProcessConvertDocumentFileStudioV1ChatFilesConvertPostResponseConte
PrepareConvertDocumentFileStudioV1ChatFilesConvertPostRequest(
httpClient: HttpClient,
httpRequestMessage: __httpRequest,
requestStartTime: requestStartTime,
request: request);

using var __response = await HttpClient.SendAsync(
Expand Down Expand Up @@ -200,15 +183,11 @@ partial void ProcessConvertDocumentFileStudioV1ChatFilesConvertPostResponseConte
/// <summary>
/// Convert Document File
/// </summary>
/// <param name="requestStartTime">
/// Default Value: 1730898900272
/// </param>
/// <param name="files"></param>
/// <param name="cancellationToken">The token to cancel the operation with</param>
/// <exception cref="global::System.InvalidOperationException"></exception>
public async global::System.Threading.Tasks.Task<string> ConvertDocumentFileStudioV1ChatFilesConvertPostAsync(
global::System.Collections.Generic.IList<byte[]> files,
int? requestStartTime = default,
global::System.Threading.CancellationToken cancellationToken = default)
{
var __request = new global::AI21.BodyConvertDocumentFileStudioV1ChatFilesConvertPost
Expand All @@ -217,7 +196,6 @@ partial void ProcessConvertDocumentFileStudioV1ChatFilesConvertPostResponseConte
};

return await ConvertDocumentFileStudioV1ChatFilesConvertPostAsync(
requestStartTime: requestStartTime,
request: __request,
cancellationToken: cancellationToken).ConfigureAwait(false);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,11 @@ public partial class Ai21Api
{
partial void PrepareGenerateOrgTokenStudioV1ConnectorsConnectedUsersOrganizationIdTokensPostArguments(
global::System.Net.Http.HttpClient httpClient,
ref string organizationId,
ref int? requestStartTime);
ref string organizationId);
partial void PrepareGenerateOrgTokenStudioV1ConnectorsConnectedUsersOrganizationIdTokensPostRequest(
global::System.Net.Http.HttpClient httpClient,
global::System.Net.Http.HttpRequestMessage httpRequestMessage,
string organizationId,
int? requestStartTime);
string organizationId);
partial void ProcessGenerateOrgTokenStudioV1ConnectorsConnectedUsersOrganizationIdTokensPostResponse(
global::System.Net.Http.HttpClient httpClient,
global::System.Net.Http.HttpResponseMessage httpResponseMessage);
Expand All @@ -27,29 +25,21 @@ partial void ProcessGenerateOrgTokenStudioV1ConnectorsConnectedUsersOrganization
/// Generate Org Token
/// </summary>
/// <param name="organizationId"></param>
/// <param name="requestStartTime">
/// Default Value: 1730898900272
/// </param>
/// <param name="cancellationToken">The token to cancel the operation with</param>
/// <exception cref="global::AI21.ApiException"></exception>
public async global::System.Threading.Tasks.Task<global::AI21.ConnectorsToken> GenerateOrgTokenStudioV1ConnectorsConnectedUsersOrganizationIdTokensPostAsync(
string organizationId,
int? requestStartTime = default,
global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
PrepareGenerateOrgTokenStudioV1ConnectorsConnectedUsersOrganizationIdTokensPostArguments(
httpClient: HttpClient,
organizationId: ref organizationId,
requestStartTime: ref requestStartTime);
organizationId: ref organizationId);

var __pathBuilder = new PathBuilder(
path: $"/studio/v1/connectors/connected-users/{organizationId}/tokens",
baseUri: HttpClient.BaseAddress);
__pathBuilder
.AddOptionalParameter("request_start_time", requestStartTime?.ToString())
;
var __path = __pathBuilder.ToString();
using var __httpRequest = new global::System.Net.Http.HttpRequestMessage(
method: global::System.Net.Http.HttpMethod.Post,
Expand Down Expand Up @@ -81,8 +71,7 @@ partial void ProcessGenerateOrgTokenStudioV1ConnectorsConnectedUsersOrganization
PrepareGenerateOrgTokenStudioV1ConnectorsConnectedUsersOrganizationIdTokensPostRequest(
httpClient: HttpClient,
httpRequestMessage: __httpRequest,
organizationId: organizationId,
requestStartTime: requestStartTime);
organizationId: organizationId);

using var __response = await HttpClient.SendAsync(
request: __httpRequest,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,12 @@ public partial class Ai21Api
partial void PrepareGetDataSourceStatusStudioV1ConnectorsConnectedUsersOrganizationIdDataSourcesDataSourceStatusGetArguments(
global::System.Net.Http.HttpClient httpClient,
ref string organizationId,
ref string dataSource,
ref int? requestStartTime);
ref string dataSource);
partial void PrepareGetDataSourceStatusStudioV1ConnectorsConnectedUsersOrganizationIdDataSourcesDataSourceStatusGetRequest(
global::System.Net.Http.HttpClient httpClient,
global::System.Net.Http.HttpRequestMessage httpRequestMessage,
string organizationId,
string dataSource,
int? requestStartTime);
string dataSource);
partial void ProcessGetDataSourceStatusStudioV1ConnectorsConnectedUsersOrganizationIdDataSourcesDataSourceStatusGetResponse(
global::System.Net.Http.HttpClient httpClient,
global::System.Net.Http.HttpResponseMessage httpResponseMessage);
Expand All @@ -30,31 +28,23 @@ partial void ProcessGetDataSourceStatusStudioV1ConnectorsConnectedUsersOrganizat
/// </summary>
/// <param name="organizationId"></param>
/// <param name="dataSource"></param>
/// <param name="requestStartTime">
/// Default Value: 1730898900272
/// </param>
/// <param name="cancellationToken">The token to cancel the operation with</param>
/// <exception cref="global::AI21.ApiException"></exception>
public async global::System.Threading.Tasks.Task<global::AI21.ConnectorsStatus> GetDataSourceStatusStudioV1ConnectorsConnectedUsersOrganizationIdDataSourcesDataSourceStatusGetAsync(
string organizationId,
string dataSource,
int? requestStartTime = default,
global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
PrepareGetDataSourceStatusStudioV1ConnectorsConnectedUsersOrganizationIdDataSourcesDataSourceStatusGetArguments(
httpClient: HttpClient,
organizationId: ref organizationId,
dataSource: ref dataSource,
requestStartTime: ref requestStartTime);
dataSource: ref dataSource);

var __pathBuilder = new PathBuilder(
path: $"/studio/v1/connectors/connected-users/{organizationId}/data-sources/{dataSource}/status",
baseUri: HttpClient.BaseAddress);
__pathBuilder
.AddOptionalParameter("request_start_time", requestStartTime?.ToString())
;
var __path = __pathBuilder.ToString();
using var __httpRequest = new global::System.Net.Http.HttpRequestMessage(
method: global::System.Net.Http.HttpMethod.Get,
Expand Down Expand Up @@ -87,8 +77,7 @@ partial void ProcessGetDataSourceStatusStudioV1ConnectorsConnectedUsersOrganizat
httpClient: HttpClient,
httpRequestMessage: __httpRequest,
organizationId: organizationId,
dataSource: dataSource,
requestStartTime: requestStartTime);
dataSource: dataSource);

using var __response = await HttpClient.SendAsync(
request: __httpRequest,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,11 @@ public partial class Ai21Api
{
partial void PrepareGetOrgDataSourcesInfoStudioV1ConnectorsConnectedUsersOrganizationIdDataSourcesGetArguments(
global::System.Net.Http.HttpClient httpClient,
ref string organizationId,
ref int? requestStartTime);
ref string organizationId);
partial void PrepareGetOrgDataSourcesInfoStudioV1ConnectorsConnectedUsersOrganizationIdDataSourcesGetRequest(
global::System.Net.Http.HttpClient httpClient,
global::System.Net.Http.HttpRequestMessage httpRequestMessage,
string organizationId,
int? requestStartTime);
string organizationId);
partial void ProcessGetOrgDataSourcesInfoStudioV1ConnectorsConnectedUsersOrganizationIdDataSourcesGetResponse(
global::System.Net.Http.HttpClient httpClient,
global::System.Net.Http.HttpResponseMessage httpResponseMessage);
Expand All @@ -27,29 +25,21 @@ partial void ProcessGetOrgDataSourcesInfoStudioV1ConnectorsConnectedUsersOrganiz
/// Get Org Data Sources Info
/// </summary>
/// <param name="organizationId"></param>
/// <param name="requestStartTime">
/// Default Value: 1730898900272
/// </param>
/// <param name="cancellationToken">The token to cancel the operation with</param>
/// <exception cref="global::AI21.ApiException"></exception>
public async global::System.Threading.Tasks.Task<global::AI21.ConnectorsDataSources> GetOrgDataSourcesInfoStudioV1ConnectorsConnectedUsersOrganizationIdDataSourcesGetAsync(
string organizationId,
int? requestStartTime = default,
global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
PrepareGetOrgDataSourcesInfoStudioV1ConnectorsConnectedUsersOrganizationIdDataSourcesGetArguments(
httpClient: HttpClient,
organizationId: ref organizationId,
requestStartTime: ref requestStartTime);
organizationId: ref organizationId);

var __pathBuilder = new PathBuilder(
path: $"/studio/v1/connectors/connected-users/{organizationId}/data-sources",
baseUri: HttpClient.BaseAddress);
__pathBuilder
.AddOptionalParameter("request_start_time", requestStartTime?.ToString())
;
var __path = __pathBuilder.ToString();
using var __httpRequest = new global::System.Net.Http.HttpRequestMessage(
method: global::System.Net.Http.HttpMethod.Get,
Expand Down Expand Up @@ -81,8 +71,7 @@ partial void ProcessGetOrgDataSourcesInfoStudioV1ConnectorsConnectedUsersOrganiz
PrepareGetOrgDataSourcesInfoStudioV1ConnectorsConnectedUsersOrganizationIdDataSourcesGetRequest(
httpClient: HttpClient,
httpRequestMessage: __httpRequest,
organizationId: organizationId,
requestStartTime: requestStartTime);
organizationId: organizationId);

using var __response = await HttpClient.SendAsync(
request: __httpRequest,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,13 @@ partial void PrepareRunWorkflowStudioV1ConnectorsConnectedUsersOrganizationIdDat
global::System.Net.Http.HttpClient httpClient,
ref string organizationId,
ref string dataSource,
ref string workflowName,
ref int? requestStartTime);
ref string workflowName);
partial void PrepareRunWorkflowStudioV1ConnectorsConnectedUsersOrganizationIdDataSourcesDataSourceWorkflowsWorkflowNameRunPostRequest(
global::System.Net.Http.HttpClient httpClient,
global::System.Net.Http.HttpRequestMessage httpRequestMessage,
string organizationId,
string dataSource,
string workflowName,
int? requestStartTime);
string workflowName);
partial void ProcessRunWorkflowStudioV1ConnectorsConnectedUsersOrganizationIdDataSourcesDataSourceWorkflowsWorkflowNameRunPostResponse(
global::System.Net.Http.HttpClient httpClient,
global::System.Net.Http.HttpResponseMessage httpResponseMessage);
Expand All @@ -33,16 +31,12 @@ partial void ProcessRunWorkflowStudioV1ConnectorsConnectedUsersOrganizationIdDat
/// <param name="organizationId"></param>
/// <param name="dataSource"></param>
/// <param name="workflowName"></param>
/// <param name="requestStartTime">
/// Default Value: 1730898900272
/// </param>
/// <param name="cancellationToken">The token to cancel the operation with</param>
/// <exception cref="global::AI21.ApiException"></exception>
public async global::System.Threading.Tasks.Task<string> RunWorkflowStudioV1ConnectorsConnectedUsersOrganizationIdDataSourcesDataSourceWorkflowsWorkflowNameRunPostAsync(
string organizationId,
string dataSource,
string workflowName,
int? requestStartTime = default,
global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
Expand All @@ -51,15 +45,11 @@ partial void ProcessRunWorkflowStudioV1ConnectorsConnectedUsersOrganizationIdDat
httpClient: HttpClient,
organizationId: ref organizationId,
dataSource: ref dataSource,
workflowName: ref workflowName,
requestStartTime: ref requestStartTime);
workflowName: ref workflowName);

var __pathBuilder = new PathBuilder(
path: $"/studio/v1/connectors/connected-users/{organizationId}/data-sources/{dataSource}/workflows/{workflowName}/run",
baseUri: HttpClient.BaseAddress);
__pathBuilder
.AddOptionalParameter("request_start_time", requestStartTime?.ToString())
;
var __path = __pathBuilder.ToString();
using var __httpRequest = new global::System.Net.Http.HttpRequestMessage(
method: global::System.Net.Http.HttpMethod.Post,
Expand Down Expand Up @@ -93,8 +83,7 @@ partial void ProcessRunWorkflowStudioV1ConnectorsConnectedUsersOrganizationIdDat
httpRequestMessage: __httpRequest,
organizationId: organizationId,
dataSource: dataSource,
workflowName: workflowName,
requestStartTime: requestStartTime);
workflowName: workflowName);

using var __response = await HttpClient.SendAsync(
request: __httpRequest,
Expand Down
Loading
Loading