GetProcessInstancesResult GetProcessInstances(BpmProcessId tBpmProcess, BProcessInstancesArg arg)
tBpmProcess. Moniker of opened process instance.
arg. Operation execution parameters.
The GetProcessInstances operation gets a list of executed process instances.
To execute the operation, in the tBpmProcess field specify moniker of opened process instance. The moniker can be obtained after executing the OpenBpmProcess operation. If it is required to get a list of processes executed within a subprocess, specify identifier of the subprocess instance in the arg.parentInstId field.
The operation results in the obtained list of executed process instances.
Below is the example of getting a list of executed process instances. The request contains moniker of opened process instance. The response contains the obtained information.
{
"GetProcessInstances" :
{
"tBpmProcess" :
{
"id" : "CDIKMKCKEHJCGOAELMMPKEGKAJIPBMFELKNPPPKHHFAHIIHI!M!S!BPFGPGKNCKEHJCGOAEHJDEHIPJFHBPODGEKJCMFANHBFPHKIDC"
},
"arg" :
{
"mode" : "Default"
}
}
}
{
"GetProcessInstancesResult" :
{
"operations" : "1",
"list" :
{
"it" :
{
"key" : "51021",
"startDate" : "31.03.2024 17:14:38",
"comment" : "",
"prms" : "Dictionary = '1'"
}
}
}
}
public static GetProcessInstancesResult GetProcessInstances(string moniker)
{
var somClient = new SomPortTypeClient(); // Proxy object for operation execution
// Operation execution parameters
var tGet = new GetProcessInstances()
{
tBpmProcess = new BpmProcessId() { id = moniker },
arg = new BProcessInstancesArg() { mode = BProcessInstanceMode.Default }
};
// Get a list of executed instances of the specified process
var result = somClient.GetProcessInstances(tGet);
return result;
}
See also: