[BUG] Adding marketplace with custom SSH git url is not allowed

Status Open
Maintainer reply None cached
Activity 12 comments · opened Oct 17, 2025

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

Using a custom ssh git url (something different to git@.../....git) is not allowed

What Should Happen?

Any ssh git url should be allowed. IE: ${user}@${server}:${owner}/${repo}.git where user could be anything

EG: org-123456@github.com:my-org/my-marketplace.git should work

Github enterprises using ssh certificates must use a different user different to git (usually org-#######) to clone their repos

EG: user@192.168.10.123:path/to/repo (no .git here) should work

Simple cloning on a local network should work with any user

Error Messages/Logs

✘ Invalid marketplace source format. Try: owner/repo, https://..., or ./path

Steps to Reproduce

claude plugin marketplace add org-123456@github.com:my-org/my-marketplace.git

Claude Model

None

Is this a regression?

No, this never worked

Last Working Version

_No response_

Claude Code Version

2.0.21

Platform

Anthropic API

Operating System

Ubuntu/Debian Linux

Terminal/Shell

Other

Additional Information

_No response_

View original on GitHub ↗

11 Comments

github-actions[bot] · 10 months ago

Found 1 possible duplicate issue:

  1. https://github.com/anthropics/claude-code/issues/9719

This issue will be automatically closed as a duplicate in 3 days.

  • If your issue is a duplicate, please close it and 👍 the existing issue instead
  • To prevent auto-closure, add a comment or 👎 this comment

🤖 Generated with Claude Code

gastonsilva · 10 months ago

👎

gastonsilva · 10 months ago
Found 1 possible duplicate issue: 1. [[BUG] Marketplace add fails when cloning via Github Slug/ SSH. No issue with HTTPS #9719](https://github.com/anthropics/claude-code/issues/9719) This issue will be automatically closed as a duplicate in 3 days. If your issue is a duplicate, please close it and 👍 the existing issue instead To prevent auto-closure, add a comment or 👎 this comment 🤖 Generated with Claude Code

👎

github-actions[bot] · 8 months ago

This issue has been inactive for 30 days. If the issue is still occurring, please comment to let us know. Otherwise, this issue will be automatically closed in 30 days for housekeeping purposes.

andrewrabert · 8 months ago

Still an issue.

maxstepanov · 8 months ago

Unable to load plugins using Azure Devops git repositories because of this. Only Github works

CraigSalajan · 8 months ago

Same issue here. Using Azure DevOps repo, it is able to clone now via SSH, but arbitrarily rejects adding the marketplace because the url doesn't end in .git

frittsy · 7 months ago

I did manage to get Azure DevOps repositories working but it was ugly.

  1. Only cloning over ssh works, so you need to add an ssh key to Azure DevOps
  2. The repositories need to be renamed to end in .git, i.e. rename a repo marketplace to marketplace.git
  3. Do not use /plugin marketplace add, but instead only do /plugin -> tab over to "Marketplaces" -> Add Marketplace
  4. Use the ssh url to add the marketplace git@ssh.dev.azure.com:v3/your-org/project/marketplace.git
  5. Plugins need be formatted with ssh URLs and also end with .git in the repo name:
"plugins": [
  {
    "name": "custom-plugin",
    "source": {
      "source": "url",
      "url": "git@ssh.dev.azure.com:v3/your-org/project/custom-plugin.git"
    },
    "description": "Your custom plugin"
  }
]

A lot of compromises but figured I would share something that at least has the functionality some of us may want. Hopefully some of these restrictions loosen up over time.

mfoo · 7 months ago

While this thread is about custom URLs not ending with .git, you might also like to note that the URL seems to need to not contain :. It's something that tripped me up and it's possible that it's relevant to the issue here.

For GitLab, if you copy the git URL from the UI, you'll get something like git@gitlab.com:org/group/claude-marketplace.git. This SSH URL format won't work directly, you need to replace the : with / in the path and to add the ssh:// URI scheme. The following works for us:

  "extraKnownMarketplaces": {
    "org-plugins": {
      "source": {
        "source": "git",
        "url": "ssh://git@gitlab.com/org/group/claude-marketplace.git"
      }
    }
  },
  "enabledPlugins": {
    "claude-settings@org-plugins": true,
    "readmes@org-plugins": true
  }

To be explicit:

Good: ssh://git@gitlab.com/org/group/claude-marketplace.git
Bad:  ssh://git@gitlab.com:org/group/claude-marketplace.git
                          ^

This is the opposite of the behaviour when adding via the CLI, where claude plugin marketplace add git@gitlab.com:org/group/claude-marketplace.git works fine.

For anyone having difficulties debugging, run claude --debug. It will print a log file and that log file will likely contain the cause. For us it was:

2026-01-28T16:59:08.511Z [ERROR] Error: Error: Failed to clone marketplace repository: SSH authentication failed. Please ensure your SSH keys are configured for GitHub, or use an HTTPS URL instead.

Original error: Cloning into '/Users/mf/.claude/plugins/marketplaces/temp_1769619548465'...
ssh: Could not resolve hostname gitlab.com:org: nodename nor servname provided, or not known^M
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

This issue is not listed in the troubleshooting section of the marketplace guide, but the extraKnownMarketplace docs have some examples that just happen to not contain colons in the paths:

Git repositories:
{ "source": "git", "url": "https://gitlab.example.com/tools/plugins.git" }
{ "source": "git", "url": "https://bitbucket.org/acme-corp/plugins.git", "ref": "production" }
{ "source": "git", "url": "ssh://git@git.example.com/plugins.git", "ref": "v3.1", "path": "approved" }

It would be perhaps useful to add a GitLab example.

est7 · 6 months ago

If your Git server uses a non-standard SSH port, the usual scp-style Git URL can be misleading here.

Key points:

  • git@host:path/to/repo.git is the scp-style form. The : is part of the path syntax and cannot represent a port.
  • If you try git@host:1022/org/repo.git, Git interprets 1022/... as a path, and will still connect to port 22.

What to do instead:

Option A (preferred): use ~/.ssh/config to encode the port

  1. Add a host alias:
Host my-gitlab
  HostName gitlab.example.com
  User git
  Port 1022
  IdentityFile ~/.ssh/id_ed25519
  IdentitiesOnly yes
  1. Use the alias in the marketplace URL (no custom port in the URL needed):
  • scp-style: git@my-gitlab:org/group/claude-marketplace.git
  • or URL-style: ssh://git@my-gitlab/org/group/claude-marketplace.git

Option B: use the URL-style form with an explicit port (only if accepted by the validator)
ssh://git@gitlab.example.com:1022/org/group/claude-marketplace.git

If the marketplace validator rejects : in the URL (some reports suggest it does), Option A is the most reliable workaround because it avoids host:port entirely while still using the correct port under the hood.

ANogin · 1 month ago

Another workaround is to manually clone into ~/.claude/plugins/marketplaces/foo, manually update ~/.claude/plugins/known_marketplaces.json then run claude plugin marketplace foo update, but it's a huge pain for something that seems like it ought to be a trivial fix :(

Showing cached comments. Read the full discussion on GitHub ↗