Workflow missing when creating an incident through Web Services
search cancel

Workflow missing when creating an incident through Web Services

book

Article ID: 217625

calendar_today

Updated On:

Products

CA Service Desk Manager CA Service Management - Service Desk Manager

Issue/Introduction

When creating Incident via Web Services, using a category that has Workflow (WF) attached, the Incident does not present the WF

Environment

Release : 17.3 or later versions

Service Desk Web Services

Cause

Faulty web services code and SDM category configuration. Please see resolution for an example of web services code that should work.

Resolution

Within Service Desk please make these changes

  1. Log into SDM
  2. Go to Admin tab
  3. Select Service Desk
  4. Select Requests/Incidents/Problems
  5. Click Areas
  6. Click Create New
  7. In the Symbol box type any name you want
  8. Select Service Type
  9. Self-Service Symbol should match Symbol
  10. Click Workflow , then Incidents, then add classic Workflow
  11. Save

 

Within SoapUI, please make these changes

  1. Click the Soap Icon on the top left corner
    In the dialog box for New Soap Project
         Give your project a name
         Enter the Initial WSDL = http//:Servername.bpc.broadcom.net:8080/axis/services/USD_R11_WebService?WSDL
         
  2. Click OK
    Inside of the Navigator Bar on the Left side click login
    Click Request 1
    Enter your Service Desk Login and Password

  3. Enter the following code:

                 <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"xmlns:ser="http://www.ca.com/UnicenterServicePlus/ServiceDesk">
              <soapenv:Header/>
                <soapenv:Body>
                  <ser:login>
                    <username>?</username>
                  <password>?</password>
                </ser:login>
               </soapenv:Body>
             </soapenv:Envelope>

  4. Click the Play button to run
           If its's successful you will see

              &ltsoapenv:Envelope  xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"xmlns:xsd="http://www.w3.org/2001/XMLSchema  "xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
                 <soapenv:Body>
                    <loginResponse xmlns="http://www.ca.com/UnicenterServicePlus/ServiceDesk">
                        <loginReturn xmlns="">510741424</loginReturn>
                      </loginResponse>
                     </soapenv:Body>
                 </soapenv:Envelope>

 

 Copy the SID from the loginReturn field

 <loginReturn xmlns="">510741424</loginReturn>

 

Within the Navigator Bar on the Left side click createRequest
  Click Request1
Sample Request:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ser="http://www.ca.com/UnicenterServicePlus/ServiceDesk">
   <soapenv:Header/>
   <soapenv:Body>
      <ser:createRequest>
       <!--Enter the SID you copied from Login-->
         <sid><510741424</sid>   
      <!--creatorHandle is retrieved from SQL ca_contact table in the ID column-->
         <creatorHandle>cnt:3D5F8E143C02D843AAD44654D556151C</creatorHandle>
         <attrVals>
            <!--1 or more repetitions:-->
           <string>description</string>
            <string>Test Description</string>
      <!--retrieve the category from SQL prob_ctg table in the ID column-->
            <string>category</string>
            <string>pcat:400002</string>
        <!--log_agent matches the creatorHandle-->
            <string>log_agent</string>
            <string>cnt:3D5F8E143C02D843AAD44654D556151C</string>
            <string>summary</string>
            <string>Test Summary Here</string>
            <string>status</string>
            <string>OP</string>
         <!--customer matches the creatorHandle for testing purposes-->
            <string>customer</string>
            <string>cnt:3D5F8E143C02D843AAD44654D556151C</string>
         <!--change type to I for incident-->
            <string>type</string>
            <string>I</string>
            <string>priority</string>
            <string>0</string>
         </attrVals>
         <propertyValues>
            <!--1 or more repetitions:-->
            <string></string>
         </propertyValues>
         <template></template>
         <attributes>
            <!--1 or more repetitions:-->
            <string>ref_num</string>
         </attributes>
         <newRequestHandle></newRequestHandle>
         <newRequestNumber></newRequestNumber>
      </ser:createRequest>
   </soapenv:Body>
</soapenv:Envelope>

Click the Play button to run
       If its's successful you will see

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
   <soapenv:Body>
      <createRequestResponse xmlns="http://www.ca.com/UnicenterServicePlus/ServiceDesk">
         <createRequestReturn xmlns=""><![CDATA[<?xml version="1.0" encoding="UTF-8"?><UDSObject>
    <Handle>cr:400228</Handle>
    <Attributes>
        <Attribute DataType="2002">
            <AttrName>ref_num</AttrName>
            <AttrValue>85</AttrValue>
        </Attribute>
    </Attributes>
</UDSObject>]]></createRequestReturn>
         <newRequestHandle xmlns="">cr:400228</newRequestHandle>
         <newRequestNumber xmlns="">85</newRequestNumber>
      </createRequestResponse>
   </soapenv:Body>
</soapenv:Envelope>

Go back to SDM
Click Service Desk
Click Incidents
Locate your ticket and open
Verify that the Workflow is attached for Incident