Prerequisites
Configure PagerDuty integration in Backstage
Integrations are configured at the root level of theapp-config.yaml file. Here’s an example configuration for PagerDuty:
Add the PagerDutyFactCollector to Soundcheck
First, add the@spotify/backstage-plugin-soundcheck-backend-module-pagerduty package:
packages/backend/src/index.ts file:
packages/backend/src/index.ts
Plugin Configuration
The collection of PagerDuty facts is driven by the configuration. To learn more about the configuration, consult the Defining PagerDuty Fact Collectors section. PagerDuty Fact Collector can be configured via YAML or No-Code UI. If you configure it via both YAML and No-Code UI, the configurations will be merged. It’s preferable to choose a single source for the Fact Collectors configuration (either No-Code UI or YAML) to avoid confusing merge results.No-Code UI Configuration Option
- Make sure the prerequisite Configure PagerDuty integration in Backstage is completed and PagerDuty instance details are configured.
-
To enable the PagerDuty Integration, go to
Soundcheck > Integrations > PagerDutyand click theConfigurebutton. To learn more about the No-Code UI config, see the Configuring a fact collector (integration) via the no-code UI.

YAML Configuration Option
-
Create a
pagerduty-facts-collectors.yamlfile in the root of your Backstage repository and fill in all your PagerDuty Fact Collectors. A simple example PagerDuty fact collector is listed below.Note: this file will be loaded at runtime along with the rest of your Backstage configuration files, so make sure it’s available in deployed environments in the same way as yourapp-config.yamlfiles. -
Add a Soundcheck collectors field to the
app-config.yamlfile and reference the newly createdpagerduty-facts-collectors.yamlfile.
Rate Limiting (Optional)
This fact collector can be rate limited in Soundcheck using the following configuration:Defining PagerDuty Fact Collectors
This section describes the data shape and semantics of PagerDuty Fact Collectors.Overall Shape Of A PagerDuty Fact Collector
The following is an example of a descriptor file for a PagerDuty Fact Collector:frequency [optional]
The frequency at which the collector should be executed. Possible values are either a cron expression { cron: ... } or HumanDuration.
This is the default frequency for each extractor.
filter [optional]
A filter specifying which entities to collect the specified facts for. Matches the filter format used by the Catalog API.
This is the default filter for each extractor.
exclude [optional]
Entities matching this filter will be skipped during the fact collection process. Can be used in combination with filter. Matches the filter format used by the Catalog API.
cache [optional]
If the collected facts should be cached, and if so, for how long. Possible values are either true or false or a nested { duration: HumanDuration } field.
This is the default cache config for each extractor.
collects [required]
An array describing which facts to collect and how to extract them. See below for details on the overall shape of a fact extractor.
Overall Shape Of A Fact Extractor
Each extractor supports the fields described below.type [required]
The type of the extractor (e.g. Service, Standards).
frequency [optional]
The frequency at which the fact extraction should be executed. Possible values are either a cron expression { cron: ... } or HumanDuration.
If provided, it overrides the default frequency provided at the top level. If not provided, it defaults to the frequency provided at the top level. If neither extractor’s frequency, nor default frequency is provided, the fact will only be collected on demand.
Example:
initialDelay [optional]
The amount of time that should pass before the first invocation happens. Possible values are either a cron expression { cron: ... } or HumanDuration.
Example:
batchSize [optional]
The number of entities to collect facts for at once. Optional, the default value is 1.
Note: Fact collection for a batch of entities is still considered as one hit towards the rate limits
by the Soundcheck Rate Limiting engine, while the actual number of hits
will be equal to the batchSize.
Example:
filter [optional]
A filter specifying which entities to collect the specified facts for. Matches the filter format used by the Catalog API.
If provided, it overrides the default filter provided at the top level. If not provided, it defaults to the filter provided at the top level. If neither extractor’s filter, nor default filter is provided, the fact will be collected for all entities.
See filters for more details.
exclude [optional]
Entities matching this filter will be skipped during the fact collection process. Can be used in combination with filter. Matches the filter format used by the Catalog API.
cache [optional]
If the collected facts should be cached, and if so, for how long. Possible values are either true or false or a nested { duration: HumanDuration } field.
If provided, it overrides the default cache config provided at the top level. If not provided, it defaults to the cache config provided at the top level. If neither extractor’s cache, nor default cache config is provided, the fact will not be cached.
Example:
Entity configuration
In yourcatalog-info.yaml file, add following metadata annotation to allow the plugin to map an entity to a service in PagerDuty.
Collecting Service Facts
A Service Fact contains information about a service from the PagerDuty Service API.Shape of A Service Fact Collector
The shape of a Service Fact Collector matches the Overall Shape Of A PagerDuty Fact Collector (restriction:type: Service).
Here’s an example of a Service Fact Collector configuration:
Shape of A Service Fact
The shape of a Service Fact is based on the Soundcheck Fact Schema.Shape of A Service Fact Check
The shape of a Service Fact Check matches the Shape of a Fact Check. Here’s an example of a Service Fact Check configuration:Collecting Standards Fact
The Standards Fact contains information about standards from PagerDuty Standards API.Shape of A Standards Fact Collector
The shape of a Standards Fact Collector matches the Overall Shape Of A PagerDuty Fact Collector (restriction:type: Standards).
Here’s an example of a Standards Fact Collector configuration:
Shape of A Standards Fact
The shape of a Standards Fact is based on the Soundcheck Fact Schema.Shape of A Standards Fact Check
The shape of a Standards Fact Check matches the Shape of a Fact Check. Here’s an example of a Standards Fact Check:Collecting Incidents Fact
The Incidents Fact contains information about incidents from PagerDuty Incidents API.Shape of A Incidents Fact Collector
The shape of an Incidents Fact Collector matches the Overall Shape Of A PagerDuty Fact Collector (restriction:type: Incidents).
Here’s an example of an Incidents Fact Collector configuration: