Antithesis logomark
DOCS

Tooling integrations

Antithesis offers tooling integrations that help you fit Antithesis into your development cycle with ease. You can launch tests directly from your CI/CD pipeline via GitHub Actions, get results posted to Discord or Slack, and create tickets for failures with the issue tracker integration.

CI integration

Antithesis provides native integration with GitHub Actions via the Antithesis Trigger Action. You can easily trigger a test run via a GitHub action and have the results reported back natively in GitHub. Follow the README to set it up.

Discord and Slack integration

When you run tests, Antithesis will generate triage reports and email them to you. In addition, you may configure the test to post back results to a platform of your choice. This document covers how to configure this integration with Discord and Slack.

This is an example of an Antithesis API endpoint that kicks off a test and posts the results back to Discord (and also GitHub):

curl --fail $AUTH -X POST \
https://$ANTITHESIS_TENANT.antithesis.com/api/v1/launch/<ENDPOINT> \
-d '{"params": { "antithesis.description":"Nightly testing on main",
"antithesis.integrations.discord.callback_url": "https://discord.com/api/webhooks/1234567890123456789/",
"antithesis.integrations.discord.token": "<SECRET>",
"antithesis.integrations.github.callback_url": "<URL>",
"antithesis.integrations.github.token": "<SECRET>",
"antithesis.images":"my_images_with_version_list" } }'

You can also add the callback URL and token for Discord or Slack to the Antithesis GitHub Action as additional parameters. Here’s an example that posts back to Discord and Slack:

additional_parameters: |-
antithesis.integrations.discord.callback_url=<DISCORD_CALLBACK_URL>
antithesis.integrations.discord.token=<DISCORD_SECRET>
antithesis.integrations.slack.callback_url=<SLACK_CALLBACK_URL>
antithesis.integrations.slack.token=<SLACK_SECRET>

See the API reference for the syntax of API calls in general. The remainder of this document describes how to generate the following parameters for Antithesis:

antithesis.integrations.<INTEGRATION_TYPE>.callback_url
antithesis.integrations.<INTEGRATION_TYPE>.token

where <INTEGRATION_TYPE> is discord or slack.

Importantly, you will need to go to your messaging app to generate these parameters, but then paste the generated parameters into your Antithesis API call.

  1. Begin in the server where you want your Antithesis results to be posted. Follow the directions in the Discord webhook docs, to create a new webhook. The steps below are correct as of September 2024.
  2. Navigate to Server Settings and then to Integrations.
  3. Create a new webhook.
  4. Copy the webhook URL.

The URL will look something like:

https://discord.com/api/webhooks/000000000000000000/1111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111

Everything up to and including the final forward slash is the callback URL. Everything after the final forward slash is the token. You should treat the token as a secret.

  1. Paste the callback URL and token into your webhook call as follows:
antithesis.integrations.discord.callback_url: https://discord.com/api/webhooks/000000000000000000/
antithesis.integrations.discord.token: 1111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111

When this integration is enabled, you will see results like the following:

Discord Integration Example
  1. First, create a Slack app associated with the workspace where you want to post the results. The most current directions for doing this can be found at the Slack webhook docs documentation. The steps below are correct as of September 2024.
  2. Click on dropdown arrow next to the name of your workspace. This will create a dropdown menu. Select Tools & settings and then Manage apps.
  3. On the new screen, select Build. The Create New App button will pop up a menu. Select From scratch. Follow the prompts to create a new app.
  4. On the new screen, select Incoming Webhooks in the Features section. Ensure that incoming webhooks are enabled and click the button labeled Add New Webhook to Workspace.
  5. Pick the channel where you want your Antithesis results to be posted, and click Allow.
  6. You should now see a section Webhook URLs for Your Workspace. Copy the webhook URL, which will look something like:
https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX

Everything up to and including the final forward slash is the callback URL. Everything after the final forward slash is the token. You should treat the token as a secret.

  1. Following the example at the top of this page, paste the callback URL and token into your API call:
antithesis.integrations.slack.callback_url: https://hooks.slack.com/services/T00000000/B00000000/
antithesis.integrations.slack.token: XXXXXXXXXXXXXXXXXXXXXXXX

When this integration is enabled, you will see results like the following:

Slack Integration Example

Issue tracker integration

Antithesis makes it easy to create tickets in your issue tracker directly from a Finding or group of Findings.

When you click the “Create ticket” button, your issue tracker opens in a new tab with a pre-filled create ticket form. You’ll just need to click “create.”

Create ticket example 1
Create ticket example 2

How to set it up

Simply send your issue tracker’s URL to your customer success engineer to enable the integration.

Supported issue trackers

https://linear.app/YOUR_TEAM_NAME/new
  • YOUR_TEAM_NAME: Your team name in Linear (visible in the URL when using the web app).
https://ORGANIZATION.atlassian.net/secure/CreateIssueDetails!init.jspa?pid=PROJECT_ID&issuetype=ISSUE_TYPE_ID
  • ORGANIZATION: Your Jira Cloud organization name (part of their domain).

  • PROJECT_ID: The internal project ID. To find this, export an issue to XML and look for the ID in the <project> tag.

  • ISSUE_TYPE_ID: Tickets will be created with this issue type. To find this, export an issue to XML and look for the ID in the <type> tag.

Jira Export XML option
Jira XML example
https://github.com/ORG/REPO/issues/new
  • ORG: Your GitHub organization or user name.
  • REPO: Issues will be created in this repo.
https://gitlab.com/YOUR_GROUP/YOUR_PROJECT/-/issues/new
  • GROUP: Your group or namespace in GitLab.
  • PROJECT: Issues will be created in this project.
https://trello.com/add-card?mode=popup&url=https://trello.com/b/BOARDID
  • BOARDID: The ID of your Trello board.