Collect Smartscape topology data from Dynatrace

This page describes StackState version 4.1.

The StackState 4.1 version range is End of Life (EOL) and no longer supported. We encourage customers still running the 4.1 version range to upgrade to a more recent release.

Go to the documentation for the latest StackState release.


The Dynatrace StackPack creates a synchronization between a Dynatrace instance and StackState. When the integration is enabled, Dynatrace Smartscape topology from the last 72 hours will be added to the topology in StackState.

  • Agent V2 connects to the configured Dynatrace API to retrieve Smartscape topology data from the last 72 hours.

  • Agent V2 pushes retrieved data to StackState.

  • StackState translates incoming Dynatrace data into topology components and relations.



To set up the Dynatrace integration you will need to have:

  • StackState Agent V2 installed on a machine that can connect to both Dynatrace and StackState.

  • A running Dynatrace instance.

  • A Dynatrace API Token with access to read the Smartscape Topology, see REST API endpoints.


Install the Dynatrace StackPack from the StackState UI StackPacks > Integrations screen. You will need to provide the following parameters:

  • Dynatrace URL - the Dynatrace URL from which topology will be collected.

  • Dynatrace Instance Name - the user-defined name of the Dynatrace account shown in configurations such as views.


To enable the Dynatrace check and begin collecting data from Dynatrace, add the following configuration to StackState Agent V2:

  1. Edit the Agent integration configuration file /etc/sts-agent/conf.d/dynatrace_topology.d/conf.yaml to include details of your Dynatrace instance:

    • url - the URL of the Dynatrace instance.

    • token - an API token with access to the required Dynatrace API endpoints.

      # Section used for global dynatrace check config
      # mandatory
      - url: <url> # URL of the Dynatrace instance
        token: <token> # API-Token to connect to Dynatrace
        # verify: True  # By default its True
        # cert: /path/to/cert.pem
        # keyfile: /path/to/key.pem
        # domain: <domain>  # default 'dynatrace'
        # environment: <environment>    # default 'production'
        # tags:
        #   - foo:bar
  2. Optional: Add a domain and environment in the conf.yaml file to specify where imported Dynatrace topology will end up in StackState (default domain=dynatrace and environment=production).

  3. Restart the StackState Agent(s) to apply the configuration changes.

  4. Once the Agent has restarted, wait for data to be collected from Dynatrace and sent to StackState.


To check the status of the Dynatrace integration, run the status subcommand and look for Dynatrace under Running Checks:

sudo stackstate-agent status

Integration details

REST API endpoints

The API Token configured in StackState Agent V2 must have the permission Access problems and event feed, metrics, and topology (API value DataExport), see Dynatrace API token permissions (dynatrace.com) for details. The API endpoints used in the StackState integration are listed below:

  • /api/v1/entity/applications

  • /api/v1/entity/infrastructure/hosts

  • /api/v1/entity/infrastructure/processes

  • /api/v1/entity/infrastructure/process-groups

  • /api/v1/entity/services

Refer to the Dynatrace documentation for details on how to create an API Token.

Data retrieved


The Dynatrace check does not retrieve any events data.


The Dynatrace check does not retrieve any metrics data.


The Dynatrace check retrieves the following topology data from Dynatrace:




Smartscape Applications, Hosts, Processes, Process-Groups and Services from the last 72 hours.


Relations between the imported components are included in the component data retrieved from Dynatrace.


The Dynatrace check does not retrieve any traces data.

Dynatrace filters for StackState views

When the Dynatrace integration is enabled, the following additional keys can be used to filter views in the StackState UI:

  • dynatrace-ManagementZones

  • dynatrace-EntityID

  • dynatrace-Tags

  • dynatrace-MonitoringState

For example, to filter a view by Dynatrace Management Zone, add the key dynatrace-managementZones:<value> to the Labels filter box.

Open source

The code for the Dynatrace check is open source and available on GitHub at: https://github.com/StackVista/stackstate-agent-integrations/tree/master/dynatrace_topology


Troubleshooting steps for any known issues can be found in the StackState support Knowledge base.


To uninstall the Dynatrace StackPack and disable the Dynatrace check:

  1. Go to the StackState UI StackPacks > Integrations > Dynatrace screen and click UNINSTALL.

    • All Dynatrace specific configuration will be removed from StackState.

  2. Remove or rename the Agent integration configuration file, for example:

     mv dynatrace.d/conf.yaml dynatrace.d/conf.yaml.bak
  3. Restart the StackState Agent(s) to apply the configuration changes.

See also

Last updated