Skip to content

Commit f527be3

Browse files
ToshYgithub-actions[bot]
authored andcommitted
Updated API models
1 parent 03e6907 commit f527be3

20 files changed

Lines changed: 557 additions & 7 deletions

generator/Map/Core.php

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@
5555
use ToshY\BunnyNet\Model\Api\Core\PullZone\AddOrUpdateEdgeRule;
5656
use ToshY\BunnyNet\Model\Api\Core\PullZone\AddPullZone;
5757
use ToshY\BunnyNet\Model\Api\Core\PullZone\CheckPullZoneAvailability;
58+
use ToshY\BunnyNet\Model\Api\Core\PullZone\CompleteExternalDnsCertificate;
5859
use ToshY\BunnyNet\Model\Api\Core\PullZone\DeleteEdgeRule;
5960
use ToshY\BunnyNet\Model\Api\Core\PullZone\DeletePullZone;
6061
use ToshY\BunnyNet\Model\Api\Core\PullZone\GetOptimizerStatistics;
@@ -69,6 +70,7 @@
6970
use ToshY\BunnyNet\Model\Api\Core\PullZone\RemoveBlockedReferer;
7071
use ToshY\BunnyNet\Model\Api\Core\PullZone\RemoveCertificate;
7172
use ToshY\BunnyNet\Model\Api\Core\PullZone\RemoveCustomHostname;
73+
use ToshY\BunnyNet\Model\Api\Core\PullZone\RequestExternalDnsCertificate;
7274
use ToshY\BunnyNet\Model\Api\Core\PullZone\ResetTokenKey;
7375
use ToshY\BunnyNet\Model\Api\Core\PullZone\SetEdgeRuleEnabled;
7476
use ToshY\BunnyNet\Model\Api\Core\PullZone\SetForceSsl;
@@ -206,6 +208,12 @@ final class Core
206208
'/pullzone/loadFreeCertificate' => [
207209
'get' => LoadFreeCertificate::class,
208210
],
211+
'/pullzone/requestExternalDnsCertificate' => [
212+
'post' => RequestExternalDnsCertificate::class,
213+
],
214+
'/pullzone/completeExternalDnsCertificate' => [
215+
'post' => CompleteExternalDnsCertificate::class,
216+
],
209217
'/pullzone/{id}/purgeCache' => [
210218
'post' => PurgeCache::class,
211219
],

generator/Map/Shield.php

