design-schema

design-schema is a skill for Claude Code from evgenii-studitskikh/Claude-Code-SaaS-Studio. It costs 37 tokens per session (573 once invoked), scanned A, original, MIT.

A database-design guide for PostgreSQL, the database system used by Supabase. It drafts tables, relationships, access rules, and a migration, which is a file that changes a database's structure.

In plain words
What is it for?
Use it to turn a product plan into Supabase tables, tenant-specific access rules, indexes, and an approved migration draft.
Why use it?
It helps prevent missing relationships, unsafe data access, and accidental access between different customers' data.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: model in frontmatter; names the AskUserQuestion tool.

Good fit Use it to turn a product plan into Supabase tables, tenant-specific access rules, indexes, and an approved migration draft.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/evgenii-studitskikh/claude-code-saas-studio/design-schema
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 evgenii-studitskikh/Claude-Code-SaaS-Studio --skill design-schema
Clone the repo
git clone --depth 1 https://github.com/evgenii-studitskikh/Claude-Code-SaaS-Studio

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 design-schema

README.md
[![agentmods](https://agentmods.dev/badge/skills/evgenii-studitskikh/claude-code-saas-studio/design-schema.svg)](https://agentmods.dev/skills/evgenii-studitskikh/claude-code-saas-studio/design-schema)
Your own site
<a href="https://agentmods.dev/skills/evgenii-studitskikh/claude-code-saas-studio/design-schema"><img src="https://agentmods.dev/badge/skills/evgenii-studitskikh/claude-code-saas-studio/design-schema.svg" alt="Measured on agentmods" height="20"></a>
Per session 37 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 573 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. 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.00037 $0.00573
Opus 5 $0.00018 $0.00287
Sonnet 5 $0.00007 $0.00115
Haiku 4.5 $0.00004 $0.00057

Measured 7d ago against content hash b7beec89cd50, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

design-schema 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 7d 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.

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.

.claude/skills/design-schema/SKILL.md · 23 lines

How it starts

The opening of the file, as written. The whole thing — 23 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Translate the architecture and PRD into a concrete Postgres schema with Row-Level Security policies, tenant isolation, and a ready-to-apply Supabase migration file. Non-autonomous: the full schema draft is presented and approved before any migration is applied.

Phases

  1. Load context — read docs/specs/architecture.md, docs/specs/prd.md, and any existing migration files under supabase/migrations/. If the architecture doc is missing, stop and direct to /design-architecture.
  2. Draft tables and relations — propose each table with columns, data types, primary keys, foreign keys, and indexes. Note which tables are tenant-scoped (include a tenant_id column referencing an organizations or tenants table). Present the entity-relation summary for the user's review.
  3. Design RLS policies — for every tenant-scoped table, write the RLS ENABLE ROW LEVEL SECURITY statement and at least a SELECT, INSERT, UPDATE, and DELETE policy using auth.uid() and tenant scoping. Explain each policy in plain language. Flag any table that is intentionally public-read or service-role-only.
  4. Review edge cases — check for: missing indexes on foreign keys, cascade-delete implications, enum vs. text trade-offs, and any table that stores PII (flag for encryption or masking consideration). Surface findings; get the user's decisions before locking the schema.
  5. Write migration draft — fill .claude/templates/data-model.md into docs/specs/data-model.md and write the migration SQL to supabase/migrations/{timestamp}_initial_schema.sql. Show both files for approval. Do NOT run supabase db push or any database command until the user explicitly approves. Honor the review intensity: under full, walk through each table and policy for sign-off; under lean, get a single confirmation before writing; under solo, proceed and summarize after.
  6. Apply (optional) — if the user approves application, run supabase db push and verify success. Report the output. Next step: point to /build-feature.

Read the full file on GitHub · 23 lines

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. 7d ago First seen · 23 lines · 37 tokens per session scan A b7beec89cd50

Subscribe to this mod's changes

design-schema is a skill published in the GitHub repository evgenii-studitskikh/Claude-Code-SaaS-Studio (1 stars, last pushed 2mo ago), licensed MIT. It adds 37 tokens to every session and 573 once invoked, about $0.0002 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