Skip to content

Commit dab37fd

Browse files
author
LittleCoinCoin
committed
docs(mcp): add comprehensive synchronization command documentation
Create complete documentation for Phase 3f sync functionality: New documentation: - docs/articles/users/MCP/synchronization_commands.md: Comprehensive sync guide * Cross-environment and host-to-host synchronization * Advanced filtering with server names and regex patterns * Safety features (dry-run, backup, confirmation) * Common use cases and workflow examples Updated documentation: - docs/articles/users/MCPHostConfiguration.md: Updated sync section * Reference to new comprehensive sync commands * Modern command syntax examples - docs/articles/users/CLIReference.md: Complete MCP CLI reference * All MCP commands with full syntax and options * Detailed parameter descriptions and defaults Follows organization documentation standards with focused technical clarity, practical examples, and proper cross-referencing between articles.
1 parent 80f67a1 commit dab37fd

File tree

3 files changed

+428
-8
lines changed

3 files changed

+428
-8
lines changed

docs/articles/users/CLIReference.md

Lines changed: 174 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -307,6 +307,180 @@ HATCH_AUTO_APPROVE=yes hatch package add production_package
307307

308308
---
309309

310+
## MCP Host Configuration Commands
311+
312+
### `hatch mcp configure`
313+
314+
Configure an MCP server on a specific host platform.
315+
316+
Syntax:
317+
318+
`hatch mcp configure <server-name> --host <host> [--command CMD] [--args ARGS] [--url URL] [--header HEADER] [--env-var VAR] [--dry-run] [--auto-approve] [--no-backup]`
319+
320+
| Argument / Flag | Type | Description | Default |
321+
|---:|---|---|---|
322+
| `server-name` | string (positional) | Name of the MCP server to configure | n/a |
323+
| `--host` | string | Target host platform (claude-desktop, cursor, etc.) | n/a |
324+
| `--command` | string | Command to execute for local servers | none |
325+
| `--args` | string | Command arguments for local servers | none |
326+
| `--url` | string | URL for remote MCP servers | none |
327+
| `--header` | string | HTTP headers for remote servers (repeatable) | none |
328+
| `--env-var` | string | Environment variables (repeatable) | none |
329+
| `--dry-run` | flag | Preview configuration without applying changes | false |
330+
| `--auto-approve` | flag | Skip confirmation prompts | false |
331+
| `--no-backup` | flag | Skip backup creation before configuration | false |
332+
333+
### `hatch mcp sync`
334+
335+
Synchronize MCP configurations across environments and hosts.
336+
337+
Syntax:
338+
339+
`hatch mcp sync [--from-env ENV | --from-host HOST] --to-host HOSTS [--servers SERVERS | --pattern PATTERN] [--dry-run] [--auto-approve] [--no-backup]`
340+
341+
| Flag | Type | Description | Default |
342+
|---:|---|---|---|
343+
| `--from-env` | string | Source Hatch environment (mutually exclusive with --from-host) | none |
344+
| `--from-host` | string | Source host platform (mutually exclusive with --from-env) | none |
345+
| `--to-host` | string | Target hosts (comma-separated or 'all') | n/a |
346+
| `--servers` | string | Specific server names to sync (mutually exclusive with --pattern) | none |
347+
| `--pattern` | string | Regex pattern for server selection (mutually exclusive with --servers) | none |
348+
| `--dry-run` | flag | Preview synchronization without executing changes | false |
349+
| `--auto-approve` | flag | Skip confirmation prompts | false |
350+
| `--no-backup` | flag | Skip backup creation before synchronization | false |
351+
352+
### `hatch mcp remove server`
353+
354+
Remove an MCP server from one or more hosts.
355+
356+
Syntax:
357+
358+
`hatch mcp remove server <server-name> --host <hosts> [--dry-run] [--auto-approve] [--no-backup]`
359+
360+
| Argument / Flag | Type | Description | Default |
361+
|---:|---|---|---|
362+
| `server-name` | string (positional) | Name of the server to remove | n/a |
363+
| `--host` | string | Target hosts (comma-separated or 'all') | n/a |
364+
| `--dry-run` | flag | Preview removal without executing changes | false |
365+
| `--auto-approve` | flag | Skip confirmation prompts | false |
366+
| `--no-backup` | flag | Skip backup creation before removal | false |
367+
368+
### `hatch mcp remove host`
369+
370+
Remove complete host configuration.
371+
372+
Syntax:
373+
374+
`hatch mcp remove host <host-name> [--dry-run] [--auto-approve] [--no-backup]`
375+
376+
| Argument / Flag | Type | Description | Default |
377+
|---:|---|---|---|
378+
| `host-name` | string (positional) | Name of the host to remove | n/a |
379+
| `--dry-run` | flag | Preview removal without executing changes | false |
380+
| `--auto-approve` | flag | Skip confirmation prompts | false |
381+
| `--no-backup` | flag | Skip backup creation before removal | false |
382+
383+
### `hatch mcp list hosts`
384+
385+
List available MCP host platforms.
386+
387+
Syntax:
388+
389+
`hatch mcp list hosts [--detailed]`
390+
391+
| Flag | Type | Description | Default |
392+
|---:|---|---|---|
393+
| `--detailed` | flag | Show detailed host information | false |
394+
395+
### `hatch mcp list servers`
396+
397+
List configured MCP servers on hosts.
398+
399+
Syntax:
400+
401+
`hatch mcp list servers [--host HOST] [--detailed]`
402+
403+
| Flag | Type | Description | Default |
404+
|---:|---|---|---|
405+
| `--host` | string | Specific host to list servers for | all hosts |
406+
| `--detailed` | flag | Show detailed server information | false |
407+
408+
### `hatch mcp discover hosts`
409+
410+
Discover available MCP host platforms on the system.
411+
412+
Syntax:
413+
414+
`hatch mcp discover hosts`
415+
416+
### `hatch mcp discover servers`
417+
418+
Discover MCP servers in Hatch environments.
419+
420+
Syntax:
421+
422+
`hatch mcp discover servers [--env ENV]`
423+
424+
| Flag | Type | Description | Default |
425+
|---:|---|---|---|
426+
| `--env` | string | Specific environment to discover servers in | current environment |
427+
428+
### `hatch mcp backup create`
429+
430+
Create backup of host configurations.
431+
432+
Syntax:
433+
434+
`hatch mcp backup create --host <hosts>`
435+
436+
| Flag | Type | Description | Default |
437+
|---:|---|---|---|
438+
| `--host` | string | Hosts to backup (comma-separated or 'all') | n/a |
439+
440+
### `hatch mcp backup list`
441+
442+
List available configuration backups.
443+
444+
Syntax:
445+
446+
`hatch mcp backup list [--host HOST] [--detailed]`
447+
448+
| Flag | Type | Description | Default |
449+
|---:|---|---|---|
450+
| `--host` | string | Filter backups by host | all hosts |
451+
| `--detailed` | flag | Show detailed backup information | false |
452+
453+
### `hatch mcp backup restore`
454+
455+
Restore host configuration from backup.
456+
457+
Syntax:
458+
459+
`hatch mcp backup restore <backup-id> [--dry-run] [--auto-approve]`
460+
461+
| Argument / Flag | Type | Description | Default |
462+
|---:|---|---|---|
463+
| `backup-id` | string (positional) | Backup identifier to restore | n/a |
464+
| `--dry-run` | flag | Preview restore without executing changes | false |
465+
| `--auto-approve` | flag | Skip confirmation prompts | false |
466+
467+
### `hatch mcp backup clean`
468+
469+
Clean old backup files.
470+
471+
Syntax:
472+
473+
`hatch mcp backup clean [--older-than DAYS] [--keep-count COUNT] [--dry-run] [--auto-approve]`
474+
475+
| Flag | Type | Description | Default |
476+
|---:|---|---|---|
477+
| `--older-than` | integer | Remove backups older than specified days | none |
478+
| `--keep-count` | integer | Keep only the most recent N backups | none |
479+
| `--dry-run` | flag | Preview cleanup without executing changes | false |
480+
| `--auto-approve` | flag | Skip confirmation prompts | false |
481+
482+
---
483+
310484
## Exit codes
311485

312486
| Code | Meaning |

0 commit comments

Comments
 (0)