put

/shipping/zones/{zone_id}/methods/{method_id}

Updates a Shipping Method in a zone. Real Time Carrier Connections are also supported by this endpoint.

Read Only Fields

  • id

Settings Objects

A shipping method’s type and settings properties can match one of the following models:

perorder Object – Properties

Object model for flat-rate shipping quotes per order.

Name Type Description
rate number Flat rate per order.

JSON Example

{
	"name": "Flat Rate per Order",
	"type": "perorder",
	"settings": {
		"rate": 7
	}
},

peritem Object – Properties

Object model for flat-rate shipping quotes per item ordered.

Name Type Description
rate number Flat rate per item.

JSON Example

{
	"name": "Flat Rate per Item",
	"type": "peritem",
	"settings": {
		"rate": 8
	}
},

weight Object – Properties

Object model for shipping quotes by weight.

Name Type Description
default_cost number Default shipping cost, applied either as a percentage of the order’s total value or as a fixed amount.
default_cost_type string How the default shipping cost is calculated. One of: percentage_of_total or fixed_amount.
range number Array of range objects. The units for these ranges’ lower_limit and upper_limit properties depend on the default units set in the store’s control panel.

JSON Example

{
	"name": "Rate per Weight",
	"type": "weight",
	"settings": {
		"default_cost": 12,
		"default_cost_type": "fixed_amount",
		"range": [
			{
				"lower_limit": 0,
				"upper_limit": 20,
				"shipping_cost": 8
			},
			{
				"lower_limit": 20,
				"upper_limit": 40,
				"shipping_cost": 12
			}
		]
	}
}

total Object – Properties

Object model for shipping quotes by order’s total value.

Name Type Description
default_cost number Default shipping cost, applied either as a percentage of the order’s total value or as a fixed amount.
default_cost_type string How the default shipping cost is calculated. One of: percentage_of_total or fixed_amount.
include_order_total_taxes boolean Whether or not to include taxes on the order’s total value in the shipping-cost calculation.
range number Array of range objects. The units for these ranges’ lower_limit and upper_limit properties are values in the store’s currency.

JSON Example

This example sets free shipping above a certain order total:

{
	"name": "Per Total or Free",
	"type": "total",
	"settings": {
		"default_cost": 12,
		"default_cost_type": "fixed_amount",
		"include_order_total_taxes": 0,
		"range": [
			{
				"lower_limit": 0,
				"upper_limit": 5,
				"shipping_cost": 5
			},
			{
				"lower_limit": 5,
				"upper_limit": 10,
				"shipping_cost": 8
			},
			{
				"lower_limit": 10,
				"upper_limit": 20,
				"shipping_cost": 10
			},
			{
				"lower_limit": 20,
				"upper_limit": 49.99,
				"shipping_cost": 15
			},
			{
				"lower_limit": 50,
				"upper_limit": 100000,
				"shipping_cost": 0
			}       
		]
	}
}

Range Object – Properties

Object model to define ranges for shipping quotes. Units are defined in the parent object.

Name Type Description
lower_limit number Lower limit for order total.
upper_limit number Upper limit for order total.
shipping_cost number Shipping cost for orders whose total falls between the lower and upper limits.

JSON Example

{
	"lower_limit": 0,
	"upper_limit": 20,
	"shipping_cost": 8
}

Authorization

apiKey - X-Auth-Token

Request Parameters

2 Path Parameters
2 Headers

Request Body

1 Example
Schema
object
name
string

Display name for shipping method.

1 validation
type
string
3 validations
settings
object

Depends on the shipping-method type. See the supported settings object.

enabled
boolean

Whether or not this shipping-zone method is enabled.

1 validation
handling_fees
object

fixed_surcharge: flat-rate handling fee applied to shipping cost.

percentage_surcharge: percentage handling fee applied to shipping cost

2 validations
is_fallback
boolean

Whether or not this shipping zone is the fallback if all others are not valid for the order.

1 validation

Responses

2 Examples
Schema
object
id
integer

Shipping-method ID. READ-ONLY

1 validation
name
string

Display name for shipping method.

1 validation
type
string
3 validations
settings
object

Depends on the shipping-method type. See the supported settings object.

enabled
boolean

Whether or not this shipping-zone method is enabled.

1 validation
handling_fees
object

fixed_surcharge: flat-rate handling fee applied to shipping cost.

percentage_surcharge: percentage handling fee applied to shipping cost

2 validations
is_fallback
boolean

Whether or not this shipping zone is the fallback if all others are not valid for the order.

1 validation

Send a Test Request

Send requests directly from the browser (CORS must be enabled)
Path Params
2 path params not set
zone_id
method_id
$$.env
1 variable not set
store_hash
X-Auth-Token