-
Notifications
You must be signed in to change notification settings - Fork 3
OcAgentsApi
This class contains all REST API calls to the /api/agents
endpoint.
It is accessible under OpencastApi\Rest
namespace.
This endpoint is available for API Version 1.1.0 or greater, therefore, it throws an Exception upon direct class instantiation, or it won't be defined as property in OpencastApi\OpenCast
class when api version is incompatible!
- In
OpencastApi\OpenCast
as its property with OpenCast properties naming convention:
use OpencastApi\OpenCast;
$opencastApi = new OpenCast($config);
$ocAgentsApi = $opencastApi->agentsApi;
...
- Direct instantiation:
use OpencastApi\Rest\OcRestClient;
use OpencastApi\Rest\OcAgentsApi;
$ocRestClient = new OcRestClient($config);
$ocAgentsApi = new OcAgentsApi($ocRestClient);
...
Consumable functions are listed below:
Returns a list of capture agents. More Detail
-
$limit
(int) (optional) The maximum number of results to return for a single request (Default value=0) -
$offset
(int) (optional) The index of the first result to return (Default value=0) -
Returns an array:
['code' => 200, 'body' => '{A (potentially empty) list of agents is returned}']
Returns a single capture agent. More Detail
-
$agentId
(string) The agent id -
Returns an array:
['code' => 200, 'body' => '{The agent is returned}']