Skip to content

Commit c285e12

Browse files
Merge pull request #108 from jaredhendrickson13/fw_shaper_api
Firewall Shaper & Schedule Endpoints
2 parents 19db858 + f6637b4 commit c285e12

111 files changed

Lines changed: 18028 additions & 845 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/FUNDING.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
github: jaredhendrickson13

README.md

Lines changed: 6050 additions & 538 deletions
Large diffs are not rendered by default.

docs/documentation.json

Lines changed: 1912 additions & 151 deletions
Large diffs are not rendered by default.
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
<?php
2+
// Copyright 2021 Jared Hendrickson
3+
//
4+
// Licensed under the Apache License, Version 2.0 (the "License");
5+
// you may not use this file except in compliance with the License.
6+
// You may obtain a copy of the License at
7+
//
8+
// http://www.apache.org/licenses/LICENSE-2.0
9+
//
10+
// Unless required by applicable law or agreed to in writing, software
11+
// distributed under the License is distributed on an "AS IS" BASIS,
12+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
// See the License for the specific language governing permissions and
14+
// limitations under the License.
15+
16+
require_once("api/framework/APIEndpoint.inc");
17+
18+
class APIFirewallSchedule extends APIEndpoint {
19+
public function __construct() {
20+
$this->url = "/api/v1/firewall/schedule";
21+
}
22+
23+
protected function get() {
24+
return (new APIFirewallScheduleRead())->call();
25+
}
26+
27+
protected function post() {
28+
return (new APIFirewallScheduleCreate())->call();
29+
}
30+
31+
protected function put() {
32+
return (new APIFirewallScheduleUpdate())->call();
33+
}
34+
35+
protected function delete() {
36+
return (new APIFirewallScheduleDelete())->call();
37+
}
38+
}
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
<?php
2+
// Copyright 2021 Jared Hendrickson
3+
//
4+
// Licensed under the Apache License, Version 2.0 (the "License");
5+
// you may not use this file except in compliance with the License.
6+
// You may obtain a copy of the License at
7+
//
8+
// http://www.apache.org/licenses/LICENSE-2.0
9+
//
10+
// Unless required by applicable law or agreed to in writing, software
11+
// distributed under the License is distributed on an "AS IS" BASIS,
12+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
// See the License for the specific language governing permissions and
14+
// limitations under the License.
15+
16+
require_once("api/framework/APIEndpoint.inc");
17+
18+
class APIFirewallScheduleTimeRange extends APIEndpoint {
19+
public function __construct() {
20+
$this->url = "/api/v1/firewall/schedule/time_range";
21+
}
22+
23+
protected function post() {
24+
return (new APIFirewallScheduleTimeRangeCreate())->call();
25+
}
26+
27+
protected function delete() {
28+
return (new APIFirewallScheduleTimeRangeDelete())->call();
29+
}
30+
}
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
<?php
2+
// Copyright 2021 Jared Hendrickson
3+
//
4+
// Licensed under the Apache License, Version 2.0 (the "License");
5+
// you may not use this file except in compliance with the License.
6+
// You may obtain a copy of the License at
7+
//
8+
// http://www.apache.org/licenses/LICENSE-2.0
9+
//
10+
// Unless required by applicable law or agreed to in writing, software
11+
// distributed under the License is distributed on an "AS IS" BASIS,
12+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
// See the License for the specific language governing permissions and
14+
// limitations under the License.
15+
16+
require_once("api/framework/APIEndpoint.inc");
17+
18+
class APIFirewallTrafficShaper extends APIEndpoint {
19+
public function __construct() {
20+
$this->url = "/api/v1/firewall/traffic_shaper";
21+
}
22+
23+
protected function get() {
24+
return (new APIFirewallTrafficShaperRead())->call();
25+
}
26+
27+
protected function post() {
28+
return (new APIFirewallTrafficShaperCreate())->call();
29+
}
30+
31+
protected function put() {
32+
return (new APIFirewallTrafficShaperUpdate())->call();
33+
}
34+
35+
protected function delete() {
36+
return (new APIFirewallTrafficShaperDelete())->call();
37+
}
38+
}
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
<?php
2+
// Copyright 2021 Jared Hendrickson
3+
//
4+
// Licensed under the Apache License, Version 2.0 (the "License");
5+
// you may not use this file except in compliance with the License.
6+
// You may obtain a copy of the License at
7+
//
8+
// http://www.apache.org/licenses/LICENSE-2.0
9+
//
10+
// Unless required by applicable law or agreed to in writing, software
11+
// distributed under the License is distributed on an "AS IS" BASIS,
12+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
// See the License for the specific language governing permissions and
14+
// limitations under the License.
15+
16+
require_once("api/framework/APIEndpoint.inc");
17+
18+
class APIFirewallTrafficShaperLimiter extends APIEndpoint {
19+
public function __construct() {
20+
$this->url = "/api/v1/firewall/traffic_shaper/limiter";
21+
}
22+
23+
protected function get() {
24+
return (new APIFirewallTrafficShaperLimiterRead())->call();
25+
}
26+
27+
protected function post() {
28+
return (new APIFirewallTrafficShaperLimiterCreate())->call();
29+
}
30+
31+
protected function delete() {
32+
return (new APIFirewallTrafficShaperLimiterDelete())->call();
33+
}
34+
}
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
<?php
2+
// Copyright 2021 Jared Hendrickson
3+
//
4+
// Licensed under the Apache License, Version 2.0 (the "License");
5+
// you may not use this file except in compliance with the License.
6+
// You may obtain a copy of the License at
7+
//
8+
// http://www.apache.org/licenses/LICENSE-2.0
9+
//
10+
// Unless required by applicable law or agreed to in writing, software
11+
// distributed under the License is distributed on an "AS IS" BASIS,
12+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
// See the License for the specific language governing permissions and
14+
// limitations under the License.
15+
16+
require_once("api/framework/APIEndpoint.inc");
17+
18+
class APIFirewallTrafficShaperLimiterBandwidth extends APIEndpoint {
19+
public function __construct() {
20+
$this->url = "/api/v1/firewall/traffic_shaper/limiter/bandwidth";
21+
}
22+
23+
protected function post() {
24+
return (new APIFirewallTrafficShaperLimiterBandwidthCreate())->call();
25+
}
26+
27+
protected function delete() {
28+
return (new APIFirewallTrafficShaperLimiterBandwidthDelete())->call();
29+
}
30+
}
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
<?php
2+
// Copyright 2021 Jared Hendrickson
3+
//
4+
// Licensed under the Apache License, Version 2.0 (the "License");
5+
// you may not use this file except in compliance with the License.
6+
// You may obtain a copy of the License at
7+
//
8+
// http://www.apache.org/licenses/LICENSE-2.0
9+
//
10+
// Unless required by applicable law or agreed to in writing, software
11+
// distributed under the License is distributed on an "AS IS" BASIS,
12+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
// See the License for the specific language governing permissions and
14+
// limitations under the License.
15+
16+
require_once("api/framework/APIEndpoint.inc");
17+
18+
class APIFirewallTrafficShaperLimiterQueue extends APIEndpoint {
19+
public function __construct() {
20+
$this->url = "/api/v1/firewall/traffic_shaper/limiter/queue";
21+
}
22+
23+
protected function post() {
24+
return (new APIFirewallTrafficShaperLimiterQueueCreate())->call();
25+
}
26+
27+
protected function delete() {
28+
return (new APIFirewallTrafficShaperLimiterQueueDelete())->call();
29+
}
30+
}
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
<?php
2+
// Copyright 2021 Jared Hendrickson
3+
//
4+
// Licensed under the Apache License, Version 2.0 (the "License");
5+
// you may not use this file except in compliance with the License.
6+
// You may obtain a copy of the License at
7+
//
8+
// http://www.apache.org/licenses/LICENSE-2.0
9+
//
10+
// Unless required by applicable law or agreed to in writing, software
11+
// distributed under the License is distributed on an "AS IS" BASIS,
12+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
// See the License for the specific language governing permissions and
14+
// limitations under the License.
15+
16+
require_once("api/framework/APIEndpoint.inc");
17+
18+
class APIFirewallTrafficShaperQueue extends APIEndpoint {
19+
public function __construct() {
20+
$this->url = "/api/v1/firewall/traffic_shaper/queue";
21+
}
22+
23+
protected function post() {
24+
return (new APIFirewallTrafficShaperQueueCreate())->call();
25+
}
26+
27+
protected function delete() {
28+
return (new APIFirewallTrafficShaperQueueDelete())->call();
29+
}
30+
}

0 commit comments

Comments
 (0)