docs: rename Architectural Modules to Infrastructure Modules (#12212)

* docs: rename Architectural Modules to Infrastructure Modules

* generate again
This commit is contained in:
Shahed Nasser
2025-04-17 13:20:43 +03:00
committed by GitHub
parent 8618e6ee38
commit eb73bdb478
149 changed files with 12165 additions and 12145 deletions
@@ -461,7 +461,7 @@ tags:
You can upload public files, such as product images, or private files, such as CSV files used to import products.
externalDocs:
description: Check out available file module providers.
url: https://docs.medusajs.com/resources/architectural-modules/file
url: https://docs.medusajs.com/resources/infrastructure-modules/file
- name: Users
description: |
A user is an admin user that can authenticate and perform functionalities as an admin user.
@@ -481,7 +481,7 @@ tags:
Depending on the workflow engine you use, executions may only be retained for a short while, or only until the Medusa application is restarted.
externalDocs:
description: Check out available Workflow Engine Modules
url: https://docs.medusajs.com/resources/architectural-modules/workflow-engine
url: https://docs.medusajs.com/resources/infrastructure-modules/workflow-engine
paths:
/admin/api-keys:
get:
@@ -50279,7 +50279,7 @@ paths:
description: |
Generate a reset password token for an admin user. This API route doesn't reset the admin's password or send them the reset instructions in a notification.
Instead, This API route emits the `auth.password_reset` event, passing it the token as a payload. You can listen to that event in a subscriber as explained in [this guide](https://docs.medusajs.com/resources/commerce-modules/auth/reset-password), then send the user a notification. The notification is sent using a [Notification Module Provider](https://docs.medusajs.com/resources/architectural-modules/notification), and it should have the URL to reset the password in the Medusa Admin dashboard, such as `http://localhost:9000/app/reset-password?token=123`.
Instead, This API route emits the `auth.password_reset` event, passing it the token as a payload. You can listen to that event in a subscriber as explained in [this guide](https://docs.medusajs.com/resources/commerce-modules/auth/reset-password), then send the user a notification. The notification is sent using a [Notification Module Provider](https://docs.medusajs.com/resources/infrastructure-modules/notification), and it should have the URL to reset the password in the Medusa Admin dashboard, such as `http://localhost:9000/app/reset-password?token=123`.
Use the generated token to update the user's password using the [Reset Password API route](https://docs.medusajs.com/api/admin#auth_postactor_typeauth_providerupdate).
@@ -610,7 +610,7 @@ tags:
such as CSV files used to import products.
externalDocs:
description: Check out available file module providers.
url: https://docs.medusajs.com/resources/architectural-modules/file
url: https://docs.medusajs.com/resources/infrastructure-modules/file
- name: Users
description: >
A user is an admin user that can authenticate and perform functionalities
@@ -638,7 +638,7 @@ tags:
externalDocs:
description: Check out available Workflow Engine Modules
url: >-
https://docs.medusajs.com/resources/architectural-modules/workflow-engine
https://docs.medusajs.com/resources/infrastructure-modules/workflow-engine
paths:
/admin/api-keys:
$ref: paths/admin_api-keys.yaml
@@ -14,7 +14,7 @@ post:
guide](https://docs.medusajs.com/resources/commerce-modules/auth/reset-password),
then send the user a notification. The notification is sent using a
[Notification Module
Provider](https://docs.medusajs.com/resources/architectural-modules/notification),
Provider](https://docs.medusajs.com/resources/infrastructure-modules/notification),
and it should have the URL to reset the password in the Medusa Admin
dashboard, such as `http://localhost:9000/app/reset-password?token=123`.
@@ -447,7 +447,7 @@ paths:
description: |
Generate a reset password token for a customer. This API route doesn't reset the customer password or send them the reset instructions in a notification.
Instead, This API route emits the `auth.password_reset` event, passing it the token as a payload. You can listen to that event in a subscriber as explained in [this guide](https://docs.medusajs.com/resources/commerce-modules/auth/reset-password), then send the customer a notification. The notification is sent using a [Notification Module Provider](https://docs.medusajs.com/resources/architectural-modules/notification), and it should have a URL that accepts a `token` query parameter, allowing the customer to reset their password from the storefront.
Instead, This API route emits the `auth.password_reset` event, passing it the token as a payload. You can listen to that event in a subscriber as explained in [this guide](https://docs.medusajs.com/resources/commerce-modules/auth/reset-password), then send the customer a notification. The notification is sent using a [Notification Module Provider](https://docs.medusajs.com/resources/infrastructure-modules/notification), and it should have a URL that accepts a `token` query parameter, allowing the customer to reset their password from the storefront.
Use the generated token to update the customer's password using the [Reset Password API route](https://docs.medusajs.com/api/store#auth_postactor_typeauth_providerupdate).
@@ -13,7 +13,7 @@ post:
guide](https://docs.medusajs.com/resources/commerce-modules/auth/reset-password),
then send the customer a notification. The notification is sent using a
[Notification Module
Provider](https://docs.medusajs.com/resources/architectural-modules/notification),
Provider](https://docs.medusajs.com/resources/infrastructure-modules/notification),
and it should have a URL that accepts a `token` query parameter, allowing
the customer to reset their password from the storefront.
@@ -636,7 +636,7 @@ The value of this configuration is prepended to `sess:`. For example, if you set
<Note>
This configuration is not used for modules that also connect to Redis, such as the [Redis Cache Module](!resources!/architectural-modules/cache/redis).
This configuration is not used for modules that also connect to Redis, such as the [Redis Cache Module](!resources!/infrastructure-modules/cache/redis).
</Note>
@@ -656,7 +656,7 @@ module.exports = defineConfig({
The `projectConfig.redisUrl` configuration specifies the connection URL to Redis to store the Medusa server session. When specified, the Medusa server uses Redis to store the session data. Otherwie, the session data is stored in-memory.
This configuration is not used for modules that also connect to Redis, such as the [Redis Cache Module](!resources!/architectural-modules/cache/redis). You'll have to configure the Redis connection for those modules separately.
This configuration is not used for modules that also connect to Redis, such as the [Redis Cache Module](!resources!/infrastructure-modules/cache/redis). You'll have to configure the Redis connection for those modules separately.
<Note>
@@ -699,7 +699,7 @@ The `projectConfig.sessionOptions` configuration defines additional options to p
<Note>
This configuration is not used for modules that also connect to Redis, such as the [Redis Cache Module](!resources!/architectural-modules/cache/redis).
This configuration is not used for modules that also connect to Redis, such as the [Redis Cache Module](!resources!/infrastructure-modules/cache/redis).
</Note>
@@ -895,7 +895,7 @@ module.exports = defineConfig({
## Module Configurations (`modules`)
The `modules` configuration allows you to register and configure the [modules](../../fundamentals/modules/page.mdx) registered in the Medusa application. Medusa's commerce and architectural modules are configured by default. So, you only need to pass your custom modules, or override the default configurations of the existing modules.
The `modules` configuration allows you to register and configure the [modules](../../fundamentals/modules/page.mdx) registered in the Medusa application. Medusa's commerce and Infrastructure Modules are configured by default. So, you only need to pass your custom modules, or override the default configurations of the existing modules.
`modules` is an array of objects for the modules to register. Each object has the following properties:
@@ -8,7 +8,7 @@ export const metadata = {
In this chapter, you'll learn how to define a module link between a brand defined in the [custom Brand Module](../../custom-features/module/page.mdx), and a product defined in the [Product Module](!resources!/commerce-modules/product) that's available in your Medusa application out-of-the-box.
Modules are [isolated](../../../fundamentals/modules/isolation/page.mdx) from other resources, ensuring that they're integrated into the Medusa application without side effects. However, you may need to associate data models of different modules, or you're trying to extend data models from commerce modules with custom properties. To do that, you define module links.
Modules are [isolated](../../../fundamentals/modules/isolation/page.mdx) from other resources, ensuring that they're integrated into the Medusa application without side effects. However, you may need to associate data models of different modules, or you're trying to extend data models from Commerce Modules with custom properties. To do that, you define module links.
A module link forms an association between two data models of different modules while maintaining module isolation. You can then manage and query linked records of the data models using Medusa's Modules SDK.
@@ -12,7 +12,7 @@ The next chapters will cover each of these concepts in depth, with the different
The following guides and references are useful for your development journey:
3. [Commerce Modules](!resources!/commerce-modules): Browse the list of commerce modules in Medusa and their references to learn how to use them.
3. [Commerce Modules](!resources!/commerce-modules): Browse the list of Commerce Modules in Medusa and their references to learn how to use them.
1. [Service Factory Reference](!resources!/service-factory-reference): Learn about the methods generated by `MedusaService` with examples.
2. [Workflows Reference](!resources!/medusa-workflows-reference): Browse the list of core workflows and their hooks that are useful for your customizations.
4. [Admin Injection Zones](!resources!/admin-widget-injection-zones): Browse the injection zones in the Medusa Admin to learn where you can inject widgets.
@@ -128,11 +128,11 @@ By default, your Medusa application uses modules and providers useful for develo
Its highly recommended to instead use modules and providers suitable for production, including:
- [Redis Cache Module](!resources!/architectural-modules/cache/redis)
- [Redis Event Bus Module](!resources!/architectural-modules/event/redis)
- [Workflow Engine Redis Module](!resources!/architectural-modules/workflow-engine/redis)
- [S3 File Module Provider](!resources!/architectural-modules/file/s3) (or other file module providers production-ready).
- [SendGrid Notification Module Provider](!resources!/architectural-modules/notification/sendgrid) (or other notification module providers production-ready).
- [Redis Cache Module](!resources!/infrastructure-modules/cache/redis)
- [Redis Event Bus Module](!resources!/infrastructure-modules/event/redis)
- [Workflow Engine Redis Module](!resources!/infrastructure-modules/workflow-engine/redis)
- [S3 File Module Provider](!resources!/infrastructure-modules/file/s3) (or other file module providers production-ready).
- [SendGrid Notification Module Provider](!resources!/infrastructure-modules/notification/sendgrid) (or other notification module providers production-ready).
Then, add these modules in `medusa-config.ts`:
@@ -168,7 +168,7 @@ module.exports = defineConfig({
<Note title="Tip">
Check out the [Integrations](!resources!/integrations) and [Architectural Modules](!resources!/architectural-modules) documentation for other modules and providers to use.
Check out the [Integrations](!resources!/integrations) and [Infrastructure Modules](!resources!/infrastructure-modules) documentation for other modules and providers to use.
</Note>
@@ -217,7 +217,7 @@ Where:
- Set the PostgreSQL database's connection URL as the value of `DATABASE_URL`
- Set the Redis database's connection URL as the value of `REDIS_URL`.
Feel free to add any other relevant environment variables, such as for integrations and architectural modules. If you're using environment variables in your admin customizations, make sure to set them as well, as they're inlined during the build process.
Feel free to add any other relevant environment variables, such as for integrations and Infrastructure Modules. If you're using environment variables in your admin customizations, make sure to set them as well, as they're inlined during the build process.
### Set Start Command
@@ -296,7 +296,7 @@ Where:
- Set the PostgreSQL database's connection URL as the value of `DATABASE_URL`
- Set the Redis database's connection URL as the value of `REDIS_URL`.
Feel free to add any other relevant environment variables, such as for integrations and architectural modules.
Feel free to add any other relevant environment variables, such as for integrations and Infrastructure Modules.
### Set Start Command
@@ -12,7 +12,7 @@ In this chapter, you'll learn how to pass additional data in requests to Medusa'
Some of Medusa's API Routes accept an `additional_data` parameter whose type is an object. The API Route passes the `additional_data` to the workflow, which in turn passes it to its hooks.
This is useful when you have a link from your custom module to a commerce module, and you want to perform an additional action when a request is sent to an existing API route.
This is useful when you have a link from your custom module to a Commerce Module, and you want to perform an additional action when a request is sent to an existing API route.
For example, the [Create Product API Route](!api!/admin#products_postproducts) accepts an `additional_data` parameter. If you have a data model linked to it, you consume the `productsCreated` hook to create a record of the data model using the custom data and link it to the product.
@@ -152,7 +152,7 @@ The uploaded files are stored in the `req.files` property as an array of Multer
### Uploading Files using File Module Provider
The recommended way to upload the files to storage using the configured [File Module Provider](!resources!/architectural-modules/file) is to use the [uploadFilesWorkflow](!resources!/references/medusa-workflows/uploadFilesWorkflow):
The recommended way to upload the files to storage using the configured [File Module Provider](!resources!/infrastructure-modules/file) is to use the [uploadFilesWorkflow](!resources!/references/medusa-workflows/uploadFilesWorkflow):
```ts title="src/api/custom/route.ts"
import { MedusaRequest, MedusaResponse } from "@medusajs/framework/http"
@@ -98,11 +98,11 @@ The first message indicates that the `order.placed` event was emitted, and the s
## Event Module
The subscription and emitting of events is handled by an Event Module, an architectural module that implements the pub/sub functionalities of Medusa's event system.
The subscription and emitting of events is handled by an Event Module, an Infrastructure Module that implements the pub/sub functionalities of Medusa's event system.
Medusa provides two Event Modules out of the box:
- [Local Event Module](!resources!/architectural-modules/event/local), used by default. It's useful for development, as you don't need additional setup to use it.
- [Redis Event Module](!resources!/architectural-modules/event/redis), which is useful in production. It uses [Redis](https://redis.io/) to implement Medusa's pub/sub events system.
- [Local Event Module](!resources!/infrastructure-modules/event/local), used by default. It's useful for development, as you don't need additional setup to use it.
- [Redis Event Module](!resources!/infrastructure-modules/event/redis), which is useful in production. It uses [Redis](https://redis.io/) to implement Medusa's pub/sub events system.
Medusa's [architecture](../../introduction/architecture/page.mdx) also allows you to build a custom Event Module that uses a different service or logic to implement the pub/sub system. Learn how to build an Event Module in [this guide](!resources!/architectural-modules/event/create).
Medusa's [architecture](../../introduction/architecture/page.mdx) also allows you to build a custom Event Module that uses a different service or logic to implement the pub/sub system. Learn how to build an Event Module in [this guide](!resources!/infrastructure-modules/event/create).
@@ -10,7 +10,7 @@ In this chapter, youll learn what a module link is and how to define one.
Medusa's modular architecture isolates modules from one another to ensure they can be integrated into your application without side effects. Module isolation has other benefits, which you can learn about in the [Module Isolation chapter](../modules/isolation/page.mdx). Since modules are isolated, you can't access another module's data models to add a relation to it or extend it. Instead, you use a module link.
A module link forms an association between two data models of different modules while maintaining module isolation. Using module links, you can build virtual relations between your custom data models and data models in the commerce modules, which is useful as you extend the features provided by the commerce modules. Then, Medusa creates a link table in the database to store the IDs of the linked records. You'll learn more about link tables later in this chapter.
A module link forms an association between two data models of different modules while maintaining module isolation. Using module links, you can build virtual relations between your custom data models and data models in the Commerce Modules, which is useful as you extend the features provided by the Commerce Modules. Then, Medusa creates a link table in the database to store the IDs of the linked records. You'll learn more about link tables later in this chapter.
For example, the [Brand Customizations Tutorial](../../customization/extend-features/page.mdx) shows how to create a Brand Module that adds the concept of brands to your application, then link those brands to a product.
@@ -12,7 +12,7 @@ In this chapter, youll learn about Query and how to use it to fetch data from
Query fetches data across modules. Its a set of methods registered in the Medusa container under the `query` key.
In all resources that can access the [Medusa Container](../../medusa-container/page.mdx), such as API routes or workflows, you can resolve Query to fetch data across custom modules and Medusas commerce modules.
In all resources that can access the [Medusa Container](../../medusa-container/page.mdx), such as API routes or workflows, you can resolve Query to fetch data across custom modules and Medusas Commerce Modules.
---
@@ -4,13 +4,13 @@ export const metadata = {
# {metadata.title}
In this chapter, you'll learn about Medusa's commerce modules.
In this chapter, you'll learn about Medusa's Commerce Modules.
## What is a Commerce Module?
Commerce modules are built-in [modules](../page.mdx) of Medusa that provide core commerce logic specific to domains like Products, Orders, Customers, Fulfillment, and much more.
Commerce Modules are built-in [modules](../page.mdx) of Medusa that provide core commerce logic specific to domains like Products, Orders, Customers, Fulfillment, and much more.
Medusa's commerce modules are used to form Medusa's default [workflows](!resources!/medusa-workflows-reference) and [APIs](!api!/store). For example, when you call the add to cart endpoint. the add to cart workflow runs which uses the Product Module to check if the product exists, the Inventory Module to ensure the product is available in the inventory, and the Cart Module to finally add the product to the cart.
Medusa's Commerce Modules are used to form Medusa's default [workflows](!resources!/medusa-workflows-reference) and [APIs](!api!/store). For example, when you call the add to cart endpoint. the add to cart workflow runs which uses the Product Module to check if the product exists, the Inventory Module to ensure the product is available in the inventory, and the Cart Module to finally add the product to the cart.
<Note title="Tip">
@@ -22,13 +22,13 @@ The core commerce logic contained in Commerce Modules is also available directly
### List of Medusa's Commerce Modules
Refer to [this reference](!resources!/commerce-modules) for a full list of commerce modules in Medusa.
Refer to [this reference](!resources!/commerce-modules) for a full list of Commerce Modules in Medusa.
---
## Use Commerce Modules in Custom Flows
Similar to your [custom modules](../page.mdx), the Medusa application registers a commerce module's service in the [container](../../medusa-container/page.mdx). So, you can resolve it in your custom flows. This is useful as you build unique requirements extending core commerce features.
Similar to your [custom modules](../page.mdx), the Medusa application registers a Commerce Module's service in the [container](../../medusa-container/page.mdx). So, you can resolve it in your custom flows. This is useful as you build unique requirements extending core commerce features.
For example, consider you have a [workflow](../../../fundamentals/workflows/page.mdx) (a special function that performs a task in a series of steps with rollback mechanism) that needs a step to retrieve the total number of products. You can create a step in the workflow that resolves the Product Module's service from the container to use its methods:
@@ -52,4 +52,4 @@ export const countProductsStep = createStep(
)
```
Your workflow can use services of both custom and commerce modules, supporting you in building custom flows without having to re-build core commerce features.
Your workflow can use services of both custom and Commerce Modules, supporting you in building custom flows without having to re-build core commerce features.
@@ -1,33 +1,34 @@
export const metadata = {
title: `${pageNumber} Architectural Modules`,
title: `${pageNumber} Infrastructure Modules`,
}
# {metadata.title}
In this chapter, youll learn about architectural modules.
In this chapter, youll learn about Infrastructure Modules.
## What is an Architectural Module?
## What is an Infrastructure Module?
An architectural module implements features and mechanisms related to the Medusa applications architecture and infrastructure.
An Infrastructure Module implements features and mechanisms related to the Medusa applications architecture and infrastructure.
Since modules are interchangeable, you have more control over Medusas architecture. For example, you can choose to use Memcached for event handling instead of Redis.
---
## Architectural Module Types
## Infrastructure Module Types
There are different architectural module types including:
There are different Infrastructure Module types including:
![Diagram illustrating how the modules connect to third-party services](https://res.cloudinary.com/dza7lstvk/image/upload/v1727095814/Medusa%20Book/architectural-modules_bj9bb9.jpg)
![Diagram illustrating how the modules connect to third-party services](https://res.cloudinary.com/dza7lstvk/image/upload/v1727095814/Medusa%20Book/infrastructure-modules_bj9bb9.jpg)
- Cache Module: Defines the caching mechanism or logic to cache computational results.
- Event Module: Integrates a pub/sub service to handle subscribing to and emitting events.
- Workflow Engine Module: Integrates a service to store and track workflow executions and steps.
- File Module: Integrates a storage service to handle uploading and managing files.
- Notification Module: Integrates a third-party service or defines custom logic to send notifications to users and customers.
- Locking Module: Integrates a service that manages access to shared resources by multiple processes or threads.
---
## Architectural Modules List
## Infrastructure Modules List
Refer to the [Architectural Modules reference](!resources!/architectural-modules) for a list of Medusas architectural modules, available modules to install, and how to create an architectural module.
Refer to the [Infrastructure Modules reference](!resources!/infrastructure-modules) for a list of Medusas Infrastructure Modules, available modules to install, and how to create an Infrastructure Module.
@@ -502,9 +502,9 @@ import BlogType from "@myorg/plugin-name/types/blog"
### Create Module Providers
The [exported resources](#package-exports) also allow you to import module providers in your plugin and register them in the Medusa application's configuration. A module provider is a module that provides the underlying logic or integration related to a commerce or architectural module.
The [exported resources](#package-exports) also allow you to import module providers in your plugin and register them in the Medusa application's configuration. A module provider is a module that provides the underlying logic or integration related to a commerce or Infrastructure Module.
For example, assuming your plugin has a [Notification Module Provider](!resources!/architectural-modules/notification) called `my-notification`, you can register it in your Medusa application's configuration like this:
For example, assuming your plugin has a [Notification Module Provider](!resources!/infrastructure-modules/notification) called `my-notification`, you can register it in your Medusa application's configuration like this:
<Note title="Tip">
@@ -28,7 +28,7 @@ You can view stored workflow executions from the Medusa Admin dashboard by going
items={[
{
text: "Redis Workflow Engine must be installed and configured.",
link: "!resources!/architectural-modules/workflow-engine/redis"
link: "!resources!/infrastructure-modules/workflow-engine/redis"
}
]}
/>
@@ -49,7 +49,7 @@ Modules can be implemented within [plugins](../../fundamentals/plugins/page.mdx)
## Third-Party Integrations Layer
Third-party services and systems are integrated through Medusa's Commerce and Architectural modules. You also create custom third-party integrations through a [custom module](../../fundamentals/modules/page.mdx).
Third-party services and systems are integrated through Medusa's Commerce and Infrastructure Modules. You also create custom third-party integrations through a [custom module](../../fundamentals/modules/page.mdx).
<Note>
@@ -59,28 +59,28 @@ Modules can be implemented within [plugins](../../fundamentals/plugins/page.mdx)
### Commerce Modules
[Commerce modules](!resources!/commerce-modules) integrate third-party services relevant for commerce or user-facing features. For example, you can integrate [Stripe](!resources!/commerce-modules/payment/payment-provider/stripe) through a Payment Module Provider, or [ShipStation](!resources!/integrations/guides/shipstation) through a Fulfillment Module Provider.
[Commerce Modules](!resources!/commerce-modules) integrate third-party services relevant for commerce or user-facing features. For example, you can integrate [Stripe](!resources!/commerce-modules/payment/payment-provider/stripe) through a Payment Module Provider, or [ShipStation](!resources!/integrations/guides/shipstation) through a Fulfillment Module Provider.
You can also integrate third-party services for custom functionalities. For example, you can integrate [Sanity](!resources!/integrations/guides/sanity) for rich CMS capabilities, or [Odoo](!resources!/recipes/erp/odoo) to sync your Medusa application with your ERP system.
You can replace any of the third-party services mentioned above to build your preferred commerce ecosystem.
![Diagram illustrating the commerce modules integration to third-party services](https://res.cloudinary.com/dza7lstvk/image/upload/v1727175357/Medusa%20Book/service-commerce_qcbdsl.jpg)
![Diagram illustrating the Commerce Modules integration to third-party services](https://res.cloudinary.com/dza7lstvk/image/upload/v1727175357/Medusa%20Book/service-commerce_qcbdsl.jpg)
### Architectural Modules
### Infrastructure Modules
[Architectural modules](!resources!/architectural-modules) integrate third-party services and systems for architectural features. Medusa has the following Architectural modules:
[Infrastructure Modules](!resources!/infrastructure-modules) integrate third-party services and systems that customize Medusa's infrastructure. Medusa has the following Infrastructure Modules:
- [Cache Module](!resources!/architectural-modules/cache): Caches data that require heavy computation. You can integrate a custom module to handle the caching with services like Memcached, or use the existing [Redis Cache Module](!resources!/architectural-modules/cache/redis).
- [Event Module](!resources!/architectural-modules/event): A pub/sub system that allows you to subscribe to events and trigger them. You can integrate [Redis](!resources!/architectural-modules/event/redis) as the pub/sub system.
- [File Module](!resources!/architectural-modules/file): Manages file uploads and storage, such as upload of product images. You can integrate [AWS S3](!resources!/architectural-modules/file/s3) for file storage.
- [Locking Module](!resources!/architectural-modules/locking): Manages access to shared resources by multiple processes or threads, preventing conflict between processes and ensuring data consistency. You can integrate [Redis](!resources!/architectural-modules/locking/redis) for locking.
- [Notification Module](!resources!/architectural-modules/notification): Sends notifications to customers and users, such as for order updates or newsletters. You can integrate [SendGrid](!resources!/architectural-modules/notification/sendgrid) for sending emails.
- [Workflow Engine Module](!resources!/architectural-modules/workflow-engine): Orchestrates workflows that hold the business logic of your application. You can integrate [Redis](!resources!/architectural-modules/workflow-engine/redis) to orchestrate workflows.
- [Cache Module](!resources!/infrastructure-modules/cache): Caches data that require heavy computation. You can integrate a custom module to handle the caching with services like Memcached, or use the existing [Redis Cache Module](!resources!/infrastructure-modules/cache/redis).
- [Event Module](!resources!/infrastructure-modules/event): A pub/sub system that allows you to subscribe to events and trigger them. You can integrate [Redis](!resources!/infrastructure-modules/event/redis) as the pub/sub system.
- [File Module](!resources!/infrastructure-modules/file): Manages file uploads and storage, such as upload of product images. You can integrate [AWS S3](!resources!/infrastructure-modules/file/s3) for file storage.
- [Locking Module](!resources!/infrastructure-modules/locking): Manages access to shared resources by multiple processes or threads, preventing conflict between processes and ensuring data consistency. You can integrate [Redis](!resources!/infrastructure-modules/locking/redis) for locking.
- [Notification Module](!resources!/infrastructure-modules/notification): Sends notifications to customers and users, such as for order updates or newsletters. You can integrate [SendGrid](!resources!/infrastructure-modules/notification/sendgrid) for sending emails.
- [Workflow Engine Module](!resources!/infrastructure-modules/workflow-engine): Orchestrates workflows that hold the business logic of your application. You can integrate [Redis](!resources!/infrastructure-modules/workflow-engine/redis) to orchestrate workflows.
All of the third-party services mentioned above can be replaced to help you build your preferred architecture and ecosystem.
![Diagram illustrating the architectural modules integration to third-party services and systems](https://res.cloudinary.com/dza7lstvk/image/upload/v1727175342/Medusa%20Book/service-arch_ozvryw.jpg)
![Diagram illustrating the Infrastructure Modules integration to third-party services and systems](https://res.cloudinary.com/dza7lstvk/image/upload/v1727175342/Medusa%20Book/service-arch_ozvryw.jpg)
---
+2 -2
View File
@@ -12,7 +12,7 @@ Medusa is a digital commerce platform with a built-in Framework for customizatio
Medusa ships with three main tools:
1. A suite of [commerce modules](!resources!/commerce-modules) with core commerce functionalities, such as tracking inventory, calculating cart totals, accepting payments, managing orders, and much more.
1. A suite of [Commerce Modules](!resources!/commerce-modules) with core commerce functionalities, such as tracking inventory, calculating cart totals, accepting payments, managing orders, and much more.
2. A [Framework](./fundamentals/framework/page.mdx) for building custom functionalities specific to your business, product, or industry. This includes tools for introducing custom API endpoints, business logic, and data models; building workflows and automations; and integrating with third-party services.
3. A customizable admin dashboard for merchants to configure and operate their store.
@@ -100,7 +100,7 @@ This documentation is split into the following sections:
Product
</Table.Cell>
<Table.Cell>
Documentation for the [Framework](./fundamentals/framework/page.mdx), [Commerce Modules](!resources!/commerce-modules), and [Architectural Modules](!resources!/architectural-modules). These sections include concepts, guides, and references for each of those products.
Documentation for the [Framework](./fundamentals/framework/page.mdx), [Commerce Modules](!resources!/commerce-modules), and [Infrastructure Modules](!resources!/infrastructure-modules). These sections include concepts, guides, and references for each of those products.
</Table.Cell>
</Table.Row>
<Table.Row>
@@ -156,7 +156,7 @@ const HomepageModulesSection = () => {
All commerce features are provided as extendable modules in Medusa.
</h2>
<span className="text-medusa-fg-subtle text-small-plus">
Click on any of the commerce modules below to learn more about their
Click on any of the Commerce Modules below to learn more about their
commerce features, and how to extend and use them for your custom
use-case.
</span>
+15 -15
View File
@@ -2,8 +2,8 @@ export const generatedEditDates = {
"app/learn/fundamentals/scheduled-jobs/page.mdx": "2024-12-09T10:51:40.570Z",
"app/learn/fundamentals/workflows/page.mdx": "2024-12-09T14:45:17.837Z",
"app/learn/deployment/page.mdx": "2025-03-11T14:53:25.540Z",
"app/learn/page.mdx": "2025-04-17T07:45:47.162Z",
"app/learn/fundamentals/modules/commerce-modules/page.mdx": "2024-12-09T10:46:29.339Z",
"app/learn/page.mdx": "2025-04-17T08:50:17.036Z",
"app/learn/fundamentals/modules/commerce-modules/page.mdx": "2025-04-17T08:51:32.723Z",
"app/learn/fundamentals/workflows/retry-failed-steps/page.mdx": "2025-03-28T07:15:19.388Z",
"app/learn/fundamentals/workflows/workflow-hooks/page.mdx": "2024-12-09T10:44:33.781Z",
"app/learn/debugging-and-testing/logging/page.mdx": "2024-09-30T08:43:53.135Z",
@@ -17,7 +17,7 @@ export const generatedEditDates = {
"app/learn/fundamentals/api-routes/page.mdx": "2024-12-04T11:02:57.134Z",
"app/learn/fundamentals/modules/modules-directory-structure/page.mdx": "2024-12-09T10:32:46.839Z",
"app/learn/fundamentals/workflows/access-workflow-errors/page.mdx": "2024-10-21T13:30:21.371Z",
"app/learn/fundamentals/events-and-subscribers/page.mdx": "2024-12-09T10:48:09.285Z",
"app/learn/fundamentals/events-and-subscribers/page.mdx": "2025-04-17T08:29:09.896Z",
"app/learn/fundamentals/modules/container/page.mdx": "2025-03-18T15:10:03.574Z",
"app/learn/fundamentals/workflows/execute-another-workflow/page.mdx": "2024-12-09T15:56:22.895Z",
"app/learn/fundamentals/modules/loaders/page.mdx": "2025-03-24T06:40:39.948Z",
@@ -67,13 +67,13 @@ export const generatedEditDates = {
"app/learn/debugging-and-testing/testing-tools/modules-tests/page.mdx": "2025-03-24T06:54:21.249Z",
"app/learn/fundamentals/module-links/custom-columns/page.mdx": "2025-03-11T13:29:54.752Z",
"app/learn/fundamentals/module-links/directions/page.mdx": "2025-03-17T12:52:06.161Z",
"app/learn/fundamentals/module-links/page.mdx": "2025-03-11T13:39:14.345Z",
"app/learn/fundamentals/module-links/query/page.mdx": "2025-03-24T06:42:32.337Z",
"app/learn/fundamentals/module-links/page.mdx": "2025-04-17T08:50:17.036Z",
"app/learn/fundamentals/module-links/query/page.mdx": "2025-04-17T08:50:17.036Z",
"app/learn/fundamentals/modules/db-operations/page.mdx": "2025-03-21T09:21:46.901Z",
"app/learn/fundamentals/modules/multiple-services/page.mdx": "2025-03-18T15:11:44.632Z",
"app/learn/fundamentals/modules/page.mdx": "2025-03-18T07:51:09.049Z",
"app/learn/debugging-and-testing/instrumentation/page.mdx": "2025-02-24T08:12:53.132Z",
"app/learn/fundamentals/api-routes/additional-data/page.mdx": "2025-01-27T08:45:19.025Z",
"app/learn/fundamentals/api-routes/additional-data/page.mdx": "2025-04-17T08:50:17.036Z",
"app/learn/fundamentals/workflows/variable-manipulation/page.mdx": "2025-01-27T08:45:19.029Z",
"app/learn/customization/custom-features/api-route/page.mdx": "2024-12-09T10:39:30.046Z",
"app/learn/customization/custom-features/module/page.mdx": "2025-03-18T07:49:30.590Z",
@@ -83,38 +83,38 @@ export const generatedEditDates = {
"app/learn/customization/customize-admin/page.mdx": "2024-12-09T11:02:38.801Z",
"app/learn/customization/customize-admin/route/page.mdx": "2025-02-11T15:56:03.835Z",
"app/learn/customization/customize-admin/widget/page.mdx": "2025-02-05T09:10:18.163Z",
"app/learn/customization/extend-features/define-link/page.mdx": "2024-12-09T11:02:39.346Z",
"app/learn/customization/extend-features/define-link/page.mdx": "2025-04-17T08:50:17.036Z",
"app/learn/customization/extend-features/page.mdx": "2024-12-09T11:02:39.244Z",
"app/learn/customization/extend-features/query-linked-records/page.mdx": "2025-03-25T13:48:49.973Z",
"app/learn/customization/integrate-systems/handle-event/page.mdx": "2024-12-24T15:09:24.653Z",
"app/learn/customization/integrate-systems/page.mdx": "2024-12-09T10:40:08.528Z",
"app/learn/customization/integrate-systems/schedule-task/page.mdx": "2025-01-28T16:42:42.071Z",
"app/learn/customization/integrate-systems/service/page.mdx": "2024-12-09T11:02:39.594Z",
"app/learn/customization/next-steps/page.mdx": "2024-12-06T14:34:53.356Z",
"app/learn/fundamentals/modules/architectural-modules/page.mdx": "2024-10-21T13:30:21.367Z",
"app/learn/introduction/architecture/page.mdx": "2025-03-12T14:39:09.724Z",
"app/learn/customization/next-steps/page.mdx": "2025-04-17T08:50:17.036Z",
"app/learn/fundamentals/modules/infrastructure-modules/page.mdx": "2025-04-17T08:29:09.895Z",
"app/learn/introduction/architecture/page.mdx": "2025-04-17T08:51:32.723Z",
"app/learn/fundamentals/data-models/infer-type/page.mdx": "2025-03-18T07:41:01.936Z",
"app/learn/fundamentals/custom-cli-scripts/seed-data/page.mdx": "2024-12-09T14:38:06.385Z",
"app/learn/fundamentals/environment-variables/page.mdx": "2025-03-11T08:55:03.343Z",
"app/learn/build/page.mdx": "2024-12-09T11:05:17.383Z",
"app/learn/deployment/general/page.mdx": "2025-03-25T13:32:56.287Z",
"app/learn/deployment/general/page.mdx": "2025-04-17T08:29:09.878Z",
"app/learn/fundamentals/workflows/multiple-step-usage/page.mdx": "2024-11-25T16:19:32.169Z",
"app/learn/installation/page.mdx": "2025-03-11T08:55:12.967Z",
"app/learn/fundamentals/data-models/check-constraints/page.mdx": "2024-12-06T14:34:50.384Z",
"app/learn/fundamentals/module-links/link/page.mdx": "2025-04-07T08:03:14.513Z",
"app/learn/fundamentals/workflows/store-executions/page.mdx": "2025-02-11T15:56:03.835Z",
"app/learn/fundamentals/plugins/create/page.mdx": "2025-04-15T06:41:10.746Z",
"app/learn/fundamentals/workflows/store-executions/page.mdx": "2025-04-17T08:29:10.166Z",
"app/learn/fundamentals/plugins/create/page.mdx": "2025-04-17T08:29:09.910Z",
"app/learn/fundamentals/plugins/page.mdx": "2025-01-22T10:14:10.433Z",
"app/learn/customization/reuse-customizations/page.mdx": "2025-01-22T10:01:57.665Z",
"app/learn/update/page.mdx": "2025-01-27T08:45:19.030Z",
"app/learn/fundamentals/module-links/query-context/page.mdx": "2025-02-12T16:59:20.963Z",
"app/learn/fundamentals/admin/environment-variables/page.mdx": "2025-03-25T13:32:19.713Z",
"app/learn/fundamentals/api-routes/parse-body/page.mdx": "2025-02-14T08:32:25.596Z",
"app/learn/fundamentals/api-routes/parse-body/page.mdx": "2025-04-17T08:29:10.145Z",
"app/learn/fundamentals/admin/routing/page.mdx": "2025-02-24T09:50:37.495Z",
"app/learn/resources/contribution-guidelines/admin-translations/page.mdx": "2025-02-11T16:57:46.726Z",
"app/learn/resources/contribution-guidelines/docs/page.mdx": "2025-03-06T09:32:26.010Z",
"app/learn/resources/usage/page.mdx": "2025-02-26T13:35:34.824Z",
"app/learn/configurations/medusa-config/page.mdx": "2025-03-11T14:27:04.528Z",
"app/learn/configurations/medusa-config/page.mdx": "2025-04-17T08:29:09.907Z",
"app/learn/configurations/ts-aliases/page.mdx": "2025-02-11T16:57:46.683Z",
"app/learn/production/worker-mode/page.mdx": "2025-03-11T15:21:50.906Z",
"app/learn/fundamentals/module-links/read-only/page.mdx": "2025-03-21T09:14:54.944Z",
+3 -3
View File
@@ -364,10 +364,10 @@ export const generatedSidebars = [
"loaded": true,
"isPathHref": true,
"type": "link",
"path": "/learn/fundamentals/modules/architectural-modules",
"title": "Architectural Modules",
"path": "/learn/fundamentals/modules/infrastructure-modules",
"title": "Infrastructure Modules",
"children": [],
"chapterTitle": "3.3.11. Architectural Modules",
"chapterTitle": "3.3.11. Infrastructure Modules",
"number": "3.3.11."
}
],
File diff suppressed because it is too large Load Diff
+10 -10
View File
@@ -4,7 +4,7 @@
Medusa ships with three main tools:
- A suite of commerce modules with core commerce functionalities, such as tracking inventory, calculating cart totals, accepting payments, managing orders, and much more.
- A suite of Commerce Modules with core commerce functionalities, such as tracking inventory, calculating cart totals, accepting payments, managing orders, and much more.
- A framework for building custom functionalities specific to your business, product, or industry. This includes tools for introducing custom API endpoints, business logic, and data models; building workflows and automations; and integrating with third-party services.
- A customizable admin dashboard for merchants to configure and operate their store.
@@ -16,7 +16,7 @@ Businesses of all sizes can use Medusa, from small start ups to large enterprise
- [Get Started](https://docs.medusajs.com/learn/installation/index.html.md): Install a digital commerce application with Medusa.
- [Main docs](https://docs.medusajs.com/learn/index.html.md): Chapters to learn Medusa's concepts and toolings.
- [Development guides and resources](https://docs.medusajs.com/resources/index.html.md): Development guides for storefront, admin, commerce modules, and more.
- [Development guides and resources](https://docs.medusajs.com/resources/index.html.md): Development guides for storefront, admin, Commerce Modules, and more.
- [Medusa UI](https://docs.medusajs.com/ui/index.html.md): A React library to build applications using Medusa's primitives and design system.
- [Admin API Reference](https://docs.medusajs.com/api/admin): List of all Admin API routes in Medusa with code snippets.
- [Store API Reference](https://docs.medusajs.com/api/store): List of all Store API Routes in Medusa with code snippets.
@@ -41,8 +41,8 @@ Businesses of all sizes can use Medusa, from small start ups to large enterprise
## Built-in Modules
- [Commerce Modules](https://docs.medusajs.com/resources/commerce-modules): A commerce module provides features for a commerce domain within its service. The Medusa application exposes these features in its API routes to clients.
- [Architectural Modules](https://docs.medusajs.com/resources/architectural-modules): An architectural module is a package that can be installed and used in any Medusa application. These modules allow you to choose and integrate custom services for architectural purposes.
- [Commerce Modules](https://docs.medusajs.com/resources/commerce-modules): A Commerce Module provides features for a commerce domain within its service. The Medusa application exposes these features in its API routes to clients.
- [Infrastructure Modules](https://docs.medusajs.com/resources/infrastructure-modules): An infrastructure module is a package that can be installed and used in any Medusa application. These modules allow you to choose and integrate custom services to modify your application's infrastructure.
## Tools and SDKs
@@ -260,13 +260,13 @@ Businesses of all sizes can use Medusa, from small start ups to large enterprise
- [User Module's Service Reference](https://docs.medusajs.com/resources/references/user/index.html.md): Methods of the User Module's Service.
- [User Module's Data Models Reference](https://docs.medusajs.com/resources/references/user/models/index.html.md): Data models created by the User Module.
## Architectural Modules
## Infrastructure Modules
- [Cache Modules](https://docs.medusajs.com/resources/architectural-modules/cache/index.html.md): A Cache Module is used to cache the results of computations such as price selection or various tax calculations.
- [Event Modules](https://docs.medusajs.com/resources/architectural-modules/event/index.html.md): An Event Module implements the underlying publish/subscribe system that handles queueing events, emitting them, and executing their subscribers.
- [File Module Providers](https://docs.medusajs.com/resources/architectural-modules/file/index.html.md): A file module provider implements the underlying logic of handling uploads and downloads of assets, such as integrating third-party services. The File Module must have one file module provider configured.
- [Notification Module Provider](https://docs.medusajs.com/resources/architectural-modules/notification/index.html.md): A notification module provider implements the underlying logic of sending notification. It either integrates a third-party service or uses custom logic to send the notification.
- [Workflow Engine Modules](https://docs.medusajs.com/resources/architectural-modules/workflow-engine/index.html.md): Workflow engine modules handle tracking and recording the transactions and statuses of workflows and their steps.
- [Cache Modules](https://docs.medusajs.com/resources/infrastructure-modules/cache/index.html.md): A Cache Module is used to cache the results of computations such as price selection or various tax calculations.
- [Event Modules](https://docs.medusajs.com/resources/infrastructure-modules/event/index.html.md): An Event Module implements the underlying publish/subscribe system that handles queueing events, emitting them, and executing their subscribers.
- [File Module Providers](https://docs.medusajs.com/resources/infrastructure-modules/file/index.html.md): A file module provider implements the underlying logic of handling uploads and downloads of assets, such as integrating third-party services. The File Module must have one file module provider configured.
- [Notification Module Provider](https://docs.medusajs.com/resources/infrastructure-modules/notification/index.html.md): A notification module provider implements the underlying logic of sending notification. It either integrates a third-party service or uses custom logic to send the notification.
- [Workflow Engine Modules](https://docs.medusajs.com/resources/infrastructure-modules/workflow-engine/index.html.md): Workflow engine modules handle tracking and recording the transactions and statuses of workflows and their steps.
## Optional
+2 -2
View File
@@ -195,8 +195,8 @@ export const sidebars = [
},
{
type: "link",
path: "/learn/fundamentals/modules/architectural-modules",
title: "Architectural Modules",
path: "/learn/fundamentals/modules/infrastructure-modules",
title: "Infrastructure Modules",
},
],
},
+7 -2
View File
@@ -64,8 +64,8 @@ const redirects = async () => {
permanent: true,
},
{
source: "/learn/advanced-development/architecture/architectural-modules",
destination: "/learn/fundamentals/modules/architectural-modules",
source: "/learn/advanced-development/architecture/infrastructure-modules",
destination: "/learn/fundamentals/modules/infrastructure-modules",
permanent: true,
},
{
@@ -158,6 +158,11 @@ const redirects = async () => {
destination: "/resources/nextjs-starter",
permanent: true,
},
{
source: "/learn/fundamentals/modules/infrastructure-modules",
destination: "/learn/fundamentals/modules/infrastructure-modules",
permanent: true,
},
]
}
@@ -6,7 +6,7 @@ export const metadata = {
# {metadata.title}
This document showcases the module links defined between the API Key Module and other commerce modules.
This document showcases the module links defined between the API Key Module and other Commerce Modules.
## Summary
@@ -14,7 +14,7 @@ Refer to the [Medusa Admin User Guide](!user-guide!/settings/developer) to learn
</Note>
Medusa has API-key related features available out-of-the-box through the API Key Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in commerce modules, such as this API Key Module.
Medusa has API-key related features available out-of-the-box through the API Key Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in Commerce Modules, such as this API Key Module.
<Note>
@@ -33,7 +33,7 @@ Learn more about why modules are isolated in [this documentation](!docs!/learn/f
## How to Use the API Key Module
In your Medusa application, you build flows around commerce modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
In your Medusa application, you build flows around Commerce Modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
You can build custom workflows and steps. You can also re-use Medusa's workflows and steps, which are provided by the `@medusajs/medusa/core-flows` package.
@@ -8,7 +8,7 @@ export const metadata = {
In this section of the documentation, you will find resources to learn more about the Auth Module and how to use it in your application.
Medusa has auth related features available out-of-the-box through the Auth Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in commerce modules, such as this Auth Module.
Medusa has auth related features available out-of-the-box through the Auth Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in Commerce Modules, such as this Auth Module.
<Note>
@@ -27,7 +27,7 @@ Learn more about why modules are isolated in [this documentation](!docs!/learn/f
## How to Use the Auth Module
In your Medusa application, you build flows around commerce modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
In your Medusa application, you build flows around Commerce Modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
You can build custom workflows and steps. You can also re-use Medusa's workflows and steps, which are provided by the `@medusajs/medusa/core-flows` package.
@@ -28,7 +28,7 @@ You'll create a subscriber that listens to the event. When the event is emitted,
items={[
{
text: "A notification provider module, such as SendGrid",
link: "/architectural-modules/notification/sendgrid"
link: "/infrastructure-modules/notification/sendgrid"
}
]}
/>
@@ -6,7 +6,7 @@ export const metadata = {
# {metadata.title}
This document showcases the module links defined between the Cart Module and other commerce modules.
This document showcases the module links defined between the Cart Module and other Commerce Modules.
## Summary
@@ -8,7 +8,7 @@ export const metadata = {
In this section of the documentation, you will find resources to learn more about the Cart Module and how to use it in your application.
Medusa has cart related features available out-of-the-box through the Cart Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in commerce modules, such as this Cart Module.
Medusa has cart related features available out-of-the-box through the Cart Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in Commerce Modules, such as this Cart Module.
<Note>
@@ -21,13 +21,13 @@ Learn more about why modules are isolated in [this documentation](!docs!/learn/f
- [Cart Management](./concepts/page.mdx): Store and manage carts, including their addresses, line items, shipping methods, and more.
- [Apply Promotion Adjustments](./promotions/page.mdx): Apply promotions or discounts to line items and shipping methods by adding adjustment lines that are factored into their subtotals.
- [Apply Tax Lines](./tax-lines/page.mdx): Apply tax lines to line items and shipping methods.
- [Cart Scoping](./links-to-other-modules/page.mdx): When used in the Medusa application, Medusa creates links to other commerce modules, scoping a cart to a sales channel, region, and a customer.
- [Cart Scoping](./links-to-other-modules/page.mdx): When used in the Medusa application, Medusa creates links to other Commerce Modules, scoping a cart to a sales channel, region, and a customer.
---
## How to Use the Cart Module
In your Medusa application, you build flows around commerce modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
In your Medusa application, you build flows around Commerce Modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
You can build custom workflows and steps. You can also re-use Medusa's workflows and steps, which are provided by the `@medusajs/medusa/core-flows` package.
@@ -6,7 +6,7 @@ export const metadata = {
# {metadata.title}
This document showcases the module links defined between the Currency Module and other commerce modules.
This document showcases the module links defined between the Currency Module and other Commerce Modules.
## Summary
@@ -14,7 +14,7 @@ Refer to the [Medusa Admin User Guide](!user-guide!/settings/store) to learn how
</Note>
Medusa has currency related features available out-of-the-box through the Currency Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in commerce modules, such as this Currency Module.
Medusa has currency related features available out-of-the-box through the Currency Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in Commerce Modules, such as this Currency Module.
<Note>
@@ -25,13 +25,13 @@ Learn more about why modules are isolated in [this documentation](!docs!/learn/f
## Currency Features
- [Currency Management and Retrieval](/references/currency/listAndCountCurrencies): This module adds all common currencies to your application and allows you to retrieve them.
- [Support Currencies in Modules](./links-to-other-modules/page.mdx): Other commerce modules use currency codes in their data models or operations. Use the Currency Module to retrieve a currency code and its details.
- [Support Currencies in Modules](./links-to-other-modules/page.mdx): Other Commerce Modules use currency codes in their data models or operations. Use the Currency Module to retrieve a currency code and its details.
---
## How to Use the Currency Module
In your Medusa application, you build flows around commerce modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
In your Medusa application, you build flows around Commerce Modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
You can build custom workflows and steps. You can also re-use Medusa's workflows and steps, which are provided by the `@medusajs/medusa/core-flows` package.
@@ -6,7 +6,7 @@ export const metadata = {
# {metadata.title}
This document showcases the module links defined between the Customer Module and other commerce modules.
This document showcases the module links defined between the Customer Module and other Commerce Modules.
## Summary
@@ -14,7 +14,7 @@ Refer to the [Medusa Admin User Guide](!user-guide!/customers) to learn how to m
</Note>
Medusa has customer related features available out-of-the-box through the Customer Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in commerce modules, such as this Customer Module.
Medusa has customer related features available out-of-the-box through the Customer Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in Commerce Modules, such as this Customer Module.
<Note>
@@ -31,7 +31,7 @@ Learn more about why modules are isolated in [this documentation](!docs!/learn/f
## How to Use the Customer Module
In your Medusa application, you build flows around commerce modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
In your Medusa application, you build flows around Commerce Modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
You can build custom workflows and steps. You can also re-use Medusa's workflows and steps, which are provided by the `@medusajs/medusa/core-flows` package.
@@ -6,7 +6,7 @@ export const metadata = {
# {metadata.title}
This document showcases the module links defined between the Fulfillment Module and other commerce modules.
This document showcases the module links defined between the Fulfillment Module and other Commerce Modules.
## Summary
@@ -17,7 +17,7 @@ Refer to the Medusa Admin User Guide to learn how to use the dashboard to:
</Note>
Medusa has fulfillment related features available out-of-the-box through the Fulfillment Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in commerce modules, such as this Fulfillment Module.
Medusa has fulfillment related features available out-of-the-box through the Fulfillment Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in Commerce Modules, such as this Fulfillment Module.
<Note>
@@ -36,7 +36,7 @@ Learn more about why modules are isolated in [this documentation](!docs!/learn/f
## How to Use the Fulfillment Module
In your Medusa application, you build flows around commerce modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
In your Medusa application, you build flows around Commerce Modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
You can build custom workflows and steps. You can also re-use Medusa's workflows and steps, which are provided by the `@medusajs/medusa/core-flows` package.
@@ -6,7 +6,7 @@ export const metadata = {
# {metadata.title}
This document showcases the module links defined between the Inventory Module and other commerce modules.
This document showcases the module links defined between the Inventory Module and other Commerce Modules.
## Summary
@@ -14,7 +14,7 @@ Refer to the [Medusa Admin User Guide](!user-guide!/inventory) to learn how to m
</Note>
Medusa has inventory related features available out-of-the-box through the Inventory Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in commerce modules, such as this Inventory Module.
Medusa has inventory related features available out-of-the-box through the Inventory Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in Commerce Modules, such as this Inventory Module.
<Note>
@@ -34,7 +34,7 @@ Learn more about why modules are isolated in [this documentation](!docs!/learn/f
## How to Use the Inventory Module
In your Medusa application, you build flows around commerce modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
In your Medusa application, you build flows around Commerce Modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
You can build custom workflows and steps. You can also re-use Medusa's workflows and steps, which are provided by the `@medusajs/medusa/core-flows` package.
@@ -6,7 +6,7 @@ export const metadata = {
# {metadata.title}
This document showcases the module links defined between the Order Module and other commerce modules.
This document showcases the module links defined between the Order Module and other Commerce Modules.
## Summary
@@ -14,7 +14,7 @@ Refer to the [Medusa Admin User Guide](!user-guide!/orders) to learn how to mana
</Note>
Medusa has order related features available out-of-the-box through the Order Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in commerce modules, such as this Order Module.
Medusa has order related features available out-of-the-box through the Order Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in Commerce Modules, such as this Order Module.
<Note>
@@ -34,7 +34,7 @@ Learn more about why modules are isolated in [this documentation](!docs!/learn/f
## How to Use the Order Module
In your Medusa application, you build flows around commerce modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
In your Medusa application, you build flows around Commerce Modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
You can build custom workflows and steps. You can also re-use Medusa's workflows and steps, which are provided by the `@medusajs/medusa/core-flows` package.
@@ -6,11 +6,11 @@ export const metadata = {
# {metadata.title}
In this section of the documentation, you'll find guides and references related to Medusa's commerce modules.
In this section of the documentation, you'll find guides and references related to Medusa's Commerce Modules.
A commerce module provides features for a commerce domain within its service. The Medusa application exposes these features in its API routes to clients.
A Commerce Module provides features for a commerce domain within its service. The Medusa application exposes these features in its API routes to clients.
A commerce module also defines data models, representing tables in the database. The Medusa Framework and tools allow you to extend these data models to add custom fields.
A Commerce Module also defines data models, representing tables in the database. The Medusa Framework and tools allow you to extend these data models to add custom fields.
## Commerce Modules List
@@ -6,7 +6,7 @@ export const metadata = {
# {metadata.title}
This document showcases the module links defined between the Payment Module and other commerce modules.
This document showcases the module links defined between the Payment Module and other Commerce Modules.
## Summary
@@ -14,7 +14,7 @@ Refer to the [Medusa Admin User Guide](!user-guide!/orders/payments) to learn ho
</Note>
Medusa has payment related features available out-of-the-box through the Payment Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in commerce modules, such as this Payment Module.
Medusa has payment related features available out-of-the-box through the Payment Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in Commerce Modules, such as this Payment Module.
<Note>
@@ -34,7 +34,7 @@ Learn more about why modules are isolated in [this documentation](!docs!/learn/f
## How to Use the Payment Module
In your Medusa application, you build flows around commerce modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
In your Medusa application, you build flows around Commerce Modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
You can build custom workflows and steps. You can also re-use Medusa's workflows and steps, which are provided by the `@medusajs/medusa/core-flows` package.
@@ -6,7 +6,7 @@ export const metadata = {
# {metadata.title}
This document showcases the module links defined between the Pricing Module and other commerce modules.
This document showcases the module links defined between the Pricing Module and other Commerce Modules.
## Summary
@@ -14,7 +14,7 @@ Refer to the [Medusa Admin User Guide](!user-guide!/price-lists) to learn how to
</Note>
Medusa has pricing related features available out-of-the-box through the Pricing Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in commerce modules, such as this Pricing Module.
Medusa has pricing related features available out-of-the-box through the Pricing Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in Commerce Modules, such as this Pricing Module.
<Note>
@@ -34,7 +34,7 @@ Learn more about why modules are isolated in [this documentation](!docs!/learn/f
## How to Use the Pricing Module
In your Medusa application, you build flows around commerce modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
In your Medusa application, you build flows around Commerce Modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
You can build custom workflows and steps. You can also re-use Medusa's workflows and steps, which are provided by the `@medusajs/medusa/core-flows` package.
@@ -6,7 +6,7 @@ export const metadata = {
# {metadata.title}
This document showcases the module links defined between the Product Module and other commerce modules.
This document showcases the module links defined between the Product Module and other Commerce Modules.
## Summary
@@ -14,7 +14,7 @@ Refer to the [Medusa Admin User Guide](!user-guide!/products) to learn how to ma
</Note>
Medusa has product related features available out-of-the-box through the Product Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in commerce modules, such as this Product Module.
Medusa has product related features available out-of-the-box through the Product Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in Commerce Modules, such as this Product Module.
<Note>
@@ -32,7 +32,7 @@ Learn more about why modules are isolated in [this documentation](!docs!/learn/f
## How to Use the Product Module
In your Medusa application, you build flows around commerce modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
In your Medusa application, you build flows around Commerce Modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
You can build custom workflows and steps. You can also re-use Medusa's workflows and steps, which are provided by the `@medusajs/medusa/core-flows` package.
@@ -6,7 +6,7 @@ export const metadata = {
# {metadata.title}
This document showcases the module links defined between the Promotion Module and other commerce modules.
This document showcases the module links defined between the Promotion Module and other Commerce Modules.
## Summary
@@ -14,7 +14,7 @@ Refer to the [Medusa Admin User Guide](!user-guide!/promotions) to learn how to
</Note>
Medusa has promotion related features available out-of-the-box through the Promotion Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in commerce modules, such as this Promotion Module.
Medusa has promotion related features available out-of-the-box through the Promotion Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in Commerce Modules, such as this Promotion Module.
<Note>
@@ -33,7 +33,7 @@ Learn more about why modules are isolated in [this documentation](!docs!/learn/f
## How to Use the Promotion Module
In your Medusa application, you build flows around commerce modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
In your Medusa application, you build flows around Commerce Modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
You can build custom workflows and steps. You can also re-use Medusa's workflows and steps, which are provided by the `@medusajs/medusa/core-flows` package.
@@ -6,7 +6,7 @@ export const metadata = {
# {metadata.title}
This document showcases the module links defined between the Region Module and other commerce modules.
This document showcases the module links defined between the Region Module and other Commerce Modules.
## Summary
@@ -14,7 +14,7 @@ Refer to the [Medusa Admin User Guide](!user-guide!/settings/regions) to learn h
</Note>
Medusa has region related features available out-of-the-box through the Region Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in commerce modules, such as this Region Module.
Medusa has region related features available out-of-the-box through the Region Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in Commerce Modules, such as this Region Module.
<Note>
@@ -34,7 +34,7 @@ Learn more about why modules are isolated in [this documentation](!docs!/learn/f
## How to Use Region Module's Service
In your Medusa application, you build flows around commerce modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
In your Medusa application, you build flows around Commerce Modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
You can build custom workflows and steps. You can also re-use Medusa's workflows and steps, which are provided by the `@medusajs/medusa/core-flows` package.
@@ -6,7 +6,7 @@ export const metadata = {
# {metadata.title}
This document showcases the module links defined between the Sales Channel Module and other commerce modules.
This document showcases the module links defined between the Sales Channel Module and other Commerce Modules.
## Summary
@@ -14,7 +14,7 @@ Refer to the [Medusa Admin User Guide](!user-guide!/settings/sales-channels) to
</Note>
Medusa has sales channel related features available out-of-the-box through the Sales Channel Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in commerce modules, such as this Sales Channel Module.
Medusa has sales channel related features available out-of-the-box through the Sales Channel Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in Commerce Modules, such as this Sales Channel Module.
<Note>
@@ -45,7 +45,7 @@ Some use case examples for using a sales channel:
## How to Use Sales Channel Module's Service
In your Medusa application, you build flows around commerce modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
In your Medusa application, you build flows around Commerce Modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
You can build custom workflows and steps. You can also re-use Medusa's workflows and steps, which are provided by the `@medusajs/medusa/core-flows` package.
@@ -6,7 +6,7 @@ export const metadata = {
# {metadata.title}
This document showcases the module links defined between the Stock Location Module and other commerce modules.
This document showcases the module links defined between the Stock Location Module and other Commerce Modules.
## Summary
@@ -14,7 +14,7 @@ Refer to the [Medusa Admin User Guide](!user-guide!/settings/locations-and-shipp
</Note>
Medusa has stock location related features available out-of-the-box through the Stock Location Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in commerce modules, such as this Stock Location Module.
Medusa has stock location related features available out-of-the-box through the Stock Location Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in Commerce Modules, such as this Stock Location Module.
<Note>
@@ -31,7 +31,7 @@ Learn more about why modules are isolated in [this documentation](!docs!/learn/f
## How to Use Stock Location Module's Service
In your Medusa application, you build flows around commerce modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
In your Medusa application, you build flows around Commerce Modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
You can build custom workflows and steps. You can also re-use Medusa's workflows and steps, which are provided by the `@medusajs/medusa/core-flows` package.
@@ -6,7 +6,7 @@ export const metadata = {
# {metadata.title}
This document showcases the module links defined between the Store Module and other commerce modules.
This document showcases the module links defined between the Store Module and other Commerce Modules.
## Summary
@@ -14,7 +14,7 @@ Refer to the [Medusa Admin User Guide](!user-guide!/settings/store) to learn how
</Note>
Medusa has store related features available out-of-the-box through the Store Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in commerce modules, such as this Store Module.
Medusa has store related features available out-of-the-box through the Store Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in Commerce Modules, such as this Store Module.
<Note>
@@ -31,7 +31,7 @@ Learn more about why modules are isolated in [this documentation](!docs!/learn/f
## How to Use Store Module's Service
In your Medusa application, you build flows around commerce modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
In your Medusa application, you build flows around Commerce Modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
You can build custom workflows and steps. You can also re-use Medusa's workflows and steps, which are provided by the `@medusajs/medusa/core-flows` package.
@@ -14,7 +14,7 @@ Refer to the [Medusa Admin User Guide](!user-guide!/settings/tax-regions) to lea
</Note>
Medusa has tax related features available out-of-the-box through the Tax Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in commerce modules, such as this Tax Module.
Medusa has tax related features available out-of-the-box through the Tax Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in Commerce Modules, such as this Tax Module.
<Note>
@@ -32,7 +32,7 @@ Learn more about why modules are isolated in [this documentation](!docs!/learn/f
## How to Use Tax Module's Service
In your Medusa application, you build flows around commerce modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
In your Medusa application, you build flows around Commerce Modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
You can build custom workflows and steps. You can also re-use Medusa's workflows and steps, which are provided by the `@medusajs/medusa/core-flows` package.
@@ -14,7 +14,7 @@ Refer to the [Medusa Admin User Guide](!user-guide!/settings/users) to learn how
</Note>
Medusa has user related features available out-of-the-box through the User Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in commerce modules, such as this User Module.
Medusa has user related features available out-of-the-box through the User Module. A [module](!docs!/learn/fundamentals/modules) is a standalone package that provides features for a single domain. Each of Medusa's commerce features are placed in Commerce Modules, such as this User Module.
<Note>
@@ -31,7 +31,7 @@ Learn more about why modules are isolated in [this documentation](!docs!/learn/f
## How to Use User Module's Service
In your Medusa application, you build flows around commerce modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
In your Medusa application, you build flows around Commerce Modules. A flow is built as a [Workflow](!docs!/learn/fundamentals/workflows), which is a special function composed of a series of steps that guarantees data consistency and reliable roll-back mechanism.
You can build custom workflows and steps. You can also re-use Medusa's workflows and steps, which are provided by the `@medusajs/medusa/core-flows` package.
@@ -110,11 +110,11 @@ So, add the following script in `package.json`:
By default, your Medusa application uses modules and providers useful for development, such as the In-Memory Cache Module or the Local File Module Provider. Its highly recommended to instead use modules and providers suitable for production, including:
- [Redis Cache Module](../../../architectural-modules/cache/redis/page.mdx)
- [Redis Event Bus Module](../../../architectural-modules/event/redis/page.mdx)
- [Workflow Engine Redis Module](../../../architectural-modules/workflow-engine/redis/page.mdx)
- [S3 File Module Provider](../../../architectural-modules/file/s3/page.mdx) (or other file module providers production-ready).
- [SendGrid Notification Module Provider](../../../architectural-modules/notification/sendgrid/page.mdx) (or other notification module providers production-ready).
- [Redis Cache Module](../../../infrastructure-modules/cache/redis/page.mdx)
- [Redis Event Bus Module](../../../infrastructure-modules/event/redis/page.mdx)
- [Workflow Engine Redis Module](../../../infrastructure-modules/workflow-engine/redis/page.mdx)
- [S3 File Module Provider](../../../infrastructure-modules/file/s3/page.mdx) (or other file module providers production-ready).
- [SendGrid Notification Module Provider](../../../infrastructure-modules/notification/sendgrid/page.mdx) (or other notification module providers production-ready).
For example, add the following modules to `medusa-config.ts`:
@@ -150,7 +150,7 @@ module.exports = defineConfig({
<Note title="Tip">
Check out the [Integrations](../../../integrations/page.mdx) and [Architectural Modules](../../../architectural-modules/page.mdx) documentation for other modules and providers to use.
Check out the [Integrations](../../../integrations/page.mdx) and [Infrastructure Modules](../../../infrastructure-modules/page.mdx) documentation for other modules and providers to use.
</Note>
@@ -40,7 +40,7 @@ export const metadata = {
In this guide, you'll learn how to add line items with custom prices to a cart in Medusa.
When you install a Medusa application, you get a fully-fledged commerce platform with a Framework for customization. The Medusa application's commerce features are built around [commerce modules](../../../commerce-modules/page.mdx) which are available out-of-the-box. These features include managing carts and adding line items to them.
When you install a Medusa application, you get a fully-fledged commerce platform with a Framework for customization. The Medusa application's commerce features are built around [Commerce Modules](../../../commerce-modules/page.mdx) which are available out-of-the-box. These features include managing carts and adding line items to them.
By default, you can add product variants to the cart, where the price of its associated line item is based on the product variant's price. However, you can build customizations to add line items with custom prices to the cart. This is useful when integrating an Enterprise Resource Planning (ERP), Product Information Management (PIM), or other third-party services that provide real-time prices for your products.
@@ -40,7 +40,7 @@ export const metadata = {
In this guide, you'll learn how to implement quote management in Medusa.
When you install a Medusa application, you get a fully-fledged commerce platform with a Framework for customization. The Medusa application's commerce features are built around [commerce modules](../../../commerce-modules/page.mdx) which are available out-of-the-box.
When you install a Medusa application, you get a fully-fledged commerce platform with a Framework for customization. The Medusa application's commerce features are built around [Commerce Modules](../../../commerce-modules/page.mdx) which are available out-of-the-box.
By default, the Medusa application provides standard commerce features for orders and carts. However, Medusa's customization capabilities facilitate extending existing features to implement quote-management features.
+4 -4
View File
@@ -1694,7 +1694,7 @@ A module link forms an association between two data models of different modules,
### Define a Link
To define a link between your custom module and a commerce module, such as the Product Module:
To define a link between your custom module and a Commerce Module, such as the Product Module:
1. Create the file `src/links/blog-product.ts` with the following content:
@@ -2533,7 +2533,7 @@ const { transaction } = await myLongRunningWorkflow(req.scope)
.run()
```
2. In an API route, workflow, or other resource, change a step's status to successful using the [Worfklow Engine Module](../architectural-modules/workflow-engine/page.mdx):
2. In an API route, workflow, or other resource, change a step's status to successful using the [Worfklow Engine Module](../infrastructure-modules/workflow-engine/page.mdx):
export const stepSuccessHighlights = [
["5", "setStepSuccess", "Change a step's status to success"],
@@ -2561,7 +2561,7 @@ await workflowEngineService.setStepSuccess({
})
```
3. In an API route, workflow, or other resource, change a step's status to failure using the [Worfklow Engine Module](../architectural-modules/workflow-engine/page.mdx):
3. In an API route, workflow, or other resource, change a step's status to failure using the [Worfklow Engine Module](../infrastructure-modules/workflow-engine/page.mdx):
export const stepFailureHighlights = [
["5", "setStepFailure", "Change a step's status to failure"],
@@ -3341,7 +3341,7 @@ npm run test:modules
## Commerce Modules
Medusa provides all its commerce features as separate commerce modules, such as the Product or Order modules.
Medusa provides all its commerce features as separate Commerce Modules, such as the Product or Order modules.
<Note>
@@ -41,9 +41,9 @@ export const metadata = {
In this tutorial, you will learn how to send notifications to customers who have abandoned their carts.
When you install a Medusa application, you get a fully-fledged commerce platform with a Framework for customization. The Medusa application's commerce features are built around [commerce modules](../../../commerce-modules/page.mdx), which are available out-of-the-box. These features include cart-management capabilities.
When you install a Medusa application, you get a fully-fledged commerce platform with a Framework for customization. The Medusa application's commerce features are built around [Commerce Modules](../../../commerce-modules/page.mdx), which are available out-of-the-box. These features include cart-management capabilities.
Medusa's [Notification Module](../../../architectural-modules/notification/page.mdx) allows you to send notifications to users or customers, such as password reset emails, order confirmation SMS, or other types of notifications.
Medusa's [Notification Module](../../../infrastructure-modules/notification/page.mdx) allows you to send notifications to users or customers, such as password reset emails, order confirmation SMS, or other types of notifications.
In this tutorial, you will use the Notification Module to send an email to customers who have abandoned their carts. The email will contain a link to recover the customer's cart, encouraging them to complete their purchase. You will use SendGrid to send the emails, but you can also use other email providers.
@@ -129,9 +129,9 @@ Check out the [troubleshooting guides](../../../troubleshooting/create-medusa-ap
Medusa's Notification Module provides the general functionality to send notifications, but the sending logic is implemented in a module provider. This allows you to integrate the email provider of your choice.
To send the cart-abandonment emails, you will use SendGrid. Medusa provides a [SendGrid Notification Module Provider](../../../architectural-modules/notification/sendgrid/page.mdx) that you can use to send emails.
To send the cart-abandonment emails, you will use SendGrid. Medusa provides a [SendGrid Notification Module Provider](../../../infrastructure-modules/notification/sendgrid/page.mdx) that you can use to send emails.
Alternatively, you can use [other Notification Module Providers](../../../architectural-modules/notification/page.mdx#what-is-a-notification-module-provider) or [create a custom provider](/references/notification-provider-module).
Alternatively, you can use [other Notification Module Providers](../../../infrastructure-modules/notification/page.mdx#what-is-a-notification-module-provider) or [create a custom provider](/references/notification-provider-module).
To set up SendGrid, add the SendGrid Notification Module Provider to `medusa-config.ts`:
@@ -30,7 +30,7 @@ Medusa Cloud provides a beta Store Credits feature that facilitates building a l
</Note>
When you install a Medusa application, you get a fully-fledged commerce platform with a Framework for customization. The Medusa application's commerce features are built around [commerce modules](../../../commerce-modules/page.mdx), which are available out-of-the-box. These features include management capabilities related to carts, orders, promotions, and more.
When you install a Medusa application, you get a fully-fledged commerce platform with a Framework for customization. The Medusa application's commerce features are built around [Commerce Modules](../../../commerce-modules/page.mdx), which are available out-of-the-box. These features include management capabilities related to carts, orders, promotions, and more.
A loyalty point system allows customers to earn points for purchases, which can be redeemed for discounts or rewards. In this tutorial, you'll learn how to customize the Medusa application to implement a loyalty points system.
@@ -40,7 +40,7 @@ export const metadata = {
In this tutorial, you'll learn how to implement product reviews in Medusa.
When you install a Medusa application, you get a fully-fledged commerce platform with a Framework for customization. The Medusa application's commerce features are built around [commerce modules](../../../commerce-modules/page.mdx) which are available out-of-the-box. The features include product-management features.
When you install a Medusa application, you get a fully-fledged commerce platform with a Framework for customization. The Medusa application's commerce features are built around [Commerce Modules](../../../commerce-modules/page.mdx) which are available out-of-the-box. The features include product-management features.
Medusa doesn't provide product reviews out-of-the-box, but the Medusa Framework facilitates implementing customizations like product reviews. In this tutorial, you'll learn how to customize the Medusa server, Admin dashboard, and Next.js Starter Storefront to implement product reviews.
@@ -68,7 +68,7 @@ Medusa provides the following Cache Modules. You can use one of them, or [Create
items={[
{
title: "In-Memory",
href: "/architectural-modules/cache/in-memory",
href: "/infrastructure-modules/cache/in-memory",
badge: {
variant: "neutral",
children: "For Development"
@@ -76,7 +76,7 @@ Medusa provides the following Cache Modules. You can use one of them, or [Create
},
{
title: "Redis",
href: "/architectural-modules/cache/redis",
href: "/infrastructure-modules/cache/redis",
badge: {
variant: "green",
children: "For Production"
@@ -80,7 +80,7 @@ Medusa provides the following Event Modules. You can use one of them, or [Create
items={[
{
title: "Local",
href: "/architectural-modules/event/local",
href: "/infrastructure-modules/event/local",
badge: {
variant: "neutral",
children: "For Development"
@@ -88,7 +88,7 @@ Medusa provides the following Event Modules. You can use one of them, or [Create
},
{
title: "Redis",
href: "/architectural-modules/event/redis",
href: "/infrastructure-modules/event/redis",
badge: {
variant: "green",
children: "For Production"
@@ -78,7 +78,7 @@ This is useful for development. However, for production, its highly recommend
items={[
{
title: "Local",
href: "/architectural-modules/file/local",
href: "/infrastructure-modules/file/local",
badge: {
variant: "neutral",
children: "For Development"
@@ -86,7 +86,7 @@ This is useful for development. However, for production, its highly recommend
},
{
title: "AWS S3 (and Compatible APIs)",
href: "/architectural-modules/file/s3",
href: "/infrastructure-modules/file/s3",
badge: {
variant: "green",
children: "For Production"
@@ -146,7 +146,7 @@ Medusa provides the following Locking Module Providers. You can use one of them,
items={[
{
title: "Redis",
href: "/architectural-modules/locking/redis",
href: "/infrastructure-modules/locking/redis",
badge: {
variant: "green",
children: "Recommended"
@@ -154,7 +154,7 @@ Medusa provides the following Locking Module Providers. You can use one of them,
},
{
title: "PostgreSQL",
href: "/architectural-modules/locking/postgres",
href: "/infrastructure-modules/locking/postgres",
}
]}
/>
@@ -73,7 +73,7 @@ Medusa provides other Notification Modules that actually send notifications, suc
items={[
{
title: "Local",
href: "/architectural-modules/notification/local",
href: "/infrastructure-modules/notification/local",
badge: {
variant: "neutral",
children: "For Development"
@@ -81,7 +81,7 @@ Medusa provides other Notification Modules that actually send notifications, suc
},
{
title: "SendGrid",
href: "/architectural-modules/notification/sendgrid",
href: "/infrastructure-modules/notification/sendgrid",
badge: {
variant: "green",
children: "For Production"
@@ -1,16 +1,16 @@
import { CardList } from "docs-ui"
export const metadata = {
title: `Architectural Modules`,
title: `Infrastructure Modules`,
}
# {metadata.title}
Medusa's architectural functionalities, such as emitting and subscribing to events or caching data, are all implemented in Architectural Modules. An Architectural Module is a package that can be installed and used in any Medusa application. These modules allow you to choose and integrate custom services for architectural purposes.
Medusa's architectural functionalities, such as emitting and subscribing to events or caching data, are all implemented in Infrastructure Modules. An Infrastructure Module is a package that can be installed and used in any Medusa application. These modules allow you to choose and integrate custom services for architectural purposes.
For example, you can use our [Redis Event Module](./event/redis/page.mdx) to handle event functionalities, or create a custom module that implements these functionalities with Memcached. Learn more in [the Architecture documentation](!docs!/learn/introduction/architecture).
This section of the documentation showcases Medusa's Architectural Modules, how they work, and how to use them in your Medusa application.
This section of the documentation showcases Medusa's Infrastructure Modules, how they work, and how to use them in your Medusa application.
## Cache Module
@@ -22,7 +22,7 @@ The following Cache modules are provided by Medusa. You can also create your own
items={[
{
title: "In-Memory",
href: "/architectural-modules/cache/in-memory",
href: "/infrastructure-modules/cache/in-memory",
badge: {
variant: "neutral",
children: "For Development"
@@ -30,7 +30,7 @@ The following Cache modules are provided by Medusa. You can also create your own
},
{
title: "Redis",
href: "/architectural-modules/cache/redis",
href: "/infrastructure-modules/cache/redis",
badge: {
variant: "green",
children: "For Production"
@@ -51,7 +51,7 @@ The following Event modules are provided by Medusa. You can also create your own
items={[
{
title: "Local",
href: "/architectural-modules/event/local",
href: "/infrastructure-modules/event/local",
badge: {
variant: "neutral",
children: "For Development"
@@ -59,7 +59,7 @@ The following Event modules are provided by Medusa. You can also create your own
},
{
title: "Redis",
href: "/architectural-modules/event/redis",
href: "/infrastructure-modules/event/redis",
badge: {
variant: "green",
children: "For Production"
@@ -80,7 +80,7 @@ The File Module has module providers that implement the underlying logic of hand
items={[
{
title: "Local",
href: "/architectural-modules/file/local",
href: "/infrastructure-modules/file/local",
badge: {
variant: "neutral",
children: "For Development"
@@ -88,7 +88,7 @@ The File Module has module providers that implement the underlying logic of hand
},
{
title: "AWS S3 (and Compatible APIs)",
href: "/architectural-modules/file/s3",
href: "/infrastructure-modules/file/s3",
badge: {
variant: "green",
children: "For Production"
@@ -109,7 +109,7 @@ The Locking Module uses module providers that implement the underlying logic of
items={[
{
title: "Redis",
href: "/architectural-modules/locking/redis",
href: "/infrastructure-modules/locking/redis",
badge: {
variant: "green",
children: "Recommended"
@@ -117,7 +117,7 @@ The Locking Module uses module providers that implement the underlying logic of
},
{
title: "PostgreSQL",
href: "/architectural-modules/locking/postgres",
href: "/infrastructure-modules/locking/postgres",
}
]}
/>
@@ -134,7 +134,7 @@ The Notification Module has module providers that implement the underlying logic
items={[
{
title: "Local",
href: "/architectural-modules/notification/local",
href: "/infrastructure-modules/notification/local",
badge: {
variant: "neutral",
children: "For Development"
@@ -142,7 +142,7 @@ The Notification Module has module providers that implement the underlying logic
},
{
title: "SendGrid",
href: "/architectural-modules/notification/sendgrid",
href: "/infrastructure-modules/notification/sendgrid",
badge: {
variant: "green",
children: "For Production"
@@ -157,7 +157,7 @@ The Notification Module has module providers that implement the underlying logic
items={[
{
title: "Send Notification",
href: "/architectural-modules/notification/send-notification"
href: "/infrastructure-modules/notification/send-notification"
},
{
title: "Create Notification Provider",
@@ -186,7 +186,7 @@ The following Workflow Engine modules are provided by Medusa.
items={[
{
title: "In-Memory",
href: "/architectural-modules/workflow-engine/in-memory",
href: "/infrastructure-modules/workflow-engine/in-memory",
badge: {
variant: "neutral",
children: "For Development"
@@ -194,7 +194,7 @@ The following Workflow Engine modules are provided by Medusa.
},
{
title: "Redis",
href: "/architectural-modules/workflow-engine/redis",
href: "/infrastructure-modules/workflow-engine/redis",
badge: {
variant: "green",
children: "For Production"
@@ -74,7 +74,7 @@ Medusa provides the following Workflow Engine Modules.
items={[
{
title: "In-Memory",
href: "/architectural-modules/workflow-engine/in-memory",
href: "/infrastructure-modules/workflow-engine/in-memory",
badge: {
variant: "neutral",
children: "For Development"
@@ -82,7 +82,7 @@ Medusa provides the following Workflow Engine Modules.
},
{
title: "Redis",
href: "/architectural-modules/workflow-engine/redis",
href: "/infrastructure-modules/workflow-engine/redis",
badge: {
variant: "green",
children: "For Production"
@@ -690,7 +690,7 @@ Since you export a `POST` route handler function, you expose an `API` route at `
1. A request object with details and context on the request, such as body parameters or authenticated user details.
2. A response object to manipulate and send the response.
In the route handler, you use the Medusa container that is available in the request object to resolve the [Event Module](../../../architectural-modules/event/page.mdx). This module manages events and their subscribers.
In the route handler, you use the Medusa container that is available in the request object to resolve the [Event Module](../../../infrastructure-modules/event/page.mdx). This module manages events and their subscribers.
Then, you emit the `algolia.sync` event using the Event Module's `emit` method, passing it the event name.
@@ -646,7 +646,7 @@ Where:
<Note title="Tip">
Medusa supports integrating third-party services, such as [S3](../../../architectural-modules/file/s3/page.mdx), in a File Module Provider. Refer to the [File Module](../../../architectural-modules/file/page.mdx) documentation to find other module providers and how to create a custom provider.
Medusa supports integrating third-party services, such as [S3](../../../infrastructure-modules/file/s3/page.mdx), in a File Module Provider. Refer to the [File Module](../../../infrastructure-modules/file/page.mdx) documentation to find other module providers and how to create a custom provider.
</Note>
@@ -1684,9 +1684,9 @@ Earlier in this guide when introducing workflows, you learned that you can track
### Retrieve Sync Executions API Route
Medusa has a [workflow engine](../../../architectural-modules/workflow-engine/page.mdx) that manages workflow executions, roll-backs, and other functionalities under the hood.
Medusa has a [workflow engine](../../../infrastructure-modules/workflow-engine/page.mdx) that manages workflow executions, roll-backs, and other functionalities under the hood.
The workflow engine is an [architectural module](!docs!/learn/fundamentals/modules/architectural-modules), which can be replaced with a [Redis Workflow Engine](../../../architectural-modules/workflow-engine/redis/page.mdx), or a custom one of your choice, allowing you to take ownership of your application's tooling.
The workflow engine is an [Infrastructure Module](!docs!/learn/fundamentals/modules/infrastructure-modules), which can be replaced with a [Redis Workflow Engine](../../../infrastructure-modules/workflow-engine/redis/page.mdx), or a custom one of your choice, allowing you to take ownership of your application's tooling.
In your customizations, you can resolve the workflow engine from the container and manage executions of a workflow, such as retrieve them and check their progress.
+2 -2
View File
@@ -91,7 +91,7 @@ A File Module Provider uploads and manages assets, such as product images, on a
<CardList
items={[
{
href: "/architectural-modules/file/s3",
href: "/infrastructure-modules/file/s3",
title: "AWS S3 (and Compatible APIs)"
}
]}
@@ -131,7 +131,7 @@ A Notification Module Provider sends messages to users and customers in your Med
<CardList
items={[
{
href: "/architectural-modules/notification/sendgrid",
href: "/infrastructure-modules/notification/sendgrid",
title: "SendGrid"
},
{
@@ -132,7 +132,7 @@ Use the `ContainerRegistrationKeys` enum imported from `@medusajs/framework/util
<Table.Cell>
- For custom modules, the registration name is the key of the module in the `modules` configuration in `medusa-config.ts`.
- For Medusa's commerce modules, use the `Modules` enum imported from `@medusajs/framework/utils`.
- For Medusa's Commerce Modules, use the `Modules` enum imported from `@medusajs/framework/utils`.
</Table.Cell>
</Table.Row>
@@ -39,7 +39,7 @@ export const metadata = {
In this guide, you'll learn how to build a wishlist [plugin](!docs!/learn/fundamentals/plugins) in Medusa.
When you install a Medusa application, you get a fully-fledged commerce platform with a Framework for customization. The Medusa application's commerce features are built around [commerce modules](../../../commerce-modules/page.mdx) which are available out-of-the-box.
When you install a Medusa application, you get a fully-fledged commerce platform with a Framework for customization. The Medusa application's commerce features are built around [Commerce Modules](../../../commerce-modules/page.mdx) which are available out-of-the-box.
Customers browsing your store may be interested in a product but not ready to buy it yet. They may want to save the product for later or share it with friends and family. A wishlist feature allows customers to save products they like and access them later.
@@ -396,7 +396,7 @@ The tables of the Wishlist Module's data models are now created in the database.
## Step 5: Link Wishlist Data Models with Core Models
The Wishlist Module's data models store IDs of records in data models implemented in Medusa's core commerce modules, such as the ID of a customer or a product variant.
The Wishlist Module's data models store IDs of records in data models implemented in Medusa's core Commerce Modules, such as the ID of a customer or a product variant.
However, modules are [isolated](!docs!/learn/fundamentals/modules/isolation) to ensure they're re-usable and don't have side effects when integrated into the Medusa application. So, to build associations between modules, you define [module links](!docs!/learn/fundamentals/module-links). A Module link associates two modules' data models while maintaining module isolation.
+1 -1
View File
@@ -18,7 +18,7 @@ Medusa has a ready-to-use B2B starter that you install and use in [this GitHub r
In a B2B store, you provide different types of customers with relevant pricing, products, shopping experience, and more.
Medusas commerce modules, including Sales Channel, Customer, and Pricing modules facilitate implementing this setup. Medusas architecture and extendible nature allow you to customize your store based on your use case.
Medusas Commerce Modules, including Sales Channel, Customer, and Pricing modules facilitate implementing this setup. Medusas architecture and extendible nature allow you to customize your store based on your use case.
<Note title="Related use-case">
@@ -37,7 +37,7 @@ You can use the Notification Module to send notifications when an action is trig
<Note title="Tip">
The [Events reference](../../events-reference/page.mdx) shows an extensive list of events triggered for each commerce module.
The [Events reference](../../events-reference/page.mdx) shows an extensive list of events triggered for each Commerce Module.
</Note>
@@ -45,7 +45,7 @@ Medusa also provides Notification Module Providers that integrate with third-par
<CardList items={[
{
href: "/architectural-modules/notification",
href: "/infrastructure-modules/notification",
title: "Notification Module",
text: "Learn about the Notification Module.",
icon: AcademicCapSolid,
@@ -94,7 +94,7 @@ To handle events within an order flow and automate actions, create a subscriber.
{
href: "/events-reference",
title: "Events Reference",
text: "Check out triggered events by each commerce module.",
text: "Check out triggered events by each Commerce Module.",
icon: AcademicCapSolid,
},
]} />
@@ -132,7 +132,7 @@ Medusa's commerce features are geared towards automating RMA flows and ensuring
Businesses use customer segmentation to organize customers into different groups and then apply different price rules to these groups.
Medusa's commerce modules provide the necessary features to implement this use case:
Medusa's Commerce Modules provide the necessary features to implement this use case:
- The Customer Module provides a customer groups feature to organize customers into customer groups.
- The Pricing Module provides the features to specify prices based on a condition, such as the group of the customer.
@@ -164,7 +164,7 @@ For example, to group customers with over twenty orders:
{
href: "/events-reference",
title: "Events Reference",
text: "Check out triggered events by each commerce module.",
text: "Check out triggered events by each Commerce Module.",
icon: AcademicCapSolid,
},
]} />

Some files were not shown because too many files have changed in this diff Show More