Lines changed: 26 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,17 +12,24 @@
1212
use ToshY\BunnyNet\Model\Api\Shield\AccessLists\UpdateShieldZoneAccessList;
1313
use ToshY\BunnyNet\Model\Api\Shield\AccessLists\UpdateShieldZoneCuratedThreatList;
1414
use ToshY\BunnyNet\Model\Api\Shield\ApiGuardian\GetApiGuardian;
15+
use ToshY\BunnyNet\Model\Api\Shield\ApiGuardian\GetApiGuardianEnums;
1516
use ToshY\BunnyNet\Model\Api\Shield\ApiGuardian\UpdateApiGuardian;
1617
use ToshY\BunnyNet\Model\Api\Shield\ApiGuardian\UpdateOpenapiSpecification;
17-
use ToshY\BunnyNet\Model\Api\Shield\ApiGuardian\UploadOpenapiSpecification;
18+
use ToshY\BunnyNet\Model\Api\Shield\ApiGuardian\UpdateYourOpenapiSpecification;
19+
use ToshY\BunnyNet\Model\Api\Shield\ApiGuardian\UploadYourOpenapiSpecification;
1820
use ToshY\BunnyNet\Model\Api\Shield\BotDetection\CreateOrUpdateShieldZoneBotDetection;
1921
use ToshY\BunnyNet\Model\Api\Shield\BotDetection\GetShieldZoneBotDetection;
22+
use ToshY\BunnyNet\Model\Api\Shield\CustomResponsePages\DeleteCustomResponsePage;
23+
use ToshY\BunnyNet\Model\Api\Shield\CustomResponsePages\GetCustomResponsePage;
24+
use ToshY\BunnyNet\Model\Api\Shield\CustomResponsePages\UploadCustomResponsePage;
2025
use ToshY\BunnyNet\Model\Api\Shield\Ddos\ListDdosEnums;
2126
use ToshY\BunnyNet\Model\Api\Shield\EventLogs\ListEventLogs;
27+
use ToshY\BunnyNet\Model\Api\Shield\Metrics\GetApiGuardianEndpointMetrics;
2228
use ToshY\BunnyNet\Model\Api\Shield\Metrics\GetBotDetectionMetrics;
2329
use ToshY\BunnyNet\Model\Api\Shield\Metrics\GetMetricsOverviewDetailed;
2430
use ToshY\BunnyNet\Model\Api\Shield\Metrics\GetOverviewMetrics;
2531
use ToshY\BunnyNet\Model\Api\Shield\Metrics\GetRateLimitMetrics;
32+
use ToshY\BunnyNet\Model\Api\Shield\Metrics\GetShieldZoneApiGuardianMetrics;
2633
use ToshY\BunnyNet\Model\Api\Shield\Metrics\GetUploadScanningMetrics;
2734
use ToshY\BunnyNet\Model\Api\Shield\Metrics\GetWafRuleMetrics;
2835
use ToshY\BunnyNet\Model\Api\Shield\Metrics\ListRateLimitMetrics;
@@ -79,16 +86,27 @@ final class Shield
7986
],
8087
'/shield/shield-zone/{shieldZoneId}/api-guardian' => [
8188
'get' => GetApiGuardian::class,
82-
'post' => UploadOpenapiSpecification::class,
8389
'patch' => UpdateOpenapiSpecification::class,
8490
],
8591
'/shield/shield-zone/{shieldZoneId}/api-guardian/endpoint/{endpointId}' => [
8692
'patch' => UpdateApiGuardian::class,
8793
],
94+
'/shield/shield-zone/{shieldZoneId}/api-guardian/spec' => [
95+
'post' => UploadYourOpenapiSpecification::class,
96+
'patch' => UpdateYourOpenapiSpecification::class,
97+
],
98+
'/shield/shield-zone/{shieldZoneId}/api-guardian/enums' => [
99+
'get' => GetApiGuardianEnums::class,
100+
],
88101
'/shield/shield-zone/{shieldZoneId}/bot-detection' => [
89102
'get' => GetShieldZoneBotDetection::class,
90103
'patch' => CreateOrUpdateShieldZoneBotDetection::class,
91104
],
105+
'/shield/shield-zone/{shieldZoneId}/custom-page/{pageType}' => [
106+
'get' => GetCustomResponsePage::class,
107+
'put' => UploadCustomResponsePage::class,
108+
'delete' => DeleteCustomResponsePage::class,
109+
],
92110
'/shield/ddos/enums' => [
93111
'get' => ListDdosEnums::class,
94112
],
@@ -116,6 +134,12 @@ final class Shield
116134
'/shield/metrics/shield-zone/{shieldZoneId}/upload-scanning' => [
117135
'get' => GetUploadScanningMetrics::class,
118136
],
137+
'/shield/metrics/shield-zone/{shieldZoneId}/api-guardian' => [
138+
'get' => GetShieldZoneApiGuardianMetrics::class,
139+
],
140+
'/shield/metrics/shield-zone/{shieldZoneId}/api-guardian/endpoint/{endpointId}' => [
141+
'get' => GetApiGuardianEndpointMetrics::class,
142+
],
119143
'/shield/promo/state' => [
120144
'get' => GetCurrentPromotions::class,
121145
],

