Complete WorkItem from API

Hello everyone,

I have a specific question, but maybe I’ll give the bigger picture first.

We are wanting to automate the testing of a Workflow and its related Forms in IIQ. I thought that maybe we could do this through the API. I was able to launch the Workflow and pre-fill the first Form in the Workflow, but after the Form is filled, I don’t know how to submit the Form. What I am left with is a WorkItem for the Form that is completely filled out (but unsubmitted).

I am wondering if there is a way for me to either complete the Form/WorkItem via the API.

If anyone has any insight on that specific issue or my larger effort of Workflow testing, I would appreciate it.

Thanks,
Vic

Hi @vic_rinkenberger

Did you look into Forms Link . Why are we trying to achieve this via API approach?

<Button label='Submit' action='next'/>

Regards
Rajesh Kumar

1 Like

There are at least 2 ways to test workflows automatically. However, if you want either of the ways below use from API, then you have to go one extra mile and wrap all actions into API - which I would argue sounds overkill.
Maybe your question is rather just about testing?

Way 1: Start the workflow with Workflower method launcSession, which gives you sailpoint.api.WorkflowSession object which you can use to move steps, provide forms input, inspect results etc.

Way 2: Use Sailpoint class WorkflowTestSuite, which is also intended to test workflows.

Way 3: There were options in the SSB too as I remember

Unfortunately, first 2 options miss almost completely any documentation and support. The sailpoint.api.WorkflowSession does not even have a docs link. But SailPoint Professional Services can help you here.

1 Like

Hello,

  1. The common Java API method to finish a workitem we used is normally: sailpoint.api.Workflower.finish(Workitem item) or sailpoint.api.Workflower.reject(Workitem item).

  2. In order to make a REST API endpoint, I would recommend to utilize the plugin framework to provide a custom endpoint in your case of integration.

  3. Another possibility is that we can use DebSAK Plugin, it can be installed on a Windows machine, and it provides commands such as workitemApprove, workitemExpire, workitemReject, which you can also use RPC client to run the command, this is not the best practice, but it can somehow simulate a REST API service.

Personally, I would say the second option would be the best solution in this case. But it also depends on your requirements, if it’s only a PoC, or only a small integration, maybe option 3 is not too bad to be considered.

Thanks and Regards,
Mike

2 Likes

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.