Skip to content

How to load Claude Code plugins (skills/agents) in sandbox sessions? #295

@Crunchyman-ralph

Description

@Crunchyman-ralph

Question

We're using sandbox-agent (v0.4.2) with the Claude agent in E2B sandboxes. We have Claude Code plugins installed (via enabledPlugins in ~/.claude/settings.json), and the plugin files are present on disk at ~/.claude/plugins/marketplaces/, but the skills from those plugins are not available to the Skill tool when we create a session.

What we've tried

  1. enabledPlugins in ~/.claude/settings.json — The plugins are listed and the SKILL.md files exist at ~/.claude/plugins/marketplaces/<plugin>/skills/<skill>/SKILL.md, but they don't appear as invocable skills in the session's system prompt.

  2. claude plugins install <plugin> via the CLI binary at ~/.local/share/sandbox-agent/bin/claude — This registers the plugin, but by the time we run it (after SandboxAgent.start()), the session may have already loaded its skill list.

  3. sdk.setSkillsConfig() — We tried this but it appears the skills config is separate from the Claude Code plugin system.

  4. Symlink workaround — Symlinking plugin skills into the workspace .claude/skills/ directory works because workspace skills are always loaded at session creation. But this feels like a workaround.

What we observed

When asking Claude directly inside the sandbox:

  • Only workspace skills (from <cwd>/.claude/skills/) are exposed to the Skill tool
  • Plugin marketplace skills (from ~/.claude/plugins/marketplaces/) exist on disk but are NOT injected into the system prompt
  • claude plugins list shows "No plugins installed" — the enabledPlugins config is not the same as the plugin install registry

Questions

  1. Is there a recommended way to pre-install Claude Code plugins so they're available when createSession() is called?
  2. Does the ACP adapter (claude-agent-acp) support Claude Code's plugin loading lifecycle, or does it only support workspace skills?
  3. Should we be using sdk.setSkillsConfig() instead of the Claude Code plugin system? If so, does it support GitHub sources for skills?
  4. Is there a way to trigger plugin sync/reload after SandboxAgent.start() but before createSession()?

Environment

  • sandbox-agent SDK: v0.4.2
  • @agentclientprotocol/sdk: v0.16.1
  • Agent: claude
  • Sandbox: E2B (Firecracker)
  • Claude Code binary: ~/.local/share/sandbox-agent/bin/claude

Workaround

Currently we symlink plugin skills into the workspace .claude/skills/ directory after provisioning and before session creation. This works but bypasses the plugin system entirely.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions