idorgham/gateflow/database
Claude Code and agent skill by idorgham/gateflow
Trust tier 3
- community
Source check pending
Checking that the SKILL.md file is still in the repository.
Prisma schema, migrations, and query patterns for GateFlow. Use when creating/modifying models, writing queries, creating migrations, or debugging data issues.
Install
npx vskill@latest install idorgham/gateflow/databaseSKILL.md
The same SKILL.md was published earlier as idorgham/gateflow/database.
GateFlow Database
Stack
- DB: PostgreSQL 15+
- ORM: Prisma 5.x
- Schema:
packages/db/prisma/schema.prisma - Migrations:
packages/db/prisma/migrations/
Required Patterns
Multi-tenant (always)
Soft delete (always)
New model checklist
organizationId+@@index([organizationId])for tenant modelsdeletedAt DateTime?+@@index([deletedAt])for mutable modelscreatedAt,updatedAttimestamps@default(cuid())for ids
Migration Workflow
MCP: Prisma-Local
When Prisma-Local MCP is enabled, use its tools for:
- migrate-dev — Create and apply migration (LLM provides migration name)
- migrate-status — Check migration state
- Prisma-Studio — Open Prisma Studio via
prisma studio
Core Models
| Model | Purpose | |
|---|---|---|
| Organization | Multi-tenant root | |
| Project | Sub-grouping | |
| User | Auth, RBAC | |
| Gate | Access points | |
| QRCode | Access codes (HMAC signed) | |
| ScanLog | Immutable audit trail (scanUuid dedup) | |
| Unit | Residential units (Phase 2) |
Query Examples
Find many with org scope
Transaction
Aggregation
Performance
- Use
selectfor large result sets createManyfor bulk inserts- Add
@@indexon frequently queried fields - Connection pool in DATABASE_URL
Input Validation
Use Zod for API input; Prisma for DB constraints.
Reference: packages/db/prisma/schema.prisma, packages/db/prisma/seed.ts
Security
- Security scanPassed, 95 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryChecking.antigravity/skills/database/SKILL.md
Popularity
- 7-day trend score
- 5
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Grok Build (Cursor)
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/idorgham/gateflow/database)