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

Latest commit

 

History

History
380 lines (274 loc) · 12.8 KB

UserWorkflowApi.md

File metadata and controls

380 lines (274 loc) · 12.8 KB

OpenEuropa\SyncopePhpClient\UserWorkflowApi

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

Method HTTP request Description
claimForm POST /userworkflow/forms/{taskId}/claim Claims the form for the given task id.
executeTask POST /userworkflow/tasks/{taskId}/execute Executes workflow task for matching id.
getAvailableTasks GET /userworkflow/tasks/{userKey} Returns a list of available tasks for the given user key.
getFormForUser GET /userworkflow/forms/{userKey} Returns a list of available forms for the given user key.
getForms GET /userworkflow/forms Returns a list of all available workflow forms.
submitForm POST /userworkflow/forms Submits a workflow form.

claimForm

claimForm($taskId, $xSyncopeDomain)

Claims the form for the given task id.

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\UserWorkflowApi(
    // 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
);
$taskId = 'taskId_example'; // string | workflow task id
$xSyncopeDomain = 'Master'; // string | 

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

Parameters

Name Type Description Notes
taskId string workflow task id
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]

executeTask

executeTask($taskId, $xSyncopeDomain, $userTO)

Executes workflow task for matching id.

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\UserWorkflowApi(
    // 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
);
$taskId = 'taskId_example'; // string | workflow task id
$xSyncopeDomain = 'Master'; // string | argument to be passed to workflow task
$userTO = new \OpenEuropa\SyncopePhpClient\Model\UserTO(); // \OpenEuropa\SyncopePhpClient\Model\UserTO | 

try {
    $apiInstance->executeTask($taskId, $xSyncopeDomain, $userTO);
} catch (Exception $e) {
    echo 'Exception when calling UserWorkflowApi->executeTask: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
taskId string workflow task id
xSyncopeDomain string argument to be passed to workflow task [default to 'Master']
userTO \OpenEuropa\SyncopePhpClient\Model\UserTO

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]

getAvailableTasks

getAvailableTasks($userKey, $xSyncopeDomain)

Returns a list of available tasks for the given user 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\UserWorkflowApi(
    // 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
);
$userKey = 'userKey_example'; // string | user key
$xSyncopeDomain = 'Master'; // string | 

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

Parameters

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

Return type

void (empty response body)

Authorization

BasicAuthentication, Bearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: /

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

getFormForUser

getFormForUser($userKey, $xSyncopeDomain)

Returns a list of available forms for the given user 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\UserWorkflowApi(
    // 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
);
$userKey = 'userKey_example'; // string | user key
$xSyncopeDomain = 'Master'; // string | 

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

Parameters

Name Type Description Notes
userKey string user 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]

getForms

getForms($xSyncopeDomain, $page, $size, $orderby)

Returns a list of all available workflow forms.

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\UserWorkflowApi(
    // 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 | 
$page = 1; // int | query conditions
$size = 25; // int | 
$orderby = 'orderby_example'; // string | 

try {
    $apiInstance->getForms($xSyncopeDomain, $page, $size, $orderby);
} catch (Exception $e) {
    echo 'Exception when calling UserWorkflowApi->getForms: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
xSyncopeDomain string [default to 'Master']
page int query conditions [optional] [default to 1]
size int [optional] [default to 25]
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]

submitForm

submitForm($xSyncopeDomain, $workflowFormTO)

Submits a workflow form.

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\UserWorkflowApi(
    // 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 | workflow form.
$workflowFormTO = new \OpenEuropa\SyncopePhpClient\Model\WorkflowFormTO(); // \OpenEuropa\SyncopePhpClient\Model\WorkflowFormTO | 

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

Parameters

Name Type Description Notes
xSyncopeDomain string workflow form. [default to 'Master']
workflowFormTO \OpenEuropa\SyncopePhpClient\Model\WorkflowFormTO

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]