db

db is a skill for Claude Code from Supersynergy/awesome-agentic-coding. It costs 39 tokens per session (536 once invoked), scanned A, original, MIT.

A command-line tool for working with PostgreSQL, SurrealDB, and SQLite databases. It detects database settings from common project files and runs queries.

In plain words
What is it for?
Use it to inspect tables, schemas, indexes, row counts, and small result sets in supported databases.
Why use it?
It gives developers one workflow for finding the database connection, exploring its structure, and querying data with limits.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: model in frontmatter.

Good fit Use it to inspect tables, schemas, indexes, row counts, and small result sets in supported databases.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/supersynergy/awesome-agentic-coding/db
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.

Any agent
npx skills add Supersynergy/awesome-agentic-coding --skill db
Clone the repo
git clone --depth 1 https://github.com/Supersynergy/awesome-agentic-coding

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for db

README.md
[![agentmods](https://agentmods.dev/badge/skills/supersynergy/awesome-agentic-coding/db/github.svg)](https://agentmods.dev/skills/supersynergy/awesome-agentic-coding/db)
Your own site
<a href="https://agentmods.dev/skills/supersynergy/awesome-agentic-coding/db"><img src="https://agentmods.dev/badge/skills/supersynergy/awesome-agentic-coding/db/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for db

Your own site · 80×15
<a href="https://agentmods.dev/skills/supersynergy/awesome-agentic-coding/db"><img src="https://agentmods.dev/badge/skills/supersynergy/awesome-agentic-coding/db.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 39 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 536 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00039 $0.00536
Opus 5.5 $0.00016 $0.00214
Sonnet 5.5 $0.00008 $0.00107
Haiku 4.5 $0.00004 $0.00054

Measured 1mo ago against content hash b33b5474f9f7, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

db scanned grade A with 1 finding 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 1mo ago.

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.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

curl -s http://localhost:8000/sql \
skills/db/SKILL.md · 65 lines

What it actually says

Database CLI Operations

Execute database operations for: $ARGUMENTS

Step 1: Detect Database

Check these files to find the database connection:

  • .env / .env.local for DATABASE_URL
  • docker-compose.yml for database services
  • drizzle.config.ts / prisma/schema.prisma for ORM config

Step 2: Execute Query

PostgreSQL

# Connect
psql "$DATABASE_URL" -c "YOUR QUERY"

# Exploration
psql "$DATABASE_URL" -c "\dt"                    # List tables
psql "$DATABASE_URL" -c "\d tablename"           # Describe table
psql "$DATABASE_URL" -c "\di"                    # List indexes

# Queries (always LIMIT!)
psql "$DATABASE_URL" -c "SELECT * FROM users LIMIT 10"
psql "$DATABASE_URL" -c "SELECT count(*) FROM users"

SurrealDB

# Via HTTP API (most reliable)
curl -s http://localhost:8000/sql \
  -H "Accept: application/json" \
  -H "NS: app" -H "DB: main" \
  -u "root:root" \
  --data "SELECT * FROM user LIMIT 10;"

# Via CLI
surreal sql --endpoint http://localhost:8000 \
  --namespace app --database main \
  --username root --password root \
  --query "INFO FOR DB;"

SQLite

sqlite3 path/to/db.sqlite ".tables"
sqlite3 path/to/db.sqlite ".schema tablename"
sqlite3 path/to/db.sqlite "SELECT * FROM users LIMIT 10"

Safety Rules

  • NEVER run DELETE, DROP, TRUNCATE, or ALTER without explicit user confirmation
  • Always add LIMIT to SELECT queries (default: 20)
  • Never expose passwords or connection strings in output
  • For writes, show the query first and ask before executing
  • Use READ-ONLY connections when just exploring (add ?sslmode=require&options=-c default_transaction_read_only=on for Postgres)
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. 1mo ago First seen · 65 lines · 39 tokens per session scan A b33b5474f9f7

Subscribe to this mod's changes

db is a skill published in the GitHub repository Supersynergy/awesome-agentic-coding (1 stars, last pushed 2mo ago), licensed MIT. It adds 39 tokens to every session and 536 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 1 finding (makes network calls). 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

optimize

Analyze and suggest performance improvements for code, queries, or systems.

FlorianBruniaux/claude-code-ultimate-guide · 15 tokens

database

Database design, query optimization, migrations, and indexing. Use when designing schemas, writing queries, or managing migrations.

xiaobei930/cc-best · 25 tokens

kotlin-exposed-patterns

JetBrains Exposed ORM patterns including DSL queries, DAO pattern, transactions, HikariCP connection pooling, Flyway migrations, and repository pattern.

hashgraph-online/awesome-codex-plugins · 36 tokens

postgres-idioms

PostgreSQL best practices — schema design, query performance, indexing, connection management, RLS, concurrency, monitoring, and migrations. Load when writing SQL, designing schemas, or optimizing PostgreSQL queries.

irahardianto/awesome-agv · 46 tokens

eval-hooks

Audit Claude Code and Codex hooks for validity, safety, and correctness across settings.json, hooks.json, config.toml, plugin, and skill or agent frontmatter hooks. Resolves each command, checks event names, handler types, matchers, exit-code and JSON decision strategy, and timeouts against each host's documented…

FlorianBruniaux/claude-code-ultimate-guide · 115 tokens

design-patterns

Detect, suggest, and evaluate GoF design patterns in TypeScript/JavaScript codebases. Use when refactoring code, applying singleton/factory/observer/strategy patterns, reviewing pattern quality, or finding stack-native alternatives for React, Angular, NestJS, and Vue.

FlorianBruniaux/claude-code-ultimate-guide · 59 tokens