Skip to content

Commit

Permalink
Merge pull request #54 from tryAGI/bot/update-openapi_202409200321
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] authored Sep 20, 2024
2 parents db87da6 + 9ff0d20 commit 4d0c842
Show file tree
Hide file tree
Showing 37 changed files with 454 additions and 39 deletions.
6 changes: 5 additions & 1 deletion src/libs/Cohere/Generated/Cohere.CohereApi.Chat.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,13 @@ partial void ProcessChatResponseContent(
accepts: ref accepts,
request: request);

var __pathBuilder = new PathBuilder(
path: "/v1/chat",
baseUri: _httpClient.BaseAddress);
var __path = __pathBuilder.ToString();
using var httpRequest = new global::System.Net.Http.HttpRequestMessage(
method: global::System.Net.Http.HttpMethod.Post,
requestUri: new global::System.Uri(_httpClient.BaseAddress?.AbsoluteUri.TrimEnd('/') + "/v1/chat", global::System.UriKind.RelativeOrAbsolute));
requestUri: new global::System.Uri(__path, global::System.UriKind.RelativeOrAbsolute));
var __httpRequestContentBody = global::System.Text.Json.JsonSerializer.Serialize(request, request.GetType(), JsonSerializerContext);
var __httpRequestContent = new global::System.Net.Http.StringContent(
content: __httpRequestContentBody,
Expand Down
6 changes: 5 additions & 1 deletion src/libs/Cohere/Generated/Cohere.CohereApi.Chatv2.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,13 @@ partial void ProcessChatv2ResponseContent(
httpClient: _httpClient,
request: request);

var __pathBuilder = new PathBuilder(
path: "/v2/chat",
baseUri: _httpClient.BaseAddress);
var __path = __pathBuilder.ToString();
using var httpRequest = new global::System.Net.Http.HttpRequestMessage(
method: global::System.Net.Http.HttpMethod.Post,
requestUri: new global::System.Uri(_httpClient.BaseAddress?.AbsoluteUri.TrimEnd('/') + "/v2/chat", global::System.UriKind.RelativeOrAbsolute));
requestUri: new global::System.Uri(__path, global::System.UriKind.RelativeOrAbsolute));
var __httpRequestContentBody = global::System.Text.Json.JsonSerializer.Serialize(request, request.GetType(), JsonSerializerContext);
var __httpRequestContent = new global::System.Net.Http.StringContent(
content: __httpRequestContentBody,
Expand Down
6 changes: 5 additions & 1 deletion src/libs/Cohere/Generated/Cohere.CohereApi.CheckAPIKey.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,13 @@ partial void ProcessCheckAPIKeyResponseContent(
httpClient: _httpClient,
xClientName: ref xClientName);

var __pathBuilder = new PathBuilder(
path: "/v1/check-api-key",
baseUri: _httpClient.BaseAddress);
var __path = __pathBuilder.ToString();
using var httpRequest = new global::System.Net.Http.HttpRequestMessage(
method: global::System.Net.Http.HttpMethod.Post,
requestUri: new global::System.Uri(_httpClient.BaseAddress?.AbsoluteUri.TrimEnd('/') + "/v1/check-api-key", global::System.UriKind.RelativeOrAbsolute));
requestUri: new global::System.Uri(__path, global::System.UriKind.RelativeOrAbsolute));

