commerce/targetrules

Use the TargetRules resource to manage your target rules for products and zones. For example, you can set specific rules that dictate shipping options for specific products.

JSON Example

TargetRule Properties

Property Description
code

type: string

The unique identifier of the object.

description

type: string

The localized description in text for the object, displayed per the locale code. For example, descriptions are used for product descriptions, attributes, and pre-authorization transaction types.

domain

type: string

Properties of the domain that the tenant is associated with such as the domain name, the zone string, audit information (system-supplied and read-only), assignment data, and whether or not the domain is primary or requires a SSL for authentication.

expression

type: string

The expression you want for the target rule. Refer to Product Rules in the Shipping Settings guides topic for more information.

Operations

Operation Name Request URI Description
CreateTargetRule POST %3fresponseFields%3d%7bresponseFields%7d

Creates a new target rule.

DeleteTargetRule DELETE %7bcode%7d

Deletes the specified target rule.

GetTargetRule GET %7bcode%7d%3fresponseFields%3d%7bresponseFields%7d

Retrieves the details of the specified target rule.

GetTargetRules GET %3fstartIndex%3d%7bstartIndex%7d%26pageSize%3d%7bpageSize%7d%26sortBy%3d%7bsortBy%7d%26filter%3d%7bfilter%7d%26responseFields%3d%7bresponseFields%7d

Retrieves a list of target rules and their details according to any specified facets, filter criteria, and sort options.

UpdateTargetRule PUT %7bcode%7d%3fresponseFields%3d%7bresponseFields%7d

Updates the details of the specified target rule.

ValidateTargetRule POST validate

Validates the details of a target rule.