Workflow API for Neo

DataExport

/v1/export

Requests the export of workflow definitions, form definitions, workflow instances, and task instances. The file and data structures used are subject to change. Roles permitted to execute this operation: - Global roles: WorkflowTenantOperator


/v1/export

Usage

curl -X GET -H "Accept: application/zip" -H "Content-Type: application/json" -H "Authorization: Basic [[basicHash]]" "https://sandbox.api.sap.com/workflow-service/rest/v1/export"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.DataExportApi;

import java.io.File;
import java.util.*;

public class DataExportApiExample {

    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure HTTP basic authorization: BasicAuthentication
        HttpBasicAuth BasicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("BasicAuthentication");
        BasicAuthentication.setUsername("YOUR USERNAME");
        BasicAuthentication.setPassword("YOUR PASSWORD");

        // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
        OAuth Oauth2_AuthorizationCode = (OAuth) defaultClient.getAuthentication("Oauth2_AuthorizationCode");
        Oauth2_AuthorizationCode.setAccessToken("YOUR ACCESS TOKEN");

        // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
        OAuth Oauth2_ClientCredentials = (OAuth) defaultClient.getAuthentication("Oauth2_ClientCredentials");
        Oauth2_ClientCredentials.setAccessToken("YOUR ACCESS TOKEN");