PrepareRequest(
client: _httpClient,
Expand Down
6 changes: 5 additions & 1 deletion src/libs/Cohere/Generated/Cohere.CohereApi.Classify.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,13 @@ partial void ProcessClassifyResponseContent(
xClientName: ref xClientName,
request: request);

var __pathBuilder = new PathBuilder(
path: "/v1/classify",
baseUri: _httpClient.BaseAddress);
var __path = __pathBuilder.ToString();
using var httpRequest = new global::System.Net.Http.HttpRequestMessage(
method: global::System.Net.Http.HttpMethod.Post,
requestUri: new global::System.Uri(_httpClient.BaseAddress?.AbsoluteUri.TrimEnd('/') + "/v1/classify", global::System.UriKind.RelativeOrAbsolute));
requestUri: new global::System.Uri(__path, global::System.UriKind.RelativeOrAbsolute));
var __httpRequestContentBody = global::System.Text.Json.JsonSerializer.Serialize(request, request.GetType(), JsonSerializerContext);
var __httpRequestContent = new global::System.Net.Http.StringContent(
content: __httpRequestContentBody,
Expand Down
6 changes: 5 additions & 1 deletion src/libs/Cohere/Generated/Cohere.CohereApi.Detokenize.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,13 @@ partial void ProcessDetokenizeResponseContent(
xClientName: ref xClientName,
request: request);

var __pathBuilder = new PathBuilder(
path: "/v1/detokenize",
baseUri: _httpClient.BaseAddress);
var __path = __pathBuilder.ToString();
using var httpRequest = new global::System.Net.Http.HttpRequestMessage(
method: global::System.Net.Http.HttpMethod.Post,
requestUri: new global::System.Uri(_httpClient.BaseAddress?.AbsoluteUri.TrimEnd('/') + "/v1/detokenize", global::System.UriKind.RelativeOrAbsolute));
requestUri: new global::System.Uri(__path, global::System.UriKind.RelativeOrAbsolute));
var __httpRequestContentBody = global::System.Text.Json.JsonSerializer.Serialize(request, request.GetType(), JsonSerializerContext);
var __httpRequestContent = new global::System.Net.Http.StringContent(
content: __httpRequestContentBody,
Expand Down
6 changes: 5 additions & 1 deletion src/libs/Cohere/Generated/Cohere.CohereApi.Embed.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,13 @@ partial void ProcessEmbedResponseContent(
xClientName: ref xClientName,
request: request);

var __pathBuilder = new PathBuilder(
path: "/v1/embed",
baseUri: _httpClient.BaseAddress);
var __path = __pathBuilder.ToString();
using var httpRequest = new global::System.Net.Http.HttpRequestMessage(
method: global::System.Net.Http.HttpMethod.Post,
requestUri: new global::System.Uri(_httpClient.BaseAddress?.AbsoluteUri.TrimEnd('/') + "/v1/embed", global::System.UriKind.RelativeOrAbsolute));
requestUri: new global::System.Uri(__path, global::System.UriKind.RelativeOrAbsolute));
var __httpRequestContentBody = global::System.Text.Json.JsonSerializer.Serialize(request, request.GetType(), JsonSerializerContext);
var __httpRequestContent = new global::System.Net.Http.StringContent(
content: __httpRequestContentBody,
Expand Down
6 changes: 5 additions & 1 deletion src/libs/Cohere/Generated/Cohere.CohereApi.Embedv2.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,13 @@ partial void ProcessEmbedv2ResponseContent(
xClientName: ref xClientName,
request: request);

var __pathBuilder = new PathBuilder(
path: "/v2/embed",
baseUri: _httpClient.BaseAddress);
var __path = __pathBuilder.ToString();
using var httpRequest = new global::System.Net.Http.HttpRequestMessage(
method: global::System.Net.Http.HttpMethod.Post,
requestUri: new global::System.Uri(_httpClient.BaseAddress?.AbsoluteUri.TrimEnd('/') + "/v2/embed", global::System.UriKind.RelativeOrAbsolute));
requestUri: new global::System.Uri(__path, global::System.UriKind.RelativeOrAbsolute));
var __httpRequestContentBody = global::System.Text.Json.JsonSerializer.Serialize(request, request.GetType(), JsonSerializerContext);
var __httpRequestContent = new global::System.Net.Http.StringContent(
content: __httpRequestContentBody,
Expand Down
6 changes: 5 additions & 1 deletion src/libs/Cohere/Generated/Cohere.CohereApi.Generate.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,13 @@ partial void ProcessGenerateResponseContent(
xClientName: ref xClientName,
request: request);

var __pathBuilder = new PathBuilder(
path: "/v1/generate",
baseUri: _httpClient.BaseAddress);
var __path = __pathBuilder.ToString();
using var httpRequest = new global::System.Net.Http.HttpRequestMessage(
method: global::System.Net.Http.HttpMethod.Post,
requestUri: new global::System.Uri(_httpClient.BaseAddress?.AbsoluteUri.TrimEnd('/') + "/v1/generate", global::System.UriKind.RelativeOrAbsolute));
requestUri: new global::System.Uri(__path, global::System.UriKind.RelativeOrAbsolute));
var __httpRequestContentBody = global::System.Text.Json.JsonSerializer.Serialize(request, request.GetType(), JsonSerializerContext);
var __httpRequestContent = new global::System.Net.Http.StringContent(
content: __httpRequestContentBody,
Expand Down
6 changes: 5 additions & 1 deletion src/libs/Cohere/Generated/Cohere.CohereApi.Rerank.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,13 @@ partial void ProcessRerankResponseContent(
xClientName: ref xClientName,
request: request);

var __pathBuilder = new PathBuilder(
path: "/v1/rerank",
baseUri: _httpClient.BaseAddress);
var __path = __pathBuilder.ToString();
using var httpRequest = new global::System.Net.Http.HttpRequestMessage(
method: global::System.Net.Http.HttpMethod.Post,
requestUri: new global::System.Uri(_httpClient.BaseAddress?.AbsoluteUri.TrimEnd('/') + "/v1/rerank", global::System.UriKind.RelativeOrAbsolute));
requestUri: new global::System.Uri(__path, global::System.UriKind.RelativeOrAbsolute));
var __httpRequestContentBody = global::System.Text.Json.JsonSerializer.Serialize(request, request.GetType(), JsonSerializerContext);
var __httpRequestContent = new global::System.Net.Http.StringContent(
content: __httpRequestContentBody,
Expand Down
6 changes: 5 additions & 1 deletion src/libs/Cohere/Generated/Cohere.CohereApi.Rerankv2.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,13 @@ partial void ProcessRerankv2ResponseContent(
xClientName: ref xClientName,
request: request);

var __pathBuilder = new PathBuilder(
path: "/v2/rerank",
baseUri: _httpClient.BaseAddress);
var __path = __pathBuilder.ToString();
using var httpRequest = new global::System.Net.Http.HttpRequestMessage(
method: global::System.Net.Http.HttpMethod.Post,
requestUri: new global::System.Uri(_httpClient.BaseAddress?.AbsoluteUri.TrimEnd('/') + "/v2/rerank", global::System.UriKind.RelativeOrAbsolute));
requestUri: new global::System.Uri(__path, global::System.UriKind.RelativeOrAbsolute));
var __httpRequestContentBody = global::System.Text.Json.JsonSerializer.Serialize(request, request.GetType(), JsonSerializerContext);
var __httpRequestContent = new global::System.Net.Http.StringContent(
content: __httpRequestContentBody,
Expand Down
6 changes: 5 additions & 1 deletion src/libs/Cohere/Generated/Cohere.CohereApi.Summarize.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,13 @@ partial void ProcessSummarizeResponseContent(
xClientName: ref xClientName,
request: request);

var __pathBuilder = new PathBuilder(
path: "/v1/summarize",
baseUri: _httpClient.BaseAddress);
var __path = __pathBuilder.ToString();
using var httpRequest = new global::System.Net.Http.HttpRequestMessage(
method: global::System.Net.Http.HttpMethod.Post,
requestUri: new global::System.Uri(_httpClient.BaseAddress?.AbsoluteUri.TrimEnd('/') + "/v1/summarize", global::System.UriKind.RelativeOrAbsolute));
requestUri: new global::System.Uri(__path, global::System.UriKind.RelativeOrAbsolute));
var __httpRequestContentBody = global::System.Text.Json.JsonSerializer.Serialize(request, request.GetType(), JsonSerializerContext);
var __httpRequestContent = new global::System.Net.Http.StringContent(
content: __httpRequestContentBody,
Expand Down
6 changes: 5 additions & 1 deletion src/libs/Cohere/Generated/Cohere.CohereApi.Tokenize.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,13 @@ partial void ProcessTokenizeResponseContent(
xClientName: ref xClientName,
request: request);

var __pathBuilder = new PathBuilder(
path: "/v1/tokenize",
baseUri: _httpClient.BaseAddress);
var __path = __pathBuilder.ToString();
using var httpRequest = new global::System.Net.Http.HttpRequestMessage(
method: global::System.Net.Http.HttpMethod.Post,
requestUri: new global::System.Uri(_httpClient.BaseAddress?.AbsoluteUri.TrimEnd('/') + "/v1/tokenize", global::System.UriKind.RelativeOrAbsolute));
requestUri: new global::System.Uri(__path, global::System.UriKind.RelativeOrAbsolute));
var __httpRequestContentBody = global::System.Text.Json.JsonSerializer.Serialize(request, request.GetType(), JsonSerializerContext);
var __httpRequestContent = new global::System.Net.Http.StringContent(
content: __httpRequestContentBody,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,13 @@ partial void ProcessCreateConnectorResponseContent(
xClientName: ref xClientName,
request: request);

var __pathBuilder = new PathBuilder(
path: "/v1/connectors",
baseUri: _httpClient.BaseAddress);
var __path = __pathBuilder.ToString();
using var httpRequest = new global::System.Net.Http.HttpRequestMessage(
method: global::System.Net.Http.HttpMethod.Post,
requestUri: new global::System.Uri(_httpClient.BaseAddress?.AbsoluteUri.TrimEnd('/') + "/v1/connectors", global::System.UriKind.RelativeOrAbsolute));
requestUri: new global::System.Uri(__path, global::System.UriKind.RelativeOrAbsolute));
var __httpRequestContentBody = global::System.Text.Json.JsonSerializer.Serialize(request, request.GetType(), JsonSerializerContext);
var __httpRequestContent = new global::System.Net.Http.StringContent(
content: __httpRequestContentBody,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,13 @@ partial void ProcessDeleteConnectorResponseContent(
id: ref id,
xClientName: ref xClientName);

var __pathBuilder = new PathBuilder(
path: $"/v1/connectors/{id}",
baseUri: _httpClient.BaseAddress);
var __path = __pathBuilder.ToString();
using var httpRequest = new global::System.Net.Http.HttpRequestMessage(
method: global::System.Net.Http.HttpMethod.Delete,
requestUri: new global::System.Uri(_httpClient.BaseAddress?.AbsoluteUri.TrimEnd('/') + $"/v1/connectors/{id}", global::System.UriKind.RelativeOrAbsolute));
requestUri: new global::System.Uri(__path, global::System.UriKind.RelativeOrAbsolute));

