About wiki-cli
wiki-cli is a read-only transport skill for Obsidian vaults. It checks whether the official Obsidian CLI is usable, then supports reading and searching, with filesystem access as a fallback.
Key features
- 01CLI availability detection
- 02Read notes through Obsidian CLI
- 03Search vault content
- 04Filesystem and rg fallback
- 05Vault path confinement
Use cases
- 01Checking CLI readiness before reading
- 02Reading a note from the selected vault
- 03Searching when CLI access is available
- 04Falling back to file reads and rg
Install
Copy the command and run it in a terminal.
npx skills add https:/ / github.com/ agricidaniel/ claude-obsidian --skill wiki-cliAfter installing, type/wiki-cliin Claude Code to confirm it loaded.
Details
From the project READMEObsidian CLI read transport
Use this skill only to detect transport and read or search a selected vault.
The official executable is obsidian; binary presence alone does not prove it
is usable.
Resolve the installed product root from this skill's own location, not from the vault or current working directory:
PRODUCT_ROOT=/absolute/path/to/installed/claude-obsidian
DETECT_TRANSPORT="$PRODUCT_ROOT/scripts/detect-transport.sh"
test -f "$DETECT_TRANSPORT"
Every ../wiki/references/ link in this file resolves the same way, relative
to this skill's own directory under $PRODUCT_ROOT, never relative to the
selected vault's wiki/ directory.
Detect safely
Probe without persisting host state:
bash "$DETECT_TRANSPORT" --peek --vault "$VAULT"
Trust available.cli.usable, not merely present or exit status. A supported
CLI can still be unavailable because the Obsidian app is not running, command
line access is disabled, or its response is an error. Use filesystem reads as
the portable fallback.
Persist a refreshed .vault-meta/transport.json only when the user or setup
workflow asks for a transport snapshot:
bash "$DETECT_TRANSPORT" --force --vault "$VAULT"
That file is derived runtime configuration, not knowledge content. Preserve a
valid manual_override recorded by the detector.
Read and search
Run official CLI commands from the selected vault so Obsidian resolves the correct workspace. Confirm supported syntax with the installed CLI before relying on optional commands. Typical read-only forms are:
(cd "$VAULT" && obsidian read path="$NOTE")
(cd "$VAULT" && obsidian search query="$QUERY")
Use read-only commands for backlinks, tags, or Bases results only when the
detector reports the CLI ready. Otherwise read files under $VAULT directly
and use rg for search. Reject absolute note arguments, traversal, symlinks, or
resolved paths outside the selected vault.
Mutation boundary
Do not use CLI create, write, append, property-set, daily-append, move, rename, or delete commands. Do not replace those commands with direct filesystem writes. Any knowledge or configuration change must be expressed as one reviewed transaction through the portable core; see operation transactions.
Transport choice never changes mutation semantics. The CLI is an optional read surface, not a lock manager, transaction engine, or Git checkpoint mechanism.
Checkpoint
Observe actual capability, think about the least complex read transport, verify that every resolved path stays in the vault, and accept filesystem fallback when the CLI is not ready.