-
Notifications
You must be signed in to change notification settings - Fork 9
Add MCP Documentation #344
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
ertzL
wants to merge
6
commits into
main
Choose a base branch
from
MCP-documents
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
360f5d7
Create integrating-with-mcp
ertzL e367fb8
Delete src/content/integrations/integrating-with-mcp
ertzL 2be50da
Create integrating-with-mcp.mdx
ertzL 4f2fb56
Update src/content/integrations/integrating-with-mcp.mdx
ertzL d56040b
Update src/content/integrations/integrating-with-mcp.mdx
ertzL 46262fd
Update src/content/integrations/integrating-with-mcp.mdx
ertzL File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,101 @@ | ||
| # MCP Server Support for Cloudsmith CLI | ||
| How to integrate MCP with Cloudsmith | ||
|
|
||
| The Cloudsmith CLI now includes support for the Model Context Protocol (MCP), allowing AI assistants like Claude to interact with your Cloudsmith repositories through natural language. | ||
|
|
||
| ## What's New | ||
|
|
||
| The MCP server enables AI assistants to programmatically manage Cloudsmith repositories, packages, and artifacts by automatically generating tools from Cloudsmith's OpenAPI specification. | ||
|
|
||
| ## Requirements | ||
|
|
||
| **Python 3.10 or later** is required to use the Cloudsmith CLI. | ||
|
|
||
| ## Getting Started | ||
|
|
||
| ### Auto-Configure MCP Clients | ||
|
|
||
| The CLI provides a command to facilitate the configuration of MCP clients: | ||
|
|
||
| ```bash | ||
| # Configure for default profile | ||
| $ cloudsmith mcp configure | ||
|
|
||
| # Configure for specific profile | ||
| $ cloudsmith mcp configure -P my-profile | ||
| ``` | ||
|
|
||
| Currently supported MCP clients for auto-configuration: **Claude Desktop**, **Cursor**, **VS Code (Copilot)**, and **Gemini CLI**. | ||
|
|
||
| ### Manual Configuration | ||
|
|
||
| Alternatively, you can manually configure the MCP server by modifying the JSON configuration file for your LLM client. | ||
|
|
||
| For example, with **Claude Desktop on macOS**, the configuration file is located at: | ||
|
|
||
| ``` | ||
| ~/Library/Application Support/Claude/claude_desktop_config.json | ||
| ``` | ||
|
|
||
| Example configuration: | ||
|
|
||
| ```json | ||
| { | ||
| "mcpServers": { | ||
| "cloudsmith": { | ||
| "command": "cloudsmith", | ||
| "args": [ | ||
| "mcp", | ||
| "start" | ||
| ] | ||
| } | ||
| } | ||
| } | ||
| ``` | ||
|
|
||
| **Note:** The MCP server will be started automatically by your LLM client. You don't need to run `cloudsmith mcp start` manually. | ||
|
|
||
| ### Managing Available Tools | ||
|
|
||
| Due to the large number of tools exposed by the MCP server, a limited subset is available by default to avoid filling the LLM's context window. | ||
|
|
||
| **Disabled tool categories by default:** | ||
| `broadcasts, rates, packages_upload, packages_validate, user_token, user_tokens, webhooks, status, repos_ecdsa, repos_geoip, repos_gpg, repos_rsa, repos_x509, repos_upstream, orgs_openid, orgs_saml, orgs_invites, files, badges, quota, users_profile, workspaces_policies, storage_regions, entitlements, metrics_entitlements, metrics_packages, orgs_teams, repo_retention` | ||
|
|
||
ertzL marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| ### List Available Tools and Groups | ||
|
|
||
| ```bash | ||
| # Show all available tools | ||
| $ cloudsmith mcp list_tools -a | ||
|
|
||
| # Show all tool groups | ||
| $ cloudsmith mcp list_groups -a | ||
| ``` | ||
|
|
||
| After reviewing the available tools and groups, you can customize which ones are exposed to your AI assistant. | ||
|
|
||
| ## Customizing Available Tools | ||
|
|
||
| You can customize which tools are available by editing `~/.cloudsmith/config.ini`: | ||
|
|
||
| ```bash | ||
| [default] | ||
| mcp_allowed_tools=workspaces_policies_simulate_list | ||
| mcp_allowed_tool_groups=metrics | ||
| ``` | ||
|
|
||
| This configuration exposes: | ||
|
|
||
| - Individual tools listed in `mcp_allowed_tools` | ||
| - All tools within the groups specified in `mcp_allowed_tool_groups` | ||
|
|
||
| ## Authentication | ||
|
|
||
| The MCP server uses your existing Cloudsmith CLI credentials: | ||
|
|
||
| - **API Keys**: Automatically used if configured | ||
| - **SSO**: Complete authentication via `cloudsmith auth` before configuring and launching your LLM client, as MCP clients cannot trigger the SSO flow automatically once the server is running | ||
|
|
||
| ## Multi-Profile Support | ||
|
|
||
| Configure separate MCP server instances for different Cloudsmith profiles using the `-P` flag with the configure command. | ||
ertzL marked this conversation as resolved.
Show resolved
Hide resolved
|
||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.