# Docker Hub MCP for AI Agents MCP

> Docker Hub MCP lets your AI client manage container images directly from natural conversation. Check repository details, discover image tags with versions and sizes, or search thousands of public community images without logging into a web dashboard.

## Overview
- **Category:** loved-by-devs
- **Price:** Free
- **Tags:** containerization, registry, image-management, automation, repository, version-control

## Description

Managing containers usually means clicking through dozens of tabs to check pull counts or verify if the right version tag exists. This MCP lets you bypass the UI entirely. Your AI agent connects straight to your Docker Hub account, letting you perform registry tasks using simple conversation. Need to know what versions are available for a specific image? Just ask. Want to see how popular a repository is across organizations? It's ready. You can use it to list and manage repositories, browse all associated tags with version info, or even search the massive public catalog for community images. With Vinkius managing this connection, your AI agent acts like a dedicated DevOps assistant, handling everything from listing organization members to updating repository descriptions—all without you ever touching the Docker Hub website.

## Tools

### create_repository
Creates a brand-new container repository, allowing you to set its description and whether it should be public or private.

### delete_repository
Permanently removes an entire Docker Hub repository. Be careful; this action cannot be undone.

### get_repository
Retrieves specific details, including ownership and creation metadata, for a given repository name.

### get_tag
Fetches detailed information about a single image tag, providing its size and push date.

### get_user
Confirms your connected identity by retrieving basic user info like name, email, and account type.

### list_organizations
Shows all the organizational groups you are a member of on Docker Hub.

### list_repositories
Provides an overview of all your repositories, including their star count and last update date.

### list_tags
Lists every available tag for a specific repository, useful for seeing version history.

### search_repositories
Searches the public Docker Hub catalog to discover community images based on keywords or descriptions.

### update_repository
Modifies metadata for an existing repository, such as changing its description or setting its private status.

## Prompt Examples

**Prompt:** 
```
I need a quick list of all my current production repositories.
```

**Response:** 
```
**Repositories Overview**

*   `api-service`: 12.5K pulls (Public) - Last updated: 3 days ago
*   `web-frontend`: 8.9K pulls (Public) - Last updated: 1 week ago
*   `internal-worker`: Private - Last updated: 2 months ago

You can also check the full details on any of these.
```

**Prompt:** 
```
Show me all available versions for my base image repo.
```

**Response:** 
```
The `base-image` repository has several tags. Here are some recent ones:

*   **latest**: 150MB (Pushed: Today)
*   **v2.1.3**: 149MB (Pushed: 5 days ago)
*   **v2.1-alpine**: 80MB (Pushed: 5 days ago)

The latest stable tag is `v2.1.3`.
```

**Prompt:** 
```
Search for a lightweight Python base image.
```

**Response:** 
```
I found several matching images:

*   **Official Python**: The main repository has over 1.2B pulls.
*   **Python Alpine:** A great lightweight option (approx. 50MB).
*   **Slimmed Version:** Also available, offering a minimal footprint for production builds.
```

## Capabilities

### List all repositories
Retrieves a list of image repositories belonging to your user or organization.

### Discover available tags for an image
Shows every version tag associated with a specific repository, including size and push date.

### Search public images by name
Finds matching community repositories across the entire Docker Hub catalog based on keywords or descriptions.

### Create new image repositories
Sets up a brand-new repository within your account, defining its visibility and description.

### Update existing repo details
Changes metadata on an established repository, such as updating the description or setting privacy status.

## Use Cases

### Verifying the correct image version
A developer needs to confirm if `nginx:1.25-alpine` is available for deployment. Instead of searching through dozens of tags, they ask their agent, and it uses `list_tags` to provide a clean list showing the size and push date.

### Starting a new microservice container
A platform team needs a dedicated repo for a new service. They use the agent's command capability to execute `create_repository`, instantly setting up the required namespace and privacy settings.

### Checking organizational access rights
An engineer needs to know which teams belong to their organization. The agent uses `list_organizations` and can then list all associated repositories, providing a quick audit trail for compliance checks.

## Benefits

- Checking available versions: Use the `list_tags` tool to instantly view every tag for a repo, eliminating manual browsing of version history.
- Finding base images: The `search_repositories` tool lets you find community Docker images across the whole catalog using only keywords.
- Auditing status: Run `list_repositories` and monitor pull counts or last updated dates without visiting the dashboard page.
- Maintaining integrity: Use `get_repository` to instantly confirm metadata, like ownership or description, for any service repo.
- Updating details: Never manually edit a repo again. The `update_repository` tool lets you change descriptions or privacy settings via command.

## How It Works

The bottom line is that you talk to your agent about your containers, and it handles the API calls necessary to get you the data or make the change.

1. You subscribe to this MCP and provide your Docker Hub Access Token.
2. Your AI client authenticates with Vinkius and gains access to all available container registry tools.
3. You give a natural language command, like 'list the tags for my web service repo,' and your agent executes the action.

## Frequently Asked Questions

**How do I check my repository's pull count using the Docker Hub MCP?**
You can use this MCP to list all your repositories and see their pull counts instantly. This saves you from having to visit each repo page individually just for basic metrics.

**Can I find community images in the Docker Hub using this MCP?**
Yes, absolutely. You can use the search function within the MCP to query the entire public catalog of Docker Hub, finding niche base images or related projects by name or description.

**What if I need to change my repository's privacy status?**
The MCP includes a tool that lets you update your repositories. You can use it to switch a repo from public to private, or vice versa, directly through conversation.

**Does the Docker Hub MCP help me manage multiple organizations?**
Yes. The MCP allows you to list all the organizations you belong to and view repositories across those different organizational accounts in one place.

**What is the difference between listing tags and getting repo details with this MCP?**
Listing tags gives you a comprehensive list of every version tag for an image. Getting repository details provides high-level metadata, like who owns it or when it was last updated.