building-with-medusa

Apply standardized backend architecture patterns to Medusa modules, workflows, API routes, and module links.

Updated Mar 22, 2026
One-click install
npx skills add https://github.com/afterwork/arra-aif --skill building-with-medusa-afterwork
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: building-with-medusa
Source: https://github.com/afterwork/arra-aif/tree/main/.cursor/skills/building-with-medusa
Command: npx skills add https://github.com/afterwork/arra-aif --skill building-with-medusa-afterwork

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill provides a structured approach to planning and implementing Medusa backend features by codifying architectural patterns, best practices, and critical rules that extend beyond MCP docs.

Core Features & Use Cases

  • Patterns and guidelines across six categories: architecture, type safety, business logic placement, import and code organization, data access patterns, and file organization.
  • Practical checklists and guardrails for planning, implementation, and exploration of Medusa backend work, including modules, API routes, workflows, data models, and module links.
  • Real-world scenarios and guidelines to help teams align on structure, validation, and risk mitigation when building or extending Medusa backends.

Quick Start

Review the guide and start applying the documented patterns to your Medusa backend work.

Frequently Asked Questions about building-with-medusa

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
What are the best practices for Medusa backend architecture and module isolation?

Medusa backend architecture best practices enforce module isolation, workflow-centric design, and proper API route structure. Guidelines span six priority categories including type safety, business logic placement, data access patterns, and file organization to ensure scalable implementations.

How do I organize business logic placement in Medusa workflows and API routes?

Business logic placement in Medusa workflows requires isolating logic within workflows rather than API routes, following strict import and code organization rules. This maintains module isolation and aligns with Medusa's workflow-centric architecture.

When do I need module links in Medusa backend data models?

Module links are needed in Medusa backend data models when establishing relationships between isolated modules. Standardized patterns provide guardrails for safe implementation, ensuring data access respects module boundaries and maintains architectural integrity.

Does this Medusa backend skill support type safety and validation checklists?

Yes, the Medusa backend skill includes type safety and validation checklists as a core priority category. Practical guardrails cover planning, implementation, and exploration phases to help teams align on structure and mitigate risks.

What is the correct way to structure data access patterns in Medusa modules?

Correct data access patterns in Medusa modules require respecting module isolation and following standardized architectural rules. The skill provides critical rules and best practices for safe, scalable backend work that aligns with Medusa's workflow-centric approach.

Why does my Medusa workflow architecture break module isolation rules?

Medusa workflow architecture breaks module isolation when business logic leaks into API routes or imports cross module boundaries improperly. Applying standardized import organization and data access pattern rules restores architectural compliance.