Skip to content

Commit 146c97a

Browse files
HavenDVgithub-actions[bot]
andauthored
feat: Updated OpenAPI spec (#101)
Co-authored-by: github-actions[bot] <dependabot@bot.com>
1 parent f1d9861 commit 146c97a

10 files changed

Lines changed: 184 additions & 46 deletions

src/libs/Apify/Generated/Apify.ActorRunsClient.PostResurrectRun.g.cs

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -498,6 +498,43 @@ partial void ProcessPostResurrectRunResponseContent(
498498
h => h.Key,
499499
h => h.Value));
500500
}
501+
// Payment required - the user has exceeded their usage limit, does not have enough credits, or the request lacks authentication and payment credentials.
502+
if ((int)__response.StatusCode == 402)
503+
{
504+
string? __content_402 = null;
505+
global::System.Exception? __exception_402 = null;
506+
global::Apify.ErrorResponse? __value_402 = null;
507+
try
508+
{
509+
if (__effectiveReadResponseAsString)
510+
{
511+
__content_402 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false);
512+
__value_402 = global::Apify.ErrorResponse.FromJson(__content_402, JsonSerializerContext);
513+
}
514+
else
515+
{
516+
__content_402 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false);
517+
518+
__value_402 = global::Apify.ErrorResponse.FromJson(__content_402, JsonSerializerContext);
519+
}
520+
}
521+
catch (global::System.Exception __ex)
522+
{
523+
__exception_402 = __ex;
524+
}
525+
526+
527+
throw global::Apify.ApiException<global::Apify.ErrorResponse>.Create(
528+
statusCode: __response.StatusCode,
529+
message: __content_402 ?? __response.ReasonPhrase ?? string.Empty,
530+
innerException: __exception_402,
531+
responseBody: __content_402,
532+
responseObject: __value_402,
533+
responseHeaders: global::System.Linq.Enumerable.ToDictionary(
534+
__response.Headers,
535+
h => h.Key,
536+
h => h.Value));
537+
}
501538
// Forbidden - insufficient permissions to perform this action.
502539
if ((int)__response.StatusCode == 403)
503540
{

src/libs/Apify/Generated/Apify.ActorTasksClient.ActorTaskRunSyncGetDatasetItemsPost.g.cs

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1032,6 +1032,43 @@ partial void ProcessActorTaskRunSyncGetDatasetItemsPostResponseContent(
10321032
h => h.Key,
10331033
h => h.Value));
10341034
}
1035+
// The HTTP request exceeded the timeout limit
1036+
if ((int)__response.StatusCode == 408)
1037+
{
1038+
string? __content_408 = null;
1039+
global::System.Exception? __exception_408 = null;
1040+
global::Apify.ErrorResponse? __value_408 = null;
1041+
try
1042+
{
1043+
if (__effectiveReadResponseAsString)
1044+
{
1045+
__content_408 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false);
1046+
__value_408 = global::Apify.ErrorResponse.FromJson(__content_408, JsonSerializerContext);
1047+
}
1048+
else
1049+
{
1050+
__content_408 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false);
1051+
1052+
__value_408 = global::Apify.ErrorResponse.FromJson(__content_408, JsonSerializerContext);
1053+
}
1054+
}
1055+
catch (global::System.Exception __ex)
1056+
{
1057+
__exception_408 = __ex;
1058+
}
1059+
1060+
1061+
throw global::Apify.ApiException<global::Apify.ErrorResponse>.Create(
1062+
statusCode: __response.StatusCode,
1063+
message: __content_408 ?? __response.ReasonPhrase ?? string.Empty,
1064+
innerException: __exception_408,
1065+
responseBody: __content_408,
1066+
responseObject: __value_408,
1067+
responseHeaders: global::System.Linq.Enumerable.ToDictionary(
1068+
__response.Headers,
1069+
h => h.Key,
1070+
h => h.Value));
1071+
}
10351072
// Payload too large - the request body exceeds the size limit.
10361073
if ((int)__response.StatusCode == 413)
10371074
{

src/libs/Apify/Generated/Apify.ActorsActorRunsClient.ActRunResurrectPost.g.cs

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -495,6 +495,43 @@ partial void ProcessActRunResurrectPostResponseContent(
495495
h => h.Key,
496496
h => h.Value));
497497
}
498+
// Payment required - the user has exceeded their usage limit, does not have enough credits, or the request lacks authentication and payment credentials.
499+
if ((int)__response.StatusCode == 402)
500+
{
501+
string? __content_402 = null;
502+
global::System.Exception? __exception_402 = null;
503+
global::Apify.ErrorResponse? __value_402 = null;
504+
try
505+
{
506+
if (__effectiveReadResponseAsString)
507+
{
508+
__content_402 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false);
509+
__value_402 = global::Apify.ErrorResponse.FromJson(__content_402, JsonSerializerContext);
510+
}
511+
else
512+
{
513+
__content_402 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false);
514+
515+
__value_402 = global::Apify.ErrorResponse.FromJson(__content_402, JsonSerializerContext);
516+
}
517+
}
518+
catch (global::System.Exception __ex)
519+
{
520+
__exception_402 = __ex;
521+
}
522+
523+
524+
throw global::Apify.ApiException<global::Apify.ErrorResponse>.Create(
525+
statusCode: __response.StatusCode,
526+
message: __content_402 ?? __response.ReasonPhrase ?? string.Empty,
527+
innerException: __exception_402,
528+
responseBody: __content_402,
529+
responseObject: __value_402,
530+
responseHeaders: global::System.Linq.Enumerable.ToDictionary(
531+
__response.Headers,
532+
h => h.Key,
533+
h => h.Value));
534+
}
498535
// Forbidden - insufficient permissions to perform this action.
499536
if ((int)__response.StatusCode == 403)
500537
{

src/libs/Apify/Generated/Apify.ActorsActorRunsClient.ActRunSyncGetDatasetItemsGet.g.cs

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -848,6 +848,43 @@ partial void ProcessActRunSyncGetDatasetItemsGetResponseContent(
848848
h => h.Key,
849849
h => h.Value));
850850
}
851+
// Payment required - the user has exceeded their usage limit, does not have enough credits, or the request lacks authentication and payment credentials.
852+
if ((int)__response.StatusCode == 402)
853+
{
854+
string? __content_402 = null;
855+
global::System.Exception? __exception_402 = null;
856+
global::Apify.ErrorResponse? __value_402 = null;
857+
try
858+
{
859+
if (__effectiveReadResponseAsString)
860+
{
861+
__content_402 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false);
862+
__value_402 = global::Apify.ErrorResponse.FromJson(__content_402, JsonSerializerContext);
863+
}
864+
else
865+
{
866+
__content_402 = await __response.Content.ReadAsStringAsync(__effectiveCancellationToken).ConfigureAwait(false);
867+
868+
__value_402 = global::Apify.ErrorResponse.FromJson(__content_402, JsonSerializerContext);
869+
}
870+
}
871+
catch (global::System.Exception __ex)
872+
{
873+
__exception_402 = __ex;
874+
}
875+
876+
877+
throw global::Apify.ApiException<global::Apify.ErrorResponse>.Create(
878+
statusCode: __response.StatusCode,
879+
message: __content_402 ?? __response.ReasonPhrase ?? string.Empty,
880+
innerException: __exception_402,
881+
responseBody: __content_402,
882+
responseObject: __value_402,
883+
responseHeaders: global::System.Linq.Enumerable.ToDictionary(
884+
__response.Headers,
885+
h => h.Key,
886+
h => h.Value));
887+
}
851888
// Forbidden - insufficient permissions to perform this action.
852889
if ((int)__response.StatusCode == 403)
853890
{

src/libs/Apify/Generated/Apify.Models.BuildStats.g.cs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,7 @@ public sealed partial class BuildStats
2424
///
2525
/// </summary>
2626
[global::System.Text.Json.Serialization.JsonPropertyName("computeUnits")]
27-
[global::System.Text.Json.Serialization.JsonRequired]
28-
public required double ComputeUnits { get; set; }
27+
public double? ComputeUnits { get; set; }
2928

3029
/// <summary>
3130
///
@@ -42,17 +41,17 @@ public sealed partial class BuildStats
4241
/// <summary>
4342
/// Initializes a new instance of the <see cref="BuildStats" /> class.
4443
/// </summary>
45-
/// <param name="computeUnits"></param>
4644
/// <param name="durationMillis"></param>
4745
/// <param name="runTimeSecs"></param>
46+
/// <param name="computeUnits"></param>
4847
/// <param name="imageSizeBytes"></param>
4948
#if NET7_0_OR_GREATER
5049
[global::System.Diagnostics.CodeAnalysis.SetsRequiredMembers]
5150
#endif
5251
public BuildStats(
53-
double computeUnits,
5452
int? durationMillis,
5553
double? runTimeSecs,
54+
double? computeUnits,
5655
long? imageSizeBytes)
5756
{
5857
this.DurationMillis = durationMillis;

src/libs/Apify/Generated/Apify.Models.KeyValueStoreStats.g.cs

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,15 +12,13 @@ public sealed partial class KeyValueStoreStats
1212
///
1313
/// </summary>
1414
[global::System.Text.Json.Serialization.JsonPropertyName("readCount")]
15-
[global::System.Text.Json.Serialization.JsonRequired]
16-
public required int ReadCount { get; set; }
15+
public int? ReadCount { get; set; }
1716

1817
/// <summary>
1918
///
2019
/// </summary>
2120
[global::System.Text.Json.Serialization.JsonPropertyName("writeCount")]
22-
[global::System.Text.Json.Serialization.JsonRequired]
23-
public required int WriteCount { get; set; }
21+
public int? WriteCount { get; set; }
2422

2523
/// <summary>
2624
///
@@ -65,8 +63,8 @@ public sealed partial class KeyValueStoreStats
6563
[global::System.Diagnostics.CodeAnalysis.SetsRequiredMembers]
6664
#endif
6765
public KeyValueStoreStats(
68-
int readCount,
69-
int writeCount,
66+
int? readCount,
67+
int? writeCount,
7068
int? deleteCount,
7169
int? listCount,
7270
long? s3StorageBytes,

src/libs/Apify/Generated/Apify.Models.RunStats.g.cs

Lines changed: 10 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -30,15 +30,13 @@ public sealed partial class RunStats
3030
///
3131
/// </summary>
3232
[global::System.Text.Json.Serialization.JsonPropertyName("restartCount")]
33-
[global::System.Text.Json.Serialization.JsonRequired]
34-
public required int RestartCount { get; set; }
33+
public int? RestartCount { get; set; }
3534

3635
/// <summary>
3736
///
3837
/// </summary>
3938
[global::System.Text.Json.Serialization.JsonPropertyName("resurrectCount")]
40-
[global::System.Text.Json.Serialization.JsonRequired]
41-
public required int ResurrectCount { get; set; }
39+
public int? ResurrectCount { get; set; }
4240

4341
/// <summary>
4442
///
@@ -110,8 +108,7 @@ public sealed partial class RunStats
110108
///
111109
/// </summary>
112110
[global::System.Text.Json.Serialization.JsonPropertyName("computeUnits")]
113-
[global::System.Text.Json.Serialization.JsonRequired]
114-
public required double ComputeUnits { get; set; }
111+
public double? ComputeUnits { get; set; }
115112

116113
/// <summary>
117114
/// Additional properties that are not explicitly defined in the schema
@@ -122,12 +119,11 @@ public sealed partial class RunStats
122119
/// <summary>
123120
/// Initializes a new instance of the <see cref="RunStats" /> class.
124121
/// </summary>
125-
/// <param name="restartCount"></param>
126-
/// <param name="resurrectCount"></param>
127-
/// <param name="computeUnits"></param>
128122
/// <param name="inputBodyLen"></param>
129123
/// <param name="migrationCount"></param>
130124
/// <param name="rebootCount"></param>
125+
/// <param name="restartCount"></param>
126+
/// <param name="resurrectCount"></param>
131127
/// <param name="memAvgBytes"></param>
132128
/// <param name="memMaxBytes"></param>
133129
/// <param name="memCurrentBytes"></param>
@@ -139,16 +135,16 @@ public sealed partial class RunStats
139135
/// <param name="durationMillis"></param>
140136
/// <param name="runTimeSecs"></param>
141137
/// <param name="metamorph"></param>
138+
/// <param name="computeUnits"></param>
142139
#if NET7_0_OR_GREATER
143140
[global::System.Diagnostics.CodeAnalysis.SetsRequiredMembers]
144141
#endif
145142
public RunStats(
146-
int restartCount,
147-
int resurrectCount,
148-
double computeUnits,
149143
int? inputBodyLen,
150144
int? migrationCount,
151145
int? rebootCount,
146+
int? restartCount,
147+
int? resurrectCount,
152148
double? memAvgBytes,
153149
long? memMaxBytes,
154150
long? memCurrentBytes,
@@ -159,7 +155,8 @@ public RunStats(
159155
long? netTxBytes,
160156
int? durationMillis,
161157
double? runTimeSecs,
162-
int? metamorph)
158+
int? metamorph,
159+
double? computeUnits)
163160
{
164161
this.InputBodyLen = inputBodyLen;
165162
this.MigrationCount = migrationCount;

src/libs/Apify/Generated/Apify.Models.WebhookStats.g.cs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,7 @@ public sealed partial class WebhookStats
1212
///
1313
/// </summary>
1414
[global::System.Text.Json.Serialization.JsonPropertyName("totalDispatches")]
15-
[global::System.Text.Json.Serialization.JsonRequired]
16-
public required int TotalDispatches { get; set; }
15+
public int? TotalDispatches { get; set; }
1716

1817
/// <summary>
1918
/// Additional properties that are not explicitly defined in the schema
@@ -29,7 +28,7 @@ public sealed partial class WebhookStats
2928
[global::System.Diagnostics.CodeAnalysis.SetsRequiredMembers]
3029
#endif
3130
public WebhookStats(
32-
int totalDispatches)
31+
int? totalDispatches)
3332
{
3433
this.TotalDispatches = totalDispatches;
3534
}

0 commit comments

Comments
 (0)