database

A collection of scripts for managing PostgreSQL, SQLite, and Redis databases. Databases store application data; migrations apply planned schema changes, and backups save data for recovery.

In plain words
What is it for?
Use it to run migrations, create or restore PostgreSQL and SQLite backups, check database health, manage PostgreSQL users and permissions, and work with Redis.
Why use it?
It provides repeatable commands for common database operations instead of handling setup, changes, recovery, and health checks manually.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/jansenanalytics/claudex/database
Any agent
npx skills add JansenAnalytics/claudex --skill database
Clone the repo
git clone --depth 1 https://github.com/JansenAnalytics/claudex

Made for: Claude Code, Codex.

Per session 24 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 451 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00024 $0.00451
Opus 5 $0.00012 $0.00226
Sonnet 5 $0.00005 $0.00090
Haiku 4.5 $0.00002 $0.00045

Measured yesterday against content hash 924031e9bf3c, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

database scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/database/SKILL.md · 59 lines

What it actually says

database

Manage PostgreSQL, SQLite, and Redis databases: create, migrate, backup, restore, query, optimize.

When to Use

  • Setting up new databases or tables
  • Running schema migrations
  • Creating and restoring backups
  • Debugging query performance
  • Managing database users and permissions
  • Health checking database instances

Scripts

Script Purpose Usage
backup.sh Backup/restore PostgreSQL or SQLite databases bash scripts/backup.sh backup|restore <type> <db> [file]
migrate.sh Run SQL migration files in order bash scripts/migrate.sh <db-url> <migrations-dir>
health-check.sh Check database connectivity and basic stats bash scripts/health-check.sh <type> <connection>
user-manager.sh Manage PostgreSQL users and permissions bash scripts/user-manager.sh create|grant|revoke|list <args>

References

File Contents
postgresql-cheatsheet.md Common PostgreSQL commands and patterns
sqlite-cheatsheet.md SQLite CLI and SQL reference
redis-cheatsheet.md Redis commands and data structures
backup-strategies.md Backup approaches for production databases

Examples

Backup a SQLite database

bash scripts/backup.sh backup sqlite /path/to/mydb.sqlite3

Run migrations

bash scripts/migrate.sh sqlite:///path/to/db.sqlite3 ./migrations/

Health check PostgreSQL

bash scripts/health-check.sh postgres "host=localhost dbname=myapp user=admin"
Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 59 lines · 24 tokens per session scan A 924031e9bf3c

Subscribe to this mod's changes

database is a skill published in the GitHub repository JansenAnalytics/claudex (5 stars, last pushed 2mo ago), licensed MIT. It adds 24 tokens to every session and 451 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

database-engineer

!cat skills/shared/protocols/ux-protocol.md 2>/dev/null || true !cat skills/shared/protocols/input-validation.md 2>/dev/null || true !cat skills/shared/protocols/tool-efficiency.md 2>/dev/null || true !cat .production-grade.yaml 2>/dev/null || echo "No config — using defaults" !cat .forgewright/codebase-context.md…

buiphucminhtam/forgewright · 45 tokens

db-migration

数据库迁移技能 - Schema检查、迁移脚本生成、漂移检测、索引优化.

chainlesschain/chainlesschain · 25 tokens

database-query

Generate, optimize, and explain SQL queries - supports SQLite, PostgreSQL, MySQL with schema introspection, migration generation, and query performance analysis.

chainlesschain/chainlesschain · 32 tokens

newsblur-cli

Manage your NewsBlur from the terminal. Read feeds, search stories, save and share articles, train intelligence classifiers, discover new feeds, and automate workflows with the NewsBlur CLI. Use when the user wants to interact with their NewsBlur account, check feeds, manage subscriptions, or build scripts around…

samuelclay/NewsBlur · 67 tokens

make-interfaces-feel-better

Design engineering principles for making interfaces feel polished. Use when building UI components, reviewing frontend code, implementing animations, hover states, shadows, borders, typography, micro-interactions, enter/exit animations, or any visual detail work. Triggers on UI polish, design details, "make it feel…

samuelclay/NewsBlur · 96 tokens

enferno-dev

Development skill for Enferno Flask framework. Use when implementing features, fixing bugs, or writing code for Enferno-based applications. This includes creating models, API endpoints, Vue.js frontend components, database operations, or any development task within the Enferno ecosystem. Triggers: creating blueprints…

level09/enferno · 82 tokens