mcpField
M
Maven Check MCP Server

Maven Check MCP Server

Local
github.com/danielschollDeveloper Tools0Updated 78w ago

About Maven Check MCP Server

Maven Check MCP Server lets LLMs query Maven Central for artifact versions and existence. It supports semantic-version comparisons, packaging and classifiers, plus batch checks for dependency lists.

Key features

  1. 01Find latest artifact versions
  2. 02Check whether a version exists
  3. 03Compare major, minor, and patch versions
  4. 04Support packaging types and classifiers
  5. 05Batch-check dependencies

Use cases

  1. 01Checking Maven dependency versions
  2. 02Choosing major, minor, or patch updates
  3. 03Verifying versions across a dependency list

MCP support

Exposes five tools to MCP clients for retrieving Maven versions, checking version existence, comparing semantic-version components, and processing dependency batches.

Configuration

Local server config is the same for every client. Copy it into your client’s MCP config file.

No install method listed yet

We haven’t collected a package or remote endpoint for this server. Follow the instructions in the project README.

Repository

Tools

No tool list yet

Local servers expose tools only once running on your machine, and the maintainer has not provided a tool list.

Details

From the project README

Maven Check MCP Server

A lightweight MCP server that lets Large Language Models query Maven Central for artifact versions. This server allows Claude and other LLMs to find the latest version of a Maven dependency and check if a specific version exists.

Features

  • Find the latest version of any Maven dependency (library)
  • Check if a specific version of a dependency exists
  • Support for packaging types (jar, war, pom, etc.)
  • Automatic detection of POM dependencies (artifacts with -bom or -dependencies suffix)
  • Support for classifiers
  • Proper semantic versioning comparisons
  • Batch processing for multiple dependencies in a single request
  • Connection via Model Context Protocol (MCP)

Installation

# Clone the repository
git clone https://github.com/danielscholl/maven-mcp-server.git
cd maven-mcp-server

# Install dependencies and the package
uv sync && uv pip install -e .

MCP Server Configuration

To use this MCP server with your projects, add the following to your .mcp.json:

{
  "mcpServers": {
    "maven-check": {
      "type": "stdio",
      "command": "uv",
      "args": ["run", "maven-check"],
      "env": {}
    }
  }
}

Install with UVX in VS Code

Usage

Start the server:

uv run maven-check

For debug logging:

uv run maven-check --debug

Tools

This MCP server provides five tools:

1. get_maven_latest_version

Gets the latest version of a Maven dependency.

Parameters:

  • dependency (required): The dependency in the format 'groupId:artifactId'
  • packaging (optional): The packaging type, defaults to 'jar' (automatically uses 'pom' for dependencies with -bom or -dependencies suffix)
  • classifier (optional): The classifier, if any

Examples:

{
  "dependency": "org.apache.commons:commons-lang3"
}
{
  "dependency": "org.springframework.boot:spring-boot-dependencies"
}

Returns: The latest version as a string (e.g., "3.14.0")

2. check_maven_version_exists

Checks if a specific version of a Maven dependency exists.

Parameters:

  • dependency (required): The dependency in the format 'groupId:artifactId'
  • version (required): The version to check
  • packaging (optional): The packaging type, defaults to 'jar' (automatically uses 'pom' for dependencies with -bom or -dependencies suffix)
  • classifier (optional): The classifier, if any

Examples:

{
  "dependency": "org.apache.commons:commons-lang3",
  "version": "3.14.0"
}
{
  "dependency": "org.springframework.boot:spring-boot-dependencies",
  "version": "3.2.0"
}

Returns: A boolean indicating whether the version exists ("true" or "false")

3. find_maven_latest_component_version

Gets the latest version of a Maven dependency based on semantic versioning component (major, minor, or patch).

Parameters:

  • dependency (required): The dependency in the format 'groupId:artifactId'
  • version (required): The version in semantic version format (MAJOR.MINOR.PATCH)
  • target_component (required): The component to find the latest version for, one of: "major", "minor", "patch"
  • packaging (optional): The packaging type, defaults to 'jar' (automatically uses 'pom' for dependencies with -bom or -dependencies suffix)
  • classifier (optional): The classifier, if any

Examples:

{
  "dependency": "org.apache.commons:commons-lang3",
  "version": "3.12.0",
  "target_component": "minor"
}
{
  "dependency": "org.springframework.boot:spring-boot-dependencies",
  "version": "3.1.0",
  "target_component": "minor"
}

Returns: The latest version as a string (e.g., "3.14.0")

Behavior by Target Component
  • major: Returns the highest available major version (across all versions)
  • minor: Returns the highest minor version within the given major version
  • patch: Returns the highest patch version within the given major.minor version
4. get_maven_all_latest_versions

Gets the latest versions for all semantic versioning components (major, minor, patch) in a single call.

