Private API for VAF partners
This PHP package is automatically generated by the Swagger Codegen project:
- API version: 1.0.0
- Build package: io.swagger.codegen.v3.generators.php.PhpClientCodegen
PHP 5.5 and later
To install the bindings via Composer, add the following to composer.json
:
{
"repositories": [
{
"type": "git",
"url": "https://github.com/GIT_USER_ID/GIT_REPO_ID.git"
}
],
"require": {
"GIT_USER_ID/GIT_REPO_ID": "*@dev"
}
}
Then run composer install
Download the files and include autoload.php
:
require_once('/path/to/SwaggerClient-php/vendor/autoload.php');
To run the unit tests:
composer install
./vendor/bin/phpunit
Please follow the installation procedure and then run the following:
<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: apiAuth
$config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKey('X-Api-Key', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('X-Api-Key', 'Bearer');
$apiInstance = new Swagger\Client\Api\DefaultApi(
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
// This is optional, `GuzzleHttp\Client` will be used as default.
new GuzzleHttp\Client(),
$config
);
$id = "id_example"; // string | The ID of the asset
try {
$result = $apiInstance->assetsIdDownloadGet($id);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling DefaultApi->assetsIdDownloadGet: ', $e->getMessage(), PHP_EOL;
}
// Configure API key authorization: apiAuth
$config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKey('X-Api-Key', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('X-Api-Key', 'Bearer');
$apiInstance = new Swagger\Client\Api\DefaultApi(
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
// This is optional, `GuzzleHttp\Client` will be used as default.
new GuzzleHttp\Client(),
$config
);
$id = "id_example"; // string | The ID of the asset
try {
$result = $apiInstance->assetsIdGet($id);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling DefaultApi->assetsIdGet: ', $e->getMessage(), PHP_EOL;
}
// Configure API key authorization: apiAuth
$config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKey('X-Api-Key', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('X-Api-Key', 'Bearer');
$apiInstance = new Swagger\Client\Api\DefaultApi(
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
// This is optional, `GuzzleHttp\Client` will be used as default.
new GuzzleHttp\Client(),
$config
);
try {
$result = $apiInstance->filmsGet();
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling DefaultApi->filmsGet: ', $e->getMessage(), PHP_EOL;
}
// Configure API key authorization: apiAuth
$config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKey('X-Api-Key', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('X-Api-Key', 'Bearer');
$apiInstance = new Swagger\Client\Api\DefaultApi(
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
// This is optional, `GuzzleHttp\Client` will be used as default.
new GuzzleHttp\Client(),
$config
);
$id = "id_example"; // string | The ID of the film
try {
$result = $apiInstance->filmsIdGet($id);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling DefaultApi->filmsIdGet: ', $e->getMessage(), PHP_EOL;
}
// Configure API key authorization: apiAuth
$config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKey('X-Api-Key', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('X-Api-Key', 'Bearer');
$apiInstance = new Swagger\Client\Api\DefaultApi(
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
// This is optional, `GuzzleHttp\Client` will be used as default.
new GuzzleHttp\Client(),
$config
);
$id = "id_example"; // string | The ID of the film
try {
$result = $apiInstance->filmsIdPostersGet($id);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling DefaultApi->filmsIdPostersGet: ', $e->getMessage(), PHP_EOL;
}
// Configure API key authorization: apiAuth
$config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKey('X-Api-Key', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('X-Api-Key', 'Bearer');
$apiInstance = new Swagger\Client\Api\DefaultApi(
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
// This is optional, `GuzzleHttp\Client` will be used as default.
new GuzzleHttp\Client(),
$config
);
$id = "id_example"; // string | The ID of the film
try {
$result = $apiInstance->filmsIdStillsGet($id);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling DefaultApi->filmsIdStillsGet: ', $e->getMessage(), PHP_EOL;
}
// Configure API key authorization: apiAuth
$config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKey('X-Api-Key', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = Swagger\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('X-Api-Key', 'Bearer');
$apiInstance = new Swagger\Client\Api\DefaultApi(
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
// This is optional, `GuzzleHttp\Client` will be used as default.
new GuzzleHttp\Client(),
$config
);
try {
$result = $apiInstance->rootGet();
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling DefaultApi->rootGet: ', $e->getMessage(), PHP_EOL;
}
?>
All URIs are relative to http://api.vaf.be/api/v1
Class | Method | HTTP request | Description |
---|---|---|---|
DefaultApi | assetsIdDownloadGet | GET /assets/{id}/download | Returns binary data by asset id |
DefaultApi | assetsIdGet | GET /assets/{id} | Returns a asset by id |
DefaultApi | filmsGet | GET /films | Returns all films |
DefaultApi | filmsIdGet | GET /films/{id} | Returns a film by id |
DefaultApi | filmsIdPostersGet | GET /films/{id}/posters | Returns posters (assets) for a film |
DefaultApi | filmsIdStillsGet | GET /films/{id}/stills | Returns stills (assets) for a film |
DefaultApi | rootGet | GET / | Returns API version info |
- Type: API key
- API key parameter name: X-Api-Key
- Location: HTTP header