diff --git a/src/libs/Opik/Generated/Opik.IOptimizationsClient.CancelStudioOptimizations.g.cs b/src/libs/Opik/Generated/Opik.IOptimizationsClient.CancelStudioOptimizations.g.cs
deleted file mode 100644
index b8b3a60..0000000
--- a/src/libs/Opik/Generated/Opik.IOptimizationsClient.CancelStudioOptimizations.g.cs
+++ /dev/null
@@ -1,32 +0,0 @@
-#nullable enable
-
-namespace Opik
-{
- public partial interface IOptimizationsClient
- {
- ///
- /// Cancel Studio optimizations
- /// Cancel Studio optimizations by id
- ///
- ///
- /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering.
- /// The token to cancel the operation with
- ///
- global::System.Threading.Tasks.Task CancelStudioOptimizationsAsync(
- global::System.Guid id,
- global::Opik.AutoSDKRequestOptions? requestOptions = default,
- global::System.Threading.CancellationToken cancellationToken = default);
- ///
- /// Cancel Studio optimizations
- /// Cancel Studio optimizations by id
- ///
- ///
- /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering.
- /// The token to cancel the operation with
- ///
- global::System.Threading.Tasks.Task CancelStudioOptimizationsAsResponseAsync(
- global::System.Guid id,
- global::Opik.AutoSDKRequestOptions? requestOptions = default,
- global::System.Threading.CancellationToken cancellationToken = default);
- }
-}
\ No newline at end of file
diff --git a/src/libs/Opik/Generated/Opik.IOptimizationsClient.UpdateOptimizationsById.g.cs b/src/libs/Opik/Generated/Opik.IOptimizationsClient.UpdateOptimizationsById.g.cs
index c85af04..b14e244 100644
--- a/src/libs/Opik/Generated/Opik.IOptimizationsClient.UpdateOptimizationsById.g.cs
+++ b/src/libs/Opik/Generated/Opik.IOptimizationsClient.UpdateOptimizationsById.g.cs
@@ -41,6 +41,7 @@ public partial interface IOptimizationsClient
///
///
///
+ ///
/// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering.
/// The token to cancel the operation with
///
@@ -48,6 +49,7 @@ public partial interface IOptimizationsClient
global::System.Guid id,
string? name = default,
global::Opik.OptimizationUpdateStatus? status = default,
+ global::Opik.JsonListString? metadata = default,
global::Opik.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default);
}
diff --git a/src/libs/Opik/Generated/Opik.Models.OptimizationUpdate.g.cs b/src/libs/Opik/Generated/Opik.Models.OptimizationUpdate.g.cs
index 84ade6f..6b00e0f 100644
--- a/src/libs/Opik/Generated/Opik.Models.OptimizationUpdate.g.cs
+++ b/src/libs/Opik/Generated/Opik.Models.OptimizationUpdate.g.cs
@@ -21,6 +21,13 @@ public sealed partial class OptimizationUpdate
[global::System.Text.Json.Serialization.JsonConverter(typeof(global::Opik.JsonConverters.OptimizationUpdateStatusJsonConverter))]
public global::Opik.OptimizationUpdateStatus? Status { get; set; }
+ ///
+ ///
+ ///
+ [global::System.Text.Json.Serialization.JsonPropertyName("metadata")]
+ [global::System.Text.Json.Serialization.JsonConverter(typeof(global::Opik.JsonConverters.JsonListStringJsonConverter))]
+ public global::Opik.JsonListString? Metadata { get; set; }
+
///
/// Additional properties that are not explicitly defined in the schema
///
@@ -32,15 +39,18 @@ public sealed partial class OptimizationUpdate
///
///
///
+ ///
#if NET7_0_OR_GREATER
[global::System.Diagnostics.CodeAnalysis.SetsRequiredMembers]
#endif
public OptimizationUpdate(
string? name,
- global::Opik.OptimizationUpdateStatus? status)
+ global::Opik.OptimizationUpdateStatus? status,
+ global::Opik.JsonListString? metadata)
{
this.Name = name;
this.Status = status;
+ this.Metadata = metadata;
}
///
diff --git a/src/libs/Opik/Generated/Opik.OptimizationsClient.CancelStudioOptimizations.g.cs b/src/libs/Opik/Generated/Opik.OptimizationsClient.CancelStudioOptimizations.g.cs
deleted file mode 100644
index 8e8023f..0000000
--- a/src/libs/Opik/Generated/Opik.OptimizationsClient.CancelStudioOptimizations.g.cs
+++ /dev/null
@@ -1,450 +0,0 @@
-
-#nullable enable
-
-namespace Opik
-{
- public partial class OptimizationsClient
- {
-
- private static readonly global::Opik.AutoSDKServer[] s_CancelStudioOptimizationsServers = new global::Opik.AutoSDKServer[]
- { new global::Opik.AutoSDKServer(
- id: "http-localhost-api",
- name: "Local server",
- url: "http://localhost:5173/api",
- description: "Local server"),
- new global::Opik.AutoSDKServer(
- id: "https-www-comet-com-opik-api",
- name: "Opik Cloud",
- url: "https://www.comet.com/opik/api",
- description: "Opik Cloud"),
- };
-
-
- private static readonly global::Opik.EndPointSecurityRequirement s_CancelStudioOptimizationsSecurityRequirement0 =
- new global::Opik.EndPointSecurityRequirement
- {
- Authorizations = new global::Opik.EndPointAuthorizationRequirement[]
- { new global::Opik.EndPointAuthorizationRequirement
- {
- Type = "Http",
- SchemeId = "HttpBearer",
- Location = "Header",
- Name = "Bearer",
- FriendlyName = "Bearer",
- },
- },
- };
- private static readonly global::Opik.EndPointSecurityRequirement[] s_CancelStudioOptimizationsSecurityRequirements =
- new global::Opik.EndPointSecurityRequirement[]
- { s_CancelStudioOptimizationsSecurityRequirement0,
- };
- partial void PrepareCancelStudioOptimizationsArguments(
- global::System.Net.Http.HttpClient httpClient,
- ref global::System.Guid id);
- partial void PrepareCancelStudioOptimizationsRequest(
- global::System.Net.Http.HttpClient httpClient,
- global::System.Net.Http.HttpRequestMessage httpRequestMessage,
- global::System.Guid id);
- partial void ProcessCancelStudioOptimizationsResponse(
- global::System.Net.Http.HttpClient httpClient,
- global::System.Net.Http.HttpResponseMessage httpResponseMessage);
-
- ///
- /// Cancel Studio optimizations
- /// Cancel Studio optimizations by id
- ///
- ///
- /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering.
- /// The token to cancel the operation with
- ///
- public async global::System.Threading.Tasks.Task CancelStudioOptimizationsAsync(
- global::System.Guid id,
- global::Opik.AutoSDKRequestOptions? requestOptions = default,
- global::System.Threading.CancellationToken cancellationToken = default)
- {
- await CancelStudioOptimizationsAsResponseAsync(
- id: id,
- requestOptions: requestOptions,
- cancellationToken: cancellationToken
- ).ConfigureAwait(false);
- }
- ///
- /// Cancel Studio optimizations
- /// Cancel Studio optimizations by id
- ///
- ///
- /// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering.
- /// The token to cancel the operation with
- ///
- public async global::System.Threading.Tasks.Task CancelStudioOptimizationsAsResponseAsync(
- global::System.Guid id,
- global::Opik.AutoSDKRequestOptions? requestOptions = default,
- global::System.Threading.CancellationToken cancellationToken = default)
- {
- PrepareArguments(
- client: HttpClient);
- PrepareCancelStudioOptimizationsArguments(
- httpClient: HttpClient,
- id: ref id);
-
-
- var __authorizations = global::Opik.EndPointSecurityResolver.ResolveAuthorizations(
- availableAuthorizations: Authorizations,
- securityRequirements: s_CancelStudioOptimizationsSecurityRequirements,
- operationName: "CancelStudioOptimizationsAsync");
-
- using var __timeoutCancellationTokenSource = global::Opik.AutoSDKRequestOptionsSupport.CreateTimeoutCancellationTokenSource(
- clientOptions: Options,
- requestOptions: requestOptions,
- cancellationToken: cancellationToken);
- var __effectiveCancellationToken = __timeoutCancellationTokenSource?.Token ?? cancellationToken;
- var __effectiveReadResponseAsString = global::Opik.AutoSDKRequestOptionsSupport.GetReadResponseAsString(
- clientOptions: Options,
- requestOptions: requestOptions,
- fallbackValue: ReadResponseAsString);
- var __maxAttempts = global::Opik.AutoSDKRequestOptionsSupport.GetMaxAttempts(
- clientOptions: Options,
- requestOptions: requestOptions,
- supportsRetry: true);
-
- global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
- {
-
- var __pathBuilder = new global::Opik.PathBuilder(
- path: $"/v1/private/optimizations/studio/{id}/cancel",
- baseUri: ResolveBaseUri(
- servers: s_CancelStudioOptimizationsServers,
- defaultBaseUrl: "http://localhost:5173/api"));
- var __path = __pathBuilder.ToString();
- __path = global::Opik.AutoSDKRequestOptionsSupport.AppendQueryParameters(
- path: __path,
- clientParameters: Options.QueryParameters,
- requestParameters: requestOptions?.QueryParameters);
- var __httpRequest = new global::System.Net.Http.HttpRequestMessage(
- method: global::System.Net.Http.HttpMethod.Get,
- requestUri: new global::System.Uri(__path, global::System.UriKind.RelativeOrAbsolute));
-#if NET6_0_OR_GREATER
- __httpRequest.Version = global::System.Net.HttpVersion.Version11;
- __httpRequest.VersionPolicy = global::System.Net.Http.HttpVersionPolicy.RequestVersionOrHigher;
-#endif
-
- foreach (var __authorization in __authorizations)
- {
- if (__authorization.Type == "Http" ||
- __authorization.Type == "OAuth2" ||
- __authorization.Type == "OpenIdConnect")
- {
- __httpRequest.Headers.Authorization = new global::System.Net.Http.Headers.AuthenticationHeaderValue(
- scheme: __authorization.Name,
- parameter: __authorization.Value);
- }
- else if (__authorization.Type == "ApiKey" &&
- __authorization.Location == "Header")
- {
- __httpRequest.Headers.Add(__authorization.Name, __authorization.Value);
- }
- }
- global::Opik.AutoSDKRequestOptionsSupport.ApplyHeaders(
- request: __httpRequest,
- clientHeaders: Options.Headers,
- requestHeaders: requestOptions?.Headers);
-
- PrepareRequest(
- client: HttpClient,
- request: __httpRequest);
- PrepareCancelStudioOptimizationsRequest(
- httpClient: HttpClient,
- httpRequestMessage: __httpRequest,
- id: id!);
-
- return __httpRequest;
- }
-
- global::System.Net.Http.HttpRequestMessage? __httpRequest = null;
- global::System.Net.Http.HttpResponseMessage? __response = null;
- var __attemptNumber = 0;
- try
- {
- for (var __attempt = 1; __attempt <= __maxAttempts; __attempt++)
- {
- __attemptNumber = __attempt;
- __httpRequest = __CreateHttpRequest();
- await global::Opik.AutoSDKRequestOptionsSupport.OnBeforeRequestAsync(
- clientOptions: Options,
- context: global::Opik.AutoSDKRequestOptionsSupport.CreateHookContext(
- operationId: "CancelStudioOptimizations",
- methodName: "CancelStudioOptimizationsAsync",
- pathTemplate: "$\"/v1/private/optimizations/studio/{id}/cancel\"",
- httpMethod: "GET",
- baseUri: BaseUri,
- request: __httpRequest!,
- response: null,
- exception: null,
- clientOptions: Options,
- requestOptions: requestOptions,
- attempt: __attempt,
- maxAttempts: __maxAttempts,
- willRetry: false,
- retryDelay: null,
- retryReason: global::System.String.Empty,
- cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
- try
- {
- __response = await HttpClient.SendAsync(
- request: __httpRequest,
- completionOption: global::System.Net.Http.HttpCompletionOption.ResponseContentRead,
- cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
- }
- catch (global::System.Net.Http.HttpRequestException __exception)
- {
- var __retryDelay = global::Opik.AutoSDKRequestOptionsSupport.GetRetryDelay(
- clientOptions: Options,
- requestOptions: requestOptions,
- response: null,
- attempt: __attempt);
- var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
- await global::Opik.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
- clientOptions: Options,
- context: global::Opik.AutoSDKRequestOptionsSupport.CreateHookContext(
- operationId: "CancelStudioOptimizations",
- methodName: "CancelStudioOptimizationsAsync",
- pathTemplate: "$\"/v1/private/optimizations/studio/{id}/cancel\"",
- httpMethod: "GET",
- baseUri: BaseUri,
- request: __httpRequest!,
- response: null,
- exception: __exception,
- clientOptions: Options,
- requestOptions: requestOptions,
- attempt: __attempt,
- maxAttempts: __maxAttempts,
- willRetry: __willRetry,
- retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
- retryReason: "exception",
- cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
- if (!__willRetry)
- {
- throw;
- }
-
- __httpRequest.Dispose();
- __httpRequest = null;
- await global::Opik.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- retryDelay: __retryDelay,
- cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
- continue;
- }
-
- if (__response != null &&
- __attempt < __maxAttempts &&
- global::Opik.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
- {
- var __retryDelay = global::Opik.AutoSDKRequestOptionsSupport.GetRetryDelay(
- clientOptions: Options,
- requestOptions: requestOptions,
- response: __response,
- attempt: __attempt);
- await global::Opik.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
- clientOptions: Options,
- context: global::Opik.AutoSDKRequestOptionsSupport.CreateHookContext(
- operationId: "CancelStudioOptimizations",
- methodName: "CancelStudioOptimizationsAsync",
- pathTemplate: "$\"/v1/private/optimizations/studio/{id}/cancel\"",
- httpMethod: "GET",
- baseUri: BaseUri,
- request: __httpRequest!,
- response: __response,
- exception: null,
- clientOptions: Options,
- requestOptions: requestOptions,
- attempt: __attempt,
- maxAttempts: __maxAttempts,
- willRetry: true,
- retryDelay: __retryDelay,
- retryReason: "status:" + ((int)__response.StatusCode).ToString(global::System.Globalization.CultureInfo.InvariantCulture),
- cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
- __response.Dispose();
- __response = null;
- __httpRequest.Dispose();
- __httpRequest = null;
- await global::Opik.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- retryDelay: __retryDelay,
- cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
- continue;
- }
-
- break;
- }
-
- if (__response == null)
- {
- throw new global::System.InvalidOperationException("No response received.");
- }
-
- using (__response)
- {
-
- ProcessResponse(
- client: HttpClient,
- response: __response);
- ProcessCancelStudioOptimizationsResponse(
- httpClient: HttpClient,
- httpResponseMessage: __response);
- if (__response.IsSuccessStatusCode)
- {
- await global::Opik.AutoSDKRequestOptionsSupport.OnAfterSuccessAsync(
- clientOptions: Options,
- context: global::Opik.AutoSDKRequestOptionsSupport.CreateHookContext(
- operationId: "CancelStudioOptimizations",
- methodName: "CancelStudioOptimizationsAsync",
- pathTemplate: "$\"/v1/private/optimizations/studio/{id}/cancel\"",
- httpMethod: "GET",
- baseUri: BaseUri,
- request: __httpRequest!,
- response: __response,
- exception: null,
- clientOptions: Options,
- requestOptions: requestOptions,
- attempt: __attemptNumber,
- maxAttempts: __maxAttempts,
- willRetry: false,
- retryDelay: null,
- retryReason: global::System.String.Empty,
- cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
- }
- else
- {
- await global::Opik.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
- clientOptions: Options,
- context: global::Opik.AutoSDKRequestOptionsSupport.CreateHookContext(
- operationId: "CancelStudioOptimizations",
- methodName: "CancelStudioOptimizationsAsync",
- pathTemplate: "$\"/v1/private/optimizations/studio/{id}/cancel\"",
- httpMethod: "GET",
- baseUri: BaseUri,
- request: __httpRequest!,
- response: __response,
- exception: null,
- clientOptions: Options,
- requestOptions: requestOptions,
- attempt: __attemptNumber,
- maxAttempts: __maxAttempts,
- willRetry: false,
- retryDelay: null,
- retryReason: global::System.String.Empty,
- cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
- }
- //
- if ((int)__response.StatusCode == 501)
- {
- string? __content_501 = null;
- global::System.Exception? __exception_501 = null;
- try
- {
- if (__effectiveReadResponseAsString)
- {
- __content_501 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false);
- }
- else
- {
- __content_501 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false);
- }
- }
- catch (global::System.Exception __ex)
- {
- __exception_501 = __ex;
- }
-
-
- throw global::Opik.ApiException.Create(
- statusCode: __response.StatusCode,
- message: __content_501 ?? __response.ReasonPhrase ?? string.Empty,
- innerException: __exception_501,
- responseBody: __content_501,
- responseHeaders: global::System.Linq.Enumerable.ToDictionary(
- __response.Headers,
- h => h.Key,
- h => h.Value));
- }
-
- if (__effectiveReadResponseAsString)
- {
- var __content = await __response.Content.ReadAsStringAsync(
- #if NET5_0_OR_GREATER
- __effectiveCancellationToken
- #endif
- ).ConfigureAwait(false);
-
- ProcessResponseContent(
- client: HttpClient,
- response: __response,
- content: ref __content);
-
- try
- {
- __response.EnsureSuccessStatusCode();
-
- return new global::Opik.AutoSDKHttpResponse(
- statusCode: __response.StatusCode,
- headers: global::Opik.AutoSDKHttpResponse.CreateHeaders(__response),
- requestUri: __response.RequestMessage?.RequestUri);
- }
- catch (global::System.Exception __ex)
- {
- throw global::Opik.ApiException.Create(
- statusCode: __response.StatusCode,
- message: __content ?? __response.ReasonPhrase ?? string.Empty,
- innerException: __ex,
- responseBody: __content,
- responseHeaders: global::System.Linq.Enumerable.ToDictionary(
- __response.Headers,
- h => h.Key,
- h => h.Value));
- }
- }
- else
- {
- try
- {
- __response.EnsureSuccessStatusCode();
- return new global::Opik.AutoSDKHttpResponse(
- statusCode: __response.StatusCode,
- headers: global::Opik.AutoSDKHttpResponse.CreateHeaders(__response),
- requestUri: __response.RequestMessage?.RequestUri);
- }
- catch (global::System.Exception __ex)
- {
- string? __content = null;
- try
- {
- __content = await __response.Content.ReadAsStringAsync(
- #if NET5_0_OR_GREATER
- __effectiveCancellationToken
- #endif
- ).ConfigureAwait(false);
- }
- catch (global::System.Exception)
- {
- }
-
- throw global::Opik.ApiException.Create(
- statusCode: __response.StatusCode,
- message: __content ?? __response.ReasonPhrase ?? string.Empty,
- innerException: __ex,
- responseBody: __content,
- responseHeaders: global::System.Linq.Enumerable.ToDictionary(
- __response.Headers,
- h => h.Key,
- h => h.Value));
- }
- }
-
- }
- }
- finally
- {
- __httpRequest?.Dispose();
- }
- }
- }
-}
\ No newline at end of file
diff --git a/src/libs/Opik/Generated/Opik.OptimizationsClient.UpdateOptimizationsById.g.cs b/src/libs/Opik/Generated/Opik.OptimizationsClient.UpdateOptimizationsById.g.cs
index 4e1f615..366421c 100644
--- a/src/libs/Opik/Generated/Opik.OptimizationsClient.UpdateOptimizationsById.g.cs
+++ b/src/libs/Opik/Generated/Opik.OptimizationsClient.UpdateOptimizationsById.g.cs
@@ -441,6 +441,7 @@ await UpdateOptimizationsByIdAsResponseAsync(
///
///
///
+ ///
/// Per-request overrides such as headers, query parameters, timeout, retries, and response buffering.
/// The token to cancel the operation with
///
@@ -448,6 +449,7 @@ await UpdateOptimizationsByIdAsResponseAsync(
global::System.Guid id,
string? name = default,
global::Opik.OptimizationUpdateStatus? status = default,
+ global::Opik.JsonListString? metadata = default,
global::Opik.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
{
@@ -455,6 +457,7 @@ await UpdateOptimizationsByIdAsResponseAsync(
{
Name = name,
Status = status,
+ Metadata = metadata,
};
await UpdateOptimizationsByIdAsync(
diff --git a/src/libs/Opik/openapi.yaml b/src/libs/Opik/openapi.yaml
index d677d8c..2a4cf8b 100644
--- a/src/libs/Opik/openapi.yaml
+++ b/src/libs/Opik/openapi.yaml
@@ -5515,23 +5515,6 @@ paths:
description: default response
content:
'*/*': {}
- /v1/private/optimizations/studio/{id}/cancel:
- get:
- tags:
- - Optimizations
- summary: Cancel Studio optimizations
- description: Cancel Studio optimizations by id
- operationId: cancelStudioOptimizations
- parameters:
- - name: id
- in: path
- required: true
- schema:
- type: string
- format: uuid
- responses:
- "501":
- description: Not Implemented
/v1/private/optimizations:
get:
tags:
@@ -19213,6 +19196,8 @@ components:
- cancelled
- initialized
- error
+ metadata:
+ $ref: "#/components/schemas/JsonListString"
ActivateRequest:
required:
- hmac