        DataExportApi apiInstance = new DataExportApi();
        try {
            apiInstance.v1ExportGet();
        } catch (ApiException e) {
            System.err.println("Exception when calling DataExportApi#v1ExportGet");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.DataExportApi;

public class DataExportApiExample {

    public static void main(String[] args) {
        DataExportApi apiInstance = new DataExportApi();
        try {
            apiInstance.v1ExportGet();
        } catch (ApiException e) {
            System.err.println("Exception when calling DataExportApi#v1ExportGet");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];
// Configure HTTP basic authorization (authentication scheme: BasicAuthentication)
[apiConfig setUsername:@"YOUR_USERNAME"];
[apiConfig setPassword:@"YOUR_PASSWORD"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_AuthorizationCode)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_ClientCredentials)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];


DataExportApi *apiInstance = [[DataExportApi alloc] init];

// Data Export
[apiInstance v1ExportGetWithCompletionHandler: 
              ^(NSError* error) {
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var WorkflowApiForNeo = require('workflow_api_for_neo');
var defaultClient = WorkflowApiForNeo.ApiClient.instance;

// Configure HTTP basic authorization: BasicAuthentication
var BasicAuthentication = defaultClient.authentications['BasicAuthentication'];
BasicAuthentication.username = 'YOUR USERNAME'
BasicAuthentication.password = 'YOUR PASSWORD'

// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
var Oauth2_AuthorizationCode = defaultClient.authentications['Oauth2_AuthorizationCode'];
Oauth2_AuthorizationCode.accessToken = "YOUR ACCESS TOKEN"

// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
var Oauth2_ClientCredentials = defaultClient.authentications['Oauth2_ClientCredentials'];
Oauth2_ClientCredentials.accessToken = "YOUR ACCESS TOKEN"

var api = new WorkflowApiForNeo.DataExportApi()

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.v1ExportGet(callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class v1ExportGetExample
    {
        public void main()
        {
            
            // Configure HTTP basic authorization: BasicAuthentication
            Configuration.Default.Username = "YOUR_USERNAME";
            Configuration.Default.Password = "YOUR_PASSWORD";
            // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
            // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            var apiInstance = new DataExportApi();

            try
            {
                // Data Export
                apiInstance.v1ExportGet();
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling DataExportApi.v1ExportGet: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
Swagger\Client\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Swagger\Client\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Swagger\Client\Api\DataExportApi();

try {
    $api_instance->v1ExportGet();
} catch (Exception $e) {
    echo 'Exception when calling DataExportApi->v1ExportGet: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::DataExportApi;

# Configure HTTP basic authorization: BasicAuthentication
$WWW::SwaggerClient::Configuration::username = 'YOUR_USERNAME';
$WWW::SwaggerClient::Configuration::password = 'YOUR_PASSWORD';
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

my $api_instance = WWW::SwaggerClient::DataExportApi->new();

eval { 
    $api_instance->v1ExportGet();
};
if ($@) {
    warn "Exception when calling DataExportApi->v1ExportGet: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# Configure HTTP basic authorization: BasicAuthentication
swagger_client.configuration.username = 'YOUR_USERNAME'
swagger_client.configuration.password = 'YOUR_PASSWORD'
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# create an instance of the API class
api_instance = swagger_client.DataExportApi()

try: 
    # Data Export
    api_instance.v1ExportGet()
except ApiException as e:
    print("Exception when calling DataExportApi->v1ExportGet: %s\n" % e)

Parameters

Responses

Status: 200 - Returns all data related to workflow instances and task instances as well as the latest version of all workflow definitions and form definitions as a .zip-file. The exported file and data structures are subject to change. For more information, see the product documentation at: https://help.sap.com/viewer/f85276c5069a429fa37d1cd352785c25/Cloud/en-US/5df7521ad6f74a24b84ab448fb58c66b.html.

Status: 403 - Access forbidden. You do not have the required permissions to access the resource.

{error={message=User does not have sufficient privileges.}}

Status: 429 - You cannot run concurrent requests of this type for the current account. Please retry later.

Status: 500 - Internal server error. The operation you requested led to an error during execution.

{error={code=bpm.workflowruntime.rest.internal.server.error, message=Internal server error, logId=f29a5719-3342-4a4a-8a3d-5ddd5253159e}}

Status: 503 - The limit of concurrent requests of this type has been exceeded. Please retry later.


Forms

/v1/forms/{definitionId}

Undeploys all versions of an existing form. Roles permitted to execute this operation: - Global roles: WorkflowTenantOperator


/v1/forms/{definitionId}

Usage

curl -X DELETE -H "Accept: application/json" -H "Content-Type: application/json" -H "Authorization: Basic [[basicHash]]" "https://sandbox.api.sap.com/workflow-service/rest/v1/forms/{definitionId}"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.FormsApi;

import java.io.File;
import java.util.*;

public class FormsApiExample {

    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure HTTP basic authorization: BasicAuthentication
        HttpBasicAuth BasicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("BasicAuthentication");
        BasicAuthentication.setUsername("YOUR USERNAME");
        BasicAuthentication.setPassword("YOUR PASSWORD");

        // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
        OAuth Oauth2_AuthorizationCode = (OAuth) defaultClient.getAuthentication("Oauth2_AuthorizationCode");
        Oauth2_AuthorizationCode.setAccessToken("YOUR ACCESS TOKEN");

        // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
        OAuth Oauth2_ClientCredentials = (OAuth) defaultClient.getAuthentication("Oauth2_ClientCredentials");
        Oauth2_ClientCredentials.setAccessToken("YOUR ACCESS TOKEN");

        FormsApi apiInstance = new FormsApi();
        String formId = formId_example; // String | The ID of the form you want to undeploy. The ID is at most 255 characters long.
        String xCSRFToken = xCSRFToken_example; // String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.
        try {
            apiInstance.v1FormsDefinitionIdDelete(formId, xCSRFToken);
        } catch (ApiException e) {
            System.err.println("Exception when calling FormsApi#v1FormsDefinitionIdDelete");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.FormsApi;

public class FormsApiExample {

    public static void main(String[] args) {
        FormsApi apiInstance = new FormsApi();
        String formId = formId_example; // String | The ID of the form you want to undeploy. The ID is at most 255 characters long.
        String xCSRFToken = xCSRFToken_example; // String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.
        try {
            apiInstance.v1FormsDefinitionIdDelete(formId, xCSRFToken);
        } catch (ApiException e) {
            System.err.println("Exception when calling FormsApi#v1FormsDefinitionIdDelete");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];
// Configure HTTP basic authorization (authentication scheme: BasicAuthentication)
[apiConfig setUsername:@"YOUR_USERNAME"];
[apiConfig setPassword:@"YOUR_PASSWORD"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_AuthorizationCode)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_ClientCredentials)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

String *formId = formId_example; // The ID of the form you want to undeploy. The ID is at most 255 characters long.
String *xCSRFToken = xCSRFToken_example; // The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.

FormsApi *apiInstance = [[FormsApi alloc] init];

// Delete a form.
[apiInstance v1FormsDefinitionIdDeleteWith:formId
    xCSRFToken:xCSRFToken
              completionHandler: ^(NSError* error) {
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var WorkflowApiForNeo = require('workflow_api_for_neo');
var defaultClient = WorkflowApiForNeo.ApiClient.instance;

// Configure HTTP basic authorization: BasicAuthentication
var BasicAuthentication = defaultClient.authentications['BasicAuthentication'];
BasicAuthentication.username = 'YOUR USERNAME'
BasicAuthentication.password = 'YOUR PASSWORD'

// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
var Oauth2_AuthorizationCode = defaultClient.authentications['Oauth2_AuthorizationCode'];
Oauth2_AuthorizationCode.accessToken = "YOUR ACCESS TOKEN"

// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
var Oauth2_ClientCredentials = defaultClient.authentications['Oauth2_ClientCredentials'];
Oauth2_ClientCredentials.accessToken = "YOUR ACCESS TOKEN"

var api = new WorkflowApiForNeo.FormsApi()

var formId = formId_example; // {String} The ID of the form you want to undeploy. The ID is at most 255 characters long.

var xCSRFToken = xCSRFToken_example; // {String} The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.v1FormsDefinitionIdDelete(formId, xCSRFToken, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class v1FormsDefinitionIdDeleteExample
    {
        public void main()
        {
            
            // Configure HTTP basic authorization: BasicAuthentication
            Configuration.Default.Username = "YOUR_USERNAME";
            Configuration.Default.Password = "YOUR_PASSWORD";
            // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
            // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            var apiInstance = new FormsApi();
            var formId = formId_example;  // String | The ID of the form you want to undeploy. The ID is at most 255 characters long.
            var xCSRFToken = xCSRFToken_example;  // String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.

            try
            {
                // Delete a form.
                apiInstance.v1FormsDefinitionIdDelete(formId, xCSRFToken);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling FormsApi.v1FormsDefinitionIdDelete: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
Swagger\Client\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Swagger\Client\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Swagger\Client\Api\FormsApi();
$formId = formId_example; // String | The ID of the form you want to undeploy. The ID is at most 255 characters long.
$xCSRFToken = xCSRFToken_example; // String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.

try {
    $api_instance->v1FormsDefinitionIdDelete($formId, $xCSRFToken);
} catch (Exception $e) {
    echo 'Exception when calling FormsApi->v1FormsDefinitionIdDelete: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::FormsApi;

# Configure HTTP basic authorization: BasicAuthentication
$WWW::SwaggerClient::Configuration::username = 'YOUR_USERNAME';
$WWW::SwaggerClient::Configuration::password = 'YOUR_PASSWORD';
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

my $api_instance = WWW::SwaggerClient::FormsApi->new();
my $formId = formId_example; # String | The ID of the form you want to undeploy. The ID is at most 255 characters long.
my $xCSRFToken = xCSRFToken_example; # String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.

eval { 
    $api_instance->v1FormsDefinitionIdDelete(formId => $formId, xCSRFToken => $xCSRFToken);
};
if ($@) {
    warn "Exception when calling FormsApi->v1FormsDefinitionIdDelete: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# Configure HTTP basic authorization: BasicAuthentication
swagger_client.configuration.username = 'YOUR_USERNAME'
swagger_client.configuration.password = 'YOUR_PASSWORD'
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# create an instance of the API class
api_instance = swagger_client.FormsApi()
formId = formId_example # String | The ID of the form you want to undeploy. The ID is at most 255 characters long.
xCSRFToken = xCSRFToken_example # String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.

try: 
    # Delete a form.
    api_instance.v1FormsDefinitionIdDelete(formId, xCSRFToken)
except ApiException as e:
    print("Exception when calling FormsApi->v1FormsDefinitionIdDelete: %s\n" % e)

Parameters

Path parameters
Name Description
formId*
Header parameters
Name Description
X-CSRF-Token*

Responses

Status: 204 - The request was successful and the form definition was deleted.

Status: 403 - Access forbidden. You do not have the required permissions to access the resource.

{error={message=User does not have sufficient privileges.}}

Status: 404 - Form definition not found. Either the payload did not contain a definitionId property or the specified ID was incorrect.

{error={code=bpm.formruntime.definition.not.found, message=Form definition not found, logId=1c4daaf5-eb3f-4ff5-8b13-aa32a47bb07d}}

Status: 429 - Too many requests. You've reached the usage limits that are configured for your tenant. Reduce the number of requests.

Status: 500 - Internal server error. The operation you requested led to an error during execution.

{error={code=bpm.workflowruntime.rest.internal.server.error, message=Internal server error, logId=f29a5719-3342-4a4a-8a3d-5ddd5253159e}}

/v1/forms/{formId}/versions/{versionNumber}/model

Retrieves the model of the specified version of the specified form definition. Roles permitted to execute this operation: - Global roles: WorkflowViewer, WorkflowAdmin, WorkflowDeveloper


/v1/forms/{formId}/versions/{versionNumber}/model

Usage

curl -X GET -H "Accept: application/json" -H "Content-Type: application/json" -H "Authorization: Basic [[basicHash]]" "https://sandbox.api.sap.com/workflow-service/rest/v1/forms/{formId}/versions/{versionNumber}/model"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.FormsApi;

import java.io.File;
import java.util.*;

public class FormsApiExample {

    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure HTTP basic authorization: BasicAuthentication
        HttpBasicAuth BasicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("BasicAuthentication");
        BasicAuthentication.setUsername("YOUR USERNAME");
        BasicAuthentication.setPassword("YOUR PASSWORD");

        // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
        OAuth Oauth2_AuthorizationCode = (OAuth) defaultClient.getAuthentication("Oauth2_AuthorizationCode");
        Oauth2_AuthorizationCode.setAccessToken("YOUR ACCESS TOKEN");

        // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
        OAuth Oauth2_ClientCredentials = (OAuth) defaultClient.getAuthentication("Oauth2_ClientCredentials");
        Oauth2_ClientCredentials.setAccessToken("YOUR ACCESS TOKEN");

        FormsApi apiInstance = new FormsApi();
        String formId = formId_example; // String | The form ID for which the model should be retrieved. The form definition ID is at most 255 characters long.
        String versionNumber = versionNumber_example; // String | The version number for which the model should be retrieved. The version number consists of 1 - 10 digits.
        try {
            inline_response_200 result = apiInstance.v1FormsFormIdVersionsVersionNumberModelGet(formId, versionNumber);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling FormsApi#v1FormsFormIdVersionsVersionNumberModelGet");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.FormsApi;

public class FormsApiExample {

    public static void main(String[] args) {
        FormsApi apiInstance = new FormsApi();
        String formId = formId_example; // String | The form ID for which the model should be retrieved. The form definition ID is at most 255 characters long.
        String versionNumber = versionNumber_example; // String | The version number for which the model should be retrieved. The version number consists of 1 - 10 digits.
        try {
            inline_response_200 result = apiInstance.v1FormsFormIdVersionsVersionNumberModelGet(formId, versionNumber);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling FormsApi#v1FormsFormIdVersionsVersionNumberModelGet");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];
// Configure HTTP basic authorization (authentication scheme: BasicAuthentication)
[apiConfig setUsername:@"YOUR_USERNAME"];
[apiConfig setPassword:@"YOUR_PASSWORD"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_AuthorizationCode)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_ClientCredentials)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

String *formId = formId_example; // The form ID for which the model should be retrieved. The form definition ID is at most 255 characters long.
String *versionNumber = versionNumber_example; // The version number for which the model should be retrieved. The version number consists of 1 - 10 digits.

FormsApi *apiInstance = [[FormsApi alloc] init];

// Retrieve form model by ID and version number.
[apiInstance v1FormsFormIdVersionsVersionNumberModelGetWith:formId
    versionNumber:versionNumber
              completionHandler: ^(inline_response_200 output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var WorkflowApiForNeo = require('workflow_api_for_neo');
var defaultClient = WorkflowApiForNeo.ApiClient.instance;

// Configure HTTP basic authorization: BasicAuthentication
var BasicAuthentication = defaultClient.authentications['BasicAuthentication'];
BasicAuthentication.username = 'YOUR USERNAME'
BasicAuthentication.password = 'YOUR PASSWORD'

// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
var Oauth2_AuthorizationCode = defaultClient.authentications['Oauth2_AuthorizationCode'];
Oauth2_AuthorizationCode.accessToken = "YOUR ACCESS TOKEN"

// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
var Oauth2_ClientCredentials = defaultClient.authentications['Oauth2_ClientCredentials'];
Oauth2_ClientCredentials.accessToken = "YOUR ACCESS TOKEN"

var api = new WorkflowApiForNeo.FormsApi()

var formId = formId_example; // {String} The form ID for which the model should be retrieved. The form definition ID is at most 255 characters long.

var versionNumber = versionNumber_example; // {String} The version number for which the model should be retrieved. The version number consists of 1 - 10 digits.


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.v1FormsFormIdVersionsVersionNumberModelGet(formId, versionNumber, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class v1FormsFormIdVersionsVersionNumberModelGetExample
    {
        public void main()
        {
            
            // Configure HTTP basic authorization: BasicAuthentication
            Configuration.Default.Username = "YOUR_USERNAME";
            Configuration.Default.Password = "YOUR_PASSWORD";
            // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
            // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            var apiInstance = new FormsApi();
            var formId = formId_example;  // String | The form ID for which the model should be retrieved. The form definition ID is at most 255 characters long.
            var versionNumber = versionNumber_example;  // String | The version number for which the model should be retrieved. The version number consists of 1 - 10 digits.

            try
            {
                // Retrieve form model by ID and version number.
                inline_response_200 result = apiInstance.v1FormsFormIdVersionsVersionNumberModelGet(formId, versionNumber);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling FormsApi.v1FormsFormIdVersionsVersionNumberModelGet: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
Swagger\Client\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Swagger\Client\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Swagger\Client\Api\FormsApi();
$formId = formId_example; // String | The form ID for which the model should be retrieved. The form definition ID is at most 255 characters long.
$versionNumber = versionNumber_example; // String | The version number for which the model should be retrieved. The version number consists of 1 - 10 digits.

try {
    $result = $api_instance->v1FormsFormIdVersionsVersionNumberModelGet($formId, $versionNumber);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling FormsApi->v1FormsFormIdVersionsVersionNumberModelGet: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::FormsApi;

# Configure HTTP basic authorization: BasicAuthentication
$WWW::SwaggerClient::Configuration::username = 'YOUR_USERNAME';
$WWW::SwaggerClient::Configuration::password = 'YOUR_PASSWORD';
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

my $api_instance = WWW::SwaggerClient::FormsApi->new();
my $formId = formId_example; # String | The form ID for which the model should be retrieved. The form definition ID is at most 255 characters long.
my $versionNumber = versionNumber_example; # String | The version number for which the model should be retrieved. The version number consists of 1 - 10 digits.

eval { 
    my $result = $api_instance->v1FormsFormIdVersionsVersionNumberModelGet(formId => $formId, versionNumber => $versionNumber);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling FormsApi->v1FormsFormIdVersionsVersionNumberModelGet: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# Configure HTTP basic authorization: BasicAuthentication
swagger_client.configuration.username = 'YOUR_USERNAME'
swagger_client.configuration.password = 'YOUR_PASSWORD'
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# create an instance of the API class
api_instance = swagger_client.FormsApi()
formId = formId_example # String | The form ID for which the model should be retrieved. The form definition ID is at most 255 characters long.
versionNumber = versionNumber_example # String | The version number for which the model should be retrieved. The version number consists of 1 - 10 digits.

try: 
    # Retrieve form model by ID and version number.
    api_response = api_instance.v1FormsFormIdVersionsVersionNumberModelGet(formId, versionNumber)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling FormsApi->v1FormsFormIdVersionsVersionNumberModelGet: %s\n" % e)

Parameters

Path parameters
Name Description
formId*
versionNumber*

Responses

Status: 200 - The deployed form definition model.

{name=Expense Report Approval Form, id=com_sap_bpm_approve_travel_expense, revision=4, type=task, content=[{id=reportHeader, title=Overview, type=section, content=[{id=metadata, title=Report Data, type=subsection, content=[{id=reportName, type=string, value=${context.report.name}, label=Report Name, placeholder=Travel to...}, {id=reportId, type=string, value=${context.report.id}, label=Report ID, placeholder=A2E...}, {id=owner, type=string, value=${context.report.owner}, label=Owner, placeholder=Firstname Lastname}]}, {id=invoicedAmount, title=Invoice Amount, type=subsection, content=[{id=totalClaimedAmount, type=float, value=${context.report.totalClaimedAmount}, label=Total Claimed Amount, placeholder=1000.00}, {id=currencyCode, type=string, value=${context.report.currencyCode}, label=Currency Code, placeholder=EUR}, {id=includesVAT, type=boolean, value=${context.report.includesVAT}, label=VAT Included in Claimed Amount}, {id=numItems, type=integer, value=${context.report.numItems}, label=Total Number of Items, placeholder=2}]}]}, {id=invoiceDetails, title=Invoice Details, type=section, content=[{id=invoiceDate, type=date, value=${context.report.invoice.date}, label=Date of Invoice, placeholder=Must correspond to the date of the submitted paper invoice}, {id=invoiceTime, type=time, value=${context.report.invoice.time}, label=Time of Invoice, placeholder=Must correspond to the time of the submitted paper invoice}, {id=orderDateTime, type=datetime, value=${context.report.invoice.orderDatetime}, label=Date and Time of Purchase Order, placeholder=Look up using transaction /PO32}]}], decisions=[{id=accept, text=Accept, decisionType=positive}, {id=reject, text=Reject, decisionType=negative}, {id=neutral, text=Neutral}]}

Status: 403 - Access forbidden. You do not have the required permissions to access the resource.

{error={message=User does not have sufficient privileges.}}

Status: 404 - Either the specified form definition, the specified version within that definition, or the JSON model for that definition version was not found.

{error={code=bpm.formruntime.definition.not.found, message=Form definition not found, logId=381a4f5-eb3f-4c3a-89b0-ca32a47bb517}}

Status: 429 - Too many requests. You've reached the usage limits that are configured for your tenant. Reduce the number of requests.

Status: 500 - Internal server error. The operation you requested led to an error during execution.

{error={code=bpm.workflowruntime.rest.internal.server.error, message=Internal server error, logId=f29a5719-3342-4a4a-8a3d-5ddd5253159e}}

Jobs

/v1/jobs/{jobId}

Tracks the status of API requests, which the server executed asynchronously. Roles permitted to execute this operation: - Global roles: WorkflowTenantOperator


/v1/jobs/{jobId}

Usage

curl -X GET -H "Accept: application/json" -H "Content-Type: application/json" -H "Authorization: Basic [[basicHash]]" "https://sandbox.api.sap.com/workflow-service/rest/v1/jobs/{jobId}"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.JobsApi;

import java.io.File;
import java.util.*;

public class JobsApiExample {

    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure HTTP basic authorization: BasicAuthentication
        HttpBasicAuth BasicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("BasicAuthentication");
        BasicAuthentication.setUsername("YOUR USERNAME");
        BasicAuthentication.setPassword("YOUR PASSWORD");

        // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
        OAuth Oauth2_AuthorizationCode = (OAuth) defaultClient.getAuthentication("Oauth2_AuthorizationCode");
        Oauth2_AuthorizationCode.setAccessToken("YOUR ACCESS TOKEN");

        // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
        OAuth Oauth2_ClientCredentials = (OAuth) defaultClient.getAuthentication("Oauth2_ClientCredentials");
        Oauth2_ClientCredentials.setAccessToken("YOUR ACCESS TOKEN");

        JobsApi apiInstance = new JobsApi();
        String jobId = jobId_example; // String | The ID of the job for which you check the status.
Typically, the ID has been retrieved from another API request that was processed asynchronously.
The ID is at most 36 characters long.
        try {
            inline_response_200_1 result = apiInstance.v1JobsJobIdGet(jobId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling JobsApi#v1JobsJobIdGet");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.JobsApi;

public class JobsApiExample {

    public static void main(String[] args) {
        JobsApi apiInstance = new JobsApi();
        String jobId = jobId_example; // String | The ID of the job for which you check the status.
Typically, the ID has been retrieved from another API request that was processed asynchronously.
The ID is at most 36 characters long.
        try {
            inline_response_200_1 result = apiInstance.v1JobsJobIdGet(jobId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling JobsApi#v1JobsJobIdGet");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];
// Configure HTTP basic authorization (authentication scheme: BasicAuthentication)
[apiConfig setUsername:@"YOUR_USERNAME"];
[apiConfig setPassword:@"YOUR_PASSWORD"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_AuthorizationCode)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_ClientCredentials)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

String *jobId = jobId_example; // The ID of the job for which you check the status.
Typically, the ID has been retrieved from another API request that was processed asynchronously.
The ID is at most 36 characters long.

JobsApi *apiInstance = [[JobsApi alloc] init];

// Retrieve Job status
[apiInstance v1JobsJobIdGetWith:jobId
              completionHandler: ^(inline_response_200_1 output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var WorkflowApiForNeo = require('workflow_api_for_neo');
var defaultClient = WorkflowApiForNeo.ApiClient.instance;

// Configure HTTP basic authorization: BasicAuthentication
var BasicAuthentication = defaultClient.authentications['BasicAuthentication'];
BasicAuthentication.username = 'YOUR USERNAME'
BasicAuthentication.password = 'YOUR PASSWORD'

// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
var Oauth2_AuthorizationCode = defaultClient.authentications['Oauth2_AuthorizationCode'];
Oauth2_AuthorizationCode.accessToken = "YOUR ACCESS TOKEN"

// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
var Oauth2_ClientCredentials = defaultClient.authentications['Oauth2_ClientCredentials'];
Oauth2_ClientCredentials.accessToken = "YOUR ACCESS TOKEN"

var api = new WorkflowApiForNeo.JobsApi()

var jobId = jobId_example; // {String} The ID of the job for which you check the status.
Typically, the ID has been retrieved from another API request that was processed asynchronously.
The ID is at most 36 characters long.


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.v1JobsJobIdGet(jobId, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class v1JobsJobIdGetExample
    {
        public void main()
        {
            
            // Configure HTTP basic authorization: BasicAuthentication
            Configuration.Default.Username = "YOUR_USERNAME";
            Configuration.Default.Password = "YOUR_PASSWORD";
            // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
            // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            var apiInstance = new JobsApi();
            var jobId = jobId_example;  // String | The ID of the job for which you check the status.
Typically, the ID has been retrieved from another API request that was processed asynchronously.
The ID is at most 36 characters long.

            try
            {
                // Retrieve Job status
                inline_response_200_1 result = apiInstance.v1JobsJobIdGet(jobId);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling JobsApi.v1JobsJobIdGet: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
Swagger\Client\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Swagger\Client\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Swagger\Client\Api\JobsApi();
$jobId = jobId_example; // String | The ID of the job for which you check the status.
Typically, the ID has been retrieved from another API request that was processed asynchronously.
The ID is at most 36 characters long.

try {
    $result = $api_instance->v1JobsJobIdGet($jobId);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling JobsApi->v1JobsJobIdGet: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::JobsApi;

# Configure HTTP basic authorization: BasicAuthentication
$WWW::SwaggerClient::Configuration::username = 'YOUR_USERNAME';
$WWW::SwaggerClient::Configuration::password = 'YOUR_PASSWORD';
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

my $api_instance = WWW::SwaggerClient::JobsApi->new();
my $jobId = jobId_example; # String | The ID of the job for which you check the status.
Typically, the ID has been retrieved from another API request that was processed asynchronously.
The ID is at most 36 characters long.

eval { 
    my $result = $api_instance->v1JobsJobIdGet(jobId => $jobId);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling JobsApi->v1JobsJobIdGet: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# Configure HTTP basic authorization: BasicAuthentication
swagger_client.configuration.username = 'YOUR_USERNAME'
swagger_client.configuration.password = 'YOUR_PASSWORD'
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# create an instance of the API class
api_instance = swagger_client.JobsApi()
jobId = jobId_example # String | The ID of the job for which you check the status.
Typically, the ID has been retrieved from another API request that was processed asynchronously.
The ID is at most 36 characters long.

try: 
    # Retrieve Job status
    api_response = api_instance.v1JobsJobIdGet(jobId)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling JobsApi->v1JobsJobIdGet: %s\n" % e)

Parameters

Path parameters
Name Description
jobId*

Responses

Status: 200 - Returns the status of the job

{status=ERRONEOUS, details={instancesInitial=432, instancesLeft=89}, error={code=bpm.workflowruntime.scheduler.error, message=An unspecified error occurred. Contact support citing logId af07a8d9-f899-4ed8-abb2-7667bf2ae53d and provide steps to reproduce., logId=af07a8d9-f899-4ed8-abb2-7667bf2ae53d}}

Status: 404 - Job not found. You may have provided an incorrect job ID or the job may have already completed.

{error={code=bpm.workflowruntime.rest.job.not.found, message=Job not found, logId=dc68239e-3ad4-442a-8343-cc197f69d05f}}

Status: 429 - Too many requests. You've reached the usage limits that are configured for your tenant. Reduce the number of requests.


Messages

/v1/messages/

Sends a message to a set of workflow instances for consumption in intermediate message events. The message is identified by the name specified in the workflow model (request body parameter 'definitionId') and the ID of the workflow model (request body parameter 'workflowDefinitionId'). The message is consumed by the workflow instances that match the following criteria: * The business key specified in the request body matches the business key of the workflow instance. * The workflow instance is not in the SUSPENDED state. * The workflow instance currently waits at the intermediate message event referring to the specified message. Roles permitted to execute this operation: - Global roles: WorkflowMessageSender


/v1/messages/

Usage

curl -X POST -H "Accept: application/json" -H "Content-Type: application/json" -H "Authorization: Basic [[basicHash]]" "https://sandbox.api.sap.com/workflow-service/rest/v1/messages/"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.MessagesApi;

import java.io.File;
import java.util.*;

public class MessagesApiExample {

    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure HTTP basic authorization: BasicAuthentication
        HttpBasicAuth BasicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("BasicAuthentication");
        BasicAuthentication.setUsername("YOUR USERNAME");
        BasicAuthentication.setPassword("YOUR PASSWORD");

        // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
        OAuth Oauth2_AuthorizationCode = (OAuth) defaultClient.getAuthentication("Oauth2_AuthorizationCode");
        Oauth2_AuthorizationCode.setAccessToken("YOUR ACCESS TOKEN");

        // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
        OAuth Oauth2_ClientCredentials = (OAuth) defaultClient.getAuthentication("Oauth2_ClientCredentials");
        Oauth2_ClientCredentials.setAccessToken("YOUR ACCESS TOKEN");

        MessagesApi apiInstance = new MessagesApi();
        Messages_POST body = ; // Messages_POST | Specify the request body according to the given schema.
The length of the request body is limited to ensure optimal operation of the service.
        String xCSRFToken = xCSRFToken_example; // String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.
        try {
            WorkflowInstanceIdList result = apiInstance.v1MessagesPost(body, xCSRFToken);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling MessagesApi#v1MessagesPost");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.MessagesApi;

public class MessagesApiExample {

    public static void main(String[] args) {
        MessagesApi apiInstance = new MessagesApi();
        Messages_POST body = ; // Messages_POST | Specify the request body according to the given schema.
The length of the request body is limited to ensure optimal operation of the service.
        String xCSRFToken = xCSRFToken_example; // String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.
        try {
            WorkflowInstanceIdList result = apiInstance.v1MessagesPost(body, xCSRFToken);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling MessagesApi#v1MessagesPost");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];
// Configure HTTP basic authorization (authentication scheme: BasicAuthentication)
[apiConfig setUsername:@"YOUR_USERNAME"];
[apiConfig setPassword:@"YOUR_PASSWORD"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_AuthorizationCode)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_ClientCredentials)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

Messages_POST *body = ; // Specify the request body according to the given schema.
The length of the request body is limited to ensure optimal operation of the service.
String *xCSRFToken = xCSRFToken_example; // The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.

MessagesApi *apiInstance = [[MessagesApi alloc] init];

// Send message
[apiInstance v1MessagesPostWith:body
    xCSRFToken:xCSRFToken
              completionHandler: ^(WorkflowInstanceIdList output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var WorkflowApiForNeo = require('workflow_api_for_neo');
var defaultClient = WorkflowApiForNeo.ApiClient.instance;

// Configure HTTP basic authorization: BasicAuthentication
var BasicAuthentication = defaultClient.authentications['BasicAuthentication'];
BasicAuthentication.username = 'YOUR USERNAME'
BasicAuthentication.password = 'YOUR PASSWORD'

// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
var Oauth2_AuthorizationCode = defaultClient.authentications['Oauth2_AuthorizationCode'];
Oauth2_AuthorizationCode.accessToken = "YOUR ACCESS TOKEN"

// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
var Oauth2_ClientCredentials = defaultClient.authentications['Oauth2_ClientCredentials'];
Oauth2_ClientCredentials.accessToken = "YOUR ACCESS TOKEN"

var api = new WorkflowApiForNeo.MessagesApi()

var body = ; // {Messages_POST} Specify the request body according to the given schema.
The length of the request body is limited to ensure optimal operation of the service.

var xCSRFToken = xCSRFToken_example; // {String} The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.v1MessagesPost(body, xCSRFToken, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class v1MessagesPostExample
    {
        public void main()
        {
            
            // Configure HTTP basic authorization: BasicAuthentication
            Configuration.Default.Username = "YOUR_USERNAME";
            Configuration.Default.Password = "YOUR_PASSWORD";
            // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
            // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            var apiInstance = new MessagesApi();
            var body = new Messages_POST(); // Messages_POST | Specify the request body according to the given schema.
The length of the request body is limited to ensure optimal operation of the service.
            var xCSRFToken = xCSRFToken_example;  // String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.

            try
            {
                // Send message
                WorkflowInstanceIdList result = apiInstance.v1MessagesPost(body, xCSRFToken);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling MessagesApi.v1MessagesPost: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
Swagger\Client\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Swagger\Client\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Swagger\Client\Api\MessagesApi();
$body = ; // Messages_POST | Specify the request body according to the given schema.
The length of the request body is limited to ensure optimal operation of the service.
$xCSRFToken = xCSRFToken_example; // String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.

try {
    $result = $api_instance->v1MessagesPost($body, $xCSRFToken);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling MessagesApi->v1MessagesPost: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::MessagesApi;

# Configure HTTP basic authorization: BasicAuthentication
$WWW::SwaggerClient::Configuration::username = 'YOUR_USERNAME';
$WWW::SwaggerClient::Configuration::password = 'YOUR_PASSWORD';
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

my $api_instance = WWW::SwaggerClient::MessagesApi->new();
my $body = WWW::SwaggerClient::Object::Messages_POST->new(); # Messages_POST | Specify the request body according to the given schema.
The length of the request body is limited to ensure optimal operation of the service.
my $xCSRFToken = xCSRFToken_example; # String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.

eval { 
    my $result = $api_instance->v1MessagesPost(body => $body, xCSRFToken => $xCSRFToken);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling MessagesApi->v1MessagesPost: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# Configure HTTP basic authorization: BasicAuthentication
swagger_client.configuration.username = 'YOUR_USERNAME'
swagger_client.configuration.password = 'YOUR_PASSWORD'
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# create an instance of the API class
api_instance = swagger_client.MessagesApi()
body =  # Messages_POST | Specify the request body according to the given schema.
The length of the request body is limited to ensure optimal operation of the service.
xCSRFToken = xCSRFToken_example # String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.

try: 
    # Send message
    api_response = api_instance.v1MessagesPost(body, xCSRFToken)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling MessagesApi->v1MessagesPost: %s\n" % e)

Parameters

Header parameters
Name Description
X-CSRF-Token*
Body parameters
Name Description
body *

Specify the request body according to the given schema. The length of the request body is limited to ensure optimal operation of the service.

Responses

Status: 200 - Returns a list of workflow instance IDs that consumed the message.

[{id=c4f2-4066-0ba1-ee8393107bc2}, {id=fef2-5066-1ba1-fe8393107ef5}]

Status: 403 - Access forbidden. You do not have the required permissions to access the resource.

{error={message=User does not have sufficient privileges.}}

Status: 422 - The message was not consumed by the intermediate message event. Please see the messages API to verify that your message meets the requirements for successful consumption.

{error={code=bpm.workflowruntime.rest.message.no.match, message=No matching workflow instance found for message, logId=dc68239e-3ad4-442a-8343-cc197f69d05f}}

Status: 429 - Too many requests. You've reached the usage limits that are configured for your tenant. Reduce the number of requests.

Status: 500 - Internal server error. The operation you requested led to an error during execution.

{error={code=bpm.workflowruntime.rest.internal.server.error, message=Internal server error, logId=f29a5719-3342-4a4a-8a3d-5ddd5253159e}}

Purge

/v1/purge

Completely erases all workflow definitions, all workflow instances, and all form definitions. Roles permitted to execute this operation: - Global roles: WorkflowTenantOperator


/v1/purge

Usage

curl -X POST -H "Accept: application/json" -H "Content-Type: application/json" -H "Authorization: Basic [[basicHash]]" "https://sandbox.api.sap.com/workflow-service/rest/v1/purge"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.PurgeApi;

import java.io.File;
import java.util.*;

public class PurgeApiExample {

    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure HTTP basic authorization: BasicAuthentication
        HttpBasicAuth BasicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("BasicAuthentication");
        BasicAuthentication.setUsername("YOUR USERNAME");
        BasicAuthentication.setPassword("YOUR PASSWORD");

        // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
        OAuth Oauth2_AuthorizationCode = (OAuth) defaultClient.getAuthentication("Oauth2_AuthorizationCode");
        Oauth2_AuthorizationCode.setAccessToken("YOUR ACCESS TOKEN");

        // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
        OAuth Oauth2_ClientCredentials = (OAuth) defaultClient.getAuthentication("Oauth2_ClientCredentials");
        Oauth2_ClientCredentials.setAccessToken("YOUR ACCESS TOKEN");

        PurgeApi apiInstance = new PurgeApi();
        String xCSRFToken = xCSRFToken_example; // String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.
        try {
            apiInstance.v1PurgePost(xCSRFToken);
        } catch (ApiException e) {
            System.err.println("Exception when calling PurgeApi#v1PurgePost");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.PurgeApi;

public class PurgeApiExample {

    public static void main(String[] args) {
        PurgeApi apiInstance = new PurgeApi();
        String xCSRFToken = xCSRFToken_example; // String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.
        try {
            apiInstance.v1PurgePost(xCSRFToken);
        } catch (ApiException e) {
            System.err.println("Exception when calling PurgeApi#v1PurgePost");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];
// Configure HTTP basic authorization (authentication scheme: BasicAuthentication)
[apiConfig setUsername:@"YOUR_USERNAME"];
[apiConfig setPassword:@"YOUR_PASSWORD"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_AuthorizationCode)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_ClientCredentials)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

String *xCSRFToken = xCSRFToken_example; // The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.

PurgeApi *apiInstance = [[PurgeApi alloc] init];

// Purge instances and definitions
[apiInstance v1PurgePostWith:xCSRFToken
              completionHandler: ^(NSError* error) {
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var WorkflowApiForNeo = require('workflow_api_for_neo');
var defaultClient = WorkflowApiForNeo.ApiClient.instance;

// Configure HTTP basic authorization: BasicAuthentication
var BasicAuthentication = defaultClient.authentications['BasicAuthentication'];
BasicAuthentication.username = 'YOUR USERNAME'
BasicAuthentication.password = 'YOUR PASSWORD'

// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
var Oauth2_AuthorizationCode = defaultClient.authentications['Oauth2_AuthorizationCode'];
Oauth2_AuthorizationCode.accessToken = "YOUR ACCESS TOKEN"

// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
var Oauth2_ClientCredentials = defaultClient.authentications['Oauth2_ClientCredentials'];
Oauth2_ClientCredentials.accessToken = "YOUR ACCESS TOKEN"

var api = new WorkflowApiForNeo.PurgeApi()

var xCSRFToken = xCSRFToken_example; // {String} The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.v1PurgePost(xCSRFToken, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class v1PurgePostExample
    {
        public void main()
        {
            
            // Configure HTTP basic authorization: BasicAuthentication
            Configuration.Default.Username = "YOUR_USERNAME";
            Configuration.Default.Password = "YOUR_PASSWORD";
            // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
            // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            var apiInstance = new PurgeApi();
            var xCSRFToken = xCSRFToken_example;  // String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.

            try
            {
                // Purge instances and definitions
                apiInstance.v1PurgePost(xCSRFToken);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling PurgeApi.v1PurgePost: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
Swagger\Client\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Swagger\Client\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Swagger\Client\Api\PurgeApi();
$xCSRFToken = xCSRFToken_example; // String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.

try {
    $api_instance->v1PurgePost($xCSRFToken);
} catch (Exception $e) {
    echo 'Exception when calling PurgeApi->v1PurgePost: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::PurgeApi;

# Configure HTTP basic authorization: BasicAuthentication
$WWW::SwaggerClient::Configuration::username = 'YOUR_USERNAME';
$WWW::SwaggerClient::Configuration::password = 'YOUR_PASSWORD';
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

my $api_instance = WWW::SwaggerClient::PurgeApi->new();
my $xCSRFToken = xCSRFToken_example; # String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.

eval { 
    $api_instance->v1PurgePost(xCSRFToken => $xCSRFToken);
};
if ($@) {
    warn "Exception when calling PurgeApi->v1PurgePost: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# Configure HTTP basic authorization: BasicAuthentication
swagger_client.configuration.username = 'YOUR_USERNAME'
swagger_client.configuration.password = 'YOUR_PASSWORD'
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# create an instance of the API class
api_instance = swagger_client.PurgeApi()
xCSRFToken = xCSRFToken_example # String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.

try: 
    # Purge instances and definitions
    api_instance.v1PurgePost(xCSRFToken)
except ApiException as e:
    print("Exception when calling PurgeApi->v1PurgePost: %s\n" % e)

Parameters

Header parameters
Name Description
X-CSRF-Token*

Responses

Status: 202 - The request is successful and the purge operation will be performed asynchronously. The response will include the header 'Location' that points to a dedicated resource. You can use this resource to track the status of the purge operation.

Name Type Format Description
Location String Relative URL that points to a job resource. Use this resource to track the status of the purge operation.

Status: 303 - A purge operation is already running. The response will include the header 'Location' that points to a job resource which you can use to track the status of the purge operation. Depending on your web client you may be automatically redirected to this resource and receive the status of the purge operation as the result of your request.

Name Type Format Description
Location String Relative URL that points to a job resource. Using this resource you can track the status of the purge operation.

Status: 403 - Access forbidden. You do not have the required permissions to access the resource.

{error={message=User does not have sufficient privileges.}}

Status: 429 - Too many requests. You've reached the usage limits that are configured for your tenant. Reduce the number of requests.

Status: 500 - Internal server error. The operation you requested led to an error during execution.

{error={code=bpm.workflowruntime.rest.internal.server.error, message=Internal server error, logId=f29a5719-3342-4a4a-8a3d-5ddd5253159e}}

TaskDefinitions

/v1/task-definitions

Retrieves task definitions by query parameters. A task definition is identified by the ID of the respective activity within a workflow definition (for example, usertask1) and the workflow definition ID. The workflow definition ID is version independent. That means, this API assumes that task definitions are semantically the same if they span several workflow versions and therefore have the same identifier. The latest workflow definition version is expected to contain the leading property values of the task definition. At the moment, filtering is limited to the $skip and $top parameters for paging through the available task definitions. The returned task definitions are sorted in descending order of their creation time. Roles permitted to execute this operation: - Global roles: WorkflowViewer, WorkflowAdmin


/v1/task-definitions

Usage

curl -X GET -H "Accept: application/json" -H "Content-Type: application/json" -H "Authorization: Basic [[basicHash]]" "https://sandbox.api.sap.com/workflow-service/rest/v1/task-definitions?$skip=&$top=&$inlinecount=&$expand="
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.TaskDefinitionsApi;

import java.io.File;
import java.util.*;

public class TaskDefinitionsApiExample {

    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure HTTP basic authorization: BasicAuthentication
        HttpBasicAuth BasicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("BasicAuthentication");
        BasicAuthentication.setUsername("YOUR USERNAME");
        BasicAuthentication.setPassword("YOUR PASSWORD");

        // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
        OAuth Oauth2_AuthorizationCode = (OAuth) defaultClient.getAuthentication("Oauth2_AuthorizationCode");
        Oauth2_AuthorizationCode.setAccessToken("YOUR ACCESS TOKEN");

        // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
        OAuth Oauth2_ClientCredentials = (OAuth) defaultClient.getAuthentication("Oauth2_ClientCredentials");
        Oauth2_ClientCredentials.setAccessToken("YOUR ACCESS TOKEN");

        TaskDefinitionsApi apiInstance = new TaskDefinitionsApi();
        Integer $skip = 56; // Integer | The number of records you want to skip from the beginning.
You can skip at most 4000 records. To indicate a result range that starts, for example, at 1001, combine the $skip with the $top parameter.
If not specified, no records are skipped. You can use this parameter only once.
Refer also to the $top parameter.
        Integer $top = 56; // Integer | The number of records you want to show.
You can get at most 1000 records per API call. To indicate a result range that starts, for example, at 1001, combine the $top with the $skip parameter.
If not specified, 100 records are returned. You can use this parameter only once.
Refer also to the $skip parameter.
        String $inlinecount = $inlinecount_example; // String | Specify whether the total count of the task definitions should be returned as a value of the X-Total-Count response header.
To enable the header, use the 'allpages' setting. To disable the header, use the 'none' setting.
The values are case-sensitive. You can use this parameter only once.
        String $expand = $expand_example; // String | You can request task attributes to become part of the task output by specifying the value 'attributeDefinitions' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributeDefinitions' field is not included into the output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where the corresponding task definition exists.
        try {
            TaskDefinitionList result = apiInstance.v1TaskDefinitionsGet($skip, $top, $inlinecount, $expand);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TaskDefinitionsApi#v1TaskDefinitionsGet");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.TaskDefinitionsApi;

public class TaskDefinitionsApiExample {

    public static void main(String[] args) {
        TaskDefinitionsApi apiInstance = new TaskDefinitionsApi();
        Integer $skip = 56; // Integer | The number of records you want to skip from the beginning.
You can skip at most 4000 records. To indicate a result range that starts, for example, at 1001, combine the $skip with the $top parameter.
If not specified, no records are skipped. You can use this parameter only once.
Refer also to the $top parameter.
        Integer $top = 56; // Integer | The number of records you want to show.
You can get at most 1000 records per API call. To indicate a result range that starts, for example, at 1001, combine the $top with the $skip parameter.
If not specified, 100 records are returned. You can use this parameter only once.
Refer also to the $skip parameter.
        String $inlinecount = $inlinecount_example; // String | Specify whether the total count of the task definitions should be returned as a value of the X-Total-Count response header.
To enable the header, use the 'allpages' setting. To disable the header, use the 'none' setting.
The values are case-sensitive. You can use this parameter only once.
        String $expand = $expand_example; // String | You can request task attributes to become part of the task output by specifying the value 'attributeDefinitions' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributeDefinitions' field is not included into the output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where the corresponding task definition exists.
        try {
            TaskDefinitionList result = apiInstance.v1TaskDefinitionsGet($skip, $top, $inlinecount, $expand);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling TaskDefinitionsApi#v1TaskDefinitionsGet");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];
// Configure HTTP basic authorization (authentication scheme: BasicAuthentication)
[apiConfig setUsername:@"YOUR_USERNAME"];
[apiConfig setPassword:@"YOUR_PASSWORD"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_AuthorizationCode)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_ClientCredentials)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

Integer *$skip = 56; // The number of records you want to skip from the beginning.
You can skip at most 4000 records. To indicate a result range that starts, for example, at 1001, combine the $skip with the $top parameter.
If not specified, no records are skipped. You can use this parameter only once.
Refer also to the $top parameter. (optional) (default to 0)
Integer *$top = 56; // The number of records you want to show.
You can get at most 1000 records per API call. To indicate a result range that starts, for example, at 1001, combine the $top with the $skip parameter.
If not specified, 100 records are returned. You can use this parameter only once.
Refer also to the $skip parameter. (optional) (default to 100)
String *$inlinecount = $inlinecount_example; // Specify whether the total count of the task definitions should be returned as a value of the X-Total-Count response header.
To enable the header, use the 'allpages' setting. To disable the header, use the 'none' setting.
The values are case-sensitive. You can use this parameter only once. (optional) (default to none)
String *$expand = $expand_example; // You can request task attributes to become part of the task output by specifying the value 'attributeDefinitions' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributeDefinitions' field is not included into the output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where the corresponding task definition exists. (optional)

TaskDefinitionsApi *apiInstance = [[TaskDefinitionsApi alloc] init];

// Retrieve definitions by query parameters
[apiInstance v1TaskDefinitionsGetWith:$skip
    $top:$top
    $inlinecount:$inlinecount
    $expand:$expand
              completionHandler: ^(TaskDefinitionList output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var WorkflowApiForNeo = require('workflow_api_for_neo');
var defaultClient = WorkflowApiForNeo.ApiClient.instance;

// Configure HTTP basic authorization: BasicAuthentication
var BasicAuthentication = defaultClient.authentications['BasicAuthentication'];
BasicAuthentication.username = 'YOUR USERNAME'
BasicAuthentication.password = 'YOUR PASSWORD'

// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
var Oauth2_AuthorizationCode = defaultClient.authentications['Oauth2_AuthorizationCode'];
Oauth2_AuthorizationCode.accessToken = "YOUR ACCESS TOKEN"

// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
var Oauth2_ClientCredentials = defaultClient.authentications['Oauth2_ClientCredentials'];
Oauth2_ClientCredentials.accessToken = "YOUR ACCESS TOKEN"

var api = new WorkflowApiForNeo.TaskDefinitionsApi()

var opts = { 
  '$skip': 56, // {Integer} The number of records you want to skip from the beginning.
You can skip at most 4000 records. To indicate a result range that starts, for example, at 1001, combine the $skip with the $top parameter.
If not specified, no records are skipped. You can use this parameter only once.
Refer also to the $top parameter.
  '$top': 56, // {Integer} The number of records you want to show.
You can get at most 1000 records per API call. To indicate a result range that starts, for example, at 1001, combine the $top with the $skip parameter.
If not specified, 100 records are returned. You can use this parameter only once.
Refer also to the $skip parameter.
  '$inlinecount': $inlinecount_example, // {String} Specify whether the total count of the task definitions should be returned as a value of the X-Total-Count response header.
To enable the header, use the 'allpages' setting. To disable the header, use the 'none' setting.
The values are case-sensitive. You can use this parameter only once.
  '$expand': $expand_example // {String} You can request task attributes to become part of the task output by specifying the value 'attributeDefinitions' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributeDefinitions' field is not included into the output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where the corresponding task definition exists.
};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.v1TaskDefinitionsGet(opts, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class v1TaskDefinitionsGetExample
    {
        public void main()
        {
            
            // Configure HTTP basic authorization: BasicAuthentication
            Configuration.Default.Username = "YOUR_USERNAME";
            Configuration.Default.Password = "YOUR_PASSWORD";
            // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
            // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            var apiInstance = new TaskDefinitionsApi();
            var $skip = 56;  // Integer | The number of records you want to skip from the beginning.
You can skip at most 4000 records. To indicate a result range that starts, for example, at 1001, combine the $skip with the $top parameter.
If not specified, no records are skipped. You can use this parameter only once.
Refer also to the $top parameter. (optional)  (default to 0)
            var $top = 56;  // Integer | The number of records you want to show.
You can get at most 1000 records per API call. To indicate a result range that starts, for example, at 1001, combine the $top with the $skip parameter.
If not specified, 100 records are returned. You can use this parameter only once.
Refer also to the $skip parameter. (optional)  (default to 100)
            var $inlinecount = $inlinecount_example;  // String | Specify whether the total count of the task definitions should be returned as a value of the X-Total-Count response header.
To enable the header, use the 'allpages' setting. To disable the header, use the 'none' setting.
The values are case-sensitive. You can use this parameter only once. (optional)  (default to none)
            var $expand = $expand_example;  // String | You can request task attributes to become part of the task output by specifying the value 'attributeDefinitions' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributeDefinitions' field is not included into the output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where the corresponding task definition exists. (optional) 

            try
            {
                // Retrieve definitions by query parameters
                TaskDefinitionList result = apiInstance.v1TaskDefinitionsGet($skip, $top, $inlinecount, $expand);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling TaskDefinitionsApi.v1TaskDefinitionsGet: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
Swagger\Client\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Swagger\Client\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Swagger\Client\Api\TaskDefinitionsApi();
$$skip = 56; // Integer | The number of records you want to skip from the beginning.
You can skip at most 4000 records. To indicate a result range that starts, for example, at 1001, combine the $skip with the $top parameter.
If not specified, no records are skipped. You can use this parameter only once.
Refer also to the $top parameter.
$$top = 56; // Integer | The number of records you want to show.
You can get at most 1000 records per API call. To indicate a result range that starts, for example, at 1001, combine the $top with the $skip parameter.
If not specified, 100 records are returned. You can use this parameter only once.
Refer also to the $skip parameter.
$$inlinecount = $inlinecount_example; // String | Specify whether the total count of the task definitions should be returned as a value of the X-Total-Count response header.
To enable the header, use the 'allpages' setting. To disable the header, use the 'none' setting.
The values are case-sensitive. You can use this parameter only once.
$$expand = $expand_example; // String | You can request task attributes to become part of the task output by specifying the value 'attributeDefinitions' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributeDefinitions' field is not included into the output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where the corresponding task definition exists.

try {
    $result = $api_instance->v1TaskDefinitionsGet($$skip, $$top, $$inlinecount, $$expand);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling TaskDefinitionsApi->v1TaskDefinitionsGet: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::TaskDefinitionsApi;

# Configure HTTP basic authorization: BasicAuthentication
$WWW::SwaggerClient::Configuration::username = 'YOUR_USERNAME';
$WWW::SwaggerClient::Configuration::password = 'YOUR_PASSWORD';
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

my $api_instance = WWW::SwaggerClient::TaskDefinitionsApi->new();
my $$skip = 56; # Integer | The number of records you want to skip from the beginning.
You can skip at most 4000 records. To indicate a result range that starts, for example, at 1001, combine the $skip with the $top parameter.
If not specified, no records are skipped. You can use this parameter only once.
Refer also to the $top parameter.
my $$top = 56; # Integer | The number of records you want to show.
You can get at most 1000 records per API call. To indicate a result range that starts, for example, at 1001, combine the $top with the $skip parameter.
If not specified, 100 records are returned. You can use this parameter only once.
Refer also to the $skip parameter.
my $$inlinecount = $inlinecount_example; # String | Specify whether the total count of the task definitions should be returned as a value of the X-Total-Count response header.
To enable the header, use the 'allpages' setting. To disable the header, use the 'none' setting.
The values are case-sensitive. You can use this parameter only once.
my $$expand = $expand_example; # String | You can request task attributes to become part of the task output by specifying the value 'attributeDefinitions' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributeDefinitions' field is not included into the output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where the corresponding task definition exists.

eval { 
    my $result = $api_instance->v1TaskDefinitionsGet($skip => $$skip, $top => $$top, $inlinecount => $$inlinecount, $expand => $$expand);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling TaskDefinitionsApi->v1TaskDefinitionsGet: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# Configure HTTP basic authorization: BasicAuthentication
swagger_client.configuration.username = 'YOUR_USERNAME'
swagger_client.configuration.password = 'YOUR_PASSWORD'
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# create an instance of the API class
api_instance = swagger_client.TaskDefinitionsApi()
$skip = 56 # Integer | The number of records you want to skip from the beginning.
You can skip at most 4000 records. To indicate a result range that starts, for example, at 1001, combine the $skip with the $top parameter.
If not specified, no records are skipped. You can use this parameter only once.
Refer also to the $top parameter. (optional) (default to 0)
$top = 56 # Integer | The number of records you want to show.
You can get at most 1000 records per API call. To indicate a result range that starts, for example, at 1001, combine the $top with the $skip parameter.
If not specified, 100 records are returned. You can use this parameter only once.
Refer also to the $skip parameter. (optional) (default to 100)
$inlinecount = $inlinecount_example # String | Specify whether the total count of the task definitions should be returned as a value of the X-Total-Count response header.
To enable the header, use the 'allpages' setting. To disable the header, use the 'none' setting.
The values are case-sensitive. You can use this parameter only once. (optional) (default to none)
$expand = $expand_example # String | You can request task attributes to become part of the task output by specifying the value 'attributeDefinitions' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributeDefinitions' field is not included into the output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where the corresponding task definition exists. (optional)

try: 
    # Retrieve definitions by query parameters
    api_response = api_instance.v1TaskDefinitionsGet($skip=$skip, $top=$top, $inlinecount=$inlinecount, $expand=$expand)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling TaskDefinitionsApi->v1TaskDefinitionsGet: %s\n" % e)

Parameters

Query parameters
Name Description
$skip
$top
$inlinecount
$expand

Responses

Status: 200 - Returns a list of task definitions.

[{id=usertask1@myfirstworkflow, name=Approve Onboarding, createdAt=2017-03-08T17:26:51.643Z}, {id=usertask2@myfirstworkflow, name=Confirm Equipment of Onboardee, createdAt=2017-03-08T17:26:51.643Z}]

Status: 400 - Incorrect format or structure of the provided request body.

{error={code=bpm.workflowruntime.rest.content.format.invalid, message=Unable to parse the request content because it has an unexpected format or structure., logId=e329b2a4-cac7-44d7-b5c5-0494e6fbad5a}}

Status: 403 - Access forbidden. You do not have the required permissions to access the resource.

{error={message=User does not have sufficient privileges.}}

Status: 429 - Too many requests. You've reached the usage limits that are configured for your tenant. Reduce the number of requests.

Status: 500 - Internal server error. The operation you requested led to an error during execution.

{error={code=bpm.workflowruntime.rest.internal.server.error, message=Internal server error, logId=f29a5719-3342-4a4a-8a3d-5ddd5253159e}}

UserTaskInstances

/v1/task-instances

Retrieves user task instances by parameters. If no parameters are specified, all instances with status READY, RESERVED, CANCELED, or COMPLETED are returned. Parameters for different attributes of the instance are evaluated using the logical 'and' operator. If a parameter is specified multiple times, results are matched using the logical 'or' operator, unless noted otherwise. Empty parameters are treated as if they were not specified. By default, returned tasks are sorted by creation time in ascending order. Roles permitted to execute this operation: - Global roles: WorkflowViewer, WorkflowAdmin - Instance-specific roles: viewerUsers, viewerGroups, adminUsers, adminGroups [Prerequisite: You are assigned to the WorkflowParticipant global role.]


/v1/task-instances

Usage

curl -X GET -H "Accept: application/json" -H "Content-Type: application/json" -H "Authorization: Basic [[basicHash]]" "https://sandbox.api.sap.com/workflow-service/rest/v1/task-instances?$skip=&$top=&$inlinecount=&$expand=&$orderby=&workflowInstanceId=&workflowDefinitionId=&processor=&id=&activityId=&description=&subject=&createdAt=&createdFrom=&createdUpTo=&claimedAt=&claimedFrom=&claimedUpTo=&completedAt=&completedFrom=&completedUpTo=&lastChangedAt=&lastChangedFrom=&lastChangedUpTo=&dueDate=&dueDateFrom=&dueDateUpTo=&priority=&status=&recipientUsers=&recipientGroups=&containsText=&attributes.ExampleCustomAttribute=&definitionId="
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.UserTaskInstancesApi;

import java.io.File;
import java.util.*;

public class UserTaskInstancesApiExample {

    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure HTTP basic authorization: BasicAuthentication
        HttpBasicAuth BasicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("BasicAuthentication");
        BasicAuthentication.setUsername("YOUR USERNAME");
        BasicAuthentication.setPassword("YOUR PASSWORD");

        // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
        OAuth Oauth2_AuthorizationCode = (OAuth) defaultClient.getAuthentication("Oauth2_AuthorizationCode");
        Oauth2_AuthorizationCode.setAccessToken("YOUR ACCESS TOKEN");

        // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
        OAuth Oauth2_ClientCredentials = (OAuth) defaultClient.getAuthentication("Oauth2_ClientCredentials");
        Oauth2_ClientCredentials.setAccessToken("YOUR ACCESS TOKEN");

        UserTaskInstancesApi apiInstance = new UserTaskInstancesApi();
        Integer $skip = 56; // Integer | The number of records you want to skip from the beginning.
You can skip at most 4000 records. To indicate a result range that starts, for example, at 1001, combine the $skip with the $top parameter.
If not specified, no records are skipped. You can use this parameter only once.
Refer also to the $top parameter.
        Integer $top = 56; // Integer | The number of records you want to show.
You can get at most 1000 records per API call. To indicate a result range that starts, for example, at 1001, combine the $top with the $skip parameter.
If not specified, 100 records are returned. You can use this parameter only once.
Refer also to the $skip parameter.
        String $inlinecount = $inlinecount_example; // String | Specify whether the total count of the task instances, which match the search criteria, should be returned as a value 
of the X-Total-Count response header. To enable the header, use the 'allpages' setting. To disable the header, use the 'none' setting.
The values are case-sensitive. You can use this parameter only once.
        String $expand = $expand_example; // String | You can request task attributes to become part of the task output by specifying the value 'attributes' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributes' field is not included into task output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where these attributes are present.

        String $orderby = $orderby_example; // String | The attribute and direction by which tasks are sorted. The sort attribute and direction are separated by a space.
The parameter value is case-sensitive. You can only specify one ordering parameter, which contains attribute and direction.
To stabilize the order of tasks the implicit second ordering parameter 'createdAt asc' is applied.

 * claimedAt asc - Ascending, task claim time from the oldest to the most recent, tasks with status READY (not yet claimed) first.
 * claimedAt desc - Descending, from the most recently claimed tasks to the oldest ones, tasks with status READY (not yet claimed) last.
 * completedAt asc - Ascending, task completion or cancelation time from the oldest to the most recent, not yet COMPLETED tasks first.
 * completedAt desc - Descending, from the most recently COMPLETED or CANCELED tasks to the oldest ones, not yet COMPLETED tasks last.
 * createdAt asc - Ascending, task creation time from the oldest to the most recent.
 * createdAt desc - Descending, from the most recently created tasks to the oldest ones.
 * lastChangedAt asc - Ascending, task last change time from the oldest to the most recent.
 * lastChangedAt desc - Descending, from the most recently changed tasks to the oldest ones.             
 * dueDate asc - Ascending, tasks due date from the oldest to the most distant in future ones, tasks without due date first.
 * dueDate desc - Descending, tasks due date from the most distant in future to the oldest ones, tasks without due date last.
 * subject asc - Ascending, from A to Z case-sensitive.
 * subject desc - Descending, from Z to A case-sensitive.
 * description asc - Ascending, from A to Z case-sensitive, tasks without description first.
 * description desc - Descending, from Z to A case-sensitive, tasks without description last.
 * activityId asc - Ascending, from A to Z case-sensitive.
 * activityId desc - Descending, from Z to A case-sensitive.
 * id asc - Ascending, from A to Z case-sensitive.
 * id desc - Descending, from Z to A case-sensitive.
 * processor asc - Ascending, from A to Z case-sensitive, tasks without processor first.
 * processor desc - Descending, from Z to A case-sensitive, tasks without processor last.
 * workflowDefinitionId asc - Ascending, from A to Z case-sensitive.
 * workflowDefinitionId desc - Descending, from Z to A case-sensitive.
 * workflowInstanceId asc - Ascending, from A to Z case-sensitive.
 * workflowInstanceId desc - Descending, from Z to A case-sensitive.
 * priority asc - Ascending, tasks priority from lowest to highest.
 * priority desc - Descending, tasks priority from highest to lowest.
        String workflowInstanceId = workflowInstanceId_example; // String | The workflow instance ID for which the user task instances are returned. The workflow instance ID is 36 characters long.
        String workflowDefinitionId = workflowDefinitionId_example; // String | The workflow definition ID for which the user task instances are returned.
        String processor = processor_example; // String | The processor of the user task instance.
        String id = id_example; // String | The unique ID of the user task instance. The user task instance ID is 36 characters long.
        String activityId = activityId_example; // String | The activityId of the user task instance. This field represents the ID of the user task definition.
        String description = description_example; // String | The description of the user task instance in UTF-8 encoding. You must not specify texts that contain commas with this parameter.
        String subject = subject_example; // String | The subject of the user task instance in UTF-8 encoding. You must not specify texts that contain commas with this parameter.
        String createdAt = createdAt_example; // String | Time when the user task instance has been created.
Evaluated using the logical 'or' operator with the values of the 'createdFrom' and 'createdUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String createdFrom = createdFrom_example; // String | The start time (inclusive) of the time range when the user task instance was created.
Must be less or equal to the value of the 'createdUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'createdAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String createdUpTo = createdUpTo_example; // String | The end time (inclusive) of the time range when the user task instance was created.
Must be greater or equal to the value of the 'createdFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'createdAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String claimedAt = claimedAt_example; // String | Time when the user task instance was claimed.
Evaluated using the logical 'or' operator with the values of the 'claimedFrom' and 'claimedUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String claimedFrom = claimedFrom_example; // String | The start time (inclusive) of the time range when the user task instance was claimed.
Must be less or equal to the value of the 'claimedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'claimedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String claimedUpTo = claimedUpTo_example; // String | The end time (inclusive) of the time range when the user task instance was claimed.
Must be greater or equal to the value of the 'claimedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'claimedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String completedAt = completedAt_example; // String | Time when the user task instance was COMPLETED or CANCELED.
Evaluated using the logical 'or' operator with the values of the 'completedFrom' and 'completedUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String completedFrom = completedFrom_example; // String | The start time (inclusive) of the time range when the user task instance was COMPLETED or CANCELED.
Must be less or equal to the value of the 'completedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'completedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String completedUpTo = completedUpTo_example; // String | The end time (inclusive) of the time range when the user task instance was COMPLETED or CANCELED.
Must be greater or equal to the value of the 'completedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'completedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String lastChangedAt = lastChangedAt_example; // String | Time when the user task instance has been changed for the last time.
Evaluated using the logical 'or' operator with the values of the 'lastChangedFrom' and 'lastChangedTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String lastChangedFrom = lastChangedFrom_example; // String | The start time (inclusive) of the time range when the user task instance was changed for the last time.
Must be less or equal to the value of the 'lastChangedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'lastChangedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String lastChangedUpTo = lastChangedUpTo_example; // String | The end time (inclusive) of the time range when the user task instance was changed for the last time.
Must be greater or equal to the value of the 'lastChangedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'lastChangedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String dueDate = dueDate_example; // String | The due date of the user task instance.
Evaluated using the logical 'or' operator with the values of the 'dueDateFrom' and 'dueDateUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String dueDateFrom = dueDateFrom_example; // String | The start time (inclusive) of the due date time range for the user task instance.
Must be less or equal to the value of the 'dueDateUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'dueDate' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String dueDateUpTo = dueDateUpTo_example; // String | The end time (inclusive) of the due date time range for the user task instance.
Must be greater or equal to the 'dueDateFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'dueDate' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String priority = priority_example; // String | The priority of the user task instance.
The values are case-insensitive.

        String status = status_example; // String | The status of the user task instance.
The values are case-insensitive.

        String recipientUsers = recipientUsers_example; // String | The users who must be among the recipient users of the user task instance. A user task instance has to match at least one of the recipient users specified.
Specify the users by repeating this parameter multiple times, with one user each. 

        String recipientGroups = recipientGroups_example; // String | The groups which must be among the recipient groups of the user task instance. A user task instance has to match at least one of the recipient groups specified.
Specify the groups by repeating this parameter multiple times, with one user each. 

        String containsText = containsText_example; // String | Text, which should be contained in at least one of the following fields of the user task instance:

 * subject
 * description
 * activityId
 * id
 * processor
 * workflowDefinitionId
 * workflowInstanceId

Performed filtering is case-insensitive. You must not use this parameter more than once.

        String attributes.ExampleCustomAttribute = attributes.ExampleCustomAttribute_example; // String | Example of a parameter that filters task instances by the value of the custom attribute with the ID 'ExampleCustomAttribute'.
You can specify parameters for other attributes in an analogous way.
If you specify a parameter several times, the logical operators apply as outlined in the overall description of this API.
If attributes with different IDs are present in the URL, only tasks which contain all of them with the values specified will be returned as a response to the request.
If a query by custom attributes matches too many task definitions, you have to limit the query further. Refer, for example, to parameter 'definitionId'.

        String definitionId = definitionId_example; // String | The definition ID of the user task.
It consists of the ID of the task defined in the workflow definition (task definition ID) as well as the workflow definition ID delimited by an '@' sign.
For optimal performance, specify this parameter when searching for tasks by custom attributes.
If the custom attribute IDs from the query match more than 50 task definitions, you have to specify one or more task definition IDs when searching for tasks by custom attributes.

        try {
            TaskInstanceList result = apiInstance.v1TaskInstancesGet($skip, $top, $inlinecount, $expand, $orderby, workflowInstanceId, workflowDefinitionId, processor, id, activityId, description, subject, createdAt, createdFrom, createdUpTo, claimedAt, claimedFrom, claimedUpTo, completedAt, completedFrom, completedUpTo, lastChangedAt, lastChangedFrom, lastChangedUpTo, dueDate, dueDateFrom, dueDateUpTo, priority, status, recipientUsers, recipientGroups, containsText, attributes.ExampleCustomAttribute, definitionId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserTaskInstancesApi#v1TaskInstancesGet");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.UserTaskInstancesApi;

public class UserTaskInstancesApiExample {

    public static void main(String[] args) {
        UserTaskInstancesApi apiInstance = new UserTaskInstancesApi();
        Integer $skip = 56; // Integer | The number of records you want to skip from the beginning.
You can skip at most 4000 records. To indicate a result range that starts, for example, at 1001, combine the $skip with the $top parameter.
If not specified, no records are skipped. You can use this parameter only once.
Refer also to the $top parameter.
        Integer $top = 56; // Integer | The number of records you want to show.
You can get at most 1000 records per API call. To indicate a result range that starts, for example, at 1001, combine the $top with the $skip parameter.
If not specified, 100 records are returned. You can use this parameter only once.
Refer also to the $skip parameter.
        String $inlinecount = $inlinecount_example; // String | Specify whether the total count of the task instances, which match the search criteria, should be returned as a value 
of the X-Total-Count response header. To enable the header, use the 'allpages' setting. To disable the header, use the 'none' setting.
The values are case-sensitive. You can use this parameter only once.
        String $expand = $expand_example; // String | You can request task attributes to become part of the task output by specifying the value 'attributes' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributes' field is not included into task output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where these attributes are present.

        String $orderby = $orderby_example; // String | The attribute and direction by which tasks are sorted. The sort attribute and direction are separated by a space.
The parameter value is case-sensitive. You can only specify one ordering parameter, which contains attribute and direction.
To stabilize the order of tasks the implicit second ordering parameter 'createdAt asc' is applied.

 * claimedAt asc - Ascending, task claim time from the oldest to the most recent, tasks with status READY (not yet claimed) first.
 * claimedAt desc - Descending, from the most recently claimed tasks to the oldest ones, tasks with status READY (not yet claimed) last.
 * completedAt asc - Ascending, task completion or cancelation time from the oldest to the most recent, not yet COMPLETED tasks first.
 * completedAt desc - Descending, from the most recently COMPLETED or CANCELED tasks to the oldest ones, not yet COMPLETED tasks last.
 * createdAt asc - Ascending, task creation time from the oldest to the most recent.
 * createdAt desc - Descending, from the most recently created tasks to the oldest ones.
 * lastChangedAt asc - Ascending, task last change time from the oldest to the most recent.
 * lastChangedAt desc - Descending, from the most recently changed tasks to the oldest ones.             
 * dueDate asc - Ascending, tasks due date from the oldest to the most distant in future ones, tasks without due date first.
 * dueDate desc - Descending, tasks due date from the most distant in future to the oldest ones, tasks without due date last.
 * subject asc - Ascending, from A to Z case-sensitive.
 * subject desc - Descending, from Z to A case-sensitive.
 * description asc - Ascending, from A to Z case-sensitive, tasks without description first.
 * description desc - Descending, from Z to A case-sensitive, tasks without description last.
 * activityId asc - Ascending, from A to Z case-sensitive.
 * activityId desc - Descending, from Z to A case-sensitive.
 * id asc - Ascending, from A to Z case-sensitive.
 * id desc - Descending, from Z to A case-sensitive.
 * processor asc - Ascending, from A to Z case-sensitive, tasks without processor first.
 * processor desc - Descending, from Z to A case-sensitive, tasks without processor last.
 * workflowDefinitionId asc - Ascending, from A to Z case-sensitive.
 * workflowDefinitionId desc - Descending, from Z to A case-sensitive.
 * workflowInstanceId asc - Ascending, from A to Z case-sensitive.
 * workflowInstanceId desc - Descending, from Z to A case-sensitive.
 * priority asc - Ascending, tasks priority from lowest to highest.
 * priority desc - Descending, tasks priority from highest to lowest.
        String workflowInstanceId = workflowInstanceId_example; // String | The workflow instance ID for which the user task instances are returned. The workflow instance ID is 36 characters long.
        String workflowDefinitionId = workflowDefinitionId_example; // String | The workflow definition ID for which the user task instances are returned.
        String processor = processor_example; // String | The processor of the user task instance.
        String id = id_example; // String | The unique ID of the user task instance. The user task instance ID is 36 characters long.
        String activityId = activityId_example; // String | The activityId of the user task instance. This field represents the ID of the user task definition.
        String description = description_example; // String | The description of the user task instance in UTF-8 encoding. You must not specify texts that contain commas with this parameter.
        String subject = subject_example; // String | The subject of the user task instance in UTF-8 encoding. You must not specify texts that contain commas with this parameter.
        String createdAt = createdAt_example; // String | Time when the user task instance has been created.
Evaluated using the logical 'or' operator with the values of the 'createdFrom' and 'createdUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String createdFrom = createdFrom_example; // String | The start time (inclusive) of the time range when the user task instance was created.
Must be less or equal to the value of the 'createdUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'createdAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String createdUpTo = createdUpTo_example; // String | The end time (inclusive) of the time range when the user task instance was created.
Must be greater or equal to the value of the 'createdFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'createdAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String claimedAt = claimedAt_example; // String | Time when the user task instance was claimed.
Evaluated using the logical 'or' operator with the values of the 'claimedFrom' and 'claimedUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String claimedFrom = claimedFrom_example; // String | The start time (inclusive) of the time range when the user task instance was claimed.
Must be less or equal to the value of the 'claimedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'claimedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String claimedUpTo = claimedUpTo_example; // String | The end time (inclusive) of the time range when the user task instance was claimed.
Must be greater or equal to the value of the 'claimedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'claimedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String completedAt = completedAt_example; // String | Time when the user task instance was COMPLETED or CANCELED.
Evaluated using the logical 'or' operator with the values of the 'completedFrom' and 'completedUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String completedFrom = completedFrom_example; // String | The start time (inclusive) of the time range when the user task instance was COMPLETED or CANCELED.
Must be less or equal to the value of the 'completedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'completedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String completedUpTo = completedUpTo_example; // String | The end time (inclusive) of the time range when the user task instance was COMPLETED or CANCELED.
Must be greater or equal to the value of the 'completedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'completedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String lastChangedAt = lastChangedAt_example; // String | Time when the user task instance has been changed for the last time.
Evaluated using the logical 'or' operator with the values of the 'lastChangedFrom' and 'lastChangedTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String lastChangedFrom = lastChangedFrom_example; // String | The start time (inclusive) of the time range when the user task instance was changed for the last time.
Must be less or equal to the value of the 'lastChangedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'lastChangedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String lastChangedUpTo = lastChangedUpTo_example; // String | The end time (inclusive) of the time range when the user task instance was changed for the last time.
Must be greater or equal to the value of the 'lastChangedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'lastChangedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String dueDate = dueDate_example; // String | The due date of the user task instance.
Evaluated using the logical 'or' operator with the values of the 'dueDateFrom' and 'dueDateUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String dueDateFrom = dueDateFrom_example; // String | The start time (inclusive) of the due date time range for the user task instance.
Must be less or equal to the value of the 'dueDateUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'dueDate' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String dueDateUpTo = dueDateUpTo_example; // String | The end time (inclusive) of the due date time range for the user task instance.
Must be greater or equal to the 'dueDateFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'dueDate' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

        String priority = priority_example; // String | The priority of the user task instance.
The values are case-insensitive.

        String status = status_example; // String | The status of the user task instance.
The values are case-insensitive.

        String recipientUsers = recipientUsers_example; // String | The users who must be among the recipient users of the user task instance. A user task instance has to match at least one of the recipient users specified.
Specify the users by repeating this parameter multiple times, with one user each. 

        String recipientGroups = recipientGroups_example; // String | The groups which must be among the recipient groups of the user task instance. A user task instance has to match at least one of the recipient groups specified.
Specify the groups by repeating this parameter multiple times, with one user each. 

        String containsText = containsText_example; // String | Text, which should be contained in at least one of the following fields of the user task instance:

 * subject
 * description
 * activityId
 * id
 * processor
 * workflowDefinitionId
 * workflowInstanceId

Performed filtering is case-insensitive. You must not use this parameter more than once.

        String attributes.ExampleCustomAttribute = attributes.ExampleCustomAttribute_example; // String | Example of a parameter that filters task instances by the value of the custom attribute with the ID 'ExampleCustomAttribute'.
You can specify parameters for other attributes in an analogous way.
If you specify a parameter several times, the logical operators apply as outlined in the overall description of this API.
If attributes with different IDs are present in the URL, only tasks which contain all of them with the values specified will be returned as a response to the request.
If a query by custom attributes matches too many task definitions, you have to limit the query further. Refer, for example, to parameter 'definitionId'.

        String definitionId = definitionId_example; // String | The definition ID of the user task.
It consists of the ID of the task defined in the workflow definition (task definition ID) as well as the workflow definition ID delimited by an '@' sign.
For optimal performance, specify this parameter when searching for tasks by custom attributes.
If the custom attribute IDs from the query match more than 50 task definitions, you have to specify one or more task definition IDs when searching for tasks by custom attributes.

        try {
            TaskInstanceList result = apiInstance.v1TaskInstancesGet($skip, $top, $inlinecount, $expand, $orderby, workflowInstanceId, workflowDefinitionId, processor, id, activityId, description, subject, createdAt, createdFrom, createdUpTo, claimedAt, claimedFrom, claimedUpTo, completedAt, completedFrom, completedUpTo, lastChangedAt, lastChangedFrom, lastChangedUpTo, dueDate, dueDateFrom, dueDateUpTo, priority, status, recipientUsers, recipientGroups, containsText, attributes.ExampleCustomAttribute, definitionId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserTaskInstancesApi#v1TaskInstancesGet");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];
// Configure HTTP basic authorization (authentication scheme: BasicAuthentication)
[apiConfig setUsername:@"YOUR_USERNAME"];
[apiConfig setPassword:@"YOUR_PASSWORD"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_AuthorizationCode)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_ClientCredentials)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

Integer *$skip = 56; // The number of records you want to skip from the beginning.
You can skip at most 4000 records. To indicate a result range that starts, for example, at 1001, combine the $skip with the $top parameter.
If not specified, no records are skipped. You can use this parameter only once.
Refer also to the $top parameter. (optional) (default to 0)
Integer *$top = 56; // The number of records you want to show.
You can get at most 1000 records per API call. To indicate a result range that starts, for example, at 1001, combine the $top with the $skip parameter.
If not specified, 100 records are returned. You can use this parameter only once.
Refer also to the $skip parameter. (optional) (default to 100)
String *$inlinecount = $inlinecount_example; // Specify whether the total count of the task instances, which match the search criteria, should be returned as a value 
of the X-Total-Count response header. To enable the header, use the 'allpages' setting. To disable the header, use the 'none' setting.
The values are case-sensitive. You can use this parameter only once. (optional) (default to none)
String *$expand = $expand_example; // You can request task attributes to become part of the task output by specifying the value 'attributes' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributes' field is not included into task output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where these attributes are present.
 (optional)
String *$orderby = $orderby_example; // The attribute and direction by which tasks are sorted. The sort attribute and direction are separated by a space.
The parameter value is case-sensitive. You can only specify one ordering parameter, which contains attribute and direction.
To stabilize the order of tasks the implicit second ordering parameter 'createdAt asc' is applied.

 * claimedAt asc - Ascending, task claim time from the oldest to the most recent, tasks with status READY (not yet claimed) first.
 * claimedAt desc - Descending, from the most recently claimed tasks to the oldest ones, tasks with status READY (not yet claimed) last.
 * completedAt asc - Ascending, task completion or cancelation time from the oldest to the most recent, not yet COMPLETED tasks first.
 * completedAt desc - Descending, from the most recently COMPLETED or CANCELED tasks to the oldest ones, not yet COMPLETED tasks last.
 * createdAt asc - Ascending, task creation time from the oldest to the most recent.
 * createdAt desc - Descending, from the most recently created tasks to the oldest ones.
 * lastChangedAt asc - Ascending, task last change time from the oldest to the most recent.
 * lastChangedAt desc - Descending, from the most recently changed tasks to the oldest ones.             
 * dueDate asc - Ascending, tasks due date from the oldest to the most distant in future ones, tasks without due date first.
 * dueDate desc - Descending, tasks due date from the most distant in future to the oldest ones, tasks without due date last.
 * subject asc - Ascending, from A to Z case-sensitive.
 * subject desc - Descending, from Z to A case-sensitive.
 * description asc - Ascending, from A to Z case-sensitive, tasks without description first.
 * description desc - Descending, from Z to A case-sensitive, tasks without description last.
 * activityId asc - Ascending, from A to Z case-sensitive.
 * activityId desc - Descending, from Z to A case-sensitive.
 * id asc - Ascending, from A to Z case-sensitive.
 * id desc - Descending, from Z to A case-sensitive.
 * processor asc - Ascending, from A to Z case-sensitive, tasks without processor first.
 * processor desc - Descending, from Z to A case-sensitive, tasks without processor last.
 * workflowDefinitionId asc - Ascending, from A to Z case-sensitive.
 * workflowDefinitionId desc - Descending, from Z to A case-sensitive.
 * workflowInstanceId asc - Ascending, from A to Z case-sensitive.
 * workflowInstanceId desc - Descending, from Z to A case-sensitive.
 * priority asc - Ascending, tasks priority from lowest to highest.
 * priority desc - Descending, tasks priority from highest to lowest. (optional) (default to createdAt asc)
String *workflowInstanceId = workflowInstanceId_example; // The workflow instance ID for which the user task instances are returned. The workflow instance ID is 36 characters long. (optional)
String *workflowDefinitionId = workflowDefinitionId_example; // The workflow definition ID for which the user task instances are returned. (optional)
String *processor = processor_example; // The processor of the user task instance. (optional)
String *id = id_example; // The unique ID of the user task instance. The user task instance ID is 36 characters long. (optional)
String *activityId = activityId_example; // The activityId of the user task instance. This field represents the ID of the user task definition. (optional)
String *description = description_example; // The description of the user task instance in UTF-8 encoding. You must not specify texts that contain commas with this parameter. (optional)
String *subject = subject_example; // The subject of the user task instance in UTF-8 encoding. You must not specify texts that contain commas with this parameter. (optional)
String *createdAt = createdAt_example; // Time when the user task instance has been created.
Evaluated using the logical 'or' operator with the values of the 'createdFrom' and 'createdUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
String *createdFrom = createdFrom_example; // The start time (inclusive) of the time range when the user task instance was created.
Must be less or equal to the value of the 'createdUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'createdAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
String *createdUpTo = createdUpTo_example; // The end time (inclusive) of the time range when the user task instance was created.
Must be greater or equal to the value of the 'createdFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'createdAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
String *claimedAt = claimedAt_example; // Time when the user task instance was claimed.
Evaluated using the logical 'or' operator with the values of the 'claimedFrom' and 'claimedUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
String *claimedFrom = claimedFrom_example; // The start time (inclusive) of the time range when the user task instance was claimed.
Must be less or equal to the value of the 'claimedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'claimedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
String *claimedUpTo = claimedUpTo_example; // The end time (inclusive) of the time range when the user task instance was claimed.
Must be greater or equal to the value of the 'claimedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'claimedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
String *completedAt = completedAt_example; // Time when the user task instance was COMPLETED or CANCELED.
Evaluated using the logical 'or' operator with the values of the 'completedFrom' and 'completedUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
String *completedFrom = completedFrom_example; // The start time (inclusive) of the time range when the user task instance was COMPLETED or CANCELED.
Must be less or equal to the value of the 'completedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'completedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
String *completedUpTo = completedUpTo_example; // The end time (inclusive) of the time range when the user task instance was COMPLETED or CANCELED.
Must be greater or equal to the value of the 'completedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'completedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
String *lastChangedAt = lastChangedAt_example; // Time when the user task instance has been changed for the last time.
Evaluated using the logical 'or' operator with the values of the 'lastChangedFrom' and 'lastChangedTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
String *lastChangedFrom = lastChangedFrom_example; // The start time (inclusive) of the time range when the user task instance was changed for the last time.
Must be less or equal to the value of the 'lastChangedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'lastChangedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
String *lastChangedUpTo = lastChangedUpTo_example; // The end time (inclusive) of the time range when the user task instance was changed for the last time.
Must be greater or equal to the value of the 'lastChangedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'lastChangedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
String *dueDate = dueDate_example; // The due date of the user task instance.
Evaluated using the logical 'or' operator with the values of the 'dueDateFrom' and 'dueDateUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
String *dueDateFrom = dueDateFrom_example; // The start time (inclusive) of the due date time range for the user task instance.
Must be less or equal to the value of the 'dueDateUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'dueDate' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
String *dueDateUpTo = dueDateUpTo_example; // The end time (inclusive) of the due date time range for the user task instance.
Must be greater or equal to the 'dueDateFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'dueDate' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
String *priority = priority_example; // The priority of the user task instance.
The values are case-insensitive.
 (optional)
String *status = status_example; // The status of the user task instance.
The values are case-insensitive.
 (optional)
String *recipientUsers = recipientUsers_example; // The users who must be among the recipient users of the user task instance. A user task instance has to match at least one of the recipient users specified.
Specify the users by repeating this parameter multiple times, with one user each. 
 (optional)
String *recipientGroups = recipientGroups_example; // The groups which must be among the recipient groups of the user task instance. A user task instance has to match at least one of the recipient groups specified.
Specify the groups by repeating this parameter multiple times, with one user each. 
 (optional)
String *containsText = containsText_example; // Text, which should be contained in at least one of the following fields of the user task instance:

 * subject
 * description
 * activityId
 * id
 * processor
 * workflowDefinitionId
 * workflowInstanceId

Performed filtering is case-insensitive. You must not use this parameter more than once.
 (optional)
String *attributes.ExampleCustomAttribute = attributes.ExampleCustomAttribute_example; // Example of a parameter that filters task instances by the value of the custom attribute with the ID 'ExampleCustomAttribute'.
You can specify parameters for other attributes in an analogous way.
If you specify a parameter several times, the logical operators apply as outlined in the overall description of this API.
If attributes with different IDs are present in the URL, only tasks which contain all of them with the values specified will be returned as a response to the request.
If a query by custom attributes matches too many task definitions, you have to limit the query further. Refer, for example, to parameter 'definitionId'.
 (optional)
String *definitionId = definitionId_example; // The definition ID of the user task.
It consists of the ID of the task defined in the workflow definition (task definition ID) as well as the workflow definition ID delimited by an '@' sign.
For optimal performance, specify this parameter when searching for tasks by custom attributes.
If the custom attribute IDs from the query match more than 50 task definitions, you have to specify one or more task definition IDs when searching for tasks by custom attributes.
 (optional)

UserTaskInstancesApi *apiInstance = [[UserTaskInstancesApi alloc] init];

// Retrieve instances by query parameters
[apiInstance v1TaskInstancesGetWith:$skip
    $top:$top
    $inlinecount:$inlinecount
    $expand:$expand
    $orderby:$orderby
    workflowInstanceId:workflowInstanceId
    workflowDefinitionId:workflowDefinitionId
    processor:processor
    id:id
    activityId:activityId
    description:description
    subject:subject
    createdAt:createdAt
    createdFrom:createdFrom
    createdUpTo:createdUpTo
    claimedAt:claimedAt
    claimedFrom:claimedFrom
    claimedUpTo:claimedUpTo
    completedAt:completedAt
    completedFrom:completedFrom
    completedUpTo:completedUpTo
    lastChangedAt:lastChangedAt
    lastChangedFrom:lastChangedFrom
    lastChangedUpTo:lastChangedUpTo
    dueDate:dueDate
    dueDateFrom:dueDateFrom
    dueDateUpTo:dueDateUpTo
    priority:priority
    status:status
    recipientUsers:recipientUsers
    recipientGroups:recipientGroups
    containsText:containsText
    attributes.ExampleCustomAttribute:attributes.ExampleCustomAttribute
    definitionId:definitionId
              completionHandler: ^(TaskInstanceList output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var WorkflowApiForNeo = require('workflow_api_for_neo');
var defaultClient = WorkflowApiForNeo.ApiClient.instance;

// Configure HTTP basic authorization: BasicAuthentication
var BasicAuthentication = defaultClient.authentications['BasicAuthentication'];
BasicAuthentication.username = 'YOUR USERNAME'
BasicAuthentication.password = 'YOUR PASSWORD'

// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
var Oauth2_AuthorizationCode = defaultClient.authentications['Oauth2_AuthorizationCode'];
Oauth2_AuthorizationCode.accessToken = "YOUR ACCESS TOKEN"

// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
var Oauth2_ClientCredentials = defaultClient.authentications['Oauth2_ClientCredentials'];
Oauth2_ClientCredentials.accessToken = "YOUR ACCESS TOKEN"

var api = new WorkflowApiForNeo.UserTaskInstancesApi()

var opts = { 
  '$skip': 56, // {Integer} The number of records you want to skip from the beginning.
You can skip at most 4000 records. To indicate a result range that starts, for example, at 1001, combine the $skip with the $top parameter.
If not specified, no records are skipped. You can use this parameter only once.
Refer also to the $top parameter.
  '$top': 56, // {Integer} The number of records you want to show.
You can get at most 1000 records per API call. To indicate a result range that starts, for example, at 1001, combine the $top with the $skip parameter.
If not specified, 100 records are returned. You can use this parameter only once.
Refer also to the $skip parameter.
  '$inlinecount': $inlinecount_example, // {String} Specify whether the total count of the task instances, which match the search criteria, should be returned as a value 
of the X-Total-Count response header. To enable the header, use the 'allpages' setting. To disable the header, use the 'none' setting.
The values are case-sensitive. You can use this parameter only once.
  '$expand': $expand_example, // {String} You can request task attributes to become part of the task output by specifying the value 'attributes' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributes' field is not included into task output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where these attributes are present.

  '$orderby': $orderby_example, // {String} The attribute and direction by which tasks are sorted. The sort attribute and direction are separated by a space.
The parameter value is case-sensitive. You can only specify one ordering parameter, which contains attribute and direction.
To stabilize the order of tasks the implicit second ordering parameter 'createdAt asc' is applied.

 * claimedAt asc - Ascending, task claim time from the oldest to the most recent, tasks with status READY (not yet claimed) first.
 * claimedAt desc - Descending, from the most recently claimed tasks to the oldest ones, tasks with status READY (not yet claimed) last.
 * completedAt asc - Ascending, task completion or cancelation time from the oldest to the most recent, not yet COMPLETED tasks first.
 * completedAt desc - Descending, from the most recently COMPLETED or CANCELED tasks to the oldest ones, not yet COMPLETED tasks last.
 * createdAt asc - Ascending, task creation time from the oldest to the most recent.
 * createdAt desc - Descending, from the most recently created tasks to the oldest ones.
 * lastChangedAt asc - Ascending, task last change time from the oldest to the most recent.
 * lastChangedAt desc - Descending, from the most recently changed tasks to the oldest ones.             
 * dueDate asc - Ascending, tasks due date from the oldest to the most distant in future ones, tasks without due date first.
 * dueDate desc - Descending, tasks due date from the most distant in future to the oldest ones, tasks without due date last.
 * subject asc - Ascending, from A to Z case-sensitive.
 * subject desc - Descending, from Z to A case-sensitive.
 * description asc - Ascending, from A to Z case-sensitive, tasks without description first.
 * description desc - Descending, from Z to A case-sensitive, tasks without description last.
 * activityId asc - Ascending, from A to Z case-sensitive.
 * activityId desc - Descending, from Z to A case-sensitive.
 * id asc - Ascending, from A to Z case-sensitive.
 * id desc - Descending, from Z to A case-sensitive.
 * processor asc - Ascending, from A to Z case-sensitive, tasks without processor first.
 * processor desc - Descending, from Z to A case-sensitive, tasks without processor last.
 * workflowDefinitionId asc - Ascending, from A to Z case-sensitive.
 * workflowDefinitionId desc - Descending, from Z to A case-sensitive.
 * workflowInstanceId asc - Ascending, from A to Z case-sensitive.
 * workflowInstanceId desc - Descending, from Z to A case-sensitive.
 * priority asc - Ascending, tasks priority from lowest to highest.
 * priority desc - Descending, tasks priority from highest to lowest.
  'workflowInstanceId': workflowInstanceId_example, // {String} The workflow instance ID for which the user task instances are returned. The workflow instance ID is 36 characters long.
  'workflowDefinitionId': workflowDefinitionId_example, // {String} The workflow definition ID for which the user task instances are returned.
  'processor': processor_example, // {String} The processor of the user task instance.
  'id': id_example, // {String} The unique ID of the user task instance. The user task instance ID is 36 characters long.
  'activityId': activityId_example, // {String} The activityId of the user task instance. This field represents the ID of the user task definition.
  'description': description_example, // {String} The description of the user task instance in UTF-8 encoding. You must not specify texts that contain commas with this parameter.
  'subject': subject_example, // {String} The subject of the user task instance in UTF-8 encoding. You must not specify texts that contain commas with this parameter.
  'createdAt': createdAt_example, // {String} Time when the user task instance has been created.
Evaluated using the logical 'or' operator with the values of the 'createdFrom' and 'createdUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

  'createdFrom': createdFrom_example, // {String} The start time (inclusive) of the time range when the user task instance was created.
Must be less or equal to the value of the 'createdUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'createdAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

  'createdUpTo': createdUpTo_example, // {String} The end time (inclusive) of the time range when the user task instance was created.
Must be greater or equal to the value of the 'createdFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'createdAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

  'claimedAt': claimedAt_example, // {String} Time when the user task instance was claimed.
Evaluated using the logical 'or' operator with the values of the 'claimedFrom' and 'claimedUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

  'claimedFrom': claimedFrom_example, // {String} The start time (inclusive) of the time range when the user task instance was claimed.
Must be less or equal to the value of the 'claimedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'claimedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

  'claimedUpTo': claimedUpTo_example, // {String} The end time (inclusive) of the time range when the user task instance was claimed.
Must be greater or equal to the value of the 'claimedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'claimedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

  'completedAt': completedAt_example, // {String} Time when the user task instance was COMPLETED or CANCELED.
Evaluated using the logical 'or' operator with the values of the 'completedFrom' and 'completedUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

  'completedFrom': completedFrom_example, // {String} The start time (inclusive) of the time range when the user task instance was COMPLETED or CANCELED.
Must be less or equal to the value of the 'completedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'completedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

  'completedUpTo': completedUpTo_example, // {String} The end time (inclusive) of the time range when the user task instance was COMPLETED or CANCELED.
Must be greater or equal to the value of the 'completedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'completedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

  'lastChangedAt': lastChangedAt_example, // {String} Time when the user task instance has been changed for the last time.
Evaluated using the logical 'or' operator with the values of the 'lastChangedFrom' and 'lastChangedTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

  'lastChangedFrom': lastChangedFrom_example, // {String} The start time (inclusive) of the time range when the user task instance was changed for the last time.
Must be less or equal to the value of the 'lastChangedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'lastChangedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

  'lastChangedUpTo': lastChangedUpTo_example, // {String} The end time (inclusive) of the time range when the user task instance was changed for the last time.
Must be greater or equal to the value of the 'lastChangedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'lastChangedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

  'dueDate': dueDate_example, // {String} The due date of the user task instance.
Evaluated using the logical 'or' operator with the values of the 'dueDateFrom' and 'dueDateUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

  'dueDateFrom': dueDateFrom_example, // {String} The start time (inclusive) of the due date time range for the user task instance.
Must be less or equal to the value of the 'dueDateUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'dueDate' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

  'dueDateUpTo': dueDateUpTo_example, // {String} The end time (inclusive) of the due date time range for the user task instance.
Must be greater or equal to the 'dueDateFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'dueDate' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

  'priority': priority_example, // {String} The priority of the user task instance.
The values are case-insensitive.

  'status': status_example, // {String} The status of the user task instance.
The values are case-insensitive.

  'recipientUsers': recipientUsers_example, // {String} The users who must be among the recipient users of the user task instance. A user task instance has to match at least one of the recipient users specified.
Specify the users by repeating this parameter multiple times, with one user each. 

  'recipientGroups': recipientGroups_example, // {String} The groups which must be among the recipient groups of the user task instance. A user task instance has to match at least one of the recipient groups specified.
Specify the groups by repeating this parameter multiple times, with one user each. 

  'containsText': containsText_example, // {String} Text, which should be contained in at least one of the following fields of the user task instance:

 * subject
 * description
 * activityId
 * id
 * processor
 * workflowDefinitionId
 * workflowInstanceId

Performed filtering is case-insensitive. You must not use this parameter more than once.

  'attributes.ExampleCustomAttribute': attributes.ExampleCustomAttribute_example, // {String} Example of a parameter that filters task instances by the value of the custom attribute with the ID 'ExampleCustomAttribute'.
You can specify parameters for other attributes in an analogous way.
If you specify a parameter several times, the logical operators apply as outlined in the overall description of this API.
If attributes with different IDs are present in the URL, only tasks which contain all of them with the values specified will be returned as a response to the request.
If a query by custom attributes matches too many task definitions, you have to limit the query further. Refer, for example, to parameter 'definitionId'.

  'definitionId': definitionId_example // {String} The definition ID of the user task.
It consists of the ID of the task defined in the workflow definition (task definition ID) as well as the workflow definition ID delimited by an '@' sign.
For optimal performance, specify this parameter when searching for tasks by custom attributes.
If the custom attribute IDs from the query match more than 50 task definitions, you have to specify one or more task definition IDs when searching for tasks by custom attributes.

};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.v1TaskInstancesGet(opts, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class v1TaskInstancesGetExample
    {
        public void main()
        {
            
            // Configure HTTP basic authorization: BasicAuthentication
            Configuration.Default.Username = "YOUR_USERNAME";
            Configuration.Default.Password = "YOUR_PASSWORD";
            // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
            // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            var apiInstance = new UserTaskInstancesApi();
            var $skip = 56;  // Integer | The number of records you want to skip from the beginning.
You can skip at most 4000 records. To indicate a result range that starts, for example, at 1001, combine the $skip with the $top parameter.
If not specified, no records are skipped. You can use this parameter only once.
Refer also to the $top parameter. (optional)  (default to 0)
            var $top = 56;  // Integer | The number of records you want to show.
You can get at most 1000 records per API call. To indicate a result range that starts, for example, at 1001, combine the $top with the $skip parameter.
If not specified, 100 records are returned. You can use this parameter only once.
Refer also to the $skip parameter. (optional)  (default to 100)
            var $inlinecount = $inlinecount_example;  // String | Specify whether the total count of the task instances, which match the search criteria, should be returned as a value 
of the X-Total-Count response header. To enable the header, use the 'allpages' setting. To disable the header, use the 'none' setting.
The values are case-sensitive. You can use this parameter only once. (optional)  (default to none)
            var $expand = $expand_example;  // String | You can request task attributes to become part of the task output by specifying the value 'attributes' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributes' field is not included into task output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where these attributes are present.
 (optional) 
            var $orderby = $orderby_example;  // String | The attribute and direction by which tasks are sorted. The sort attribute and direction are separated by a space.
The parameter value is case-sensitive. You can only specify one ordering parameter, which contains attribute and direction.
To stabilize the order of tasks the implicit second ordering parameter 'createdAt asc' is applied.

 * claimedAt asc - Ascending, task claim time from the oldest to the most recent, tasks with status READY (not yet claimed) first.
 * claimedAt desc - Descending, from the most recently claimed tasks to the oldest ones, tasks with status READY (not yet claimed) last.
 * completedAt asc - Ascending, task completion or cancelation time from the oldest to the most recent, not yet COMPLETED tasks first.
 * completedAt desc - Descending, from the most recently COMPLETED or CANCELED tasks to the oldest ones, not yet COMPLETED tasks last.
 * createdAt asc - Ascending, task creation time from the oldest to the most recent.
 * createdAt desc - Descending, from the most recently created tasks to the oldest ones.
 * lastChangedAt asc - Ascending, task last change time from the oldest to the most recent.
 * lastChangedAt desc - Descending, from the most recently changed tasks to the oldest ones.             
 * dueDate asc - Ascending, tasks due date from the oldest to the most distant in future ones, tasks without due date first.
 * dueDate desc - Descending, tasks due date from the most distant in future to the oldest ones, tasks without due date last.
 * subject asc - Ascending, from A to Z case-sensitive.
 * subject desc - Descending, from Z to A case-sensitive.
 * description asc - Ascending, from A to Z case-sensitive, tasks without description first.
 * description desc - Descending, from Z to A case-sensitive, tasks without description last.
 * activityId asc - Ascending, from A to Z case-sensitive.
 * activityId desc - Descending, from Z to A case-sensitive.
 * id asc - Ascending, from A to Z case-sensitive.
 * id desc - Descending, from Z to A case-sensitive.
 * processor asc - Ascending, from A to Z case-sensitive, tasks without processor first.
 * processor desc - Descending, from Z to A case-sensitive, tasks without processor last.
 * workflowDefinitionId asc - Ascending, from A to Z case-sensitive.
 * workflowDefinitionId desc - Descending, from Z to A case-sensitive.
 * workflowInstanceId asc - Ascending, from A to Z case-sensitive.
 * workflowInstanceId desc - Descending, from Z to A case-sensitive.
 * priority asc - Ascending, tasks priority from lowest to highest.
 * priority desc - Descending, tasks priority from highest to lowest. (optional)  (default to createdAt asc)
            var workflowInstanceId = workflowInstanceId_example;  // String | The workflow instance ID for which the user task instances are returned. The workflow instance ID is 36 characters long. (optional) 
            var workflowDefinitionId = workflowDefinitionId_example;  // String | The workflow definition ID for which the user task instances are returned. (optional) 
            var processor = processor_example;  // String | The processor of the user task instance. (optional) 
            var id = id_example;  // String | The unique ID of the user task instance. The user task instance ID is 36 characters long. (optional) 
            var activityId = activityId_example;  // String | The activityId of the user task instance. This field represents the ID of the user task definition. (optional) 
            var description = description_example;  // String | The description of the user task instance in UTF-8 encoding. You must not specify texts that contain commas with this parameter. (optional) 
            var subject = subject_example;  // String | The subject of the user task instance in UTF-8 encoding. You must not specify texts that contain commas with this parameter. (optional) 
            var createdAt = createdAt_example;  // String | Time when the user task instance has been created.
Evaluated using the logical 'or' operator with the values of the 'createdFrom' and 'createdUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional) 
            var createdFrom = createdFrom_example;  // String | The start time (inclusive) of the time range when the user task instance was created.
Must be less or equal to the value of the 'createdUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'createdAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional) 
            var createdUpTo = createdUpTo_example;  // String | The end time (inclusive) of the time range when the user task instance was created.
Must be greater or equal to the value of the 'createdFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'createdAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional) 
            var claimedAt = claimedAt_example;  // String | Time when the user task instance was claimed.
Evaluated using the logical 'or' operator with the values of the 'claimedFrom' and 'claimedUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional) 
            var claimedFrom = claimedFrom_example;  // String | The start time (inclusive) of the time range when the user task instance was claimed.
Must be less or equal to the value of the 'claimedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'claimedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional) 
            var claimedUpTo = claimedUpTo_example;  // String | The end time (inclusive) of the time range when the user task instance was claimed.
Must be greater or equal to the value of the 'claimedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'claimedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional) 
            var completedAt = completedAt_example;  // String | Time when the user task instance was COMPLETED or CANCELED.
Evaluated using the logical 'or' operator with the values of the 'completedFrom' and 'completedUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional) 
            var completedFrom = completedFrom_example;  // String | The start time (inclusive) of the time range when the user task instance was COMPLETED or CANCELED.
Must be less or equal to the value of the 'completedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'completedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional) 
            var completedUpTo = completedUpTo_example;  // String | The end time (inclusive) of the time range when the user task instance was COMPLETED or CANCELED.
Must be greater or equal to the value of the 'completedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'completedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional) 
            var lastChangedAt = lastChangedAt_example;  // String | Time when the user task instance has been changed for the last time.
Evaluated using the logical 'or' operator with the values of the 'lastChangedFrom' and 'lastChangedTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional) 
            var lastChangedFrom = lastChangedFrom_example;  // String | The start time (inclusive) of the time range when the user task instance was changed for the last time.
Must be less or equal to the value of the 'lastChangedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'lastChangedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional) 
            var lastChangedUpTo = lastChangedUpTo_example;  // String | The end time (inclusive) of the time range when the user task instance was changed for the last time.
Must be greater or equal to the value of the 'lastChangedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'lastChangedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional) 
            var dueDate = dueDate_example;  // String | The due date of the user task instance.
Evaluated using the logical 'or' operator with the values of the 'dueDateFrom' and 'dueDateUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional) 
            var dueDateFrom = dueDateFrom_example;  // String | The start time (inclusive) of the due date time range for the user task instance.
Must be less or equal to the value of the 'dueDateUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'dueDate' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional) 
            var dueDateUpTo = dueDateUpTo_example;  // String | The end time (inclusive) of the due date time range for the user task instance.
Must be greater or equal to the 'dueDateFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'dueDate' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional) 
            var priority = priority_example;  // String | The priority of the user task instance.
The values are case-insensitive.
 (optional) 
            var status = status_example;  // String | The status of the user task instance.
The values are case-insensitive.
 (optional) 
            var recipientUsers = recipientUsers_example;  // String | The users who must be among the recipient users of the user task instance. A user task instance has to match at least one of the recipient users specified.
Specify the users by repeating this parameter multiple times, with one user each. 
 (optional) 
            var recipientGroups = recipientGroups_example;  // String | The groups which must be among the recipient groups of the user task instance. A user task instance has to match at least one of the recipient groups specified.
Specify the groups by repeating this parameter multiple times, with one user each. 
 (optional) 
            var containsText = containsText_example;  // String | Text, which should be contained in at least one of the following fields of the user task instance:

 * subject
 * description
 * activityId
 * id
 * processor
 * workflowDefinitionId
 * workflowInstanceId

Performed filtering is case-insensitive. You must not use this parameter more than once.
 (optional) 
            var attributes.ExampleCustomAttribute = attributes.ExampleCustomAttribute_example;  // String | Example of a parameter that filters task instances by the value of the custom attribute with the ID 'ExampleCustomAttribute'.
You can specify parameters for other attributes in an analogous way.
If you specify a parameter several times, the logical operators apply as outlined in the overall description of this API.
If attributes with different IDs are present in the URL, only tasks which contain all of them with the values specified will be returned as a response to the request.
If a query by custom attributes matches too many task definitions, you have to limit the query further. Refer, for example, to parameter 'definitionId'.
 (optional) 
            var definitionId = definitionId_example;  // String | The definition ID of the user task.
It consists of the ID of the task defined in the workflow definition (task definition ID) as well as the workflow definition ID delimited by an '@' sign.
For optimal performance, specify this parameter when searching for tasks by custom attributes.
If the custom attribute IDs from the query match more than 50 task definitions, you have to specify one or more task definition IDs when searching for tasks by custom attributes.
 (optional) 

            try
            {
                // Retrieve instances by query parameters
                TaskInstanceList result = apiInstance.v1TaskInstancesGet($skip, $top, $inlinecount, $expand, $orderby, workflowInstanceId, workflowDefinitionId, processor, id, activityId, description, subject, createdAt, createdFrom, createdUpTo, claimedAt, claimedFrom, claimedUpTo, completedAt, completedFrom, completedUpTo, lastChangedAt, lastChangedFrom, lastChangedUpTo, dueDate, dueDateFrom, dueDateUpTo, priority, status, recipientUsers, recipientGroups, containsText, attributes.ExampleCustomAttribute, definitionId);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling UserTaskInstancesApi.v1TaskInstancesGet: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
Swagger\Client\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Swagger\Client\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Swagger\Client\Api\UserTaskInstancesApi();
$$skip = 56; // Integer | The number of records you want to skip from the beginning.
You can skip at most 4000 records. To indicate a result range that starts, for example, at 1001, combine the $skip with the $top parameter.
If not specified, no records are skipped. You can use this parameter only once.
Refer also to the $top parameter.
$$top = 56; // Integer | The number of records you want to show.
You can get at most 1000 records per API call. To indicate a result range that starts, for example, at 1001, combine the $top with the $skip parameter.
If not specified, 100 records are returned. You can use this parameter only once.
Refer also to the $skip parameter.
$$inlinecount = $inlinecount_example; // String | Specify whether the total count of the task instances, which match the search criteria, should be returned as a value 
of the X-Total-Count response header. To enable the header, use the 'allpages' setting. To disable the header, use the 'none' setting.
The values are case-sensitive. You can use this parameter only once.
$$expand = $expand_example; // String | You can request task attributes to become part of the task output by specifying the value 'attributes' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributes' field is not included into task output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where these attributes are present.

$$orderby = $orderby_example; // String | The attribute and direction by which tasks are sorted. The sort attribute and direction are separated by a space.
The parameter value is case-sensitive. You can only specify one ordering parameter, which contains attribute and direction.
To stabilize the order of tasks the implicit second ordering parameter 'createdAt asc' is applied.

 * claimedAt asc - Ascending, task claim time from the oldest to the most recent, tasks with status READY (not yet claimed) first.
 * claimedAt desc - Descending, from the most recently claimed tasks to the oldest ones, tasks with status READY (not yet claimed) last.
 * completedAt asc - Ascending, task completion or cancelation time from the oldest to the most recent, not yet COMPLETED tasks first.
 * completedAt desc - Descending, from the most recently COMPLETED or CANCELED tasks to the oldest ones, not yet COMPLETED tasks last.
 * createdAt asc - Ascending, task creation time from the oldest to the most recent.
 * createdAt desc - Descending, from the most recently created tasks to the oldest ones.
 * lastChangedAt asc - Ascending, task last change time from the oldest to the most recent.
 * lastChangedAt desc - Descending, from the most recently changed tasks to the oldest ones.             
 * dueDate asc - Ascending, tasks due date from the oldest to the most distant in future ones, tasks without due date first.
 * dueDate desc - Descending, tasks due date from the most distant in future to the oldest ones, tasks without due date last.
 * subject asc - Ascending, from A to Z case-sensitive.
 * subject desc - Descending, from Z to A case-sensitive.
 * description asc - Ascending, from A to Z case-sensitive, tasks without description first.
 * description desc - Descending, from Z to A case-sensitive, tasks without description last.
 * activityId asc - Ascending, from A to Z case-sensitive.
 * activityId desc - Descending, from Z to A case-sensitive.
 * id asc - Ascending, from A to Z case-sensitive.
 * id desc - Descending, from Z to A case-sensitive.
 * processor asc - Ascending, from A to Z case-sensitive, tasks without processor first.
 * processor desc - Descending, from Z to A case-sensitive, tasks without processor last.
 * workflowDefinitionId asc - Ascending, from A to Z case-sensitive.
 * workflowDefinitionId desc - Descending, from Z to A case-sensitive.
 * workflowInstanceId asc - Ascending, from A to Z case-sensitive.
 * workflowInstanceId desc - Descending, from Z to A case-sensitive.
 * priority asc - Ascending, tasks priority from lowest to highest.
 * priority desc - Descending, tasks priority from highest to lowest.
$workflowInstanceId = workflowInstanceId_example; // String | The workflow instance ID for which the user task instances are returned. The workflow instance ID is 36 characters long.
$workflowDefinitionId = workflowDefinitionId_example; // String | The workflow definition ID for which the user task instances are returned.
$processor = processor_example; // String | The processor of the user task instance.
$id = id_example; // String | The unique ID of the user task instance. The user task instance ID is 36 characters long.
$activityId = activityId_example; // String | The activityId of the user task instance. This field represents the ID of the user task definition.
$description = description_example; // String | The description of the user task instance in UTF-8 encoding. You must not specify texts that contain commas with this parameter.
$subject = subject_example; // String | The subject of the user task instance in UTF-8 encoding. You must not specify texts that contain commas with this parameter.
$createdAt = createdAt_example; // String | Time when the user task instance has been created.
Evaluated using the logical 'or' operator with the values of the 'createdFrom' and 'createdUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

$createdFrom = createdFrom_example; // String | The start time (inclusive) of the time range when the user task instance was created.
Must be less or equal to the value of the 'createdUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'createdAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

$createdUpTo = createdUpTo_example; // String | The end time (inclusive) of the time range when the user task instance was created.
Must be greater or equal to the value of the 'createdFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'createdAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

$claimedAt = claimedAt_example; // String | Time when the user task instance was claimed.
Evaluated using the logical 'or' operator with the values of the 'claimedFrom' and 'claimedUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

$claimedFrom = claimedFrom_example; // String | The start time (inclusive) of the time range when the user task instance was claimed.
Must be less or equal to the value of the 'claimedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'claimedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

$claimedUpTo = claimedUpTo_example; // String | The end time (inclusive) of the time range when the user task instance was claimed.
Must be greater or equal to the value of the 'claimedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'claimedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

$completedAt = completedAt_example; // String | Time when the user task instance was COMPLETED or CANCELED.
Evaluated using the logical 'or' operator with the values of the 'completedFrom' and 'completedUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

$completedFrom = completedFrom_example; // String | The start time (inclusive) of the time range when the user task instance was COMPLETED or CANCELED.
Must be less or equal to the value of the 'completedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'completedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

$completedUpTo = completedUpTo_example; // String | The end time (inclusive) of the time range when the user task instance was COMPLETED or CANCELED.
Must be greater or equal to the value of the 'completedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'completedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

$lastChangedAt = lastChangedAt_example; // String | Time when the user task instance has been changed for the last time.
Evaluated using the logical 'or' operator with the values of the 'lastChangedFrom' and 'lastChangedTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

$lastChangedFrom = lastChangedFrom_example; // String | The start time (inclusive) of the time range when the user task instance was changed for the last time.
Must be less or equal to the value of the 'lastChangedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'lastChangedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

$lastChangedUpTo = lastChangedUpTo_example; // String | The end time (inclusive) of the time range when the user task instance was changed for the last time.
Must be greater or equal to the value of the 'lastChangedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'lastChangedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

$dueDate = dueDate_example; // String | The due date of the user task instance.
Evaluated using the logical 'or' operator with the values of the 'dueDateFrom' and 'dueDateUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

$dueDateFrom = dueDateFrom_example; // String | The start time (inclusive) of the due date time range for the user task instance.
Must be less or equal to the value of the 'dueDateUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'dueDate' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

$dueDateUpTo = dueDateUpTo_example; // String | The end time (inclusive) of the due date time range for the user task instance.
Must be greater or equal to the 'dueDateFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'dueDate' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

$priority = priority_example; // String | The priority of the user task instance.
The values are case-insensitive.

$status = status_example; // String | The status of the user task instance.
The values are case-insensitive.

$recipientUsers = recipientUsers_example; // String | The users who must be among the recipient users of the user task instance. A user task instance has to match at least one of the recipient users specified.
Specify the users by repeating this parameter multiple times, with one user each. 

$recipientGroups = recipientGroups_example; // String | The groups which must be among the recipient groups of the user task instance. A user task instance has to match at least one of the recipient groups specified.
Specify the groups by repeating this parameter multiple times, with one user each. 

$containsText = containsText_example; // String | Text, which should be contained in at least one of the following fields of the user task instance:

 * subject
 * description
 * activityId
 * id
 * processor
 * workflowDefinitionId
 * workflowInstanceId

Performed filtering is case-insensitive. You must not use this parameter more than once.

$attributes.ExampleCustomAttribute = attributes.ExampleCustomAttribute_example; // String | Example of a parameter that filters task instances by the value of the custom attribute with the ID 'ExampleCustomAttribute'.
You can specify parameters for other attributes in an analogous way.
If you specify a parameter several times, the logical operators apply as outlined in the overall description of this API.
If attributes with different IDs are present in the URL, only tasks which contain all of them with the values specified will be returned as a response to the request.
If a query by custom attributes matches too many task definitions, you have to limit the query further. Refer, for example, to parameter 'definitionId'.

$definitionId = definitionId_example; // String | The definition ID of the user task.
It consists of the ID of the task defined in the workflow definition (task definition ID) as well as the workflow definition ID delimited by an '@' sign.
For optimal performance, specify this parameter when searching for tasks by custom attributes.
If the custom attribute IDs from the query match more than 50 task definitions, you have to specify one or more task definition IDs when searching for tasks by custom attributes.


try {
    $result = $api_instance->v1TaskInstancesGet($$skip, $$top, $$inlinecount, $$expand, $$orderby, $workflowInstanceId, $workflowDefinitionId, $processor, $id, $activityId, $description, $subject, $createdAt, $createdFrom, $createdUpTo, $claimedAt, $claimedFrom, $claimedUpTo, $completedAt, $completedFrom, $completedUpTo, $lastChangedAt, $lastChangedFrom, $lastChangedUpTo, $dueDate, $dueDateFrom, $dueDateUpTo, $priority, $status, $recipientUsers, $recipientGroups, $containsText, $attributes.ExampleCustomAttribute, $definitionId);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling UserTaskInstancesApi->v1TaskInstancesGet: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::UserTaskInstancesApi;

# Configure HTTP basic authorization: BasicAuthentication
$WWW::SwaggerClient::Configuration::username = 'YOUR_USERNAME';
$WWW::SwaggerClient::Configuration::password = 'YOUR_PASSWORD';
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

my $api_instance = WWW::SwaggerClient::UserTaskInstancesApi->new();
my $$skip = 56; # Integer | The number of records you want to skip from the beginning.
You can skip at most 4000 records. To indicate a result range that starts, for example, at 1001, combine the $skip with the $top parameter.
If not specified, no records are skipped. You can use this parameter only once.
Refer also to the $top parameter.
my $$top = 56; # Integer | The number of records you want to show.
You can get at most 1000 records per API call. To indicate a result range that starts, for example, at 1001, combine the $top with the $skip parameter.
If not specified, 100 records are returned. You can use this parameter only once.
Refer also to the $skip parameter.
my $$inlinecount = $inlinecount_example; # String | Specify whether the total count of the task instances, which match the search criteria, should be returned as a value 
of the X-Total-Count response header. To enable the header, use the 'allpages' setting. To disable the header, use the 'none' setting.
The values are case-sensitive. You can use this parameter only once.
my $$expand = $expand_example; # String | You can request task attributes to become part of the task output by specifying the value 'attributes' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributes' field is not included into task output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where these attributes are present.

my $$orderby = $orderby_example; # String | The attribute and direction by which tasks are sorted. The sort attribute and direction are separated by a space.
The parameter value is case-sensitive. You can only specify one ordering parameter, which contains attribute and direction.
To stabilize the order of tasks the implicit second ordering parameter 'createdAt asc' is applied.

 * claimedAt asc - Ascending, task claim time from the oldest to the most recent, tasks with status READY (not yet claimed) first.
 * claimedAt desc - Descending, from the most recently claimed tasks to the oldest ones, tasks with status READY (not yet claimed) last.
 * completedAt asc - Ascending, task completion or cancelation time from the oldest to the most recent, not yet COMPLETED tasks first.
 * completedAt desc - Descending, from the most recently COMPLETED or CANCELED tasks to the oldest ones, not yet COMPLETED tasks last.
 * createdAt asc - Ascending, task creation time from the oldest to the most recent.
 * createdAt desc - Descending, from the most recently created tasks to the oldest ones.
 * lastChangedAt asc - Ascending, task last change time from the oldest to the most recent.
 * lastChangedAt desc - Descending, from the most recently changed tasks to the oldest ones.             
 * dueDate asc - Ascending, tasks due date from the oldest to the most distant in future ones, tasks without due date first.
 * dueDate desc - Descending, tasks due date from the most distant in future to the oldest ones, tasks without due date last.
 * subject asc - Ascending, from A to Z case-sensitive.
 * subject desc - Descending, from Z to A case-sensitive.
 * description asc - Ascending, from A to Z case-sensitive, tasks without description first.
 * description desc - Descending, from Z to A case-sensitive, tasks without description last.
 * activityId asc - Ascending, from A to Z case-sensitive.
 * activityId desc - Descending, from Z to A case-sensitive.
 * id asc - Ascending, from A to Z case-sensitive.
 * id desc - Descending, from Z to A case-sensitive.
 * processor asc - Ascending, from A to Z case-sensitive, tasks without processor first.
 * processor desc - Descending, from Z to A case-sensitive, tasks without processor last.
 * workflowDefinitionId asc - Ascending, from A to Z case-sensitive.
 * workflowDefinitionId desc - Descending, from Z to A case-sensitive.
 * workflowInstanceId asc - Ascending, from A to Z case-sensitive.
 * workflowInstanceId desc - Descending, from Z to A case-sensitive.
 * priority asc - Ascending, tasks priority from lowest to highest.
 * priority desc - Descending, tasks priority from highest to lowest.
my $workflowInstanceId = workflowInstanceId_example; # String | The workflow instance ID for which the user task instances are returned. The workflow instance ID is 36 characters long.
my $workflowDefinitionId = workflowDefinitionId_example; # String | The workflow definition ID for which the user task instances are returned.
my $processor = processor_example; # String | The processor of the user task instance.
my $id = id_example; # String | The unique ID of the user task instance. The user task instance ID is 36 characters long.
my $activityId = activityId_example; # String | The activityId of the user task instance. This field represents the ID of the user task definition.
my $description = description_example; # String | The description of the user task instance in UTF-8 encoding. You must not specify texts that contain commas with this parameter.
my $subject = subject_example; # String | The subject of the user task instance in UTF-8 encoding. You must not specify texts that contain commas with this parameter.
my $createdAt = createdAt_example; # String | Time when the user task instance has been created.
Evaluated using the logical 'or' operator with the values of the 'createdFrom' and 'createdUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

my $createdFrom = createdFrom_example; # String | The start time (inclusive) of the time range when the user task instance was created.
Must be less or equal to the value of the 'createdUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'createdAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

my $createdUpTo = createdUpTo_example; # String | The end time (inclusive) of the time range when the user task instance was created.
Must be greater or equal to the value of the 'createdFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'createdAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

my $claimedAt = claimedAt_example; # String | Time when the user task instance was claimed.
Evaluated using the logical 'or' operator with the values of the 'claimedFrom' and 'claimedUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

my $claimedFrom = claimedFrom_example; # String | The start time (inclusive) of the time range when the user task instance was claimed.
Must be less or equal to the value of the 'claimedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'claimedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

my $claimedUpTo = claimedUpTo_example; # String | The end time (inclusive) of the time range when the user task instance was claimed.
Must be greater or equal to the value of the 'claimedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'claimedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

my $completedAt = completedAt_example; # String | Time when the user task instance was COMPLETED or CANCELED.
Evaluated using the logical 'or' operator with the values of the 'completedFrom' and 'completedUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

my $completedFrom = completedFrom_example; # String | The start time (inclusive) of the time range when the user task instance was COMPLETED or CANCELED.
Must be less or equal to the value of the 'completedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'completedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

my $completedUpTo = completedUpTo_example; # String | The end time (inclusive) of the time range when the user task instance was COMPLETED or CANCELED.
Must be greater or equal to the value of the 'completedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'completedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

my $lastChangedAt = lastChangedAt_example; # String | Time when the user task instance has been changed for the last time.
Evaluated using the logical 'or' operator with the values of the 'lastChangedFrom' and 'lastChangedTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

my $lastChangedFrom = lastChangedFrom_example; # String | The start time (inclusive) of the time range when the user task instance was changed for the last time.
Must be less or equal to the value of the 'lastChangedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'lastChangedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

my $lastChangedUpTo = lastChangedUpTo_example; # String | The end time (inclusive) of the time range when the user task instance was changed for the last time.
Must be greater or equal to the value of the 'lastChangedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'lastChangedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

my $dueDate = dueDate_example; # String | The due date of the user task instance.
Evaluated using the logical 'or' operator with the values of the 'dueDateFrom' and 'dueDateUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

my $dueDateFrom = dueDateFrom_example; # String | The start time (inclusive) of the due date time range for the user task instance.
Must be less or equal to the value of the 'dueDateUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'dueDate' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

my $dueDateUpTo = dueDateUpTo_example; # String | The end time (inclusive) of the due date time range for the user task instance.
Must be greater or equal to the 'dueDateFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'dueDate' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS

my $priority = priority_example; # String | The priority of the user task instance.
The values are case-insensitive.

my $status = status_example; # String | The status of the user task instance.
The values are case-insensitive.

my $recipientUsers = recipientUsers_example; # String | The users who must be among the recipient users of the user task instance. A user task instance has to match at least one of the recipient users specified.
Specify the users by repeating this parameter multiple times, with one user each. 

my $recipientGroups = recipientGroups_example; # String | The groups which must be among the recipient groups of the user task instance. A user task instance has to match at least one of the recipient groups specified.
Specify the groups by repeating this parameter multiple times, with one user each. 

my $containsText = containsText_example; # String | Text, which should be contained in at least one of the following fields of the user task instance:

 * subject
 * description
 * activityId
 * id
 * processor
 * workflowDefinitionId
 * workflowInstanceId

Performed filtering is case-insensitive. You must not use this parameter more than once.

my $attributes.ExampleCustomAttribute = attributes.ExampleCustomAttribute_example; # String | Example of a parameter that filters task instances by the value of the custom attribute with the ID 'ExampleCustomAttribute'.
You can specify parameters for other attributes in an analogous way.
If you specify a parameter several times, the logical operators apply as outlined in the overall description of this API.
If attributes with different IDs are present in the URL, only tasks which contain all of them with the values specified will be returned as a response to the request.
If a query by custom attributes matches too many task definitions, you have to limit the query further. Refer, for example, to parameter 'definitionId'.

my $definitionId = definitionId_example; # String | The definition ID of the user task.
It consists of the ID of the task defined in the workflow definition (task definition ID) as well as the workflow definition ID delimited by an '@' sign.
For optimal performance, specify this parameter when searching for tasks by custom attributes.
If the custom attribute IDs from the query match more than 50 task definitions, you have to specify one or more task definition IDs when searching for tasks by custom attributes.


eval { 
    my $result = $api_instance->v1TaskInstancesGet($skip => $$skip, $top => $$top, $inlinecount => $$inlinecount, $expand => $$expand, $orderby => $$orderby, workflowInstanceId => $workflowInstanceId, workflowDefinitionId => $workflowDefinitionId, processor => $processor, id => $id, activityId => $activityId, description => $description, subject => $subject, createdAt => $createdAt, createdFrom => $createdFrom, createdUpTo => $createdUpTo, claimedAt => $claimedAt, claimedFrom => $claimedFrom, claimedUpTo => $claimedUpTo, completedAt => $completedAt, completedFrom => $completedFrom, completedUpTo => $completedUpTo, lastChangedAt => $lastChangedAt, lastChangedFrom => $lastChangedFrom, lastChangedUpTo => $lastChangedUpTo, dueDate => $dueDate, dueDateFrom => $dueDateFrom, dueDateUpTo => $dueDateUpTo, priority => $priority, status => $status, recipientUsers => $recipientUsers, recipientGroups => $recipientGroups, containsText => $containsText, attributes.ExampleCustomAttribute => $attributes.ExampleCustomAttribute, definitionId => $definitionId);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling UserTaskInstancesApi->v1TaskInstancesGet: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# Configure HTTP basic authorization: BasicAuthentication
swagger_client.configuration.username = 'YOUR_USERNAME'
swagger_client.configuration.password = 'YOUR_PASSWORD'
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# create an instance of the API class
api_instance = swagger_client.UserTaskInstancesApi()
$skip = 56 # Integer | The number of records you want to skip from the beginning.
You can skip at most 4000 records. To indicate a result range that starts, for example, at 1001, combine the $skip with the $top parameter.
If not specified, no records are skipped. You can use this parameter only once.
Refer also to the $top parameter. (optional) (default to 0)
$top = 56 # Integer | The number of records you want to show.
You can get at most 1000 records per API call. To indicate a result range that starts, for example, at 1001, combine the $top with the $skip parameter.
If not specified, 100 records are returned. You can use this parameter only once.
Refer also to the $skip parameter. (optional) (default to 100)
$inlinecount = $inlinecount_example # String | Specify whether the total count of the task instances, which match the search criteria, should be returned as a value 
of the X-Total-Count response header. To enable the header, use the 'allpages' setting. To disable the header, use the 'none' setting.
The values are case-sensitive. You can use this parameter only once. (optional) (default to none)
$expand = $expand_example # String | You can request task attributes to become part of the task output by specifying the value 'attributes' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributes' field is not included into task output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where these attributes are present.
 (optional)
$orderby = $orderby_example # String | The attribute and direction by which tasks are sorted. The sort attribute and direction are separated by a space.
The parameter value is case-sensitive. You can only specify one ordering parameter, which contains attribute and direction.
To stabilize the order of tasks the implicit second ordering parameter 'createdAt asc' is applied.

 * claimedAt asc - Ascending, task claim time from the oldest to the most recent, tasks with status READY (not yet claimed) first.
 * claimedAt desc - Descending, from the most recently claimed tasks to the oldest ones, tasks with status READY (not yet claimed) last.
 * completedAt asc - Ascending, task completion or cancelation time from the oldest to the most recent, not yet COMPLETED tasks first.
 * completedAt desc - Descending, from the most recently COMPLETED or CANCELED tasks to the oldest ones, not yet COMPLETED tasks last.
 * createdAt asc - Ascending, task creation time from the oldest to the most recent.
 * createdAt desc - Descending, from the most recently created tasks to the oldest ones.
 * lastChangedAt asc - Ascending, task last change time from the oldest to the most recent.
 * lastChangedAt desc - Descending, from the most recently changed tasks to the oldest ones.             
 * dueDate asc - Ascending, tasks due date from the oldest to the most distant in future ones, tasks without due date first.
 * dueDate desc - Descending, tasks due date from the most distant in future to the oldest ones, tasks without due date last.
 * subject asc - Ascending, from A to Z case-sensitive.
 * subject desc - Descending, from Z to A case-sensitive.
 * description asc - Ascending, from A to Z case-sensitive, tasks without description first.
 * description desc - Descending, from Z to A case-sensitive, tasks without description last.
 * activityId asc - Ascending, from A to Z case-sensitive.
 * activityId desc - Descending, from Z to A case-sensitive.
 * id asc - Ascending, from A to Z case-sensitive.
 * id desc - Descending, from Z to A case-sensitive.
 * processor asc - Ascending, from A to Z case-sensitive, tasks without processor first.
 * processor desc - Descending, from Z to A case-sensitive, tasks without processor last.
 * workflowDefinitionId asc - Ascending, from A to Z case-sensitive.
 * workflowDefinitionId desc - Descending, from Z to A case-sensitive.
 * workflowInstanceId asc - Ascending, from A to Z case-sensitive.
 * workflowInstanceId desc - Descending, from Z to A case-sensitive.
 * priority asc - Ascending, tasks priority from lowest to highest.
 * priority desc - Descending, tasks priority from highest to lowest. (optional) (default to createdAt asc)
workflowInstanceId = workflowInstanceId_example # String | The workflow instance ID for which the user task instances are returned. The workflow instance ID is 36 characters long. (optional)
workflowDefinitionId = workflowDefinitionId_example # String | The workflow definition ID for which the user task instances are returned. (optional)
processor = processor_example # String | The processor of the user task instance. (optional)
id = id_example # String | The unique ID of the user task instance. The user task instance ID is 36 characters long. (optional)
activityId = activityId_example # String | The activityId of the user task instance. This field represents the ID of the user task definition. (optional)
description = description_example # String | The description of the user task instance in UTF-8 encoding. You must not specify texts that contain commas with this parameter. (optional)
subject = subject_example # String | The subject of the user task instance in UTF-8 encoding. You must not specify texts that contain commas with this parameter. (optional)
createdAt = createdAt_example # String | Time when the user task instance has been created.
Evaluated using the logical 'or' operator with the values of the 'createdFrom' and 'createdUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
createdFrom = createdFrom_example # String | The start time (inclusive) of the time range when the user task instance was created.
Must be less or equal to the value of the 'createdUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'createdAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
createdUpTo = createdUpTo_example # String | The end time (inclusive) of the time range when the user task instance was created.
Must be greater or equal to the value of the 'createdFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'createdAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
claimedAt = claimedAt_example # String | Time when the user task instance was claimed.
Evaluated using the logical 'or' operator with the values of the 'claimedFrom' and 'claimedUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
claimedFrom = claimedFrom_example # String | The start time (inclusive) of the time range when the user task instance was claimed.
Must be less or equal to the value of the 'claimedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'claimedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
claimedUpTo = claimedUpTo_example # String | The end time (inclusive) of the time range when the user task instance was claimed.
Must be greater or equal to the value of the 'claimedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'claimedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
completedAt = completedAt_example # String | Time when the user task instance was COMPLETED or CANCELED.
Evaluated using the logical 'or' operator with the values of the 'completedFrom' and 'completedUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
completedFrom = completedFrom_example # String | The start time (inclusive) of the time range when the user task instance was COMPLETED or CANCELED.
Must be less or equal to the value of the 'completedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'completedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
completedUpTo = completedUpTo_example # String | The end time (inclusive) of the time range when the user task instance was COMPLETED or CANCELED.
Must be greater or equal to the value of the 'completedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'completedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
lastChangedAt = lastChangedAt_example # String | Time when the user task instance has been changed for the last time.
Evaluated using the logical 'or' operator with the values of the 'lastChangedFrom' and 'lastChangedTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
lastChangedFrom = lastChangedFrom_example # String | The start time (inclusive) of the time range when the user task instance was changed for the last time.
Must be less or equal to the value of the 'lastChangedUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'lastChangedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
lastChangedUpTo = lastChangedUpTo_example # String | The end time (inclusive) of the time range when the user task instance was changed for the last time.
Must be greater or equal to the value of the 'lastChangedFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'lastChangedAt' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
dueDate = dueDate_example # String | The due date of the user task instance.
Evaluated using the logical 'or' operator with the values of the 'dueDateFrom' and 'dueDateUpTo' parameters if they are specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
dueDateFrom = dueDateFrom_example # String | The start time (inclusive) of the due date time range for the user task instance.
Must be less or equal to the value of the 'dueDateUpTo' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'dueDate' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
dueDateUpTo = dueDateUpTo_example # String | The end time (inclusive) of the due date time range for the user task instance.
Must be greater or equal to the 'dueDateFrom' parameter if the latter is specified.
Evaluated using the logical 'or' operator with the value of the 'dueDate' parameter if the latter is specified.

Supports two date formats:
1. yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
2. yyyyMMddHHmmss.SSS
 (optional)
priority = priority_example # String | The priority of the user task instance.
The values are case-insensitive.
 (optional)
status = status_example # String | The status of the user task instance.
The values are case-insensitive.
 (optional)
recipientUsers = recipientUsers_example # String | The users who must be among the recipient users of the user task instance. A user task instance has to match at least one of the recipient users specified.
Specify the users by repeating this parameter multiple times, with one user each. 
 (optional)
recipientGroups = recipientGroups_example # String | The groups which must be among the recipient groups of the user task instance. A user task instance has to match at least one of the recipient groups specified.
Specify the groups by repeating this parameter multiple times, with one user each. 
 (optional)
containsText = containsText_example # String | Text, which should be contained in at least one of the following fields of the user task instance:

 * subject
 * description
 * activityId
 * id
 * processor
 * workflowDefinitionId
 * workflowInstanceId

Performed filtering is case-insensitive. You must not use this parameter more than once.
 (optional)
attributes.ExampleCustomAttribute = attributes.ExampleCustomAttribute_example # String | Example of a parameter that filters task instances by the value of the custom attribute with the ID 'ExampleCustomAttribute'.
You can specify parameters for other attributes in an analogous way.
If you specify a parameter several times, the logical operators apply as outlined in the overall description of this API.
If attributes with different IDs are present in the URL, only tasks which contain all of them with the values specified will be returned as a response to the request.
If a query by custom attributes matches too many task definitions, you have to limit the query further. Refer, for example, to parameter 'definitionId'.
 (optional)
definitionId = definitionId_example # String | The definition ID of the user task.
It consists of the ID of the task defined in the workflow definition (task definition ID) as well as the workflow definition ID delimited by an '@' sign.
For optimal performance, specify this parameter when searching for tasks by custom attributes.
If the custom attribute IDs from the query match more than 50 task definitions, you have to specify one or more task definition IDs when searching for tasks by custom attributes.
 (optional)

try: 
    # Retrieve instances by query parameters
    api_response = api_instance.v1TaskInstancesGet($skip=$skip, $top=$top, $inlinecount=$inlinecount, $expand=$expand, $orderby=$orderby, workflowInstanceId=workflowInstanceId, workflowDefinitionId=workflowDefinitionId, processor=processor, id=id, activityId=activityId, description=description, subject=subject, createdAt=createdAt, createdFrom=createdFrom, createdUpTo=createdUpTo, claimedAt=claimedAt, claimedFrom=claimedFrom, claimedUpTo=claimedUpTo, completedAt=completedAt, completedFrom=completedFrom, completedUpTo=completedUpTo, lastChangedAt=lastChangedAt, lastChangedFrom=lastChangedFrom, lastChangedUpTo=lastChangedUpTo, dueDate=dueDate, dueDateFrom=dueDateFrom, dueDateUpTo=dueDateUpTo, priority=priority, status=status, recipientUsers=recipientUsers, recipientGroups=recipientGroups, containsText=containsText, attributes.ExampleCustomAttribute=attributes.ExampleCustomAttribute, definitionId=definitionId)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling UserTaskInstancesApi->v1TaskInstancesGet: %s\n" % e)

Parameters

Query parameters
Name Description
$skip
$top
$inlinecount
$expand
$orderby
workflowInstanceId
workflowDefinitionId
processor
id
activityId
description
subject
createdAt
createdFrom
createdUpTo
claimedAt
claimedFrom
claimedUpTo
completedAt
completedFrom
completedUpTo
lastChangedAt
lastChangedFrom
lastChangedUpTo
dueDate
dueDateFrom
dueDateUpTo
priority
status
recipientUsers
recipientGroups
containsText
attributes.ExampleCustomAttribute
definitionId

Responses

Status: 200 - Returns a list of user task instances.

[{activityId=usertask1, claimedAt=2017-03-08T17:26:51.637Z, completedAt=2017-03-08T17:26:51.643Z, createdAt=2017-03-08T17:26:51.577Z, description=A very important task, id=1d8e6a7a-03f6-11e7-873d-00163e2ab1ae, priority=VERY_HIGH, dueDate=2017-03-09T19:48:30.281Z, processor=UserId1, recipientUsers=[], recipientGroups=[Admins, Managers], status=COMPLETED, subject=First Task, workflowDefinitionId=myfirstworkflow, workflowInstanceId=1d4f3e91-03f6-11e7-873d-00163e2ab1ae}, {activityId=usertask1, claimedAt=2017-03-08T17:26:51.637Z, completedAt=2017-03-08T17:26:51.643Z, createdAt=2017-03-08T17:26:51.577Z, description=A very important task, id=1d8e6a7a-03f6-11e7-873d-00163e2ab1ae, priority=VERY_HIGH, processor=UserId1, recipientUsers=[UserId1, UserId13], status=CANCELED, subject=First Task, workflowDefinitionId=myfirstworkflow, workflowInstanceId=1d4f3e91-03f6-11e7-873d-00163e2ab1ae}, {activityId=usertask2, createdAt=2017-03-08T17:26:51.675Z, description=An important task, id=a8a6c8ae-03f6-11e7-873d-00163e2ab1ae, priority=HIGH, dueDate=2017-03-10T12:00:21.382Z, recipientUsers=[UserId1], recipientGroups=[], status=READY, subject=Second Task, workflowDefinitionId=myfirstworkflow, workflowInstanceId=1d4f3e91-03f6-11e7-873d-00163e2ab1ae, definitionId=usertask1@myfirstworkflow}, {activityId=usertask3, claimedAt=2017-03-09T07:26:51.675Z, createdAt=2017-03-08T17:26:51.675Z, description=A task that is already claimed, id=a8a6c8ae-13f6-11e7-873d-20163e2ab1ae, priority=MEDIUM, processor=UserId1, recipientUsers=[UserId1], recipientGroups=[Admins], status=RESERVED, subject=Second Task, workflowDefinitionId=myfirstworkflow, workflowInstanceId=1d4f3e91-03f6-11e7-873d-00163e2ab1ae, definitionId=usertask3@myfirstworkflow}]

Status: 400 - Incorrect format or structure of the provided request body.

{error={code=bpm.workflowruntime.rest.content.format.invalid, message=Unable to parse the request content because it has an unexpected format or structure., logId=e329b2a4-cac7-44d7-b5c5-0494e6fbad5a}}

Status: 403 - Access forbidden. You do not have the required permissions to access the resource.

{error={message=User does not have sufficient privileges.}}

Status: 404 - URL not found. Check whether the URL is correct and whether you refer to an existing task instance.

{error={code=bpm.workflowruntime.rest.task.not.found, message=Task not found, logId=d9abb62e-837b-465b-a77b-4821e21fc21d}}

Status: 429 - Too many requests. You've reached the usage limits that are configured for your tenant. Reduce the number of requests.

Status: 500 - Internal server error. The operation you requested led to an error during execution.

{error={code=bpm.workflowruntime.rest.internal.server.error, message=Internal server error, logId=f29a5719-3342-4a4a-8a3d-5ddd5253159e}}

/v1/task-instances/{taskInstanceId}/attributes

Retrieves attributes of a user task. Labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where these attributes are present. Roles permitted to execute this operation: - Global roles: WorkflowViewer, WorkflowAdmin - Instance-specific roles: viewerUsers, viewerGroups, adminUsers, adminGroups [Prerequisite: You are assigned to the WorkflowParticipant global role.] - Task-specific roles: recipientUsers, recipientGroups [Prerequisite: You are assigned to the WorkflowParticipant global role.]


/v1/task-instances/{taskInstanceId}/attributes

Usage

curl -X GET -H "Accept: application/json" -H "Content-Type: application/json" -H "Authorization: Basic [[basicHash]]" "https://sandbox.api.sap.com/workflow-service/rest/v1/task-instances/{taskInstanceId}/attributes"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.UserTaskInstancesApi;

import java.io.File;
import java.util.*;

public class UserTaskInstancesApiExample {

    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure HTTP basic authorization: BasicAuthentication
        HttpBasicAuth BasicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("BasicAuthentication");
        BasicAuthentication.setUsername("YOUR USERNAME");
        BasicAuthentication.setPassword("YOUR PASSWORD");

        // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
        OAuth Oauth2_AuthorizationCode = (OAuth) defaultClient.getAuthentication("Oauth2_AuthorizationCode");
        Oauth2_AuthorizationCode.setAccessToken("YOUR ACCESS TOKEN");

        // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
        OAuth Oauth2_ClientCredentials = (OAuth) defaultClient.getAuthentication("Oauth2_ClientCredentials");
        Oauth2_ClientCredentials.setAccessToken("YOUR ACCESS TOKEN");

        UserTaskInstancesApi apiInstance = new UserTaskInstancesApi();
        String taskInstanceId = taskInstanceId_example; // String | The ID of the user task instance for which the attributes should be retrieved. The ID is 36 characters long.
        try {
            TaskAttributeList result = apiInstance.v1TaskInstancesTaskInstanceIdAttributesGet(taskInstanceId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserTaskInstancesApi#v1TaskInstancesTaskInstanceIdAttributesGet");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.UserTaskInstancesApi;

public class UserTaskInstancesApiExample {

    public static void main(String[] args) {
        UserTaskInstancesApi apiInstance = new UserTaskInstancesApi();
        String taskInstanceId = taskInstanceId_example; // String | The ID of the user task instance for which the attributes should be retrieved. The ID is 36 characters long.
        try {
            TaskAttributeList result = apiInstance.v1TaskInstancesTaskInstanceIdAttributesGet(taskInstanceId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserTaskInstancesApi#v1TaskInstancesTaskInstanceIdAttributesGet");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];
// Configure HTTP basic authorization (authentication scheme: BasicAuthentication)
[apiConfig setUsername:@"YOUR_USERNAME"];
[apiConfig setPassword:@"YOUR_PASSWORD"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_AuthorizationCode)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_ClientCredentials)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

String *taskInstanceId = taskInstanceId_example; // The ID of the user task instance for which the attributes should be retrieved. The ID is 36 characters long.

UserTaskInstancesApi *apiInstance = [[UserTaskInstancesApi alloc] init];

// Retrieve task attributes by task instance ID
[apiInstance v1TaskInstancesTaskInstanceIdAttributesGetWith:taskInstanceId
              completionHandler: ^(TaskAttributeList output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var WorkflowApiForNeo = require('workflow_api_for_neo');
var defaultClient = WorkflowApiForNeo.ApiClient.instance;

// Configure HTTP basic authorization: BasicAuthentication
var BasicAuthentication = defaultClient.authentications['BasicAuthentication'];
BasicAuthentication.username = 'YOUR USERNAME'
BasicAuthentication.password = 'YOUR PASSWORD'

// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
var Oauth2_AuthorizationCode = defaultClient.authentications['Oauth2_AuthorizationCode'];
Oauth2_AuthorizationCode.accessToken = "YOUR ACCESS TOKEN"

// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
var Oauth2_ClientCredentials = defaultClient.authentications['Oauth2_ClientCredentials'];
Oauth2_ClientCredentials.accessToken = "YOUR ACCESS TOKEN"

var api = new WorkflowApiForNeo.UserTaskInstancesApi()

var taskInstanceId = taskInstanceId_example; // {String} The ID of the user task instance for which the attributes should be retrieved. The ID is 36 characters long.


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.v1TaskInstancesTaskInstanceIdAttributesGet(taskInstanceId, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class v1TaskInstancesTaskInstanceIdAttributesGetExample
    {
        public void main()
        {
            
            // Configure HTTP basic authorization: BasicAuthentication
            Configuration.Default.Username = "YOUR_USERNAME";
            Configuration.Default.Password = "YOUR_PASSWORD";
            // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
            // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            var apiInstance = new UserTaskInstancesApi();
            var taskInstanceId = taskInstanceId_example;  // String | The ID of the user task instance for which the attributes should be retrieved. The ID is 36 characters long.

            try
            {
                // Retrieve task attributes by task instance ID
                TaskAttributeList result = apiInstance.v1TaskInstancesTaskInstanceIdAttributesGet(taskInstanceId);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling UserTaskInstancesApi.v1TaskInstancesTaskInstanceIdAttributesGet: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
Swagger\Client\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Swagger\Client\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Swagger\Client\Api\UserTaskInstancesApi();
$taskInstanceId = taskInstanceId_example; // String | The ID of the user task instance for which the attributes should be retrieved. The ID is 36 characters long.

try {
    $result = $api_instance->v1TaskInstancesTaskInstanceIdAttributesGet($taskInstanceId);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling UserTaskInstancesApi->v1TaskInstancesTaskInstanceIdAttributesGet: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::UserTaskInstancesApi;

# Configure HTTP basic authorization: BasicAuthentication
$WWW::SwaggerClient::Configuration::username = 'YOUR_USERNAME';
$WWW::SwaggerClient::Configuration::password = 'YOUR_PASSWORD';
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

my $api_instance = WWW::SwaggerClient::UserTaskInstancesApi->new();
my $taskInstanceId = taskInstanceId_example; # String | The ID of the user task instance for which the attributes should be retrieved. The ID is 36 characters long.

eval { 
    my $result = $api_instance->v1TaskInstancesTaskInstanceIdAttributesGet(taskInstanceId => $taskInstanceId);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling UserTaskInstancesApi->v1TaskInstancesTaskInstanceIdAttributesGet: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# Configure HTTP basic authorization: BasicAuthentication
swagger_client.configuration.username = 'YOUR_USERNAME'
swagger_client.configuration.password = 'YOUR_PASSWORD'
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# create an instance of the API class
api_instance = swagger_client.UserTaskInstancesApi()
taskInstanceId = taskInstanceId_example # String | The ID of the user task instance for which the attributes should be retrieved. The ID is 36 characters long.

try: 
    # Retrieve task attributes by task instance ID
    api_response = api_instance.v1TaskInstancesTaskInstanceIdAttributesGet(taskInstanceId)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling UserTaskInstancesApi->v1TaskInstancesTaskInstanceIdAttributesGet: %s\n" % e)

Parameters

Path parameters
Name Description
taskInstanceId*

Responses

Status: 200 - Returns the task attributes for the requested user task.

[{id=ExampleCustomAttribute, label=Example of custom attribute, value=PRO_247, type=string}, {id=Cur, label=Currency, value=EUR, type=string}]

Status: 403 - Access forbidden. You do not have the required permissions to access the resource.

{error={message=User does not have sufficient privileges.}}

Status: 404 - URL not found. Check whether the URL is correct and whether you refer to an existing task instance.

{error={code=bpm.workflowruntime.rest.task.not.found, message=Task not found, logId=d9abb62e-837b-465b-a77b-4821e21fc21d}}

Status: 429 - Too many requests. You've reached the usage limits that are configured for your tenant. Reduce the number of requests.

Status: 500 - Internal server error. The operation you requested led to an error during execution.

{error={code=bpm.workflowruntime.rest.internal.server.error, message=Internal server error, logId=f29a5719-3342-4a4a-8a3d-5ddd5253159e}}

/v1/task-instances/{taskInstanceId}/context

**Warning: Users with the role "WorkflowAdmin" are no longer able to view the task context. To allow these users to continue to view the context, assign the role "WorkflowContextViewer" to them.** Retrieves the context of a user task. Roles permitted to execute this operation: - Global roles: WorkflowContextViewer, WorkflowContextAdmin - Instance-specific roles: contextViewerUsers, contextViewerGroups, contextAdminUsers, contextAdminGroups [Prerequisite: You are assigned to the WorkflowParticipant global role.] - Task-specific roles: recipientUsers, recipientGroups [Prerequisite: You are assigned to the WorkflowParticipant global role.]


/v1/task-instances/{taskInstanceId}/context

Usage

curl -X GET -H "Accept: application/json" -H "Content-Type: application/json" -H "Authorization: Basic [[basicHash]]" "https://sandbox.api.sap.com/workflow-service/rest/v1/task-instances/{taskInstanceId}/context"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.UserTaskInstancesApi;

import java.io.File;
import java.util.*;

public class UserTaskInstancesApiExample {

    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure HTTP basic authorization: BasicAuthentication
        HttpBasicAuth BasicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("BasicAuthentication");
        BasicAuthentication.setUsername("YOUR USERNAME");
        BasicAuthentication.setPassword("YOUR PASSWORD");

        // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
        OAuth Oauth2_AuthorizationCode = (OAuth) defaultClient.getAuthentication("Oauth2_AuthorizationCode");
        Oauth2_AuthorizationCode.setAccessToken("YOUR ACCESS TOKEN");

        // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
        OAuth Oauth2_ClientCredentials = (OAuth) defaultClient.getAuthentication("Oauth2_ClientCredentials");
        Oauth2_ClientCredentials.setAccessToken("YOUR ACCESS TOKEN");

        UserTaskInstancesApi apiInstance = new UserTaskInstancesApi();
        String taskInstanceId = taskInstanceId_example; // String | The ID of the user task for which the context should be retrieved. The ID is 36 characters long.
        try {
            Object result = apiInstance.v1TaskInstancesTaskInstanceIdContextGet(taskInstanceId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserTaskInstancesApi#v1TaskInstancesTaskInstanceIdContextGet");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.UserTaskInstancesApi;

public class UserTaskInstancesApiExample {

    public static void main(String[] args) {
        UserTaskInstancesApi apiInstance = new UserTaskInstancesApi();
        String taskInstanceId = taskInstanceId_example; // String | The ID of the user task for which the context should be retrieved. The ID is 36 characters long.
        try {
            Object result = apiInstance.v1TaskInstancesTaskInstanceIdContextGet(taskInstanceId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserTaskInstancesApi#v1TaskInstancesTaskInstanceIdContextGet");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];
// Configure HTTP basic authorization (authentication scheme: BasicAuthentication)
[apiConfig setUsername:@"YOUR_USERNAME"];
[apiConfig setPassword:@"YOUR_PASSWORD"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_AuthorizationCode)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_ClientCredentials)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

String *taskInstanceId = taskInstanceId_example; // The ID of the user task for which the context should be retrieved. The ID is 36 characters long.

UserTaskInstancesApi *apiInstance = [[UserTaskInstancesApi alloc] init];

// Retrieve task context by ID
[apiInstance v1TaskInstancesTaskInstanceIdContextGetWith:taskInstanceId
              completionHandler: ^(Object output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var WorkflowApiForNeo = require('workflow_api_for_neo');
var defaultClient = WorkflowApiForNeo.ApiClient.instance;

// Configure HTTP basic authorization: BasicAuthentication
var BasicAuthentication = defaultClient.authentications['BasicAuthentication'];
BasicAuthentication.username = 'YOUR USERNAME'
BasicAuthentication.password = 'YOUR PASSWORD'

// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
var Oauth2_AuthorizationCode = defaultClient.authentications['Oauth2_AuthorizationCode'];
Oauth2_AuthorizationCode.accessToken = "YOUR ACCESS TOKEN"

// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
var Oauth2_ClientCredentials = defaultClient.authentications['Oauth2_ClientCredentials'];
Oauth2_ClientCredentials.accessToken = "YOUR ACCESS TOKEN"

var api = new WorkflowApiForNeo.UserTaskInstancesApi()

var taskInstanceId = taskInstanceId_example; // {String} The ID of the user task for which the context should be retrieved. The ID is 36 characters long.


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.v1TaskInstancesTaskInstanceIdContextGet(taskInstanceId, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class v1TaskInstancesTaskInstanceIdContextGetExample
    {
        public void main()
        {
            
            // Configure HTTP basic authorization: BasicAuthentication
            Configuration.Default.Username = "YOUR_USERNAME";
            Configuration.Default.Password = "YOUR_PASSWORD";
            // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
            // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            var apiInstance = new UserTaskInstancesApi();
            var taskInstanceId = taskInstanceId_example;  // String | The ID of the user task for which the context should be retrieved. The ID is 36 characters long.

            try
            {
                // Retrieve task context by ID
                Object result = apiInstance.v1TaskInstancesTaskInstanceIdContextGet(taskInstanceId);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling UserTaskInstancesApi.v1TaskInstancesTaskInstanceIdContextGet: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
Swagger\Client\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Swagger\Client\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Swagger\Client\Api\UserTaskInstancesApi();
$taskInstanceId = taskInstanceId_example; // String | The ID of the user task for which the context should be retrieved. The ID is 36 characters long.

try {
    $result = $api_instance->v1TaskInstancesTaskInstanceIdContextGet($taskInstanceId);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling UserTaskInstancesApi->v1TaskInstancesTaskInstanceIdContextGet: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::UserTaskInstancesApi;

# Configure HTTP basic authorization: BasicAuthentication
$WWW::SwaggerClient::Configuration::username = 'YOUR_USERNAME';
$WWW::SwaggerClient::Configuration::password = 'YOUR_PASSWORD';
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

my $api_instance = WWW::SwaggerClient::UserTaskInstancesApi->new();
my $taskInstanceId = taskInstanceId_example; # String | The ID of the user task for which the context should be retrieved. The ID is 36 characters long.

eval { 
    my $result = $api_instance->v1TaskInstancesTaskInstanceIdContextGet(taskInstanceId => $taskInstanceId);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling UserTaskInstancesApi->v1TaskInstancesTaskInstanceIdContextGet: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# Configure HTTP basic authorization: BasicAuthentication
swagger_client.configuration.username = 'YOUR_USERNAME'
swagger_client.configuration.password = 'YOUR_PASSWORD'
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# create an instance of the API class
api_instance = swagger_client.UserTaskInstancesApi()
taskInstanceId = taskInstanceId_example # String | The ID of the user task for which the context should be retrieved. The ID is 36 characters long.

try: 
    # Retrieve task context by ID
    api_response = api_instance.v1TaskInstancesTaskInstanceIdContextGet(taskInstanceId)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling UserTaskInstancesApi->v1TaskInstancesTaskInstanceIdContextGet: %s\n" % e)

Parameters

Path parameters
Name Description
taskInstanceId*

Responses

Status: 200 - Returns the context of the specified user task.

{firstname=John, lastname=Doe}

Status: 403 - Access forbidden. You do not have the required permissions to access the resource.

{error={message=User does not have sufficient privileges.}}

Status: 404 - URL not found. Check whether the URL is correct and whether you refer to an existing task instance.

{error={code=bpm.workflowruntime.rest.task.not.found, message=Task not found, logId=d9abb62e-837b-465b-a77b-4821e21fc21d}}

Status: 429 - Too many requests. You've reached the usage limits that are configured for your tenant. Reduce the number of requests.

Status: 500 - Internal server error. The operation you requested led to an error during execution.

{error={code=bpm.workflowruntime.rest.internal.server.error, message=Internal server error, logId=f29a5719-3342-4a4a-8a3d-5ddd5253159e}}

/v1/task-instances/{taskInstanceId}

Retrieves the user task instance with the specified task instance ID. Roles permitted to execute this operation: - Global roles: WorkflowViewer, WorkflowAdmin - Instance-specific roles: viewerUsers, viewerGroups, adminUsers, adminGroups [Prerequisite: You are assigned to the WorkflowParticipant global role.] - Task-specific roles: recipientUsers, recipientGroups [Prerequisite: You are assigned to the WorkflowParticipant global role.]


/v1/task-instances/{taskInstanceId}

Usage

curl -X GET -H "Accept: application/json" -H "Content-Type: application/json" -H "Authorization: Basic [[basicHash]]" "https://sandbox.api.sap.com/workflow-service/rest/v1/task-instances/{taskInstanceId}?$expand="
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.UserTaskInstancesApi;

import java.io.File;
import java.util.*;

public class UserTaskInstancesApiExample {

    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure HTTP basic authorization: BasicAuthentication
        HttpBasicAuth BasicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("BasicAuthentication");
        BasicAuthentication.setUsername("YOUR USERNAME");
        BasicAuthentication.setPassword("YOUR PASSWORD");

        // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
        OAuth Oauth2_AuthorizationCode = (OAuth) defaultClient.getAuthentication("Oauth2_AuthorizationCode");
        Oauth2_AuthorizationCode.setAccessToken("YOUR ACCESS TOKEN");

        // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
        OAuth Oauth2_ClientCredentials = (OAuth) defaultClient.getAuthentication("Oauth2_ClientCredentials");
        Oauth2_ClientCredentials.setAccessToken("YOUR ACCESS TOKEN");

        UserTaskInstancesApi apiInstance = new UserTaskInstancesApi();
        String taskInstanceId = taskInstanceId_example; // String | The ID of the user task instance, which should be retrieved. The ID is 36 characters long.
        String $expand = $expand_example; // String | You can request task attributes to become part of the task output by specifying the value 'attributes' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributes' field is not included into task output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where these attributes are present.

        try {
            TaskInstance result = apiInstance.v1TaskInstancesTaskInstanceIdGet(taskInstanceId, $expand);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserTaskInstancesApi#v1TaskInstancesTaskInstanceIdGet");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.UserTaskInstancesApi;

public class UserTaskInstancesApiExample {

    public static void main(String[] args) {
        UserTaskInstancesApi apiInstance = new UserTaskInstancesApi();
        String taskInstanceId = taskInstanceId_example; // String | The ID of the user task instance, which should be retrieved. The ID is 36 characters long.
        String $expand = $expand_example; // String | You can request task attributes to become part of the task output by specifying the value 'attributes' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributes' field is not included into task output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where these attributes are present.

        try {
            TaskInstance result = apiInstance.v1TaskInstancesTaskInstanceIdGet(taskInstanceId, $expand);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserTaskInstancesApi#v1TaskInstancesTaskInstanceIdGet");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];
// Configure HTTP basic authorization (authentication scheme: BasicAuthentication)
[apiConfig setUsername:@"YOUR_USERNAME"];
[apiConfig setPassword:@"YOUR_PASSWORD"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_AuthorizationCode)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_ClientCredentials)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

String *taskInstanceId = taskInstanceId_example; // The ID of the user task instance, which should be retrieved. The ID is 36 characters long.
String *$expand = $expand_example; // You can request task attributes to become part of the task output by specifying the value 'attributes' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributes' field is not included into task output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where these attributes are present.
 (optional)

UserTaskInstancesApi *apiInstance = [[UserTaskInstancesApi alloc] init];

// Retrieve task by ID
[apiInstance v1TaskInstancesTaskInstanceIdGetWith:taskInstanceId
    $expand:$expand
              completionHandler: ^(TaskInstance output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var WorkflowApiForNeo = require('workflow_api_for_neo');
var defaultClient = WorkflowApiForNeo.ApiClient.instance;

// Configure HTTP basic authorization: BasicAuthentication
var BasicAuthentication = defaultClient.authentications['BasicAuthentication'];
BasicAuthentication.username = 'YOUR USERNAME'
BasicAuthentication.password = 'YOUR PASSWORD'

// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
var Oauth2_AuthorizationCode = defaultClient.authentications['Oauth2_AuthorizationCode'];
Oauth2_AuthorizationCode.accessToken = "YOUR ACCESS TOKEN"

// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
var Oauth2_ClientCredentials = defaultClient.authentications['Oauth2_ClientCredentials'];
Oauth2_ClientCredentials.accessToken = "YOUR ACCESS TOKEN"

var api = new WorkflowApiForNeo.UserTaskInstancesApi()

var taskInstanceId = taskInstanceId_example; // {String} The ID of the user task instance, which should be retrieved. The ID is 36 characters long.

var opts = { 
  '$expand': $expand_example // {String} You can request task attributes to become part of the task output by specifying the value 'attributes' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributes' field is not included into task output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where these attributes are present.

};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.v1TaskInstancesTaskInstanceIdGet(taskInstanceId, opts, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class v1TaskInstancesTaskInstanceIdGetExample
    {
        public void main()
        {
            
            // Configure HTTP basic authorization: BasicAuthentication
            Configuration.Default.Username = "YOUR_USERNAME";
            Configuration.Default.Password = "YOUR_PASSWORD";
            // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
            // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            var apiInstance = new UserTaskInstancesApi();
            var taskInstanceId = taskInstanceId_example;  // String | The ID of the user task instance, which should be retrieved. The ID is 36 characters long.
            var $expand = $expand_example;  // String | You can request task attributes to become part of the task output by specifying the value 'attributes' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributes' field is not included into task output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where these attributes are present.
 (optional) 

            try
            {
                // Retrieve task by ID
                TaskInstance result = apiInstance.v1TaskInstancesTaskInstanceIdGet(taskInstanceId, $expand);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling UserTaskInstancesApi.v1TaskInstancesTaskInstanceIdGet: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
Swagger\Client\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Swagger\Client\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Swagger\Client\Api\UserTaskInstancesApi();
$taskInstanceId = taskInstanceId_example; // String | The ID of the user task instance, which should be retrieved. The ID is 36 characters long.
$$expand = $expand_example; // String | You can request task attributes to become part of the task output by specifying the value 'attributes' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributes' field is not included into task output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where these attributes are present.


try {
    $result = $api_instance->v1TaskInstancesTaskInstanceIdGet($taskInstanceId, $$expand);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling UserTaskInstancesApi->v1TaskInstancesTaskInstanceIdGet: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::UserTaskInstancesApi;

# Configure HTTP basic authorization: BasicAuthentication
$WWW::SwaggerClient::Configuration::username = 'YOUR_USERNAME';
$WWW::SwaggerClient::Configuration::password = 'YOUR_PASSWORD';
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

my $api_instance = WWW::SwaggerClient::UserTaskInstancesApi->new();
my $taskInstanceId = taskInstanceId_example; # String | The ID of the user task instance, which should be retrieved. The ID is 36 characters long.
my $$expand = $expand_example; # String | You can request task attributes to become part of the task output by specifying the value 'attributes' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributes' field is not included into task output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where these attributes are present.


eval { 
    my $result = $api_instance->v1TaskInstancesTaskInstanceIdGet(taskInstanceId => $taskInstanceId, $expand => $$expand);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling UserTaskInstancesApi->v1TaskInstancesTaskInstanceIdGet: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# Configure HTTP basic authorization: BasicAuthentication
swagger_client.configuration.username = 'YOUR_USERNAME'
swagger_client.configuration.password = 'YOUR_PASSWORD'
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# create an instance of the API class
api_instance = swagger_client.UserTaskInstancesApi()
taskInstanceId = taskInstanceId_example # String | The ID of the user task instance, which should be retrieved. The ID is 36 characters long.
$expand = $expand_example # String | You can request task attributes to become part of the task output by specifying the value 'attributes' for the '$expand' parameter.
Otherwise, if the '$expand' parameter is not specified, the 'attributes' field is not included into task output. Note that labels as well as the order of the task attributes in which they are returned, are taken from the latest versions of the workflow definitions where these attributes are present.
 (optional)

try: 
    # Retrieve task by ID
    api_response = api_instance.v1TaskInstancesTaskInstanceIdGet(taskInstanceId, $expand=$expand)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling UserTaskInstancesApi->v1TaskInstancesTaskInstanceIdGet: %s\n" % e)

Parameters

Path parameters
Name Description
taskInstanceId*
Query parameters
Name Description
$expand

Responses

Status: 200 - Returns the requested user task.

{activityId=usertask1, createdAt=2017-03-08T17:26:51.675Z, description=An important task, id=a8a6c8ae-03f6-11e7-873d-00163e2ab1ae, priority=MEDIUM, dueDate=2017-03-10T12:00:21.382Z, recipientUsers=[D000001], recipientGroups=[Admins], status=READY, subject=Second Task, workflowDefinitionId=myfirstworkflow, workflowInstanceId=1d4f3e91-03f6-11e7-873d-00163e2ab1ae}

Status: 403 - Access forbidden. You do not have the required permissions to access the resource.

{error={message=User does not have sufficient privileges.}}

Status: 404 - URL not found. Check whether the URL is correct and whether you refer to an existing task instance.

{error={code=bpm.workflowruntime.rest.task.not.found, message=Task not found, logId=d9abb62e-837b-465b-a77b-4821e21fc21d}}

Status: 429 - Too many requests. You've reached the usage limits that are configured for your tenant. Reduce the number of requests.

Status: 500 - Internal server error. The operation you requested led to an error during execution.

{error={code=bpm.workflowruntime.rest.internal.server.error, message=Internal server error, logId=f29a5719-3342-4a4a-8a3d-5ddd5253159e}}

/v1/task-instances/{taskInstanceId}

Updates a user task's status, its properties (for example, subject), and its context with the attributes provided in the request body. For more information, see SAP Cloud Platform Workflow Service documentation on the [SAP Help Portal](https://help.sap.com/viewer/f85276c5069a429fa37d1cd352785c25/Cloud/en-US/fe41c54d61fa4710b34f2afe11b5d00e.html). Roles permitted to execute this operation: - Global roles: WorkflowAdmin - Instance-specific roles: adminUsers, adminGroups [Prerequisite: You are assigned to the WorkflowParticipant global role.] - Task-specific roles: recipientUsers, recipientGroups [Prerequisite: You are assigned to the WorkflowParticipant global role.]


/v1/task-instances/{taskInstanceId}

Usage

curl -X PATCH -H "Accept: application/json" -H "Content-Type: application/json" -H "Authorization: Basic [[basicHash]]" "https://sandbox.api.sap.com/workflow-service/rest/v1/task-instances/{taskInstanceId}"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.UserTaskInstancesApi;

import java.io.File;
import java.util.*;

public class UserTaskInstancesApiExample {

    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure HTTP basic authorization: BasicAuthentication
        HttpBasicAuth BasicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("BasicAuthentication");
        BasicAuthentication.setUsername("YOUR USERNAME");
        BasicAuthentication.setPassword("YOUR PASSWORD");

        // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
        OAuth Oauth2_AuthorizationCode = (OAuth) defaultClient.getAuthentication("Oauth2_AuthorizationCode");
        Oauth2_AuthorizationCode.setAccessToken("YOUR ACCESS TOKEN");

        // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
        OAuth Oauth2_ClientCredentials = (OAuth) defaultClient.getAuthentication("Oauth2_ClientCredentials");
        Oauth2_ClientCredentials.setAccessToken("YOUR ACCESS TOKEN");

        UserTaskInstancesApi apiInstance = new UserTaskInstancesApi();
        String taskInstanceId = taskInstanceId_example; // String | The ID of the user task instance, that is to be updated. The ID is 36 characters long.
        String xCSRFToken = xCSRFToken_example; // String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.
        TaskInstance_PATCH body = ; // TaskInstance_PATCH | Specify the request body according to the given schema.
The length of the request body is limited to ensure an optimal operation of the service.
        try {
            apiInstance.v1TaskInstancesTaskInstanceIdPatch(taskInstanceId, xCSRFToken, body);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserTaskInstancesApi#v1TaskInstancesTaskInstanceIdPatch");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.UserTaskInstancesApi;

public class UserTaskInstancesApiExample {

    public static void main(String[] args) {
        UserTaskInstancesApi apiInstance = new UserTaskInstancesApi();
        String taskInstanceId = taskInstanceId_example; // String | The ID of the user task instance, that is to be updated. The ID is 36 characters long.
        String xCSRFToken = xCSRFToken_example; // String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.
        TaskInstance_PATCH body = ; // TaskInstance_PATCH | Specify the request body according to the given schema.
The length of the request body is limited to ensure an optimal operation of the service.
        try {
            apiInstance.v1TaskInstancesTaskInstanceIdPatch(taskInstanceId, xCSRFToken, body);
        } catch (ApiException e) {
            System.err.println("Exception when calling UserTaskInstancesApi#v1TaskInstancesTaskInstanceIdPatch");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];
// Configure HTTP basic authorization (authentication scheme: BasicAuthentication)
[apiConfig setUsername:@"YOUR_USERNAME"];
[apiConfig setPassword:@"YOUR_PASSWORD"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_AuthorizationCode)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_ClientCredentials)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

String *taskInstanceId = taskInstanceId_example; // The ID of the user task instance, that is to be updated. The ID is 36 characters long.
String *xCSRFToken = xCSRFToken_example; // The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.
TaskInstance_PATCH *body = ; // Specify the request body according to the given schema.
The length of the request body is limited to ensure an optimal operation of the service.

UserTaskInstancesApi *apiInstance = [[UserTaskInstancesApi alloc] init];

// Update task by ID
[apiInstance v1TaskInstancesTaskInstanceIdPatchWith:taskInstanceId
    xCSRFToken:xCSRFToken
    body:body
              completionHandler: ^(NSError* error) {
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var WorkflowApiForNeo = require('workflow_api_for_neo');
var defaultClient = WorkflowApiForNeo.ApiClient.instance;

// Configure HTTP basic authorization: BasicAuthentication
var BasicAuthentication = defaultClient.authentications['BasicAuthentication'];
BasicAuthentication.username = 'YOUR USERNAME'
BasicAuthentication.password = 'YOUR PASSWORD'

// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
var Oauth2_AuthorizationCode = defaultClient.authentications['Oauth2_AuthorizationCode'];
Oauth2_AuthorizationCode.accessToken = "YOUR ACCESS TOKEN"

// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
var Oauth2_ClientCredentials = defaultClient.authentications['Oauth2_ClientCredentials'];
Oauth2_ClientCredentials.accessToken = "YOUR ACCESS TOKEN"

var api = new WorkflowApiForNeo.UserTaskInstancesApi()

var taskInstanceId = taskInstanceId_example; // {String} The ID of the user task instance, that is to be updated. The ID is 36 characters long.

var xCSRFToken = xCSRFToken_example; // {String} The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.

var body = ; // {TaskInstance_PATCH} Specify the request body according to the given schema.
The length of the request body is limited to ensure an optimal operation of the service.


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.v1TaskInstancesTaskInstanceIdPatch(taskInstanceId, xCSRFToken, body, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class v1TaskInstancesTaskInstanceIdPatchExample
    {
        public void main()
        {
            
            // Configure HTTP basic authorization: BasicAuthentication
            Configuration.Default.Username = "YOUR_USERNAME";
            Configuration.Default.Password = "YOUR_PASSWORD";
            // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
            // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            var apiInstance = new UserTaskInstancesApi();
            var taskInstanceId = taskInstanceId_example;  // String | The ID of the user task instance, that is to be updated. The ID is 36 characters long.
            var xCSRFToken = xCSRFToken_example;  // String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.
            var body = new TaskInstance_PATCH(); // TaskInstance_PATCH | Specify the request body according to the given schema.
The length of the request body is limited to ensure an optimal operation of the service.

            try
            {
                // Update task by ID
                apiInstance.v1TaskInstancesTaskInstanceIdPatch(taskInstanceId, xCSRFToken, body);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling UserTaskInstancesApi.v1TaskInstancesTaskInstanceIdPatch: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
Swagger\Client\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Swagger\Client\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Swagger\Client\Api\UserTaskInstancesApi();
$taskInstanceId = taskInstanceId_example; // String | The ID of the user task instance, that is to be updated. The ID is 36 characters long.
$xCSRFToken = xCSRFToken_example; // String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.
$body = ; // TaskInstance_PATCH | Specify the request body according to the given schema.
The length of the request body is limited to ensure an optimal operation of the service.

try {
    $api_instance->v1TaskInstancesTaskInstanceIdPatch($taskInstanceId, $xCSRFToken, $body);
} catch (Exception $e) {
    echo 'Exception when calling UserTaskInstancesApi->v1TaskInstancesTaskInstanceIdPatch: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::UserTaskInstancesApi;

# Configure HTTP basic authorization: BasicAuthentication
$WWW::SwaggerClient::Configuration::username = 'YOUR_USERNAME';
$WWW::SwaggerClient::Configuration::password = 'YOUR_PASSWORD';
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

my $api_instance = WWW::SwaggerClient::UserTaskInstancesApi->new();
my $taskInstanceId = taskInstanceId_example; # String | The ID of the user task instance, that is to be updated. The ID is 36 characters long.
my $xCSRFToken = xCSRFToken_example; # String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.
my $body = WWW::SwaggerClient::Object::TaskInstance_PATCH->new(); # TaskInstance_PATCH | Specify the request body according to the given schema.
The length of the request body is limited to ensure an optimal operation of the service.

eval { 
    $api_instance->v1TaskInstancesTaskInstanceIdPatch(taskInstanceId => $taskInstanceId, xCSRFToken => $xCSRFToken, body => $body);
};
if ($@) {
    warn "Exception when calling UserTaskInstancesApi->v1TaskInstancesTaskInstanceIdPatch: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# Configure HTTP basic authorization: BasicAuthentication
swagger_client.configuration.username = 'YOUR_USERNAME'
swagger_client.configuration.password = 'YOUR_PASSWORD'
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# create an instance of the API class
api_instance = swagger_client.UserTaskInstancesApi()
taskInstanceId = taskInstanceId_example # String | The ID of the user task instance, that is to be updated. The ID is 36 characters long.
xCSRFToken = xCSRFToken_example # String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.
body =  # TaskInstance_PATCH | Specify the request body according to the given schema.
The length of the request body is limited to ensure an optimal operation of the service.

try: 
    # Update task by ID
    api_instance.v1TaskInstancesTaskInstanceIdPatch(taskInstanceId, xCSRFToken, body)
except ApiException as e:
    print("Exception when calling UserTaskInstancesApi->v1TaskInstancesTaskInstanceIdPatch: %s\n" % e)

Parameters

Path parameters
Name Description
taskInstanceId*
Header parameters
Name Description
X-CSRF-Token*
Body parameters
Name Description
body *

Specify the request body according to the given schema. The length of the request body is limited to ensure an optimal operation of the service.

Responses

Status: 204 - Depending on the request, either the task has been COMPLETED and the context updated, or the task's properties have been updated.

Status: 400 - Incorrect format or structure of the provided request body.

{error={code=bpm.workflowruntime.rest.content.format.invalid, message=Unable to parse the request content because it has an unexpected format or structure., logId=e329b2a4-cac7-44d7-b5c5-0494e6fbad5a}}

Status: 403 - Access forbidden. You do not have the required permissions to access the resource.

{error={message=User does not have sufficient privileges.}}

Status: 404 - URL not found. Check whether the URL is correct and whether you refer to an existing task instance.

{error={code=bpm.workflowruntime.rest.task.not.found, message=Task not found, logId=d9abb62e-837b-465b-a77b-4821e21fc21d}}

Status: 422 - The task cannot be updated for one of the following reasons: The values submitted for updating the property cannot be resolved or became invalid after resolution; the context provided in the request body contains prohibited fields, or the status in the request body is invalid.

{error={code=bpm.workflowruntime.rest.task.change.property.invalid, message=Could not update task., details=[{severity=error, message=The subject could not be set, because the value submitted is too long.}, {severity=error, message=The description could not be set: syntax error at position 9.}]}}

Status: 429 - Too many requests. You've reached the usage limits that are configured for your tenant. Reduce the number of requests.

Status: 500 - Internal server error. The operation you requested led to an error during execution.

{error={code=bpm.workflowruntime.rest.internal.server.error, message=Internal server error, logId=f29a5719-3342-4a4a-8a3d-5ddd5253159e}}

WorkflowDefinitions

/v1/workflow-definitions/{definitionId}

Undeploys all versions of an existing workflow definition and deletes the corresponding workflow instances. Once the undeployment has started, you can no longer start a new workflow instance based on this workflow definition. Roles permitted to execute this operation: - Global roles: WorkflowTenantOperator


/v1/workflow-definitions/{definitionId}

Usage

curl -X DELETE -H "Accept: application/json" -H "Content-Type: application/json" -H "Authorization: Basic [[basicHash]]" "https://sandbox.api.sap.com/workflow-service/rest/v1/workflow-definitions/{definitionId}?cascade="
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.WorkflowDefinitionsApi;

import java.io.File;
import java.util.*;

public class WorkflowDefinitionsApiExample {

    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure HTTP basic authorization: BasicAuthentication
        HttpBasicAuth BasicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("BasicAuthentication");
        BasicAuthentication.setUsername("YOUR USERNAME");
        BasicAuthentication.setPassword("YOUR PASSWORD");

        // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
        OAuth Oauth2_AuthorizationCode = (OAuth) defaultClient.getAuthentication("Oauth2_AuthorizationCode");
        Oauth2_AuthorizationCode.setAccessToken("YOUR ACCESS TOKEN");

        // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
        OAuth Oauth2_ClientCredentials = (OAuth) defaultClient.getAuthentication("Oauth2_ClientCredentials");
        Oauth2_ClientCredentials.setAccessToken("YOUR ACCESS TOKEN");

        WorkflowDefinitionsApi apiInstance = new WorkflowDefinitionsApi();
        String definitionId = definitionId_example; // String | The ID of the workflow definition to be undeployed. The ID is at most 64 characters long.
        String xCSRFToken = xCSRFToken_example; // String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.
        Boolean cascade = true; // Boolean | Whether the undeployment of the workflow definition deletes active workflow instances.
If the parameter is false or not specified and there are active workflow instances for the specified workflow definition, 
the undeployment is rejected. An instance is considered active if it is in status RUNNING, ERRONEOUS, or SUSPENDED.

        try {
            apiInstance.v1WorkflowDefinitionsDefinitionIdDelete(definitionId, xCSRFToken, cascade);
        } catch (ApiException e) {
            System.err.println("Exception when calling WorkflowDefinitionsApi#v1WorkflowDefinitionsDefinitionIdDelete");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.WorkflowDefinitionsApi;

public class WorkflowDefinitionsApiExample {

    public static void main(String[] args) {
        WorkflowDefinitionsApi apiInstance = new WorkflowDefinitionsApi();
        String definitionId = definitionId_example; // String | The ID of the workflow definition to be undeployed. The ID is at most 64 characters long.
        String xCSRFToken = xCSRFToken_example; // String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.
        Boolean cascade = true; // Boolean | Whether the undeployment of the workflow definition deletes active workflow instances.
If the parameter is false or not specified and there are active workflow instances for the specified workflow definition, 
the undeployment is rejected. An instance is considered active if it is in status RUNNING, ERRONEOUS, or SUSPENDED.

        try {
            apiInstance.v1WorkflowDefinitionsDefinitionIdDelete(definitionId, xCSRFToken, cascade);
        } catch (ApiException e) {
            System.err.println("Exception when calling WorkflowDefinitionsApi#v1WorkflowDefinitionsDefinitionIdDelete");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];
// Configure HTTP basic authorization (authentication scheme: BasicAuthentication)
[apiConfig setUsername:@"YOUR_USERNAME"];
[apiConfig setPassword:@"YOUR_PASSWORD"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_AuthorizationCode)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_ClientCredentials)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

String *definitionId = definitionId_example; // The ID of the workflow definition to be undeployed. The ID is at most 64 characters long.
String *xCSRFToken = xCSRFToken_example; // The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.
Boolean *cascade = true; // Whether the undeployment of the workflow definition deletes active workflow instances.
If the parameter is false or not specified and there are active workflow instances for the specified workflow definition, 
the undeployment is rejected. An instance is considered active if it is in status RUNNING, ERRONEOUS, or SUSPENDED.
 (optional) (default to false)

WorkflowDefinitionsApi *apiInstance = [[WorkflowDefinitionsApi alloc] init];

// Delete workflow definition
[apiInstance v1WorkflowDefinitionsDefinitionIdDeleteWith:definitionId
    xCSRFToken:xCSRFToken
    cascade:cascade
              completionHandler: ^(NSError* error) {
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var WorkflowApiForNeo = require('workflow_api_for_neo');
var defaultClient = WorkflowApiForNeo.ApiClient.instance;

// Configure HTTP basic authorization: BasicAuthentication
var BasicAuthentication = defaultClient.authentications['BasicAuthentication'];
BasicAuthentication.username = 'YOUR USERNAME'
BasicAuthentication.password = 'YOUR PASSWORD'

// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
var Oauth2_AuthorizationCode = defaultClient.authentications['Oauth2_AuthorizationCode'];
Oauth2_AuthorizationCode.accessToken = "YOUR ACCESS TOKEN"

// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
var Oauth2_ClientCredentials = defaultClient.authentications['Oauth2_ClientCredentials'];
Oauth2_ClientCredentials.accessToken = "YOUR ACCESS TOKEN"

var api = new WorkflowApiForNeo.WorkflowDefinitionsApi()

var definitionId = definitionId_example; // {String} The ID of the workflow definition to be undeployed. The ID is at most 64 characters long.

var xCSRFToken = xCSRFToken_example; // {String} The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.

var opts = { 
  'cascade': true // {Boolean} Whether the undeployment of the workflow definition deletes active workflow instances.
If the parameter is false or not specified and there are active workflow instances for the specified workflow definition, 
the undeployment is rejected. An instance is considered active if it is in status RUNNING, ERRONEOUS, or SUSPENDED.

};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
api.v1WorkflowDefinitionsDefinitionIdDelete(definitionId, xCSRFToken, opts, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class v1WorkflowDefinitionsDefinitionIdDeleteExample
    {
        public void main()
        {
            
            // Configure HTTP basic authorization: BasicAuthentication
            Configuration.Default.Username = "YOUR_USERNAME";
            Configuration.Default.Password = "YOUR_PASSWORD";
            // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
            // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            var apiInstance = new WorkflowDefinitionsApi();
            var definitionId = definitionId_example;  // String | The ID of the workflow definition to be undeployed. The ID is at most 64 characters long.
            var xCSRFToken = xCSRFToken_example;  // String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.
            var cascade = true;  // Boolean | Whether the undeployment of the workflow definition deletes active workflow instances.
If the parameter is false or not specified and there are active workflow instances for the specified workflow definition, 
the undeployment is rejected. An instance is considered active if it is in status RUNNING, ERRONEOUS, or SUSPENDED.
 (optional)  (default to false)

            try
            {
                // Delete workflow definition
                apiInstance.v1WorkflowDefinitionsDefinitionIdDelete(definitionId, xCSRFToken, cascade);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling WorkflowDefinitionsApi.v1WorkflowDefinitionsDefinitionIdDelete: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
Swagger\Client\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Swagger\Client\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Swagger\Client\Api\WorkflowDefinitionsApi();
$definitionId = definitionId_example; // String | The ID of the workflow definition to be undeployed. The ID is at most 64 characters long.
$xCSRFToken = xCSRFToken_example; // String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.
$cascade = true; // Boolean | Whether the undeployment of the workflow definition deletes active workflow instances.
If the parameter is false or not specified and there are active workflow instances for the specified workflow definition, 
the undeployment is rejected. An instance is considered active if it is in status RUNNING, ERRONEOUS, or SUSPENDED.


try {
    $api_instance->v1WorkflowDefinitionsDefinitionIdDelete($definitionId, $xCSRFToken, $cascade);
} catch (Exception $e) {
    echo 'Exception when calling WorkflowDefinitionsApi->v1WorkflowDefinitionsDefinitionIdDelete: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::WorkflowDefinitionsApi;

# Configure HTTP basic authorization: BasicAuthentication
$WWW::SwaggerClient::Configuration::username = 'YOUR_USERNAME';
$WWW::SwaggerClient::Configuration::password = 'YOUR_PASSWORD';
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

my $api_instance = WWW::SwaggerClient::WorkflowDefinitionsApi->new();
my $definitionId = definitionId_example; # String | The ID of the workflow definition to be undeployed. The ID is at most 64 characters long.
my $xCSRFToken = xCSRFToken_example; # String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.
my $cascade = true; # Boolean | Whether the undeployment of the workflow definition deletes active workflow instances.
If the parameter is false or not specified and there are active workflow instances for the specified workflow definition, 
the undeployment is rejected. An instance is considered active if it is in status RUNNING, ERRONEOUS, or SUSPENDED.


eval { 
    $api_instance->v1WorkflowDefinitionsDefinitionIdDelete(definitionId => $definitionId, xCSRFToken => $xCSRFToken, cascade => $cascade);
};
if ($@) {
    warn "Exception when calling WorkflowDefinitionsApi->v1WorkflowDefinitionsDefinitionIdDelete: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# Configure HTTP basic authorization: BasicAuthentication
swagger_client.configuration.username = 'YOUR_USERNAME'
swagger_client.configuration.password = 'YOUR_PASSWORD'
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# create an instance of the API class
api_instance = swagger_client.WorkflowDefinitionsApi()
definitionId = definitionId_example # String | The ID of the workflow definition to be undeployed. The ID is at most 64 characters long.
xCSRFToken = xCSRFToken_example # String | The XSRF token that is valid for the current session (see resource '/v1/xsrf-token'). If the call is authenticated using OAuth, the XSRF token is unavailable and must not be specified.
cascade = true # Boolean | Whether the undeployment of the workflow definition deletes active workflow instances.
If the parameter is false or not specified and there are active workflow instances for the specified workflow definition, 
the undeployment is rejected. An instance is considered active if it is in status RUNNING, ERRONEOUS, or SUSPENDED.
 (optional) (default to false)

try: 
    # Delete workflow definition
    api_instance.v1WorkflowDefinitionsDefinitionIdDelete(definitionId, xCSRFToken, cascade=cascade)
except ApiException as e:
    print("Exception when calling WorkflowDefinitionsApi->v1WorkflowDefinitionsDefinitionIdDelete: %s\n" % e)

Parameters

Path parameters
Name Description
definitionId*
Header parameters
Name Description
X-CSRF-Token*
Query parameters
Name Description
cascade

Responses

Status: 202 - The undeployment of the workflow definition has been accepted, but will be executed asynchronously. The response will include the header 'Location' that points to a dedicated resource. You can use this resource to track the status of the undeployment.

Name Type Format Description
Location String Relative URL that points to a job resource. Use this resource to track the status of the undeployment.

Status: 303 - Another undeployment of the workflow definition is already running. The response will include the header 'Location' that points to a job resource which you can use to track the status of the undeployment. Depending on your web client you may be automatically redirected to this resource and receive the status of the undeployment as the result of your request.

Name Type Format Description
Location String Relative URL that points to a job resource. Using this resource you can track the status of the undeployment.

Status: 403 - Access forbidden. You do not have the required permissions to access the resource.

{error={message=User does not have sufficient privileges.}}

Status: 404 - Workflow definition not found. Either the payload does not contain a definitionId property or the specified ID is incorrect.

{error={code=bpm.workflowruntime.rest.definition.not.found, message=Workflow definition not found, logId=1c4daaf5-eb3f-4ff5-8b13-aa32a47bb07d}}

Status: 412 - At least one version of the workflow definition has at least one RUNNING instance.

{error={code=bpm.workflowruntime.rest.instances.running, message=Cannot undeploy workflow definition because it still has RUNNING instances., logId=c7c7235e-4528-469f-a2de-c9a1bcaacdd3}}

Status: 429 - Too many requests. You've reached the usage limits that are configured for your tenant. Reduce the number of requests.

Status: 500 - Internal server error. The operation you requested led to an error during execution.

{error={code=bpm.workflowruntime.rest.internal.server.error, message=Internal server error, logId=f29a5719-3342-4a4a-8a3d-5ddd5253159e}}

/v1/workflow-definitions/{definitionId}

Retrieves the latest version of the specified workflow definition. Roles permitted to execute this operation: - Global roles: WorkflowViewer, WorkflowAdmin, WorkflowDeveloper


/v1/workflow-definitions/{definitionId}

Usage

curl -X GET -H "Accept: application/json" -H "Content-Type: application/json" -H "Authorization: Basic [[basicHash]]" "https://sandbox.api.sap.com/workflow-service/rest/v1/workflow-definitions/{definitionId}"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.WorkflowDefinitionsApi;

import java.io.File;
import java.util.*;

public class WorkflowDefinitionsApiExample {

    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure HTTP basic authorization: BasicAuthentication
        HttpBasicAuth BasicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("BasicAuthentication");
        BasicAuthentication.setUsername("YOUR USERNAME");
        BasicAuthentication.setPassword("YOUR PASSWORD");

        // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
        OAuth Oauth2_AuthorizationCode = (OAuth) defaultClient.getAuthentication("Oauth2_AuthorizationCode");
        Oauth2_AuthorizationCode.setAccessToken("YOUR ACCESS TOKEN");

        // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
        OAuth Oauth2_ClientCredentials = (OAuth) defaultClient.getAuthentication("Oauth2_ClientCredentials");
        Oauth2_ClientCredentials.setAccessToken("YOUR ACCESS TOKEN");

        WorkflowDefinitionsApi apiInstance = new WorkflowDefinitionsApi();
        String definitionId = definitionId_example; // String | The ID of the workflow definition for which the latest version should be retrieved. The ID is at most 64 characters long.
        try {
            WorkflowDefinition result = apiInstance.v1WorkflowDefinitionsDefinitionIdGet(definitionId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling WorkflowDefinitionsApi#v1WorkflowDefinitionsDefinitionIdGet");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.WorkflowDefinitionsApi;

public class WorkflowDefinitionsApiExample {

    public static void main(String[] args) {
        WorkflowDefinitionsApi apiInstance = new WorkflowDefinitionsApi();
        String definitionId = definitionId_example; // String | The ID of the workflow definition for which the latest version should be retrieved. The ID is at most 64 characters long.
        try {
            WorkflowDefinition result = apiInstance.v1WorkflowDefinitionsDefinitionIdGet(definitionId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling WorkflowDefinitionsApi#v1WorkflowDefinitionsDefinitionIdGet");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];
// Configure HTTP basic authorization (authentication scheme: BasicAuthentication)
[apiConfig setUsername:@"YOUR_USERNAME"];
[apiConfig setPassword:@"YOUR_PASSWORD"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_AuthorizationCode)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_ClientCredentials)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

String *definitionId = definitionId_example; // The ID of the workflow definition for which the latest version should be retrieved. The ID is at most 64 characters long.

WorkflowDefinitionsApi *apiInstance = [[WorkflowDefinitionsApi alloc] init];

// Retrieve workflow definition by ID
[apiInstance v1WorkflowDefinitionsDefinitionIdGetWith:definitionId
              completionHandler: ^(WorkflowDefinition output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var WorkflowApiForNeo = require('workflow_api_for_neo');
var defaultClient = WorkflowApiForNeo.ApiClient.instance;

// Configure HTTP basic authorization: BasicAuthentication
var BasicAuthentication = defaultClient.authentications['BasicAuthentication'];
BasicAuthentication.username = 'YOUR USERNAME'
BasicAuthentication.password = 'YOUR PASSWORD'

// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
var Oauth2_AuthorizationCode = defaultClient.authentications['Oauth2_AuthorizationCode'];
Oauth2_AuthorizationCode.accessToken = "YOUR ACCESS TOKEN"

// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
var Oauth2_ClientCredentials = defaultClient.authentications['Oauth2_ClientCredentials'];
Oauth2_ClientCredentials.accessToken = "YOUR ACCESS TOKEN"

var api = new WorkflowApiForNeo.WorkflowDefinitionsApi()

var definitionId = definitionId_example; // {String} The ID of the workflow definition for which the latest version should be retrieved. The ID is at most 64 characters long.


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.v1WorkflowDefinitionsDefinitionIdGet(definitionId, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class v1WorkflowDefinitionsDefinitionIdGetExample
    {
        public void main()
        {
            
            // Configure HTTP basic authorization: BasicAuthentication
            Configuration.Default.Username = "YOUR_USERNAME";
            Configuration.Default.Password = "YOUR_PASSWORD";
            // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
            // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            var apiInstance = new WorkflowDefinitionsApi();
            var definitionId = definitionId_example;  // String | The ID of the workflow definition for which the latest version should be retrieved. The ID is at most 64 characters long.

            try
            {
                // Retrieve workflow definition by ID
                WorkflowDefinition result = apiInstance.v1WorkflowDefinitionsDefinitionIdGet(definitionId);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling WorkflowDefinitionsApi.v1WorkflowDefinitionsDefinitionIdGet: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
Swagger\Client\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Swagger\Client\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Swagger\Client\Api\WorkflowDefinitionsApi();
$definitionId = definitionId_example; // String | The ID of the workflow definition for which the latest version should be retrieved. The ID is at most 64 characters long.

try {
    $result = $api_instance->v1WorkflowDefinitionsDefinitionIdGet($definitionId);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling WorkflowDefinitionsApi->v1WorkflowDefinitionsDefinitionIdGet: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::WorkflowDefinitionsApi;

# Configure HTTP basic authorization: BasicAuthentication
$WWW::SwaggerClient::Configuration::username = 'YOUR_USERNAME';
$WWW::SwaggerClient::Configuration::password = 'YOUR_PASSWORD';
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

my $api_instance = WWW::SwaggerClient::WorkflowDefinitionsApi->new();
my $definitionId = definitionId_example; # String | The ID of the workflow definition for which the latest version should be retrieved. The ID is at most 64 characters long.

eval { 
    my $result = $api_instance->v1WorkflowDefinitionsDefinitionIdGet(definitionId => $definitionId);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling WorkflowDefinitionsApi->v1WorkflowDefinitionsDefinitionIdGet: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# Configure HTTP basic authorization: BasicAuthentication
swagger_client.configuration.username = 'YOUR_USERNAME'
swagger_client.configuration.password = 'YOUR_PASSWORD'
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# create an instance of the API class
api_instance = swagger_client.WorkflowDefinitionsApi()
definitionId = definitionId_example # String | The ID of the workflow definition for which the latest version should be retrieved. The ID is at most 64 characters long.

try: 
    # Retrieve workflow definition by ID
    api_response = api_instance.v1WorkflowDefinitionsDefinitionIdGet(definitionId)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling WorkflowDefinitionsApi->v1WorkflowDefinitionsDefinitionIdGet: %s\n" % e)

Parameters

Path parameters
Name Description
definitionId*

Responses

Status: 200 - Returns a single workflow definition version.

{id=LeaveRequestWorkflow, name=Leave Request Workflow, version=2, createdBy=UserId1, createdAt=2018-05-09T11:42:27.524+0000, jobs=[]}

Status: 403 - Access forbidden. You do not have the required permissions to access the resource.

{error={message=User does not have sufficient privileges.}}

Status: 404 - Workflow definition not found. Either the payload does not contain a definitionId property or the specified ID is incorrect.

{error={code=bpm.workflowruntime.rest.definition.not.found, message=Workflow definition not found, logId=1c4daaf5-eb3f-4ff5-8b13-aa32a47bb07d}}

Status: 429 - Too many requests. You've reached the usage limits that are configured for your tenant. Reduce the number of requests.

Status: 500 - Internal server error. The operation you requested led to an error during execution.

{error={code=bpm.workflowruntime.rest.internal.server.error, message=Internal server error, logId=f29a5719-3342-4a4a-8a3d-5ddd5253159e}}

/v1/workflow-definitions/{definitionId}/model

Retrieves the model of the latest version of the specified workflow definition. Roles permitted to execute this operation: - Global roles: WorkflowViewer, WorkflowAdmin, WorkflowDeveloper


/v1/workflow-definitions/{definitionId}/model

Usage

curl -X GET -H "Accept: application/json" -H "Content-Type: application/json" -H "Authorization: Basic [[basicHash]]" "https://sandbox.api.sap.com/workflow-service/rest/v1/workflow-definitions/{definitionId}/model"
import io.swagger.client.*;
import io.swagger.client.auth.*;
import io.swagger.client.model.*;
import io.swagger.client.api.WorkflowDefinitionsApi;

import java.io.File;
import java.util.*;

public class WorkflowDefinitionsApiExample {

    public static void main(String[] args) {
        ApiClient defaultClient = Configuration.getDefaultApiClient();
        
        // Configure HTTP basic authorization: BasicAuthentication
        HttpBasicAuth BasicAuthentication = (HttpBasicAuth) defaultClient.getAuthentication("BasicAuthentication");
        BasicAuthentication.setUsername("YOUR USERNAME");
        BasicAuthentication.setPassword("YOUR PASSWORD");

        // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
        OAuth Oauth2_AuthorizationCode = (OAuth) defaultClient.getAuthentication("Oauth2_AuthorizationCode");
        Oauth2_AuthorizationCode.setAccessToken("YOUR ACCESS TOKEN");

        // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
        OAuth Oauth2_ClientCredentials = (OAuth) defaultClient.getAuthentication("Oauth2_ClientCredentials");
        Oauth2_ClientCredentials.setAccessToken("YOUR ACCESS TOKEN");

        WorkflowDefinitionsApi apiInstance = new WorkflowDefinitionsApi();
        String definitionId = definitionId_example; // String | The workflow definition ID for which the latest model should be retrieved. The workflow definition ID is at most 64 characters long.
        try {
            inline_response_200 result = apiInstance.v1WorkflowDefinitionsDefinitionIdModelGet(definitionId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling WorkflowDefinitionsApi#v1WorkflowDefinitionsDefinitionIdModelGet");
            e.printStackTrace();
        }
    }
}
import io.swagger.client.api.WorkflowDefinitionsApi;

public class WorkflowDefinitionsApiExample {

    public static void main(String[] args) {
        WorkflowDefinitionsApi apiInstance = new WorkflowDefinitionsApi();
        String definitionId = definitionId_example; // String | The workflow definition ID for which the latest model should be retrieved. The workflow definition ID is at most 64 characters long.
        try {
            inline_response_200 result = apiInstance.v1WorkflowDefinitionsDefinitionIdModelGet(definitionId);
            System.out.println(result);
        } catch (ApiException e) {
            System.err.println("Exception when calling WorkflowDefinitionsApi#v1WorkflowDefinitionsDefinitionIdModelGet");
            e.printStackTrace();
        }
    }
}
Configuration *apiConfig = [Configuration sharedConfig];
// Configure HTTP basic authorization (authentication scheme: BasicAuthentication)
[apiConfig setUsername:@"YOUR_USERNAME"];
[apiConfig setPassword:@"YOUR_PASSWORD"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_AuthorizationCode)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

// Configure OAuth2 access token for authorization: (authentication scheme: Oauth2_ClientCredentials)
[apiConfig setAccessToken:@"YOUR_ACCESS_TOKEN"];

String *definitionId = definitionId_example; // The workflow definition ID for which the latest model should be retrieved. The workflow definition ID is at most 64 characters long.

WorkflowDefinitionsApi *apiInstance = [[WorkflowDefinitionsApi alloc] init];

// Retrieve workflow definition model by ID
[apiInstance v1WorkflowDefinitionsDefinitionIdModelGetWith:definitionId
              completionHandler: ^(inline_response_200 output, NSError* error) {
                            if (output) {
                                NSLog(@"%@", output);
                            }
                            if (error) {
                                NSLog(@"Error: %@", error);
                            }
                        }];
var WorkflowApiForNeo = require('workflow_api_for_neo');
var defaultClient = WorkflowApiForNeo.ApiClient.instance;

// Configure HTTP basic authorization: BasicAuthentication
var BasicAuthentication = defaultClient.authentications['BasicAuthentication'];
BasicAuthentication.username = 'YOUR USERNAME'
BasicAuthentication.password = 'YOUR PASSWORD'

// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
var Oauth2_AuthorizationCode = defaultClient.authentications['Oauth2_AuthorizationCode'];
Oauth2_AuthorizationCode.accessToken = "YOUR ACCESS TOKEN"

// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
var Oauth2_ClientCredentials = defaultClient.authentications['Oauth2_ClientCredentials'];
Oauth2_ClientCredentials.accessToken = "YOUR ACCESS TOKEN"

var api = new WorkflowApiForNeo.WorkflowDefinitionsApi()

var definitionId = definitionId_example; // {String} The workflow definition ID for which the latest model should be retrieved. The workflow definition ID is at most 64 characters long.


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
api.v1WorkflowDefinitionsDefinitionIdModelGet(definitionId, callback);
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;

namespace Example
{
    public class v1WorkflowDefinitionsDefinitionIdModelGetExample
    {
        public void main()
        {
            
            // Configure HTTP basic authorization: BasicAuthentication
            Configuration.Default.Username = "YOUR_USERNAME";
            Configuration.Default.Password = "YOUR_PASSWORD";
            // Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";
            // Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
            Configuration.Default.AccessToken = "YOUR_ACCESS_TOKEN";

            var apiInstance = new WorkflowDefinitionsApi();
            var definitionId = definitionId_example;  // String | The workflow definition ID for which the latest model should be retrieved. The workflow definition ID is at most 64 characters long.

            try
            {
                // Retrieve workflow definition model by ID
                inline_response_200 result = apiInstance.v1WorkflowDefinitionsDefinitionIdModelGet(definitionId);
                Debug.WriteLine(result);
            }
            catch (Exception e)
            {
                Debug.Print("Exception when calling WorkflowDefinitionsApi.v1WorkflowDefinitionsDefinitionIdModelGet: " + e.Message );
            }
        }
    }
}
<?php
require_once(__DIR__ . '/vendor/autoload.php');

// Configure HTTP basic authorization: BasicAuthentication
Swagger\Client\Configuration::getDefaultConfiguration()->setUsername('YOUR_USERNAME');
Swagger\Client\Configuration::getDefaultConfiguration()->setPassword('YOUR_PASSWORD');
// Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');
// Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
Swagger\Client\Configuration::getDefaultConfiguration()->setAccessToken('YOUR_ACCESS_TOKEN');

$api_instance = new Swagger\Client\Api\WorkflowDefinitionsApi();
$definitionId = definitionId_example; // String | The workflow definition ID for which the latest model should be retrieved. The workflow definition ID is at most 64 characters long.

try {
    $result = $api_instance->v1WorkflowDefinitionsDefinitionIdModelGet($definitionId);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling WorkflowDefinitionsApi->v1WorkflowDefinitionsDefinitionIdModelGet: ', $e->getMessage(), PHP_EOL;
}
?>
use Data::Dumper;
use WWW::SwaggerClient::Configuration;
use WWW::SwaggerClient::WorkflowDefinitionsApi;

# Configure HTTP basic authorization: BasicAuthentication
$WWW::SwaggerClient::Configuration::username = 'YOUR_USERNAME';
$WWW::SwaggerClient::Configuration::password = 'YOUR_PASSWORD';
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
$WWW::SwaggerClient::Configuration::access_token = 'YOUR_ACCESS_TOKEN';

my $api_instance = WWW::SwaggerClient::WorkflowDefinitionsApi->new();
my $definitionId = definitionId_example; # String | The workflow definition ID for which the latest model should be retrieved. The workflow definition ID is at most 64 characters long.

eval { 
    my $result = $api_instance->v1WorkflowDefinitionsDefinitionIdModelGet(definitionId => $definitionId);
    print Dumper($result);
};
if ($@) {
    warn "Exception when calling WorkflowDefinitionsApi->v1WorkflowDefinitionsDefinitionIdModelGet: $@\n";
}
from __future__ import print_statement
import time
import swagger_client
from swagger_client.rest import ApiException
from pprint import pprint

# Configure HTTP basic authorization: BasicAuthentication
swagger_client.configuration.username = 'YOUR_USERNAME'
swagger_client.configuration.password = 'YOUR_PASSWORD'
# Configure OAuth2 access token for authorization: Oauth2_AuthorizationCode
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
# Configure OAuth2 access token for authorization: Oauth2_ClientCredentials
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'

# create an instance of the API class
api_instance = swagger_client.WorkflowDefinitionsApi()
definitionId = definitionId_example # String | The workflow definition ID for which the latest model should be retrieved. The workflow definition ID is at most 64 characters long.

try: 
    # Retrieve workflow definition model by ID
    api_response = api_instance.v1WorkflowDefinitionsDefinitionIdModelGet(definitionId)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling WorkflowDefinitionsApi->v1WorkflowDefinitionsDefinitionIdModelGet: %s\n" % e)

Parameters

Path parameters
Name Description
definitionId*

Responses

Status: 200 - The deployed workflow model.

{contents={a46b9a0c-e2c4-46f1-ab45-a4f1c64242e1={classDefinition=com.sap.bpm.wfs.Model, id=ExternalServiceFlow, name=ExternalServiceFlow, subject=External Service Flow '${id}', businessKey=${id}, lastIds=835bb943-b74b-4a45-9a26-2a5ab2471fae, events={dac01f83-3cd2-421a-b099-695372490c22={name=StartEvent1}, 17af566f-cce3-4375-9e92-85fe456b9b1a={name=EndEvent1}}, activities={65021cef-c40b-4481-b6a5-d28f3d425b49={name=Call external Service}}, sequenceFlows={98d81e72-af85-46be-86f2-b86a290db42d={name=SequenceFlow14}, 0da7f0a6-fa3e-4c2a-a3a9-92f738e9cef9={name=SequenceFlow15}}, diagrams={5136eee3-88cd-40b3-a909-a212b7be5c1c={}}}, 835bb943-b74b-4a45-9a26-2a5ab2471fae={classDefinition=com.sap.bpm.wfs.LastIDs, sequenceflow=15, startevent=1, endevent=1, servicetask=1, scripttask=2, parallelgateway=2, exclusivegateway=2}, 5136eee3-88cd-40b3-a909-a212b7be5c1c={classDefinition=com.sap.bpm.wfs.ui.Diagram, symbols={e5af1ccc-d6ac-4b93-bd54-9ecbc22e1b0c={}, bba91ec8-a65b-4220-8b9a-38346de34c1e={}, fd3dd963-fa3f-4346-b75f-aaffcf172b6a={}, 9e681614-dc17-425d-ab02-037029c789e8={}, 9d851743-62a1-47cc-8786-522310d3a