Symptoms
Not able to start a process using REST services
Diagnoses
We are trying to launch the process using REST by sending a post request like below. We are getting HTTP 202 back, and the process does not get kicked off. There is nothing specific in the log file (attached).
https://k2.denallix.com/K2Services/REST.svc/Process/Instances/StartInstance?synchronous=true
User-Agent: Fiddler
content-type: application/xml
Host: k2.denallix.com
Content-Length: 669
Resolution
We were able to start process instances using REST > POST with both SOAPUI and Fiddler Request Composer. The POST header below will be necessary:
Authorization: Basic or NTLM {encrypted token goes here}
Content-type: application/xml
The Request body should have the following (this example without datafield/xml input, please see the documentation for more information):
<?xml version="1.0" encoding="utf-8"?> <w:ProcessInstance xmlns:w="http://schemas.k2.com/worklist/d1" xmlns:p="http://schemas.k2.com/process/d1" ExpectedDuration="20" FullName="K2Project2Process" Folio="POSTCall" Priority="3"></w:ProcessInstance>
http://help.k2.com/onlinehelp/k2blackpearl/devref/4.6.9/default.htm_ProcessInstancesStartInstance.html?TocPath=Reference%20Information|Services%20Reference|K2%20Services%20(Workflow%20Runtime)|Process%20Service|_____2