Azure DevOps Setup
Copado’s integration with Azure DevOps allows you to work on your user stories by easily creating a project and importing your work items to the project in Copado. Let’s see how you can set up this integration and start leveraging Copado and Azure DevOps.
In order to get the integration up and running, you need to make the following configurations:
- Install the Copado Change Management Integrations package.
- Create a named credential.
- Create a Copado Integration Setting record.
- Customize the Project object’s layout.
- Update your project in Copado or create a new one if there is none.
Installing the Copado Change Management Integrations Package
The first thing you need to do is install the Copado Change Management Integrations package.
- If you are installing the package in a production/developer org, use this link: https://login.salesforce.com/packaging/installPackage.apexp?p0=04t1r000000b6f5.
- If you are installing the package in a sandbox, use this link: https://test.salesforce.com/packaging/installPackage.apexp?p0=04t1r000000b6f5.
You can choose to install the package for admins only (recommended option) or for specific profiles.
Creating the Named Credential
Once the package has been successfully installed, the next step will be to create a named credential. A named credential specifies the callout endpoint's URL and the authentication settings that are required for Salesforce to make callouts to the remote system.
To create the named credential, follow the steps below:
- Go to Setup > Named Credentials.
- Click on New Named Credential.
- Type in a label for your named credential and insert the URL. The accepted Azure DevOps URL is “https://dev.azure.com/[OrganizationName]/”. Taking Copado Academy as organization name, the URL would look like this: https://dev.azure.com/CopadoAcademy/.
- Choose Named Principal as Identity Type.
- Select Password Authentication as Authentication Protocol.
- Enter your username and the Azure DevOps API token. If you don’t have an API token yet, follow these steps to create one:
- Sign in to your organization in Azure DevOps using “https://dev.azure.com/[CompanyName]”.
- Go to your profile and select Security.
- Click on New Token.
- Give your token a name and set an expiration date.
- Make sure the Generate Authentication Header checkbox is enabled and click on Save.
Creating the Copado Integration Setting Record
Now that you have the named credential, you need to create a Copado Integration Setting record to link the named credential with the project where you would like to import your work items.
- Navigate to the Copado Integration Setting tab and click on New.
- Give the setting a name.
- In the External System field, select Visual Studio Team Services.
- In the Named Credential field, type in exactly the same name (API name) you used for the named credential.
- Click on Save.
Customizing the Project Layout
In order for you to be able to make the necessary changes to the project, you will need to add a few elements to the project layout.
- Go to Setup > Object Manager > Project.
- Click on Page Layouts and then on Project Layout.
- Add the following fields to the layout:
- Workspace Id
- Project External Id
- Copado Integration Setting
- Enable Logs
- Add the Sync External User Stories button. This button will be used to fetch and import Azure items on demand.
- Add the following related lists:
- Field Mappings. Click on the wrench icon in the related list to open the related list properties and include the fields as related list’s columns:
- Field Mapping Name
- Salesforce Field Name
- Third Party Field Name
- Exclude from Salesforce update
- Exclude from Third Party update
- Created by
- Last Modified by
- Callout Logs
Updating an Existing Project or Creating a New One
Finally, it is time to define the project information.
- Navigate to the project where you want to import your Azure DevOps work items. If you have not created a project yet, follow the instructions in the article Project Overview and Setup to create a new one.
- In the Copado Integration Setting lookup, find the setting you have previously created.
- Populate the Project Id from Azure DevOps. This will be the name of the project as shown in Project details in Azure.
- Enter the Workspace Id from Azure DevOps.
- Build a query that suits your needs.
- Click on Run Query to test it and then on Save Query if you are happy with the result.
- Give your query a name and select a folder to store it. Then, click on OK.