Skip to main content
Glama
Artifact Registry MCP Server

Artifact Registry MCP Server

by Pawangunjkar

Artifact Registry MCP Server

A Python Model Context Protocol (MCP) server for Sonatype Nexus Repository 3 and JFrog Artifactory — search binaries across Maven/Docker/npm/PyPI/Helm/raw repositories, resolve immutable OCI sha256 digests, verify checksum integrity, and promote or prune releases with confirmation gates.

Python 3.10+ MCP Protocol License: MIT


Overview

Artifact Registry MCP Server gives AI assistants direct read, attestation, and gated release-promotion control over Sonatype Nexus 3 and JFrog Artifactory.

  • Dual registry support: Unified tool surface across Nexus Repository 3 and JFrog Artifactory (ARTIFACT_REGISTRY_TYPE=nexus or artifactory).

  • Supply-chain attestation: artifact_verify_checksum_integrity compares expected CI SHA-256 checksums against registry-stored checksums, and artifact_get_docker_image_tags_and_digests resolves immutable sha256:... digests before deployment.

  • Confirmation-gated mutations: Uploads, release promotions, and snapshot cleanups (dry_run=true by default) require explicit confirm=true after preview.

  • Multi-session auth: Supports named sessions and optional credential caching under ~/.artifact-mcp-cache.


Related MCP server: JFrog Artifactory MCP Server

Architecture & Supply-Chain Flow

flowchart TB
  subgraph CI["Layer 1 — CI & Source Control"]
    GH["GitHub Actions / CI"]
    JK["Jenkins Build Jobs"]
  end

  subgraph MCP["Layer 2 — Artifact Registry MCP"]
    REG["artifact-registry-mcp (FastMCP)"]
    CS["CredentialStore (~/.artifact-mcp-cache)"]
    GATE["Confirmation Gate (confirm=true)"]
  end

  subgraph BACKENDS["Layer 3 — Artifact Registries"]
    NEXUS["Sonatype Nexus Repository 3"]
    JFROG["JFrog Artifactory"]
  end

  subgraph DEPLOY["Layer 4 — Deployment"]
    K8S["Kubernetes / OpenShift (sha256 digest)"]
  end

  GH -->|"artifact_upload_binary"| REG
  JK -->|"artifact_upload_binary"| REG
  REG --> CS
  REG --> GATE
  GATE -->|"Upload / Promote / Prune"| NEXUS
  GATE -->|"Upload / Promote / Prune"| JFROG
  NEXUS -->|"artifact_verify_checksum_integrity"| REG
  JFROG -->|"artifact_verify_checksum_integrity"| REG
  REG -->|"artifact_get_docker_image_tags_and_digests"| K8S

Project Layout

artifact-registry-mcp/
├── src/artifact_mcp/
│   ├── __init__.py          # Package metadata
│   ├── __main__.py          # `python -m artifact_mcp` entry point
│   ├── server.py            # FastMCP server, 12 tools, /health, CLI transport
│   ├── artifact_client.py   # Nexus 3 & Artifactory REST clients + SHA-256 helpers
│   └── credential_store.py  # Session credential persistence
├── tests/                   # Unit + httpx.MockTransport regression tests
├── pyproject.toml           # Hatchling build config (`artifact-mcp`, `artifact-registry-mcp`)
├── Dockerfile               # Streamable HTTP container
└── mcpize.yaml              # Hosted HTTP runtime config

Tools Reference (12)

Connection & Session Management (5)

Tool

Access

Description

artifact_connect

Read-only

Connect to Sonatype Nexus 3 or JFrog Artifactory and create a named session.

artifact_status

Read-only

Check connection health, version, authenticated user, and storage quota.

artifact_disconnect

Read-only

Disconnect an active session and close HTTP connections.

artifact_list_sessions

Read-only

List active and cached registry sessions with masked credentials.

artifact_save_credentials

Read-only

Save connection credentials to local cache file.

Binary Discovery & Supply-Chain Attestation (4)

Tool

Access

Description

artifact_list_repositories

Read-only

List repositories filtered by format (maven2, docker, npm, pypi, helm, raw) and type.

artifact_search_binaries

Read-only

Search components by name, group, version, or SHA-256; returns URLs, timestamps, and checksums.

artifact_get_docker_image_tags_and_digests

Read-only

Resolve immutable sha256:... container digest for deployment.

artifact_verify_checksum_integrity

Read-only

Compare expected CI SHA-256 against the registry checksum before rollout.

Confirmation-Gated Mutating Tools (3)

Tool

Access

Description

artifact_upload_binary

