# msw-setup > Configure MSW for API mocking in tests and Storybook. - Author: Adam Winick - Repository: sinelanguage/cursor-config-web - Version: 20260201223507 - Stars: 0 - Forks: 0 - Last Updated: 2026-02-06 - Source: https://github.com/sinelanguage/cursor-config-web - Web: https://mule.run/skillshub/@@sinelanguage/cursor-config-web~msw-setup:20260201223507 --- --- name: msw-setup description: Configure MSW for API mocking in tests and Storybook. disable-model-invocation: true --- # MSW Setup Add Mock Service Worker configuration for tests and stories. ## When to Use - Use this skill when you need deterministic API mocks. ## Inputs - API endpoints to mock - Target environments (tests, Storybook, dev) ## Instructions 1. Add MSW setup for tests. 2. Define request handlers with typed responses. 3. Document how to add new handlers. 4. Add examples for Storybook if relevant. ## Output - MSW configuration and example handlers.