Azure DevOps Integration through Zoho Flow
Use Case
You can integrate ServiceDesk Plus with Azure DevOps through Zoho Flow. With this integration, you can create a new work-item in Azure DevOps when a request is created in ServiceDesk Plus as well as update a request in ServiceDesk Plus when the corresponding work-item is updated in Azure DevOps.
To integrate ServiceDesk Plus with Azure Devops, you need to create a Azure DevOps connection.
Create Azure DevOps Connection
In order to access the Azure DevOps application through Zoho Flow, you need to create a connection.
- Navigate to Settings tab in left navbar and click on Connections subtab and click Create Connection and select Azure DevOps application.

- Fill out the details in the form and click on Authorize. A microsoft login page opens up(if not logged-in).


What is a Flow?
A flow is the combination of a trigger and action(s). The trigger kick-starts the flow, and the actions are tasks that are executed by the flow.
Create Integration Flow from ServiceDesk Plus to DevOps
In this flow, when a request is created in ServiceDesk Plus, a related work-item will be created in Azure DevOps. To manage the relationship between a work-item and request you need to add additional fields to store the ID of the related work-item/request.
- Add sdp_request_id field in Azure DevOps.
- Add devops_id(single line text) field in SDP OnPremise.
- Please follow these links on how to add additional fields(SDP, DevOps).
- Click the Create Flow button on "My Flows"(present on left navbar) page to start a new flow.

- Create flow form will be opened with required fields, fill in the details and click on Create.

- Next step is to select the type of the trigger, since the trigger is being sent by the ServiceDesk Plus application, you need to select App as type of trigger.

- A list of all the apps supported by Zoho Flow will be shown. Search for "ServiceDesk Plus On-Premises" and select the SDP app.

- Select the trigger event out of the list of events supported by ServiceDesk Plus. In this flow the trigger event is "Request created in template", i.e whenever a request is created under the "Azure DevOps Template" in ServiceDesk Plus application.

- A form opens up with required fields, after populating the data, click Done.

- In the above image, the Filter criterion is selected as "Priority" equals "High" i.e this trigger will be executed when a request with high priority is created in the "Azure DevOps Template"(Filter criteria is optional based on the requirement).
- Decision actions is to check if "devops_id" is null, i.e checking if any work item is already associated with the request. If it's null, it'll proceed to the next action, otherwise it will end the process(devops_id is added as an additional field in Azure DevOps template to store the associated work item ID), double click on the condition name and change it to an appropriate name as you changed it to devops_is null check. Please refer to this document on how to create a decision.


- When "devops_id" is null, a new work item needs to be created with the details same as request(subject of the request), on left side of the builder list of all the apps supported by ZohoFlow will be shown, search for Azure DevOps and select the app. A list of all the actions supported by DevOps will be shown, drag and drop the "Create Work Item" action to success output of decision box.


- A popup opens up with create work-item fields. Fill in the details as required.



- Since the main goal is to create a work item with a title same as the subject in the request, the title field in "Create Work item" is provided with input with the subject value of the trigger(which contains the subject of the request created).

- To enter value to a field, click on the empty input box of the field first which highlights the field and then click on the fields on the right side(trigger/action(s)). In the above screenshot, you can see that ${request.subject} has been set as a value input in title input box, since the provided variable name of the trigger is request hence it's accessed as ${request.subject}.

- After adding a work-item in DevOps, you have to associate it with the request. For that, you need to update DevOps work-item ID on request as devops_id, Search for "Servicedesk Plus On-Premises" in apps search and select "Update Request" action. This action will update the created work item ID as devops_id in the request.


- In "Update Request" action, the ID of the request has been fetched from "Requested Created in Template" trigger and "devops_id" from "Create Work-item" action.
Update Integration flow from Azure to SDP
To update the integration flow from Azure to ServiceDesk Plus, click the Create Flow button on "My Flows"(present in left navbar) page to start a new flow.
- In the new form, fill in the details and click on "Create".
- Select the type of the trigger, since the trigger is being sent by the Azure DevOps application you need to select App as type of trigger.
- A List of all the apps supported by Zoho Flow will be shown, search "Azure DevOps" and select the DevOps app.
- Select the trigger event out of list of events supported by Azure DevOps, In this flow the trigger event is "Work-item Updated", i.e whenever a work-item has been updated in Azure DevOps application.


- In the trigger, select the work-item type as "Issue" and field as "State", i.e the type of the updated work-item has to be "Issue" and the field which has been updated should be "State" to initiate the trigger.

- Decision action is to check weather "sdp_request_id" is not null, i.e checking whether request is associated with the work item. If it's null it will end the process if not it will proceed to next action.


- When "sdp_request_id" is not null "Update Request" will be executed and the request will be updated in SDP with state of the work-item. Search for "Service desk Plus On-Premises in the apps list and select "Update Request" action".

- Since the state of a work-item changes every time, it's inappropriate to select a particular status value for the status field in the "Update Request" action, hence you need to select "Use Custom Value" and provide the value in the textbox. Here the value of the status will be the state of the work-item. Hence, you need to fetch it from the fields of "Work-item Updated" trigger.
