cancel
Showing results for 
Search instead for 
Did you mean: 

Not able to retrieve count of Workflow instances

thejk
Explorer
0 Kudos

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

View Entire Topic
thejk
Explorer

Hello Tobias,

Whitelisting was the solution. Works perfect... I also changed the way I specify "status"

Thanks a Lot!

Jürgen