SalesRules: Magento Cart Price Rules
insert update delete REST
- Catalog:
Magento - Schema:
Marketing - Primary Keys:
rule_id - Label: Cart Price Rules
Retrieve sales rules that match te specified criteria. This call returns an array of objects, but detailed information about each object’s attributes might not be included. See https://developer.adobe.com/commerce/webapi/rest/attributes#RuleRepositoryInterface to determine which call to use to get detailed information about all attributes for an object.
Can retrieve data and change data using insert, update and delete.
Summary
Retrieve sales rules that match te specified criteria. This call returns an array of objects, but detailed information about each object’s attributes might not be included. See https://developer.adobe.com/commerce/webapi/rest/attributes#RuleRepositoryInterface to determine which call to use to get detailed information about all attributes for an object.
API Source
- Endpoint:
/V1/salesRules/search - Operation:
get /V1/salesRules/search
Performance Characteristics
| Characteristic | Value |
|---|---|
| Average access latency (ms) | 48 |
| Full scan rows per minute | 114,833 |
| Point query rows per minute | 1,188 |
| Write rows per minute | 599 |
The result can be cached on the client.
Parameters
| Name | Data Type | Required | Default | Documentation |
|---|---|---|---|---|
search |
`` | Current page. | ||
search |
`` | Condition type | ||
search |
`` | Field | ||
search |
`` | Value | ||
search |
`` | Page size. | ||
search |
`` | Sorting direction. | ||
search |
`` | Sorting field. |
Table Columns
The columns of the table SalesRules are shown below. Each column has an SQL data type. A new non-null value must be provided for every required column at all times during insert and update.
| Name | Data Type | Label | Required | Marks | Documentation |
|---|---|---|---|---|---|
action_ |
varchar2 |
Action Condition Aggregator Type | filters on the platform, writable, action_ |
The aggregator type | |
action_ |
varchar2 |
Action Condition Attribute Name | filters on the platform, writable, action_ |
The attribute name of the condition | |
action_ |
varchar2 |
Action Condition Condition Type | filters on the platform, writable, action_ |
Condition type | |
action_ |
varchar2 |
Action Condition Extension Attributes | writable | The JSON text of the nested object. | |
action_ |
varchar2 |
Action Condition Operator | filters on the platform, writable, action_ |
The operator of the condition | |
action_ |
varchar2 |
Action Condition Value | filters on the platform, writable, action_ |
The value of the condition | |
apply_ |
char |
Apply to Shipping | filters on the platform, writable, apply_ |
The rule applies to shipping | |
condition_ |
varchar2 |
Condition Aggregator Type | filters on the platform, writable, condition. |
The aggregator type | |
condition_ |
varchar2 |
Condition Attribute Name | filters on the platform, writable, condition. |
The attribute name of the condition | |
condition_ |
varchar2 |
Condition Condition Type | filters on the platform, writable, condition. |
Condition type | |
condition_ |
varchar2 |
Condition Extension Attributes | writable | The JSON text of the nested object. | |
condition_ |
varchar2 |
Condition Operator | filters on the platform, writable, condition. |
The operator of the condition | |
condition_ |
varchar2 |
Condition Value | filters on the platform, writable, condition. |
The value of the condition | |
coupon_ |
varchar2 |
Coupon Type | filters on the platform, writable, coupon_ |
Coupon type | |
customer_ |
varchar2 |
Customer Group IDs | filters on the platform, writable, customer_ |
Ids of customer groups that the rule applies to The identifiers, separated by commas. | |
description |
varchar2 |
Description | filters on the platform, writable, description |
Description | |
discount_ |
decimal |
Discount Amount | filters on the platform, writable, discount_ |
Discount amount | |
discount_ |
decimal |
Discount Quantity | filters on the platform, writable, discount_ |
Maximum qty discount is applied | |
discount_ |
int64 |
Discount Step | filters on the platform, writable, discount_ |
Discount step | |
extension_ |
varchar2 |
Extension Attributes | writable | The JSON text of the nested object. | |
from_ |
varchar2 |
From Date | filters on the platform, writable, from_ |
The start date when the coupon is active | |
is_ |
char |
Is Active | filters on the platform, writable, is_ |
The coupon is active | |
is_ |
char |
Is Advanced | filters on the platform, writable, is_ |
Is this field needed | |
is_rss |
char |
Is RSS | filters on the platform, writable, is_rss |
Whether the rule is in RSS | |
name |
varchar2 |
Name | filters on the platform, writable, name |
Rule name | |
product_ |
varchar2 |
Product IDs | filters on the platform, writable, product_ |
Product ids The identifiers, separated by commas. | |
rule_ |
int64 |
Rule ID | filters on the platform, writable, rule_ |
Rule id | |
simple_ |
varchar2 |
Simple Action | filters on the platform, writable, simple_ |
Simple action of the rule | |
simple_ |
varchar2 |
Simple Free Shipping | filters on the platform, writable, simple_ |
To grant free shipping | |
sort_ |
int64 |
Sort Order | filters on the platform, writable, sort_ |
Sort order | |
stop_ |
char |
Stop Rules Processing | filters on the platform, writable, stop_ |
To stop rule processing | |
times_ |
int64 |
Times Used | filters on the platform, writable, times_ |
How many times the rule has been used | |
to_ |
varchar2 |
To Date | filters on the platform, writable, to_ |
The end date when the coupon is active | |
use_ |
char |
Use Auto Generation | filters on the platform, writable, use_ |
To auto generate coupon | |
uses_ |
int64 |
Uses per Coupon | filters on the platform, writable, uses_ |
Limit of uses per coupon | |
uses_ |
int64 |
Uses per Customer | filters on the platform, writable, uses_ |
Number of uses per customer | |
website_ |
varchar2 |
Website IDs | filters on the platform, writable, website_ |
A list of websites the rule applies to The identifiers, separated by commas. |