Skip to main content
The crustdata CLI gives you the full Crustdata API in your terminal. Each API endpoint is a command with typed flags. On a terminal, the CLI prints markdown tables. When you pipe the output to another program, the CLI prints raw JSON. You, your scripts, and your agents can use the same commands.

Quick start

1

Install

On macOS and Linux:
On Windows:
The installer verifies the checksums and puts the binary in ~/.crustdata/bin. It also adds that directory to your PATH. To stop the installer from changing your PATH, set CRUSTDATA_NO_MODIFY_PATH=1.After the install, open a new terminal. To upgrade the CLI later, run crustdata upgrade.
2

Authenticate

This command opens your browser. Sign in and pick your team. The CLI then saves the API key for that team.If the machine has no browser, add --no-browser. The CLI prints the sign-in URL and asks you to paste the redirect back.For CI and scripts, set CRUSTDATA_API_KEY, or read the key from a file with crustdata auth login --with-token < key.txt. Non-interactive authentication compares the options.
3

Run a command

This command returns the basic_info and headcount fields for stripe.com.

Commands

Run crustdata <command> --help to see the flags and runnable examples for any command.

Live mode

Four commands support --live:
  • company search
  • person search
  • person enrich
  • job search
Without --live, these commands query the indexed dataset. With --live, they query the professional network in real time. Live search uses different field names from indexed search, for example REGION and CURRENT_TITLE. Live company search and live person search also need --page.

Filters

Search commands take a --filter flag in the form 'field op value'. You can repeat --filter. The CLI joins all filters with AND.
The operators are the same as in the API: =, !=, <, >, =<, =>, in, not_in, (.), and [.]. For in and not_in, give a comma-separated list of values. Field names are the API’s dot-paths, such as headcount.total. If the API does not know a field name, it returns invalid_request: Unsupported columns in conditions. To check a field name before you send a request, use --dry-run, tab completion, or the field tables in the API reference.

OR logic and nested groups

--filter gives you AND only. For OR logic and nested groups, write the full JSON request body and pass it with --input:
  • --input query.json reads the body from a file.
  • --input - reads the body from stdin.
If you also pass a flag, the flag value replaces the matching field in the body. The company examples include an OR query.

Output

On a terminal, the CLI prints markdown tables. When you pipe the output, the CLI prints the raw JSON response. To choose the format yourself, add --format json or --format md. To select part of the JSON response, use the built-in --jq flag. You do not need to install jq. --jq always prints JSON.
The CLI writes data only to stdout. It writes progress messages and hints to stderr. The CLI does not fetch the next page for you, because each page costs credits. To get the next page of an indexed search, pass the next_cursor value from the response to --cursor.

Exit codes

Preview requests for free

Use these tools to build a request before you spend credits:
  • --dry-run prints the request body that the CLI composes, and does not send it. Every request command supports --dry-run.
  • --example prints request examples from the API spec. Every request command supports --example.
  • Tab completion suggests field names and operators.
These tools spend no credits and need no authentication.

Dry runs

Spec examples

To print a named example, use the = form: --example=name. With no name, --example lists the examples that exist.

Tab completion

To turn on tab completion in your current shell session, run this line:
To turn on completion for every new session, follow the steps in crustdata completion zsh --help. Tab completion then fills in field names and operators:
Tab completion does not fill in values. To get valid values for a field, use a suggest command, such as crustdata company suggest country 'Uni' or crustdata person suggest basic_profile.city 'San'. Unlike the tools above, suggest calls the API.

Examples

Each example below runs as written on CLI v0.2.5.

Companies

People

Jobs, posts, and the web

Account and housekeeping

Bulk jobs

This command does three things:
  1. It submits the bulk job.
  2. It polls the job until the job completes (--wait).
  3. It downloads the results as decompressed JSONL (--download).
You can also submit a job without --wait and come back to it later:

Search the docs

The CLI can search and read these docs. It uses the public docs MCP server, so you do not need to authenticate.

Set up the Crustdata MCP

The Model Context Protocol (MCP) lets agent clients, such as Claude Code and Cursor, call external tools. crustdata mcp install adds the hosted Crustdata MCP server to your agent clients.
Supported targets:
  • claude-code installs the Crustdata plugin, which includes the MCP server and skills. To install only the MCP server, add --mcp-only.
  • cursor, vscode, and windsurf get a crustdata entry in the client’s MCP config.
  • claude-desktop connects through the mcp-remote bridge.
  • claude-web gets printed manual steps, because connectors are set at the account level.
The CLI edits only the crustdata entry in each client config. It keeps all other entries as they are. To see the exact change without writing it, add --dry-run. By default, each client signs in with OAuth the first time it connects. For headless setups, where nobody can complete a browser sign-in, use one of these flags:
  • --with-key writes your saved API key into the client config as plain text. The CLI prints a warning when you use it.
  • --with-key=env writes the reference ${env:CRUSTDATA_API_KEY} instead of the key itself.

For scripts and agents

  • When you pipe the output, the CLI always prints raw JSON.
  • --jq works everywhere and needs no other install.
  • --help on any command shows runnable examples.
  • --dry-run composes any request without sending it. An agent can use it to explore commands without spending credits.
  • The CLI writes data only to stdout. The exit codes tell you what failed.

Non-interactive authentication

The CLI opens a browser only when it runs on a real terminal. When stdin is a pipe, the CLI never opens a browser. The CLI shows the paste prompt only when you give it no key in another way. This means an agent never waits on a hidden prompt. Use one of these three methods:
auth login checks the key against the API before it saves the key. If the key is not valid, the command exits with code 4. A bad key fails at setup, not in the middle of a task. To see the current authentication state, run crustdata auth status.