Parameters:

  • dependency (required): The dependency in the format 'groupId:artifactId'
  • version (required): The version in semantic version format (MAJOR.MINOR.PATCH)
  • packaging (optional): The packaging type, defaults to 'jar' (automatically uses 'pom' for dependencies with -bom or -dependencies suffix)
  • classifier (optional): The classifier, if any

Examples:

{
  "dependency": "org.apache.commons:commons-lang3",
  "version": "3.12.0"
}
{
  "dependency": "org.springframework.boot:spring-boot-dependencies",
  "version": "3.1.0"
}

Returns: A JSON object containing the latest versions for each component:

{
  "latest_major_version": "3.14.0",
  "latest_minor_version": "3.12.0",
  "latest_patch_version": "3.12.0"
}
5. batch_maven_versions_check

Checks the latest versions for multiple Maven dependencies in a single batch request, reducing the number of API calls when working with projects containing many dependencies.

Parameters:

  • dependencies (required): List of dependency objects to check, each containing:
    • dependency (required): The dependency in the format 'groupId:artifactId'
    • version (required): The version in any supported format
    • packaging (optional): The packaging type, defaults to 'jar' (automatically uses 'pom' for dependencies with -bom or -dependencies suffix)
    • classifier (optional): The classifier, if any

Example:

{
  "dependencies": [
    {
      "dependency": "org.apache.commons:commons-lang3",
      "version": "3.12.0" 
    },
    {
      "dependency": "org.springframework.boot:spring-boot-dependencies", 
      "version": "3.1.0"
    },
    {
      "dependency": "org.json:json",
      "version": "20231013"
    }
  ]
}

Returns: A JSON object containing a summary and results for each dependency:

{
  "summary": {
    "total": 3,
    "success": 3,
    "failed": 0
  },
  "dependencies": [
    {
      "dependency": "org.apache.commons:commons-lang3",
      "status": "success",
      "versions": {
        "latest_major_version": "3.14.0",
        "latest_minor_version": "3.12.0",
        "latest_patch_version": "3.12.0"
      }
    },
    {
      "dependency": "org.springframework.boot:spring-boot-dependencies",
      "status": "success",
      "versions": {
        "latest_major_version": "3.2.0",
        "latest_minor_version": "3.1.5",
        "latest_patch_version": "3.1.0"
      }
    },
    {
      "dependency": "org.json:json",
      "status": "success",
      "versions": {
        "latest_major_version": "20240303",
        "latest_minor_version": "20240303",
        "latest_patch_version": "20240303"
      }
    }
  ]
}

How It Works

The server works by:

  1. Querying the Maven Central Repository Search API
  2. Parsing and validating dependency formats
  3. Automatically detecting POM dependencies:
    • Identifies artifacts with "-bom" or "-dependencies" suffix
    • Uses "pom" packaging type for these artifacts
  4. For latest version queries:
    • Fetches all versions of the artifact
    • Sorts them using proper semantic versioning rules
    • Returns the most recent version
  5. For version existence checks:
    • Directly queries Maven Central for the specific version
    • Returns whether it exists
  6. For batch version checks:
    • Processes multiple dependency requests in a single call
    • Returns detailed results for each dependency with success/error status
    • Provides a summary with counts of successful and failed requests

Development

Testing

Run all tests:

uv run pytest

Using with Claude

Once the server is set up and Claude Code is connected, you can use the tools like this:

  1. Get the latest version of a Maven dependency:

    What is the latest version of org.springframework:spring-framework-bom 
    
  2. Check if a specific version exists:

    Does version 3.14.0 of org.apache.commons:commons-lang3 exist?
    
  3. Get latest patch version:

    I'm using version 2.0.2 of org.springdoc:springdoc-openapi-starter-webmvc-ui what is the latest patch?
    
  4. Working with BOM and POM dependencies:

    What is the latest version of org.springframework.boot:spring-boot-dependencies?
    

    The server automatically detects dependencies with "-dependencies" or "-bom" suffix and uses POM packaging type.

  5. Get all latest versions in one call:

    Check latest versions org.springframework.boot:spring-boot-dependencies (currently using 3.1.0)
    

    This returns the latest major, minor, and patch versions in a single call, making it efficient for understanding upgrade options.

  6. Check multiple dependencies at once with batch processing:

    I need to check the latest versions for:
    - org.apache.commons:commons-lang3 (currently using 3.12.0)
    - org.springframework.boot:spring-boot-dependencies (currently using 3.1.0)
    - org.json:json (currently using 20231013)
    

    The batch processing tool checks all dependencies in one request, improving efficiency for projects with multiple dependencies.

Comments

Markdown supported

New to MCP?

From what the protocol is to installing your first server, these answers cover most first questions.

An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.