Confirm (confirm=true)

Compute local SHA-256, upload file, and verify remote checksum match.

artifact_promote_release

Confirm (confirm=true)

Promote immutable artifact from staging to release repository without rebuilding.

artifact_cleanup_old_snapshots

Confirm (dry_run=false, confirm=true)

Prune stale snapshot builds beyond retention count (dry_run=true simulates safely).


Installation & Configuration

Requires Python 3.10+ and uv.

git clone https://github.com/Pawangunjkar/artifact-registry-mcp.git
cd artifact-registry-mcp
uv sync
uv run artifact-registry-mcp

Environment Variables

Variable

Default

Purpose

ARTIFACT_REGISTRY_TYPE

unset

nexus or artifactory.

ARTIFACT_REGISTRY_URL

unset

Base URL of your Nexus or Artifactory instance.

ARTIFACT_REGISTRY_USER

unset

Registry username or service account.

ARTIFACT_REGISTRY_TOKEN

unset

API token, password, or access token.

ARTIFACT_REGISTRY_SSL_VERIFY

true

Set to false for internal self-signed certificates.

ARTIFACT_REGISTRY_TIMEOUT

30

HTTP timeout in seconds.

ARTIFACT_MCP_CACHE_DIR

~/.artifact-mcp-cache

Session credential cache directory.

Cursor / Claude Code Setup

{
  "mcpServers": {
    "artifact-registry": {
      "command": "uv",
      "args": ["run", "--directory", "/absolute/path/to/artifact-registry-mcp", "artifact-registry-mcp"],
      "env": {
        "ARTIFACT_REGISTRY_TYPE": "nexus",
        "ARTIFACT_REGISTRY_URL": "http://localhost:8081",
        "ARTIFACT_REGISTRY_USER": "admin",
        "ARTIFACT_REGISTRY_TOKEN": "your-token-or-password"
      }
    }
  }
}

Development & Tests

uv run python -m unittest discover -s tests -v
uv build

Author & License

Pawan Gunjkar — pawangunjkar@gmail.com · GitHub

MIT License — see LICENSE.

Available Tools

12 tools
artifact_cleanup_old_snapshotsA

Identify and prune stale snapshot artifacts to reclaim storage.

⚠️ CONFIRMATION-GATED MUTATING TOOL: Requires dry_run=false AND confirm=true to delete.

Finds all snapshot versions of a component, sorts by timestamp/version descending, preserves the latest keep_latest_n snapshots, and simulates or deletes stale items.

Purpose: Maintain storage quotas and enforce artifact retention policies. When to Use: In Workflow 4 during scheduled maintenance or when storage alerts trigger. Behavior: Dry-run simulation by default. Destructive deletion when dry_run=false and confirm=true. Side Effects: Permanently deletes pruned snapshot artifacts when executed.

Args: repository: Repository containing snapshot artifacts (e.g. 'maven-snapshots', 'libs-snapshot-local') component_name: Name of the component to clean up (e.g. 'billing-engine') keep_latest_n: Number of most recent snapshots to preserve (default: 5) dry_run: If True, simulates cleanup without deleting files (default: True) confirm: Must be True when dry_run=False to execute permanent deletion (default: False) session_name: Session to use (default: 'default')

Inputs: repository (required), component_name (required), confirm, dry_run, +2 more. Returns: result

artifact_connectA

Connect to Sonatype Nexus 3 or JFrog Artifactory and create a named session.

Probes registry system status and version to verify connectivity and credentials. Credentials are automatically cached to ~/.artifact-mcp-cache/credentials.json.

Purpose: Establish an authenticated session before calling any registry tool. When to Use: At the start of an artifact supply chain workflow or to switch between staging/production registries using named sessions. Behavior: Read-Only probe (no artifacts mutated). Side Effects: Caches session credentials locally.

Args: registry_type: 'nexus' (Sonatype Nexus 3) or 'artifactory' (JFrog Artifactory) base_url: Registry base URL (e.g. 'http://localhost:8081' or 'https://myorg.jfrog.io/artifactory') token_or_password: Password, API Token, or Access Token username: Username (e.g. 'admin' or 'ci-agent') session_name: Name for this session, e.g. 'prod', 'staging' (default: 'default')

Inputs: base_url, username, session_name, registry_type, +1 more. Returns: result

artifact_disconnectA

Disconnect an active artifact registry session and close HTTP connections.

Purpose: Clean up open network sessions and release memory. When to Use: When switching environments or finishing a pipeline run. Behavior: Closes local HTTP client. Side Effects: Removes session from active memory.