src/Enum/Validation/Map/Core.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@
5757
use ToshY\BunnyNet\Model\Api\Core\PullZone\AddOrUpdateEdgeRule;
5858
use ToshY\BunnyNet\Model\Api\Core\PullZone\AddPullZone;
5959
use ToshY\BunnyNet\Model\Api\Core\PullZone\CheckPullZoneAvailability;
60+
use ToshY\BunnyNet\Model\Api\Core\PullZone\CompleteExternalDnsCertificate;
6061
use ToshY\BunnyNet\Model\Api\Core\PullZone\DeleteEdgeRule;
6162
use ToshY\BunnyNet\Model\Api\Core\PullZone\DeletePullZone;
6263
use ToshY\BunnyNet\Model\Api\Core\PullZone\GetOptimizerStatistics;
@@ -71,6 +72,7 @@
7172
use ToshY\BunnyNet\Model\Api\Core\PullZone\RemoveBlockedReferer;
7273
use ToshY\BunnyNet\Model\Api\Core\PullZone\RemoveCertificate;
7374
use ToshY\BunnyNet\Model\Api\Core\PullZone\RemoveCustomHostname;
75+
use ToshY\BunnyNet\Model\Api\Core\PullZone\RequestExternalDnsCertificate;
7476
use ToshY\BunnyNet\Model\Api\Core\PullZone\ResetTokenKey;
7577
use ToshY\BunnyNet\Model\Api\Core\PullZone\SetEdgeRuleEnabled;
7678
use ToshY\BunnyNet\Model\Api\Core\PullZone\SetForceSsl;
@@ -166,6 +168,8 @@ final class Core
166168
GetOptimizerStatistics::class => ModelValidationStrategy::STRICT_QUERY,
167169
UpdatePrivateKeyType::class => ModelValidationStrategy::STRICT_BODY,
168170
LoadFreeCertificate::class => ModelValidationStrategy::STRICT_QUERY,
171+
RequestExternalDnsCertificate::class => ModelValidationStrategy::STRICT_BODY,
172+
CompleteExternalDnsCertificate::class => ModelValidationStrategy::STRICT_BODY,
169173
PurgeCache::class => ModelValidationStrategy::STRICT_BODY,
170174
CheckPullZoneAvailability::class => ModelValidationStrategy::STRICT_BODY,
171175
AddCustomCertificate::class => ModelValidationStrategy::STRICT_BODY,

