diff --git a/src/libs/Presenton/Generated/Presenton.AuthClient.AuthJwtLoginApiV1AuthJwtLoginPost.g.cs b/src/libs/Presenton/Generated/Presenton.AuthClient.AuthJwtLoginApiV1AuthJwtLoginPost.g.cs
index ecaa2d0..a6f7811 100644
--- a/src/libs/Presenton/Generated/Presenton.AuthClient.AuthJwtLoginApiV1AuthJwtLoginPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.AuthClient.AuthJwtLoginApiV1AuthJwtLoginPost.g.cs
@@ -50,6 +50,28 @@ partial void ProcessAuthJwtLoginApiV1AuthJwtLoginPostResponseContent(
///
public async global::System.Threading.Tasks.Task AuthJwtLoginApiV1AuthJwtLoginPostAsync(
+ global::Presenton.BodyAuthJwtLoginApiV1AuthJwtLoginPost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await AuthJwtLoginApiV1AuthJwtLoginPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Auth:Jwt.Login
+ ///
+ ///
+ /// 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> AuthJwtLoginApiV1AuthJwtLoginPostAsResponseAsync(
+
global::Presenton.BodyAuthJwtLoginApiV1AuthJwtLoginPost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -84,6 +106,7 @@ partial void ProcessAuthJwtLoginApiV1AuthJwtLoginPostResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/auth/jwt/login",
baseUri: HttpClient.BaseAddress);
@@ -163,6 +186,8 @@ partial void ProcessAuthJwtLoginApiV1AuthJwtLoginPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -173,6 +198,11 @@ partial void ProcessAuthJwtLoginApiV1AuthJwtLoginPostResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -190,6 +220,8 @@ partial void ProcessAuthJwtLoginApiV1AuthJwtLoginPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -199,8 +231,7 @@ partial void ProcessAuthJwtLoginApiV1AuthJwtLoginPostResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -209,6 +240,11 @@ partial void ProcessAuthJwtLoginApiV1AuthJwtLoginPostResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -225,14 +261,15 @@ partial void ProcessAuthJwtLoginApiV1AuthJwtLoginPostResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -272,6 +309,8 @@ partial void ProcessAuthJwtLoginApiV1AuthJwtLoginPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -292,6 +331,8 @@ partial void ProcessAuthJwtLoginApiV1AuthJwtLoginPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Bad Request
@@ -392,9 +433,13 @@ partial void ProcessAuthJwtLoginApiV1AuthJwtLoginPostResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.BearerResponse.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.BearerResponse.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -422,9 +467,13 @@ partial void ProcessAuthJwtLoginApiV1AuthJwtLoginPostResponseContent(
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.BearerResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.BearerResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.AuthClient.AuthJwtLogoutApiV1AuthJwtLogoutPost.g.cs b/src/libs/Presenton/Generated/Presenton.AuthClient.AuthJwtLogoutApiV1AuthJwtLogoutPost.g.cs
index 401eb77..2113532 100644
--- a/src/libs/Presenton/Generated/Presenton.AuthClient.AuthJwtLogoutApiV1AuthJwtLogoutPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.AuthClient.AuthJwtLogoutApiV1AuthJwtLogoutPost.g.cs
@@ -48,6 +48,23 @@ partial void ProcessAuthJwtLogoutApiV1AuthJwtLogoutPostResponseContent(
public async global::System.Threading.Tasks.Task AuthJwtLogoutApiV1AuthJwtLogoutPostAsync(
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await AuthJwtLogoutApiV1AuthJwtLogoutPostAsResponseAsync(
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Auth:Jwt.Logout
+ ///
+ /// 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> AuthJwtLogoutApiV1AuthJwtLogoutPostAsResponseAsync(
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
@@ -76,6 +93,7 @@ partial void ProcessAuthJwtLogoutApiV1AuthJwtLogoutPostResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/auth/jwt/logout",
baseUri: HttpClient.BaseAddress);
@@ -148,6 +166,8 @@ partial void ProcessAuthJwtLogoutApiV1AuthJwtLogoutPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -158,6 +178,11 @@ partial void ProcessAuthJwtLogoutApiV1AuthJwtLogoutPostResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -175,6 +200,8 @@ partial void ProcessAuthJwtLogoutApiV1AuthJwtLogoutPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -184,8 +211,7 @@ partial void ProcessAuthJwtLogoutApiV1AuthJwtLogoutPostResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -194,6 +220,11 @@ partial void ProcessAuthJwtLogoutApiV1AuthJwtLogoutPostResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -210,14 +241,15 @@ partial void ProcessAuthJwtLogoutApiV1AuthJwtLogoutPostResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -257,6 +289,8 @@ partial void ProcessAuthJwtLogoutApiV1AuthJwtLogoutPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -277,6 +311,8 @@ partial void ProcessAuthJwtLogoutApiV1AuthJwtLogoutPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
//
@@ -334,7 +370,11 @@ partial void ProcessAuthJwtLogoutApiV1AuthJwtLogoutPostResponseContent(
{
__response.EnsureSuccessStatusCode();
- return __content;
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __content);
}
catch (global::System.Exception __ex)
{
@@ -362,7 +402,11 @@ partial void ProcessAuthJwtLogoutApiV1AuthJwtLogoutPostResponseContent(
#endif
).ConfigureAwait(false);
- return __content;
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __content);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.AuthClient.AuthorizeApiV1AuthGoogleAuthorizeGet.g.cs b/src/libs/Presenton/Generated/Presenton.AuthClient.AuthorizeApiV1AuthGoogleAuthorizeGet.g.cs
index f44f8fe..37f51c2 100644
--- a/src/libs/Presenton/Generated/Presenton.AuthClient.AuthorizeApiV1AuthGoogleAuthorizeGet.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.AuthClient.AuthorizeApiV1AuthGoogleAuthorizeGet.g.cs
@@ -52,6 +52,26 @@ partial void ProcessAuthorizeApiV1AuthGoogleAuthorizeGetResponseContent(
global::System.Collections.Generic.IList? scopes = default,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await AuthorizeApiV1AuthGoogleAuthorizeGetAsResponseAsync(
+ scopes: scopes,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Authorize
+ ///
+ ///
+ /// 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> AuthorizeApiV1AuthGoogleAuthorizeGetAsResponseAsync(
+ global::System.Collections.Generic.IList? scopes = default,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
@@ -81,11 +101,12 @@ partial void ProcessAuthorizeApiV1AuthGoogleAuthorizeGetResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/auth/google/authorize",
- baseUri: HttpClient.BaseAddress);
+ baseUri: HttpClient.BaseAddress);
__pathBuilder
- .AddOptionalParameter("scopes", scopes, delimiter: ",", explode: true)
+ .AddOptionalParameter("scopes", scopes, delimiter: ",", explode: true)
;
var __path = __pathBuilder.ToString();
__path = global::Presenton.AutoSDKRequestOptionsSupport.AppendQueryParameters(
@@ -157,6 +178,8 @@ partial void ProcessAuthorizeApiV1AuthGoogleAuthorizeGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -167,6 +190,11 @@ partial void ProcessAuthorizeApiV1AuthGoogleAuthorizeGetResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -184,6 +212,8 @@ partial void ProcessAuthorizeApiV1AuthGoogleAuthorizeGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -193,8 +223,7 @@ partial void ProcessAuthorizeApiV1AuthGoogleAuthorizeGetResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -203,6 +232,11 @@ partial void ProcessAuthorizeApiV1AuthGoogleAuthorizeGetResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -219,14 +253,15 @@ partial void ProcessAuthorizeApiV1AuthGoogleAuthorizeGetResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -266,6 +301,8 @@ partial void ProcessAuthorizeApiV1AuthGoogleAuthorizeGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -286,6 +323,8 @@ partial void ProcessAuthorizeApiV1AuthGoogleAuthorizeGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -348,9 +387,13 @@ partial void ProcessAuthorizeApiV1AuthGoogleAuthorizeGetResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.OAuth2AuthorizeResponse.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.OAuth2AuthorizeResponse.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -378,9 +421,13 @@ partial void ProcessAuthorizeApiV1AuthGoogleAuthorizeGetResponseContent(
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.OAuth2AuthorizeResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.OAuth2AuthorizeResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.AuthClient.CallbackApiV1AuthGoogleCallbackGet.g.cs b/src/libs/Presenton/Generated/Presenton.AuthClient.CallbackApiV1AuthGoogleCallbackGet.g.cs
index 467bf57..e7b0ff1 100644
--- a/src/libs/Presenton/Generated/Presenton.AuthClient.CallbackApiV1AuthGoogleCallbackGet.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.AuthClient.CallbackApiV1AuthGoogleCallbackGet.g.cs
@@ -61,6 +61,33 @@ partial void ProcessCallbackApiV1AuthGoogleCallbackGetResponseContent(
string? error = default,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await CallbackApiV1AuthGoogleCallbackGetAsResponseAsync(
+ code: code,
+ state: state,
+ error: error,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Callback
+ /// The response varies based on the authentication backend used.
+ ///
+ ///
+ ///
+ ///
+ /// 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> CallbackApiV1AuthGoogleCallbackGetAsResponseAsync(
+ string? code = default,
+ string? state = default,
+ string? error = default,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
@@ -92,13 +119,14 @@ partial void ProcessCallbackApiV1AuthGoogleCallbackGetResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/auth/google/callback",
- baseUri: HttpClient.BaseAddress);
+ baseUri: HttpClient.BaseAddress);
__pathBuilder
.AddOptionalParameter("code", code)
.AddOptionalParameter("state", state)
- .AddOptionalParameter("error", error)
+ .AddOptionalParameter("error", error)
;
var __path = __pathBuilder.ToString();
__path = global::Presenton.AutoSDKRequestOptionsSupport.AppendQueryParameters(
@@ -172,6 +200,8 @@ partial void ProcessCallbackApiV1AuthGoogleCallbackGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -182,6 +212,11 @@ partial void ProcessCallbackApiV1AuthGoogleCallbackGetResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -199,6 +234,8 @@ partial void ProcessCallbackApiV1AuthGoogleCallbackGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -208,8 +245,7 @@ partial void ProcessCallbackApiV1AuthGoogleCallbackGetResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -218,6 +254,11 @@ partial void ProcessCallbackApiV1AuthGoogleCallbackGetResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -234,14 +275,15 @@ partial void ProcessCallbackApiV1AuthGoogleCallbackGetResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -281,6 +323,8 @@ partial void ProcessCallbackApiV1AuthGoogleCallbackGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -301,6 +345,8 @@ partial void ProcessCallbackApiV1AuthGoogleCallbackGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Bad Request
@@ -401,7 +447,11 @@ partial void ProcessCallbackApiV1AuthGoogleCallbackGetResponseContent(
{
__response.EnsureSuccessStatusCode();
- return __content;
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __content);
}
catch (global::System.Exception __ex)
{
@@ -429,7 +479,11 @@ partial void ProcessCallbackApiV1AuthGoogleCallbackGetResponseContent(
#endif
).ConfigureAwait(false);
- return __content;
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __content);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.AuthClient.CreateTokenApiV1AuthTokenCreatePost.g.cs b/src/libs/Presenton/Generated/Presenton.AuthClient.CreateTokenApiV1AuthTokenCreatePost.g.cs
index 1d2b02b..5564fb0 100644
--- a/src/libs/Presenton/Generated/Presenton.AuthClient.CreateTokenApiV1AuthTokenCreatePost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.AuthClient.CreateTokenApiV1AuthTokenCreatePost.g.cs
@@ -48,6 +48,23 @@ partial void ProcessCreateTokenApiV1AuthTokenCreatePostResponseContent(
public async global::System.Threading.Tasks.Task CreateTokenApiV1AuthTokenCreatePostAsync(
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await CreateTokenApiV1AuthTokenCreatePostAsResponseAsync(
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Create Token
+ ///
+ /// 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> CreateTokenApiV1AuthTokenCreatePostAsResponseAsync(
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
@@ -76,6 +93,7 @@ partial void ProcessCreateTokenApiV1AuthTokenCreatePostResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/auth/token/create",
baseUri: HttpClient.BaseAddress);
@@ -148,6 +166,8 @@ partial void ProcessCreateTokenApiV1AuthTokenCreatePostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -158,6 +178,11 @@ partial void ProcessCreateTokenApiV1AuthTokenCreatePostResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -175,6 +200,8 @@ partial void ProcessCreateTokenApiV1AuthTokenCreatePostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -184,8 +211,7 @@ partial void ProcessCreateTokenApiV1AuthTokenCreatePostResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -194,6 +220,11 @@ partial void ProcessCreateTokenApiV1AuthTokenCreatePostResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -210,14 +241,15 @@ partial void ProcessCreateTokenApiV1AuthTokenCreatePostResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -257,6 +289,8 @@ partial void ProcessCreateTokenApiV1AuthTokenCreatePostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -277,6 +311,8 @@ partial void ProcessCreateTokenApiV1AuthTokenCreatePostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
@@ -301,9 +337,13 @@ partial void ProcessCreateTokenApiV1AuthTokenCreatePostResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.AccessToken.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.AccessToken.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -331,9 +371,13 @@ partial void ProcessCreateTokenApiV1AuthTokenCreatePostResponseContent(
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.AccessToken.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.AccessToken.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.AuthClient.DeleteUserProfileApiV1AuthProfileDeleteDelete.g.cs b/src/libs/Presenton/Generated/Presenton.AuthClient.DeleteUserProfileApiV1AuthProfileDeleteDelete.g.cs
index d66c612..599aa78 100644
--- a/src/libs/Presenton/Generated/Presenton.AuthClient.DeleteUserProfileApiV1AuthProfileDeleteDelete.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.AuthClient.DeleteUserProfileApiV1AuthProfileDeleteDelete.g.cs
@@ -43,6 +43,21 @@ partial void ProcessDeleteUserProfileApiV1AuthProfileDeleteDeleteResponse(
public async global::System.Threading.Tasks.Task DeleteUserProfileApiV1AuthProfileDeleteDeleteAsync(
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ await DeleteUserProfileApiV1AuthProfileDeleteDeleteAsResponseAsync(
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+ }
+ ///
+ /// Delete User Profile
+ ///
+ /// 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 DeleteUserProfileApiV1AuthProfileDeleteDeleteAsResponseAsync(
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
@@ -71,6 +86,7 @@ partial void ProcessDeleteUserProfileApiV1AuthProfileDeleteDeleteResponse(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/auth/profile/delete",
baseUri: HttpClient.BaseAddress);
@@ -143,6 +159,8 @@ partial void ProcessDeleteUserProfileApiV1AuthProfileDeleteDeleteResponse(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -153,6 +171,11 @@ partial void ProcessDeleteUserProfileApiV1AuthProfileDeleteDeleteResponse(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -170,6 +193,8 @@ partial void ProcessDeleteUserProfileApiV1AuthProfileDeleteDeleteResponse(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -179,8 +204,7 @@ partial void ProcessDeleteUserProfileApiV1AuthProfileDeleteDeleteResponse(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -189,6 +213,11 @@ partial void ProcessDeleteUserProfileApiV1AuthProfileDeleteDeleteResponse(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -205,14 +234,15 @@ partial void ProcessDeleteUserProfileApiV1AuthProfileDeleteDeleteResponse(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -252,6 +282,8 @@ partial void ProcessDeleteUserProfileApiV1AuthProfileDeleteDeleteResponse(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -272,6 +304,8 @@ partial void ProcessDeleteUserProfileApiV1AuthProfileDeleteDeleteResponse(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
@@ -292,6 +326,10 @@ partial void ProcessDeleteUserProfileApiV1AuthProfileDeleteDeleteResponse(
{
__response.EnsureSuccessStatusCode();
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri);
}
catch (global::System.Exception __ex)
{
@@ -313,6 +351,10 @@ partial void ProcessDeleteUserProfileApiV1AuthProfileDeleteDeleteResponse(
try
{
__response.EnsureSuccessStatusCode();
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.AuthClient.EnterpriseLoginApiV1AuthEnterpriseLoginGet.g.cs b/src/libs/Presenton/Generated/Presenton.AuthClient.EnterpriseLoginApiV1AuthEnterpriseLoginGet.g.cs
index a4c5e0c..5739fdc 100644
--- a/src/libs/Presenton/Generated/Presenton.AuthClient.EnterpriseLoginApiV1AuthEnterpriseLoginGet.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.AuthClient.EnterpriseLoginApiV1AuthEnterpriseLoginGet.g.cs
@@ -62,6 +62,34 @@ partial void ProcessEnterpriseLoginApiV1AuthEnterpriseLoginGetResponseContent(
string? lastName = default,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await EnterpriseLoginApiV1AuthEnterpriseLoginGetAsResponseAsync(
+ email: email,
+ firstName: firstName,
+ lastName: lastName,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Enterprise Login
+ ///
+ ///
+ /// Work email (must be @exlservice.com)
+ ///
+ ///
+ ///
+ /// 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> EnterpriseLoginApiV1AuthEnterpriseLoginGetAsResponseAsync(
+ string email,
+ string? firstName = default,
+ string? lastName = default,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
@@ -93,13 +121,14 @@ partial void ProcessEnterpriseLoginApiV1AuthEnterpriseLoginGetResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/auth/enterprise-login",
- baseUri: HttpClient.BaseAddress);
+ baseUri: HttpClient.BaseAddress);
__pathBuilder
.AddRequiredParameter("email", email)
.AddOptionalParameter("first_name", firstName)
- .AddOptionalParameter("last_name", lastName)
+ .AddOptionalParameter("last_name", lastName)
;
var __path = __pathBuilder.ToString();
__path = global::Presenton.AutoSDKRequestOptionsSupport.AppendQueryParameters(
@@ -173,6 +202,8 @@ partial void ProcessEnterpriseLoginApiV1AuthEnterpriseLoginGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -183,6 +214,11 @@ partial void ProcessEnterpriseLoginApiV1AuthEnterpriseLoginGetResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -200,6 +236,8 @@ partial void ProcessEnterpriseLoginApiV1AuthEnterpriseLoginGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -209,8 +247,7 @@ partial void ProcessEnterpriseLoginApiV1AuthEnterpriseLoginGetResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -219,6 +256,11 @@ partial void ProcessEnterpriseLoginApiV1AuthEnterpriseLoginGetResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -235,14 +277,15 @@ partial void ProcessEnterpriseLoginApiV1AuthEnterpriseLoginGetResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -282,6 +325,8 @@ partial void ProcessEnterpriseLoginApiV1AuthEnterpriseLoginGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -302,6 +347,8 @@ partial void ProcessEnterpriseLoginApiV1AuthEnterpriseLoginGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -364,9 +411,13 @@ partial void ProcessEnterpriseLoginApiV1AuthEnterpriseLoginGetResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.EnterpriseLoginResponse.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.EnterpriseLoginResponse.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -394,9 +445,13 @@ partial void ProcessEnterpriseLoginApiV1AuthEnterpriseLoginGetResponseContent(
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.EnterpriseLoginResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.EnterpriseLoginResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.AuthClient.GetMeApiV1AuthProfileGet.g.cs b/src/libs/Presenton/Generated/Presenton.AuthClient.GetMeApiV1AuthProfileGet.g.cs
index 347c5ee..345134b 100644
--- a/src/libs/Presenton/Generated/Presenton.AuthClient.GetMeApiV1AuthProfileGet.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.AuthClient.GetMeApiV1AuthProfileGet.g.cs
@@ -48,6 +48,23 @@ partial void ProcessGetMeApiV1AuthProfileGetResponseContent(
public async global::System.Threading.Tasks.Task GetMeApiV1AuthProfileGetAsync(
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await GetMeApiV1AuthProfileGetAsResponseAsync(
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Get Me
+ ///
+ /// 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> GetMeApiV1AuthProfileGetAsResponseAsync(
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
@@ -76,6 +93,7 @@ partial void ProcessGetMeApiV1AuthProfileGetResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/auth/profile",
baseUri: HttpClient.BaseAddress);
@@ -148,6 +166,8 @@ partial void ProcessGetMeApiV1AuthProfileGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -158,6 +178,11 @@ partial void ProcessGetMeApiV1AuthProfileGetResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -175,6 +200,8 @@ partial void ProcessGetMeApiV1AuthProfileGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -184,8 +211,7 @@ partial void ProcessGetMeApiV1AuthProfileGetResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -194,6 +220,11 @@ partial void ProcessGetMeApiV1AuthProfileGetResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -210,14 +241,15 @@ partial void ProcessGetMeApiV1AuthProfileGetResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -257,6 +289,8 @@ partial void ProcessGetMeApiV1AuthProfileGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -277,6 +311,8 @@ partial void ProcessGetMeApiV1AuthProfileGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -339,9 +375,13 @@ partial void ProcessGetMeApiV1AuthProfileGetResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.GetMeResponse.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.GetMeResponse.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -369,9 +409,13 @@ partial void ProcessGetMeApiV1AuthProfileGetResponseContent(
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.GetMeResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.GetMeResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.AuthClient.ListTokensApiV1AuthTokenListGet.g.cs b/src/libs/Presenton/Generated/Presenton.AuthClient.ListTokensApiV1AuthTokenListGet.g.cs
index 507b23e..44a45cf 100644
--- a/src/libs/Presenton/Generated/Presenton.AuthClient.ListTokensApiV1AuthTokenListGet.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.AuthClient.ListTokensApiV1AuthTokenListGet.g.cs
@@ -48,6 +48,23 @@ partial void ProcessListTokensApiV1AuthTokenListGetResponseContent(
public async global::System.Threading.Tasks.Task> ListTokensApiV1AuthTokenListGetAsync(
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await ListTokensApiV1AuthTokenListGetAsResponseAsync(
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// List Tokens
+ ///
+ /// 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>> ListTokensApiV1AuthTokenListGetAsResponseAsync(
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
@@ -76,6 +93,7 @@ partial void ProcessListTokensApiV1AuthTokenListGetResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/auth/token/list",
baseUri: HttpClient.BaseAddress);
@@ -148,6 +166,8 @@ partial void ProcessListTokensApiV1AuthTokenListGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -158,6 +178,11 @@ partial void ProcessListTokensApiV1AuthTokenListGetResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -175,6 +200,8 @@ partial void ProcessListTokensApiV1AuthTokenListGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -184,8 +211,7 @@ partial void ProcessListTokensApiV1AuthTokenListGetResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -194,6 +220,11 @@ partial void ProcessListTokensApiV1AuthTokenListGetResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -210,14 +241,15 @@ partial void ProcessListTokensApiV1AuthTokenListGetResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -257,6 +289,8 @@ partial void ProcessListTokensApiV1AuthTokenListGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -277,6 +311,8 @@ partial void ProcessListTokensApiV1AuthTokenListGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
@@ -301,9 +337,13 @@ partial void ProcessListTokensApiV1AuthTokenListGetResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- (global::System.Collections.Generic.IList?)global::System.Text.Json.JsonSerializer.Deserialize(__content, typeof(global::System.Collections.Generic.IList), JsonSerializerContext) ??
+ var __value = (global::System.Collections.Generic.IList?)global::System.Text.Json.JsonSerializer.Deserialize(__content, typeof(global::System.Collections.Generic.IList), JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse>(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -331,9 +371,13 @@ partial void ProcessListTokensApiV1AuthTokenListGetResponseContent(
#endif
).ConfigureAwait(false);
- return
- (global::System.Collections.Generic.IList?)await global::System.Text.Json.JsonSerializer.DeserializeAsync(__content, typeof(global::System.Collections.Generic.IList), JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = (global::System.Collections.Generic.IList?)await global::System.Text.Json.JsonSerializer.DeserializeAsync(__content, typeof(global::System.Collections.Generic.IList), JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse>(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.AuthClient.PatchMeApiV1AuthProfileUpdatePatch.g.cs b/src/libs/Presenton/Generated/Presenton.AuthClient.PatchMeApiV1AuthProfileUpdatePatch.g.cs
index 5cf71d8..ea813dc 100644
--- a/src/libs/Presenton/Generated/Presenton.AuthClient.PatchMeApiV1AuthProfileUpdatePatch.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.AuthClient.PatchMeApiV1AuthProfileUpdatePatch.g.cs
@@ -50,6 +50,28 @@ partial void ProcessPatchMeApiV1AuthProfileUpdatePatchResponseContent(
///
public async global::System.Threading.Tasks.Task PatchMeApiV1AuthProfileUpdatePatchAsync(
+ global::Presenton.BodyPatchMeApiV1AuthProfileUpdatePatch request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await PatchMeApiV1AuthProfileUpdatePatchAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Patch Me
+ ///
+ ///
+ /// 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> PatchMeApiV1AuthProfileUpdatePatchAsResponseAsync(
+
global::Presenton.BodyPatchMeApiV1AuthProfileUpdatePatch request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -80,10 +102,11 @@ partial void ProcessPatchMeApiV1AuthProfileUpdatePatchResponseContent(
var __maxAttempts = global::Presenton.AutoSDKRequestOptionsSupport.GetMaxAttempts(
clientOptions: Options,
requestOptions: requestOptions,
- supportsRetry: true);
+ supportsRetry: false);
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/auth/profile/update",
baseUri: HttpClient.BaseAddress);
@@ -116,6 +139,7 @@ partial void ProcessPatchMeApiV1AuthProfileUpdatePatchResponseContent(
__httpRequest.Headers.Add(__authorization.Name, __authorization.Value);
}
}
+
var __httpRequestContent = new global::System.Net.Http.MultipartFormDataContent();
if (request.ProfilePicture != default)
{
@@ -157,15 +181,19 @@ request.ProfilePicturename is null
{
__contentProfilePicture.Headers.ContentDisposition.FileNameStar = null;
}
- }
+
+ }
if (request.Name != default)
{
__httpRequestContent.Add(
content: new global::System.Net.Http.StringContent(request.Name ?? string.Empty),
name: "\"name\"");
+
}
+
__httpRequest.Content = __httpRequestContent;
+
global::Presenton.AutoSDKRequestOptionsSupport.ApplyHeaders(
request: __httpRequest,
clientHeaders: Options.Headers,
@@ -207,6 +235,8 @@ request.ProfilePicturename is null
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -217,6 +247,11 @@ request.ProfilePicturename is null
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -234,6 +269,8 @@ request.ProfilePicturename is null
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -243,8 +280,7 @@ request.ProfilePicturename is null
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -253,6 +289,11 @@ request.ProfilePicturename is null
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -269,14 +310,15 @@ request.ProfilePicturename is null
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -316,6 +358,8 @@ request.ProfilePicturename is null
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -336,6 +380,8 @@ request.ProfilePicturename is null
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -398,7 +444,11 @@ request.ProfilePicturename is null
{
__response.EnsureSuccessStatusCode();
- return __content;
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __content);
}
catch (global::System.Exception __ex)
{
@@ -426,7 +476,11 @@ request.ProfilePicturename is null
#endif
).ConfigureAwait(false);
- return __content;
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __content);
}
catch (global::System.Exception __ex)
{
@@ -492,5 +546,928 @@ request.ProfilePicturename is null
requestOptions: requestOptions,
cancellationToken: cancellationToken).ConfigureAwait(false);
}
+
+ ///
+ /// Patch Me
+ ///
+ ///
+ /// The stream to send as the multipart 'profile_picture' file part.
+ ///
+ ///
+ ///
+ /// 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 PatchMeApiV1AuthProfileUpdatePatchAsync(
+ global::System.IO.Stream? profilePicture = default,
+ string? profilePicturename = default,
+ string? name = default,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+
+ var request = new global::Presenton.BodyPatchMeApiV1AuthProfileUpdatePatch
+ {
+ ProfilePicture = global::System.Array.Empty(),
+ ProfilePicturename = profilePicturename,
+ Name = name,
+ };
+ PrepareArguments(
+ client: HttpClient);
+ PreparePatchMeApiV1AuthProfileUpdatePatchArguments(
+ httpClient: HttpClient,
+ request: request);
+
+
+ var __authorizations = global::Presenton.EndPointSecurityResolver.ResolveAuthorizations(
+ availableAuthorizations: Authorizations,
+ securityRequirements: s_PatchMeApiV1AuthProfileUpdatePatchSecurityRequirements,
+ operationName: "PatchMeApiV1AuthProfileUpdatePatchAsync");
+
+ using var __timeoutCancellationTokenSource = global::Presenton.AutoSDKRequestOptionsSupport.CreateTimeoutCancellationTokenSource(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken);
+ var __effectiveCancellationToken = __timeoutCancellationTokenSource?.Token ?? cancellationToken;
+ var __effectiveReadResponseAsString = global::Presenton.AutoSDKRequestOptionsSupport.GetReadResponseAsString(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ fallbackValue: ReadResponseAsString);
+ var __maxAttempts = global::Presenton.AutoSDKRequestOptionsSupport.GetMaxAttempts(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ supportsRetry: false);
+
+ global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
+ {
+
+ var __pathBuilder = new global::Presenton.PathBuilder(
+ path: "/api/v1/auth/profile/update",
+ baseUri: HttpClient.BaseAddress);
+ var __path = __pathBuilder.ToString();
+ __path = global::Presenton.AutoSDKRequestOptionsSupport.AppendQueryParameters(
+ path: __path,
+ clientParameters: Options.QueryParameters,
+ requestParameters: requestOptions?.QueryParameters);
+ var __httpRequest = new global::System.Net.Http.HttpRequestMessage(
+ method: new global::System.Net.Http.HttpMethod("PATCH"),
+ 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);
+ }
+ }
+
+ var __httpRequestContent = new global::System.Net.Http.MultipartFormDataContent();
+ if (profilePicture != default)
+ {
+
+ var __contentProfilePicture = new global::System.Net.Http.StreamContent(profilePicture);
+ __contentProfilePicture.Headers.ContentType = new global::System.Net.Http.Headers.MediaTypeHeaderValue(
+ request.ProfilePicturename is null
+ ? "application/octet-stream"
+ : (global::System.IO.Path.GetExtension(request.ProfilePicturename) ?? string.Empty).ToLowerInvariant() switch
+ {
+ ".aac" => "audio/aac",
+ ".flac" => "audio/flac",
+ ".gif" => "image/gif",
+ ".jpeg" => "image/jpeg",
+ ".jpg" => "image/jpeg",
+ ".json" => "application/json",
+ ".m4a" => "audio/mp4",
+ ".mp3" => "audio/mpeg",
+ ".mp4" => "video/mp4",
+ ".mpeg" => "audio/mpeg",
+ ".mpga" => "audio/mpeg",
+ ".oga" => "audio/ogg",
+ ".ogg" => "audio/ogg",
+ ".opus" => "audio/ogg",
+ ".pdf" => "application/pdf",
+ ".png" => "image/png",
+ ".txt" => "text/plain",
+ ".wav" => "audio/wav",
+ ".weba" => "audio/webm",
+ ".webm" => "video/webm",
+ ".webp" => "image/webp",
+ _ => "application/octet-stream",
+ });
+ __httpRequestContent.Add(
+ content: __contentProfilePicture,
+ name: "\"profile_picture\"",
+ fileName: request.ProfilePicturename != null ? $"\"{request.ProfilePicturename}\"" : string.Empty);
+ if (__contentProfilePicture.Headers.ContentDisposition != null)
+ {
+ __contentProfilePicture.Headers.ContentDisposition.FileNameStar = null;
+ }
+
+ }
+ if (request.Name != default)
+ {
+
+ __httpRequestContent.Add(
+ content: new global::System.Net.Http.StringContent(request.Name ?? string.Empty),
+ name: "\"name\"");
+
+ }
+
+ __httpRequest.Content = __httpRequestContent;
+
+ global::Presenton.AutoSDKRequestOptionsSupport.ApplyHeaders(
+ request: __httpRequest,
+ clientHeaders: Options.Headers,
+ requestHeaders: requestOptions?.Headers);
+
+ PrepareRequest(
+ client: HttpClient,
+ request: __httpRequest);
+ PreparePatchMeApiV1AuthProfileUpdatePatchRequest(
+ httpClient: HttpClient,
+ httpRequestMessage: __httpRequest,
+ request: request);
+
+ 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::Presenton.AutoSDKRequestOptionsSupport.OnBeforeRequestAsync(
+ clientOptions: Options,
+ context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
+ operationId: "PatchMeApiV1AuthProfileUpdatePatch",
+ methodName: "PatchMeApiV1AuthProfileUpdatePatchAsync",
+ pathTemplate: "\"/api/v1/auth/profile/update\"",
+ httpMethod: "PATCH",
+ 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::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
+ var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
+ await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
+ clientOptions: Options,
+ context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
+ operationId: "PatchMeApiV1AuthProfileUpdatePatch",
+ methodName: "PatchMeApiV1AuthProfileUpdatePatchAsync",
+ pathTemplate: "\"/api/v1/auth/profile/update\"",
+ httpMethod: "PATCH",
+ 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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
+ retryDelay: __retryDelay,
+ cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
+ continue;
+ }
+
+ if (__response != null &&
+ __attempt < __maxAttempts &&
+ global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
+ {
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
+ await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
+ clientOptions: Options,
+ context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
+ operationId: "PatchMeApiV1AuthProfileUpdatePatch",
+ methodName: "PatchMeApiV1AuthProfileUpdatePatchAsync",
+ pathTemplate: "\"/api/v1/auth/profile/update\"",
+ httpMethod: "PATCH",
+ 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::Presenton.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);
+ ProcessPatchMeApiV1AuthProfileUpdatePatchResponse(
+ httpClient: HttpClient,
+ httpResponseMessage: __response);
+ if (__response.IsSuccessStatusCode)
+ {
+ await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterSuccessAsync(
+ clientOptions: Options,
+ context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
+ operationId: "PatchMeApiV1AuthProfileUpdatePatch",
+ methodName: "PatchMeApiV1AuthProfileUpdatePatchAsync",
+ pathTemplate: "\"/api/v1/auth/profile/update\"",
+ httpMethod: "PATCH",
+ 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::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
+ clientOptions: Options,
+ context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
+ operationId: "PatchMeApiV1AuthProfileUpdatePatch",
+ methodName: "PatchMeApiV1AuthProfileUpdatePatchAsync",
+ pathTemplate: "\"/api/v1/auth/profile/update\"",
+ httpMethod: "PATCH",
+ 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);
+ }
+ // Validation Error
+ if ((int)__response.StatusCode == 422)
+ {
+ string? __content_422 = null;
+ global::System.Exception? __exception_422 = null;
+ global::Presenton.HTTPValidationError? __value_422 = null;
+ try
+ {
+ if (__effectiveReadResponseAsString)
+ {
+ __content_422 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false);
+ __value_422 = global::Presenton.HTTPValidationError.FromJson(__content_422, JsonSerializerContext);
+ }
+ else
+ {
+ __content_422 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false);
+
+ __value_422 = global::Presenton.HTTPValidationError.FromJson(__content_422, JsonSerializerContext);
+ }
+ }
+ catch (global::System.Exception __ex)
+ {
+ __exception_422 = __ex;
+ }
+
+ throw new global::Presenton.ApiException(
+ message: __content_422 ?? __response.ReasonPhrase ?? string.Empty,
+ innerException: __exception_422,
+ statusCode: __response.StatusCode)
+ {
+ ResponseBody = __content_422,
+ ResponseObject = __value_422,
+ 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);
+ ProcessPatchMeApiV1AuthProfileUpdatePatchResponseContent(
+ httpClient: HttpClient,
+ httpResponseMessage: __response,
+ content: ref __content);
+
+ try
+ {
+ __response.EnsureSuccessStatusCode();
+
+ return __content;
+ }
+ catch (global::System.Exception __ex)
+ {
+ throw new global::Presenton.ApiException(
+ message: __content ?? __response.ReasonPhrase ?? string.Empty,
+ innerException: __ex,
+ statusCode: __response.StatusCode)
+ {
+ ResponseBody = __content,
+ ResponseHeaders = global::System.Linq.Enumerable.ToDictionary(
+ __response.Headers,
+ h => h.Key,
+ h => h.Value),
+ };
+ }
+ }
+ else
+ {
+ try
+ {
+ __response.EnsureSuccessStatusCode();
+ var __content = await __response.Content.ReadAsStringAsync(
+ #if NET5_0_OR_GREATER
+ __effectiveCancellationToken
+ #endif
+ ).ConfigureAwait(false);
+
+ return __content;
+ }
+ 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 new global::Presenton.ApiException(
+ message: __content ?? __response.ReasonPhrase ?? string.Empty,
+ innerException: __ex,
+ statusCode: __response.StatusCode)
+ {
+ ResponseBody = __content,
+ ResponseHeaders = global::System.Linq.Enumerable.ToDictionary(
+ __response.Headers,
+ h => h.Key,
+ h => h.Value),
+ };
+ }
+ }
+
+ }
+ }
+ finally
+ {
+ __httpRequest?.Dispose();
+ }
+ }
+ ///
+ /// Patch Me
+ ///
+ ///
+ /// The stream to send as the multipart 'profile_picture' file part.
+ ///
+ ///
+ ///
+ /// 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> PatchMeApiV1AuthProfileUpdatePatchAsResponseAsync(
+ global::System.IO.Stream? profilePicture = default,
+ string? profilePicturename = default,
+ string? name = default,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+
+ var request = new global::Presenton.BodyPatchMeApiV1AuthProfileUpdatePatch
+ {
+ ProfilePicture = global::System.Array.Empty(),
+ ProfilePicturename = profilePicturename,
+ Name = name,
+ };
+ PrepareArguments(
+ client: HttpClient);
+ PreparePatchMeApiV1AuthProfileUpdatePatchArguments(
+ httpClient: HttpClient,
+ request: request);
+
+
+ var __authorizations = global::Presenton.EndPointSecurityResolver.ResolveAuthorizations(
+ availableAuthorizations: Authorizations,
+ securityRequirements: s_PatchMeApiV1AuthProfileUpdatePatchSecurityRequirements,
+ operationName: "PatchMeApiV1AuthProfileUpdatePatchAsync");
+
+ using var __timeoutCancellationTokenSource = global::Presenton.AutoSDKRequestOptionsSupport.CreateTimeoutCancellationTokenSource(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken);
+ var __effectiveCancellationToken = __timeoutCancellationTokenSource?.Token ?? cancellationToken;
+ var __effectiveReadResponseAsString = global::Presenton.AutoSDKRequestOptionsSupport.GetReadResponseAsString(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ fallbackValue: ReadResponseAsString);
+ var __maxAttempts = global::Presenton.AutoSDKRequestOptionsSupport.GetMaxAttempts(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ supportsRetry: false);
+
+ global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
+ {
+
+ var __pathBuilder = new global::Presenton.PathBuilder(
+ path: "/api/v1/auth/profile/update",
+ baseUri: HttpClient.BaseAddress);
+ var __path = __pathBuilder.ToString();
+ __path = global::Presenton.AutoSDKRequestOptionsSupport.AppendQueryParameters(
+ path: __path,
+ clientParameters: Options.QueryParameters,
+ requestParameters: requestOptions?.QueryParameters);
+ var __httpRequest = new global::System.Net.Http.HttpRequestMessage(
+ method: new global::System.Net.Http.HttpMethod("PATCH"),
+ 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);
+ }
+ }
+
+ var __httpRequestContent = new global::System.Net.Http.MultipartFormDataContent();
+ if (profilePicture != default)
+ {
+
+ var __contentProfilePicture = new global::System.Net.Http.StreamContent(profilePicture);
+ __contentProfilePicture.Headers.ContentType = new global::System.Net.Http.Headers.MediaTypeHeaderValue(
+ request.ProfilePicturename is null
+ ? "application/octet-stream"
+ : (global::System.IO.Path.GetExtension(request.ProfilePicturename) ?? string.Empty).ToLowerInvariant() switch
+ {
+ ".aac" => "audio/aac",
+ ".flac" => "audio/flac",
+ ".gif" => "image/gif",
+ ".jpeg" => "image/jpeg",
+ ".jpg" => "image/jpeg",
+ ".json" => "application/json",
+ ".m4a" => "audio/mp4",
+ ".mp3" => "audio/mpeg",
+ ".mp4" => "video/mp4",
+ ".mpeg" => "audio/mpeg",
+ ".mpga" => "audio/mpeg",
+ ".oga" => "audio/ogg",
+ ".ogg" => "audio/ogg",
+ ".opus" => "audio/ogg",
+ ".pdf" => "application/pdf",
+ ".png" => "image/png",
+ ".txt" => "text/plain",
+ ".wav" => "audio/wav",
+ ".weba" => "audio/webm",
+ ".webm" => "video/webm",
+ ".webp" => "image/webp",
+ _ => "application/octet-stream",
+ });
+ __httpRequestContent.Add(
+ content: __contentProfilePicture,
+ name: "\"profile_picture\"",
+ fileName: request.ProfilePicturename != null ? $"\"{request.ProfilePicturename}\"" : string.Empty);
+ if (__contentProfilePicture.Headers.ContentDisposition != null)
+ {
+ __contentProfilePicture.Headers.ContentDisposition.FileNameStar = null;
+ }
+
+ }
+ if (request.Name != default)
+ {
+
+ __httpRequestContent.Add(
+ content: new global::System.Net.Http.StringContent(request.Name ?? string.Empty),
+ name: "\"name\"");
+
+ }
+
+ __httpRequest.Content = __httpRequestContent;
+
+ global::Presenton.AutoSDKRequestOptionsSupport.ApplyHeaders(
+ request: __httpRequest,
+ clientHeaders: Options.Headers,
+ requestHeaders: requestOptions?.Headers);
+
+ PrepareRequest(
+ client: HttpClient,
+ request: __httpRequest);
+ PreparePatchMeApiV1AuthProfileUpdatePatchRequest(
+ httpClient: HttpClient,
+ httpRequestMessage: __httpRequest,
+ request: request);
+
+ 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::Presenton.AutoSDKRequestOptionsSupport.OnBeforeRequestAsync(
+ clientOptions: Options,
+ context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
+ operationId: "PatchMeApiV1AuthProfileUpdatePatch",
+ methodName: "PatchMeApiV1AuthProfileUpdatePatchAsync",
+ pathTemplate: "\"/api/v1/auth/profile/update\"",
+ httpMethod: "PATCH",
+ 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::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
+ var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
+ await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
+ clientOptions: Options,
+ context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
+ operationId: "PatchMeApiV1AuthProfileUpdatePatch",
+ methodName: "PatchMeApiV1AuthProfileUpdatePatchAsync",
+ pathTemplate: "\"/api/v1/auth/profile/update\"",
+ httpMethod: "PATCH",
+ 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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
+ retryDelay: __retryDelay,
+ cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
+ continue;
+ }
+
+ if (__response != null &&
+ __attempt < __maxAttempts &&
+ global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
+ {
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
+ await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
+ clientOptions: Options,
+ context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
+ operationId: "PatchMeApiV1AuthProfileUpdatePatch",
+ methodName: "PatchMeApiV1AuthProfileUpdatePatchAsync",
+ pathTemplate: "\"/api/v1/auth/profile/update\"",
+ httpMethod: "PATCH",
+ 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::Presenton.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);
+ ProcessPatchMeApiV1AuthProfileUpdatePatchResponse(
+ httpClient: HttpClient,
+ httpResponseMessage: __response);
+ if (__response.IsSuccessStatusCode)
+ {
+ await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterSuccessAsync(
+ clientOptions: Options,
+ context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
+ operationId: "PatchMeApiV1AuthProfileUpdatePatch",
+ methodName: "PatchMeApiV1AuthProfileUpdatePatchAsync",
+ pathTemplate: "\"/api/v1/auth/profile/update\"",
+ httpMethod: "PATCH",
+ 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::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
+ clientOptions: Options,
+ context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
+ operationId: "PatchMeApiV1AuthProfileUpdatePatch",
+ methodName: "PatchMeApiV1AuthProfileUpdatePatchAsync",
+ pathTemplate: "\"/api/v1/auth/profile/update\"",
+ httpMethod: "PATCH",
+ 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);
+ }
+ // Validation Error
+ if ((int)__response.StatusCode == 422)
+ {
+ string? __content_422 = null;
+ global::System.Exception? __exception_422 = null;
+ global::Presenton.HTTPValidationError? __value_422 = null;
+ try
+ {
+ if (__effectiveReadResponseAsString)
+ {
+ __content_422 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false);
+ __value_422 = global::Presenton.HTTPValidationError.FromJson(__content_422, JsonSerializerContext);
+ }
+ else
+ {
+ __content_422 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false);
+
+ __value_422 = global::Presenton.HTTPValidationError.FromJson(__content_422, JsonSerializerContext);
+ }
+ }
+ catch (global::System.Exception __ex)
+ {
+ __exception_422 = __ex;
+ }
+
+ throw new global::Presenton.ApiException(
+ message: __content_422 ?? __response.ReasonPhrase ?? string.Empty,
+ innerException: __exception_422,
+ statusCode: __response.StatusCode)
+ {
+ ResponseBody = __content_422,
+ ResponseObject = __value_422,
+ 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);
+ ProcessPatchMeApiV1AuthProfileUpdatePatchResponseContent(
+ httpClient: HttpClient,
+ httpResponseMessage: __response,
+ content: ref __content);
+
+ try
+ {
+ __response.EnsureSuccessStatusCode();
+
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __content);
+ }
+ catch (global::System.Exception __ex)
+ {
+ throw new global::Presenton.ApiException(
+ message: __content ?? __response.ReasonPhrase ?? string.Empty,
+ innerException: __ex,
+ statusCode: __response.StatusCode)
+ {
+ ResponseBody = __content,
+ ResponseHeaders = global::System.Linq.Enumerable.ToDictionary(
+ __response.Headers,
+ h => h.Key,
+ h => h.Value),
+ };
+ }
+ }
+ else
+ {
+ try
+ {
+ __response.EnsureSuccessStatusCode();
+ var __content = await __response.Content.ReadAsStringAsync(
+ #if NET5_0_OR_GREATER
+ __effectiveCancellationToken
+ #endif
+ ).ConfigureAwait(false);
+
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __content);
+ }
+ 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 new global::Presenton.ApiException(
+ message: __content ?? __response.ReasonPhrase ?? string.Empty,
+ innerException: __ex,
+ statusCode: __response.StatusCode)
+ {
+ 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/Presenton/Generated/Presenton.AuthClient.RegisterRegisterApiV1AuthRegisterPost.g.cs b/src/libs/Presenton/Generated/Presenton.AuthClient.RegisterRegisterApiV1AuthRegisterPost.g.cs
index 52756de..d073fe2 100644
--- a/src/libs/Presenton/Generated/Presenton.AuthClient.RegisterRegisterApiV1AuthRegisterPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.AuthClient.RegisterRegisterApiV1AuthRegisterPost.g.cs
@@ -50,6 +50,28 @@ partial void ProcessRegisterRegisterApiV1AuthRegisterPostResponseContent(
///
public async global::System.Threading.Tasks.Task RegisterRegisterApiV1AuthRegisterPostAsync(
+ global::Presenton.UserCreate request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await RegisterRegisterApiV1AuthRegisterPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Register:Register
+ ///
+ ///
+ /// 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> RegisterRegisterApiV1AuthRegisterPostAsResponseAsync(
+
global::Presenton.UserCreate request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -84,6 +106,7 @@ partial void ProcessRegisterRegisterApiV1AuthRegisterPostResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/auth/register",
baseUri: HttpClient.BaseAddress);
@@ -163,6 +186,8 @@ partial void ProcessRegisterRegisterApiV1AuthRegisterPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -173,6 +198,11 @@ partial void ProcessRegisterRegisterApiV1AuthRegisterPostResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -190,6 +220,8 @@ partial void ProcessRegisterRegisterApiV1AuthRegisterPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -199,8 +231,7 @@ partial void ProcessRegisterRegisterApiV1AuthRegisterPostResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -209,6 +240,11 @@ partial void ProcessRegisterRegisterApiV1AuthRegisterPostResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -225,14 +261,15 @@ partial void ProcessRegisterRegisterApiV1AuthRegisterPostResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -272,6 +309,8 @@ partial void ProcessRegisterRegisterApiV1AuthRegisterPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -292,6 +331,8 @@ partial void ProcessRegisterRegisterApiV1AuthRegisterPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Bad Request
@@ -392,9 +433,13 @@ partial void ProcessRegisterRegisterApiV1AuthRegisterPostResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.UserRead.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.UserRead.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -422,9 +467,13 @@ partial void ProcessRegisterRegisterApiV1AuthRegisterPostResponseContent(
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.UserRead.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.UserRead.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.AuthClient.ResetForgotPasswordApiV1AuthForgotPasswordPost.g.cs b/src/libs/Presenton/Generated/Presenton.AuthClient.ResetForgotPasswordApiV1AuthForgotPasswordPost.g.cs
index beb7c07..f64d34f 100644
--- a/src/libs/Presenton/Generated/Presenton.AuthClient.ResetForgotPasswordApiV1AuthForgotPasswordPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.AuthClient.ResetForgotPasswordApiV1AuthForgotPasswordPost.g.cs
@@ -50,6 +50,28 @@ partial void ProcessResetForgotPasswordApiV1AuthForgotPasswordPostResponseConten
///
public async global::System.Threading.Tasks.Task ResetForgotPasswordApiV1AuthForgotPasswordPostAsync(
+ global::Presenton.BodyResetForgotPasswordApiV1AuthForgotPasswordPost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await ResetForgotPasswordApiV1AuthForgotPasswordPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Reset:Forgot Password
+ ///
+ ///
+ /// 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> ResetForgotPasswordApiV1AuthForgotPasswordPostAsResponseAsync(
+
global::Presenton.BodyResetForgotPasswordApiV1AuthForgotPasswordPost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -84,6 +106,7 @@ partial void ProcessResetForgotPasswordApiV1AuthForgotPasswordPostResponseConten
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/auth/forgot-password",
baseUri: HttpClient.BaseAddress);
@@ -163,6 +186,8 @@ partial void ProcessResetForgotPasswordApiV1AuthForgotPasswordPostResponseConten
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -173,6 +198,11 @@ partial void ProcessResetForgotPasswordApiV1AuthForgotPasswordPostResponseConten
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -190,6 +220,8 @@ partial void ProcessResetForgotPasswordApiV1AuthForgotPasswordPostResponseConten
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -199,8 +231,7 @@ partial void ProcessResetForgotPasswordApiV1AuthForgotPasswordPostResponseConten
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -209,6 +240,11 @@ partial void ProcessResetForgotPasswordApiV1AuthForgotPasswordPostResponseConten
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -225,14 +261,15 @@ partial void ProcessResetForgotPasswordApiV1AuthForgotPasswordPostResponseConten
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -272,6 +309,8 @@ partial void ProcessResetForgotPasswordApiV1AuthForgotPasswordPostResponseConten
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -292,6 +331,8 @@ partial void ProcessResetForgotPasswordApiV1AuthForgotPasswordPostResponseConten
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -354,7 +395,11 @@ partial void ProcessResetForgotPasswordApiV1AuthForgotPasswordPostResponseConten
{
__response.EnsureSuccessStatusCode();
- return __content;
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __content);
}
catch (global::System.Exception __ex)
{
@@ -382,7 +427,11 @@ partial void ProcessResetForgotPasswordApiV1AuthForgotPasswordPostResponseConten
#endif
).ConfigureAwait(false);
- return __content;
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __content);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.AuthClient.ResetResetPasswordApiV1AuthResetPasswordPost.g.cs b/src/libs/Presenton/Generated/Presenton.AuthClient.ResetResetPasswordApiV1AuthResetPasswordPost.g.cs
index 5ec87d0..7ca3539 100644
--- a/src/libs/Presenton/Generated/Presenton.AuthClient.ResetResetPasswordApiV1AuthResetPasswordPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.AuthClient.ResetResetPasswordApiV1AuthResetPasswordPost.g.cs
@@ -50,6 +50,28 @@ partial void ProcessResetResetPasswordApiV1AuthResetPasswordPostResponseContent(
///
public async global::System.Threading.Tasks.Task ResetResetPasswordApiV1AuthResetPasswordPostAsync(
+ global::Presenton.BodyResetResetPasswordApiV1AuthResetPasswordPost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await ResetResetPasswordApiV1AuthResetPasswordPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Reset:Reset Password
+ ///
+ ///
+ /// 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> ResetResetPasswordApiV1AuthResetPasswordPostAsResponseAsync(
+
global::Presenton.BodyResetResetPasswordApiV1AuthResetPasswordPost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -84,6 +106,7 @@ partial void ProcessResetResetPasswordApiV1AuthResetPasswordPostResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/auth/reset-password",
baseUri: HttpClient.BaseAddress);
@@ -163,6 +186,8 @@ partial void ProcessResetResetPasswordApiV1AuthResetPasswordPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -173,6 +198,11 @@ partial void ProcessResetResetPasswordApiV1AuthResetPasswordPostResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -190,6 +220,8 @@ partial void ProcessResetResetPasswordApiV1AuthResetPasswordPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -199,8 +231,7 @@ partial void ProcessResetResetPasswordApiV1AuthResetPasswordPostResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -209,6 +240,11 @@ partial void ProcessResetResetPasswordApiV1AuthResetPasswordPostResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -225,14 +261,15 @@ partial void ProcessResetResetPasswordApiV1AuthResetPasswordPostResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -272,6 +309,8 @@ partial void ProcessResetResetPasswordApiV1AuthResetPasswordPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -292,6 +331,8 @@ partial void ProcessResetResetPasswordApiV1AuthResetPasswordPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Bad Request
@@ -392,7 +433,11 @@ partial void ProcessResetResetPasswordApiV1AuthResetPasswordPostResponseContent(
{
__response.EnsureSuccessStatusCode();
- return __content;
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __content);
}
catch (global::System.Exception __ex)
{
@@ -420,7 +465,11 @@ partial void ProcessResetResetPasswordApiV1AuthResetPasswordPostResponseContent(
#endif
).ConfigureAwait(false);
- return __content;
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __content);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.AuthClient.RevokeTokenApiV1AuthTokenRevokePost.g.cs b/src/libs/Presenton/Generated/Presenton.AuthClient.RevokeTokenApiV1AuthTokenRevokePost.g.cs
index 1feb65e..8727b3a 100644
--- a/src/libs/Presenton/Generated/Presenton.AuthClient.RevokeTokenApiV1AuthTokenRevokePost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.AuthClient.RevokeTokenApiV1AuthTokenRevokePost.g.cs
@@ -50,6 +50,28 @@ partial void ProcessRevokeTokenApiV1AuthTokenRevokePostResponseContent(
///
public async global::System.Threading.Tasks.Task RevokeTokenApiV1AuthTokenRevokePostAsync(
+ global::Presenton.BodyRevokeTokenApiV1AuthTokenRevokePost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await RevokeTokenApiV1AuthTokenRevokePostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Revoke Token
+ ///
+ ///
+ /// 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> RevokeTokenApiV1AuthTokenRevokePostAsResponseAsync(
+
global::Presenton.BodyRevokeTokenApiV1AuthTokenRevokePost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -84,6 +106,7 @@ partial void ProcessRevokeTokenApiV1AuthTokenRevokePostResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/auth/token/revoke",
baseUri: HttpClient.BaseAddress);
@@ -163,6 +186,8 @@ partial void ProcessRevokeTokenApiV1AuthTokenRevokePostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -173,6 +198,11 @@ partial void ProcessRevokeTokenApiV1AuthTokenRevokePostResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -190,6 +220,8 @@ partial void ProcessRevokeTokenApiV1AuthTokenRevokePostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -199,8 +231,7 @@ partial void ProcessRevokeTokenApiV1AuthTokenRevokePostResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -209,6 +240,11 @@ partial void ProcessRevokeTokenApiV1AuthTokenRevokePostResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -225,14 +261,15 @@ partial void ProcessRevokeTokenApiV1AuthTokenRevokePostResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -272,6 +309,8 @@ partial void ProcessRevokeTokenApiV1AuthTokenRevokePostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -292,6 +331,8 @@ partial void ProcessRevokeTokenApiV1AuthTokenRevokePostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -354,7 +395,11 @@ partial void ProcessRevokeTokenApiV1AuthTokenRevokePostResponseContent(
{
__response.EnsureSuccessStatusCode();
- return __content;
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __content);
}
catch (global::System.Exception __ex)
{
@@ -382,7 +427,11 @@ partial void ProcessRevokeTokenApiV1AuthTokenRevokePostResponseContent(
#endif
).ConfigureAwait(false);
- return __content;
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __content);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.AuthClient.UsersCurrentUserApiV1AuthUsersMeGet.g.cs b/src/libs/Presenton/Generated/Presenton.AuthClient.UsersCurrentUserApiV1AuthUsersMeGet.g.cs
index 4089f80..ca3e824 100644
--- a/src/libs/Presenton/Generated/Presenton.AuthClient.UsersCurrentUserApiV1AuthUsersMeGet.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.AuthClient.UsersCurrentUserApiV1AuthUsersMeGet.g.cs
@@ -48,6 +48,23 @@ partial void ProcessUsersCurrentUserApiV1AuthUsersMeGetResponseContent(
public async global::System.Threading.Tasks.Task UsersCurrentUserApiV1AuthUsersMeGetAsync(
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await UsersCurrentUserApiV1AuthUsersMeGetAsResponseAsync(
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Users:Current User
+ ///
+ /// 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> UsersCurrentUserApiV1AuthUsersMeGetAsResponseAsync(
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
@@ -76,6 +93,7 @@ partial void ProcessUsersCurrentUserApiV1AuthUsersMeGetResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/auth/users/me",
baseUri: HttpClient.BaseAddress);
@@ -148,6 +166,8 @@ partial void ProcessUsersCurrentUserApiV1AuthUsersMeGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -158,6 +178,11 @@ partial void ProcessUsersCurrentUserApiV1AuthUsersMeGetResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -175,6 +200,8 @@ partial void ProcessUsersCurrentUserApiV1AuthUsersMeGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -184,8 +211,7 @@ partial void ProcessUsersCurrentUserApiV1AuthUsersMeGetResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -194,6 +220,11 @@ partial void ProcessUsersCurrentUserApiV1AuthUsersMeGetResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -210,14 +241,15 @@ partial void ProcessUsersCurrentUserApiV1AuthUsersMeGetResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -257,6 +289,8 @@ partial void ProcessUsersCurrentUserApiV1AuthUsersMeGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -277,6 +311,8 @@ partial void ProcessUsersCurrentUserApiV1AuthUsersMeGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
//
@@ -334,9 +370,13 @@ partial void ProcessUsersCurrentUserApiV1AuthUsersMeGetResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.UserRead.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.UserRead.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -364,9 +404,13 @@ partial void ProcessUsersCurrentUserApiV1AuthUsersMeGetResponseContent(
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.UserRead.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.UserRead.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.AuthClient.UsersDeleteUserApiV1AuthUsersIdDelete.g.cs b/src/libs/Presenton/Generated/Presenton.AuthClient.UsersDeleteUserApiV1AuthUsersIdDelete.g.cs
index 9e8811d..7921264 100644
--- a/src/libs/Presenton/Generated/Presenton.AuthClient.UsersDeleteUserApiV1AuthUsersIdDelete.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.AuthClient.UsersDeleteUserApiV1AuthUsersIdDelete.g.cs
@@ -47,6 +47,24 @@ partial void ProcessUsersDeleteUserApiV1AuthUsersIdDeleteResponse(
string id,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ await UsersDeleteUserApiV1AuthUsersIdDeleteAsResponseAsync(
+ id: id,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+ }
+ ///
+ /// Users:Delete User
+ ///
+ ///
+ /// 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 UsersDeleteUserApiV1AuthUsersIdDeleteAsResponseAsync(
+ string id,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
@@ -76,6 +94,7 @@ partial void ProcessUsersDeleteUserApiV1AuthUsersIdDeleteResponse(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: $"/api/v1/auth/users/{id}",
baseUri: HttpClient.BaseAddress);
@@ -149,6 +168,8 @@ partial void ProcessUsersDeleteUserApiV1AuthUsersIdDeleteResponse(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -159,6 +180,11 @@ partial void ProcessUsersDeleteUserApiV1AuthUsersIdDeleteResponse(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -176,6 +202,8 @@ partial void ProcessUsersDeleteUserApiV1AuthUsersIdDeleteResponse(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -185,8 +213,7 @@ partial void ProcessUsersDeleteUserApiV1AuthUsersIdDeleteResponse(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -195,6 +222,11 @@ partial void ProcessUsersDeleteUserApiV1AuthUsersIdDeleteResponse(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -211,14 +243,15 @@ partial void ProcessUsersDeleteUserApiV1AuthUsersIdDeleteResponse(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -258,6 +291,8 @@ partial void ProcessUsersDeleteUserApiV1AuthUsersIdDeleteResponse(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -278,6 +313,8 @@ partial void ProcessUsersDeleteUserApiV1AuthUsersIdDeleteResponse(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
//
@@ -435,6 +472,10 @@ partial void ProcessUsersDeleteUserApiV1AuthUsersIdDeleteResponse(
{
__response.EnsureSuccessStatusCode();
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri);
}
catch (global::System.Exception __ex)
{
@@ -456,6 +497,10 @@ partial void ProcessUsersDeleteUserApiV1AuthUsersIdDeleteResponse(
try
{
__response.EnsureSuccessStatusCode();
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.AuthClient.UsersPatchCurrentUserApiV1AuthUsersMePatch.g.cs b/src/libs/Presenton/Generated/Presenton.AuthClient.UsersPatchCurrentUserApiV1AuthUsersMePatch.g.cs
index 4ec18d1..0d152cd 100644
--- a/src/libs/Presenton/Generated/Presenton.AuthClient.UsersPatchCurrentUserApiV1AuthUsersMePatch.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.AuthClient.UsersPatchCurrentUserApiV1AuthUsersMePatch.g.cs
@@ -50,6 +50,28 @@ partial void ProcessUsersPatchCurrentUserApiV1AuthUsersMePatchResponseContent(
///
public async global::System.Threading.Tasks.Task UsersPatchCurrentUserApiV1AuthUsersMePatchAsync(
+ global::Presenton.UserUpdate request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await UsersPatchCurrentUserApiV1AuthUsersMePatchAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Users:Patch Current User
+ ///
+ ///
+ /// 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> UsersPatchCurrentUserApiV1AuthUsersMePatchAsResponseAsync(
+
global::Presenton.UserUpdate request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -84,6 +106,7 @@ partial void ProcessUsersPatchCurrentUserApiV1AuthUsersMePatchResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/auth/users/me",
baseUri: HttpClient.BaseAddress);
@@ -163,6 +186,8 @@ partial void ProcessUsersPatchCurrentUserApiV1AuthUsersMePatchResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -173,6 +198,11 @@ partial void ProcessUsersPatchCurrentUserApiV1AuthUsersMePatchResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -190,6 +220,8 @@ partial void ProcessUsersPatchCurrentUserApiV1AuthUsersMePatchResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -199,8 +231,7 @@ partial void ProcessUsersPatchCurrentUserApiV1AuthUsersMePatchResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -209,6 +240,11 @@ partial void ProcessUsersPatchCurrentUserApiV1AuthUsersMePatchResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -225,14 +261,15 @@ partial void ProcessUsersPatchCurrentUserApiV1AuthUsersMePatchResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -272,6 +309,8 @@ partial void ProcessUsersPatchCurrentUserApiV1AuthUsersMePatchResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -292,6 +331,8 @@ partial void ProcessUsersPatchCurrentUserApiV1AuthUsersMePatchResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Bad Request
@@ -425,9 +466,13 @@ partial void ProcessUsersPatchCurrentUserApiV1AuthUsersMePatchResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.UserRead.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.UserRead.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -455,9 +500,13 @@ partial void ProcessUsersPatchCurrentUserApiV1AuthUsersMePatchResponseContent(
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.UserRead.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.UserRead.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.AuthClient.UsersPatchUserApiV1AuthUsersIdPatch.g.cs b/src/libs/Presenton/Generated/Presenton.AuthClient.UsersPatchUserApiV1AuthUsersIdPatch.g.cs
index 04627b2..787911f 100644
--- a/src/libs/Presenton/Generated/Presenton.AuthClient.UsersPatchUserApiV1AuthUsersIdPatch.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.AuthClient.UsersPatchUserApiV1AuthUsersIdPatch.g.cs
@@ -54,6 +54,31 @@ partial void ProcessUsersPatchUserApiV1AuthUsersIdPatchResponseContent(
public async global::System.Threading.Tasks.Task UsersPatchUserApiV1AuthUsersIdPatchAsync(
string id,
+ global::Presenton.UserUpdate request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await UsersPatchUserApiV1AuthUsersIdPatchAsResponseAsync(
+ id: id,
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Users:Patch User
+ ///
+ ///
+ ///
+ /// 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> UsersPatchUserApiV1AuthUsersIdPatchAsResponseAsync(
+ string id,
+
global::Presenton.UserUpdate request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -89,6 +114,7 @@ partial void ProcessUsersPatchUserApiV1AuthUsersIdPatchResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: $"/api/v1/auth/users/{id}",
baseUri: HttpClient.BaseAddress);
@@ -169,6 +195,8 @@ partial void ProcessUsersPatchUserApiV1AuthUsersIdPatchResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -179,6 +207,11 @@ partial void ProcessUsersPatchUserApiV1AuthUsersIdPatchResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -196,6 +229,8 @@ partial void ProcessUsersPatchUserApiV1AuthUsersIdPatchResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -205,8 +240,7 @@ partial void ProcessUsersPatchUserApiV1AuthUsersIdPatchResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -215,6 +249,11 @@ partial void ProcessUsersPatchUserApiV1AuthUsersIdPatchResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -231,14 +270,15 @@ partial void ProcessUsersPatchUserApiV1AuthUsersIdPatchResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -278,6 +318,8 @@ partial void ProcessUsersPatchUserApiV1AuthUsersIdPatchResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -298,6 +340,8 @@ partial void ProcessUsersPatchUserApiV1AuthUsersIdPatchResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Bad Request
@@ -497,9 +541,13 @@ partial void ProcessUsersPatchUserApiV1AuthUsersIdPatchResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.UserRead.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.UserRead.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -527,9 +575,13 @@ partial void ProcessUsersPatchUserApiV1AuthUsersIdPatchResponseContent(
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.UserRead.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.UserRead.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.AuthClient.UsersUserApiV1AuthUsersIdGet.g.cs b/src/libs/Presenton/Generated/Presenton.AuthClient.UsersUserApiV1AuthUsersIdGet.g.cs
index e2b3ca8..5136a37 100644
--- a/src/libs/Presenton/Generated/Presenton.AuthClient.UsersUserApiV1AuthUsersIdGet.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.AuthClient.UsersUserApiV1AuthUsersIdGet.g.cs
@@ -52,6 +52,26 @@ partial void ProcessUsersUserApiV1AuthUsersIdGetResponseContent(
string id,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await UsersUserApiV1AuthUsersIdGetAsResponseAsync(
+ id: id,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Users:User
+ ///
+ ///
+ /// 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> UsersUserApiV1AuthUsersIdGetAsResponseAsync(
+ string id,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
@@ -81,6 +101,7 @@ partial void ProcessUsersUserApiV1AuthUsersIdGetResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: $"/api/v1/auth/users/{id}",
baseUri: HttpClient.BaseAddress);
@@ -154,6 +175,8 @@ partial void ProcessUsersUserApiV1AuthUsersIdGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -164,6 +187,11 @@ partial void ProcessUsersUserApiV1AuthUsersIdGetResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -181,6 +209,8 @@ partial void ProcessUsersUserApiV1AuthUsersIdGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -190,8 +220,7 @@ partial void ProcessUsersUserApiV1AuthUsersIdGetResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -200,6 +229,11 @@ partial void ProcessUsersUserApiV1AuthUsersIdGetResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -216,14 +250,15 @@ partial void ProcessUsersUserApiV1AuthUsersIdGetResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -263,6 +298,8 @@ partial void ProcessUsersUserApiV1AuthUsersIdGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -283,6 +320,8 @@ partial void ProcessUsersUserApiV1AuthUsersIdGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
//
@@ -444,9 +483,13 @@ partial void ProcessUsersUserApiV1AuthUsersIdGetResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.UserRead.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.UserRead.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -474,9 +517,13 @@ partial void ProcessUsersUserApiV1AuthUsersIdGetResponseContent(
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.UserRead.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.UserRead.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.AuthClient.VerifyRequestTokenApiV1AuthRequestVerifyTokenPost.g.cs b/src/libs/Presenton/Generated/Presenton.AuthClient.VerifyRequestTokenApiV1AuthRequestVerifyTokenPost.g.cs
index fad4048..e65c7c2 100644
--- a/src/libs/Presenton/Generated/Presenton.AuthClient.VerifyRequestTokenApiV1AuthRequestVerifyTokenPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.AuthClient.VerifyRequestTokenApiV1AuthRequestVerifyTokenPost.g.cs
@@ -50,6 +50,28 @@ partial void ProcessVerifyRequestTokenApiV1AuthRequestVerifyTokenPostResponseCon
///
public async global::System.Threading.Tasks.Task VerifyRequestTokenApiV1AuthRequestVerifyTokenPostAsync(
+ global::Presenton.BodyVerifyRequestTokenApiV1AuthRequestVerifyTokenPost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await VerifyRequestTokenApiV1AuthRequestVerifyTokenPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Verify:Request-Token
+ ///
+ ///
+ /// 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> VerifyRequestTokenApiV1AuthRequestVerifyTokenPostAsResponseAsync(
+
global::Presenton.BodyVerifyRequestTokenApiV1AuthRequestVerifyTokenPost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -84,6 +106,7 @@ partial void ProcessVerifyRequestTokenApiV1AuthRequestVerifyTokenPostResponseCon
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/auth/request-verify-token",
baseUri: HttpClient.BaseAddress);
@@ -163,6 +186,8 @@ partial void ProcessVerifyRequestTokenApiV1AuthRequestVerifyTokenPostResponseCon
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -173,6 +198,11 @@ partial void ProcessVerifyRequestTokenApiV1AuthRequestVerifyTokenPostResponseCon
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -190,6 +220,8 @@ partial void ProcessVerifyRequestTokenApiV1AuthRequestVerifyTokenPostResponseCon
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -199,8 +231,7 @@ partial void ProcessVerifyRequestTokenApiV1AuthRequestVerifyTokenPostResponseCon
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -209,6 +240,11 @@ partial void ProcessVerifyRequestTokenApiV1AuthRequestVerifyTokenPostResponseCon
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -225,14 +261,15 @@ partial void ProcessVerifyRequestTokenApiV1AuthRequestVerifyTokenPostResponseCon
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -272,6 +309,8 @@ partial void ProcessVerifyRequestTokenApiV1AuthRequestVerifyTokenPostResponseCon
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -292,6 +331,8 @@ partial void ProcessVerifyRequestTokenApiV1AuthRequestVerifyTokenPostResponseCon
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -354,7 +395,11 @@ partial void ProcessVerifyRequestTokenApiV1AuthRequestVerifyTokenPostResponseCon
{
__response.EnsureSuccessStatusCode();
- return __content;
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __content);
}
catch (global::System.Exception __ex)
{
@@ -382,7 +427,11 @@ partial void ProcessVerifyRequestTokenApiV1AuthRequestVerifyTokenPostResponseCon
#endif
).ConfigureAwait(false);
- return __content;
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __content);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.AuthClient.VerifyVerifyApiV1AuthVerifyPost.g.cs b/src/libs/Presenton/Generated/Presenton.AuthClient.VerifyVerifyApiV1AuthVerifyPost.g.cs
index a6878d8..09673ec 100644
--- a/src/libs/Presenton/Generated/Presenton.AuthClient.VerifyVerifyApiV1AuthVerifyPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.AuthClient.VerifyVerifyApiV1AuthVerifyPost.g.cs
@@ -50,6 +50,28 @@ partial void ProcessVerifyVerifyApiV1AuthVerifyPostResponseContent(
///
public async global::System.Threading.Tasks.Task VerifyVerifyApiV1AuthVerifyPostAsync(
+ global::Presenton.BodyVerifyVerifyApiV1AuthVerifyPost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await VerifyVerifyApiV1AuthVerifyPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Verify:Verify
+ ///
+ ///
+ /// 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> VerifyVerifyApiV1AuthVerifyPostAsResponseAsync(
+
global::Presenton.BodyVerifyVerifyApiV1AuthVerifyPost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -84,6 +106,7 @@ partial void ProcessVerifyVerifyApiV1AuthVerifyPostResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/auth/verify",
baseUri: HttpClient.BaseAddress);
@@ -163,6 +186,8 @@ partial void ProcessVerifyVerifyApiV1AuthVerifyPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -173,6 +198,11 @@ partial void ProcessVerifyVerifyApiV1AuthVerifyPostResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -190,6 +220,8 @@ partial void ProcessVerifyVerifyApiV1AuthVerifyPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -199,8 +231,7 @@ partial void ProcessVerifyVerifyApiV1AuthVerifyPostResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -209,6 +240,11 @@ partial void ProcessVerifyVerifyApiV1AuthVerifyPostResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -225,14 +261,15 @@ partial void ProcessVerifyVerifyApiV1AuthVerifyPostResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -272,6 +309,8 @@ partial void ProcessVerifyVerifyApiV1AuthVerifyPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -292,6 +331,8 @@ partial void ProcessVerifyVerifyApiV1AuthVerifyPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Bad Request
@@ -392,9 +433,13 @@ partial void ProcessVerifyVerifyApiV1AuthVerifyPostResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.UserRead.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.UserRead.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -422,9 +467,13 @@ partial void ProcessVerifyVerifyApiV1AuthVerifyPostResponseContent(
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.UserRead.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.UserRead.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.AuthClient.g.cs b/src/libs/Presenton/Generated/Presenton.AuthClient.g.cs
index ab38c05..1ab0379 100644
--- a/src/libs/Presenton/Generated/Presenton.AuthClient.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.AuthClient.g.cs
@@ -72,10 +72,10 @@ public AuthClient(
/// Client-wide request defaults such as headers, query parameters, retries, and timeout.
/// Dispose the HttpClient when the instance is disposed. True by default.
public AuthClient(
- global::System.Net.Http.HttpClient? httpClient = null,
- global::System.Uri? baseUri = null,
- global::System.Collections.Generic.List? authorizations = null,
- global::Presenton.AutoSDKClientOptions? options = null,
+ global::System.Net.Http.HttpClient? httpClient,
+ global::System.Uri? baseUri,
+ global::System.Collections.Generic.List? authorizations,
+ global::Presenton.AutoSDKClientOptions? options,
bool disposeHttpClient = true)
{
diff --git a/src/libs/Presenton/Generated/Presenton.AutoSDKHttpResponse.g.cs b/src/libs/Presenton/Generated/Presenton.AutoSDKHttpResponse.g.cs
new file mode 100644
index 0000000..97a2688
--- /dev/null
+++ b/src/libs/Presenton/Generated/Presenton.AutoSDKHttpResponse.g.cs
@@ -0,0 +1,121 @@
+
+#nullable enable
+
+namespace Presenton
+{
+ ///
+ /// Represents a successful HTTP response with status code and headers.
+ ///
+ public partial class AutoSDKHttpResponse
+ {
+ ///
+ /// Initializes a new instance of the class.
+ ///
+ public AutoSDKHttpResponse(
+ global::System.Net.HttpStatusCode statusCode,
+ global::System.Collections.Generic.Dictionary> headers)
+ : this(
+ statusCode: statusCode,
+ headers: headers,
+ requestUri: null)
+ {
+ }
+
+ ///
+ /// Initializes a new instance of the class.
+ ///
+ public AutoSDKHttpResponse(
+ global::System.Net.HttpStatusCode statusCode,
+ global::System.Collections.Generic.Dictionary> headers,
+ global::System.Uri? requestUri)
+ {
+ StatusCode = statusCode;
+ Headers = headers ?? throw new global::System.ArgumentNullException(nameof(headers));
+ RequestUri = requestUri;
+ }
+
+ ///
+ /// Gets the HTTP status code.
+ ///
+ public global::System.Net.HttpStatusCode StatusCode { get; }
+ ///
+ /// Gets the response headers.
+ ///
+ public global::System.Collections.Generic.Dictionary> Headers { get; }
+ ///
+ /// Gets the final request URI associated with the response.
+ ///
+ public global::System.Uri? RequestUri { get; }
+
+ internal static global::System.Collections.Generic.Dictionary> CreateHeaders(
+ global::System.Net.Http.HttpResponseMessage response)
+ {
+ response = response ?? throw new global::System.ArgumentNullException(nameof(response));
+
+ var headers = global::System.Linq.Enumerable.ToDictionary(
+ response.Headers,
+ static header => header.Key,
+ static header => (global::System.Collections.Generic.IEnumerable)global::System.Linq.Enumerable.ToArray(header.Value),
+ global::System.StringComparer.OrdinalIgnoreCase);
+
+ if (response.Content?.Headers == null)
+ {
+ return headers;
+ }
+
+ foreach (var header in response.Content.Headers)
+ {
+ if (headers.TryGetValue(header.Key, out var existingValues))
+ {
+ headers[header.Key] = global::System.Linq.Enumerable.ToArray(
+ global::System.Linq.Enumerable.Concat(existingValues, header.Value));
+ }
+ else
+ {
+ headers[header.Key] = global::System.Linq.Enumerable.ToArray(header.Value);
+ }
+ }
+
+ return headers;
+ }
+ }
+
+ ///
+ /// Represents a successful HTTP response with status code, headers, and body.
+ ///
+ public partial class AutoSDKHttpResponse : AutoSDKHttpResponse
+ {
+ ///
+ /// Initializes a new instance of the class.
+ ///
+ public AutoSDKHttpResponse(
+ global::System.Net.HttpStatusCode statusCode,
+ global::System.Collections.Generic.Dictionary> headers,
+ T body)
+ : this(
+ statusCode: statusCode,
+ headers: headers,
+ requestUri: null,
+ body: body)
+ {
+ }
+
+ ///
+ /// Initializes a new instance of the class.
+ ///
+ public AutoSDKHttpResponse(
+ global::System.Net.HttpStatusCode statusCode,
+ global::System.Collections.Generic.Dictionary> headers,
+ global::System.Uri? requestUri,
+ T body)
+ : base(statusCode, headers, requestUri)
+ {
+ Body = body;
+ }
+
+ ///
+ /// Gets the response body.
+ ///
+ public T Body { get; }
+ }
+}
\ No newline at end of file
diff --git a/src/libs/Presenton/Generated/Presenton.BillingClient.CreateCheckoutSessionApiV1BillingCheckoutSessionPost.g.cs b/src/libs/Presenton/Generated/Presenton.BillingClient.CreateCheckoutSessionApiV1BillingCheckoutSessionPost.g.cs
index f8e1a5c..51f175f 100644
--- a/src/libs/Presenton/Generated/Presenton.BillingClient.CreateCheckoutSessionApiV1BillingCheckoutSessionPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.BillingClient.CreateCheckoutSessionApiV1BillingCheckoutSessionPost.g.cs
@@ -50,6 +50,28 @@ partial void ProcessCreateCheckoutSessionApiV1BillingCheckoutSessionPostResponse
///
public async global::System.Threading.Tasks.Task CreateCheckoutSessionApiV1BillingCheckoutSessionPostAsync(
+ global::Presenton.CreateCheckoutSessionRequest request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await CreateCheckoutSessionApiV1BillingCheckoutSessionPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Create Checkout Session
+ ///
+ ///
+ /// 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> CreateCheckoutSessionApiV1BillingCheckoutSessionPostAsResponseAsync(
+
global::Presenton.CreateCheckoutSessionRequest request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -84,6 +106,7 @@ partial void ProcessCreateCheckoutSessionApiV1BillingCheckoutSessionPostResponse
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/billing/checkout/session",
baseUri: HttpClient.BaseAddress);
@@ -163,6 +186,8 @@ partial void ProcessCreateCheckoutSessionApiV1BillingCheckoutSessionPostResponse
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -173,6 +198,11 @@ partial void ProcessCreateCheckoutSessionApiV1BillingCheckoutSessionPostResponse
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -190,6 +220,8 @@ partial void ProcessCreateCheckoutSessionApiV1BillingCheckoutSessionPostResponse
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -199,8 +231,7 @@ partial void ProcessCreateCheckoutSessionApiV1BillingCheckoutSessionPostResponse
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -209,6 +240,11 @@ partial void ProcessCreateCheckoutSessionApiV1BillingCheckoutSessionPostResponse
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -225,14 +261,15 @@ partial void ProcessCreateCheckoutSessionApiV1BillingCheckoutSessionPostResponse
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -272,6 +309,8 @@ partial void ProcessCreateCheckoutSessionApiV1BillingCheckoutSessionPostResponse
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -292,6 +331,8 @@ partial void ProcessCreateCheckoutSessionApiV1BillingCheckoutSessionPostResponse
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -354,9 +395,13 @@ partial void ProcessCreateCheckoutSessionApiV1BillingCheckoutSessionPostResponse
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.CreateCheckoutSessionResponse.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.CreateCheckoutSessionResponse.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -384,9 +429,13 @@ partial void ProcessCreateCheckoutSessionApiV1BillingCheckoutSessionPostResponse
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.CreateCheckoutSessionResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.CreateCheckoutSessionResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.BillingClient.CreatePortalSessionApiV1BillingPortalSessionPost.g.cs b/src/libs/Presenton/Generated/Presenton.BillingClient.CreatePortalSessionApiV1BillingPortalSessionPost.g.cs
index 44e3039..77df178 100644
--- a/src/libs/Presenton/Generated/Presenton.BillingClient.CreatePortalSessionApiV1BillingPortalSessionPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.BillingClient.CreatePortalSessionApiV1BillingPortalSessionPost.g.cs
@@ -50,6 +50,28 @@ partial void ProcessCreatePortalSessionApiV1BillingPortalSessionPostResponseCont
///
public async global::System.Threading.Tasks.Task CreatePortalSessionApiV1BillingPortalSessionPostAsync(
+ global::Presenton.BodyCreatePortalSessionApiV1BillingPortalSessionPost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await CreatePortalSessionApiV1BillingPortalSessionPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Create Portal Session
+ ///
+ ///
+ /// 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> CreatePortalSessionApiV1BillingPortalSessionPostAsResponseAsync(
+
global::Presenton.BodyCreatePortalSessionApiV1BillingPortalSessionPost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -84,6 +106,7 @@ partial void ProcessCreatePortalSessionApiV1BillingPortalSessionPostResponseCont
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/billing/portal/session",
baseUri: HttpClient.BaseAddress);
@@ -163,6 +186,8 @@ partial void ProcessCreatePortalSessionApiV1BillingPortalSessionPostResponseCont
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -173,6 +198,11 @@ partial void ProcessCreatePortalSessionApiV1BillingPortalSessionPostResponseCont
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -190,6 +220,8 @@ partial void ProcessCreatePortalSessionApiV1BillingPortalSessionPostResponseCont
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -199,8 +231,7 @@ partial void ProcessCreatePortalSessionApiV1BillingPortalSessionPostResponseCont
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -209,6 +240,11 @@ partial void ProcessCreatePortalSessionApiV1BillingPortalSessionPostResponseCont
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -225,14 +261,15 @@ partial void ProcessCreatePortalSessionApiV1BillingPortalSessionPostResponseCont
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -272,6 +309,8 @@ partial void ProcessCreatePortalSessionApiV1BillingPortalSessionPostResponseCont
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -292,6 +331,8 @@ partial void ProcessCreatePortalSessionApiV1BillingPortalSessionPostResponseCont
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -354,9 +395,13 @@ partial void ProcessCreatePortalSessionApiV1BillingPortalSessionPostResponseCont
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.CreatePortalSessionResponse.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.CreatePortalSessionResponse.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -384,9 +429,13 @@ partial void ProcessCreatePortalSessionApiV1BillingPortalSessionPostResponseCont
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.CreatePortalSessionResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.CreatePortalSessionResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.BillingClient.GetSubscriptionStatusApiV1BillingSubscriptionGet.g.cs b/src/libs/Presenton/Generated/Presenton.BillingClient.GetSubscriptionStatusApiV1BillingSubscriptionGet.g.cs
index 90e9824..0418052 100644
--- a/src/libs/Presenton/Generated/Presenton.BillingClient.GetSubscriptionStatusApiV1BillingSubscriptionGet.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.BillingClient.GetSubscriptionStatusApiV1BillingSubscriptionGet.g.cs
@@ -54,6 +54,28 @@ partial void ProcessGetSubscriptionStatusApiV1BillingSubscriptionGetResponseCont
bool? refresh = default,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await GetSubscriptionStatusApiV1BillingSubscriptionGetAsResponseAsync(
+ refresh: refresh,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Get Subscription Status
+ ///
+ ///
+ /// Default Value: false
+ ///
+ /// 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> GetSubscriptionStatusApiV1BillingSubscriptionGetAsResponseAsync(
+ bool? refresh = default,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
@@ -83,11 +105,12 @@ partial void ProcessGetSubscriptionStatusApiV1BillingSubscriptionGetResponseCont
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/billing/subscription",
- baseUri: HttpClient.BaseAddress);
+ baseUri: HttpClient.BaseAddress);
__pathBuilder
- .AddOptionalParameter("refresh", refresh?.ToString().ToLowerInvariant())
+ .AddOptionalParameter("refresh", refresh?.ToString().ToLowerInvariant())
;
var __path = __pathBuilder.ToString();
__path = global::Presenton.AutoSDKRequestOptionsSupport.AppendQueryParameters(
@@ -159,6 +182,8 @@ partial void ProcessGetSubscriptionStatusApiV1BillingSubscriptionGetResponseCont
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -169,6 +194,11 @@ partial void ProcessGetSubscriptionStatusApiV1BillingSubscriptionGetResponseCont
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -186,6 +216,8 @@ partial void ProcessGetSubscriptionStatusApiV1BillingSubscriptionGetResponseCont
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -195,8 +227,7 @@ partial void ProcessGetSubscriptionStatusApiV1BillingSubscriptionGetResponseCont
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -205,6 +236,11 @@ partial void ProcessGetSubscriptionStatusApiV1BillingSubscriptionGetResponseCont
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -221,14 +257,15 @@ partial void ProcessGetSubscriptionStatusApiV1BillingSubscriptionGetResponseCont
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -268,6 +305,8 @@ partial void ProcessGetSubscriptionStatusApiV1BillingSubscriptionGetResponseCont
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -288,6 +327,8 @@ partial void ProcessGetSubscriptionStatusApiV1BillingSubscriptionGetResponseCont
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -350,9 +391,13 @@ partial void ProcessGetSubscriptionStatusApiV1BillingSubscriptionGetResponseCont
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.Subscription.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.Subscription.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -380,9 +425,13 @@ partial void ProcessGetSubscriptionStatusApiV1BillingSubscriptionGetResponseCont
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.Subscription.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.Subscription.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.BillingClient.ListPricesApiV1BillingPricesGet.g.cs b/src/libs/Presenton/Generated/Presenton.BillingClient.ListPricesApiV1BillingPricesGet.g.cs
index a8afc58..7bbf087 100644
--- a/src/libs/Presenton/Generated/Presenton.BillingClient.ListPricesApiV1BillingPricesGet.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.BillingClient.ListPricesApiV1BillingPricesGet.g.cs
@@ -48,6 +48,23 @@ partial void ProcessListPricesApiV1BillingPricesGetResponseContent(
public async global::System.Threading.Tasks.Task> ListPricesApiV1BillingPricesGetAsync(
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await ListPricesApiV1BillingPricesGetAsResponseAsync(
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// List Prices
+ ///
+ /// 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>> ListPricesApiV1BillingPricesGetAsResponseAsync(
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
@@ -76,6 +93,7 @@ partial void ProcessListPricesApiV1BillingPricesGetResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/billing/prices",
baseUri: HttpClient.BaseAddress);
@@ -148,6 +166,8 @@ partial void ProcessListPricesApiV1BillingPricesGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -158,6 +178,11 @@ partial void ProcessListPricesApiV1BillingPricesGetResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -175,6 +200,8 @@ partial void ProcessListPricesApiV1BillingPricesGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -184,8 +211,7 @@ partial void ProcessListPricesApiV1BillingPricesGetResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -194,6 +220,11 @@ partial void ProcessListPricesApiV1BillingPricesGetResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -210,14 +241,15 @@ partial void ProcessListPricesApiV1BillingPricesGetResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -257,6 +289,8 @@ partial void ProcessListPricesApiV1BillingPricesGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -277,6 +311,8 @@ partial void ProcessListPricesApiV1BillingPricesGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
@@ -301,9 +337,13 @@ partial void ProcessListPricesApiV1BillingPricesGetResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- (global::System.Collections.Generic.IList?)global::System.Text.Json.JsonSerializer.Deserialize(__content, typeof(global::System.Collections.Generic.IList), JsonSerializerContext) ??
+ var __value = (global::System.Collections.Generic.IList?)global::System.Text.Json.JsonSerializer.Deserialize(__content, typeof(global::System.Collections.Generic.IList), JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse>(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -331,9 +371,13 @@ partial void ProcessListPricesApiV1BillingPricesGetResponseContent(
#endif
).ConfigureAwait(false);
- return
- (global::System.Collections.Generic.IList?)await global::System.Text.Json.JsonSerializer.DeserializeAsync(__content, typeof(global::System.Collections.Generic.IList), JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = (global::System.Collections.Generic.IList?)await global::System.Text.Json.JsonSerializer.DeserializeAsync(__content, typeof(global::System.Collections.Generic.IList), JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse>(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.BillingClient.ModifySubscriptionApiV1BillingSubscriptionModifyPost.g.cs b/src/libs/Presenton/Generated/Presenton.BillingClient.ModifySubscriptionApiV1BillingSubscriptionModifyPost.g.cs
index c3a6c56..a3f7f4e 100644
--- a/src/libs/Presenton/Generated/Presenton.BillingClient.ModifySubscriptionApiV1BillingSubscriptionModifyPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.BillingClient.ModifySubscriptionApiV1BillingSubscriptionModifyPost.g.cs
@@ -50,6 +50,28 @@ partial void ProcessModifySubscriptionApiV1BillingSubscriptionModifyPostResponse
///
public async global::System.Threading.Tasks.Task ModifySubscriptionApiV1BillingSubscriptionModifyPostAsync(
+ global::Presenton.BodyModifySubscriptionApiV1BillingSubscriptionModifyPost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await ModifySubscriptionApiV1BillingSubscriptionModifyPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Modify Subscription
+ ///
+ ///
+ /// 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> ModifySubscriptionApiV1BillingSubscriptionModifyPostAsResponseAsync(
+
global::Presenton.BodyModifySubscriptionApiV1BillingSubscriptionModifyPost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -84,6 +106,7 @@ partial void ProcessModifySubscriptionApiV1BillingSubscriptionModifyPostResponse
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/billing/subscription/modify",
baseUri: HttpClient.BaseAddress);
@@ -163,6 +186,8 @@ partial void ProcessModifySubscriptionApiV1BillingSubscriptionModifyPostResponse
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -173,6 +198,11 @@ partial void ProcessModifySubscriptionApiV1BillingSubscriptionModifyPostResponse
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -190,6 +220,8 @@ partial void ProcessModifySubscriptionApiV1BillingSubscriptionModifyPostResponse
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -199,8 +231,7 @@ partial void ProcessModifySubscriptionApiV1BillingSubscriptionModifyPostResponse
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -209,6 +240,11 @@ partial void ProcessModifySubscriptionApiV1BillingSubscriptionModifyPostResponse
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -225,14 +261,15 @@ partial void ProcessModifySubscriptionApiV1BillingSubscriptionModifyPostResponse
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -272,6 +309,8 @@ partial void ProcessModifySubscriptionApiV1BillingSubscriptionModifyPostResponse
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -292,6 +331,8 @@ partial void ProcessModifySubscriptionApiV1BillingSubscriptionModifyPostResponse
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -354,9 +395,13 @@ partial void ProcessModifySubscriptionApiV1BillingSubscriptionModifyPostResponse
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.ModifySubscriptionResponse.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.ModifySubscriptionResponse.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -384,9 +429,13 @@ partial void ProcessModifySubscriptionApiV1BillingSubscriptionModifyPostResponse
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.ModifySubscriptionResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.ModifySubscriptionResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.BillingClient.PurchaseCreditsApiV1BillingCreditsPurchasePost.g.cs b/src/libs/Presenton/Generated/Presenton.BillingClient.PurchaseCreditsApiV1BillingCreditsPurchasePost.g.cs
index 88d8f9c..3cfcda6 100644
--- a/src/libs/Presenton/Generated/Presenton.BillingClient.PurchaseCreditsApiV1BillingCreditsPurchasePost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.BillingClient.PurchaseCreditsApiV1BillingCreditsPurchasePost.g.cs
@@ -50,6 +50,28 @@ partial void ProcessPurchaseCreditsApiV1BillingCreditsPurchasePostResponseConten
///
public async global::System.Threading.Tasks.Task PurchaseCreditsApiV1BillingCreditsPurchasePostAsync(
+ global::Presenton.PurchaseCreditsRequest request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await PurchaseCreditsApiV1BillingCreditsPurchasePostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Purchase Credits
+ ///
+ ///
+ /// 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> PurchaseCreditsApiV1BillingCreditsPurchasePostAsResponseAsync(
+
global::Presenton.PurchaseCreditsRequest request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -84,6 +106,7 @@ partial void ProcessPurchaseCreditsApiV1BillingCreditsPurchasePostResponseConten
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/billing/credits/purchase",
baseUri: HttpClient.BaseAddress);
@@ -163,6 +186,8 @@ partial void ProcessPurchaseCreditsApiV1BillingCreditsPurchasePostResponseConten
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -173,6 +198,11 @@ partial void ProcessPurchaseCreditsApiV1BillingCreditsPurchasePostResponseConten
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -190,6 +220,8 @@ partial void ProcessPurchaseCreditsApiV1BillingCreditsPurchasePostResponseConten
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -199,8 +231,7 @@ partial void ProcessPurchaseCreditsApiV1BillingCreditsPurchasePostResponseConten
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -209,6 +240,11 @@ partial void ProcessPurchaseCreditsApiV1BillingCreditsPurchasePostResponseConten
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -225,14 +261,15 @@ partial void ProcessPurchaseCreditsApiV1BillingCreditsPurchasePostResponseConten
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -272,6 +309,8 @@ partial void ProcessPurchaseCreditsApiV1BillingCreditsPurchasePostResponseConten
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -292,6 +331,8 @@ partial void ProcessPurchaseCreditsApiV1BillingCreditsPurchasePostResponseConten
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -354,9 +395,13 @@ partial void ProcessPurchaseCreditsApiV1BillingCreditsPurchasePostResponseConten
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.CreateCheckoutSessionResponse.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.CreateCheckoutSessionResponse.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -384,9 +429,13 @@ partial void ProcessPurchaseCreditsApiV1BillingCreditsPurchasePostResponseConten
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.CreateCheckoutSessionResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.CreateCheckoutSessionResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.BillingClient.ReactivateSubscriptionApiV1BillingSubscriptionReactivatePost.g.cs b/src/libs/Presenton/Generated/Presenton.BillingClient.ReactivateSubscriptionApiV1BillingSubscriptionReactivatePost.g.cs
index f932859..7641ef7 100644
--- a/src/libs/Presenton/Generated/Presenton.BillingClient.ReactivateSubscriptionApiV1BillingSubscriptionReactivatePost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.BillingClient.ReactivateSubscriptionApiV1BillingSubscriptionReactivatePost.g.cs
@@ -48,6 +48,23 @@ partial void ProcessReactivateSubscriptionApiV1BillingSubscriptionReactivatePost
public async global::System.Threading.Tasks.Task ReactivateSubscriptionApiV1BillingSubscriptionReactivatePostAsync(
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await ReactivateSubscriptionApiV1BillingSubscriptionReactivatePostAsResponseAsync(
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Reactivate Subscription
+ ///
+ /// 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> ReactivateSubscriptionApiV1BillingSubscriptionReactivatePostAsResponseAsync(
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
@@ -76,6 +93,7 @@ partial void ProcessReactivateSubscriptionApiV1BillingSubscriptionReactivatePost
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/billing/subscription/reactivate",
baseUri: HttpClient.BaseAddress);
@@ -148,6 +166,8 @@ partial void ProcessReactivateSubscriptionApiV1BillingSubscriptionReactivatePost
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -158,6 +178,11 @@ partial void ProcessReactivateSubscriptionApiV1BillingSubscriptionReactivatePost
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -175,6 +200,8 @@ partial void ProcessReactivateSubscriptionApiV1BillingSubscriptionReactivatePost
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -184,8 +211,7 @@ partial void ProcessReactivateSubscriptionApiV1BillingSubscriptionReactivatePost
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -194,6 +220,11 @@ partial void ProcessReactivateSubscriptionApiV1BillingSubscriptionReactivatePost
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -210,14 +241,15 @@ partial void ProcessReactivateSubscriptionApiV1BillingSubscriptionReactivatePost
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -257,6 +289,8 @@ partial void ProcessReactivateSubscriptionApiV1BillingSubscriptionReactivatePost
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -277,6 +311,8 @@ partial void ProcessReactivateSubscriptionApiV1BillingSubscriptionReactivatePost
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
@@ -301,9 +337,13 @@ partial void ProcessReactivateSubscriptionApiV1BillingSubscriptionReactivatePost
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.ReactivateSubscriptionResponse.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.ReactivateSubscriptionResponse.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -331,9 +371,13 @@ partial void ProcessReactivateSubscriptionApiV1BillingSubscriptionReactivatePost
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.ReactivateSubscriptionResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.ReactivateSubscriptionResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.BillingClient.StripeWebhookApiV1BillingWebhookPost.g.cs b/src/libs/Presenton/Generated/Presenton.BillingClient.StripeWebhookApiV1BillingWebhookPost.g.cs
index 8e06b99..2ec6e47 100644
--- a/src/libs/Presenton/Generated/Presenton.BillingClient.StripeWebhookApiV1BillingWebhookPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.BillingClient.StripeWebhookApiV1BillingWebhookPost.g.cs
@@ -48,6 +48,23 @@ partial void ProcessStripeWebhookApiV1BillingWebhookPostResponseContent(
public async global::System.Threading.Tasks.Task StripeWebhookApiV1BillingWebhookPostAsync(
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await StripeWebhookApiV1BillingWebhookPostAsResponseAsync(
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Stripe Webhook
+ ///
+ /// 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> StripeWebhookApiV1BillingWebhookPostAsResponseAsync(
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
@@ -76,6 +93,7 @@ partial void ProcessStripeWebhookApiV1BillingWebhookPostResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/billing/webhook",
baseUri: HttpClient.BaseAddress);
@@ -148,6 +166,8 @@ partial void ProcessStripeWebhookApiV1BillingWebhookPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -158,6 +178,11 @@ partial void ProcessStripeWebhookApiV1BillingWebhookPostResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -175,6 +200,8 @@ partial void ProcessStripeWebhookApiV1BillingWebhookPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -184,8 +211,7 @@ partial void ProcessStripeWebhookApiV1BillingWebhookPostResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -194,6 +220,11 @@ partial void ProcessStripeWebhookApiV1BillingWebhookPostResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -210,14 +241,15 @@ partial void ProcessStripeWebhookApiV1BillingWebhookPostResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -257,6 +289,8 @@ partial void ProcessStripeWebhookApiV1BillingWebhookPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -277,6 +311,8 @@ partial void ProcessStripeWebhookApiV1BillingWebhookPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
@@ -301,7 +337,11 @@ partial void ProcessStripeWebhookApiV1BillingWebhookPostResponseContent(
{
__response.EnsureSuccessStatusCode();
- return __content;
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __content);
}
catch (global::System.Exception __ex)
{
@@ -329,7 +369,11 @@ partial void ProcessStripeWebhookApiV1BillingWebhookPostResponseContent(
#endif
).ConfigureAwait(false);
- return __content;
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __content);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.BillingClient.g.cs b/src/libs/Presenton/Generated/Presenton.BillingClient.g.cs
index 586c5c3..2b2abee 100644
--- a/src/libs/Presenton/Generated/Presenton.BillingClient.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.BillingClient.g.cs
@@ -72,10 +72,10 @@ public BillingClient(
/// Client-wide request defaults such as headers, query parameters, retries, and timeout.
/// Dispose the HttpClient when the instance is disposed. True by default.
public BillingClient(
- global::System.Net.Http.HttpClient? httpClient = null,
- global::System.Uri? baseUri = null,
- global::System.Collections.Generic.List? authorizations = null,
- global::Presenton.AutoSDKClientOptions? options = null,
+ global::System.Net.Http.HttpClient? httpClient,
+ global::System.Uri? baseUri,
+ global::System.Collections.Generic.List? authorizations,
+ global::Presenton.AutoSDKClientOptions? options,
bool disposeHttpClient = true)
{
diff --git a/src/libs/Presenton/Generated/Presenton.CreditClient.GetAddedCreditsApiV1CreditAddedGet.g.cs b/src/libs/Presenton/Generated/Presenton.CreditClient.GetAddedCreditsApiV1CreditAddedGet.g.cs
index f41b30c..fe79f5e 100644
--- a/src/libs/Presenton/Generated/Presenton.CreditClient.GetAddedCreditsApiV1CreditAddedGet.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.CreditClient.GetAddedCreditsApiV1CreditAddedGet.g.cs
@@ -60,6 +60,33 @@ partial void ProcessGetAddedCreditsApiV1CreditAddedGetResponseContent(
int? pageSize = default,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await GetAddedCreditsApiV1CreditAddedGetAsResponseAsync(
+ page: page,
+ pageSize: pageSize,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Get Added Credits
+ ///
+ ///
+ /// Default Value: 1
+ ///
+ ///
+ /// Default Value: 10
+ ///
+ /// 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> GetAddedCreditsApiV1CreditAddedGetAsResponseAsync(
+ int? page = default,
+ int? pageSize = default,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
@@ -90,12 +117,13 @@ partial void ProcessGetAddedCreditsApiV1CreditAddedGetResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/credit/added",
- baseUri: HttpClient.BaseAddress);
+ baseUri: HttpClient.BaseAddress);
__pathBuilder
.AddOptionalParameter("page", page?.ToString())
- .AddOptionalParameter("page_size", pageSize?.ToString())
+ .AddOptionalParameter("page_size", pageSize?.ToString())
;
var __path = __pathBuilder.ToString();
__path = global::Presenton.AutoSDKRequestOptionsSupport.AppendQueryParameters(
@@ -168,6 +196,8 @@ partial void ProcessGetAddedCreditsApiV1CreditAddedGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -178,6 +208,11 @@ partial void ProcessGetAddedCreditsApiV1CreditAddedGetResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -195,6 +230,8 @@ partial void ProcessGetAddedCreditsApiV1CreditAddedGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -204,8 +241,7 @@ partial void ProcessGetAddedCreditsApiV1CreditAddedGetResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -214,6 +250,11 @@ partial void ProcessGetAddedCreditsApiV1CreditAddedGetResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -230,14 +271,15 @@ partial void ProcessGetAddedCreditsApiV1CreditAddedGetResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -277,6 +319,8 @@ partial void ProcessGetAddedCreditsApiV1CreditAddedGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -297,6 +341,8 @@ partial void ProcessGetAddedCreditsApiV1CreditAddedGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -359,9 +405,13 @@ partial void ProcessGetAddedCreditsApiV1CreditAddedGetResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.PaginatedResponse.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.PaginatedResponse.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -389,9 +439,13 @@ partial void ProcessGetAddedCreditsApiV1CreditAddedGetResponseContent(
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.PaginatedResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.PaginatedResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.CreditClient.GetBalanceApiV1CreditBalanceGet.g.cs b/src/libs/Presenton/Generated/Presenton.CreditClient.GetBalanceApiV1CreditBalanceGet.g.cs
index ea078dd..a9910ba 100644
--- a/src/libs/Presenton/Generated/Presenton.CreditClient.GetBalanceApiV1CreditBalanceGet.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.CreditClient.GetBalanceApiV1CreditBalanceGet.g.cs
@@ -48,6 +48,23 @@ partial void ProcessGetBalanceApiV1CreditBalanceGetResponseContent(
public async global::System.Threading.Tasks.Task GetBalanceApiV1CreditBalanceGetAsync(
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await GetBalanceApiV1CreditBalanceGetAsResponseAsync(
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Get Balance
+ ///
+ /// 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> GetBalanceApiV1CreditBalanceGetAsResponseAsync(
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
@@ -76,6 +93,7 @@ partial void ProcessGetBalanceApiV1CreditBalanceGetResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/credit/balance",
baseUri: HttpClient.BaseAddress);
@@ -148,6 +166,8 @@ partial void ProcessGetBalanceApiV1CreditBalanceGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -158,6 +178,11 @@ partial void ProcessGetBalanceApiV1CreditBalanceGetResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -175,6 +200,8 @@ partial void ProcessGetBalanceApiV1CreditBalanceGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -184,8 +211,7 @@ partial void ProcessGetBalanceApiV1CreditBalanceGetResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -194,6 +220,11 @@ partial void ProcessGetBalanceApiV1CreditBalanceGetResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -210,14 +241,15 @@ partial void ProcessGetBalanceApiV1CreditBalanceGetResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -257,6 +289,8 @@ partial void ProcessGetBalanceApiV1CreditBalanceGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -277,6 +311,8 @@ partial void ProcessGetBalanceApiV1CreditBalanceGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
@@ -301,9 +337,13 @@ partial void ProcessGetBalanceApiV1CreditBalanceGetResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.CreditAccountWithBalance.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.CreditAccountWithBalance.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -331,9 +371,13 @@ partial void ProcessGetBalanceApiV1CreditBalanceGetResponseContent(
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.CreditAccountWithBalance.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.CreditAccountWithBalance.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.CreditClient.GetCreditAccountApiV1CreditAccountGet.g.cs b/src/libs/Presenton/Generated/Presenton.CreditClient.GetCreditAccountApiV1CreditAccountGet.g.cs
index fc3e08c..e11a247 100644
--- a/src/libs/Presenton/Generated/Presenton.CreditClient.GetCreditAccountApiV1CreditAccountGet.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.CreditClient.GetCreditAccountApiV1CreditAccountGet.g.cs
@@ -48,6 +48,23 @@ partial void ProcessGetCreditAccountApiV1CreditAccountGetResponseContent(
public async global::System.Threading.Tasks.Task GetCreditAccountApiV1CreditAccountGetAsync(
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await GetCreditAccountApiV1CreditAccountGetAsResponseAsync(
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Get Credit Account
+ ///
+ /// 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> GetCreditAccountApiV1CreditAccountGetAsResponseAsync(
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
@@ -76,6 +93,7 @@ partial void ProcessGetCreditAccountApiV1CreditAccountGetResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/credit/account",
baseUri: HttpClient.BaseAddress);
@@ -148,6 +166,8 @@ partial void ProcessGetCreditAccountApiV1CreditAccountGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -158,6 +178,11 @@ partial void ProcessGetCreditAccountApiV1CreditAccountGetResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -175,6 +200,8 @@ partial void ProcessGetCreditAccountApiV1CreditAccountGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -184,8 +211,7 @@ partial void ProcessGetCreditAccountApiV1CreditAccountGetResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -194,6 +220,11 @@ partial void ProcessGetCreditAccountApiV1CreditAccountGetResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -210,14 +241,15 @@ partial void ProcessGetCreditAccountApiV1CreditAccountGetResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -257,6 +289,8 @@ partial void ProcessGetCreditAccountApiV1CreditAccountGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -277,6 +311,8 @@ partial void ProcessGetCreditAccountApiV1CreditAccountGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
@@ -301,9 +337,13 @@ partial void ProcessGetCreditAccountApiV1CreditAccountGetResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.CreditAccount.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.CreditAccount.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -331,9 +371,13 @@ partial void ProcessGetCreditAccountApiV1CreditAccountGetResponseContent(
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.CreditAccount.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.CreditAccount.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.CreditClient.GetCreditsRatesAndAutoTopupInfoApiV1CreditInfoGet.g.cs b/src/libs/Presenton/Generated/Presenton.CreditClient.GetCreditsRatesAndAutoTopupInfoApiV1CreditInfoGet.g.cs
index 47c039a..e3adce7 100644
--- a/src/libs/Presenton/Generated/Presenton.CreditClient.GetCreditsRatesAndAutoTopupInfoApiV1CreditInfoGet.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.CreditClient.GetCreditsRatesAndAutoTopupInfoApiV1CreditInfoGet.g.cs
@@ -48,6 +48,23 @@ partial void ProcessGetCreditsRatesAndAutoTopupInfoApiV1CreditInfoGetResponseCon
public async global::System.Threading.Tasks.Task GetCreditsRatesAndAutoTopupInfoApiV1CreditInfoGetAsync(
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await GetCreditsRatesAndAutoTopupInfoApiV1CreditInfoGetAsResponseAsync(
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Get Credits Rates And Auto Topup Info
+ ///
+ /// 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> GetCreditsRatesAndAutoTopupInfoApiV1CreditInfoGetAsResponseAsync(
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
@@ -76,6 +93,7 @@ partial void ProcessGetCreditsRatesAndAutoTopupInfoApiV1CreditInfoGetResponseCon
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/credit/info",
baseUri: HttpClient.BaseAddress);
@@ -148,6 +166,8 @@ partial void ProcessGetCreditsRatesAndAutoTopupInfoApiV1CreditInfoGetResponseCon
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -158,6 +178,11 @@ partial void ProcessGetCreditsRatesAndAutoTopupInfoApiV1CreditInfoGetResponseCon
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -175,6 +200,8 @@ partial void ProcessGetCreditsRatesAndAutoTopupInfoApiV1CreditInfoGetResponseCon
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -184,8 +211,7 @@ partial void ProcessGetCreditsRatesAndAutoTopupInfoApiV1CreditInfoGetResponseCon
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -194,6 +220,11 @@ partial void ProcessGetCreditsRatesAndAutoTopupInfoApiV1CreditInfoGetResponseCon
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -210,14 +241,15 @@ partial void ProcessGetCreditsRatesAndAutoTopupInfoApiV1CreditInfoGetResponseCon
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -257,6 +289,8 @@ partial void ProcessGetCreditsRatesAndAutoTopupInfoApiV1CreditInfoGetResponseCon
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -277,6 +311,8 @@ partial void ProcessGetCreditsRatesAndAutoTopupInfoApiV1CreditInfoGetResponseCon
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -339,9 +375,13 @@ partial void ProcessGetCreditsRatesAndAutoTopupInfoApiV1CreditInfoGetResponseCon
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.CreditsRatesAndAutoTopupInfoResponse.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.CreditsRatesAndAutoTopupInfoResponse.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -369,9 +409,13 @@ partial void ProcessGetCreditsRatesAndAutoTopupInfoApiV1CreditInfoGetResponseCon
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.CreditsRatesAndAutoTopupInfoResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.CreditsRatesAndAutoTopupInfoResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.CreditClient.GetTransactionsApiV1CreditTransactionsGet.g.cs b/src/libs/Presenton/Generated/Presenton.CreditClient.GetTransactionsApiV1CreditTransactionsGet.g.cs
index d573833..8613ae9 100644
--- a/src/libs/Presenton/Generated/Presenton.CreditClient.GetTransactionsApiV1CreditTransactionsGet.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.CreditClient.GetTransactionsApiV1CreditTransactionsGet.g.cs
@@ -60,6 +60,33 @@ partial void ProcessGetTransactionsApiV1CreditTransactionsGetResponseContent(
int? pageSize = default,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await GetTransactionsApiV1CreditTransactionsGetAsResponseAsync(
+ page: page,
+ pageSize: pageSize,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Get Transactions
+ ///
+ ///
+ /// Default Value: 1
+ ///
+ ///
+ /// Default Value: 10
+ ///
+ /// 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> GetTransactionsApiV1CreditTransactionsGetAsResponseAsync(
+ int? page = default,
+ int? pageSize = default,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
@@ -90,12 +117,13 @@ partial void ProcessGetTransactionsApiV1CreditTransactionsGetResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/credit/transactions",
- baseUri: HttpClient.BaseAddress);
+ baseUri: HttpClient.BaseAddress);
__pathBuilder
.AddOptionalParameter("page", page?.ToString())
- .AddOptionalParameter("page_size", pageSize?.ToString())
+ .AddOptionalParameter("page_size", pageSize?.ToString())
;
var __path = __pathBuilder.ToString();
__path = global::Presenton.AutoSDKRequestOptionsSupport.AppendQueryParameters(
@@ -168,6 +196,8 @@ partial void ProcessGetTransactionsApiV1CreditTransactionsGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -178,6 +208,11 @@ partial void ProcessGetTransactionsApiV1CreditTransactionsGetResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -195,6 +230,8 @@ partial void ProcessGetTransactionsApiV1CreditTransactionsGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -204,8 +241,7 @@ partial void ProcessGetTransactionsApiV1CreditTransactionsGetResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -214,6 +250,11 @@ partial void ProcessGetTransactionsApiV1CreditTransactionsGetResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -230,14 +271,15 @@ partial void ProcessGetTransactionsApiV1CreditTransactionsGetResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -277,6 +319,8 @@ partial void ProcessGetTransactionsApiV1CreditTransactionsGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -297,6 +341,8 @@ partial void ProcessGetTransactionsApiV1CreditTransactionsGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -359,9 +405,13 @@ partial void ProcessGetTransactionsApiV1CreditTransactionsGetResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.PaginatedResponse.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.PaginatedResponse.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -389,9 +439,13 @@ partial void ProcessGetTransactionsApiV1CreditTransactionsGetResponseContent(
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.PaginatedResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.PaginatedResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.CreditClient.GetUsedCreditsApiV1CreditAddedIdUsedGet.g.cs b/src/libs/Presenton/Generated/Presenton.CreditClient.GetUsedCreditsApiV1CreditAddedIdUsedGet.g.cs
index 409bb8b..7ae5cf0 100644
--- a/src/libs/Presenton/Generated/Presenton.CreditClient.GetUsedCreditsApiV1CreditAddedIdUsedGet.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.CreditClient.GetUsedCreditsApiV1CreditAddedIdUsedGet.g.cs
@@ -64,6 +64,36 @@ partial void ProcessGetUsedCreditsApiV1CreditAddedIdUsedGetResponseContent(
int? pageSize = default,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await GetUsedCreditsApiV1CreditAddedIdUsedGetAsResponseAsync(
+ id: id,
+ page: page,
+ pageSize: pageSize,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Get Used Credits
+ ///
+ ///
+ ///
+ /// Default Value: 1
+ ///
+ ///
+ /// Default Value: 10
+ ///
+ /// 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> GetUsedCreditsApiV1CreditAddedIdUsedGetAsResponseAsync(
+ global::System.Guid id,
+ int? page = default,
+ int? pageSize = default,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
@@ -95,12 +125,13 @@ partial void ProcessGetUsedCreditsApiV1CreditAddedIdUsedGetResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: $"/api/v1/credit/added/{id}/used",
- baseUri: HttpClient.BaseAddress);
+ baseUri: HttpClient.BaseAddress);
__pathBuilder
.AddOptionalParameter("page", page?.ToString())
- .AddOptionalParameter("page_size", pageSize?.ToString())
+ .AddOptionalParameter("page_size", pageSize?.ToString())
;
var __path = __pathBuilder.ToString();
__path = global::Presenton.AutoSDKRequestOptionsSupport.AppendQueryParameters(
@@ -174,6 +205,8 @@ partial void ProcessGetUsedCreditsApiV1CreditAddedIdUsedGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -184,6 +217,11 @@ partial void ProcessGetUsedCreditsApiV1CreditAddedIdUsedGetResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -201,6 +239,8 @@ partial void ProcessGetUsedCreditsApiV1CreditAddedIdUsedGetResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -210,8 +250,7 @@ partial void ProcessGetUsedCreditsApiV1CreditAddedIdUsedGetResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -220,6 +259,11 @@ partial void ProcessGetUsedCreditsApiV1CreditAddedIdUsedGetResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -236,14 +280,15 @@ partial void ProcessGetUsedCreditsApiV1CreditAddedIdUsedGetResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -283,6 +328,8 @@ partial void ProcessGetUsedCreditsApiV1CreditAddedIdUsedGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -303,6 +350,8 @@ partial void ProcessGetUsedCreditsApiV1CreditAddedIdUsedGetResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -365,9 +414,13 @@ partial void ProcessGetUsedCreditsApiV1CreditAddedIdUsedGetResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.PaginatedResponse.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.PaginatedResponse.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -395,9 +448,13 @@ partial void ProcessGetUsedCreditsApiV1CreditAddedIdUsedGetResponseContent(
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.PaginatedResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.PaginatedResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.CreditClient.SetAutoTopupApiV1CreditAutoTopupPost.g.cs b/src/libs/Presenton/Generated/Presenton.CreditClient.SetAutoTopupApiV1CreditAutoTopupPost.g.cs
index aecf7d8..c2cd28b 100644
--- a/src/libs/Presenton/Generated/Presenton.CreditClient.SetAutoTopupApiV1CreditAutoTopupPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.CreditClient.SetAutoTopupApiV1CreditAutoTopupPost.g.cs
@@ -50,6 +50,28 @@ partial void ProcessSetAutoTopupApiV1CreditAutoTopupPostResponseContent(
///
public async global::System.Threading.Tasks.Task SetAutoTopupApiV1CreditAutoTopupPostAsync(
+ global::Presenton.TopupInfo request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await SetAutoTopupApiV1CreditAutoTopupPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Set Auto Topup
+ ///
+ ///
+ /// 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> SetAutoTopupApiV1CreditAutoTopupPostAsResponseAsync(
+
global::Presenton.TopupInfo request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -84,6 +106,7 @@ partial void ProcessSetAutoTopupApiV1CreditAutoTopupPostResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/credit/auto-topup",
baseUri: HttpClient.BaseAddress);
@@ -163,6 +186,8 @@ partial void ProcessSetAutoTopupApiV1CreditAutoTopupPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -173,6 +198,11 @@ partial void ProcessSetAutoTopupApiV1CreditAutoTopupPostResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -190,6 +220,8 @@ partial void ProcessSetAutoTopupApiV1CreditAutoTopupPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -199,8 +231,7 @@ partial void ProcessSetAutoTopupApiV1CreditAutoTopupPostResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -209,6 +240,11 @@ partial void ProcessSetAutoTopupApiV1CreditAutoTopupPostResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -225,14 +261,15 @@ partial void ProcessSetAutoTopupApiV1CreditAutoTopupPostResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -272,6 +309,8 @@ partial void ProcessSetAutoTopupApiV1CreditAutoTopupPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -292,6 +331,8 @@ partial void ProcessSetAutoTopupApiV1CreditAutoTopupPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -354,9 +395,13 @@ partial void ProcessSetAutoTopupApiV1CreditAutoTopupPostResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.TopupInfo.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.TopupInfo.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -384,9 +429,13 @@ partial void ProcessSetAutoTopupApiV1CreditAutoTopupPostResponseContent(
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.TopupInfo.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.TopupInfo.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.CreditClient.g.cs b/src/libs/Presenton/Generated/Presenton.CreditClient.g.cs
index 3d38030..4f795ec 100644
--- a/src/libs/Presenton/Generated/Presenton.CreditClient.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.CreditClient.g.cs
@@ -72,10 +72,10 @@ public CreditClient(
/// Client-wide request defaults such as headers, query parameters, retries, and timeout.
/// Dispose the HttpClient when the instance is disposed. True by default.
public CreditClient(
- global::System.Net.Http.HttpClient? httpClient = null,
- global::System.Uri? baseUri = null,
- global::System.Collections.Generic.List? authorizations = null,
- global::Presenton.AutoSDKClientOptions? options = null,
+ global::System.Net.Http.HttpClient? httpClient,
+ global::System.Uri? baseUri,
+ global::System.Collections.Generic.List? authorizations,
+ global::Presenton.AutoSDKClientOptions? options,
bool disposeHttpClient = true)
{
diff --git a/src/libs/Presenton/Generated/Presenton.DebugClient.AddCreditsApiV1DebugAddCreditsPost.g.cs b/src/libs/Presenton/Generated/Presenton.DebugClient.AddCreditsApiV1DebugAddCreditsPost.g.cs
index 7815ef1..ab7470b 100644
--- a/src/libs/Presenton/Generated/Presenton.DebugClient.AddCreditsApiV1DebugAddCreditsPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.DebugClient.AddCreditsApiV1DebugAddCreditsPost.g.cs
@@ -45,6 +45,26 @@ partial void ProcessAddCreditsApiV1DebugAddCreditsPostResponse(
///
public async global::System.Threading.Tasks.Task AddCreditsApiV1DebugAddCreditsPostAsync(
+ global::Presenton.BodyAddCreditsApiV1DebugAddCreditsPost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ await AddCreditsApiV1DebugAddCreditsPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+ }
+ ///
+ /// Add Credits
+ ///
+ ///
+ /// 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 AddCreditsApiV1DebugAddCreditsPostAsResponseAsync(
+
global::Presenton.BodyAddCreditsApiV1DebugAddCreditsPost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -79,6 +99,7 @@ partial void ProcessAddCreditsApiV1DebugAddCreditsPostResponse(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/debug/add-credits",
baseUri: HttpClient.BaseAddress);
@@ -158,6 +179,8 @@ partial void ProcessAddCreditsApiV1DebugAddCreditsPostResponse(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -168,6 +191,11 @@ partial void ProcessAddCreditsApiV1DebugAddCreditsPostResponse(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -185,6 +213,8 @@ partial void ProcessAddCreditsApiV1DebugAddCreditsPostResponse(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -194,8 +224,7 @@ partial void ProcessAddCreditsApiV1DebugAddCreditsPostResponse(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -204,6 +233,11 @@ partial void ProcessAddCreditsApiV1DebugAddCreditsPostResponse(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -220,14 +254,15 @@ partial void ProcessAddCreditsApiV1DebugAddCreditsPostResponse(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -267,6 +302,8 @@ partial void ProcessAddCreditsApiV1DebugAddCreditsPostResponse(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -287,6 +324,8 @@ partial void ProcessAddCreditsApiV1DebugAddCreditsPostResponse(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -345,6 +384,10 @@ partial void ProcessAddCreditsApiV1DebugAddCreditsPostResponse(
{
__response.EnsureSuccessStatusCode();
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri);
}
catch (global::System.Exception __ex)
{
@@ -366,6 +409,10 @@ partial void ProcessAddCreditsApiV1DebugAddCreditsPostResponse(
try
{
__response.EnsureSuccessStatusCode();
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.DebugClient.AddSubscriptionApiV1DebugAddSubscriptionPost.g.cs b/src/libs/Presenton/Generated/Presenton.DebugClient.AddSubscriptionApiV1DebugAddSubscriptionPost.g.cs
index 3456fb8..34df98e 100644
--- a/src/libs/Presenton/Generated/Presenton.DebugClient.AddSubscriptionApiV1DebugAddSubscriptionPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.DebugClient.AddSubscriptionApiV1DebugAddSubscriptionPost.g.cs
@@ -50,6 +50,28 @@ partial void ProcessAddSubscriptionApiV1DebugAddSubscriptionPostResponseContent(
///
public async global::System.Threading.Tasks.Task AddSubscriptionApiV1DebugAddSubscriptionPostAsync(
+ global::Presenton.BodyAddSubscriptionApiV1DebugAddSubscriptionPost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await AddSubscriptionApiV1DebugAddSubscriptionPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Add Subscription
+ ///
+ ///
+ /// 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> AddSubscriptionApiV1DebugAddSubscriptionPostAsResponseAsync(
+
global::Presenton.BodyAddSubscriptionApiV1DebugAddSubscriptionPost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -84,6 +106,7 @@ partial void ProcessAddSubscriptionApiV1DebugAddSubscriptionPostResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/debug/add-subscription",
baseUri: HttpClient.BaseAddress);
@@ -163,6 +186,8 @@ partial void ProcessAddSubscriptionApiV1DebugAddSubscriptionPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -173,6 +198,11 @@ partial void ProcessAddSubscriptionApiV1DebugAddSubscriptionPostResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -190,6 +220,8 @@ partial void ProcessAddSubscriptionApiV1DebugAddSubscriptionPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -199,8 +231,7 @@ partial void ProcessAddSubscriptionApiV1DebugAddSubscriptionPostResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -209,6 +240,11 @@ partial void ProcessAddSubscriptionApiV1DebugAddSubscriptionPostResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -225,14 +261,15 @@ partial void ProcessAddSubscriptionApiV1DebugAddSubscriptionPostResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -272,6 +309,8 @@ partial void ProcessAddSubscriptionApiV1DebugAddSubscriptionPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -292,6 +331,8 @@ partial void ProcessAddSubscriptionApiV1DebugAddSubscriptionPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -354,9 +395,13 @@ partial void ProcessAddSubscriptionApiV1DebugAddSubscriptionPostResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.Subscription.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.Subscription.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -384,9 +429,13 @@ partial void ProcessAddSubscriptionApiV1DebugAddSubscriptionPostResponseContent(
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.Subscription.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.Subscription.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.DebugClient.AddUserApiV1DebugAddUserPost.g.cs b/src/libs/Presenton/Generated/Presenton.DebugClient.AddUserApiV1DebugAddUserPost.g.cs
index 0bdb128..c6b1511 100644
--- a/src/libs/Presenton/Generated/Presenton.DebugClient.AddUserApiV1DebugAddUserPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.DebugClient.AddUserApiV1DebugAddUserPost.g.cs
@@ -50,6 +50,28 @@ partial void ProcessAddUserApiV1DebugAddUserPostResponseContent(
///
public async global::System.Threading.Tasks.Task AddUserApiV1DebugAddUserPostAsync(
+ global::Presenton.BodyAddUserApiV1DebugAddUserPost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await AddUserApiV1DebugAddUserPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Add User
+ ///
+ ///
+ /// 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> AddUserApiV1DebugAddUserPostAsResponseAsync(
+
global::Presenton.BodyAddUserApiV1DebugAddUserPost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -84,6 +106,7 @@ partial void ProcessAddUserApiV1DebugAddUserPostResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/debug/add-user",
baseUri: HttpClient.BaseAddress);
@@ -163,6 +186,8 @@ partial void ProcessAddUserApiV1DebugAddUserPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -173,6 +198,11 @@ partial void ProcessAddUserApiV1DebugAddUserPostResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -190,6 +220,8 @@ partial void ProcessAddUserApiV1DebugAddUserPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -199,8 +231,7 @@ partial void ProcessAddUserApiV1DebugAddUserPostResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -209,6 +240,11 @@ partial void ProcessAddUserApiV1DebugAddUserPostResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -225,14 +261,15 @@ partial void ProcessAddUserApiV1DebugAddUserPostResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -272,6 +309,8 @@ partial void ProcessAddUserApiV1DebugAddUserPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -292,6 +331,8 @@ partial void ProcessAddUserApiV1DebugAddUserPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -354,9 +395,13 @@ partial void ProcessAddUserApiV1DebugAddUserPostResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.UserRead.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.UserRead.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -384,9 +429,13 @@ partial void ProcessAddUserApiV1DebugAddUserPostResponseContent(
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.UserRead.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.UserRead.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.DebugClient.CheckCreditBalanceApiV1DebugCheckCreditBalancePost.g.cs b/src/libs/Presenton/Generated/Presenton.DebugClient.CheckCreditBalanceApiV1DebugCheckCreditBalancePost.g.cs
index fad0e85..1102f10 100644
--- a/src/libs/Presenton/Generated/Presenton.DebugClient.CheckCreditBalanceApiV1DebugCheckCreditBalancePost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.DebugClient.CheckCreditBalanceApiV1DebugCheckCreditBalancePost.g.cs
@@ -50,6 +50,28 @@ partial void ProcessCheckCreditBalanceApiV1DebugCheckCreditBalancePostResponseCo
///
public async global::System.Threading.Tasks.Task CheckCreditBalanceApiV1DebugCheckCreditBalancePostAsync(
+ global::Presenton.BodyCheckCreditBalanceApiV1DebugCheckCreditBalancePost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await CheckCreditBalanceApiV1DebugCheckCreditBalancePostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Check Credit Balance
+ ///
+ ///
+ /// 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> CheckCreditBalanceApiV1DebugCheckCreditBalancePostAsResponseAsync(
+
global::Presenton.BodyCheckCreditBalanceApiV1DebugCheckCreditBalancePost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -84,6 +106,7 @@ partial void ProcessCheckCreditBalanceApiV1DebugCheckCreditBalancePostResponseCo
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/debug/check-credit-balance",
baseUri: HttpClient.BaseAddress);
@@ -163,6 +186,8 @@ partial void ProcessCheckCreditBalanceApiV1DebugCheckCreditBalancePostResponseCo
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -173,6 +198,11 @@ partial void ProcessCheckCreditBalanceApiV1DebugCheckCreditBalancePostResponseCo
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -190,6 +220,8 @@ partial void ProcessCheckCreditBalanceApiV1DebugCheckCreditBalancePostResponseCo
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -199,8 +231,7 @@ partial void ProcessCheckCreditBalanceApiV1DebugCheckCreditBalancePostResponseCo
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -209,6 +240,11 @@ partial void ProcessCheckCreditBalanceApiV1DebugCheckCreditBalancePostResponseCo
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -225,14 +261,15 @@ partial void ProcessCheckCreditBalanceApiV1DebugCheckCreditBalancePostResponseCo
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -272,6 +309,8 @@ partial void ProcessCheckCreditBalanceApiV1DebugCheckCreditBalancePostResponseCo
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -292,6 +331,8 @@ partial void ProcessCheckCreditBalanceApiV1DebugCheckCreditBalancePostResponseCo
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -354,9 +395,13 @@ partial void ProcessCheckCreditBalanceApiV1DebugCheckCreditBalancePostResponseCo
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.CheckCreditBalanceResponse.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.CheckCreditBalanceResponse.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -384,9 +429,13 @@ partial void ProcessCheckCreditBalanceApiV1DebugCheckCreditBalancePostResponseCo
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.CheckCreditBalanceResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.CheckCreditBalanceResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.DebugClient.DeleteUserApiV1DebugDeleteUserDelete.g.cs b/src/libs/Presenton/Generated/Presenton.DebugClient.DeleteUserApiV1DebugDeleteUserDelete.g.cs
index 131dc2f..ee187e5 100644
--- a/src/libs/Presenton/Generated/Presenton.DebugClient.DeleteUserApiV1DebugDeleteUserDelete.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.DebugClient.DeleteUserApiV1DebugDeleteUserDelete.g.cs
@@ -45,6 +45,26 @@ partial void ProcessDeleteUserApiV1DebugDeleteUserDeleteResponse(
///
public async global::System.Threading.Tasks.Task DeleteUserApiV1DebugDeleteUserDeleteAsync(
+ global::Presenton.BodyDeleteUserApiV1DebugDeleteUserDelete request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ await DeleteUserApiV1DebugDeleteUserDeleteAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+ }
+ ///
+ /// Delete User
+ ///
+ ///
+ /// 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 DeleteUserApiV1DebugDeleteUserDeleteAsResponseAsync(
+
global::Presenton.BodyDeleteUserApiV1DebugDeleteUserDelete request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -79,6 +99,7 @@ partial void ProcessDeleteUserApiV1DebugDeleteUserDeleteResponse(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/debug/delete-user",
baseUri: HttpClient.BaseAddress);
@@ -158,6 +179,8 @@ partial void ProcessDeleteUserApiV1DebugDeleteUserDeleteResponse(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -168,6 +191,11 @@ partial void ProcessDeleteUserApiV1DebugDeleteUserDeleteResponse(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -185,6 +213,8 @@ partial void ProcessDeleteUserApiV1DebugDeleteUserDeleteResponse(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -194,8 +224,7 @@ partial void ProcessDeleteUserApiV1DebugDeleteUserDeleteResponse(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -204,6 +233,11 @@ partial void ProcessDeleteUserApiV1DebugDeleteUserDeleteResponse(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -220,14 +254,15 @@ partial void ProcessDeleteUserApiV1DebugDeleteUserDeleteResponse(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -267,6 +302,8 @@ partial void ProcessDeleteUserApiV1DebugDeleteUserDeleteResponse(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -287,6 +324,8 @@ partial void ProcessDeleteUserApiV1DebugDeleteUserDeleteResponse(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -345,6 +384,10 @@ partial void ProcessDeleteUserApiV1DebugDeleteUserDeleteResponse(
{
__response.EnsureSuccessStatusCode();
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri);
}
catch (global::System.Exception __ex)
{
@@ -366,6 +409,10 @@ partial void ProcessDeleteUserApiV1DebugDeleteUserDeleteResponse(
try
{
__response.EnsureSuccessStatusCode();
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.DebugClient.EndSubscriptionApiV1DebugEndSubscriptionPost.g.cs b/src/libs/Presenton/Generated/Presenton.DebugClient.EndSubscriptionApiV1DebugEndSubscriptionPost.g.cs
index 3397b90..1123e70 100644
--- a/src/libs/Presenton/Generated/Presenton.DebugClient.EndSubscriptionApiV1DebugEndSubscriptionPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.DebugClient.EndSubscriptionApiV1DebugEndSubscriptionPost.g.cs
@@ -45,6 +45,26 @@ partial void ProcessEndSubscriptionApiV1DebugEndSubscriptionPostResponse(
///
public async global::System.Threading.Tasks.Task EndSubscriptionApiV1DebugEndSubscriptionPostAsync(
+ global::Presenton.BodyEndSubscriptionApiV1DebugEndSubscriptionPost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ await EndSubscriptionApiV1DebugEndSubscriptionPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+ }
+ ///
+ /// End Subscription
+ ///
+ ///
+ /// 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 EndSubscriptionApiV1DebugEndSubscriptionPostAsResponseAsync(
+
global::Presenton.BodyEndSubscriptionApiV1DebugEndSubscriptionPost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -79,6 +99,7 @@ partial void ProcessEndSubscriptionApiV1DebugEndSubscriptionPostResponse(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/debug/end-subscription",
baseUri: HttpClient.BaseAddress);
@@ -158,6 +179,8 @@ partial void ProcessEndSubscriptionApiV1DebugEndSubscriptionPostResponse(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -168,6 +191,11 @@ partial void ProcessEndSubscriptionApiV1DebugEndSubscriptionPostResponse(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -185,6 +213,8 @@ partial void ProcessEndSubscriptionApiV1DebugEndSubscriptionPostResponse(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -194,8 +224,7 @@ partial void ProcessEndSubscriptionApiV1DebugEndSubscriptionPostResponse(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -204,6 +233,11 @@ partial void ProcessEndSubscriptionApiV1DebugEndSubscriptionPostResponse(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -220,14 +254,15 @@ partial void ProcessEndSubscriptionApiV1DebugEndSubscriptionPostResponse(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -267,6 +302,8 @@ partial void ProcessEndSubscriptionApiV1DebugEndSubscriptionPostResponse(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -287,6 +324,8 @@ partial void ProcessEndSubscriptionApiV1DebugEndSubscriptionPostResponse(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -345,6 +384,10 @@ partial void ProcessEndSubscriptionApiV1DebugEndSubscriptionPostResponse(
{
__response.EnsureSuccessStatusCode();
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri);
}
catch (global::System.Exception __ex)
{
@@ -366,6 +409,10 @@ partial void ProcessEndSubscriptionApiV1DebugEndSubscriptionPostResponse(
try
{
__response.EnsureSuccessStatusCode();
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.DebugClient.GetJwtTokenApiV1DebugGetJwtTokenPost.g.cs b/src/libs/Presenton/Generated/Presenton.DebugClient.GetJwtTokenApiV1DebugGetJwtTokenPost.g.cs
index 62364d8..7989bd6 100644
--- a/src/libs/Presenton/Generated/Presenton.DebugClient.GetJwtTokenApiV1DebugGetJwtTokenPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.DebugClient.GetJwtTokenApiV1DebugGetJwtTokenPost.g.cs
@@ -50,6 +50,28 @@ partial void ProcessGetJwtTokenApiV1DebugGetJwtTokenPostResponseContent(
///
public async global::System.Threading.Tasks.Task GetJwtTokenApiV1DebugGetJwtTokenPostAsync(
+ global::Presenton.BodyGetJwtTokenApiV1DebugGetJwtTokenPost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await GetJwtTokenApiV1DebugGetJwtTokenPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Get Jwt Token
+ ///
+ ///
+ /// 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> GetJwtTokenApiV1DebugGetJwtTokenPostAsResponseAsync(
+
global::Presenton.BodyGetJwtTokenApiV1DebugGetJwtTokenPost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -84,6 +106,7 @@ partial void ProcessGetJwtTokenApiV1DebugGetJwtTokenPostResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/debug/get-jwt-token",
baseUri: HttpClient.BaseAddress);
@@ -163,6 +186,8 @@ partial void ProcessGetJwtTokenApiV1DebugGetJwtTokenPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -173,6 +198,11 @@ partial void ProcessGetJwtTokenApiV1DebugGetJwtTokenPostResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -190,6 +220,8 @@ partial void ProcessGetJwtTokenApiV1DebugGetJwtTokenPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -199,8 +231,7 @@ partial void ProcessGetJwtTokenApiV1DebugGetJwtTokenPostResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -209,6 +240,11 @@ partial void ProcessGetJwtTokenApiV1DebugGetJwtTokenPostResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -225,14 +261,15 @@ partial void ProcessGetJwtTokenApiV1DebugGetJwtTokenPostResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -272,6 +309,8 @@ partial void ProcessGetJwtTokenApiV1DebugGetJwtTokenPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -292,6 +331,8 @@ partial void ProcessGetJwtTokenApiV1DebugGetJwtTokenPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -354,9 +395,13 @@ partial void ProcessGetJwtTokenApiV1DebugGetJwtTokenPostResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.GetJwtTokenResponse.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.GetJwtTokenResponse.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -384,9 +429,13 @@ partial void ProcessGetJwtTokenApiV1DebugGetJwtTokenPostResponseContent(
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.GetJwtTokenResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.GetJwtTokenResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.DebugClient.RaiseExceptionApiV1DebugRaiseExceptionPost.g.cs b/src/libs/Presenton/Generated/Presenton.DebugClient.RaiseExceptionApiV1DebugRaiseExceptionPost.g.cs
index da68593..7cede7f 100644
--- a/src/libs/Presenton/Generated/Presenton.DebugClient.RaiseExceptionApiV1DebugRaiseExceptionPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.DebugClient.RaiseExceptionApiV1DebugRaiseExceptionPost.g.cs
@@ -50,6 +50,28 @@ partial void ProcessRaiseExceptionApiV1DebugRaiseExceptionPostResponseContent(
///
public async global::System.Threading.Tasks.Task RaiseExceptionApiV1DebugRaiseExceptionPostAsync(
+ global::Presenton.BodyRaiseExceptionApiV1DebugRaiseExceptionPost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await RaiseExceptionApiV1DebugRaiseExceptionPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Raise Exception
+ ///
+ ///
+ /// 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> RaiseExceptionApiV1DebugRaiseExceptionPostAsResponseAsync(
+
global::Presenton.BodyRaiseExceptionApiV1DebugRaiseExceptionPost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -84,6 +106,7 @@ partial void ProcessRaiseExceptionApiV1DebugRaiseExceptionPostResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/debug/raise-exception",
baseUri: HttpClient.BaseAddress);
@@ -163,6 +186,8 @@ partial void ProcessRaiseExceptionApiV1DebugRaiseExceptionPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -173,6 +198,11 @@ partial void ProcessRaiseExceptionApiV1DebugRaiseExceptionPostResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -190,6 +220,8 @@ partial void ProcessRaiseExceptionApiV1DebugRaiseExceptionPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -199,8 +231,7 @@ partial void ProcessRaiseExceptionApiV1DebugRaiseExceptionPostResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -209,6 +240,11 @@ partial void ProcessRaiseExceptionApiV1DebugRaiseExceptionPostResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -225,14 +261,15 @@ partial void ProcessRaiseExceptionApiV1DebugRaiseExceptionPostResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -272,6 +309,8 @@ partial void ProcessRaiseExceptionApiV1DebugRaiseExceptionPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -292,6 +331,8 @@ partial void ProcessRaiseExceptionApiV1DebugRaiseExceptionPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -354,7 +395,11 @@ partial void ProcessRaiseExceptionApiV1DebugRaiseExceptionPostResponseContent(
{
__response.EnsureSuccessStatusCode();
- return __content;
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __content);
}
catch (global::System.Exception __ex)
{
@@ -382,7 +427,11 @@ partial void ProcessRaiseExceptionApiV1DebugRaiseExceptionPostResponseContent(
#endif
).ConfigureAwait(false);
- return __content;
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __content);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.DebugClient.SendLowBalanceEmailApiV1DebugSendLowBalanceEmailPost.g.cs b/src/libs/Presenton/Generated/Presenton.DebugClient.SendLowBalanceEmailApiV1DebugSendLowBalanceEmailPost.g.cs
index 0d9795a..5724dae 100644
--- a/src/libs/Presenton/Generated/Presenton.DebugClient.SendLowBalanceEmailApiV1DebugSendLowBalanceEmailPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.DebugClient.SendLowBalanceEmailApiV1DebugSendLowBalanceEmailPost.g.cs
@@ -45,6 +45,26 @@ partial void ProcessSendLowBalanceEmailApiV1DebugSendLowBalanceEmailPostResponse
///
public async global::System.Threading.Tasks.Task SendLowBalanceEmailApiV1DebugSendLowBalanceEmailPostAsync(
+ global::Presenton.BodySendLowBalanceEmailApiV1DebugSendLowBalanceEmailPost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ await SendLowBalanceEmailApiV1DebugSendLowBalanceEmailPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+ }
+ ///
+ /// Send Low Balance Email
+ ///
+ ///
+ /// 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 SendLowBalanceEmailApiV1DebugSendLowBalanceEmailPostAsResponseAsync(
+
global::Presenton.BodySendLowBalanceEmailApiV1DebugSendLowBalanceEmailPost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -79,6 +99,7 @@ partial void ProcessSendLowBalanceEmailApiV1DebugSendLowBalanceEmailPostResponse
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/debug/send-low-balance-email",
baseUri: HttpClient.BaseAddress);
@@ -158,6 +179,8 @@ partial void ProcessSendLowBalanceEmailApiV1DebugSendLowBalanceEmailPostResponse
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -168,6 +191,11 @@ partial void ProcessSendLowBalanceEmailApiV1DebugSendLowBalanceEmailPostResponse
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -185,6 +213,8 @@ partial void ProcessSendLowBalanceEmailApiV1DebugSendLowBalanceEmailPostResponse
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -194,8 +224,7 @@ partial void ProcessSendLowBalanceEmailApiV1DebugSendLowBalanceEmailPostResponse
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -204,6 +233,11 @@ partial void ProcessSendLowBalanceEmailApiV1DebugSendLowBalanceEmailPostResponse
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -220,14 +254,15 @@ partial void ProcessSendLowBalanceEmailApiV1DebugSendLowBalanceEmailPostResponse
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -267,6 +302,8 @@ partial void ProcessSendLowBalanceEmailApiV1DebugSendLowBalanceEmailPostResponse
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -287,6 +324,8 @@ partial void ProcessSendLowBalanceEmailApiV1DebugSendLowBalanceEmailPostResponse
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -345,6 +384,10 @@ partial void ProcessSendLowBalanceEmailApiV1DebugSendLowBalanceEmailPostResponse
{
__response.EnsureSuccessStatusCode();
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri);
}
catch (global::System.Exception __ex)
{
@@ -366,6 +409,10 @@ partial void ProcessSendLowBalanceEmailApiV1DebugSendLowBalanceEmailPostResponse
try
{
__response.EnsureSuccessStatusCode();
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.DebugClient.SendPasswordResetEmailApiV1DebugSendPasswordResetEmailPost.g.cs b/src/libs/Presenton/Generated/Presenton.DebugClient.SendPasswordResetEmailApiV1DebugSendPasswordResetEmailPost.g.cs
index 0ffb5c8..898b221 100644
--- a/src/libs/Presenton/Generated/Presenton.DebugClient.SendPasswordResetEmailApiV1DebugSendPasswordResetEmailPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.DebugClient.SendPasswordResetEmailApiV1DebugSendPasswordResetEmailPost.g.cs
@@ -45,6 +45,26 @@ partial void ProcessSendPasswordResetEmailApiV1DebugSendPasswordResetEmailPostRe
///
public async global::System.Threading.Tasks.Task SendPasswordResetEmailApiV1DebugSendPasswordResetEmailPostAsync(
+ global::Presenton.BodySendPasswordResetEmailApiV1DebugSendPasswordResetEmailPost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ await SendPasswordResetEmailApiV1DebugSendPasswordResetEmailPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+ }
+ ///
+ /// Send Password Reset Email
+ ///
+ ///
+ /// 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 SendPasswordResetEmailApiV1DebugSendPasswordResetEmailPostAsResponseAsync(
+
global::Presenton.BodySendPasswordResetEmailApiV1DebugSendPasswordResetEmailPost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -79,6 +99,7 @@ partial void ProcessSendPasswordResetEmailApiV1DebugSendPasswordResetEmailPostRe
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/debug/send-password-reset-email",
baseUri: HttpClient.BaseAddress);
@@ -158,6 +179,8 @@ partial void ProcessSendPasswordResetEmailApiV1DebugSendPasswordResetEmailPostRe
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -168,6 +191,11 @@ partial void ProcessSendPasswordResetEmailApiV1DebugSendPasswordResetEmailPostRe
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -185,6 +213,8 @@ partial void ProcessSendPasswordResetEmailApiV1DebugSendPasswordResetEmailPostRe
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -194,8 +224,7 @@ partial void ProcessSendPasswordResetEmailApiV1DebugSendPasswordResetEmailPostRe
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -204,6 +233,11 @@ partial void ProcessSendPasswordResetEmailApiV1DebugSendPasswordResetEmailPostRe
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -220,14 +254,15 @@ partial void ProcessSendPasswordResetEmailApiV1DebugSendPasswordResetEmailPostRe
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -267,6 +302,8 @@ partial void ProcessSendPasswordResetEmailApiV1DebugSendPasswordResetEmailPostRe
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -287,6 +324,8 @@ partial void ProcessSendPasswordResetEmailApiV1DebugSendPasswordResetEmailPostRe
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -345,6 +384,10 @@ partial void ProcessSendPasswordResetEmailApiV1DebugSendPasswordResetEmailPostRe
{
__response.EnsureSuccessStatusCode();
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri);
}
catch (global::System.Exception __ex)
{
@@ -366,6 +409,10 @@ partial void ProcessSendPasswordResetEmailApiV1DebugSendPasswordResetEmailPostRe
try
{
__response.EnsureSuccessStatusCode();
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.DebugClient.SendPaymentFailedEmailApiV1DebugSendPaymentFailedEmailPost.g.cs b/src/libs/Presenton/Generated/Presenton.DebugClient.SendPaymentFailedEmailApiV1DebugSendPaymentFailedEmailPost.g.cs
index 53efbe8..e55e1a7 100644
--- a/src/libs/Presenton/Generated/Presenton.DebugClient.SendPaymentFailedEmailApiV1DebugSendPaymentFailedEmailPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.DebugClient.SendPaymentFailedEmailApiV1DebugSendPaymentFailedEmailPost.g.cs
@@ -45,6 +45,26 @@ partial void ProcessSendPaymentFailedEmailApiV1DebugSendPaymentFailedEmailPostRe
///
public async global::System.Threading.Tasks.Task SendPaymentFailedEmailApiV1DebugSendPaymentFailedEmailPostAsync(
+ global::Presenton.BodySendPaymentFailedEmailApiV1DebugSendPaymentFailedEmailPost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ await SendPaymentFailedEmailApiV1DebugSendPaymentFailedEmailPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+ }
+ ///
+ /// Send Payment Failed Email
+ ///
+ ///
+ /// 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 SendPaymentFailedEmailApiV1DebugSendPaymentFailedEmailPostAsResponseAsync(
+
global::Presenton.BodySendPaymentFailedEmailApiV1DebugSendPaymentFailedEmailPost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -79,6 +99,7 @@ partial void ProcessSendPaymentFailedEmailApiV1DebugSendPaymentFailedEmailPostRe
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/debug/send-payment-failed-email",
baseUri: HttpClient.BaseAddress);
@@ -158,6 +179,8 @@ partial void ProcessSendPaymentFailedEmailApiV1DebugSendPaymentFailedEmailPostRe
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -168,6 +191,11 @@ partial void ProcessSendPaymentFailedEmailApiV1DebugSendPaymentFailedEmailPostRe
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -185,6 +213,8 @@ partial void ProcessSendPaymentFailedEmailApiV1DebugSendPaymentFailedEmailPostRe
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -194,8 +224,7 @@ partial void ProcessSendPaymentFailedEmailApiV1DebugSendPaymentFailedEmailPostRe
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -204,6 +233,11 @@ partial void ProcessSendPaymentFailedEmailApiV1DebugSendPaymentFailedEmailPostRe
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -220,14 +254,15 @@ partial void ProcessSendPaymentFailedEmailApiV1DebugSendPaymentFailedEmailPostRe
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -267,6 +302,8 @@ partial void ProcessSendPaymentFailedEmailApiV1DebugSendPaymentFailedEmailPostRe
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -287,6 +324,8 @@ partial void ProcessSendPaymentFailedEmailApiV1DebugSendPaymentFailedEmailPostRe
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -345,6 +384,10 @@ partial void ProcessSendPaymentFailedEmailApiV1DebugSendPaymentFailedEmailPostRe
{
__response.EnsureSuccessStatusCode();
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri);
}
catch (global::System.Exception __ex)
{
@@ -366,6 +409,10 @@ partial void ProcessSendPaymentFailedEmailApiV1DebugSendPaymentFailedEmailPostRe
try
{
__response.EnsureSuccessStatusCode();
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.DebugClient.SendVerificationEmailApiV1DebugSendVerificationEmailPost.g.cs b/src/libs/Presenton/Generated/Presenton.DebugClient.SendVerificationEmailApiV1DebugSendVerificationEmailPost.g.cs
index 592c032..8328a7d 100644
--- a/src/libs/Presenton/Generated/Presenton.DebugClient.SendVerificationEmailApiV1DebugSendVerificationEmailPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.DebugClient.SendVerificationEmailApiV1DebugSendVerificationEmailPost.g.cs
@@ -45,6 +45,26 @@ partial void ProcessSendVerificationEmailApiV1DebugSendVerificationEmailPostResp
///
public async global::System.Threading.Tasks.Task SendVerificationEmailApiV1DebugSendVerificationEmailPostAsync(
+ global::Presenton.BodySendVerificationEmailApiV1DebugSendVerificationEmailPost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ await SendVerificationEmailApiV1DebugSendVerificationEmailPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+ }
+ ///
+ /// Send Verification Email
+ ///
+ ///
+ /// 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 SendVerificationEmailApiV1DebugSendVerificationEmailPostAsResponseAsync(
+
global::Presenton.BodySendVerificationEmailApiV1DebugSendVerificationEmailPost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -79,6 +99,7 @@ partial void ProcessSendVerificationEmailApiV1DebugSendVerificationEmailPostResp
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/debug/send-verification-email",
baseUri: HttpClient.BaseAddress);
@@ -158,6 +179,8 @@ partial void ProcessSendVerificationEmailApiV1DebugSendVerificationEmailPostResp
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -168,6 +191,11 @@ partial void ProcessSendVerificationEmailApiV1DebugSendVerificationEmailPostResp
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -185,6 +213,8 @@ partial void ProcessSendVerificationEmailApiV1DebugSendVerificationEmailPostResp
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -194,8 +224,7 @@ partial void ProcessSendVerificationEmailApiV1DebugSendVerificationEmailPostResp
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -204,6 +233,11 @@ partial void ProcessSendVerificationEmailApiV1DebugSendVerificationEmailPostResp
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -220,14 +254,15 @@ partial void ProcessSendVerificationEmailApiV1DebugSendVerificationEmailPostResp
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -267,6 +302,8 @@ partial void ProcessSendVerificationEmailApiV1DebugSendVerificationEmailPostResp
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -287,6 +324,8 @@ partial void ProcessSendVerificationEmailApiV1DebugSendVerificationEmailPostResp
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -345,6 +384,10 @@ partial void ProcessSendVerificationEmailApiV1DebugSendVerificationEmailPostResp
{
__response.EnsureSuccessStatusCode();
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri);
}
catch (global::System.Exception __ex)
{
@@ -366,6 +409,10 @@ partial void ProcessSendVerificationEmailApiV1DebugSendVerificationEmailPostResp
try
{
__response.EnsureSuccessStatusCode();
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.DebugClient.SendWelcomeEmailApiV1DebugSendWelcomeEmailPost.g.cs b/src/libs/Presenton/Generated/Presenton.DebugClient.SendWelcomeEmailApiV1DebugSendWelcomeEmailPost.g.cs
index 9353fe4..1bce6d3 100644
--- a/src/libs/Presenton/Generated/Presenton.DebugClient.SendWelcomeEmailApiV1DebugSendWelcomeEmailPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.DebugClient.SendWelcomeEmailApiV1DebugSendWelcomeEmailPost.g.cs
@@ -45,6 +45,26 @@ partial void ProcessSendWelcomeEmailApiV1DebugSendWelcomeEmailPostResponse(
///
public async global::System.Threading.Tasks.Task SendWelcomeEmailApiV1DebugSendWelcomeEmailPostAsync(
+ global::Presenton.BodySendWelcomeEmailApiV1DebugSendWelcomeEmailPost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ await SendWelcomeEmailApiV1DebugSendWelcomeEmailPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+ }
+ ///
+ /// Send Welcome Email
+ ///
+ ///
+ /// 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 SendWelcomeEmailApiV1DebugSendWelcomeEmailPostAsResponseAsync(
+
global::Presenton.BodySendWelcomeEmailApiV1DebugSendWelcomeEmailPost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -79,6 +99,7 @@ partial void ProcessSendWelcomeEmailApiV1DebugSendWelcomeEmailPostResponse(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/debug/send-welcome-email",
baseUri: HttpClient.BaseAddress);
@@ -158,6 +179,8 @@ partial void ProcessSendWelcomeEmailApiV1DebugSendWelcomeEmailPostResponse(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -168,6 +191,11 @@ partial void ProcessSendWelcomeEmailApiV1DebugSendWelcomeEmailPostResponse(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -185,6 +213,8 @@ partial void ProcessSendWelcomeEmailApiV1DebugSendWelcomeEmailPostResponse(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -194,8 +224,7 @@ partial void ProcessSendWelcomeEmailApiV1DebugSendWelcomeEmailPostResponse(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -204,6 +233,11 @@ partial void ProcessSendWelcomeEmailApiV1DebugSendWelcomeEmailPostResponse(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -220,14 +254,15 @@ partial void ProcessSendWelcomeEmailApiV1DebugSendWelcomeEmailPostResponse(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -267,6 +302,8 @@ partial void ProcessSendWelcomeEmailApiV1DebugSendWelcomeEmailPostResponse(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -287,6 +324,8 @@ partial void ProcessSendWelcomeEmailApiV1DebugSendWelcomeEmailPostResponse(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -345,6 +384,10 @@ partial void ProcessSendWelcomeEmailApiV1DebugSendWelcomeEmailPostResponse(
{
__response.EnsureSuccessStatusCode();
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri);
}
catch (global::System.Exception __ex)
{
@@ -366,6 +409,10 @@ partial void ProcessSendWelcomeEmailApiV1DebugSendWelcomeEmailPostResponse(
try
{
__response.EnsureSuccessStatusCode();
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.DebugClient.TestJobApiV1DebugTestJobPost.g.cs b/src/libs/Presenton/Generated/Presenton.DebugClient.TestJobApiV1DebugTestJobPost.g.cs
index d1811ff..0a87780 100644
--- a/src/libs/Presenton/Generated/Presenton.DebugClient.TestJobApiV1DebugTestJobPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.DebugClient.TestJobApiV1DebugTestJobPost.g.cs
@@ -45,6 +45,26 @@ partial void ProcessTestJobApiV1DebugTestJobPostResponse(
///
public async global::System.Threading.Tasks.Task TestJobApiV1DebugTestJobPostAsync(
+ global::Presenton.BodyTestJobApiV1DebugTestJobPost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ await TestJobApiV1DebugTestJobPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+ }
+ ///
+ /// Test Job
+ ///
+ ///
+ /// 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 TestJobApiV1DebugTestJobPostAsResponseAsync(
+
global::Presenton.BodyTestJobApiV1DebugTestJobPost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -79,6 +99,7 @@ partial void ProcessTestJobApiV1DebugTestJobPostResponse(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/debug/test-job",
baseUri: HttpClient.BaseAddress);
@@ -158,6 +179,8 @@ partial void ProcessTestJobApiV1DebugTestJobPostResponse(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -168,6 +191,11 @@ partial void ProcessTestJobApiV1DebugTestJobPostResponse(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -185,6 +213,8 @@ partial void ProcessTestJobApiV1DebugTestJobPostResponse(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -194,8 +224,7 @@ partial void ProcessTestJobApiV1DebugTestJobPostResponse(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -204,6 +233,11 @@ partial void ProcessTestJobApiV1DebugTestJobPostResponse(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -220,14 +254,15 @@ partial void ProcessTestJobApiV1DebugTestJobPostResponse(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -267,6 +302,8 @@ partial void ProcessTestJobApiV1DebugTestJobPostResponse(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -287,6 +324,8 @@ partial void ProcessTestJobApiV1DebugTestJobPostResponse(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -345,6 +384,10 @@ partial void ProcessTestJobApiV1DebugTestJobPostResponse(
{
__response.EnsureSuccessStatusCode();
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri);
}
catch (global::System.Exception __ex)
{
@@ -366,6 +409,10 @@ partial void ProcessTestJobApiV1DebugTestJobPostResponse(
try
{
__response.EnsureSuccessStatusCode();
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.DebugClient.g.cs b/src/libs/Presenton/Generated/Presenton.DebugClient.g.cs
index a87e7f6..1782bde 100644
--- a/src/libs/Presenton/Generated/Presenton.DebugClient.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.DebugClient.g.cs
@@ -72,10 +72,10 @@ public DebugClient(
/// Client-wide request defaults such as headers, query parameters, retries, and timeout.
/// Dispose the HttpClient when the instance is disposed. True by default.
public DebugClient(
- global::System.Net.Http.HttpClient? httpClient = null,
- global::System.Uri? baseUri = null,
- global::System.Collections.Generic.List? authorizations = null,
- global::Presenton.AutoSDKClientOptions? options = null,
+ global::System.Net.Http.HttpClient? httpClient,
+ global::System.Uri? baseUri,
+ global::System.Collections.Generic.List? authorizations,
+ global::Presenton.AutoSDKClientOptions? options,
bool disposeHttpClient = true)
{
diff --git a/src/libs/Presenton/Generated/Presenton.DesignSystemClient.ExtractDesignSystemApiV1PptDesignSystemExtractPost.g.cs b/src/libs/Presenton/Generated/Presenton.DesignSystemClient.ExtractDesignSystemApiV1PptDesignSystemExtractPost.g.cs
index f55a4ec..baa783a 100644
--- a/src/libs/Presenton/Generated/Presenton.DesignSystemClient.ExtractDesignSystemApiV1PptDesignSystemExtractPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.DesignSystemClient.ExtractDesignSystemApiV1PptDesignSystemExtractPost.g.cs
@@ -53,6 +53,31 @@ partial void ProcessExtractDesignSystemApiV1PptDesignSystemExtractPostResponseCo
///
public async global::System.Threading.Tasks.Task ExtractDesignSystemApiV1PptDesignSystemExtractPostAsync(
+ global::Presenton.ExtractDesignSystemRequest request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await ExtractDesignSystemApiV1PptDesignSystemExtractPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Extract Design System
+ /// Accepts an array of slides (image + markdown_content), concatenates markdown,
+ /// sends all images and the markdown to OpenAI Responses API with EXTRACT_DESIGN_SYSTEM_PROMPT,
+ /// and returns the extracted design system JSON.
+ ///
+ ///
+ /// 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> ExtractDesignSystemApiV1PptDesignSystemExtractPostAsResponseAsync(
+
global::Presenton.ExtractDesignSystemRequest request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -87,6 +112,7 @@ partial void ProcessExtractDesignSystemApiV1PptDesignSystemExtractPostResponseCo
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/ppt/design-system/extract",
baseUri: HttpClient.BaseAddress);
@@ -166,6 +192,8 @@ partial void ProcessExtractDesignSystemApiV1PptDesignSystemExtractPostResponseCo
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -176,6 +204,11 @@ partial void ProcessExtractDesignSystemApiV1PptDesignSystemExtractPostResponseCo
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -193,6 +226,8 @@ partial void ProcessExtractDesignSystemApiV1PptDesignSystemExtractPostResponseCo
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -202,8 +237,7 @@ partial void ProcessExtractDesignSystemApiV1PptDesignSystemExtractPostResponseCo
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -212,6 +246,11 @@ partial void ProcessExtractDesignSystemApiV1PptDesignSystemExtractPostResponseCo
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -228,14 +267,15 @@ partial void ProcessExtractDesignSystemApiV1PptDesignSystemExtractPostResponseCo
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -275,6 +315,8 @@ partial void ProcessExtractDesignSystemApiV1PptDesignSystemExtractPostResponseCo
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -295,6 +337,8 @@ partial void ProcessExtractDesignSystemApiV1PptDesignSystemExtractPostResponseCo
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -357,9 +401,13 @@ partial void ProcessExtractDesignSystemApiV1PptDesignSystemExtractPostResponseCo
{
__response.EnsureSuccessStatusCode();
- return
- global::Presenton.ExtractDesignSystemResponse.FromJson(__content, JsonSerializerContext) ??
+ var __value = global::Presenton.ExtractDesignSystemResponse.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -387,9 +435,13 @@ partial void ProcessExtractDesignSystemApiV1PptDesignSystemExtractPostResponseCo
#endif
).ConfigureAwait(false);
- return
- await global::Presenton.ExtractDesignSystemResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = await global::Presenton.ExtractDesignSystemResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.DesignSystemClient.g.cs b/src/libs/Presenton/Generated/Presenton.DesignSystemClient.g.cs
index 477a217..0b60e70 100644
--- a/src/libs/Presenton/Generated/Presenton.DesignSystemClient.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.DesignSystemClient.g.cs
@@ -72,10 +72,10 @@ public DesignSystemClient(
/// Client-wide request defaults such as headers, query parameters, retries, and timeout.
/// Dispose the HttpClient when the instance is disposed. True by default.
public DesignSystemClient(
- global::System.Net.Http.HttpClient? httpClient = null,
- global::System.Uri? baseUri = null,
- global::System.Collections.Generic.List? authorizations = null,
- global::Presenton.AutoSDKClientOptions? options = null,
+ global::System.Net.Http.HttpClient? httpClient,
+ global::System.Uri? baseUri,
+ global::System.Collections.Generic.List? authorizations,
+ global::Presenton.AutoSDKClientOptions? options,
bool disposeHttpClient = true)
{
diff --git a/src/libs/Presenton/Generated/Presenton.DownloadsClient.AddDownloadApiV3DownloadsAddPost.g.cs b/src/libs/Presenton/Generated/Presenton.DownloadsClient.AddDownloadApiV3DownloadsAddPost.g.cs
index 2f634c4..ba17fe5 100644
--- a/src/libs/Presenton/Generated/Presenton.DownloadsClient.AddDownloadApiV3DownloadsAddPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.DownloadsClient.AddDownloadApiV3DownloadsAddPost.g.cs
@@ -56,6 +56,29 @@ partial void ProcessAddDownloadApiV3DownloadsAddPostResponseContent(
global::Presenton.DownloadFormat format,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await AddDownloadApiV3DownloadsAddPostAsResponseAsync(
+ device: device,
+ format: format,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Add Download
+ ///
+ ///
+ ///
+ /// 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> AddDownloadApiV3DownloadsAddPostAsResponseAsync(
+ global::Presenton.Device device,
+ global::Presenton.DownloadFormat format,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
{
PrepareArguments(
client: HttpClient);
@@ -86,12 +109,13 @@ partial void ProcessAddDownloadApiV3DownloadsAddPostResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v3/downloads/add",
- baseUri: HttpClient.BaseAddress);
+ baseUri: HttpClient.BaseAddress);
__pathBuilder
.AddRequiredParameter("device", device.ToValueString())
- .AddRequiredParameter("format", format.ToValueString())
+ .AddRequiredParameter("format", format.ToValueString())
;
var __path = __pathBuilder.ToString();
__path = global::Presenton.AutoSDKRequestOptionsSupport.AppendQueryParameters(
@@ -164,6 +188,8 @@ partial void ProcessAddDownloadApiV3DownloadsAddPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -174,6 +200,11 @@ partial void ProcessAddDownloadApiV3DownloadsAddPostResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -191,6 +222,8 @@ partial void ProcessAddDownloadApiV3DownloadsAddPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -200,8 +233,7 @@ partial void ProcessAddDownloadApiV3DownloadsAddPostResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -210,6 +242,11 @@ partial void ProcessAddDownloadApiV3DownloadsAddPostResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -226,14 +263,15 @@ partial void ProcessAddDownloadApiV3DownloadsAddPostResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -273,6 +311,8 @@ partial void ProcessAddDownloadApiV3DownloadsAddPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -293,6 +333,8 @@ partial void ProcessAddDownloadApiV3DownloadsAddPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -355,7 +397,11 @@ partial void ProcessAddDownloadApiV3DownloadsAddPostResponseContent(
{
__response.EnsureSuccessStatusCode();
- return __content;
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __content);
}
catch (global::System.Exception __ex)
{
@@ -383,7 +429,11 @@ partial void ProcessAddDownloadApiV3DownloadsAddPostResponseContent(
#endif
).ConfigureAwait(false);
- return __content;
+ return new global::Presenton.AutoSDKHttpResponse(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __content);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.DownloadsClient.g.cs b/src/libs/Presenton/Generated/Presenton.DownloadsClient.g.cs
index 3930111..4f4e05e 100644
--- a/src/libs/Presenton/Generated/Presenton.DownloadsClient.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.DownloadsClient.g.cs
@@ -72,10 +72,10 @@ public DownloadsClient(
/// Client-wide request defaults such as headers, query parameters, retries, and timeout.
/// Dispose the HttpClient when the instance is disposed. True by default.
public DownloadsClient(
- global::System.Net.Http.HttpClient? httpClient = null,
- global::System.Uri? baseUri = null,
- global::System.Collections.Generic.List? authorizations = null,
- global::Presenton.AutoSDKClientOptions? options = null,
+ global::System.Net.Http.HttpClient? httpClient,
+ global::System.Uri? baseUri,
+ global::System.Collections.Generic.List? authorizations,
+ global::Presenton.AutoSDKClientOptions? options,
bool disposeHttpClient = true)
{
diff --git a/src/libs/Presenton/Generated/Presenton.FilesClient.DecomposeFilesApiV1PptFilesDecomposePost.g.cs b/src/libs/Presenton/Generated/Presenton.FilesClient.DecomposeFilesApiV1PptFilesDecomposePost.g.cs
index bc000f4..cb981b3 100644
--- a/src/libs/Presenton/Generated/Presenton.FilesClient.DecomposeFilesApiV1PptFilesDecomposePost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.FilesClient.DecomposeFilesApiV1PptFilesDecomposePost.g.cs
@@ -50,6 +50,28 @@ partial void ProcessDecomposeFilesApiV1PptFilesDecomposePostResponseContent(
///
public async global::System.Threading.Tasks.Task> DecomposeFilesApiV1PptFilesDecomposePostAsync(
+ global::Presenton.BodyDecomposeFilesApiV1PptFilesDecomposePost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await DecomposeFilesApiV1PptFilesDecomposePostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Decompose Files
+ ///
+ ///
+ /// 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>> DecomposeFilesApiV1PptFilesDecomposePostAsResponseAsync(
+
global::Presenton.BodyDecomposeFilesApiV1PptFilesDecomposePost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -84,6 +106,7 @@ partial void ProcessDecomposeFilesApiV1PptFilesDecomposePostResponseContent(
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/ppt/files/decompose",
baseUri: HttpClient.BaseAddress);
@@ -163,6 +186,8 @@ partial void ProcessDecomposeFilesApiV1PptFilesDecomposePostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -173,6 +198,11 @@ partial void ProcessDecomposeFilesApiV1PptFilesDecomposePostResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -190,6 +220,8 @@ partial void ProcessDecomposeFilesApiV1PptFilesDecomposePostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -199,8 +231,7 @@ partial void ProcessDecomposeFilesApiV1PptFilesDecomposePostResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -209,6 +240,11 @@ partial void ProcessDecomposeFilesApiV1PptFilesDecomposePostResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -225,14 +261,15 @@ partial void ProcessDecomposeFilesApiV1PptFilesDecomposePostResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -272,6 +309,8 @@ partial void ProcessDecomposeFilesApiV1PptFilesDecomposePostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -292,6 +331,8 @@ partial void ProcessDecomposeFilesApiV1PptFilesDecomposePostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -354,9 +395,13 @@ partial void ProcessDecomposeFilesApiV1PptFilesDecomposePostResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- (global::System.Collections.Generic.IList?)global::System.Text.Json.JsonSerializer.Deserialize(__content, typeof(global::System.Collections.Generic.IList), JsonSerializerContext) ??
+ var __value = (global::System.Collections.Generic.IList?)global::System.Text.Json.JsonSerializer.Deserialize(__content, typeof(global::System.Collections.Generic.IList), JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse>(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -384,9 +429,13 @@ partial void ProcessDecomposeFilesApiV1PptFilesDecomposePostResponseContent(
#endif
).ConfigureAwait(false);
- return
- (global::System.Collections.Generic.IList?)await global::System.Text.Json.JsonSerializer.DeserializeAsync(__content, typeof(global::System.Collections.Generic.IList), JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = (global::System.Collections.Generic.IList?)await global::System.Text.Json.JsonSerializer.DeserializeAsync(__content, typeof(global::System.Collections.Generic.IList), JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse>(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.FilesClient.UploadFilesAndGetTemporaryUrlsApiV1PptFilesUploadAndGetTemporaryUrlsPost.g.cs b/src/libs/Presenton/Generated/Presenton.FilesClient.UploadFilesAndGetTemporaryUrlsApiV1PptFilesUploadAndGetTemporaryUrlsPost.g.cs
index f2184af..b6a10bf 100644
--- a/src/libs/Presenton/Generated/Presenton.FilesClient.UploadFilesAndGetTemporaryUrlsApiV1PptFilesUploadAndGetTemporaryUrlsPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.FilesClient.UploadFilesAndGetTemporaryUrlsApiV1PptFilesUploadAndGetTemporaryUrlsPost.g.cs
@@ -50,6 +50,28 @@ partial void ProcessUploadFilesAndGetTemporaryUrlsApiV1PptFilesUploadAndGetTempo
///
public async global::System.Threading.Tasks.Task> UploadFilesAndGetTemporaryUrlsApiV1PptFilesUploadAndGetTemporaryUrlsPostAsync(
+ global::Presenton.BodyUploadFilesAndGetTemporaryUrlsApiV1PptFilesUploadAndGetTemporaryUrlsPost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await UploadFilesAndGetTemporaryUrlsApiV1PptFilesUploadAndGetTemporaryUrlsPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Upload Files And Get Temporary Urls
+ ///
+ ///
+ /// 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>> UploadFilesAndGetTemporaryUrlsApiV1PptFilesUploadAndGetTemporaryUrlsPostAsResponseAsync(
+
global::Presenton.BodyUploadFilesAndGetTemporaryUrlsApiV1PptFilesUploadAndGetTemporaryUrlsPost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -80,10 +102,11 @@ partial void ProcessUploadFilesAndGetTemporaryUrlsApiV1PptFilesUploadAndGetTempo
var __maxAttempts = global::Presenton.AutoSDKRequestOptionsSupport.GetMaxAttempts(
clientOptions: Options,
requestOptions: requestOptions,
- supportsRetry: true);
+ supportsRetry: false);
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/ppt/files/upload-and-get-temporary-urls",
baseUri: HttpClient.BaseAddress);
@@ -116,6 +139,7 @@ partial void ProcessUploadFilesAndGetTemporaryUrlsApiV1PptFilesUploadAndGetTempo
__httpRequest.Headers.Add(__authorization.Name, __authorization.Value);
}
}
+
var __httpRequestContent = new global::System.Net.Http.MultipartFormDataContent();
if (request.Files != default)
{
@@ -123,8 +147,11 @@ partial void ProcessUploadFilesAndGetTemporaryUrlsApiV1PptFilesUploadAndGetTempo
__httpRequestContent.Add(
content: new global::System.Net.Http.StringContent(request.Files.ToString() ?? string.Empty),
name: "\"files\"");
+
}
+
__httpRequest.Content = __httpRequestContent;
+
global::Presenton.AutoSDKRequestOptionsSupport.ApplyHeaders(
request: __httpRequest,
clientHeaders: Options.Headers,
@@ -166,6 +193,8 @@ partial void ProcessUploadFilesAndGetTemporaryUrlsApiV1PptFilesUploadAndGetTempo
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -176,6 +205,11 @@ partial void ProcessUploadFilesAndGetTemporaryUrlsApiV1PptFilesUploadAndGetTempo
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -193,6 +227,8 @@ partial void ProcessUploadFilesAndGetTemporaryUrlsApiV1PptFilesUploadAndGetTempo
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -202,8 +238,7 @@ partial void ProcessUploadFilesAndGetTemporaryUrlsApiV1PptFilesUploadAndGetTempo
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -212,6 +247,11 @@ partial void ProcessUploadFilesAndGetTemporaryUrlsApiV1PptFilesUploadAndGetTempo
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -228,14 +268,15 @@ partial void ProcessUploadFilesAndGetTemporaryUrlsApiV1PptFilesUploadAndGetTempo
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -275,6 +316,8 @@ partial void ProcessUploadFilesAndGetTemporaryUrlsApiV1PptFilesUploadAndGetTempo
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -295,6 +338,8 @@ partial void ProcessUploadFilesAndGetTemporaryUrlsApiV1PptFilesUploadAndGetTempo
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -357,9 +402,13 @@ partial void ProcessUploadFilesAndGetTemporaryUrlsApiV1PptFilesUploadAndGetTempo
{
__response.EnsureSuccessStatusCode();
- return
- (global::System.Collections.Generic.IList?)global::System.Text.Json.JsonSerializer.Deserialize(__content, typeof(global::System.Collections.Generic.IList), JsonSerializerContext) ??
+ var __value = (global::System.Collections.Generic.IList?)global::System.Text.Json.JsonSerializer.Deserialize(__content, typeof(global::System.Collections.Generic.IList), JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse>(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -387,9 +436,13 @@ partial void ProcessUploadFilesAndGetTemporaryUrlsApiV1PptFilesUploadAndGetTempo
#endif
).ConfigureAwait(false);
- return
- (global::System.Collections.Generic.IList?)await global::System.Text.Json.JsonSerializer.DeserializeAsync(__content, typeof(global::System.Collections.Generic.IList), JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = (global::System.Collections.Generic.IList?)await global::System.Text.Json.JsonSerializer.DeserializeAsync(__content, typeof(global::System.Collections.Generic.IList), JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse>(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.FilesClient.UploadFilesForUiApiV1PptFilesUploadUiPost.g.cs b/src/libs/Presenton/Generated/Presenton.FilesClient.UploadFilesForUiApiV1PptFilesUploadUiPost.g.cs
index 066aaa9..f9a9852 100644
--- a/src/libs/Presenton/Generated/Presenton.FilesClient.UploadFilesForUiApiV1PptFilesUploadUiPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.FilesClient.UploadFilesForUiApiV1PptFilesUploadUiPost.g.cs
@@ -50,6 +50,28 @@ partial void ProcessUploadFilesForUiApiV1PptFilesUploadUiPostResponseContent(
///
public async global::System.Threading.Tasks.Task> UploadFilesForUiApiV1PptFilesUploadUiPostAsync(
+ global::Presenton.BodyUploadFilesForUiApiV1PptFilesUploadUiPost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await UploadFilesForUiApiV1PptFilesUploadUiPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Upload Files For Ui
+ ///
+ ///
+ /// 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>> UploadFilesForUiApiV1PptFilesUploadUiPostAsResponseAsync(
+
global::Presenton.BodyUploadFilesForUiApiV1PptFilesUploadUiPost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -80,10 +102,11 @@ partial void ProcessUploadFilesForUiApiV1PptFilesUploadUiPostResponseContent(
var __maxAttempts = global::Presenton.AutoSDKRequestOptionsSupport.GetMaxAttempts(
clientOptions: Options,
requestOptions: requestOptions,
- supportsRetry: true);
+ supportsRetry: false);
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/ppt/files/upload/ui",
baseUri: HttpClient.BaseAddress);
@@ -116,6 +139,7 @@ partial void ProcessUploadFilesForUiApiV1PptFilesUploadUiPostResponseContent(
__httpRequest.Headers.Add(__authorization.Name, __authorization.Value);
}
}
+
var __httpRequestContent = new global::System.Net.Http.MultipartFormDataContent();
if (request.Files != default)
{
@@ -123,8 +147,11 @@ partial void ProcessUploadFilesForUiApiV1PptFilesUploadUiPostResponseContent(
__httpRequestContent.Add(
content: new global::System.Net.Http.StringContent(request.Files.ToString() ?? string.Empty),
name: "\"files\"");
+
}
+
__httpRequest.Content = __httpRequestContent;
+
global::Presenton.AutoSDKRequestOptionsSupport.ApplyHeaders(
request: __httpRequest,
clientHeaders: Options.Headers,
@@ -166,6 +193,8 @@ partial void ProcessUploadFilesForUiApiV1PptFilesUploadUiPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -176,6 +205,11 @@ partial void ProcessUploadFilesForUiApiV1PptFilesUploadUiPostResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -193,6 +227,8 @@ partial void ProcessUploadFilesForUiApiV1PptFilesUploadUiPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -202,8 +238,7 @@ partial void ProcessUploadFilesForUiApiV1PptFilesUploadUiPostResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -212,6 +247,11 @@ partial void ProcessUploadFilesForUiApiV1PptFilesUploadUiPostResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -228,14 +268,15 @@ partial void ProcessUploadFilesForUiApiV1PptFilesUploadUiPostResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -275,6 +316,8 @@ partial void ProcessUploadFilesForUiApiV1PptFilesUploadUiPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -295,6 +338,8 @@ partial void ProcessUploadFilesForUiApiV1PptFilesUploadUiPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -357,9 +402,13 @@ partial void ProcessUploadFilesForUiApiV1PptFilesUploadUiPostResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- (global::System.Collections.Generic.IList?)global::System.Text.Json.JsonSerializer.Deserialize(__content, typeof(global::System.Collections.Generic.IList), JsonSerializerContext) ??
+ var __value = (global::System.Collections.Generic.IList?)global::System.Text.Json.JsonSerializer.Deserialize(__content, typeof(global::System.Collections.Generic.IList), JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse>(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
@@ -387,9 +436,13 @@ partial void ProcessUploadFilesForUiApiV1PptFilesUploadUiPostResponseContent(
#endif
).ConfigureAwait(false);
- return
- (global::System.Collections.Generic.IList?)await global::System.Text.Json.JsonSerializer.DeserializeAsync(__content, typeof(global::System.Collections.Generic.IList), JsonSerializerContext).ConfigureAwait(false) ??
+ var __value = (global::System.Collections.Generic.IList?)await global::System.Text.Json.JsonSerializer.DeserializeAsync(__content, typeof(global::System.Collections.Generic.IList), JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
+ return new global::Presenton.AutoSDKHttpResponse>(
+ statusCode: __response.StatusCode,
+ headers: global::Presenton.AutoSDKHttpResponse.CreateHeaders(__response),
+ requestUri: __response.RequestMessage?.RequestUri,
+ body: __value);
}
catch (global::System.Exception __ex)
{
diff --git a/src/libs/Presenton/Generated/Presenton.FilesClient.UploadFilesV1ApiV1PptFilesUploadPost.g.cs b/src/libs/Presenton/Generated/Presenton.FilesClient.UploadFilesV1ApiV1PptFilesUploadPost.g.cs
index 6243955..af22856 100644
--- a/src/libs/Presenton/Generated/Presenton.FilesClient.UploadFilesV1ApiV1PptFilesUploadPost.g.cs
+++ b/src/libs/Presenton/Generated/Presenton.FilesClient.UploadFilesV1ApiV1PptFilesUploadPost.g.cs
@@ -53,6 +53,31 @@ partial void ProcessUploadFilesV1ApiV1PptFilesUploadPostResponseContent(
///
public async global::System.Threading.Tasks.Task> UploadFilesV1ApiV1PptFilesUploadPostAsync(
+ global::Presenton.BodyUploadFilesV1ApiV1PptFilesUploadPost request,
+ global::Presenton.AutoSDKRequestOptions? requestOptions = default,
+ global::System.Threading.CancellationToken cancellationToken = default)
+ {
+ var __response = await UploadFilesV1ApiV1PptFilesUploadPostAsResponseAsync(
+
+ request: request,
+ requestOptions: requestOptions,
+ cancellationToken: cancellationToken
+ ).ConfigureAwait(false);
+
+ return __response.Body;
+ }
+ ///
+ /// Upload Files V1
+ /// Upload files to be used later.
+ /// Create an API Key from your account to access this endpoint.
+ /// Authorization: Bearer sk-presenton-xxxxxxxx
+ ///
+ ///
+ /// 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>> UploadFilesV1ApiV1PptFilesUploadPostAsResponseAsync(
+
global::Presenton.BodyUploadFilesV1ApiV1PptFilesUploadPost request,
global::Presenton.AutoSDKRequestOptions? requestOptions = default,
global::System.Threading.CancellationToken cancellationToken = default)
@@ -83,10 +108,11 @@ partial void ProcessUploadFilesV1ApiV1PptFilesUploadPostResponseContent(
var __maxAttempts = global::Presenton.AutoSDKRequestOptionsSupport.GetMaxAttempts(
clientOptions: Options,
requestOptions: requestOptions,
- supportsRetry: true);
+ supportsRetry: false);
global::System.Net.Http.HttpRequestMessage __CreateHttpRequest()
{
+
var __pathBuilder = new global::Presenton.PathBuilder(
path: "/api/v1/ppt/files/upload",
baseUri: HttpClient.BaseAddress);
@@ -119,6 +145,7 @@ partial void ProcessUploadFilesV1ApiV1PptFilesUploadPostResponseContent(
__httpRequest.Headers.Add(__authorization.Name, __authorization.Value);
}
}
+
var __httpRequestContent = new global::System.Net.Http.MultipartFormDataContent();
if (request.Files != default)
{
@@ -126,8 +153,11 @@ partial void ProcessUploadFilesV1ApiV1PptFilesUploadPostResponseContent(
__httpRequestContent.Add(
content: new global::System.Net.Http.StringContent(request.Files.ToString() ?? string.Empty),
name: "\"files\"");
+
}
+
__httpRequest.Content = __httpRequestContent;
+
global::Presenton.AutoSDKRequestOptionsSupport.ApplyHeaders(
request: __httpRequest,
clientHeaders: Options.Headers,
@@ -169,6 +199,8 @@ partial void ProcessUploadFilesV1ApiV1PptFilesUploadPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
try
{
@@ -179,6 +211,11 @@ partial void ProcessUploadFilesV1ApiV1PptFilesUploadPostResponseContent(
}
catch (global::System.Net.Http.HttpRequestException __exception)
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: null,
+ attempt: __attempt);
var __willRetry = __attempt < __maxAttempts && !__effectiveCancellationToken.IsCancellationRequested;
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
@@ -196,6 +233,8 @@ partial void ProcessUploadFilesV1ApiV1PptFilesUploadPostResponseContent(
attempt: __attempt,
maxAttempts: __maxAttempts,
willRetry: __willRetry,
+ retryDelay: __willRetry ? __retryDelay : (global::System.TimeSpan?)null,
+ retryReason: "exception",
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
if (!__willRetry)
{
@@ -205,8 +244,7 @@ partial void ProcessUploadFilesV1ApiV1PptFilesUploadPostResponseContent(
__httpRequest.Dispose();
__httpRequest = null;
await global::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -215,6 +253,11 @@ partial void ProcessUploadFilesV1ApiV1PptFilesUploadPostResponseContent(
__attempt < __maxAttempts &&
global::Presenton.AutoSDKRequestOptionsSupport.ShouldRetryStatusCode(__response.StatusCode))
{
+ var __retryDelay = global::Presenton.AutoSDKRequestOptionsSupport.GetRetryDelay(
+ clientOptions: Options,
+ requestOptions: requestOptions,
+ response: __response,
+ attempt: __attempt);
await global::Presenton.AutoSDKRequestOptionsSupport.OnAfterErrorAsync(
clientOptions: Options,
context: global::Presenton.AutoSDKRequestOptionsSupport.CreateHookContext(
@@ -231,14 +274,15 @@ partial void ProcessUploadFilesV1ApiV1PptFilesUploadPostResponseContent(
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::Presenton.AutoSDKRequestOptionsSupport.DelayBeforeRetryAsync(
- clientOptions: Options,
- requestOptions: requestOptions,
+ retryDelay: __retryDelay,
cancellationToken: __effectiveCancellationToken).ConfigureAwait(false);
continue;
}
@@ -278,6 +322,8 @@ partial void ProcessUploadFilesV1ApiV1PptFilesUploadPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
else
@@ -298,6 +344,8 @@ partial void ProcessUploadFilesV1ApiV1PptFilesUploadPostResponseContent(
attempt: __attemptNumber,
maxAttempts: __maxAttempts,
willRetry: false,
+ retryDelay: null,
+ retryReason: global::System.String.Empty,
cancellationToken: __effectiveCancellationToken)).ConfigureAwait(false);
}
// Validation Error
@@ -360,9 +408,13 @@ partial void ProcessUploadFilesV1ApiV1PptFilesUploadPostResponseContent(
{
__response.EnsureSuccessStatusCode();
- return
- (global::System.Collections.Generic.IList?)global::System.Text.Json.JsonSerializer.Deserialize(__content, typeof(global::System.Collections.Generic.IList), JsonSerializerContext) ??
+ var __value = (global::System.Collections.Generic.IList?)global::System.Text.Json.JsonSerializer.Deserialize(__content, typeof(global::System.Collections.Generic.IList), JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
+ return new global::Presenton.AutoSDKHttpResponse