Skip to content
DataHashi Docs

Getting started

This walks through the shortest path from “I have a warehouse” to “I ran a query.”

datahashi is split into two planes, at two hosts:

  • Control plane (api.datahashi.com) — your workspace, connections, models, and API keys. This is what the console talks to.
  • Data (query) plane (engine.datahashi.com) — where queries actually run, over REST or MCP.
Two planes, one credential The control plane manages your workspace, connections, models, and API keys. The API key it mints is sent as a bearer token to the data plane, which compiles REST or MCP requests and runs them against your warehouse. CONTROL PLANE — api.datahashi.com Workspace Connections Semantic models API keys bearer token — workspace + mode DATA PLANE — engine.datahashi.com REST /v1/query MCP /mcp Compiled & run against your warehouse
The same credential — a bearer token carrying workspace and mode — crosses from control plane to data plane on every request.

Sign in at the console and create a workspace (called an org in the API). A workspace is the isolation boundary for your sources, models, and API keys — nothing crosses between workspaces.

Connect the warehouse your models will query — Snowflake, BigQuery, Postgres, MySQL, or DuckDB. datahashi stores the connection’s address and credential; it never widens the access that credential already grants, and row-level security and cost limits are layered on top server-side. You can connect more than one source — each semantic model binds to exactly one.

A model is YAML: entities (your business nouns), dimensions and measures on those entities, and metrics built from measures. See Write your first model for a full walkthrough, or the semantic model glossary for the vocabulary first.

From your workspace, mint an API key (POST /v1/orgs/{orgId}/api-keys on the control plane). Every key is scoped to a mode:

  • governed — the default. Consumers see named metrics and curated views only.
  • explore — additionally exposes raw measures and dimensions across the join graph, for internal tooling and analysts.

The key is a bearer token, shown exactly once — store it somewhere safe. You can revoke or rotate it later without disrupting your other keys.

Send the key as a bearer token to the data plane:

Terminal window
curl https://engine.datahashi.com/v1/query \
-H "Authorization: Bearer $DATAHASHI_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"metrics": ["avg_order_value"],
"dimensions": [{ "name": "region" }],
"order": [{ "ref": "region" }],
"limit": 100
}'

See Query the API for the full request/response shape, or Use with an LLM agent to wire the same credential up over MCP instead.