ekoDB CLI verbs and JSON output for agents
The command surface below was checked on December 4, 2026. Check ekodb-cli --version and ekodb-cli --help on the installed binary before using a command from a newer release.
Setup and managed skills
The ekoDB CLI connects coding agents through the ekoDB Web App. For ekoDB CLI v0.3.0 or later, start with:
ekodb-cli setup
Connect your coding agent covers browser consent, scoped native-store credentials and managed skills. Claude Code and Codex receive hosted MCP with OS-keychain helpers and skills. Gemini CLI receives managed GEMINI.md skills only; MCP authentication is deferred, alongside Copilot CLI. AI Hive is the optional managed AI server; literal options such as --claw-url and --server claw retain their technical names.
ekodb-cli skills update refreshes from the installed CLI's vendored bundle offline; ekodb-cli skills uninstall removes managed skills. Update the CLI for a newer bundle. ekodb-cli setup --uninstall also removes its MCP registrations and native-store credentials.
Connection and output
Ops commands read EKODB_URL and EKODB_API_KEY. --url <base-url> overrides the URL; --api-key-file <path> overrides the key environment variable. The file contains the key only and must be protected. No ops argument accepts the key value itself. The CLI obtains a JWT through the client library.
Use --format json for machine consumption. The default is table; csv is also available. JSON output is pretty-printed JSON with a final newline, not JSON Lines and not an extra {data: ...} wrapper. It preserves nested values, including typed-value envelopes when returned by the server. Record keys are ordered with id first, followed by sorted fields. Treat object key order as presentation, not an API contract.
Read stdout only on a successful exit. Error diagnostics go to stderr; exit 1 means a refused or invalid answer, 2 means no answer or a command/connection problem. A timeout is bounded by --timeout-secs (default 10, minimum 1), covering the entire authenticated command. Do not substitute an empty JSON array when the command fails. Use the installed command's help for version-specific options.
Implemented ops verbs
| Command | Result |
|---|---|
ekodb-cli --format json health | Health report; no API key needed |
ekodb-cli --format json collections list | Array of collection names |
ekodb-cli --format json collections schema <name> | Schema object |
ekodb-cli --format json records get <collection> <id> | Record object |
ekodb-cli --format json records query <collection> --limit 25 | Array of matching records |
ekodb-cli --format json functions list | Array of stored-function definitions |
These ops verbs read data. Use an SDK, REST or the permitted MCP tools for writes or function calls; do not invent records insert, kv set or functions call ops commands.
records query --filter accepts a filter expression, not the whole query object. --limit and --skip are separate options:
ekodb-cli --format json records query agent_tasks \
--filter '{"type":"Condition","content":{"field":"active","operator":"Eq","value":true}}' \
--limit 25 --skip 0
Omitting --limit uses the server default, normally 1,000. --limit 0 requests all matches subject to the unpaginated ceiling. Oversized limits and offsets fail rather than being clamped. The pinned CLI has no sort/cursor option; use an SDK or REST for a keyset paging loop. Canonical formats covers filters, missing-resource responses and typed values.
Hosted MCP and approvals
mcp, approvals and chat have their own parsers and output; the ops --format contract does not apply to them. Place these subcommands first and use their --help.
| Command family | Purpose |
|---|---|
ekodb-cli mcp login / status / logout | Sign in, inspect or end hosted MCP credentials |
ekodb-cli mcp install <harness> / uninstall <harness> | Register/remove hosted servers in a supported coding agent |
ekodb-cli approvals watch --server ekodb | Human approval surface for database MCP calls |
ekodb-cli approvals watch --server claw | Human approval surface for AI Hive MCP calls |
ekodb-cli chat --agent claude-code or --agent codex | Chat through the installed external coding agent |
Follow Connect your coding agent and Human approvals for credentials, profiles and approval identity. mcp auth-header emits credential-bearing fixed JSON for the harness; never display it in agent conversation or logs. The local mcp serve transport has been retired. Do not assume a generated bundle has already been installed; use setup or the managed-skill commands above.