K2 SmartObject OData API request body JSON format for ProcessInstance Start Method?

  • 8 July 2022
  • 1 reply
  • 81 views

Badge +1

As a little background, I'm looking to use the SmartObject OData API in K2 Cloud to do some processing of workflow instances. I have managed to do some basic stuff like authenticating and listing workflows and removing single items but I need to do some more complex tasks that use JSON headers with structures instead of single variables (see screenshots).

 

Is there anywhere I can get the format of the JSON that the system smartobject is expecting when posting a request to the ProcessInstance Start method for example? Or more generally how I find these for other smartobjects?

 

I can create the json for some of the more basic ones where the parameters are simple single values like "ProcInstID" e.g:

{

  "ProcInstID": 7072

}

 

However, some of them seem to want things like a ProcessInstanceInfo structure or DataFields structure which I have no idea of the format.

 

I'll attach a couple of screenshots for reference.

 

Any help would be really appreciated.

 

I'm hoping there is some form of reference to these API interfaces otherwise I'm flying blind!


1 reply

Userlevel 2
Badge +9

Hi, John,


 


OData follows the structure of the SmartObject, so you can get some idea by looking at the reference material available here: https://help.nintex.com/en-US/k2five/userguide/5.5/default.htm#ReferenceInfo/Workflow-Reports/Workflow-Reports.htm?TocPath=Reference%2520Information%257CStandard%2520SmartObjects%2520Reference%257C_____6


 


For object serialization, you'll have to use that object's method.


 


HTH,


Mike

Reply