Args: session_name: Session to disconnect (default: 'default')

Inputs: session_name. Returns: result

artifact_get_docker_image_tags_and_digestsA

Query Docker/OCI repositories to resolve an immutable sha256:... image digest.

Queries Docker v2 manifest endpoints and AQL in Nexus and Artifactory. Produces an immutable image reference (image@sha256:...) and ready-to-run tool arguments for k8s-mcp rollouts.

Purpose: Bridge container registry images to Kubernetes deployments securely. When to Use: Right before calling k8s-mcp to deploy or update a container workload. Behavior: Read-Only query. Side Effects: None.

Args: repository: Docker repository key/name in the registry (e.g. 'docker-local' or 'docker-hosted') image_name: Container image name (e.g. 'payment-service' or 'microservices/auth') limit: Maximum number of tags to return (default: 20) session_name: Session to query (default: 'default')

Inputs: image_name (required), repository (required), limit, session_name. Returns: result

artifact_list_repositoriesA

List repositories filtered by package format and repository type.

Works across both Nexus 3 (/service/rest/v1/repositories) and Artifactory (/api/repositories).

Purpose: Inspect repository topology and locate target repos for upload or promotion. When to Use: During supply chain discovery before publishing or pulling artifacts. Behavior: Read-Only query. Side Effects: None.

Args: format_filter: Filter by package format: 'maven2', 'docker', 'npm', 'pypi', 'helm', 'raw' (or 'generic') type_filter: Filter by type: 'hosted' (or 'local'), 'proxy' (or 'remote'), 'group' (or 'virtual') session_name: Session to query (default: 'default')

Inputs: type_filter, session_name, format_filter. Returns: result

artifact_list_sessionsA

List all active and cached registry sessions with masked credentials.

Purpose: Review available registry targets, environments, and versions. When to Use: To determine which sessions are configured before executing workflows. Behavior: Read-Only local inspection. Side Effects: None.

Inputs: no named parameters. Returns: result

artifact_promote_releaseA

Promote an immutable artifact from staging/snapshot to production release repository.

⚠️ CONFIRMATION-GATED MUTATING TOOL: Requires confirm=true to execute.

Promotes a tested, immutable component from staging (e.g. 'dev-local', 'maven-staging') to production release (e.g. 'prod-release', 'maven-releases') without rebuilding, maintaining complete provenance and cryptographic integrity.

Purpose: Supply-chain promotion between pipeline stages. When to Use: In Workflow 2 after integration/smoke tests pass. Behavior: MUTATING. Copies component to target release repository. Side Effects: Modifies target release repository contents.

Args: source_repo: Source repository key (e.g. 'dev-local', 'staging-repo') target_repo: Target release repository key (e.g. 'prod-release', 'maven-releases') artifact_or_build_name: Name of the artifact or build component (e.g. 'cart-service') version: Version string to promote (e.g. '1.5.0') confirm: Must be True to execute promotion (default: False) session_name: Session to use (default: 'default')

Inputs: version (required), source_repo (required), target_repo (required), artifact_or_build_name (required), +2 more. Returns: result

artifact_save_credentialsA

Save registry credentials to the local persistent cache file.

Purpose: Cache connection details so future sessions can reconnect automatically. When to Use: When pre-configuring staging/production environments without running queries. Behavior: Local file write to ~/.artifact-mcp-cache/credentials.json. Side Effects: Overwrites existing cached credentials for session_name.

Args: registry_type: 'nexus' or 'artifactory' base_url: Registry base URL token_or_password: Password, API Token, or Access Token username: Username (e.g. 'admin') session_name: Session name to store (default: 'default')

Inputs: base_url (required), registry_type (required), token_or_password (required), username, +1 more. Returns: result

artifact_search_binariesA

Search components and artifacts across Nexus or Artifactory.

Returns download URLs, exact versions, creation/modification timestamps, and SHA256/SHA1/MD5 checksums.

Purpose: Locate specific binaries or verify build component presence. When to Use: To locate release artifacts before deployment or check artifact metadata. Behavior: Read-Only search. Side Effects: None.

Args: name: Artifact or component name (supports wildcards/substrings, e.g. 'order-service') group_or_repo: Repository name or Maven groupId (e.g. 'libs-release-local' or 'com.myorg') version: Specific version string (e.g. '1.4.2' or '2.0.0-SNAPSHOT') sha256: Exact 64-character SHA256 checksum to look up session_name: Session to query (default: 'default')

Inputs: name (required), sha256, version, session_name, +1 more. Returns: result

artifact_statusA

Check connection health, authenticated user, registry version, and storage quota.

