EcosystemDatabases
Turso
Connect Turso/libSQL with bounded, parameterized operations.
Use the same full bundle as libSQL with remote credentials:
const client = createClient({
url: process.env.TURSO_DATABASE_URL!,
authToken: process.env.TURSO_AUTH_TOKEN!,
});
export default { persistence: libsqlPersistence({ client }) };Keep URL/token secrets host-side. Mutations use optimistic version fencing and do not require a long-lived interactive transaction. Prefer the primary write URL for durable decisions; replicas can lag. Cascade deletion touches several snapshot rows, so retry it after a partial network failure.
For model-facing data, run fh add turso. The managed recipe installs compatible libSQL packages,
creates a fixed-statement tool and test, and keeps the URL/token in environment variables. Parameterize statements, enforce read/write
separation, limits, tenant predicates, and mutation approval.