pp108 : PlanIntermediateActivities

PlanIntermediateActivities


This Web service operation is used to plan the intermediate follow-up activities for a given activity instance of the Case instance. The PlanIntermediateActivities is a part of the Method Set Case Instance Execution 4.2 Web service interface with the namespace 'http://schemas.cordys.com/casemanagement/execution/1.0'.

SOAP Request

  1. Planning an intermediate activity with name and state
    <SOAP:Envelope xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/">
        <SOAP:Body>
            <PlanIntermediateActivities xmlns="http://schemas.cordys.com/casemanagement/execution/1.0">
                <caseinstanceid>{2I0C054B-E0FB-4DB4-B031-601EA31853AF}</caseinstanceid>
                <activityinstanceid activityid="{14C1BD36-9B23-45EB-9063-465AABB117BD}">
    {7BF20010-23A0-463A-BAD5-5EFC84E295C3}</activityinstanceid>
                <planactivities>
                    <activity name="Discuss problems" state="Diagnosis"/>
                </planactivities>
            </PlanIntermediateActivities>
        </SOAP:Body>
    </SOAP:Envelope>
    
  2. Planning an intermediate activity with name, state, and activity definition details to override the default values
    <SOAP:Envelope xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/">
        <SOAP:Body>
            <PlanIntermediateActivities xmlns="http://schemas.cordys.com/casemanagement/execution/1.0">
                <caseinstanceid>001A6BFA-F5BF-11E0-F0EE-296E2EEA9211</caseinstanceid>
                <activityinstanceid activityid="001A6BFA-F5BF-11E0-F062-10A9D66B3B34">
                001A6BFA-F5BF-11E0-F0EE-296E2EEB1211</activityinstanceid>
                <planactivities xmlns="http://schemas.cordys.com/casemanagement/execution/1.0">
                    <activity name="Discuss problems" state="Diagnosis">
                        <activityinstanceid>001A6BFA-F5BF-11E0-F0EC-C7395B033211</activityinstanceid>
                        <case:activity id="001A6BFA-F5BF-11E0-F0EC-C7395B06B211"
                          name="Discuss problems" type="HUMANTASK" xmlns="" xmlns:
                          case="http://schemas.cordys.com/casemanagement/1.0"
                          xmlns:ns1="http://schemas.cordys.com/1.0/xforms/processapi"
                          xmlns:ns2="http://schemas.cordys.com/default"
                          xmlns:ns3="http://schemas.cordys.com/bpm/instance/1.0" xmlns:sm="http://www.w3.org/2005/07/scxml">
                            <HumanInteraction xmlns="http://schemas.cordys.com/notification/workflow/1.0">
                                <Subject>Discuss problems</Subject>
                                <SendTo>
                                    <Target type="user">
                                        <Assignee>cn=john,cn=organizational users,o=system,cn=cordys,
                                        cn=defaultInst,o=myorg.com</Assignee>
                                    </Target>
                                </SendTo>
                            </HumanInteraction>
                            <case:associatedevents/>
                            <case:escalation/>
                        </case:activity>
                    </activity>
                </planactivities>
            </PlanIntermediateActivities>
        </SOAP:Body>
    </SOAP:Envelope>
    
    Request Parameters

Parameter

Description

Mandatory

Accepted Input Values

caseinstanceid

Refers to the unique identifier of the Case instance. The Case instance ID can be obtained from any of the following:

  • The response of CreateCase API
  • The Workflow.getCaseInstanceId API that is invoked from a human task of the Case instance

Yes

activityinstanceid

Refers to the unique identifier of the activity instance for which the intermediate activities must be planned. The activity instance ID can be obtained from the Workflow.getTaskInstanceId() Web API.

Yes

activityid

Refers to the unique identifier of the activity definition. The activity ID can be obtained from the Workflow.getCaseActivityId() Web API.

Yes

activity

Contains the ID, name, and state of the activity. The attribute ID is the activity model ID and name is the name of the activity that is planned for execution. State indicates the state in which the planned activity exists.

Either one of the parameters can be used or both name and state can be given as the input parameters.

Yes

-

activity/activityinstanceid

Refers to the unique identifier of the activity that is used for creating an instance of the activity. This ID can be used to retrieve the details of the planned activity instance using the GetActivityInstance SOAP API.

No

-

activity/activity

This element contains the details of the activity definition. Note that the namespace of this activity element is different from the namespace of its parent activity element.
This element is required only when there is a need to overwrite default values, for example, changing the due date of the activity, configured in the design time. The activity definition details can be obtained from the definition node of the GetCaseActivity SOAP API response.

No

-

SOAP Response

<SOAP:Envelope xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/">
    <SOAP:Body>
        <PlanIntermediateActivitiesResponse xmlns="http://schemas.cordys.com/casemanagement/execution/1.0">
            <activestates>
                <state id="{5E019655-709E-4CF0-BD3B-FA3E066EF8F4}" name="Dignosis">{2S0C054B-E0FB-4DB4-B031-601EA31853AF}</state>
            </activestates>
        </PlanIntermediateActivitiesResponse>
    </SOAP:Body>
</SOAP:Envelope>

Response Parameters

Parameter

Description

activestates

Contains the existing active states of the Case model

state

Refers to the name and ID of the active state