backend-dev-guidelines
Skill10k starsChanged 5 months agoMITView on GitHub
Comprehensive backend development guide for Node.js/Express/TypeScript microservices. Use when creating routes, controllers, services, repositories, middleware, or working with Express APIs, Prisma database access, Sentry error tracking, Zod validation, unifiedConfig, dependency injection, or async patterns. Covers layered architecture (routes → controllers → services → repositories), BaseController pattern, error handling, performance monitoring, testing strategies, and migration from legacy patterns.
- Reads credentials
10 other projects use a version of this, 2 of them edited.
Trending
Quiet since September.about the whole repository
Most recently taken up by
- sabahattink/antigravity-fullstack-hqtheir own version, first seen Sep 20, 2026
- TheHiddenDeveloper/jarvis-skillstheir own version, first seen Aug 19, 2026
- jgamaraalv/delivery-looptheir own version, first seen Jul 4, 2026
- litefuse/litefusetheir own version, first seen Jun 16, 2026
- ai4brands-design/claude-skillstheir own version, first seen Mar 22, 2026
- liuchiawei/agent-skillstheir own version, first seen Feb 17, 2026
Who's talking about diet103/claude-code-infrastructure-showcase
- opendatahub-io/ai-helpers“[Idea] Having issues with Claude Code... Maybe it's a skill issue!”GitHub · Jan 9, 2026 · 2 reactions
- obra/superpowers“Finding new things to add to Superpowers based on other repos”GitHub · Dec 10, 2025 · 1 reactions
- vishalsachdev/claude-skills“Add Claude Code Infrastructure Showcase skill”GitHub · Nov 6, 2025 · 1 reactions
- sudosubin/agents.nix“agent-skills.github.diet103.claude-code-infrastructure-showcase: init at 0-unstable-2026-07-12”GitHub · Sep 26, 2026
- xiaolai/nlpm“Audit candidate: diet103/claude-code-infrastructure-showcase”GitHub · Apr 6, 2026
The biggest 5 of 21 mentions linking to the repository that our crawl found. Each line is their own headline.
See all 21
Talked about on GitHub and Bluesky (21 times).
On GitHub · 20
- Jan 9, 2026[Idea] Having issues with Claude Code... Maybe it's a skill issue! — opendatahub-io/ai-helpers2 reactions · 3 comments
- Dec 10, 2025Finding new things to add to Superpowers based on other repos — obra/superpowers1 reaction · 1 comment
- Nov 6, 2025Add Claude Code Infrastructure Showcase skill — vishalsachdev/claude-skills1 reaction
- Sep 26, 2026agent-skills.github.diet103.claude-code-infrastructure-showcase: init at 0-unstable-2026-07-12 — sudosubin/agents.nix0 reactions
- Apr 6, 2026Audit candidate: diet103/claude-code-infrastructure-showcase — xiaolai/nlpm0 reactions · 2 comments
15 more on GitHub
- Feb 22, 2026Interesting agent infra/framework — thaitype/chief0 reactions
- Jan 7, 2026在 Claude Code 之上? — Pines-Cheng/blog0 reactions
- Jan 6, 2026New plugins: 5 skills from skills (safe risk) — aiskillstore/marketplace0 reactions
- Nov 9, 2025Add Claude Code infrastructure components for enhanced development wo… — kcns008/cluster-code0 reactions
- Nov 9, 2025perf: enhance skill auto-activation with hooks — mrgoonie/claudekit-cli0 reactions · 1 comment
- Nov 6, 2025Add resource: Claude Code Infrastructure Showcase — hesreallyhim/awesome-claude-code0 reactions
- Nov 6, 2025[Resource]: Claude Code Infrastructure Showcase — hesreallyhim/awesome-claude-code0 reactions · 3 comments
- Nov 6, 2025Game Changer:Skills + Hooks 实验性添加? — UfoMiao/zcf0 reactions · 2 comments
- Nov 3, 2025Add Claude agent configurations to .claude/agents folder — limbo111111/mdk-predator0 reactions · 2 comments
- Nov 3, 2025Revert "[WIP] create folder .claude and download the files in the fo… — limbo111111/mdk-predator0 reactions · 2 comments
- Nov 3, 2025[WIP] create folder .claude and download the files in the folder. from https://github.com/diet103/claude-code-infrastructure-showcase/tree/main/.claude/agents — limbo111111/mdk-predator0 reactions
- Nov 3, 2025Enhance hook-triggered orchestration with pattern-based detection — akaszubski/autonomous-dev0 reactions · 1 comment
- Nov 1, 2025Add prominent acknowledgement to original creator diet103 — weirdgme/Claude-code-infrastructure-showcase0 reactions
- Oct 31, 2025Can you make a guide for setup of opencode like this reddit post did for claude code? — anomalyco/opencode0 reactions · 4 comments
- Oct 31, 2025Check out diet103's Claude Code infra — PaulRBerg/dot-claude0 reactions
On Bluesky · 1
- Nov 12, 20251. Claude Code Infrastructure Showcase A reference library showcasing production-tested infrastructure for Claude Code, complete with skill… — @devshorts.insays it tested it0 likes and reposts · 1 reply
Used with
Projects with it also use tailwind-patterns.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
xfstudioSkilltailwind-patterns
Tailwind CSS v4 principles. CSS-first configuration, container queries, modern patterns, design token architecture.
Also in 3 projects that use this
Other versions10 projects use a version of this.
Word for word · 0
None found.
Edited · 2
- serithemage/claude-code-demo★ 489% same
- weirdgme/Claude-code-infrastructure-showcase★ 497% same
Wrote their own version · 8
- litefuse/litefuse★ 101same name
- sabahattink/antigravity-fullstack-hq★ 30same name
- xfstudio/skills★ 9same name
- DojoCodingLabs/claude-code-waypoint★ 4same name
- jgamaraalv/delivery-loop★ 4same name
- ai4brands-design/claude-skills★ 2same name
- liuchiawei/agent-skills★ 2same name
- TheHiddenDeveloper/jarvis-skills★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository8 other files it gives its agents.
- backend-dev-guidelinesSkill
- error-trackingSkill
- frontend-dev-guidelinesSkill
- skill-developerSkill
- source-command-verify-setupSkill
- error-trackingSkill
- frontend-dev-guidelinesSkill
- skill-developerSkill
The file
We split this skill into the rules it gives an agent
1 rule. 0 are common, 1 is distinctive, and 0 are very specific to this project.
0
Common
Most of the 10 edited versions we read keep these.
1
Distinctive
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 296
database-verification: - Verify column names and schema consistency
“Common” is measured: kept by at least 6 in 10 of the 10 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Backend Development Guidelines
Purpose
Establish consistency and best practices across backend services using modern Node.js/Express/TypeScript patterns.
Written for Node.js/Express/TypeScript with Prisma and Sentry. Different stack? Adapt the architectural principles - see CLAUDE_INTEGRATION_GUIDE.md in the repo root.
When to Use This Skill
Automatically activates when working on:
- Creating or modifying routes, endpoints, APIs
- Building controllers, services, repositories
- Implementing middleware (auth, validation, error handling)
- Database operations with Prisma
- Error tracking with Sentry
- Input validation with Zod
- Configuration management
- Backend testing and refactoring
Quick Start
New Backend Feature Checklist
- Route: Clean definition, delegate to controller
- Controller: Extend BaseController
- Service: Business logic with DI
- Repository: Database access (if complex)
- Validation: Zod schema
- Sentry: Error tracking
- Tests: Unit + integration tests
- Config: Use unifiedConfig
New Microservice Checklist
- Directory structure (see architecture-overview.md)
- instrument.ts for Sentry
- unifiedConfig setup
- BaseController class
- Middleware stack
- Error boundary
- Testing framework
Architecture Overview
Layered Architecture
HTTP Request
↓
Routes (routing only)
↓
Controllers (request handling)
↓
Services (business logic)
↓
Repositories (data access)
↓
Database (Prisma)Key Principle: Each layer has ONE responsibility.
See architecture-overview.md for complete details.
Directory Structure
service/src/
├── config/ # UnifiedConfig
├── controllers/ # Request handlers
├── services/ # Business logic
├── repositories/ # Data access
├── routes/ # Route definitions
├── middleware/ # Express middleware
├── types/ # TypeScript types
├── validators/ # Zod schemas
├── utils/ # Utilities
├── tests/ # Tests
├── instrument.ts # Sentry (FIRST IMPORT)
├── app.ts # Express setup
└── server.ts # HTTP serverNaming Conventions:
- Controllers:
PascalCase-UserController.ts - Services:
camelCase-userService.ts - Routes:
camelCase + Routes-userRoutes.ts - Repositories:
PascalCase + Repository-UserRepository.ts
Core Principles (7 Key Rules)
1. Routes Only Route, Controllers Control
// ❌ NEVER: Business logic in routes
router.post('/submit', async (req, res) => {
// 200 lines of logic
});
// ✅ ALWAYS: Delegate to controller
router.post('/submit', (req, res) => controller.submit(req, res));2. All Controllers Extend BaseController
export class UserController extends BaseController {
async getUser(req: Request, res: Response): Promise<void> {
try {
const user = await this.userService.findById(req.params.id);
this.handleSuccess(res, user);
} catch (error) {
this.handleError(error, res, 'getUser');
}
}
}3. All Errors to Sentry
try {
await operation();
} catch (error) {
Sentry.captureException(error);
throw error;
}4. Use unifiedConfig, NEVER process.env
// ❌ NEVER
const timeout = process.env.TIMEOUT_MS;
// ✅ ALWAYS
import { config } from './config/unifiedConfig';
const timeout = config.timeouts.default;5. Validate All Input with Zod
const schema = z.object({ email: z.string().email() });
const validated = schema.parse(req.body);6. Use Repository Pattern for Data Access
// Service → Repository → Database
const users = await userRepository.findActive();7. Comprehensive Testing Required
describe('UserService', () => {
it('should create user', async () => {
expect(user).toBeDefined();
});
});Common Imports
// Express
import express, { Request, Response, NextFunction, Router } from 'express';
// Validation
import { z } from 'zod';
// Database
import { PrismaClient } from '@prisma/client';
import type { Prisma } from '@prisma/client';
// Sentry
import * as Sentry from '@sentry/node';
// Config
import { config } from './config/unifiedConfig';
// Middleware
import { SSOMiddlewareClient } from './middleware/SSOMiddleware';
import { asyncErrorWrapper } from './middleware/errorBoundary';Quick Reference
HTTP Status Codes
| Code | Use Case |
| 200 | Success |
| 201 | Created |
| 400 | Bad Request |
| 401 | Unauthorized |
| 403 | Forbidden |
| 404 | Not Found |
| 500 | Server Error |
Service Templates
Blog API (✅ Mature) - Use as template for REST APIs Auth Service (✅ Mature) - Use as template for authentication patterns
Anti-Patterns to Avoid
❌ Business logic in routes ❌ Direct process.env usage ❌ Missing error handling ❌ No input validation ❌ Direct Prisma everywhere ❌ console.log instead of Sentry
Navigation Guide
| Need to... | Read this |
| Understand architecture | architecture-overview.md |
| Create routes/controllers | routing-and-controllers.md |
| Organize business logic | services-and-repositories.md |
| Validate input | validation-patterns.md |
| Add error tracking | sentry-and-monitoring.md |
| Create middleware | middleware-guide.md |
| Database access | database-patterns.md |
| Manage config | configuration.md |
| Handle async/errors | async-and-errors.md |
| Write tests | testing-guide.md |
| See examples | complete-examples.md |
Resource Files
architecture-overview.md
Layered architecture, request lifecycle, separation of concerns
routing-and-controllers.md
Route definitions, BaseController, error handling, examples
services-and-repositories.md
Service patterns, DI, repository pattern, caching
validation-patterns.md
Zod schemas, validation, DTO pattern
sentry-and-monitoring.md
Sentry init, error capture, performance monitoring
middleware-guide.md
Auth, audit, error boundaries, AsyncLocalStorage
database-patterns.md
PrismaService, repositories, transactions, optimization
configuration.md
UnifiedConfig, environment configs, secrets
async-and-errors.md
Async patterns, custom errors, asyncErrorWrapper
testing-guide.md
Unit/integration tests, mocking, coverage
complete-examples.md
Full examples, refactoring guide
Related Skills
- database-verification - Verify column names and schema consistency
- error-tracking - Sentry integration patterns
- skill-developer - Meta-skill for creating and managing skills
Skill Status: COMPLETE ✅ Line Count: < 500 ✅ Progressive Disclosure: 11 resource files ✅
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
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.

