create_price_rule
Create automatic discounts by defining price rules with target, value, and allocation method. Set start/end dates, usage limits, and prerequisites to control discount application.
Instructions
Create a new price rule for automatic discounts
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"title": "<title>",
"target": "<target>",
"allocationMethod": "<allocationMethod>",
"valueType": "<valueType>",
"value": "<value>"
},
"name": "create_price_rule"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| title | Yes | Price rule title | |
| value | Yes | Discount value (percentage or fixed amount) | |
| endsAt | No | End date/time (ISO format) | |
| target | Yes | What the discount applies to | |
| startsAt | No | Start date/time (ISO format) | |
| valueType | Yes | Type of discount value | |
| usageLimit | No | Total usage limit | |
| oncePerCustomer | No | Limit to one use per customer | |
| allocationMethod | Yes | How to allocate the discount | |
| prerequisiteSubtotalMin | No | Minimum subtotal required |