Skip to content

CLI Reference

Run dinobase --help for a summary, or dinobase <command> --help for any command.

Create the config directory and database.

Terminal window
dinobase init [OPTIONS]
OptionDescription
--storageCloud storage URL (e.g., s3://bucket/dinobase/, gs://bucket/dinobase/, az://container/dinobase/)

Creates ~/.dinobase/ with config.yaml and dinobase.duckdb. Safe to run multiple times.

With --storage, data is stored in cloud storage instead of locally. See the Cloud Storage Backend guide.

Terminal window
dinobase init # local (default)
dinobase init --storage s3://bucket/dinobase/ # S3
dinobase init --storage gs://bucket/dinobase/ # GCS
dinobase init --storage az://container/dinobase/ # Azure

Add a data source.

Terminal window
dinobase add <source_type> [OPTIONS]
OptionDescription
--nameCustom name for the source (defaults to type)
--pathPath to files (parquet/csv sources only)
--sync-intervalSync interval (e.g., 30m, 1h, 6h)
--freshnessFreshness threshold (e.g., 1h, 30m). Defaults: 1h for SaaS, 6h for databases

Source-specific flags (e.g., --api-key, --connection-string) are passed through.

Terminal window
dinobase add stripe --api-key sk_live_...
dinobase add stripe --api-key sk_live_... --freshness 30m
dinobase add parquet --path ./data/ --name analytics
dinobase add postgres --connection-string postgresql://... --name prod --sync-interval 30m

List connected data sources, or all available source types.

Terminal window
dinobase sources [OPTIONS]
OptionDescription
--availableShow all available source types (not just connected)
--prettyHuman-readable output

By default shows only your connected sources. Use --available to see all 100+ supported source types grouped by category.


Sync data from connected sources.

Terminal window
dinobase sync [SOURCE_NAME] [OPTIONS]
OptionDefaultDescription
--scheduleoffRun as daemon
--interval1hDefault interval for --schedule
--max-workers10Max concurrent syncs
Terminal window
dinobase sync # all sources, once
dinobase sync stripe # one source
dinobase sync --schedule --interval 30m # daemon mode

Re-sync sources to get fresh data.

Terminal window
dinobase refresh [SOURCE_NAME] [OPTIONS]
OptionDescription
--staleRefresh only sources that exceed their freshness threshold
--prettyHuman-readable output
Terminal window
dinobase refresh # refresh all sources
dinobase refresh stripe # refresh one source
dinobase refresh --stale # refresh only stale sources
dinobase refresh --stale --pretty

Without arguments, refreshes all non-file sources. Use --stale to only refresh sources past their freshness threshold.


Show status of all sources.

Terminal window
dinobase status [OPTIONS]
OptionDescription
--prettyHuman-readable output

Execute a SQL query (DuckDB dialect).

Terminal window
dinobase query "<sql>" [OPTIONS]
OptionDefaultDescription
--prettyoffTable output
--max-rows200Max rows returned
Terminal window
dinobase query "SELECT * FROM stripe.customers LIMIT 5" --pretty
dinobase query "SELECT COUNT(*) FROM hubspot.contacts"

Describe a table’s columns, types, annotations, and sample data.

Terminal window
dinobase describe <table> [OPTIONS]
OptionDescription
--prettyHuman-readable output

table can be schema.table or just table (searches all schemas).


Show database overview for agents. Outputs the same text used as MCP server instructions.

Terminal window
dinobase info

No options. Always plain text.


Start the MCP server (stdio transport).

Terminal window
dinobase serve [OPTIONS]
OptionDefaultDescription
--syncoffEnable background sync
--sync-interval1hSync interval
Terminal window
dinobase serve # MCP server only
dinobase serve --sync --sync-interval 30m # with background sync

Confirm and execute a pending mutation.

Terminal window
dinobase confirm <mutation_id>

Mutations submitted via dinobase query "UPDATE ..." return a preview with a mutation_id. Use this command to execute it.

Terminal window
dinobase query "UPDATE stripe.customers SET name = 'Acme' WHERE id = 'cus_123'"
# Returns preview with mutation_id
dinobase confirm mut_abc123def456

Cancel a pending mutation without executing it.

Terminal window
dinobase cancel <mutation_id>

Connect a source via OAuth (browser-based authorization).

Terminal window
dinobase auth <source_type> [OPTIONS]
OptionDescription
--nameCustom name for the source (defaults to type)
--proxy-urlOAuth proxy URL (or set DINOBASE_OAUTH_PROXY_URL)

Opens your browser to authorize Dinobase to access the source. Tokens are stored locally and refreshed automatically on sync.

Terminal window
dinobase auth hubspot
dinobase auth salesforce --name my_salesforce

Print MCP configuration for Claude Code, Claude Desktop, or Cursor.

Terminal window
dinobase mcp-config [CLIENT]
ArgumentDescription
claude-desktopConfig for ~/.claude/claude_desktop_config.json
claude-codeConfig for .mcp.json (project root)
cursorConfig for .cursor/mcp.json (project root)

Without arguments, prints configs for all three clients.

Terminal window
dinobase mcp-config # show all configs
dinobase mcp-config claude-desktop # Claude Desktop only
dinobase mcp-config claude-code # Claude Code only
dinobase mcp-config cursor # Cursor only

All data commands (status, query, describe) output JSON by default, optimized for agent consumption. Add --pretty for human-readable tables.