Managing Projects
Projects organize build configurations and subprojects in TeamCity. The teamcity project command group lets you browse projects, manage VCS roots, manage parameters, handle secure tokens for versioned settings, and export or validate project configuration.
Listing projects
View all TeamCity projects:

Filter by parent project:
Limit results and output as JSON:
project list flags
Flag | Description |
|---|---|
| Filter by parent project ID |
| Maximum number of projects to display |
| Output as JSON. Use |
Project tree
Display the project hierarchy as a tree, including subprojects and build configurations:

Show a specific subtree:
Hide build configurations to see only the project structure:
Limit the tree depth:
project tree flags
Flag | Description |
|---|---|
| Hide build configurations, show only projects |
| Limit tree depth (0 = unlimited) |
Creating a project
Create a new project under the Root project:
Create with an explicit ID:
Create under a parent project:
Output the created project as JSON (useful for scripting):
project create flags
Flag | Description |
|---|---|
| Explicit project ID. Defaults to an ID auto-generated by TeamCity from the name. |
| Parent project ID. Defaults to |
| Output as JSON |
| Open the new project in the browser after creating |
Viewing project details
View details of a project:
Open the project page in your browser:
Output as JSON:
Managing VCS roots
VCS roots define the connection between TeamCity and your version control repository. They are project-level entities, visible to child projects through inheritance.
Listing VCS roots
Viewing VCS root details
The view command shows all VCS root properties with human-readable labels. Secure properties (passwords, passphrases) are masked as ********.

Creating a VCS root
Create a Git VCS root with an interactive wizard or flags:
The wizard prompts for the repository URL, display name, and authentication method. Six auth methods are supported:
By default, the command tests the connection before creating. Skip with --no-test:
vcs create flags
Flag | Description |
|---|---|
| Repository URL |
| Display name (auto-generated from URL if omitted) |
| Project ID (default: _Root) |
| Auth method: |
| Username (for password auth) |
| Password or personal access token |
| Read password from stdin |
| Name of SSH key uploaded to TeamCity |
| Path to SSH key file on the build agent |
| SSH key passphrase |
| OAuth connection ID |
| Default branch (default: |
| Branch specification |
| Skip connection test before creating |
Testing a VCS root connection
Test whether an existing VCS root can connect to the repository:
Deleting a VCS root
Managing SSH keys
SSH keys uploaded to a project can be used for VCS root authentication (TEAMCITY_SSH_KEY auth method). Keys are inherited by child projects.
Listing SSH keys
Generating an SSH key pair
Generate an ed25519 or RSA key pair directly in TeamCity and print the public key:
Add the printed public key as a deploy key in your Git hosting provider.
Uploading an SSH key
Deleting an SSH key
Project connections
Connections (OAuth providers, Docker registries, cloud integrations) are configured at the project level. They let TeamCity talk to external services without storing credentials in individual jobs, and the CLI can list, create, authorize, and delete them.
See Configuring Connections for the full TeamCity reference.
Listing connections
The first column shows the connection ID (for example, PROJECT_EXT_42). That ID is what authorize, delete, and vcs create --auth token consume.
Creating a GitHub App connection
Register a GitHub App in a project. A GitHub App authenticates as itself (no per-user token), which is the right choice for CI workflows that don't need user-context OAuth.
In interactive mode, the CLI registers a brand-new App via GitHub's manifest flow — it opens a browser, you click Create, and the credentials come back automatically:
If you already have a GitHub App, pass --no-manifest and supply the credentials yourself:
After creation the CLI prompts to run authorize so the current user gets a token bound to the App. Skip the prompt with --no-authorize.
Creating a Docker registry connection
Register Docker registry credentials so jobs can pull and push images without inlining secrets:
In non-interactive setups (CI/CD), feed the password through stdin:
Authorizing a connection
OAuth-style connections (GitHub App, Bitbucket, GitLab, …) need a per-user authorization step before TeamCity can call upstream as that user. This is required, for example, before vcs create --auth token can verify a repository over the connection.
The command opens a browser to complete the OAuth flow and stores the resulting token against the current user. Connection types without a user OAuth flow (Docker, AWS) return an error.
Deleting a connection
Pass --force (or -f) to skip the interactive confirmation prompt — useful in scripts.
Managing project parameters
Project parameters are inherited by all build configurations within the project. They work identically to job parameters.
Listing parameters
Getting a parameter value
Setting a parameter
Deleting a parameter
Secure tokens
Secure tokens allow you to reference sensitive values (passwords, API keys) in versioned settings without storing them in version control. The actual values are kept securely in TeamCity and referenced using credentialsJSON:<token> identifiers.
Storing a secure token
Store a sensitive value and receive a token reference:
The command returns a token in the format credentialsJSON:<uuid>. Use this token in your versioned settings configuration files.
Retrieving a secure token value
Retrieve the original value for a secure token:
Versioned settings
Exporting project settings
Export project settings as a ZIP archive containing Kotlin DSL or XML configuration:
The exported archive can be used to version control your CI/CD configuration, migrate settings between TeamCity instances, or review settings as code.
settings export flags
Flag | Description |
|---|---|
| Export as Kotlin DSL (default) |
| Export as XML |
| Output file path (default: |
| Use relative IDs in the exported settings (enabled by default) |
Viewing versioned settings sync status
Check the synchronization status of versioned settings for a project:
This displays whether versioned settings are enabled, the current sync state, last successful sync timestamp, VCS root and format information, and any errors from the last sync attempt.
Validating Kotlin DSL
Validate Kotlin DSL configuration by running the TeamCity configuration generator:
The command auto-detects the .teamcity directory in the current directory or its parents. It requires Maven (mvn) or uses the Maven wrapper (mvnw) if present in the DSL directory.