PrepareRequest(
client: _httpClient,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,13 @@ partial void ProcessGetConnectorResponseContent(
id: ref id,
xClientName: ref xClientName);

var __pathBuilder = new PathBuilder(
path: $"/v1/connectors/{id}",
baseUri: _httpClient.BaseAddress);
var __path = __pathBuilder.ToString();
using var httpRequest = new global::System.Net.Http.HttpRequestMessage(
method: global::System.Net.Http.HttpMethod.Get,
requestUri: new global::System.Uri(_httpClient.BaseAddress?.AbsoluteUri.TrimEnd('/') + $"/v1/connectors/{id}", global::System.UriKind.RelativeOrAbsolute));
requestUri: new global::System.Uri(__path, global::System.UriKind.RelativeOrAbsolute));

PrepareRequest(
client: _httpClient,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,9 +52,17 @@ partial void ProcessListConnectorsResponseContent(
offset: ref offset,
xClientName: ref xClientName);

var __pathBuilder = new PathBuilder(
path: "/v1/connectors",
baseUri: _httpClient.BaseAddress);
__pathBuilder
.AddOptionalParameter("limit", limit?.ToString())
.AddOptionalParameter("offset", offset?.ToString())
;
var __path = __pathBuilder.ToString();
using var httpRequest = new global::System.Net.Http.HttpRequestMessage(
method: global::System.Net.Http.HttpMethod.Get,
requestUri: new global::System.Uri(_httpClient.BaseAddress?.AbsoluteUri.TrimEnd('/') + $"/v1/connectors?limit={limit}&offset={offset}", global::System.UriKind.RelativeOrAbsolute));
requestUri: new global::System.Uri(__path, global::System.UriKind.RelativeOrAbsolute));

