Azure DevOps Integration (via Microsoft Power Automate) - Create Bug and Task Work Items
IntegrationIntroduction
You can integrate third-party systems with Service Manager in many ways. The method you select will depend on business requirements, architectural and security constraints as well as the characteristics specific to each third-party application or service.
This document describes an integration process that has already been implemented in a customer context.
To find out more about this integration (e.g. scripts to be used), please do not hesitate to contact your EasyVista contact, or your service provider and integrator.
Overview of the integration
Azure DevOps is a Microsoft solution. It is a management tool for DevOps projects that ensures monitoring for tasks, deadlines, problems and calendars relating to applications.
This integration enables you to create two work items, Bug and Task in Azure DevOps when a ticket is created in Service Manager, via Microsoft Power Automate.
- The number of the Bug work item is saved in the Service Manager ticket.
- The Task work item is associated with the Bug work item.
Preview of the tools used in this integration
- Microsoft Power Automate (formerly known as Microsoft Flow) enables you to automate recurrent tasks by building workflows using Web applications. These applications use MS Power Automate connectors (based on Microsoft Azure Logic Apps) or the MS Graph gateway for interfacing with any endpoint via HTTP/HTTPS.
Integration Data Feed (direction) | Authentication Type | Integration Connector Options | ||
---|---|---|---|---|
|
|
|
Available versions | ||
---|---|---|
SaaS-based | On-premises | |
Service Manager | ![]() |
![]() |
Third-Party Product | ![]() |
N/A |
Azure DevOps - definitions
Definitions_AzureDevOps
- Azure DevOps is a Microsoft solution. It is a management tool for DevOps projects that ensures monitoring for tasks, deadlines, problems and calendars relating to applications.
- Work items are used to monitor functionalities and specifications, code errors, bugs, etc.
- Each work item is based on a work item type and has a unique ID.
- The work item types available are based on the processes used when creating projects, e.g. agile, scrum, etc. They can be configured differently by each team.
- The Bug work item type is used for tracking bugs.
- The Task work item type is used for monitoring activity and tasks.
- Work items can be assigned to other work items according to a hierarchy based on parent-child relationships.
Microsoft Power Automate flows
The integration between Service Manager and Azure DevOps will trigger a flow in Microsoft Power Automate when a ticket is created in Service Manager.
==> Create Bug and Task work items in Azure DevOps flow
Prerequisites
- You must have an Azure subscription. If this is not the case, you can create a free account, or you can buy an Azure Pay-As-You-Go subscription.
- You must have an Azure DevOps account.
- You must ask EasyVista to create two fields in the SD_REQUEST table which will be specific to Azure DevOps and GitHub.
- You must create the Bug and Task work items in Azure DevOps for the process template used by your DevOps project.
See the procedure.
- You must create two custom fields for the Bug work item to store the Service Manager ticket references.
See the procedure.
Best Practice
BestPractice
- The procedure describes all of the steps for creating Microsoft Power Automate flows. To facilitate integration, the ZIP folders shipped with this integration contain pre-configured flows. Once you have downloaded them, you should specify the parameters specific to your environment, i.e. Azure account credentials, EasyVista server address, credentials of your Service Manager platform, etc.
- Use the search field to find the connectors and actions to be created in the MS Power Automate workflow easily.
example Find the actions for the Azure DevOps connector
Caution
Caution_TitleActionInPowerAutomateFlow
- When you create workflow actions in Microsoft Power Automate, you must rename them as indicated in the procedure. This is because certain items of information in the name refer to the title of the action. If you do not respect the naming convention, the workflow will not be triggered correctly.
example The split(body('Analyze_Ticket_Info')'')?['AVAILABLE_FIELD_6'],',') instruction refers to the action called Analyze Ticket Info
Note: Spaces in the title will automatically be replaced by the underscore _.
Integration process
Prerequisite Ask EasyVista to create two fields in the SD_REQUEST table which will be specific to Azure DevOps and GitHub. Add them to the ticket form. See the detailed procedure.
1. Create the Bug and Task work items in Azure DevOps for the process template used by your DevOps project. See the detailed procedure.
2. Create the two custom fields for the Bug work item to store the Service Manager ticket references. See the detailed procedure.
3. Create the MS Power Automate flow. See the step-by-step integration process.
- Note: This requires a connection to Azure DevOps.
Import the preconfigured flow below containing all of the steps to MS Power Automate.
See the procedure for importing flows.
Step-by-Step Integration Process
AddDevOpsFieldsInTicketForm_Procedure
Add fields specific to Azure DevOps and GitHub to the SD_REQUEST table
Step 1: Ask EasyVista to add fields to the database
1. Ask EasyVista to add the following two fields.
- Field called E_ADO_NUMBER, nvarchar data type, size 20. This will store the ID of the Azure DevOps work item associated with the Service Manager ticket.
- Field called E_PR_NUMBER, nvarchar data type, size 20. This will store the number of the GitHub pull request associated with the Service Manager ticket.
Step 2: Add fields to the Ticket forms, i.e. Incident and Request forms
See the detailed procedure
1. Open each Ticket form, i.e. Incident and Request forms.
2. Click in the top banner and select Edit Form.
The main form presentation will appear.
3. Select and place the two fields in the form.
4. Click Save and click Save and Close.
The form will be refreshed.
Create the Bug and Task work items
Caution: Make sure you create the work items in the process template or in the process used by your DevOps project.
CreateBugWorkItemType_Procedure
Step 1: Log in to Azure DevOps
1. Log in to Azure DevOps using your Azure account credentials.
2. Click the name of your organization.
3. Click Organization settings.
Step 2: Create the Bug work item type
1. Select Boards > Process in the menu pane.
The list of DevOps processes will appear.
2. Select the DevOps project in which you want to monitor tickets created in Service Manager.
The list of work item types defined for the project processes will appear.
3. Click + New work item type.
4. Specify the information on the new work item type and name it Bug.
5. Click Create.
The properties of the new work item type will appear.
Step 3: Create the Task work item type
1. Click + New work item type.
2. Specify the information on the new work item type and name it Task.
3. Click Create.
The properties of the new work item type will appear.
Step 4: Create two custom fields to store the Service Manager ticket references
CreateEZVFieldsForBugWorkItem_Procedure
1. Select the Bug work item type.
2. Click New field.
3. Specify the information on storing the ticket ID in the new field and name it EZV_ID.
4. Click Add field.
The new field will be associated with the Bug work item type in the Custom section.
5. Repeat the procedure to create the second field for storing the ticket URI and name it EZV_URI.
Import the workflow to Microsoft Power Automate
Note: This requires a connection to Azure DevOps.
Step 1: Download the flow
1. Download the file below to your workstation.
ImportFlowInMicrosoftPowerAutomate_Procedure
Step 2: Import the flow to Microsoft Power Automate
1. Log in to the Microsoft Power Automate website using your account credentials.
2. Click My flows in the left pane.
A list of your MS Power Automate flows will appear.
3. Click Import in the menu bar and select the file you downloaded.
- Once imported, the package contents will appear.
- The
icon indicates that the connection for the resource was not found.
Step 3: Create the connections required for the flow
1. Click the Select during import link in the Import Setup column for the relevant resource.
The window for configuring the import will appear.
2. Create a new connection for the resource or select an existing connection.
There is an existing connection for the resource
- Select the connection.
- Click Save.
There is no existing connection for the resource
- Click + Create.
- An MS Power Automate instance will appear in a new Web browser tab.
- The list of existing connections will appear.
- Click + New connection.
- Find the connection you want using the search field and select it from the list.
example Find the GitHub connection
A window displaying the list of permissions to be granted to Microsoft Power Platform will appear.
- Click Create to create the new connection.
- Click Accept to accept the conditions and authorize Microsoft Power Platform access.
- You will return to the tab displaying the list of MS Power Automate flows.
- The new connection for the resource will appear in the list.
example New GitHub connection
- Close your Web browser tab.
You will return to the tab displaying the details of the imported package.
- Click Refresh List.
The new connection for the resource will appear in the window for configuring the import.
- Select the connection and click Save.
Theicon indicates that the connection for the resource has been correctly established.
3. Repeat the procedure for each connection required for the flow.
Step 4: Import package resources
1. Click Import.
The icon next to each package resource indicates that the flow has been correctly imported.
Step 5: Configure package resources
Note: You should perform this step if a message at the top of the page informs you that package resources must be configured.
1. Click Save as new flow in the message displayed at the top of the page.
- An MS Power Automate instance will appear in a new Web browser tab.
- The workflow of the imported package will appear.
2. Click the action indicating an invalid connection.
The list of all existing connections for the selected type of resource will appear.
2. Click the connection defined for the type of resource.
The properties of the action will appear. The properties displayed depend on the type of resource.
example Unspecified properties for an action using the Azure DevOps resource
3. Specify the connection information for the action.
example Properties for an action using the Azure DevOps resource
- Organization Name: Select the name of your organization.
- Project Name: Select the name of your DevOps project.
4. Repeat the procedure for each action indicating an invalid connection.
5. Click Save.
- The error message for the action will disappear.
example Action for the Azure DevOps resource
- You have configured all of the connections required for the flow.
- The workflow will be created.
Step 6: Configure the workflow
1. Move your cursor over the name of the flow and click .
The workflow will appear.
2. See the procedure for configuring the imported flow.
Create the MS Power Automate flow
Description of the Create Bug and Task work items in Azure DevOps workflow
![]() |
|
Step 1: Create the step that will trigger the flow
==> The flow is triggered when a ticket is created in Service Manager.
1. Create a When a HTTP request is received step that will trigger the workflow.
![]() |
|
Step 2: Create a Bug work item containing the Service Manager ticket references
1. Create a Create a work item action (Azure DevOps connector).
![]() |
|
Step 3: Create a Task work item in Azure DevOps containing the Service Manager ticket references
1. Create a Create a work item action (Azure DevOps connector).
![]() |
|
Step 4: Associate the Task work item with the Bug work item
1. Create an Update a work item action (Azure DevOps connector).
![]() |
|
Step 5: Store the Bug work item ID in the Service Manager ticket
1. Create a HTTP action to update the Service Manager ticket.
![]() |
|
Step 6: Save the configuration of the workflow
1. Click Save at the bottom of the flow.
Links to other integrations
- Microsoft Power Automate integration (formerly known as Microsoft Flow)
- GitHub integration (via Microsoft Power Automate)
- GitHub integration (via Microsoft Power Automate) - Approve a review
- GitHub integration (via Microsoft Power Automate) - Merge a pull request
- GitHub integration (via Microsoft Power Automate) - Close a pull request
- GitHub integration (via Microsoft Power Automate) - Close a Service Manager ticket associated with a pull request
List of files to download
Note: To find out more, see the step-by-step integration process.