---
title: TeamCity CI Plugin - Automated Selenium testing with TeamCity
description: Embed TestingBot videos, screenshots and logs from Selenium and Appium
  into TeamCity
source_url:
  html: https://testingbot.com/support/integrations/ci-cd/teamcity
  md: https://testingbot.com/support/integrations/ci-cd/teamcity.md
---

# TeamCity Automated Testing

[TeamCity](https://www.jetbrains.com/teamcity/) is a Java-based build management/CI system created by Jetbrains.

## TeamCity Plugin

We've created a plugin which offers integration with our TestingBot.com services.

Below is a list of features this plugin offers:

- Add a tab where we show the lists of tests for the current build. The overview shows a list of tests with their **passed/failed state** , together with the **browser they ran on**.
- View **logs** (Selenium, Chrome, Firefox, Safari logs) and a **recorded video** together with **screenshots** of every test, straight from inside TeamCity.
- Option to start/stop a [TestingBot Tunnel](https://testingbot.com/support/tunnel) automatically before and after every build run.
- Predefined environment variables with your TestingBot `key` and `secret`.
- Each build is **tagged** with the TestingBot session IDs it ran, so you can find a build back by session.
- Your TestingBot secret is registered with TeamCity's password replacer, so it is **masked in the build log** even if a build step prints it.

The plugin requires **TeamCity 2024.12** or newer, and Java 11 or newer on the build agent.

## 1. Install the Plugin

Go to **Administration** and click **Plugins** , under **Server Administration**.

 ![TeamCity integration](https://testingbot.com/assets/support/teamcity/1-a868f01c08bb08e04d9b1399962e69ad1044522334bc99a31090f9f3e852aa18.png)
## 2. Upload Plugin

Click **Upload plugin zip** and upload our TestingBot plugin.

Or download the plugin from the [TeamCity plugin page](https://plugins.jetbrains.com/plugin/10283-testingbot/), or from the [releases page on GitHub](https://github.com/testingbot/testingbot-teamcity-plugin/releases).

 ![TeamCity integration](https://testingbot.com/assets/support/teamcity/2-d6f082e24dc8a03b75734bc38cdbe73dd49193f934f5041fb3298150362028aa.png)
## 3. Restart TeamCity

Restart TeamCity to load the plugin. Once TeamCity is back up, the TestingBot plugin appears under **External plugins** on the same page.

## 4. Configuring a Project

Now that the plugin is installed, we can use the TestingBot plugin in a TeamCity project.

1. Click on **Build Features**
2. Click **Add build feature** and select **TestingBot** from the list. 

 ![TeamCity integration](https://testingbot.com/assets/support/teamcity/3-558f23bac8ac9771c1c35c7b28efa1bb590f3ca5c3efa44c3885533bed0f27fe.png)
## 5. Credentials

Add your TestingBot **Key** and **Secret** , which you can obtain from the member dashboard. Both are required and TeamCity will not let you save the build feature while either is empty.

Tick **Enable TestingBot Tunnel** if your tests need to reach a website that is not available on the public internet. The plugin starts a [TestingBot Tunnel](https://testingbot.com/support/tunnel) before the first build step, waits until it is ready, streams its output into the build log, and shuts it down when the build finishes.

 ![TeamCity integration](https://testingbot.com/assets/support/teamcity/4-7e43d73b3353e317b308e8cb9c3d3445de444aa989d3fe56a6e75f97912fe6b4.png)
## 6. Test Overview in TestingBot Tab

You can now see an overview of your Selenium tests in the **TestingBot tab**.

 ![TeamCity integration](https://testingbot.com/assets/support/teamcity/7-3e978be89ee3b9458ad771c1f8edb95842903a34ef160c0d06d9166068f807bf.png)
## 7. Test Details

Click a test to see a **video recording** , **screenshots** and **logs** for the test.

 ![TeamCity integration](https://testingbot.com/assets/support/teamcity/8-9b9cef361d30b29b05fe23985a96cf93ab46ef1450e022788ea4a62a22f605b2.png)
## 8. Configuring Tests

The plugin will automatically set the following **Environment Variables** , which you can use in your tests:

- `TB_KEY` : Your TestingBot key, available in our member area.
- `TB_SECRET` : Your TestingBot secret, available in our member area. TeamCity masks this value in the build log.
- `BUILD_ID` : An identifier for the current build, combining the build configuration ID and the build number. Set this as the `build` capability in your tests to group them together on TestingBot.

**Important!**  
 It is important to output `TestingBotSessionID={webdriver-session-id}` for every test to stdout.   
 The plugin will parse the output looking for these ids. An example on how to do this with Java:

```java
System.out.println("TestingBotSessionID=" + (((RemoteWebDriver) driver).getSessionId()).toString());
```

### Looking for more help?

Have questions or need more information? Reach out via email or Slack.

[Email us](https://testingbot.com/contact/new) [Join our Slack](https://join.slack.com/t/testingb0t/shared_invite/zt-3bcw9xch-jk19~6XPs_xBrsAgAedkCw)
