Skip to content

Commit 0616184

Browse files
chore(Endpoints): expand request method options for new FreeRADIUS endpoints
1 parent 6b6deda commit 0616184

File tree

4 files changed

+8
-16
lines changed

4 files changed

+8
-16
lines changed

pfSense-pkg-RESTAPI/files/usr/local/pkg/RESTAPI/Endpoints/ServicesFreeRADIUSClientEndpoint.inc

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,11 @@ use RESTAPI\Core\Endpoint;
1212
*/
1313
class ServicesFreeRADIUSClientEndpoint extends Endpoint {
1414
public function __construct() {
15-
/**
16-
* Set Endpoint attributes
17-
*/
15+
# Set Endpoint attributes
1816
$this->url = '/api/v2/services/freeradius/client';
1917
$this->model_name = 'FreeRADIUSClient';
2018
$this->many = false;
21-
$this->request_method_options = ['GET', 'POST', 'DELETE'];
19+
$this->request_method_options = ['GET', 'POST', 'PATCH', 'DELETE'];
2220

2321
# Construct the parent Endpoint object
2422
parent::__construct();

pfSense-pkg-RESTAPI/files/usr/local/pkg/RESTAPI/Endpoints/ServicesFreeRADIUSClientsEndpoint.inc

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,11 @@ use RESTAPI\Core\Endpoint;
1212
*/
1313
class ServicesFreeRADIUSClientsEndpoint extends Endpoint {
1414
public function __construct() {
15-
/**
16-
* Set Endpoint attributes
17-
*/
15+
# Set Endpoint attributes
1816
$this->url = '/api/v2/services/freeradius/clients';
1917
$this->model_name = 'FreeRADIUSClient';
2018
$this->many = true;
21-
$this->request_method_options = ['GET'];
19+
$this->request_method_options = ['GET', 'PUT', 'DELETE'];
2220

2321
# Construct the parent Endpoint object
2422
parent::__construct();

pfSense-pkg-RESTAPI/files/usr/local/pkg/RESTAPI/Endpoints/ServicesFreeRADIUSInterfaceEndpoint.inc

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,11 @@ use RESTAPI\Core\Endpoint;
1212
*/
1313
class ServicesFreeRADIUSInterfaceEndpoint extends Endpoint {
1414
public function __construct() {
15-
/**
16-
* Set Endpoint attributes
17-
*/
15+
# Set Endpoint attributes
1816
$this->url = '/api/v2/services/freeradius/interface';
1917
$this->model_name = 'FreeRADIUSInterface';
2018
$this->many = false;
21-
$this->request_method_options = ['GET', 'POST', 'DELETE'];
19+
$this->request_method_options = ['GET', 'POST', 'PATCH', 'DELETE'];
2220

2321
# Construct the parent Endpoint object
2422
parent::__construct();

pfSense-pkg-RESTAPI/files/usr/local/pkg/RESTAPI/Endpoints/ServicesFreeRADIUSInterfacesEndpoint.inc

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,11 @@ use RESTAPI\Core\Endpoint;
1212
*/
1313
class ServicesFreeRADIUSInterfacesEndpoint extends Endpoint {
1414
public function __construct() {
15-
/**
16-
* Set Endpoint attributes
17-
*/
15+
# Set Endpoint attributes
1816
$this->url = '/api/v2/services/freeradius/interfaces';
1917
$this->model_name = 'FreeRADIUSInterface';
2018
$this->many = true;
21-
$this->request_method_options = ['GET'];
19+
$this->request_method_options = ['GET', 'PUT', 'DELETE'];
2220

2321
# Construct the parent Endpoint object
2422
parent::__construct();

0 commit comments

Comments
 (0)