Skip to content

Commit ec57b29

Browse files
committed
Endpoint properly named now.
Plural (Many) Endpoint added.
1 parent 56efb61 commit ec57b29

File tree

2 files changed

+54
-0
lines changed

2 files changed

+54
-0
lines changed
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
<?php
2+
3+
namespace RESTAPI\Endpoints;
4+
5+
require_once 'RESTAPI/autoloader.inc';
6+
7+
use RESTAPI\Core\Endpoint;
8+
9+
/**
10+
* Defines an Endpoint for interacting with a single OpenVPNExport Model object at
11+
* /api/v2/vpn/openvpn/clientexport.
12+
*/
13+
class ServicesFreeRADIUSUserEndpoint extends Endpoint {
14+
public function __construct() {
15+
/**
16+
* Set Endpoint attributes
17+
*/
18+
$this->url = '/api/v2/services/freeradius/user';
19+
$this->model_name = 'FreeRADIUSUser';
20+
$this->many = false;
21+
$this->request_method_options = ['GET', 'POST', 'DELETE'];
22+
23+
# Construct the parent Endpoint object
24+
parent::__construct();
25+
}
26+
}
27+
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
<?php
2+
3+
namespace RESTAPI\Endpoints;
4+
5+
require_once 'RESTAPI/autoloader.inc';
6+
7+
use RESTAPI\Core\Endpoint;
8+
9+
/**
10+
* Defines an Endpoint for interacting with a single OpenVPNExport Model object at
11+
* /api/v2/vpn/openvpn/clientexport.
12+
*/
13+
class ServicesFreeRADIUSUsersEndpoint extends Endpoint {
14+
public function __construct() {
15+
/**
16+
* Set Endpoint attributes
17+
*/
18+
$this->url = '/api/v2/services/freeradius/users';
19+
$this->model_name = 'FreeRADIUSUser';
20+
$this->many = true;
21+
$this->request_method_options = ['GET', 'DELETE'];
22+
23+
# Construct the parent Endpoint object
24+
parent::__construct();
25+
}
26+
}
27+

0 commit comments

Comments
 (0)