Skip to content
This repository has been archived by the owner on May 17, 2021. It is now read-only.

Latest commit

 

History

History
634 lines (460 loc) · 22.2 KB

ResourcesApi.md

File metadata and controls

634 lines (460 loc) · 22.2 KB

OpenEuropa\SyncopePhpClient\ResourcesApi

All URIs are relative to http://syncope-vm.apache.org:9080/syncope/rest

Method HTTP request Description
check1 POST /resources/check Checks whether the connection to resource could be established.
create1 POST /resources Creates a new resource.
delete1 DELETE /resources/{key} Deletes the resource matching the given name.
list23 GET /resources Returns a list of all resources.
listConnObjects GET /resources/{key}/{anyTypeKey} Returns a paged list of connector objects from external resource, for the given type, matching page/size conditions.
read23 GET /resources/{key} Returns the resource with matching name.
readConnObject GET /resources/{key}/{anyTypeKey}/{anyKey} Returns connector object from the external resource, for the given type and key.
removeSyncToken DELETE /resources/{key}/{anyTypeKey} Removes the sync token value associated to the given any type from the given resource.
setLatestSyncToken POST /resources/{key}/{anyTypeKey} Queries the connector underlying the given resource for the latest sync token value associated to the given any type and stores the value internally, for later usage.
update1 PUT /resources/{key} Updates the resource matching the given name.

check1

check1($xSyncopeDomain, $resourceTO)

Checks whether the connection to resource could be established.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
$config = OpenEuropa\SyncopePhpClient\Configuration::getDefaultConfiguration()
              ->setUsername('YOUR_USERNAME')
              ->setPassword('YOUR_PASSWORD');

// Configure HTTP basic authorization: Bearer
$config = OpenEuropa\SyncopePhpClient\Configuration::getDefaultConfiguration()
              ->setUsername('YOUR_USERNAME')
              ->setPassword('YOUR_PASSWORD');


$apiInstance = new OpenEuropa\SyncopePhpClient\Api\ResourcesApi(
    // 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
);
$xSyncopeDomain = 'Master'; // string | resource to be checked
$resourceTO = new \OpenEuropa\SyncopePhpClient\Model\ResourceTO(); // \OpenEuropa\SyncopePhpClient\Model\ResourceTO | 

