Captain
Captain
216 views

SOAP to approve and change DAL date value

Some context:

We have many workflows, some of which are Approval activities that operate on a timer to progress. The flow paths out of particular Approval are  Approved, Denied, and Timedout.

I can use SOAP calls to IDMProv/provisioning/service to programmatically approve specific activities, however the only approval actions available are Approve and Deny. Timedout cannot be forced here.

The workflow does have an option to alter the timeout date/time by Approving and supplying a modified flowdata field 'ProcessDate'. The field is defined as type 'Date' in the Approval form of the workflow.

Whilst I can change any 'String' data type with above method (<ser:forwardRequest>), when I attempt to alter a Date field I get an error. 

Attempt to set value on Data item [ProcessDate] using incorrect type; expecting [date] got [1600999209712]
 
I can alter other Fields in the work flow using the SOAP call below, but only those defined as 'String' in the approval form fields.
 
I've tried many time formats (> 10) but it seems to me the string needs to be structured some special way.
 
Here is the SOAP envelope:
 
   <soapenv:Header/>
   <soapenv:Body>
      <ser:forwardRequest>
         <!--Optional:-->
         <ser:arg0>123446b2f7ae48fc8cf0d8e5048eabcd</ser:arg0>
         <ser:Action>APPROVE</ser:Action>
         <!--Optional:-->
         <ser:arg2>
            <!--Zero or more repetitions:-->
            <ser:dataitem>
               <ser:name>ProcessDate</ser:name>
               <ser:value>
                  <!--Zero or more repetitions:-->
                  <ser:string>1600999209712</ser:string>
               </ser:value>
            </ser:dataitem>
         </ser:arg2>
         <!-- Optional:-->
         <ser:arg3>Fast tracked termination</ser:arg3>
      </ser:forwardRequest>
   </soapenv:Body>
</soapenv:Envelope>

 

2 Replies
Commodore
Commodore

Hi,
to be honest, haven't had an opportunity to work with SOAP, but could you get the date from DAL, and then you would know what format you should use?
0 Likes
Knowledge Partner Knowledge Partner
Knowledge Partner

The proper time is usually LDAP time. Either ending in -6000 or Z.

THis article by Rob Rawson (my boss) is a very good one on the topic of time in Workflows.

https://community.microfocus.com/t5/Identity-Manager-Tips/The-Ultimate-Answer-to-Dates-Forms-and-Workflows-and-everything/ta-p/1777149

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.