agentleFS
Poorgramer-ZackPoorgramer-Zack/dart-expert-skills/skills/serverpod/SKILL.md

developing-serverpod-backend

Skill7 starsChanged 8 months agoMITView on GitHub

Develops full-stack Dart backends using the Serverpod framework with PostgreSQL, Redis, and Docker. Use when building type-safe API endpoints, defining YAML data models, configuring Serverpod auth, writing server-side tests, running database migrations, deploying to Docker/AWS/GCP, or creating database-less servers for stateless proxy/BFF endpoints.

The file

We split this skill into the rules it gives an agent

2 rules. About 0 are common, 0 are distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈0

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Use the serverpod_auth module for token-based authentication.

    line 38
  2. Very specific:

    Use docker-compose to orchestrate local and production environments.

    line 49

≈ “Common” is an estimate: at least 1 in 5 of the 408,460 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Serverpod Architecture & Development Guide

Overview

Serverpod splits projects into modules: server, client, and (fullstack template) <name>_flutter. Models defined in .spy.yaml files generate type-safe Dart classes and database migrations via serverpod generate.


Process

High-Level Workflow

Phase 1: Research & Modeling

1.1 Understand Project Structure

Serverpod separates code into server and client modules (the fullstack template adds <name>_flutter). Endpoint logic lives in server; generated client code goes into client.

1.2 Define Data Models

Define database models using .spy.yaml files, then run serverpod generate to produce Dart classes and database migrations. Use explicit foreign key mappings for relational tables.

  • Core Architecture & Models Guide - YAML model definitions, project structure, and relationship mapping.

Phase 2: Implementation

2.1 Develop Endpoints

Implement business logic inside endpoint classes. Use session parameters for authentication context, built-in caching, and native JSON serialization.

  • Endpoints & Database Guide - Typed ORM queries, transactions, and API endpoint patterns.

2.2 Authentication & Caching

Use the serverpod_auth module for token-based authentication. Configure Redis for caching to reduce repeated database queries.

  • Authentication & Caching Guide - serverpod_auth setup, endpoint protection, and Redis caching.

2.3 Database-less Backends

Serverpod 4 has no separate Mini variant. For stateless proxy/BFF endpoints, create a server without a database: serverpod create <name> --template server --no-database --no-redis --no-auth.


Phase 3: Deployment

3.1 Docker & Production

Use docker-compose to orchestrate local and production environments. Configure environment variables for credentials and connection strings.

  • Deployment & Docker Guide - Production Dockerfiles, AWS/GCP deployment, environment configuration.

Reference Files

Documentation Library

Core Framework (Load First)

  • Serverpod Overview - Setup, project structure, and architecture decisions.

Schema and Logic (Load During Phase 1/2)

  • Core Architecture & Models Guide - YAML models, database schema, directory structure.
  • Endpoints & Database Guide - ORM, typed queries, API endpoints.

Security, Scaling & Testing (Load During Phase 2/3)

  • Authentication & Caching Guide - serverpod_auth, endpoint protection, Redis caching.
  • Deployment & Docker Guide - AWS/GCP, Docker, environment management.
  • Testing Guide - Isolated database testing, endpoint simulation, auto-generated test utilities.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.