Workflow Responses
The <responses> section in the workflow’s XML file provides a way to specify fields to be returned to the client applications.
- Fields to be returned
- Message on which to return the field (initialize or decision)
- ClientRef on which to return the field
The fields to be returned are pulled from the DecisionRequest object. They can be any internal fields, which begin with ibm, or user fields, which are pulled from the tables and added by user exits.
<responseField> is used to specify the name of the field. It also specifies the message (initialize, decision, or both if omitted) on which the field should be sent.
Some fields are returned as set by default. The normalized payment record fields (ibmNprXXXX) are returned automatically on the decision message. Only those fields which were updated by the workflow on a particular decision message are returned.
- 0 - unchanged, no node modified on this field on this pass
- 1 - updated, could be updated with the same value
- a user field BankId on the initialize message
- the internal process buffer header field on the decision message
<responses>
<response clientRef="Payments Director Gateway">
<responseFields>
<responseField name="BankId" message="init"/>
<responseField name="ibmSPXProcBufHdr" message="decision"/>
</responseFields>
</response>
</responses>The normalized payment record fields are returned automatically. This can be explicitly controlled by the normalizePaymentRecord attribute.
<responses>
<response clientRef="My Client" normalizePaymentRecord="false">
<responseFields>
<responseField name="TestServerFlag" message="init"/>
<responseField name="ibmNprPocket" message="decision"/>
</responseFields>
</response>
<response>
<responseFields>
<responseField name="BankId" message="init"/>
<responseField name="LargeDollarFlag" message="decision"/>
<responseField name="ErrorCode" message="decision"/>
</responseFields>
</response>
</responses>The clientRef attribute in the second response element is omitted because it is optional. If not specified, any client whose clientRef does not match a response will use this by default.