ywc-api Cursor Rules β€” Cursor Rules | Neura Market
    Neura MarketNeura Market/Cursor
    ChatGPTChatGPTClaudeClaudeGeminiGeminiCursorCursorGrokGrokPerplexityPerplexityDeepSeekDeepSeek
    CoPilotCoPilotStable DiffusionStable DiffusionMidjourneyMidjourney
    View All Directories
    OverviewRulesPromptsMCPsAgentsBlogVideosGuidesCoursesCommunityExtensionsTrendingGenerate
    CursorRulesywc-api Cursor Rules
    Back to Rules
    Frontend

    ywc-api Cursor Rules

    musudik April 15, 2026
    0 copies 0 downloads

    Use this prompt in Cursor to bootstrap the code:

    Rule Content
    
    ---
    
    ## 🧠 Cursor AI Prompt
    
    Use this prompt in Cursor to bootstrap the code:
    
    ---
    
    **Prompt:**
    
    ```txt
    Create an Express.js REST API backend with TypeScript for a Financial Forms app. 
    
    - Database: PostgreSQL (use `pg` package, no Prisma or ORM)
    - Structure: Use `config`, `models`, `routes`, `controllers`, and `services` folders.
    - Load environment variables via `.env` (PORT, DB_USER, DB_PASSWORD, etc.).
    - Use UUIDs for primary keys like `personalId`, `employmentId`.
    - Define TypeScript interfaces for:
      - PersonalDetails (with applicantType, salutation, etc.)
      - FamilyDetails (children[], etc.)
      - EmploymentDetails, IncomeDetails, ExpensesDetails
      - Assets[], Liabilities[]
    - Write SQL queries in service files.
    - Controllers should handle validation, call services, and return JSON responses.
    - Define routes in `src/routes/` and mount in `src/index.ts`.
    - Use express.json() and cors middlewares.
    - Provide example route handlers for POST `/api/personal-details` and GET `/api/employment/:id`.
    - Generate a `.cursorules` file to enforce this structure.
    - Output all code files under `src/`.
    
    This project is meant to serve a frontend React/Vite app that captures client form data and exports PDFs.
    
    
    βœ… Seed Data Strategy
    You'll typically have a seeder.ts script that:
    
    Connects to your PostgreSQL database
    
    Inserts base roles
    
    Inserts initial admin and coach users
    
    (Optionally) hashes passwords using bcrypt
    
    πŸ“¦ Database Tables Required
    You’ll need at least the following tables:
    
    roles
    users
    user_roles (many-to-many, if users can have multiple roles)
    permissions (if you want normalized permission tracking)
    forms (if listUserForms etc. are already functional)
    
    πŸ—‚οΈ Seed Data Script Plan
    Create a script: src/seed/seeder.ts
    
    πŸ‘‡ Here’s the seed data content:
    πŸ“Œ Roles Table
    Role Name	Description	Permissions
    ADMIN	Administrator with full access	{MANAGE_USERS,CREATE_COACHES,MANAGE_ROLES,MANAGE_CLIENTS,MANAGE_COACHES,MANAGE_CONTENT,VIEW_REPORTS}
    COACH	Financial coach who manages clients	{CREATE_CLIENTS,MANAGE_OWN_CLIENTS,VIEW_CLIENT_DATA,CREATE_REPORTS}
    CLIENT	End user of the platform	{VIEW_OWN_DATA,UPDATE_PROFILE,REQUEST_SERVICES}
    GUEST	Unregistered or limited access user	{VIEW_PUBLIC_CONTENT}
    
    
    πŸ› οΈ User Services
    Below is a breakdown of services by role:
    
    πŸ” Admin Services
    Service	Description
    createUser()	Create ADMIN / COACH / CLIENT
    activateUser()	Enable account
    deactivateUser()	Disable account
    listUserByType()	Filter users by role
    resetPassword()	Reset user password
    listUserForms()	Get list of user forms (for COACH / CLIENT)
    
    πŸ§‘β€πŸ« Coach Services
    Service	Description
    createUser()	Create CLIENT
    activateUser()	Activate CLIENT
    deactivateUser()	Deactivate CLIENT
    listUsers()	List all managed clients
    resetPassword()	Reset password of a CLIENT
    listUserForms()	Get all forms for a specific CLIENT
    downloadForm()	Download a form by formId
    deleteForm()	Delete a form by formId
    
    πŸ‘€ Client Services
    Service	Description
    updateUser()	Update their own profile
    listForms()	List their submitted forms
    updateForm(FORM-ID)	Update specific form
    downloadForm(FORM-ID)	Download form
    listDocumentsByForm()	View documents for a form
    updateDocumentsByForm()	Add/update documents for a form

    Tags

    reacttypescriptprisma

    Comments

    More Rules

    View all
    Web Development

    Next.js 15 + TypeScript Cursor Rules

    Comprehensive .cursorrules file for Next.js 15 App Router projects with TypeScript, enforcing server components by default, proper use of "use client" directive, and App Router conventions.

    C
    Community
    Backend Development

    Python FastAPI Best Practices Rules

    Cursor rules for Python FastAPI projects enforcing async patterns, Pydantic v2 models, dependency injection, and proper error handling.

    C
    Community
    Frontend Development

    React + TypeScript Component Rules

    Rules for consistent React component development with TypeScript interfaces, proper hook patterns, and component composition.

    C
    Community
    AI/ML

    Cursor Agent Mode Configuration

    Rules optimizing Cursor Agent mode behavior including multi-file editing context, session management, and autonomous task completion patterns.

    C
    Cursor Team
    Frontend Development

    Tailwind CSS + shadcn/ui Rules

    Cursor rules for projects using Tailwind CSS with shadcn/ui component library, enforcing consistent utility class usage and component patterns.

    C
    Community
    Backend Development

    Go Backend Service Rules

    Rules for Go backend services enforcing idiomatic Go patterns, proper error handling, and clean architecture conventions.

    C
    Community

    Stay up to date

    Get the latest Cursor prompts, rules, and resources delivered to your inbox weekly.

    Neura Market LogoNeura Market

    Discover the best AI prompts, plugins, and resources for Cursor and more.

    Content Types

    • Rules
    • Prompts
    • MCPs
    • Agents
    • Guides

    Platforms

    • ChatGPT Directory
    • Claude Directory
    • Gemini Directory
    • Cursor Directory
    • Grok Directory
    • Perplexity Directory
    • DeepSeek Directory
    • CoPilot Directory
    • Stable Diffusion Directory
    • Midjourney Directory
    • All Directories

    Resources

    • Blog
    • Documentation
    • Help Center
    • Marketplace

    Legal

    • Privacy Policy
    • Terms of Service

    Β© 2026 Neura Market. All rights reserved.

    |

    Not affiliated with any AI platform vendors.