worldcrafter-database-setup

Generate Prisma models, migrations, and RLS policies for WorldCrafter databases.

Updated Nov 9, 2025
One-click install
npx skills add https://github.com/hopeoverture/worldcrafter-v2 --skill worldcrafter-database-setup
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: worldcrafter-database-setup
Source: https://github.com/hopeoverture/worldcrafter-v2/tree/main/.claude/skills/worldcrafter-database-setup
Command: npx skills add https://github.com/hopeoverture/worldcrafter-v2 --skill worldcrafter-database-setup

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) and assets (resource) components.

What problem does it solve?

Manually setting up database tables, managing migrations, and configuring Row-Level Security (RLS) policies is complex and error-prone. This Skill automates these foundational tasks, ensuring data integrity and security from the start, allowing developers to focus on application logic rather than database boilerplate.

Core Features & Use Cases

  • Prisma Model Generation: Automatically create Prisma ORM models following WorldCrafter conventions, complete with standard fields and relationships.
  • Database Migrations: Generate and apply database migrations to safely evolve your schema, maintaining a clear history of changes.
  • Row-Level Security (RLS): Implement robust RLS policies to enforce fine-grained data access control directly at the database level, enhancing security.
  • Use Case: A developer needs to add a new "Quest" feature to WorldCrafter. This Skill can generate the Quest model in prisma/schema.prisma, create the necessary migration file, and set up RLS policies so users can only manage their own quests, all with minimal manual intervention.

Quick Start

Use the worldcrafter-database-setup skill to create a new "Quest" table with a title, description, and a foreign key to the "World" table.

Frequently Asked Questions about worldcrafter-database-setup

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

FAQPage Schema
How do I set up Prisma models and migrations for a new database table?

Prisma model generation creates ORM models following WorldCrafter conventions with standard fields (id, createdAt, updatedAt) and relationships. The Skill generates migration files to safely evolve your schema while maintaining a clear change history, eliminating manual boilerplate.

What is Row-Level Security and how do I configure RLS policies in PostgreSQL?

Row-Level Security enforces fine-grained data access control directly at the database level. This Skill generates and applies RLS policies automatically, ensuring users can only access their own data without implementing authorization logic in application code.

Can I automate database setup with Prisma and PostgreSQL for WorldCrafter features?

Yes. This Skill automates creating Prisma models, generating and applying migrations, configuring RLS policies, and syncing test databases across WorldCrafter features, reducing manual setup errors and accelerating feature development.

How do I manage schema changes and keep migration history organized?

Database migrations track and apply schema changes safely over time. This Skill supports both automated and manual migrations, maintaining a clear audit trail of structural changes and enabling rollback if needed.

Do I need to manually write RLS policies or can they be generated?

RLS policies can be generated and applied automatically. This Skill creates policies matching your schema and relationships, removing the need to write SQL access rules by hand while ensuring consistent security enforcement.