ClaudeCode.Plugin.Marketplace (ClaudeCode v0.36.3)
View SourceMarketplace management functions wrapping claude plugin marketplace CLI commands.
Marketplaces are catalogs that define where plugins can be discovered and installed from. They can reference plugins from GitHub repos, git URLs, npm packages, and more.
All functions resolve the CLI binary via the internal Adapter.Port.Resolver and execute commands synchronously via the system command abstraction.
Note: Remote node support is not yet implemented — these commands run on the local machine only.
Examples
# List configured marketplaces
{:ok, marketplaces} = ClaudeCode.Plugin.Marketplace.list()
# Add a marketplace from GitHub
{:ok, _output} = ClaudeCode.Plugin.Marketplace.add("owner/repo")
# Remove a marketplace
{:ok, _output} = ClaudeCode.Plugin.Marketplace.remove("my-marketplace")
# Update all marketplaces
{:ok, _output} = ClaudeCode.Plugin.Marketplace.update()
Summary
Functions
Adds a marketplace from a URL, path, or GitHub repo.
Lists all configured marketplaces.
Removes a configured marketplace by name.
Updates marketplace(s) from their source.
Types
Functions
Adds a marketplace from a URL, path, or GitHub repo.
Accepts the same source formats as the CLI: GitHub shorthand ("owner/repo"),
full git URLs, or local paths.
Options
:scope- Where to declare the marketplace::user(default),:project, or:local:sparse- List of paths for git sparse-checkout (for monorepos)
Examples
{:ok, _} = ClaudeCode.Plugin.Marketplace.add("owner/repo")
{:ok, _} = ClaudeCode.Plugin.Marketplace.add("https://gitlab.com/org/plugins.git", scope: :project)
{:ok, _} = ClaudeCode.Plugin.Marketplace.add("owner/monorepo", sparse: [".claude-plugin", "plugins"])
Lists all configured marketplaces.
Returns a list of %ClaudeCode.Plugin.Marketplace{} structs parsed from
claude plugin marketplace list --json.
Examples
{:ok, marketplaces} = ClaudeCode.Plugin.Marketplace.list()
Enum.each(marketplaces, fn m -> IO.puts("#{m.name} (#{m.source})") end)
Removes a configured marketplace by name.
Examples
{:ok, _} = ClaudeCode.Plugin.Marketplace.remove("my-marketplace")
Updates marketplace(s) from their source.
When called without a name, updates all marketplaces. When called with a name, updates only that marketplace.
Examples
{:ok, _} = ClaudeCode.Plugin.Marketplace.update()
{:ok, _} = ClaudeCode.Plugin.Marketplace.update("my-marketplace")