Kysely

Build type-safe SQL queries for TypeScript applications with Kysely.

Updated Feb 12, 2026
One-click install
npx skills add https://github.com/harrytran998/crossfire --skill kysely
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: Kysely
Source: https://github.com/harrytran998/crossfire/tree/main/.agents/skills/kysely
Command: npx skills add https://github.com/harrytran998/crossfire --skill kysely

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill provides a type-safe way to build SQL queries in TypeScript, preventing runtime errors and improving developer productivity by catching SQL issues at compile time.

Core Features & Use Cases

  • Type-Safe Query Building: Ensures SQL queries are valid and match your database schema at compile time.
  • Database Agnostic: Supports multiple database engines like PostgreSQL, MySQL, and SQLite.
  • Use Case: When developing a new feature that requires complex database interactions, use this Skill to write and validate all your SQL queries, ensuring data integrity and preventing common bugs.

Quick Start

Use the Kysely skill to create a new user record in the database with the provided name and email.

Frequently Asked Questions about Kysely

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I build type-safe SQL queries in TypeScript to catch errors at compile time?

Type-safe SQL queries in TypeScript are built using the Kysely query builder, which validates database operations like joins and inserts against your schema at compile time. This prevents runtime errors by ensuring query validity before execution.

Does this approach to building SQL queries support multiple database engines like PostgreSQL and SQLite?

Yes, this type-safe query builder supports multiple database engines including PostgreSQL, MySQL, and SQLite. It is database agnostic, allowing you to integrate it with various database dialects within your existing TypeScript projects.

What's the best way to validate complex database interactions and transactions in TypeScript?

The best way to validate complex database interactions in TypeScript is using a type-safe query builder. It facilitates operations like select, insert, update, delete, joins, and transactions with compile-time validation to ensure data integrity.

How do I insert a new record into a database using a type-safe TypeScript query builder?

To insert a new record, use the query builder to construct an insert operation with your data payload, such as name and email. The builder ensures the inserted data matches your database schema types at compile time before executing the query.

Why should I use a type-safe query builder instead of writing raw SQL queries in TypeScript?

A type-safe query builder prevents runtime errors and improves developer productivity by catching SQL issues at compile time. Unlike raw SQL, it ensures queries match your database schema, providing enhanced data integrity for complex database operations.