PUT api/order/Order/ShipMethod?orderID={orderID}&shipMethodID={shipMethodID}&shouldCalculateTax={shouldCalculateTax}

This API allows updating shipping method for given order. Optionally allows overriding shipping and handling values.

Request Information

URI Parameters

NameDescriptionTypeAdditional information
orderID

The identifier of order to be updated.

integer

Required

shipMethodID

The identifier of the ship method to be associated to the given order.

integer

Required

shouldCalculateTax

When this flag is set to false the taxes won’t be recomputed as product of the shipping method change. Optional. Default is true.

boolean

Default value is True

Body Parameters

UpdateOrderShipMethodViewModel
NameDescriptionTypeAdditional information
overrideValues

Contains the fields to be overridden for the given order. Optional. Do not set this field if you want that Freedom to re-compute the taxes and totals based on configuration.

OverrideValuesViewModel

None.

Request Formats

application/xml, text/xml

Sample:
<UpdateOrderShipMethodViewModel>
  <overrideValues>
    <ShippingTotal>1</ShippingTotal>
    <ShippingTax>1</ShippingTax>
    <ShippingTaxCodeID>sample string 1</ShippingTaxCodeID>
    <HandlingFee>1</HandlingFee>
    <HandlingTax>1</HandlingTax>
    <HandlingTaxCodeID>sample string 2</HandlingTaxCodeID>
  </overrideValues>
</UpdateOrderShipMethodViewModel>

application/json, text/json

Sample:
{
  "overrideValues": {
    "ShippingTotal": 1.0,
    "ShippingTax": 1.0,
    "ShippingTaxCodeID": "sample string 1",
    "HandlingFee": 1.0,
    "HandlingTax": 1.0,
    "HandlingTaxCodeID": "sample string 2"
  }
}

application/x-www-form-urlencoded

Sample:

Failed to generate the sample for media type 'application/x-www-form-urlencoded'. Cannot use formatter 'FormUrlEncodedFormatter' to write type 'UpdateOrderShipMethodViewModel'.

Response Information

Resource Description

ApiResultOfOrderSummaryViewModel
NameDescriptionTypeAdditional information
Result

OrderSummaryViewModel

None.

IsSuccessful

boolean

None.

MessageTranslationKey

string

None.

Message

string

None.

Messages

Collection of ApiResultMessage

None.

Response Formats

application/xml, text/xml, application/json, text/json

Sample:

Sample not available.