Skip to main content

Getting started

Install the CLI or an SDK, grab an API key, and run your first query against a collection of your own documents.

What Dewey is

Dewey is a document backend for AI applications. You upload your documents; Dewey handles conversion, chunking, embedding, hybrid retrieval, and agentic research. Your code can stay focused on what to do with the answers instead of building the pipeline to find them.

These guides cover the everyday operations. For protocol-level contracts, see the API reference.

Get your API key

API keys are project-scoped. You'll need two things from the dashboard:

  1. An API key — a string that starts with dwy_live_. Create one in the API Keys section of your dashboard.
  2. Your project ID — visible on the project's settings page, alongside the API keys. You'll pass it when you create collections.
Treat the key like a password — load it from an environment variable rather than checking it into source.

Install

Pick CLI, TypeScript, or Python below. Your selection sticks across every code sample on these guide pages.

# macOS and Linux. Installs the binary to ~/.local/bin.
curl -fsSL https://raw.githubusercontent.com/meetdewey/dewey-cli/main/install.sh | sh

export DEWEY_API_KEY=dwy_live_...

Verify your setup

A quick round-trip to confirm the key, network, and TLS are working.

dewey doctor

# ✓ DEWEY_API_KEY is set (dwy_live_••••3f7a)
# ✓ DNS resolves api.meetdewey.com
# ✓ TLS handshake OK
# ✓ /collections returned 200

Your first collection, document, and query

End-to-end: create a collection, upload a document, wait for it to be ready, and run a hybrid query plus a streaming research answer. Replace YOUR_PROJECT_ID and ./report.pdf with your own values.

# 1. Create a collection (its name is the handle CLI commands use)
dewey collections create my-docs

# 2. Upload a file and stream live processing events until it's ready
dewey upload ./report.pdf -c my-docs --watch

# 3. Hybrid keyword + semantic search for the top chunks
dewey query my-docs "what are the key findings?"

# 4. Stream a cited research answer
dewey research my-docs "summarize the findings" --depth deep

From here, head to a specific recipe: