-
Notifications
You must be signed in to change notification settings - Fork 3
OcServices
FarbodZamani edited this page Jun 22, 2022
·
5 revisions
This class contains services.{json|xml}
REST API call to the /services
endpoint.
It is accessible under OpencastApi\Rest
namespace.
- In
OpencastApi\OpenCast
as its property with OpenCast properties naming convention:
use OpencastApi\OpenCast;
$opencastApi = new OpenCast($config);
$ocServices = $opencastApi->services;
...
- Direct instantiation:
use OpencastApi\Rest\OcRestClient;
use OpencastApi\Rest\OcServices;
$ocRestClient = new OcRestClient($config);
$ocServices = new OcServices($ocRestClient);
...
Consumable functions are liested below:
Returns a service registraton or list of available service registrations as object (JSON) by default or XML (text) on demand. More Detail
-
$serviceType
(string) (optional) The service type identifier. (from 1.1.1, this parameter became optional) -
$host
(string) (optional) The host, including the http(s) protocol. -
$format
(string) (optional) The output format (json or xml) of the response body. (Default value = 'json') -
Returns an array:
['code' => 200, 'body' => '{the available service, formatted as xml or json}']