Skip to content

SQLite quickstart

Wabe supports named SQLite databases on each disk. Use the HTTP API, the Turso SDK or the virtual wabesql command.

Create the demo disk and a project API key in the quickstart. The request opens or creates the quickstart database.

Terminal window
curl --fail-with-body "https://api.wabe.sh/v1/disks/demo/sqlite/quickstart/hrana/v3/pipeline" \
-H "Authorization: Bearer YOUR_PROJECT_API_KEY" \
--json '{
"requests": [
{"type":"execute","stmt":{"sql":"CREATE TABLE IF NOT EXISTS notes (id INTEGER PRIMARY KEY, body TEXT)"}},
{"type":"execute","stmt":{"sql":"INSERT OR REPLACE INTO notes VALUES (1, ?)","args":[{"type":"text","value":"Hello"}]}},
{"type":"execute","stmt":{"sql":"SELECT body FROM notes WHERE id = 1"}},
{"type":"close"}
]
}'

The third result contains one row with the text value Hello. Check each result for statement errors.

See the HTTP API, Turso SDK and SQL commands.