A solid reference for MSW v2 that covers the essentials without the usual documentation bloat. You get 45 rules across setup, handler architecture, test integration, and response patterns, all prioritized by impact so you know what actually matters. The handler architecture section is especially useful for avoiding the common pitfall of dumping all your mocks in one file. It's built for AI agents but reads fine for humans who need to set up API mocking correctly the first time. Works best alongside testing skills like test-vitest since this deliberately skips general testing methodology.

skills.sh installs
897
GitHub stars
222
last updated
Aug 21, 2026

Install

$ npx -y skills add pproenca/dot-skills --skill msw --agent claude-code

Installs into .claude/skills of the current project.

Files

MSW Best Practices

Comprehensive API mocking guide for MSW v2 applications, designed for AI agents and LLMs. Contains 45 rules across 8 categories, prioritized by impact to guide automated refactoring and code generation.

When to Apply

Reference these guidelines when:

  • Setting up MSW for testing or development
  • Writing or organizing request handlers
  • Configuring test environments with MSW
  • Mocking REST or GraphQL APIs
  • Debugging handler matching issues
  • Testing error states and edge cases

Rule Categories by Priority

PriorityCategoryImpactPrefix
1Setup & InitializationCRITICALsetup-
2Handler ArchitectureCRITICALhandler-
3Test IntegrationHIGHtest-
4Response PatternsHIGHresponse-
5Request MatchingMEDIUM-HIGHmatch-
6GraphQL MockingMEDIUMgraphql-
7Advanced PatternsMEDIUMadvanced-
8Debugging & PerformanceLOWdebug-

Quick Reference

1. Setup & Initialization (CRITICAL)

Sponsors

Details

Repository
github.com/pproenca/dot-skills
Categories
Backend & APIs, Testing & QA, Documentation
First seen
Jun 3, 2026

More from pproenca/dot-skills

All 100
1ivan-magda avatarswift-security-expertivan-magda/swift-security-skillUse when working with iOS/macOS Keychain Services (SecItem queries, kSecClass, OSStatus errors), biometric authentication (LAContext, Face ID, Touch ID), Crypto875skills.sh installs
2secondsky avatarsapui5-clisecondsky/sap-skillsManages SAPUI5/OpenUI5 projects using the UI5 Tooling CLI (@ui5/cli). Use when initializing UI5 projects, configuring ui5.yaml or ui5-workspace.yaml files, buil872skills.sh installs
3circlefin avatarunify-balancecirclefin/skillsBuild unified cross-chain USDC balance management with Circle Unified Balance Kit SDK via App Kit (`@circle-fin/app-kit`) or standalone (`@circle-fin/unified-ba851skills.sh installs
4daymade avatarwindows-remote-desktop-connection-doctordaymade/claude-code-skillsDiagnose Windows App (Microsoft Remote Desktop / Azure Virtual Desktop / W365 / direct PC) connection issues on macOS. Analyze transport protocol selection (UDP843skills.sh installs
5nvidia avatarnemoclaw-user-configure-inferencenvidia/skillsConnects NemoClaw to a local inference server. Use when setting up Ollama, vLLM, TensorRT-LLM, NIM, or any OpenAI-compatible local model server with NemoClaw. T841skills.sh installs
6harperfast avatarharper-best-practicesharperfast/skillsBest practices for building Harper applications, covering schema definition, automatic APIs, authentication, custom resources, and data handling. Triggers on ta819skills.sh installs