chore(docs): Generated References (automated) (#12942)

Co-authored-by: shahednasser <shahednasser@users.noreply.github.com>
Co-authored-by: Shahed Nasser <shahednasser@gmail.com>
This commit is contained in:
authored and GitHub committed 2025-07-14 14:39:48 +03:00
1 parent c3ee84d1c1
commit 1503ba999f
486 files changed
+211783 -211195

No files matched your search

@@ -86,6 +86,12 @@ It sends a request to the
[Confirm Product Import](https://docs.medusajs.com/api/admin#products\_postproductsimporttransaction\_idconfirm)
API route.
:::note
This is only available after Medusa `v2.8.5`.
:::
### Example
```ts
@@ -158,7 +158,7 @@ sdk.admin.promotion.update("promo_123", {
### Parameters
<TypeList types={[{"name":"id","type":"`string`","description":"The promotion's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"payload","type":"[AdminUpdatePromotion](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminUpdatePromotion/page.mdx)","description":"The details to update in the promotion.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"code","type":"`string`","description":"The promotion's code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_automatic","type":"`boolean`","description":"Whether the promotion is applied automatically\nor requires the customer to manually apply it\nby entering the code at checkout.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"type","type":"[PromotionTypeValues](../../../../../promotion/types/promotion.PromotionTypeValues/page.mdx)","description":"The type of promotion.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"status","type":"[PromotionStatusValues](../../../../../promotion/types/promotion.PromotionStatusValues/page.mdx)","description":"The status of the promotion.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"campaign_id","type":"`null` \\| `string`","description":"The ID of the campaign that the promotion belongs to.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"campaign","type":"[AdminCreateCampaign](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminCreateCampaign/page.mdx)","description":"The campaign that the promotion belongs to.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"name","type":"`string`","description":"The campaign's name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"description","type":"`string`","description":"The campaign's description.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"currency","type":"`null` \\| `string`","description":"The campaign's currency code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"campaign_identifier","type":"`string`","description":"The campaign's identifier.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"starts_at","type":"`null` \\| `Date`","description":"The date the campaign and its promotions start at.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"ends_at","type":"`null` \\| `Date`","description":"The date the campaign and its promotions end at.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"budget","type":"`null` \\| `object`","description":"The campaign's budget.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"application_method","type":"[AdminUpdateApplicationMethod](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminUpdateApplicationMethod/page.mdx)","description":"The application method of the promotion.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"description","type":"`null` \\| `string`","description":"The description of the application method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"value","type":"`number`","description":"The value of the application method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"max_quantity","type":"`null` \\| `number`","description":"The max quantity allowed in the cart for the associated promotion to be applied.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"currency_code","type":"`null` \\| `string`","description":"The currency code of the application method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"type","type":"[ApplicationMethodTypeValues](../../../../../promotion/types/promotion.ApplicationMethodTypeValues/page.mdx)","description":"The type of the application method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"target_type","type":"[ApplicationMethodTargetTypeValues](../../../../../promotion/types/promotion.ApplicationMethodTargetTypeValues/page.mdx)","description":"The target type of the application method indicating whether the associated promotion is applied\nto the cart's items, shipping methods, or the whole order.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"allocation","type":"[ApplicationMethodAllocationValues](../../../../../promotion/types/promotion.ApplicationMethodAllocationValues/page.mdx)","description":"The allocation value that indicates whether the associated promotion is applied on each\nitem in a cart or split between the items in the cart.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"target_rules","type":"[AdminCreatePromotionRule](../../../../../types/HttpTypes/interfaces/types.HLine truncated
<TypeList types={[{"name":"id","type":"`string`","description":"The promotion's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"payload","type":"[AdminUpdatePromotion](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminUpdatePromotion/page.mdx)","description":"The details to update in the promotion.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"code","type":"`string`","description":"The promotion's code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_automatic","type":"`boolean`","description":"Whether the promotion is applied automatically\nor requires the customer to manually apply it\nby entering the code at checkout.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_tax_inclusive","type":"`boolean`","description":"Whether the promotion is tax inclusive.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"type","type":"[PromotionTypeValues](../../../../../promotion/types/promotion.PromotionTypeValues/page.mdx)","description":"The type of promotion.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"status","type":"[PromotionStatusValues](../../../../../promotion/types/promotion.PromotionStatusValues/page.mdx)","description":"The status of the promotion.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"campaign_id","type":"`null` \\| `string`","description":"The ID of the campaign that the promotion belongs to.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"campaign","type":"[AdminCreateCampaign](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminCreateCampaign/page.mdx)","description":"The campaign that the promotion belongs to.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"name","type":"`string`","description":"The campaign's name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"description","type":"`string`","description":"The campaign's description.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"currency","type":"`null` \\| `string`","description":"The campaign's currency code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"campaign_identifier","type":"`string`","description":"The campaign's identifier.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"starts_at","type":"`null` \\| `Date`","description":"The date the campaign and its promotions start at.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"ends_at","type":"`null` \\| `Date`","description":"The date the campaign and its promotions end at.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"budget","type":"`null` \\| `object`","description":"The campaign's budget.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"application_method","type":"[AdminUpdateApplicationMethod](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminUpdateApplicationMethod/page.mdx)","description":"The application method of the promotion.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"description","type":"`null` \\| `string`","description":"The description of the application method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"value","type":"`number`","description":"The value of the application method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"max_quantity","type":"`null` \\| `number`","description":"The max quantity allowed in the cart for the associated promotion to be applied.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"currency_code","type":"`null` \\| `string`","description":"The currency code of the application method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"type","type":"[ApplicationMethodTypeValues](../../../../../promotion/types/promotion.ApplicationMethodTypeValues/page.mdx)","description":"The type of the application method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"target_type","type":"[ApplicationMethodTargetTypeValues](../../../../../promotion/types/promotion.ApplicationMethodTargetTypeValues/page.mdx)","description":"The target type of the application method indicating whether the associated promotion is applied\nto the cart's items, shipping methods, or the whole order.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"allocation","type":"[ApplicationMethodAllocationValues](../../../../../promotion/types/promotion.ApplicationMethodAllocationValues/page.mdx)","description":"The allocation value that indicates whether the associated promotion is applied on each\nitem in a cart or split between the items in the cart.","optiLine truncated
### Returns
@@ -7,6 +7,12 @@ It sends a request to the
[Confirm Product Import](https://docs.medusajs.com/api/admin#products\_postproductsimporttransaction\_idconfirm)
API route.
:::note
This is only available after Medusa `v2.8.5`.
:::
## Example
```ts
@@ -19,7 +19,7 @@ sdk.admin.promotion.update("promo_123", {
## Parameters
<TypeList types={[{"name":"id","type":"`string`","description":"The promotion's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"payload","type":"[AdminUpdatePromotion](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminUpdatePromotion/page.mdx)","description":"The details to update in the promotion.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"code","type":"`string`","description":"The promotion's code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_automatic","type":"`boolean`","description":"Whether the promotion is applied automatically\nor requires the customer to manually apply it\nby entering the code at checkout.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"type","type":"[PromotionTypeValues](../../../../../promotion/types/promotion.PromotionTypeValues/page.mdx)","description":"The type of promotion.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"status","type":"[PromotionStatusValues](../../../../../promotion/types/promotion.PromotionStatusValues/page.mdx)","description":"The status of the promotion.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"campaign_id","type":"`null` \\| `string`","description":"The ID of the campaign that the promotion belongs to.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"campaign","type":"[AdminCreateCampaign](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminCreateCampaign/page.mdx)","description":"The campaign that the promotion belongs to.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"name","type":"`string`","description":"The campaign's name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"description","type":"`string`","description":"The campaign's description.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"currency","type":"`null` \\| `string`","description":"The campaign's currency code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"campaign_identifier","type":"`string`","description":"The campaign's identifier.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"starts_at","type":"`null` \\| `Date`","description":"The date the campaign and its promotions start at.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"ends_at","type":"`null` \\| `Date`","description":"The date the campaign and its promotions end at.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"budget","type":"`null` \\| `object`","description":"The campaign's budget.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"application_method","type":"[AdminUpdateApplicationMethod](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminUpdateApplicationMethod/page.mdx)","description":"The application method of the promotion.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"description","type":"`null` \\| `string`","description":"The description of the application method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"value","type":"`number`","description":"The value of the application method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"max_quantity","type":"`null` \\| `number`","description":"The max quantity allowed in the cart for the associated promotion to be applied.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"currency_code","type":"`null` \\| `string`","description":"The currency code of the application method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"type","type":"[ApplicationMethodTypeValues](../../../../../promotion/types/promotion.ApplicationMethodTypeValues/page.mdx)","description":"The type of the application method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"target_type","type":"[ApplicationMethodTargetTypeValues](../../../../../promotion/types/promotion.ApplicationMethodTargetTypeValues/page.mdx)","description":"The target type of the application method indicating whether the associated promotion is applied\nto the cart's items, shipping methods, or the whole order.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"allocation","type":"[ApplicationMethodAllocationValues](../../../../../promotion/types/promotion.ApplicationMethodAllocationValues/page.mdx)","description":"The allocation value that indicates whether the associated promotion is applied on each\nitem in a cart or split between the items in the cart.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"target_rules","type":"[AdminCreatePromotionRule](../../../../../types/HttpTypes/interfaces/types.HLine truncated
<TypeList types={[{"name":"id","type":"`string`","description":"The promotion's ID.","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"payload","type":"[AdminUpdatePromotion](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminUpdatePromotion/page.mdx)","description":"The details to update in the promotion.","optional":false,"defaultValue":"","expandable":false,"children":[{"name":"code","type":"`string`","description":"The promotion's code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_automatic","type":"`boolean`","description":"Whether the promotion is applied automatically\nor requires the customer to manually apply it\nby entering the code at checkout.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"is_tax_inclusive","type":"`boolean`","description":"Whether the promotion is tax inclusive.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"type","type":"[PromotionTypeValues](../../../../../promotion/types/promotion.PromotionTypeValues/page.mdx)","description":"The type of promotion.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"status","type":"[PromotionStatusValues](../../../../../promotion/types/promotion.PromotionStatusValues/page.mdx)","description":"The status of the promotion.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"campaign_id","type":"`null` \\| `string`","description":"The ID of the campaign that the promotion belongs to.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"campaign","type":"[AdminCreateCampaign](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminCreateCampaign/page.mdx)","description":"The campaign that the promotion belongs to.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"name","type":"`string`","description":"The campaign's name.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"description","type":"`string`","description":"The campaign's description.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"currency","type":"`null` \\| `string`","description":"The campaign's currency code.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"campaign_identifier","type":"`string`","description":"The campaign's identifier.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"starts_at","type":"`null` \\| `Date`","description":"The date the campaign and its promotions start at.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"ends_at","type":"`null` \\| `Date`","description":"The date the campaign and its promotions end at.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"budget","type":"`null` \\| `object`","description":"The campaign's budget.","optional":true,"defaultValue":"","expandable":false,"children":[]}]},{"name":"application_method","type":"[AdminUpdateApplicationMethod](../../../../../types/HttpTypes/interfaces/types.HttpTypes.AdminUpdateApplicationMethod/page.mdx)","description":"The application method of the promotion.","optional":true,"defaultValue":"","expandable":false,"children":[{"name":"description","type":"`null` \\| `string`","description":"The description of the application method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"value","type":"`number`","description":"The value of the application method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"max_quantity","type":"`null` \\| `number`","description":"The max quantity allowed in the cart for the associated promotion to be applied.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"currency_code","type":"`null` \\| `string`","description":"The currency code of the application method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"type","type":"[ApplicationMethodTypeValues](../../../../../promotion/types/promotion.ApplicationMethodTypeValues/page.mdx)","description":"The type of the application method.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"target_type","type":"[ApplicationMethodTargetTypeValues](../../../../../promotion/types/promotion.ApplicationMethodTargetTypeValues/page.mdx)","description":"The target type of the application method indicating whether the associated promotion is applied\nto the cart's items, shipping methods, or the whole order.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"allocation","type":"[ApplicationMethodAllocationValues](../../../../../promotion/types/promotion.ApplicationMethodAllocationValues/page.mdx)","description":"The allocation value that indicates whether the associated promotion is applied on each\nitem in a cart or split between the items in the cart.","optiLine truncated
## Returns