Getting Started
Deltex is a PostgreSQL-flavored SQL engine compiled to WebAssembly and run at the edge. There is nothing to install on the server side — you create a database, get an API key, and query it over HTTPS from anywhere.
1 · Create an account
The fastest way to start is the web console. Sign in with your email — we send a 6-digit code, and once you verify it you get a database and an API key automatically.
You can also do it from the command line. Request a login code:
# Step 1 — request a 6-digit code by email curl -X POST https://ctrl.deltex.dev/v1/magic-key \ -H 'Content-Type: application/json' \ -d '{"email":"you@example.com"}'
Check your inbox, then exchange the code for an API key:
# Step 2 — verify the code, receive your API key curl -X POST https://ctrl.deltex.dev/v1/magic-key \ -H 'Content-Type: application/json' \ -d '{"email":"you@example.com","otp":"123456"}' # → { "api_key": "dtx_k_...", "db_id": "d_...", "endpoint": "https://db.deltex.dev" }
Your API key grants full read/write/admin access to your database. Store it as a secret — treat it like a password. You can rotate or revoke keys from the console at any time.
2 · Run your first query
Every query is a single HTTPS request. Send SQL as JSON to /v1/query with your key as a Bearer token:
curl -X POST https://db.deltex.dev/v1/query \ -H 'Authorization: Bearer dtx_k_your_key' \ -H 'Content-Type: application/json' \ -d '{"sql":"SELECT 1 + 1 AS answer"}' # → { "success": true, "columns": ["answer"], "rows": [{"answer": 2}] }
3 · Create a table and insert data
Deltex speaks standard SQL DDL and DML. Each statement is its own request:
CREATE TABLE users ( id INT PRIMARY KEY, name TEXT NOT NULL, email TEXT, created_at TEXT DEFAULT CURRENT_TIMESTAMP ); INSERT INTO users (id, name, email) VALUES (1, 'Alice', 'alice@example.com'), (2, 'Bob', 'bob@example.com'); SELECT name, email FROM users ORDER BY id;
To run several statements atomically, use POST /v1/transaction with an array of statements. See the HTTP API reference.
4 · Use the console
The web console gives you a SQL editor with schema-aware autocomplete, a table browser, query history, live metrics, and API-key management. It's the easiest way to explore your data without writing any code.
Next steps
- SQL Reference — every supported statement, function, and operator.
- SDKs — TypeScript, Python, Go, and Rust clients.
- HTTP API — endpoints, auth, transactions, streaming, and error codes.
- Architecture — how the edge executor and storage tiers work.