sync

A command that copies MCP server settings from Claude Code to other AI coding agents. MCP settings define connections to external tools and services.

In plain words
What is it for?
Use /sync for selected agents or servers, with options for backups, OAuth servers, custom configuration directories, and JSON reports.
Why use it?
It reduces repeated manual configuration when the same tools must be available in several agents.

Command

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/leoyang183/sync-agents-settings/sync
Clone the repo
git clone --depth 1 https://github.com/Leoyang183/sync-agents-settings
Per session 45 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 606 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00045 $0.00606
Opus 5 $0.00023 $0.00303
Sonnet 5 $0.00009 $0.00121
Haiku 4.5 $0.00005 $0.00061

Measured 2d ago against content hash daa3405b102c, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

sync scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

commands/sync.md · 54 lines

How it starts

The opening of the file, as written. The whole thing — 54 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Sync MCP server settings from Claude Code to other AI coding agents.

Arguments

The user may pass target names after the command: /sync gemini codex If no targets specified, sync to all targets (gemini, codex, opencode, kiro, cursor, kimi, vibe, qwen, amp, cline, windsurf).

The user may also pass server names to sync only specific servers: /sync --server context7 supabase

The user may also pass flags:

  • --server <names...> or -s <names...> — sync only specified MCP servers by name
  • --skip-oauth — skip MCP servers that require OAuth authentication
  • --no-backup — skip creating backup of target config files
  • --codex-home <path> — custom Codex config directory
  • --kimi-home <path> — custom Kimi config directory
  • --vibe-home <path> — custom Vibe config directory
  • --qwen-home <path> — custom Qwen Code config directory
  • --amp-home <path> — custom Amp config directory
  • --cline-home <path> — custom Cline CLI config directory
  • --windsurf-home <path> — custom Windsurf config directory
  • --report json — output machine-readable JSON summary (CI-friendly)

Execution Flow

  1. Parse targets and server names from user arguments. Build the command: npx sync-agents-settings sync --dry-run --target <targets> Add --server <names> if the user specified specific servers. Add --skip-oauth or --no-backup if the user specified them.

  2. Run the dry-run command using bash. This previews what will change without writing files.

  3. Present the results to the user:

    • Servers that will be added to each target
    • Servers that will be skipped (already exist or unsupported)
    • If all servers are skipped, inform the user and stop here.
  4. Ask the user: "Proceed with sync?"

  5. If confirmed, run the same command without --dry-run: npx sync-agents-settings sync --target <targets>

  6. Present the final results.

    • If --report json is used, return raw JSON and avoid text post-processing.

Error Handling

  • If npx fails with "command not found" or network error: suggest npm install -g sync-agents-settings as fallback.
  • If the CLI exits with non-zero code: show the stderr output and suggest checking that target agent directories exist.

Read the full file on GitHub · 54 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 54 lines · 45 tokens per session scan A daa3405b102c

Subscribe to this mod's changes

sync is a command published in the GitHub repository Leoyang183/sync-agents-settings (8 stars, last pushed 5mo ago), licensed MIT. It adds 45 tokens to every session and 606 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.