Skip to main content

Model Context Protocol (MCP) server providing integrated tools for Microsoft Team Foundation Server (TFS) operations. Features include:

Project description

Microsoft TFS MCP Server

PyPI version Python Versions License: MIT

A Model Context Protocol (MCP) server that provides secure access to Microsoft Visual Studio Team Foundation Server (TFS) repositories through authenticated PAT connections.

Features

  • List all repositories in a TFS project using authenticated PAT connections
  • Get detailed commit history with author filtering
  • Built-in proxy support for enterprise environments
  • Comprehensive error handling and logging
  • Secure HTTPS communication with TFS REST API

Installation

pip install mistfs-mcp-server

Requirements

  • Python 3.9 or higher
  • mcp package version 1.2.0 or higher
  • Access to Microsoft Visual Studio Team Foundation Server
  • Valid TFS Personal Access Token (PAT) with appropriate permissions

Usage

Starting the Server

# Run as a command
mistfs-mcp-server

# Or import in your Python code
from mistfs_tools.server import mcp
mcp.run()

Using with MCP Clients

This package implements the Model Context Protocol (MCP), allowing AI assistants and other MCP-compatible clients to interact with Team Foundation Server.

Example of how an MCP client might use this tool:

from mcp.client import Client

client = Client()

# Get repositories in a project
repos = await client.Get_Project_Repositories(project_name="MyProject")
print(repos)  # List of repository names in MyProject

# Get commit history for a specific user
commits = await client.Get_Repository_Checkins(
    project_name="MyProject",
    repository_name="MyRepo",
    userupn="user@company.com"
)
print(commits)  # List of commits by the specified user

API Reference

Get_Project_Repositories

Retrieves repositories from a specified Microsoft Visual Studio Team Foundation Server project.

Parameters:

  • project_name (string, required): Name of the Microsoft Visual Studio Team Foundation Server project

Features:

  • Authenticates using Personal Access Token (PAT)
  • Makes HTTPS requests to TFS API
  • Supports enterprise proxy configurations
  • Includes detailed error handling and logging

Returns:

  • List of repository names in the specified project, or an error message if the operation fails

Get_Repository_Checkins

Retrieves commit history from a specified repository in Microsoft Visual Studio Team Foundation Server.

Parameters:

  • project_name (string, required): Name of the project in Microsoft Visual Studio Team Foundation Server
  • repository_name (string, required): Name of the repository to check
  • userupn (string, required): User UPN to filter commits by author

Features:

  • Filters commits by specific user
  • Returns detailed commit information including IDs, authors, dates, and messages
  • Requires TFS_PAT environment variable for authentication
  • Supports secure HTTPS connections
  • Includes proxy support for enterprise environments
  • Comprehensive error handling and logging

Returns:

  • List of commit details or appropriate error message

Available Tools

Tool Description
Get_Project_Repositories Retrieve repositories from Microsoft Visual Studio Team Foundation Server using PAT authentication
Get_Repository_Checkins Retrieve detailed commit history from TFS repositories with user filtering

Development

Project Structure

mistfs-mcp-server/
├── src/
│   └── mistfs_tools/
│       ├── __init__.py
│       ├── __main__.py
│       └── server.py
├── LICENSE
├── README.md
└── pyproject.toml

Building and Publishing

python -m build
python -m twine upload dist/*

License

This project is licensed under the MIT License - see the LICENSE file for details.

Author

Links

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mistfs_mcp_server-0.0.3.tar.gz (5.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mistfs_mcp_server-0.0.3-py3-none-any.whl (6.5 kB view details)

Uploaded Python 3

File details

Details for the file mistfs_mcp_server-0.0.3.tar.gz.

File metadata

  • Download URL: mistfs_mcp_server-0.0.3.tar.gz
  • Upload date:
  • Size: 5.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.2

File hashes

Hashes for mistfs_mcp_server-0.0.3.tar.gz
Algorithm Hash digest
SHA256 98e9f1bf8b53349af13f4af42e10f8282238ccddd02818677426920a9564fb6c
MD5 f47ac790822261dadcc7804a167284da
BLAKE2b-256 c0c55a95c0294ce3b63f854b8ec2a84ae819d1958c9a585dadf8407ce2cf92e5

See more details on using hashes here.

File details

Details for the file mistfs_mcp_server-0.0.3-py3-none-any.whl.

File metadata

File hashes

Hashes for mistfs_mcp_server-0.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 33c298bad4341705a4597585907d71bfce77e7c9ef9e2afd100a99b849abcce1
MD5 215c3fe4d1d007a6c6d6406f933e7a11
BLAKE2b-256 3ed8c7b850a2738d2c42bf5a80a2438c2c2ffbf30576acdbfa88d7e624a922e2

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page