Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.driftless.icu/llms.txt

Use this file to discover all available pages before exploring further.

The CLI is the primary interface for developers and agents. Run commands from a Git repository root unless a command explicitly says otherwise.
Set DRIFTLESS_API_KEY for non-interactive environments. Set DRIFTLESS_API_URL only when targeting staging or a local API.

Auth and setup

CommandFlagsDescriptionExample
login--key <key>, --url <url>Authenticate with API keydriftless login --key drift_xxx
init--src <path>, --framework <fw>, --suggestScan repo, upload baseline, install skilldriftless init --src apps/api --suggest
doctor--json8 health checksdriftless doctor
install-skillnoneInstall AGENTS.md + CLAUDE.mddriftless install-skill

Context CRUD

CommandFlagsDescriptionExample
context list--stale, --docs, --auto, --manual, --status, --kind, --repo, --jsonList topics with filtersdriftless context list --stale --auto
context get <topic>--jsonFull topic detaildriftless context get b2b-guard
context get --files--files "a,b", --jsonMatch topics to filesdriftless context get --files "src/auth/guard.ts"
context get --diff--jsonTopics for current changesdriftless context get --diff
context searchquery, --jsonFull-text searchdriftless context search "payment"
context add--what, --how, --pattern, --kind, --tags, --rel, --content, --file, --dry-runCreate topicdriftless context add "payment-flow" --what "Stripe checkout" --pattern "src/billing/**" --kind code-context
context update--what, --gotcha, --decision, --invariant, --add-pattern, --remove-pattern, --rel, --dry-runModify topicdriftless context update payment-flow --gotcha "Idempotency keys required" --add-pattern "src/webhooks/stripe/**"
context delete--dry-run, --jsonDelete topicdriftless context delete payment-flow --dry-run
context load--files "a,b", --dry-run, --jsonContext + coveragedriftless context load --files "src/auth/guard.ts,src/auth/service.ts"
context link--dry-run, --jsonCross-repo linkagedriftless context link payment-flow
context sync--doc <path> or --note "..."Anchor doc or add notedriftless context sync payment-flow --doc docs/billing.md
context doctor--jsonAudit context healthdriftless context doctor
context relations--jsonList typed relationsdriftless context relations payment-flow
context graph--depth N, --jsonTopic knowledge graphdriftless context graph payment-flow --depth 2

Code Graph

CommandFlagsDescriptionExample
graph file<path>, --depth N, --jsonEntrypoints + blast radiusdriftless graph file src/auth/guard.ts --depth 2
graph impact--files "a,b", --depth N, --direction <up|down|both>, --jsonChange impact analysisdriftless graph impact --files "src/shared/utils.ts" --direction downstream
graph coverage--jsonContext coverage overviewdriftless graph coverage --json

Sync and branches

CommandFlagsDescriptionExample
sync--jsonPull team changesdriftless sync
branches--jsonView tracked branchesdriftless branches
branches add<branch>Track a branchdriftless branches add staging
branches rm<branch>Stop tracking branchdriftless branches rm staging

Global

CommandFlagsDescription
--version / -vnonePrint version
--help / -hnoneFull help
<cmd> --helpnoneCommand-specific help
VariableDescription
DRIFTLESS_API_KEYAPI key (wins over config file)
DRIFTLESS_API_URLAPI server URL (default: https://api.driftless.icu/api/v1)
DRIFTLESS_MAX_FILE_BYTESPer-file scan cap for the scanner