TeamCity · Capability

TeamCity REST API — VCS Roots

TeamCity REST API — VCS Roots. 4 operations. Lead operation: Get All VCS Roots. Self-contained Naftiko capability covering one Teamcity business surface.

Run with Naftiko TeamcityVCS Roots

What You Can Do

GET
Getallvcsroots — Get All VCS Roots
/v1/vcs-roots
POST
Createvcsroot — Create VCS Root
/v1/vcs-roots
GET
Getvcsroot — Get VCS Root
/v1/vcs-roots/{vcsrootlocator}
DELETE
Deletevcsroot — Delete VCS Root
/v1/vcs-roots/{vcsrootlocator}

MCP Tools

get-all-vcs-roots

Get All VCS Roots

read-only idempotent
create-vcs-root

Create VCS Root

get-vcs-root

Get VCS Root

read-only idempotent
delete-vcs-root

Delete VCS Root

idempotent

Capability Spec

rest-vcs-roots.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: TeamCity REST API — VCS Roots
  description: 'TeamCity REST API — VCS Roots. 4 operations. Lead operation: Get All VCS Roots. Self-contained Naftiko capability
    covering one Teamcity business surface.'
  tags:
  - Teamcity
  - VCS Roots
  created: '2026-05-19'
  modified: '2026-05-19'
binds:
- namespace: env
  keys:
    TEAMCITY_API_KEY: TEAMCITY_API_KEY
capability:
  consumes:
  - type: http
    namespace: rest-vcs-roots
    baseUri: https://{server}/app/rest
    description: TeamCity REST API — VCS Roots business capability. Self-contained, no shared references.
    resources:
    - name: vcs-roots
      path: /vcs-roots
      operations:
      - name: getallvcsroots
        method: GET
        description: Get All VCS Roots
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
      - name: createvcsroot
        method: POST
        description: Create VCS Root
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: vcs-roots-vcsRootLocator
      path: /vcs-roots/{vcsRootLocator}
      operations:
      - name: getvcsroot
        method: GET
        description: Get VCS Root
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: vcsRootLocator
          in: path
          type: string
          required: true
      - name: deletevcsroot
        method: DELETE
        description: Delete VCS Root
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: vcsRootLocator
          in: path
          type: string
          required: true
    authentication:
      type: bearer
      token: '{{env.TEAMCITY_API_KEY}}'
  exposes:
  - type: rest
    namespace: rest-vcs-roots-rest
    port: 8080
    description: REST adapter for TeamCity REST API — VCS Roots. One Spectral-compliant resource per consumed operation, prefixed
      with /v1.
    resources:
    - path: /v1/vcs-roots
      name: vcs-roots
      description: REST surface for vcs-roots.
      operations:
      - method: GET
        name: getallvcsroots
        description: Get All VCS Roots
        call: rest-vcs-roots.getallvcsroots
        outputParameters:
        - type: object
          mapping: $.
      - method: POST
        name: createvcsroot
        description: Create VCS Root
        call: rest-vcs-roots.createvcsroot
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/vcs-roots/{vcsrootlocator}
      name: vcs-roots-vcsrootlocator
      description: REST surface for vcs-roots-vcsRootLocator.
      operations:
      - method: GET
        name: getvcsroot
        description: Get VCS Root
        call: rest-vcs-roots.getvcsroot
        with:
          vcsRootLocator: rest.vcsRootLocator
        outputParameters:
        - type: object
          mapping: $.
      - method: DELETE
        name: deletevcsroot
        description: Delete VCS Root
        call: rest-vcs-roots.deletevcsroot
        with:
          vcsRootLocator: rest.vcsRootLocator
        outputParameters:
        - type: object
          mapping: $.
  - type: mcp
    namespace: rest-vcs-roots-mcp
    port: 9090
    transport: http
    description: MCP adapter for TeamCity REST API — VCS Roots. One tool per consumed operation, routed inline through this
      capability's consumes block.
    tools:
    - name: get-all-vcs-roots
      description: Get All VCS Roots
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: rest-vcs-roots.getallvcsroots
      outputParameters:
      - type: object
        mapping: $.
    - name: create-vcs-root
      description: Create VCS Root
      hints:
        readOnly: false
        destructive: false
        idempotent: false
      call: rest-vcs-roots.createvcsroot
      with:
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.
    - name: get-vcs-root
      description: Get VCS Root
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: rest-vcs-roots.getvcsroot
      with:
        vcsRootLocator: tools.vcsRootLocator
      outputParameters:
      - type: object
        mapping: $.
    - name: delete-vcs-root
      description: Delete VCS Root
      hints:
        readOnly: false
        destructive: true
        idempotent: true
      call: rest-vcs-roots.deletevcsroot
      with:
        vcsRootLocator: tools.vcsRootLocator
      outputParameters:
      - type: object
        mapping: $.