on 07-06-2018 8:49 AM
Hello,
I am trying to get the total count of instances of a certain workflow definition. I am trying this:
var sURL = "/bpmworkflowruntime/rest/v1/workflow-instances/?&definitionId=" + sWorkflowDefinition + "&status=RUNNING,ERRONEOUS,SUSPENDED,
CANCELED,COMPLETED&$inlinecount=allpages
&$orderby=startedAt desc";
$.ajax({
url: sURL,
method: "GET",
contentType: "application/json",
async: false,
success: function (oResponse, httpStatus, jqXHR) {
},
error: function (result) {
}
});
I was expecting to get a "X-Total-Count" header in the response as described in the API documentation. But all I get is this:
Guess I am doing it wrong? Any hints to point me in the right direction?
Thanks,
Jürgen
Hi Jürgen,
You probably need to whitelist the header in your HTML5 app so that it is not filtered out.
In addition: the way you specify the status is not covered by the REST API documentation. Please specify the parameter 'status' multiple times, with different values, instead of once with a comma-separated list for the value.
Regards,
Tobias
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Tobias,
Whitelisting was the solution. Works perfect... I also changed the way I specify "status"
Thanks a Lot!
Jürgen
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
77 | |
11 | |
8 | |
8 | |
6 | |
6 | |
6 | |
5 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.