src/Enum/Validation/Map/Shield.php

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,17 +13,24 @@
1313
use ToshY\BunnyNet\Model\Api\Shield\AccessLists\UpdateShieldZoneAccessList;
1414
use ToshY\BunnyNet\Model\Api\Shield\AccessLists\UpdateShieldZoneCuratedThreatList;
1515
use ToshY\BunnyNet\Model\Api\Shield\ApiGuardian\GetApiGuardian;
16+
use ToshY\BunnyNet\Model\Api\Shield\ApiGuardian\GetApiGuardianEnums;
1617
use ToshY\BunnyNet\Model\Api\Shield\ApiGuardian\UpdateApiGuardian;
1718
use ToshY\BunnyNet\Model\Api\Shield\ApiGuardian\UpdateOpenapiSpecification;
18-
use ToshY\BunnyNet\Model\Api\Shield\ApiGuardian\UploadOpenapiSpecification;
19+
use ToshY\BunnyNet\Model\Api\Shield\ApiGuardian\UpdateYourOpenapiSpecification;
20+
use ToshY\BunnyNet\Model\Api\Shield\ApiGuardian\UploadYourOpenapiSpecification;
1921
use ToshY\BunnyNet\Model\Api\Shield\BotDetection\CreateOrUpdateShieldZoneBotDetection;
2022
use ToshY\BunnyNet\Model\Api\Shield\BotDetection\GetShieldZoneBotDetection;
23+
use ToshY\BunnyNet\Model\Api\Shield\CustomResponsePages\DeleteCustomResponsePage;
24+
use ToshY\BunnyNet\Model\Api\Shield\CustomResponsePages\GetCustomResponsePage;
25+
use ToshY\BunnyNet\Model\Api\Shield\CustomResponsePages\UploadCustomResponsePage;
2126
use ToshY\BunnyNet\Model\Api\Shield\Ddos\ListDdosEnums;
2227
use ToshY\BunnyNet\Model\Api\Shield\EventLogs\ListEventLogs;
28+
use ToshY\BunnyNet\Model\Api\Shield\Metrics\GetApiGuardianEndpointMetrics;
2329
use ToshY\BunnyNet\Model\Api\Shield\Metrics\GetBotDetectionMetrics;
2430
use ToshY\BunnyNet\Model\Api\Shield\Metrics\GetMetricsOverviewDetailed;
2531
use ToshY\BunnyNet\Model\Api\Shield\Metrics\GetOverviewMetrics;
2632
use ToshY\BunnyNet\Model\Api\Shield\Metrics\GetRateLimitMetrics;
33+
use ToshY\BunnyNet\Model\Api\Shield\Metrics\GetShieldZoneApiGuardianMetrics;
2734
use ToshY\BunnyNet\Model\Api\Shield\Metrics\GetUploadScanningMetrics;
2835
use ToshY\BunnyNet\Model\Api\Shield\Metrics\GetWafRuleMetrics;
2936
use ToshY\BunnyNet\Model\Api\Shield\Metrics\ListRateLimitMetrics;
@@ -68,11 +75,16 @@ final class Shield
6875
UpdateShieldZoneAccessList::class => ModelValidationStrategy::STRICT_BODY,
6976
GetShieldZoneAccessListEnums::class => ModelValidationStrategy::NONE,
7077
GetApiGuardian::class => ModelValidationStrategy::NONE,
71-
UploadOpenapiSpecification::class => ModelValidationStrategy::STRICT_BODY,
7278
UpdateOpenapiSpecification::class => ModelValidationStrategy::STRICT_BODY,
7379
UpdateApiGuardian::class => ModelValidationStrategy::STRICT_BODY,
80+
UploadYourOpenapiSpecification::class => ModelValidationStrategy::STRICT_BODY,
81+
UpdateYourOpenapiSpecification::class => ModelValidationStrategy::STRICT_BODY,
82+
GetApiGuardianEnums::class => ModelValidationStrategy::NONE,
7483
GetShieldZoneBotDetection::class => ModelValidationStrategy::NONE,
7584
CreateOrUpdateShieldZoneBotDetection::class => ModelValidationStrategy::STRICT_BODY,
85+
GetCustomResponsePage::class => ModelValidationStrategy::NONE,
86+
UploadCustomResponsePage::class => ModelValidationStrategy::NONE,
87+
DeleteCustomResponsePage::class => ModelValidationStrategy::NONE,
7688
ListDdosEnums::class => ModelValidationStrategy::NONE,
7789
ListEventLogs::class => ModelValidationStrategy::NONE,
7890
GetOverviewMetrics::class => ModelValidationStrategy::NONE,
@@ -82,6 +94,8 @@ final class Shield
8294
GetWafRuleMetrics::class => ModelValidationStrategy::NONE,
8395
GetBotDetectionMetrics::class => ModelValidationStrategy::NONE,
8496
GetUploadScanningMetrics::class => ModelValidationStrategy::NONE,
97+
GetShieldZoneApiGuardianMetrics::class => ModelValidationStrategy::NONE,
98+
GetApiGuardianEndpointMetrics::class => ModelValidationStrategy::NONE,
8599
GetCurrentPromotions::class => ModelValidationStrategy::NONE,
86100
ListRateLimits::class => ModelValidationStrategy::STRICT_QUERY,
87101
GetRateLimit::class => ModelValidationStrategy::NONE,
Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
namespace ToshY\BunnyNet\Model\Api\Core\PullZone;
6+
7+
use ToshY\BunnyNet\Attributes\BodyProperty;
8+
use ToshY\BunnyNet\Enum\Header;
9+
use ToshY\BunnyNet\Enum\Method;
10+
use ToshY\BunnyNet\Enum\Type;
11+
use ToshY\BunnyNet\Model\AbstractParameter;
12+
use ToshY\BunnyNet\Model\BodyModelInterface;
13+
use ToshY\BunnyNet\Model\ModelInterface;
14+
15+
class CompleteExternalDnsCertificate implements ModelInterface, BodyModelInterface
16+
{
17+
/**
18+
* @param array<string,mixed> $body
19+
*/
20+
public function __construct(
21+
#[BodyProperty]
22+
public readonly array $body = [],
23+
) {
24+
}
25+
26+
public function getMethod(): Method
27+
{
28+
return Method::POST;
29+
}
30+
31+
public function getPath(): string
32+
{
33+
return 'pullzone/completeExternalDnsCertificate';
34+
}
35+
36+
public function getHeaders(): array
37+
{
38+
return [
39+
Header::ACCEPT_JSON,
40+
Header::CONTENT_TYPE_JSON,
41+
];
42+
}
43+
44+
public function getBody(): array
45+
{
46+
return [
47+
new AbstractParameter(name: 'Hostname', type: Type::STRING_TYPE, required: true),
48+
];
49+
}
50+
}
Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
namespace ToshY\BunnyNet\Model\Api\Core\PullZone;
6+
7+
use ToshY\BunnyNet\Attributes\BodyProperty;
8+
use ToshY\BunnyNet\Enum\Header;
9+
use ToshY\BunnyNet\Enum\Method;
10+
use ToshY\BunnyNet\Enum\Type;
11+
use ToshY\BunnyNet\Model\AbstractParameter;
12+
use ToshY\BunnyNet\Model\BodyModelInterface;
13+
use ToshY\BunnyNet\Model\ModelInterface;
14+
15+
class RequestExternalDnsCertificate implements ModelInterface, BodyModelInterface
16+
{
17+
/**
18+
* @param array<string,mixed> $body
19+
*/
20+
public function __construct(
21+
#[BodyProperty]
22+
public readonly array $body = [],
23+
) {
24+
}
25+
26+
public function getMethod(): Method
27+
{
28+
return Method::POST;
29+
}
30+
31+
public function getPath(): string
32+
{
33+
return 'pullzone/requestExternalDnsCertificate';
34+
}
35+
36+
public function getHeaders(): array
37+
{
38+
return [
39+
Header::ACCEPT_JSON,
40+
Header::CONTENT_TYPE_JSON,
41+
];
42+
}
43+
44+
public function getBody(): array
45+
{
46+
return [
47+
new AbstractParameter(name: 'Hostname', type: Type::STRING_TYPE, required: true),
48+
];
49+
}
50+
}

src/Model/Api/Core/Statistics/GetStatistics.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@ public function getQuery(): array
4949
new AbstractParameter(name: 'serverZoneId', type: Type::INT_TYPE),
5050
new AbstractParameter(name: 'loadErrors', type: Type::BOOLEAN_TYPE),
5151
new AbstractParameter(name: 'hourly', type: Type::BOOLEAN_TYPE),
52+
new AbstractParameter(name: 'exactRange', type: Type::BOOLEAN_TYPE),
5253
new AbstractParameter(name: 'loadOriginResponseTimes', type: Type::BOOLEAN_TYPE),
5354
new AbstractParameter(name: 'loadOriginTraffic', type: Type::BOOLEAN_TYPE),
5455
new AbstractParameter(name: 'loadRequestsServed', type: Type::BOOLEAN_TYPE),

src/Model/Api/Core/StreamVideoLibrary/AddVideoLibrary.php

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,24 @@ public function getBody(): array
4949
new AbstractParameter(name: null, type: Type::STRING_TYPE),
5050
]),
5151
new AbstractParameter(name: 'PlayerVersion', type: Type::INT_TYPE),
52+
new AbstractParameter(name: 'EncodingTier', type: Type::INT_TYPE),
53+
new AbstractParameter(name: 'JitEncodingEnabled', type: Type::BOOLEAN_TYPE),
54+
new AbstractParameter(name: 'OutputCodecs', type: Type::STRING_TYPE),
55+
new AbstractParameter(name: 'EnabledResolutions', type: Type::STRING_TYPE),
56+
new AbstractParameter(name: 'BlockNoneReferrer', type: Type::BOOLEAN_TYPE),
57+
new AbstractParameter(name: 'EnableMP4Fallback', type: Type::BOOLEAN_TYPE),
58+
new AbstractParameter(name: 'KeepOriginalFiles', type: Type::BOOLEAN_TYPE),
59+
new AbstractParameter(name: 'AllowDirectPlay', type: Type::BOOLEAN_TYPE),
60+
new AbstractParameter(name: 'EnableMultiAudioTrackSupport', type: Type::BOOLEAN_TYPE),
61+
new AbstractParameter(name: 'EnableTranscribing', type: Type::BOOLEAN_TYPE),
62+
new AbstractParameter(name: 'TranscribingCaptionLanguages', type: Type::ARRAY_TYPE, children: [
63+
new AbstractParameter(name: null, type: Type::STRING_TYPE),
64+
]),
65+
new AbstractParameter(name: 'EnableTranscribingTitleGeneration', type: Type::BOOLEAN_TYPE),
66+
new AbstractParameter(name: 'EnableTranscribingDescriptionGeneration', type: Type::BOOLEAN_TYPE),
67+
new AbstractParameter(name: 'EnableTranscribingChaptersGeneration', type: Type::BOOLEAN_TYPE),
68+
new AbstractParameter(name: 'EnableTranscribingMomentsGeneration', type: Type::BOOLEAN_TYPE),
69+
new AbstractParameter(name: 'AllowEarlyPlay', type: Type::BOOLEAN_TYPE),
5270
];
5371
}
5472
}

