Yes, there is a way to obtain the dynamic sysid (incident sysid) within your UiPath workflow when integrating with ServiceNow.
To achieve this, you can follow these steps:
After submitting the incident to ServiceNow, you can use the “Get Output Properties” activity in UiPath to retrieve the response from the integration service.
The response obtained from the integration service will typically contain information about the created incident, including the sysid. You can extract the sysid from the response using JSON manipulation techniques.
Use the appropriate JSON activities in UiPath (such as Deserialize JSON or Deserialize JSON Array) to parse the response and extract the sysid value.
Once you have extracted the sysid, you can store it in a variable for further use within your workflow or pass it to other activities as needed.
Make sure you have a variable defined to store the sysid. Let’s call it incidentSysID.
After submitting the incident to ServiceNow, you can use the “Get Output” activity to retrieve the dynamic sysid.
In the properties panel of the “Get Output” activity, set the following values:
Target: Select the ServiceNow integration service you have configured.
Output: Select the variable incidentSysID where you want to store the sysid.
Specify the correct output property in the Output field. The specific property will depend on the response structure returned by the ServiceNow integration service. For example, if the sysid is returned as part of the “Create Incident” response, the output property might be responseContent.result.sys_id.
After executing the “Get Output” activity, the sysid will be stored in the incidentSysID variable. You can use this variable later in your workflow as needed.
By retrieving the sysid dynamically in this manner, you won’t have to manually input it in the workflow. Instead, it will be obtained from the ServiceNow integration service response and stored in the incidentSysID variable for further use within the UiPath flow.