Microsoft Azure Pipelines Events
The built-in Azure Pipelines Events trigger initiates a flow when it receives a signal from a Microsoft Azure DevOps Pipelines service hook.
Add the Azure Pipelines Events trigger to the canvas
- Go to the Triggers panel in the palette, expand the App Triggers section and drag the trigger onto the canvas.
- Double-click the trigger (or click the pencil icon).
- Set the authenticating user, and then copy the URL — you'll use this to set up the webhook in Azure Pipelines. Alternatively, you can create an integration user to use as the authenticating user.
- Click the Flood Control tab to edit the trigger's default flood control settings. For more information about these settings, see Trigger Flood Control.
- Click Done.
- On the flow canvas, connect the steps you want to run when xMatters receives a request to that URL.
You're now ready to configure Azure Pipelines to target the trigger.
Configure Azure Pipelines to send requests to the trigger URL
To have Azure Pipelines send alerts to the flow trigger, you need to configure a webhook and set it to use the trigger URL.
- In Azure Pipelines, click Project settings at the bottom of the left-hand menu.
- Click Service hooks on the left-hand menu to open the Service Hooks page. Click the green plus sign to add a new service hook.
- In the Service window, select Web Hooks from the left-hand menu, and then click Next.
- In the Trigger window, fill in the following fields:
- Trigger on this type of event field: Select one of the following xMatters-supported options:
- Build completed
- Release deployment completed
- Release deployment approval completed
- Run stage approval completed
- Filters: Set your filters. (optional)
- Trigger on this type of event field: Select one of the following xMatters-supported options:
- Click Next.
- In the Action window, fill in the following fields:
- URL: Paste the trigger URL you copied from Flow Designer. Add the target names of any recipients you want xMatters to notify when the alert fires to the end of the URL.
- For URL authentication, use an ampersand to attach recipients. For example, if you want to notify Emma Pearson and the on-call members in the group responsible for the Antares service, you'd add &recipients=epearson,antares to the URL.
- For other authentication types, use a question mark to attach recipients. For example, if you want to notify Barry Gull and the on-call members in the group responsible for the Cassiopeia service, you'd add ?recipients=bgull,cassiopeia to the URL.
- You must URL-encode any special characters or spaces in the target names.
- Optional: If you chose to use Basic Authentication, fill in your username and password in the Basic authentication username and Basic authentication password fields.
- HTTP headers: Leave blank.
- Resource details to send: All
- Messages to send: All
- Detailed messages to send: All
- Resource Version: 1.0
- URL: Paste the trigger URL you copied from Flow Designer. Add the target names of any recipients you want xMatters to notify when the alert fires to the end of the URL.
- Click Test if you want to test service hook you just configured.
- Click Finish.
You're ready to use the webhook to trigger automated flows, including steps such as sending alerts and initiating incidents, though we always recommend testing before putting things into use.
Outputs
The trigger has the following outputs you can use as inputs to steps further along the flow.
Label |
Description |
---|---|
Recipients |
List of targeted recipients. |
Signal ID | Key or identifier used to terminate or correlate events/signals. |
Event Type | Type of Azure Pipeline event. |
Publisher ID | Unique identifier of the publisher as set in Azure Pipelines. |
Message | Description of the event as provided by Azure Pipelines. |
Created Date | Date and time the Azure Pipelines event was created. |
Status | Status of the event in Azure Pipelines. |
Completed |
Whether the event is considered complete in Azure Pipelines. Available values are:
|
Organization | Name of the Azure Pipelines organization. |
Project Name | Name of the project that contains the event. |
Direct Link | Direct link to the Azure Pipelines event. |
Branch | Branch where the build or release was run. |
Pipeline or Release Name | Name of the pipeline or release. |
Raw Request | JSON representation of the request that can be parsed separately to get additional context on outputs. |