Expand description
§mcp-sync
Sync canonical MCP configuration to multiple AI coding assistants
mcp-sync reads a single mcp.yaml file and syncs the server definitions
to configuration files for:
- Antigravity (VS Code extension)
- Claude Code (CLI)
- Codex (OpenAI CLI)
- OpenCode
§Quick Start
# One-time sync
mcp-sync sync
# Watch for changes
mcp-sync watch
# Sync only global configs
mcp-sync sync --scope global
# Dry run (show what would change)
mcp-sync sync --dry-run --verbose§Canonical Format
version: 1
servers:
my-server:
command: npx
args: ["-y", "@modelcontextprotocol/server"]
env:
API_KEY: "${API_KEY}"
remote-server:
kind: http
url: https://mcp.example.com/v1
headers:
Authorization: "Bearer ${TOKEN}"§Plugin System
Plugins can transform configurations:
version: 1
plugins:
- name: env-expander
config:
prefix: "${"
suffix: "}"
servers:
# ...See plugin module for creating custom plugins.
Re-exports§
pub use canon::Canon;pub use canon::CanonServer;pub use canon::PluginConfig;pub use canon::read_canon;pub use canon::read_canon_auto;pub use canon::read_canon_from_url;pub use plugin::Plugin;pub use plugin::PluginManager;pub use target::SyncOptions;pub use target::Target;pub use target::TargetManager;pub use targets::all_targets;