Skip to main content
Skip to main content

updatePriceSetMoneyAmountRules - Pricing Module Reference

Beta

This documentation provides a reference to the updatePriceSetMoneyAmountRules method. This belongs to the Pricing Module.

This method is used to update price set money amount rules, each with their provided data.

Example

import {
initialize as initializePricingModule,
} from "@medusajs/pricing"

async function updatePriceSetMoneyAmountRules (id: string, value: string) {
const pricingService = await initializePricingModule()

const priceSetMoneyAmountRules = await pricingService.updatePriceSetMoneyAmountRules([
{
id,
value
}
])

// do something with the price set money amount rules or return them
}

Parameters

The price set money amounts to update, each having the attributes to update in a price set money amount.
sharedContextContext
A context used to share resources, such as transaction manager, between the application and the module.

Returns

PromisePromise<PriceSetMoneyAmountRulesDTO[]>Required
The list of updated price set money amount rules.
Was this section helpful?