Probes status endpoints (Nexus /service/rest/v1/status, Artifactory /api/system/ping), retrieves server version, and summarizes repository storage metrics.

Purpose: Verify registry availability, user privileges, and storage capacity. When to Use: Before initiating large binary uploads or checking health. Behavior: Read-Only probe. Side Effects: None.

Args: session_name: Artifact registry session to inspect (default: 'default')

Inputs: session_name. Returns: result

artifact_upload_binaryA

Upload a local build artifact/archive to Nexus or Artifactory with checksum verification.

⚠️ CONFIRMATION-GATED MUTATING TOOL: Requires confirm=true to execute.

Computes local SHA256/SHA1/MD5 checksums, uploads the binary to the destination repository, and immediately verifies the remote checksum match.

Purpose: Publish build archives, JARs, wheels, or tarballs to the registry. When to Use: In Workflow 1 after jenkins-mcp or github-mcp build completes. Behavior: MUTATING. Writes binary to registry storage. Side Effects: Consumes registry storage space.

Args: repository: Destination repository (e.g. 'maven-releases', 'libs-snapshot-local') local_file_path: Absolute or relative path to the local file to upload target_path: Destination path in the repository (e.g. 'com/corp/auth/1.0.0/auth-1.0.0.jar') maven_coords: Optional dict of Maven coordinates {'groupId': '...', 'artifactId': '...', 'version': '...', 'packaging': 'jar'} confirm: Must be True to execute upload (default: False) session_name: Session to use (default: 'default')

Inputs: repository (required), target_path (required), local_file_path (required), confirm, +2 more. Returns: result

artifact_verify_checksum_integrityA

Compare the SHA256 digest generated by CI against registry checksum before deployment.

Verifies cryptographic attestation: compares the expected SHA256 (produced by github-mcp GitHub Actions or jenkins-mcp build jobs) against the checksum stored in Nexus or Artifactory. Blocks deployment if tampering or corruption is detected.

Purpose: Supply-chain security attestation gate. When to Use: In CI/CD pipelines right before deployment to Kubernetes/OpenShift. Behavior: Read-Only verification. Side Effects: None.

Args: artifact_path_or_url: Remote artifact path (e.g. 'libs-release-local/com/corp/app-1.0.jar') or full URL expected_sha256: 64-character SHA256 digest from CI build or SBOM session_name: Session to query (default: 'default')

Inputs: expected_sha256 (required), artifact_path_or_url (required), session_name. Returns: result

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4.2/5.0

    Scored across 12 tools

    Disambiguation4/5

    Most tools target clearly distinct registry actions and resources, with confirmation-gated mutations separated from read-only operations. The main overlap is between artifact_save_credentials and artifact_connect, since connect also caches credentials, but descriptions clarify the difference.

    Naming Consistency4/5

    All tools use a consistent artifact_ prefix with snake_case naming, mostly following an artifact_verb_noun pattern. artifact_status is the minor exception, acting as a noun-only name rather than artifact_get_status.

    Tool Count5/5

    The 12-tool set is well-scoped for an artifact registry server, covering session management, discovery, verification, upload, promotion, and cleanup. Each tool appears to earn its place without excessive surface area.

    Completeness4/5

    The surface covers the core artifact supply-chain lifecycle well: connect, inspect, search, verify, upload, promote, and clean up. Minor gaps include no direct artifact download tool and no general-purpose artifact deletion beyond snapshot cleanup.

    Maintenance

    ActivityMaintained
    ResponsivenessOutdated data

    Related MCP Connectors

    Related MCP Servers

    • F
      license
      Not graded
      quality
      D
      maintenance
      Enables AI assistants to query Maven artifacts in JFrog Artifactory by reusing credentials from ~/.m2/settings.xml and providing tools like getting latest stable versions, listing artifacts, and checking dependency updates.
      -
    • F
      license
      Not graded
      quality
      C
      maintenance
      A Model Context Protocol (MCP) server that provides seamless integration with JFrog Artifactory, enabling AI assistants to manage artifacts, repositories, and perform cleanup operations through natural language interactions.
      -
    • F
      license
      Not graded
      quality
      C
      maintenance
      Connects AI coding assistants to the JFrog platform, enabling natural-language queries for resource management, artifact discovery, security monitoring, and catalog curation.
      15
      -
    • A
      license
      Not graded
      quality
      B
      maintenance
      Enables autonomous AI agents and CI/CD runners to discover repository modules, scan outdated dependencies, fetch version histories, and apply verified dependency updates with major-version safety guardrails across polyglot monorepos.
      40 npm
      MIT