docs: sort events in reference alphabetically (#12845)

This commit is contained in:
Shahed Nasser
2025-06-27 11:56:36 +03:00
committed by GitHub
parent f614d86332
commit fcfd35a157
7 changed files with 2084 additions and 2081 deletions
File diff suppressed because it is too large Load Diff
+4 -4
View File
@@ -6198,16 +6198,16 @@ export const generatedEditDates = {
"app/commerce-modules/product/guides/variant-inventory/page.mdx": "2025-04-25T14:22:42.329Z",
"app/troubleshooting/validation-error/page.mdx": "2025-04-25T14:14:57.568Z",
"app/integrations/guides/contentful/page.mdx": "2025-06-26T11:55:43.353Z",
"references/modules/events/page.mdx": "2025-06-05T19:05:53.162Z",
"references/modules/events/page.mdx": "2025-06-27T07:31:07.646Z",
"references/module_events/module_events.Auth/page.mdx": "2025-05-20T07:51:40.956Z",
"references/module_events/module_events.Cart/page.mdx": "2025-05-20T07:51:40.956Z",
"references/module_events/module_events.Customer/page.mdx": "2025-05-20T07:51:40.956Z",
"references/module_events/module_events.Fulfillment/page.mdx": "2025-05-20T07:51:40.956Z",
"references/module_events/module_events.Order/page.mdx": "2025-06-05T19:05:53.210Z",
"references/module_events/module_events.Product/page.mdx": "2025-05-20T07:51:40.957Z",
"references/module_events/module_events.Order/page.mdx": "2025-06-27T07:31:07.670Z",
"references/module_events/module_events.Product/page.mdx": "2025-06-27T07:31:07.672Z",
"references/module_events/module_events.Region/page.mdx": "2025-05-20T07:51:40.957Z",
"references/module_events/module_events.Sales_Channel/page.mdx": "2025-05-20T07:51:40.957Z",
"references/module_events/module_events.User/page.mdx": "2025-05-20T07:51:40.957Z",
"references/module_events/module_events.User/page.mdx": "2025-06-27T07:31:07.671Z",
"references/modules/module_events/page.mdx": "2025-06-05T19:05:53.207Z",
"app/troubleshooting/medusa-admin/build-error/page.mdx": "2025-05-20T07:51:40.724Z",
"references/events/Auth/variables/events.Auth.AuthWorkflowEvents/page.mdx": "2025-05-20T07:51:40.894Z",
@@ -10,7 +10,140 @@ import { TypeList } from "docs-ui"
This reference shows all the events emitted by the Medusa application related to the Order Module. If you use the module outside the Medusa application, these events aren't emitted.
## Order Events
## Order Edit Events
### Summary
<Table>
<Table.Header>
<Table.Row>
<Table.HeaderCell>
Event
</Table.HeaderCell>
<Table.HeaderCell>
Description
</Table.HeaderCell>
</Table.Row>
</Table.Header>
<Table.Body>
<Table.Row>
<Table.Cell>
[order-edit.requested](#order-editrequested)
<Tooltip text="This event was added in version v2.8.0"><Badge variant="blue">v2.8.0</Badge></Tooltip>
</Table.Cell>
<Table.Cell>
Emitted when an order edit is requested.
</Table.Cell>
</Table.Row>
<Table.Row>
<Table.Cell>
[order-edit.confirmed](#order-editconfirmed)
<Tooltip text="This event was added in version v2.8.0"><Badge variant="blue">v2.8.0</Badge></Tooltip>
</Table.Cell>
<Table.Cell>
Emitted when an order edit request is confirmed.
</Table.Cell>
</Table.Row>
<Table.Row>
<Table.Cell>
[order-edit.canceled](#order-editcanceled)
<Tooltip text="This event was added in version v2.8.0"><Badge variant="blue">v2.8.0</Badge></Tooltip>
</Table.Cell>
<Table.Cell>
Emitted when an order edit request is canceled.
</Table.Cell>
</Table.Row>
</Table.Body>
</Table>
<EventHeader headerLvl="3" headerProps={{ id: "order-editrequested", children: (<>order-edit.requested
<Tooltip text="This event was added in version v2.8.0">
<Badge variant="blue">v2.8.0</Badge>
</Tooltip></>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="order-edit.requested" payload={`\`\`\`ts
{
order_id, // The ID of the order
actions, // (array) The [actions](https://docs.medusajs.com/resources/references/fulfillment/interfaces/fulfillment.OrderChangeActionDTO) to edit the order
}
\`\`\``} />
Emitted when an order edit is requested.
#### Payload
```ts
{
order_id, // The ID of the order
actions, // (array) The [actions](https://docs.medusajs.com/resources/references/fulfillment/interfaces/fulfillment.OrderChangeActionDTO) to edit the order
}
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [requestOrderEditRequestWorkflow](/references/medusa-workflows/requestOrderEditRequestWorkflow)
---
<EventHeader headerLvl="3" headerProps={{ id: "order-editconfirmed", children: (<>order-edit.confirmed
<Tooltip text="This event was added in version v2.8.0">
<Badge variant="blue">v2.8.0</Badge>
</Tooltip></>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="order-edit.confirmed" payload={`\`\`\`ts
{
order_id, // The ID of the order
actions, // (array) The [actions](https://docs.medusajs.com/resources/references/fulfillment/interfaces/fulfillment.OrderChangeActionDTO) to edit the order
}
\`\`\``} />
Emitted when an order edit request is confirmed.
#### Payload
```ts
{
order_id, // The ID of the order
actions, // (array) The [actions](https://docs.medusajs.com/resources/references/fulfillment/interfaces/fulfillment.OrderChangeActionDTO) to edit the order
}
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [confirmOrderEditRequestWorkflow](/references/medusa-workflows/confirmOrderEditRequestWorkflow)
---
<EventHeader headerLvl="3" headerProps={{ id: "order-editcanceled", children: (<>order-edit.canceled
<Tooltip text="This event was added in version v2.8.0">
<Badge variant="blue">v2.8.0</Badge>
</Tooltip></>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="order-edit.canceled" payload={`\`\`\`ts
{
order_id, // The ID of the order
actions, // (array) The [actions](https://docs.medusajs.com/resources/references/fulfillment/interfaces/fulfillment.OrderChangeActionDTO) to edit the order
}
\`\`\``} />
Emitted when an order edit request is canceled.
#### Payload
```ts
{
order_id, // The ID of the order
actions, // (array) The [actions](https://docs.medusajs.com/resources/references/fulfillment/interfaces/fulfillment.OrderChangeActionDTO) to edit the order
}
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [cancelBeginOrderEditWorkflow](/references/medusa-workflows/cancelBeginOrderEditWorkflow)
---
## Order Events
### Summary
@@ -438,136 +571,3 @@ another customer.
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [requestOrderTransferWorkflow](/references/medusa-workflows/requestOrderTransferWorkflow)
---
## Order Edit Events
### Summary
<Table>
<Table.Header>
<Table.Row>
<Table.HeaderCell>
Event
</Table.HeaderCell>
<Table.HeaderCell>
Description
</Table.HeaderCell>
</Table.Row>
</Table.Header>
<Table.Body>
<Table.Row>
<Table.Cell>
[order-edit.requested](#order-editrequested)
<Tooltip text="This event was added in version v2.8.0"><Badge variant="blue">v2.8.0</Badge></Tooltip>
</Table.Cell>
<Table.Cell>
Emitted when an order edit is requested.
</Table.Cell>
</Table.Row>
<Table.Row>
<Table.Cell>
[order-edit.confirmed](#order-editconfirmed)
<Tooltip text="This event was added in version v2.8.0"><Badge variant="blue">v2.8.0</Badge></Tooltip>
</Table.Cell>
<Table.Cell>
Emitted when an order edit request is confirmed.
</Table.Cell>
</Table.Row>
<Table.Row>
<Table.Cell>
[order-edit.canceled](#order-editcanceled)
<Tooltip text="This event was added in version v2.8.0"><Badge variant="blue">v2.8.0</Badge></Tooltip>
</Table.Cell>
<Table.Cell>
Emitted when an order edit request is canceled.
</Table.Cell>
</Table.Row>
</Table.Body>
</Table>
<EventHeader headerLvl="3" headerProps={{ id: "order-editrequested", children: (<>order-edit.requested
<Tooltip text="This event was added in version v2.8.0">
<Badge variant="blue">v2.8.0</Badge>
</Tooltip></>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="order-edit.requested" payload={`\`\`\`ts
{
order_id, // The ID of the order
actions, // (array) The [actions](https://docs.medusajs.com/resources/references/fulfillment/interfaces/fulfillment.OrderChangeActionDTO) to edit the order
}
\`\`\``} />
Emitted when an order edit is requested.
#### Payload
```ts
{
order_id, // The ID of the order
actions, // (array) The [actions](https://docs.medusajs.com/resources/references/fulfillment/interfaces/fulfillment.OrderChangeActionDTO) to edit the order
}
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [requestOrderEditRequestWorkflow](/references/medusa-workflows/requestOrderEditRequestWorkflow)
---
<EventHeader headerLvl="3" headerProps={{ id: "order-editconfirmed", children: (<>order-edit.confirmed
<Tooltip text="This event was added in version v2.8.0">
<Badge variant="blue">v2.8.0</Badge>
</Tooltip></>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="order-edit.confirmed" payload={`\`\`\`ts
{
order_id, // The ID of the order
actions, // (array) The [actions](https://docs.medusajs.com/resources/references/fulfillment/interfaces/fulfillment.OrderChangeActionDTO) to edit the order
}
\`\`\``} />
Emitted when an order edit request is confirmed.
#### Payload
```ts
{
order_id, // The ID of the order
actions, // (array) The [actions](https://docs.medusajs.com/resources/references/fulfillment/interfaces/fulfillment.OrderChangeActionDTO) to edit the order
}
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [confirmOrderEditRequestWorkflow](/references/medusa-workflows/confirmOrderEditRequestWorkflow)
---
<EventHeader headerLvl="3" headerProps={{ id: "order-editcanceled", children: (<>order-edit.canceled
<Tooltip text="This event was added in version v2.8.0">
<Badge variant="blue">v2.8.0</Badge>
</Tooltip></>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="order-edit.canceled" payload={`\`\`\`ts
{
order_id, // The ID of the order
actions, // (array) The [actions](https://docs.medusajs.com/resources/references/fulfillment/interfaces/fulfillment.OrderChangeActionDTO) to edit the order
}
\`\`\``} />
Emitted when an order edit request is canceled.
#### Payload
```ts
{
order_id, // The ID of the order
actions, // (array) The [actions](https://docs.medusajs.com/resources/references/fulfillment/interfaces/fulfillment.OrderChangeActionDTO) to edit the order
}
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [cancelBeginOrderEditWorkflow](/references/medusa-workflows/cancelBeginOrderEditWorkflow)
@@ -10,7 +10,7 @@ import { TypeList } from "docs-ui"
This reference shows all the events emitted by the Medusa application related to the Product Module. If you use the module outside the Medusa application, these events aren't emitted.
## Product Category Events
## Product Category Events
### Summary
@@ -125,7 +125,7 @@ The following workflows emit this event when they're executed. These workflows a
---
## Product Collection Events
## Product Collection Events
### Summary
@@ -240,7 +240,352 @@ The following workflows emit this event when they're executed. These workflows a
---
## Product Variant Events
## Product Option Events
### Summary
<Table>
<Table.Header>
<Table.Row>
<Table.HeaderCell>
Event
</Table.HeaderCell>
<Table.HeaderCell>
Description
</Table.HeaderCell>
</Table.Row>
</Table.Header>
<Table.Body>
<Table.Row>
<Table.Cell>
[product-option.updated](#product-optionupdated)
</Table.Cell>
<Table.Cell>
Emitted when product options are updated.
</Table.Cell>
</Table.Row>
<Table.Row>
<Table.Cell>
[product-option.created](#product-optioncreated)
</Table.Cell>
<Table.Cell>
Emitted when product options are created.
</Table.Cell>
</Table.Row>
<Table.Row>
<Table.Cell>
[product-option.deleted](#product-optiondeleted)
</Table.Cell>
<Table.Cell>
Emitted when product options are deleted.
</Table.Cell>
</Table.Row>
</Table.Body>
</Table>
<EventHeader headerLvl="3" headerProps={{ id: "product-optionupdated", children: (<>product-option.updated</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="product-option.updated" payload={`\`\`\`ts
[{
id, // The ID of the product option
}]
\`\`\``} />
Emitted when product options are updated.
#### Payload
```ts
[{
id, // The ID of the product option
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [updateProductOptionsWorkflow](/references/medusa-workflows/updateProductOptionsWorkflow)
---
<EventHeader headerLvl="3" headerProps={{ id: "product-optioncreated", children: (<>product-option.created</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="product-option.created" payload={`\`\`\`ts
[{
id, // The ID of the product option
}]
\`\`\``} />
Emitted when product options are created.
#### Payload
```ts
[{
id, // The ID of the product option
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [createProductOptionsWorkflow](/references/medusa-workflows/createProductOptionsWorkflow)
---
<EventHeader headerLvl="3" headerProps={{ id: "product-optiondeleted", children: (<>product-option.deleted</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="product-option.deleted" payload={`\`\`\`ts
[{
id, // The ID of the product option
}]
\`\`\``} />
Emitted when product options are deleted.
#### Payload
```ts
[{
id, // The ID of the product option
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [deleteProductOptionsWorkflow](/references/medusa-workflows/deleteProductOptionsWorkflow)
---
## Product Tag Events
### Summary
<Table>
<Table.Header>
<Table.Row>
<Table.HeaderCell>
Event
</Table.HeaderCell>
<Table.HeaderCell>
Description
</Table.HeaderCell>
</Table.Row>
</Table.Header>
<Table.Body>
<Table.Row>
<Table.Cell>
[product-tag.updated](#product-tagupdated)
</Table.Cell>
<Table.Cell>
Emitted when product tags are updated.
</Table.Cell>
</Table.Row>
<Table.Row>
<Table.Cell>
[product-tag.created](#product-tagcreated)
</Table.Cell>
<Table.Cell>
Emitted when product tags are created.
</Table.Cell>
</Table.Row>
<Table.Row>
<Table.Cell>
[product-tag.deleted](#product-tagdeleted)
</Table.Cell>
<Table.Cell>
Emitted when product tags are deleted.
</Table.Cell>
</Table.Row>
</Table.Body>
</Table>
<EventHeader headerLvl="3" headerProps={{ id: "product-tagupdated", children: (<>product-tag.updated</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="product-tag.updated" payload={`\`\`\`ts
[{
id, // The ID of the product tag
}]
\`\`\``} />
Emitted when product tags are updated.
#### Payload
```ts
[{
id, // The ID of the product tag
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [updateProductTagsWorkflow](/references/medusa-workflows/updateProductTagsWorkflow)
---
<EventHeader headerLvl="3" headerProps={{ id: "product-tagcreated", children: (<>product-tag.created</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="product-tag.created" payload={`\`\`\`ts
[{
id, // The ID of the product tag
}]
\`\`\``} />
Emitted when product tags are created.
#### Payload
```ts
[{
id, // The ID of the product tag
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [createProductTagsWorkflow](/references/medusa-workflows/createProductTagsWorkflow)
---
<EventHeader headerLvl="3" headerProps={{ id: "product-tagdeleted", children: (<>product-tag.deleted</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="product-tag.deleted" payload={`\`\`\`ts
[{
id, // The ID of the product tag
}]
\`\`\``} />
Emitted when product tags are deleted.
#### Payload
```ts
[{
id, // The ID of the product tag
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [deleteProductTagsWorkflow](/references/medusa-workflows/deleteProductTagsWorkflow)
---
## Product Type Events
### Summary
<Table>
<Table.Header>
<Table.Row>
<Table.HeaderCell>
Event
</Table.HeaderCell>
<Table.HeaderCell>
Description
</Table.HeaderCell>
</Table.Row>
</Table.Header>
<Table.Body>
<Table.Row>
<Table.Cell>
[product-type.updated](#product-typeupdated)
</Table.Cell>
<Table.Cell>
Emitted when product types are updated.
</Table.Cell>
</Table.Row>
<Table.Row>
<Table.Cell>
[product-type.created](#product-typecreated)
</Table.Cell>
<Table.Cell>
Emitted when product types are created.
</Table.Cell>
</Table.Row>
<Table.Row>
<Table.Cell>
[product-type.deleted](#product-typedeleted)
</Table.Cell>
<Table.Cell>
Emitted when product types are deleted.
</Table.Cell>
</Table.Row>
</Table.Body>
</Table>
<EventHeader headerLvl="3" headerProps={{ id: "product-typeupdated", children: (<>product-type.updated</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="product-type.updated" payload={`\`\`\`ts
[{
id, // The ID of the product type
}]
\`\`\``} />
Emitted when product types are updated.
#### Payload
```ts
[{
id, // The ID of the product type
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [updateProductTypesWorkflow](/references/medusa-workflows/updateProductTypesWorkflow)
---
<EventHeader headerLvl="3" headerProps={{ id: "product-typecreated", children: (<>product-type.created</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="product-type.created" payload={`\`\`\`ts
[{
id, // The ID of the product type
}]
\`\`\``} />
Emitted when product types are created.
#### Payload
```ts
[{
id, // The ID of the product type
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [createProductTypesWorkflow](/references/medusa-workflows/createProductTypesWorkflow)
---
<EventHeader headerLvl="3" headerProps={{ id: "product-typedeleted", children: (<>product-type.deleted</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="product-type.deleted" payload={`\`\`\`ts
[{
id, // The ID of the product type
}]
\`\`\``} />
Emitted when product types are deleted.
#### Payload
```ts
[{
id, // The ID of the product type
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [deleteProductTypesWorkflow](/references/medusa-workflows/deleteProductTypesWorkflow)
---
## Product Variant Events
### Summary
@@ -361,7 +706,7 @@ The following workflows emit this event when they're executed. These workflows a
---
## Product Events
## Product Events
### Summary
@@ -479,348 +824,3 @@ The following workflows emit this event when they're executed. These workflows a
- [deleteProductsWorkflow](/references/medusa-workflows/deleteProductsWorkflow)
- [batchProductsWorkflow](/references/medusa-workflows/batchProductsWorkflow)
- [importProductsWorkflow](/references/medusa-workflows/importProductsWorkflow)
---
## Product Type Events
### Summary
<Table>
<Table.Header>
<Table.Row>
<Table.HeaderCell>
Event
</Table.HeaderCell>
<Table.HeaderCell>
Description
</Table.HeaderCell>
</Table.Row>
</Table.Header>
<Table.Body>
<Table.Row>
<Table.Cell>
[product-type.updated](#product-typeupdated)
</Table.Cell>
<Table.Cell>
Emitted when product types are updated.
</Table.Cell>
</Table.Row>
<Table.Row>
<Table.Cell>
[product-type.created](#product-typecreated)
</Table.Cell>
<Table.Cell>
Emitted when product types are created.
</Table.Cell>
</Table.Row>
<Table.Row>
<Table.Cell>
[product-type.deleted](#product-typedeleted)
</Table.Cell>
<Table.Cell>
Emitted when product types are deleted.
</Table.Cell>
</Table.Row>
</Table.Body>
</Table>
<EventHeader headerLvl="3" headerProps={{ id: "product-typeupdated", children: (<>product-type.updated</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="product-type.updated" payload={`\`\`\`ts
[{
id, // The ID of the product type
}]
\`\`\``} />
Emitted when product types are updated.
#### Payload
```ts
[{
id, // The ID of the product type
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [updateProductTypesWorkflow](/references/medusa-workflows/updateProductTypesWorkflow)
---
<EventHeader headerLvl="3" headerProps={{ id: "product-typecreated", children: (<>product-type.created</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="product-type.created" payload={`\`\`\`ts
[{
id, // The ID of the product type
}]
\`\`\``} />
Emitted when product types are created.
#### Payload
```ts
[{
id, // The ID of the product type
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [createProductTypesWorkflow](/references/medusa-workflows/createProductTypesWorkflow)
---
<EventHeader headerLvl="3" headerProps={{ id: "product-typedeleted", children: (<>product-type.deleted</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="product-type.deleted" payload={`\`\`\`ts
[{
id, // The ID of the product type
}]
\`\`\``} />
Emitted when product types are deleted.
#### Payload
```ts
[{
id, // The ID of the product type
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [deleteProductTypesWorkflow](/references/medusa-workflows/deleteProductTypesWorkflow)
---
## Product Tag Events
### Summary
<Table>
<Table.Header>
<Table.Row>
<Table.HeaderCell>
Event
</Table.HeaderCell>
<Table.HeaderCell>
Description
</Table.HeaderCell>
</Table.Row>
</Table.Header>
<Table.Body>
<Table.Row>
<Table.Cell>
[product-tag.updated](#product-tagupdated)
</Table.Cell>
<Table.Cell>
Emitted when product tags are updated.
</Table.Cell>
</Table.Row>
<Table.Row>
<Table.Cell>
[product-tag.created](#product-tagcreated)
</Table.Cell>
<Table.Cell>
Emitted when product tags are created.
</Table.Cell>
</Table.Row>
<Table.Row>
<Table.Cell>
[product-tag.deleted](#product-tagdeleted)
</Table.Cell>
<Table.Cell>
Emitted when product tags are deleted.
</Table.Cell>
</Table.Row>
</Table.Body>
</Table>
<EventHeader headerLvl="3" headerProps={{ id: "product-tagupdated", children: (<>product-tag.updated</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="product-tag.updated" payload={`\`\`\`ts
[{
id, // The ID of the product tag
}]
\`\`\``} />
Emitted when product tags are updated.
#### Payload
```ts
[{
id, // The ID of the product tag
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [updateProductTagsWorkflow](/references/medusa-workflows/updateProductTagsWorkflow)
---
<EventHeader headerLvl="3" headerProps={{ id: "product-tagcreated", children: (<>product-tag.created</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="product-tag.created" payload={`\`\`\`ts
[{
id, // The ID of the product tag
}]
\`\`\``} />
Emitted when product tags are created.
#### Payload
```ts
[{
id, // The ID of the product tag
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [createProductTagsWorkflow](/references/medusa-workflows/createProductTagsWorkflow)
---
<EventHeader headerLvl="3" headerProps={{ id: "product-tagdeleted", children: (<>product-tag.deleted</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="product-tag.deleted" payload={`\`\`\`ts
[{
id, // The ID of the product tag
}]
\`\`\``} />
Emitted when product tags are deleted.
#### Payload
```ts
[{
id, // The ID of the product tag
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [deleteProductTagsWorkflow](/references/medusa-workflows/deleteProductTagsWorkflow)
---
## Product Option Events
### Summary
<Table>
<Table.Header>
<Table.Row>
<Table.HeaderCell>
Event
</Table.HeaderCell>
<Table.HeaderCell>
Description
</Table.HeaderCell>
</Table.Row>
</Table.Header>
<Table.Body>
<Table.Row>
<Table.Cell>
[product-option.updated](#product-optionupdated)
</Table.Cell>
<Table.Cell>
Emitted when product options are updated.
</Table.Cell>
</Table.Row>
<Table.Row>
<Table.Cell>
[product-option.created](#product-optioncreated)
</Table.Cell>
<Table.Cell>
Emitted when product options are created.
</Table.Cell>
</Table.Row>
<Table.Row>
<Table.Cell>
[product-option.deleted](#product-optiondeleted)
</Table.Cell>
<Table.Cell>
Emitted when product options are deleted.
</Table.Cell>
</Table.Row>
</Table.Body>
</Table>
<EventHeader headerLvl="3" headerProps={{ id: "product-optionupdated", children: (<>product-option.updated</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="product-option.updated" payload={`\`\`\`ts
[{
id, // The ID of the product option
}]
\`\`\``} />
Emitted when product options are updated.
#### Payload
```ts
[{
id, // The ID of the product option
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [updateProductOptionsWorkflow](/references/medusa-workflows/updateProductOptionsWorkflow)
---
<EventHeader headerLvl="3" headerProps={{ id: "product-optioncreated", children: (<>product-option.created</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="product-option.created" payload={`\`\`\`ts
[{
id, // The ID of the product option
}]
\`\`\``} />
Emitted when product options are created.
#### Payload
```ts
[{
id, // The ID of the product option
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [createProductOptionsWorkflow](/references/medusa-workflows/createProductOptionsWorkflow)
---
<EventHeader headerLvl="3" headerProps={{ id: "product-optiondeleted", children: (<>product-option.deleted</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="product-option.deleted" payload={`\`\`\`ts
[{
id, // The ID of the product option
}]
\`\`\``} />
Emitted when product options are deleted.
#### Payload
```ts
[{
id, // The ID of the product option
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [deleteProductOptionsWorkflow](/references/medusa-workflows/deleteProductOptionsWorkflow)
@@ -10,125 +10,7 @@ import { TypeList } from "docs-ui"
This reference shows all the events emitted by the Medusa application related to the User Module. If you use the module outside the Medusa application, these events aren't emitted.
## User Events
### Summary
<Table>
<Table.Header>
<Table.Row>
<Table.HeaderCell>
Event
</Table.HeaderCell>
<Table.HeaderCell>
Description
</Table.HeaderCell>
</Table.Row>
</Table.Header>
<Table.Body>
<Table.Row>
<Table.Cell>
[user.created](#usercreated)
</Table.Cell>
<Table.Cell>
Emitted when users are created.
</Table.Cell>
</Table.Row>
<Table.Row>
<Table.Cell>
[user.updated](#userupdated)
</Table.Cell>
<Table.Cell>
Emitted when users are updated.
</Table.Cell>
</Table.Row>
<Table.Row>
<Table.Cell>
[user.deleted](#userdeleted)
</Table.Cell>
<Table.Cell>
Emitted when users are deleted.
</Table.Cell>
</Table.Row>
</Table.Body>
</Table>
<EventHeader headerLvl="3" headerProps={{ id: "usercreated", children: (<>user.created</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="user.created" payload={`\`\`\`ts
[{
id, // The ID of the user
}]
\`\`\``} />
Emitted when users are created.
#### Payload
```ts
[{
id, // The ID of the user
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [createUsersWorkflow](/references/medusa-workflows/createUsersWorkflow)
- [createUserAccountWorkflow](/references/medusa-workflows/createUserAccountWorkflow)
- [acceptInviteWorkflow](/references/medusa-workflows/acceptInviteWorkflow)
---
<EventHeader headerLvl="3" headerProps={{ id: "userupdated", children: (<>user.updated</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="user.updated" payload={`\`\`\`ts
[{
id, // The ID of the user
}]
\`\`\``} />
Emitted when users are updated.
#### Payload
```ts
[{
id, // The ID of the user
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [updateUsersWorkflow](/references/medusa-workflows/updateUsersWorkflow)
---
<EventHeader headerLvl="3" headerProps={{ id: "userdeleted", children: (<>user.deleted</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="user.deleted" payload={`\`\`\`ts
[{
id, // The ID of the user
}]
\`\`\``} />
Emitted when users are deleted.
#### Payload
```ts
[{
id, // The ID of the user
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [deleteUsersWorkflow](/references/medusa-workflows/deleteUsersWorkflow)
- [removeUserAccountWorkflow](/references/medusa-workflows/removeUserAccountWorkflow)
---
## Invite Events
## Invite Events
### Summary
@@ -278,3 +160,121 @@ for example.
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [refreshInviteTokensWorkflow](/references/medusa-workflows/refreshInviteTokensWorkflow)
---
## User Events
### Summary
<Table>
<Table.Header>
<Table.Row>
<Table.HeaderCell>
Event
</Table.HeaderCell>
<Table.HeaderCell>
Description
</Table.HeaderCell>
</Table.Row>
</Table.Header>
<Table.Body>
<Table.Row>
<Table.Cell>
[user.created](#usercreated)
</Table.Cell>
<Table.Cell>
Emitted when users are created.
</Table.Cell>
</Table.Row>
<Table.Row>
<Table.Cell>
[user.updated](#userupdated)
</Table.Cell>
<Table.Cell>
Emitted when users are updated.
</Table.Cell>
</Table.Row>
<Table.Row>
<Table.Cell>
[user.deleted](#userdeleted)
</Table.Cell>
<Table.Cell>
Emitted when users are deleted.
</Table.Cell>
</Table.Row>
</Table.Body>
</Table>
<EventHeader headerLvl="3" headerProps={{ id: "usercreated", children: (<>user.created</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="user.created" payload={`\`\`\`ts
[{
id, // The ID of the user
}]
\`\`\``} />
Emitted when users are created.
#### Payload
```ts
[{
id, // The ID of the user
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [createUsersWorkflow](/references/medusa-workflows/createUsersWorkflow)
- [createUserAccountWorkflow](/references/medusa-workflows/createUserAccountWorkflow)
- [acceptInviteWorkflow](/references/medusa-workflows/acceptInviteWorkflow)
---
<EventHeader headerLvl="3" headerProps={{ id: "userupdated", children: (<>user.updated</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="user.updated" payload={`\`\`\`ts
[{
id, // The ID of the user
}]
\`\`\``} />
Emitted when users are updated.
#### Payload
```ts
[{
id, // The ID of the user
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [updateUsersWorkflow](/references/medusa-workflows/updateUsersWorkflow)
---
<EventHeader headerLvl="3" headerProps={{ id: "userdeleted", children: (<>user.deleted</>), className: "flex flex-wrap justify-center gap-docs_0.25" }} eventName="user.deleted" payload={`\`\`\`ts
[{
id, // The ID of the user
}]
\`\`\``} />
Emitted when users are deleted.
#### Payload
```ts
[{
id, // The ID of the user
}]
```
#### Workflows Emitting this Event
The following workflows emit this event when they're executed. These workflows are executed by Medusa's API routes. You can also view the events emitted by API routes in the [Store](https://docs.medusajs.com/api/store) and [Admin](https://docs.medusajs.com/api/admin) API references.
- [deleteUsersWorkflow](/references/medusa-workflows/deleteUsersWorkflow)
- [removeUserAccountWorkflow](/references/medusa-workflows/removeUserAccountWorkflow)
File diff suppressed because it is too large Load Diff
@@ -1,7 +1,6 @@
import Handlebars from "handlebars"
import pkg from "slugify"
import { DeclarationReflection, ReflectionKind } from "typedoc"
import { pascalToWords } from "utils"
const slugify = pkg.default
@@ -35,16 +34,12 @@ export default function () {
}
if (this.kind === ReflectionKind.Module) {
this.children?.forEach((child, index) => {
const count = parseChildren(child.children || [])
if (count > 0 && index < this.children!.length - 1) {
content.push("")
content.push("---")
content.push("")
}
})
const sortedChildren = sortChildren(
this.children?.map((child) => child.children || []).flat() || []
)
parseChildren(sortedChildren)
} else {
parseChildren(this.children || [])
parseChildren(sortChildren(this.children || []))
}
return content.join("\n")
@@ -67,9 +62,11 @@ function formatEventsType(
}
const content: string[] = []
const subHeaderPrefix = "#".repeat(subtitleLevel)
const header = pascalToWords(
eventVariable.name.replaceAll("WorkflowEvents", "")
)
const header =
eventVariable.comment?.blockTags
.find((tag) => tag.tag === "@category")
?.content.map((content) => content.text)
.join("") || ""
if (showHeader) {
content.push(`${"#".repeat(subtitleLevel - 1)} ${header} Events`)
}
@@ -268,3 +265,9 @@ function getEventWorkflows(event: DeclarationReflection): string[] | undefined {
.join("")
.split(", ")
}
function sortChildren(ref: DeclarationReflection[]) {
return ref.sort((a, b) => {
return a.name.localeCompare(b.name)
})
}