Skip to content

Targets Reference ​

Targets are the platforms where TestBeats delivers your test results. Each target represents a specific communication channel or data destination.

Available Targets ​

Communication Platforms ​

TargetDescriptionConfiguration
SlackSend results to Slack channelsWebhook URL
TeamsSend results to Microsoft TeamsWebhook URL
ChatSend results to Google ChatWebhook URL
GitHubPublish results to GitHub PRsGitHub Token

Data and integration targets ​

TargetDescriptionConfiguration
InfluxDBStore metrics in InfluxDBConnection details
HTTPPOST payloads to a custom HTTP endpointURL, headers, etc.

Utility targets ​

TargetDescriptionConfiguration
GitHub OutputWrite results to GITHUB_OUTPUT (GitHub Actions)Output file path / env
CustomCustom webhook integrationCustom endpoint
DelayAdd delays between targetsDuration

Target Configuration ​

Command Line Mode ​

For simple single-target setups:

bash
# Slack
npx testbeats@latest publish --slack '<webhook-url>' --junit '<report-path>'

# Teams
npx testbeats@latest publish --teams '<webhook-url>' --junit '<report-path>'

# Google Chat
npx testbeats@latest publish --chat '<webhook-url>' --junit '<report-path>'

# GitHub
npx testbeats@latest publish --github '<github-token>' --junit '<report-path>'

For local or non-Actions runs, use a configuration file and set inputs.owner, inputs.repo, and inputs.pull_number as needed.

Configuration Mode ​

For complex multi-target setups:

json
{
  "targets": [
    {
      "name": "slack",
      "condition": "fail",
      "inputs": {
        "url": "<webhook-url>",
        "publish": "test-summary"
      }
    }
  ]
}

Target Properties ​

Core Properties ​

PropertyTypeDescriptionDefault
namestringTarget type identifierRequired
conditionstringWhen to execute targetpassOrFail
inputsobjectTarget-specific configuration{}
extensionsarrayEnabled extensions[]

Common Input Properties ​

Most communication targets support these properties:

PropertyTypeDescriptionDefault
urlstringWebhook or endpoint URLRequired
publishstringReport type to publish"test-summary"
only_failuresbooleanShow only failed testsfalse
titlestringCustom report titleAuto-generated
title_linkstringClickable link on titleNone
title_suffixstringText appended to titleNone
max_suitesnumberMaximum suites to show10

Report Types ​

test-summary ​

Complete test results with suite breakdown and metrics.

test-summary-slim ​

Condensed results without suite details. Ideal for primary channels.

failure-details ​

Detailed information about failed tests including error messages.

Conditions ​

Control when targets execute based on test results:

ConditionDescription
"passOrFail"Always execute (default)
"pass"Execute only when all tests pass
"fail"Execute only when tests fail

Multiple Targets Example ​

json
{
  "targets": [
    {
      "name": "slack",
      "condition": "fail",
      "inputs": {
        "url": "<dev-channel-webhook>",
        "publish": "failure-details"
      }
    },
    {
      "name": "teams",
      "condition": "passOrFail",
      "inputs": {
        "url": "<stakeholder-channel-webhook>",
        "publish": "test-summary-slim"
      }
    },
    {
      "name": "influx",
      "inputs": {
        "url": "http://localhost:8086",
        "db": "PerfTestResults"
      }
    }
  ]
}

Next Steps ​

Released under the MIT License.