Skip to main content
Version: 0.2.3

CLI Commands Reference

All Sercha functionality is accessible via CLI commands. The CLI and Terminal UI share the same core services, so behaviour is consistent across both interfaces.

Command Summary

CommandDescription
sercha searchSearch indexed documents
sercha sourceManage document sources
sercha documentManage indexed documents
sercha syncSynchronise documents from sources
sercha authManage OAuth and PAT authorisations
sercha settingsConfigure search modes and AI providers
sercha tuiLaunch interactive Terminal UI
sercha mcpStart MCP server for AI assistants
sercha connector listList available connector types
sercha versionPrint version information

Global Flags

These flags are available for all commands:

FlagShortDescription
--verbose-vEnable verbose debug output
--configPath to config file (default: $HOME/.sercha.yaml)
--help-hDisplay help for any command

Global Behaviour

All commands share these characteristics:

  • Exit codes: 0 for success, 1 for errors
  • Error output: Errors are printed to stderr
  • Service injection: All commands use the same core services, ensuring consistent behaviour with the TUI