Shipping > Shipping Rules > shippingRulesModify
Commerce APIShippingShipping RulesshippingRulesModify
shippingRulesModify
POST:shipping_rules.json

Description

Modify one or multiple shipping rules.

Permission bit: "shipping_rules.modify"

Topic: Shipping Rules

Arguments

data: [ShippingRuleModify!]!

Main argument for mutations.


ids: [String!]!

List of shipping rule ids. See also: Unique Identifiers

Example: ["sr_EQzGqWoY"]


shop_id: String!

Unique shop identifier. See also: Unique Identifiers

Example: "sh_EQzGqWoY"


Data Argument Fields

components: String

Shipping rule components (custom JSON format)

Example: "[]"


group_policy: ShippingRateGroupPolicy

What to do with multiple shipping rate groups


name: String

Name of the shipping rule

Example: "FedEx everywhere"

Valid when: name is not empty

Valid when: name's length doesn't exceed 250 characters


priority: Int

Priority of the rule (rule with higher priority is to be evaluated first)

Example: 0


zones: [ZoneCreate!]


Result

[ShippingRule!]

Preview (typescript)

Loading module