PrepareRequest(
client: _httpClient,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,16 @@ partial void ProcessOAuthAuthorizeConnectorResponseContent(
afterTokenRedirect: ref afterTokenRedirect,
xClientName: ref xClientName);

var __pathBuilder = new PathBuilder(
path: $"/v1/connectors/{id}/oauth/authorize",
baseUri: _httpClient.BaseAddress);
__pathBuilder
.AddOptionalParameter("after_token_redirect", afterTokenRedirect)
;
var __path = __pathBuilder.ToString();
using var httpRequest = new global::System.Net.Http.HttpRequestMessage(
method: global::System.Net.Http.HttpMethod.Post,
requestUri: new global::System.Uri(_httpClient.BaseAddress?.AbsoluteUri.TrimEnd('/') + $"/v1/connectors/{id}/oauth/authorize?after_token_redirect={afterTokenRedirect}", global::System.UriKind.RelativeOrAbsolute));
requestUri: new global::System.Uri(__path, global::System.UriKind.RelativeOrAbsolute));

PrepareRequest(
client: _httpClient,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,13 @@ partial void ProcessUpdateConnectorResponseContent(
xClientName: ref xClientName,
request: request);

var __pathBuilder = new PathBuilder(
path: $"/v1/connectors/{id}",
baseUri: _httpClient.BaseAddress);
var __path = __pathBuilder.ToString();
using var httpRequest = new global::System.Net.Http.HttpRequestMessage(
method: new global::System.Net.Http.HttpMethod("PATCH"),
requestUri: new global::System.Uri(_httpClient.BaseAddress?.AbsoluteUri.TrimEnd('/') + $"/v1/connectors/{id}", global::System.UriKind.RelativeOrAbsolute));
requestUri: new global::System.Uri(__path, global::System.UriKind.RelativeOrAbsolute));
var __httpRequestContentBody = global::System.Text.Json.JsonSerializer.Serialize(request, request.GetType(), JsonSerializerContext);
var __httpRequestContent = new global::System.Net.Http.StringContent(
content: __httpRequestContentBody,
Expand Down
Loading

0 comments on commit 4d0c842

Please sign in to comment.