src/Model/Api/Core/StreamVideoLibrary/UpdateVideoLibrary.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,7 @@ public function getBody(): array
114114
new AbstractParameter(name: 'ScaleVideoUsingBothDimensions', type: Type::BOOLEAN_TYPE),
115115
new AbstractParameter(name: 'ExposeOriginals', type: Type::BOOLEAN_TYPE),
116116
new AbstractParameter(name: 'ExposeVideoMetadata', type: Type::BOOLEAN_TYPE),
117+
new AbstractParameter(name: 'EnableCompactControls', type: Type::BOOLEAN_TYPE),
117118
];
118119
}
119120
}
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
namespace ToshY\BunnyNet\Model\Api\Shield\ApiGuardian;
6+
7+
use ToshY\BunnyNet\Attributes\PathProperty;
8+
use ToshY\BunnyNet\Enum\Header;
9+
use ToshY\BunnyNet\Enum\Method;
10+
use ToshY\BunnyNet\Model\ModelInterface;
11+
12+
class GetApiGuardianEnums implements ModelInterface
13+
{
14+
/**
15+
* @param string $shieldZoneId
16+
*/
17+
public function __construct(
18+
#[PathProperty]
19+
public readonly string $shieldZoneId,
20+
) {
21+
}
22+
23+
public function getMethod(): Method
24+
{
25+
return Method::GET;
26+
}
27+
28+
public function getPath(): string
29+
{
30+
return 'shield/shield-zone/%s/api-guardian/enums';
31+
}
32+
33+
public function getHeaders(): array
34+
{
35+
return [
36+
Header::ACCEPT_JSON,
37+
];
38+
}
39+
}

0 commit comments

Comments
 (0)