try {
    $apiInstance->check1($xSyncopeDomain, $resourceTO);
} catch (Exception $e) {
    echo 'Exception when calling ResourcesApi->check1: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
xSyncopeDomain string resource to be checked [default to 'Master']
resourceTO \OpenEuropa\SyncopePhpClient\Model\ResourceTO

Return type

void (empty response body)

Authorization

BasicAuthentication, Bearer

HTTP request headers

  • Content-Type: application/json, application/yaml, application/xml
  • Accept: application/json, application/yaml, application/xml

[Back to top] [Back to API list] [Back to Model list] [Back to README]

create1

create1($xSyncopeDomain, $resourceTO)

Creates a new resource.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
$config = OpenEuropa\SyncopePhpClient\Configuration::getDefaultConfiguration()
              ->setUsername('YOUR_USERNAME')
              ->setPassword('YOUR_PASSWORD');

// Configure HTTP basic authorization: Bearer
$config = OpenEuropa\SyncopePhpClient\Configuration::getDefaultConfiguration()
              ->setUsername('YOUR_USERNAME')
              ->setPassword('YOUR_PASSWORD');


$apiInstance = new OpenEuropa\SyncopePhpClient\Api\ResourcesApi(
    // 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
);
$xSyncopeDomain = 'Master'; // string | Resource to be created
$resourceTO = new \OpenEuropa\SyncopePhpClient\Model\ResourceTO(); // \OpenEuropa\SyncopePhpClient\Model\ResourceTO | 

try {
    $apiInstance->create1($xSyncopeDomain, $resourceTO);
} catch (Exception $e) {
    echo 'Exception when calling ResourcesApi->create1: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
xSyncopeDomain string Resource to be created [default to 'Master']
resourceTO \OpenEuropa\SyncopePhpClient\Model\ResourceTO

Return type

void (empty response body)

Authorization

BasicAuthentication, Bearer

HTTP request headers

  • Content-Type: application/json, application/yaml, application/xml
  • Accept: application/json, application/yaml, application/xml

[Back to top] [Back to API list] [Back to Model list] [Back to README]

delete1

delete1($key, $xSyncopeDomain)

Deletes the resource matching the given name.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
$config = OpenEuropa\SyncopePhpClient\Configuration::getDefaultConfiguration()
              ->setUsername('YOUR_USERNAME')
              ->setPassword('YOUR_PASSWORD');

// Configure HTTP basic authorization: Bearer
$config = OpenEuropa\SyncopePhpClient\Configuration::getDefaultConfiguration()
              ->setUsername('YOUR_USERNAME')
              ->setPassword('YOUR_PASSWORD');


$apiInstance = new OpenEuropa\SyncopePhpClient\Api\ResourcesApi(
    // 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
);
$key = 'key_example'; // string | name of resource to be deleted
$xSyncopeDomain = 'Master'; // string | resource to be checked

try {
    $apiInstance->delete1($key, $xSyncopeDomain);
} catch (Exception $e) {
    echo 'Exception when calling ResourcesApi->delete1: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
key string name of resource to be deleted
xSyncopeDomain string resource to be checked [default to 'Master']

Return type

void (empty response body)

Authorization

BasicAuthentication, Bearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, application/yaml, application/xml

[Back to top] [Back to API list] [Back to Model list] [Back to README]

list23

list23($xSyncopeDomain)

Returns a list of all resources.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
$config = OpenEuropa\SyncopePhpClient\Configuration::getDefaultConfiguration()
              ->setUsername('YOUR_USERNAME')
              ->setPassword('YOUR_PASSWORD');

// Configure HTTP basic authorization: Bearer
$config = OpenEuropa\SyncopePhpClient\Configuration::getDefaultConfiguration()
              ->setUsername('YOUR_USERNAME')
              ->setPassword('YOUR_PASSWORD');


$apiInstance = new OpenEuropa\SyncopePhpClient\Api\ResourcesApi(
    // 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
);
$xSyncopeDomain = 'Master'; // string | 

try {
    $apiInstance->list23($xSyncopeDomain);
} catch (Exception $e) {
    echo 'Exception when calling ResourcesApi->list23: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
xSyncopeDomain string [default to 'Master']

Return type

void (empty response body)

Authorization

BasicAuthentication, Bearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, application/yaml, application/xml

[Back to top] [Back to API list] [Back to Model list] [Back to README]

listConnObjects

listConnObjects($key, $anyTypeKey, $xSyncopeDomain, $size, $connIdPagedResultsCookie, $orderby)

Returns a paged list of connector objects from external resource, for the given type, matching page/size conditions.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
$config = OpenEuropa\SyncopePhpClient\Configuration::getDefaultConfiguration()
              ->setUsername('YOUR_USERNAME')
              ->setPassword('YOUR_PASSWORD');

// Configure HTTP basic authorization: Bearer
$config = OpenEuropa\SyncopePhpClient\Configuration::getDefaultConfiguration()
              ->setUsername('YOUR_USERNAME')
              ->setPassword('YOUR_PASSWORD');


$apiInstance = new OpenEuropa\SyncopePhpClient\Api\ResourcesApi(
    // 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
);
$key = 'key_example'; // string | name of resource to read connector object from
$anyTypeKey = 'anyTypeKey_example'; // string | any object type
$xSyncopeDomain = 'Master'; // string | 
$size = 25; // int | query conditions
$connIdPagedResultsCookie = 'connIdPagedResultsCookie_example'; // string | 
$orderby = 'orderby_example'; // string | 

try {
    $apiInstance->listConnObjects($key, $anyTypeKey, $xSyncopeDomain, $size, $connIdPagedResultsCookie, $orderby);
} catch (Exception $e) {
    echo 'Exception when calling ResourcesApi->listConnObjects: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
key string name of resource to read connector object from
anyTypeKey string any object type
xSyncopeDomain string [default to 'Master']
size int query conditions [optional] [default to 25]
connIdPagedResultsCookie string [optional]
orderby string [optional]

Return type

void (empty response body)

Authorization

BasicAuthentication, Bearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, application/yaml, application/xml

[Back to top] [Back to API list] [Back to Model list] [Back to README]

read23

read23($key, $xSyncopeDomain)

Returns the resource with matching name.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
$config = OpenEuropa\SyncopePhpClient\Configuration::getDefaultConfiguration()
              ->setUsername('YOUR_USERNAME')
              ->setPassword('YOUR_PASSWORD');

// Configure HTTP basic authorization: Bearer
$config = OpenEuropa\SyncopePhpClient\Configuration::getDefaultConfiguration()
              ->setUsername('YOUR_USERNAME')
              ->setPassword('YOUR_PASSWORD');


$apiInstance = new OpenEuropa\SyncopePhpClient\Api\ResourcesApi(
    // 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
);
$key = 'key_example'; // string | Name of resource to be read
$xSyncopeDomain = 'Master'; // string | 

try {
    $apiInstance->read23($key, $xSyncopeDomain);
} catch (Exception $e) {
    echo 'Exception when calling ResourcesApi->read23: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
key string Name of resource to be read
xSyncopeDomain string [default to 'Master']

Return type

void (empty response body)

Authorization

BasicAuthentication, Bearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, application/yaml, application/xml

[Back to top] [Back to API list] [Back to Model list] [Back to README]

readConnObject

readConnObject($key, $anyTypeKey, $anyKey, $xSyncopeDomain)

Returns connector object from the external resource, for the given type and key.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
$config = OpenEuropa\SyncopePhpClient\Configuration::getDefaultConfiguration()
              ->setUsername('YOUR_USERNAME')
              ->setPassword('YOUR_PASSWORD');

// Configure HTTP basic authorization: Bearer
$config = OpenEuropa\SyncopePhpClient\Configuration::getDefaultConfiguration()
              ->setUsername('YOUR_USERNAME')
              ->setPassword('YOUR_PASSWORD');


$apiInstance = new OpenEuropa\SyncopePhpClient\Api\ResourcesApi(
    // 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
);
$key = 'key_example'; // string | name of resource to read connector object from
$anyTypeKey = 'anyTypeKey_example'; // string | any object type
$anyKey = 'anyKey_example'; // string | any object key
$xSyncopeDomain = 'Master'; // string | 

try {
    $apiInstance->readConnObject($key, $anyTypeKey, $anyKey, $xSyncopeDomain);
} catch (Exception $e) {
    echo 'Exception when calling ResourcesApi->readConnObject: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
key string name of resource to read connector object from
anyTypeKey string any object type
anyKey string any object key
xSyncopeDomain string [default to 'Master']

Return type

void (empty response body)

Authorization

BasicAuthentication, Bearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, application/yaml, application/xml

[Back to top] [Back to API list] [Back to Model list] [Back to README]

removeSyncToken

removeSyncToken($key, $anyTypeKey, $xSyncopeDomain)

Removes the sync token value associated to the given any type from the given resource.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
$config = OpenEuropa\SyncopePhpClient\Configuration::getDefaultConfiguration()
              ->setUsername('YOUR_USERNAME')
              ->setPassword('YOUR_PASSWORD');

// Configure HTTP basic authorization: Bearer
$config = OpenEuropa\SyncopePhpClient\Configuration::getDefaultConfiguration()
              ->setUsername('YOUR_USERNAME')
              ->setPassword('YOUR_PASSWORD');


$apiInstance = new OpenEuropa\SyncopePhpClient\Api\ResourcesApi(
    // 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
);
$key = 'key_example'; // string | resource
$anyTypeKey = 'anyTypeKey_example'; // string | any type
$xSyncopeDomain = 'Master'; // string | name of resource to be deleted

try {
    $apiInstance->removeSyncToken($key, $anyTypeKey, $xSyncopeDomain);
} catch (Exception $e) {
    echo 'Exception when calling ResourcesApi->removeSyncToken: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
key string resource
anyTypeKey string any type
xSyncopeDomain string name of resource to be deleted [default to 'Master']

Return type

void (empty response body)

Authorization

BasicAuthentication, Bearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, application/yaml, application/xml

[Back to top] [Back to API list] [Back to Model list] [Back to README]

setLatestSyncToken

setLatestSyncToken($key, $anyTypeKey, $xSyncopeDomain)

Queries the connector underlying the given resource for the latest sync token value associated to the given any type and stores the value internally, for later usage.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
$config = OpenEuropa\SyncopePhpClient\Configuration::getDefaultConfiguration()
              ->setUsername('YOUR_USERNAME')
              ->setPassword('YOUR_PASSWORD');

// Configure HTTP basic authorization: Bearer
$config = OpenEuropa\SyncopePhpClient\Configuration::getDefaultConfiguration()
              ->setUsername('YOUR_USERNAME')
              ->setPassword('YOUR_PASSWORD');


$apiInstance = new OpenEuropa\SyncopePhpClient\Api\ResourcesApi(
    // 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
);
$key = 'key_example'; // string | resource
$anyTypeKey = 'anyTypeKey_example'; // string | any type
$xSyncopeDomain = 'Master'; // string | resource

try {
    $apiInstance->setLatestSyncToken($key, $anyTypeKey, $xSyncopeDomain);
} catch (Exception $e) {
    echo 'Exception when calling ResourcesApi->setLatestSyncToken: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
key string resource
anyTypeKey string any type
xSyncopeDomain string resource [default to 'Master']

Return type

void (empty response body)

Authorization

BasicAuthentication, Bearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json, application/yaml, application/xml

[Back to top] [Back to API list] [Back to Model list] [Back to README]

update1

update1($key, $xSyncopeDomain, $resourceTO)

Updates the resource matching the given name.

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
$config = OpenEuropa\SyncopePhpClient\Configuration::getDefaultConfiguration()
              ->setUsername('YOUR_USERNAME')
              ->setPassword('YOUR_PASSWORD');

// Configure HTTP basic authorization: Bearer
$config = OpenEuropa\SyncopePhpClient\Configuration::getDefaultConfiguration()
              ->setUsername('YOUR_USERNAME')
              ->setPassword('YOUR_PASSWORD');


$apiInstance = new OpenEuropa\SyncopePhpClient\Api\ResourcesApi(
    // 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
);
$key = 'key_example'; // string | Resource's key
$xSyncopeDomain = 'Master'; // string | resource
$resourceTO = new \OpenEuropa\SyncopePhpClient\Model\ResourceTO(); // \OpenEuropa\SyncopePhpClient\Model\ResourceTO | 

try {
    $apiInstance->update1($key, $xSyncopeDomain, $resourceTO);
} catch (Exception $e) {
    echo 'Exception when calling ResourcesApi->update1: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
key string Resource's key
xSyncopeDomain string resource [default to 'Master']
resourceTO \OpenEuropa\SyncopePhpClient\Model\ResourceTO

Return type

void (empty response body)

Authorization

BasicAuthentication, Bearer

HTTP request headers

  • Content-Type: application/json, application/yaml, application/xml
  • Accept: application/json, application/yaml, application/xml

[Back to top] [Back to API list] [Back to Model list] [Back to README]