skeld Get started

Modules

PostgreSQL and SQLite, through one query API.

Connects a skeld service to PostgreSQL or SQLite. Every value you put into a query travels as a parameter, and what the database says about a failure stays out of responses and logs.

Install
npm install @skeld/data
Needs
@skeld/core, and nothing else
Talks to
PostgreSQL and SQLite
No database driver is installed. skeld speaks to PostgreSQL itself.

What it is

The module for stored data. You write SQL, and data sends each value separately from the query text, so a request value cannot change what the query means. It manages the pool of connections, runs transactions, checks rows coming back against a schema when you name one, and can limit how often a client may call a route.

Should you use it

What it is not

  • An ORM. There are no models and no query builder; you write SQL.
  • A database. You still run PostgreSQL or keep the SQLite file, with its backups and access.
  • Proven behind every connection pooler or managed service. Try it against yours first.

When to reach for it

  • Your service stores anything.
  • You want one way to write queries for both PostgreSQL and SQLite.
  • A route needs a rate limit.

What good looks like

  • Every value goes through the query tag; nothing is joined into SQL text.
  • Queries that feed a response name a row schema.
  • Writes that belong together sit in one transaction.
  • The connection to the database uses TLS.

Where to go next