Keyboard shortcuts

Press โ† or โ†’ to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Config Management Commands

Manage individual stored configs after import.

These commands operate on config IDs from xrat list configs.

When to Use These Commands

CommandUse when you want to
addStore one share link without creating a subscription source record
showInspect one stored config
enableInclude a config in normal filtered workflows
disableKeep a config stored but skip it in normal filtered workflows
deleteHide a config from normal lists while preserving history
restoreBring a soft-deleted config back

Config State

active, enabled, and deleted are separate states.

StateMeaning
activeThe config used by the current managed runtime session.
enabledIncluded in normal list, test, and rotation workflows.
disabledStored but skipped by enabled-only workflows.
deletedSoft-deleted and hidden unless --deleted or --all used.

Use xrat connect <id> when you want to start a proxy runtime. Use xrat proxy start when you want the daemon to manage automatic rotation.


add

Add a single config URI directly to the database.

xrat add <input>

Arguments

ArgumentDescription
inputConfig URI: vless://..., vmess://..., ss://..., trojan://..., hysteria2://..., etc.

Examples

xrat add "vless://uuid@example.com:443?type=ws&security=tls#Node"

Unlike xrat import, xrat add does not create or update a subscription source record.


show

Show details for one stored config.

xrat show <id> [flags]

Arguments

ArgumentDescription
idConfig ID to show

Flags

FlagDescription
--jsonPrint the result as JSON

Examples

xrat show 42
xrat show 42 --json

enable

Enable a config.

xrat enable <id>

Arguments

ArgumentDescription
idConfig ID to enable

Enabled configs are included in normal enabled-only workflows, such as:

xrat list configs --enabled-only
xrat test --enabled-only

disable

Disable a config.

xrat disable <id>

Arguments

ArgumentDescription
idConfig ID to disable

Disabled configs remain in the database but are excluded from enabled-only queries, tests, and rotation candidate selection.


delete

Soft-delete a config by default.

xrat delete <id> [flags]

Arguments

ArgumentDescription
idConfig ID to delete

Flags

FlagDescription
--hardPermanently delete the config

Soft-deleted configs are hidden from normal lists but can still be viewed with:

xrat list configs --deleted
xrat list configs --all

Use --hard only when the row should be permanently removed.


restore

Restore a soft-deleted config.

xrat restore <id>

Arguments

ArgumentDescription
idConfig ID to restore

restore only applies to soft-deleted configs. It does not recreate a config that was removed with delete --hard.

  • list โ€” find config IDs and filter by state
  • runtime โ€” connect, disconnect, and inspect active sessions
  • tui โ€” manage configs interactively