From c2a079cebb77b7d05524a5f68bc34a206de95a07 Mon Sep 17 00:00:00 2001 From: bc-andreadao <96258747+bc-andreadao@users.noreply.github.com> Date: Mon, 14 Nov 2022 17:46:46 -0600 Subject: [PATCH] DEVDOCS-4330: [maintenance] Shipping v2, clarify zones schemas (#966) Co-authored-by: Sarah Riehl Co-authored-by: Andrea Dao --- reference/shipping.v2.yml | 428 ++++++++++++++++++++++---------------- 1 file changed, 254 insertions(+), 174 deletions(-) diff --git a/reference/shipping.v2.yml b/reference/shipping.v2.yml index e2a32b08f..be7db651b 100644 --- a/reference/shipping.v2.yml +++ b/reference/shipping.v2.yml @@ -1,7 +1,12 @@ -openapi: 3.0.0 +openapi: '3.0.3' info: version: '' title: Shipping V2 + termsOfService: 'https://www.bigcommerce.com/terms' + contact: + name: BigCommerce + url: 'https://www.bigcommerce.com' + email: support@bigcommerce.com description: |- Manage shipping zones, shipping methods, and shipping carrier connections. @@ -19,6 +24,16 @@ info: ### Shipping Carrier Connections Carrier connections refer to specific settings required to connect to a specific shipping carrier. Each carrier requires your app to supply a unique set of properties/fields to establish a connection with that carrier. +servers: + - url: 'https://api.bigcommerce.com' + description: BigCommerce API Gateway +security: + - X-Auth-Token: [] +tags: + - name: Shipping Method + - name: Shipping Carrier + - name: Shipping Zones + - name: Shipping Products Custom Information paths: '/stores/{store_hash}/v2/shipping/zones': get: @@ -58,7 +73,7 @@ paths: example: 1 name: type: string - description: Zone name. Required for /PUT + description: Zone name. Required for PUT requests. example: United States type: type: string @@ -104,18 +119,27 @@ paths: handling_fees: title: Shipping Zone Handling Fees type: object - properties: - fixed_surcharge: - description: '' - example: '0' - type: string - percentage_surcharge: - description: '' - type: string - display_separately: - description: '' - example: true - type: boolean + oneOf: + - properties: + fixed_surcharge: + description: Flat-rate handling fee applied to shipping cost. + example: '0' + type: string + display_separately: + description: Indicates whether store displays handling fee separately at checkout. + example: true + type: boolean + title: fixed surcharge + - properties: + percentage_surcharge: + description: Percentage handling fee applied to shipping cost. + example: '5' + type: string + display_separately: + description: Indicates whether store displays handling fee separately at checkout. + example: true + type: boolean + title: percentage surcharge enabled: description: Whether this shipping zone is enabled. example: true @@ -133,9 +157,6 @@ paths: enabled: false minimum_sub_total: '0.0000' exclude_fixed_shipping_products: false - handling_fees: - display_separately: true - fixed_surcharge: '0.0000' enabled: true - id: 2 name: Australia @@ -147,9 +168,6 @@ paths: enabled: false minimum_sub_total: '0.0000' exclude_fixed_shipping_products: false - handling_fees: - display_separately: true - fixed_surcharge: '0.0000' enabled: true Response Schema: examples: @@ -214,7 +232,7 @@ paths: properties: name: type: string - description: Zone name. Required for /PUT + description: Zone name. Required for PUT requests. example: United States type: type: string @@ -260,18 +278,27 @@ paths: handling_fees: title: Shipping Zone Handling Fees type: object - properties: - fixed_surcharge: - description: '' - example: '0' - type: string - percentage_surcharge: - description: '' - type: string - display_separately: - description: '' - example: true - type: boolean + oneOf: + - properties: + fixed_surcharge: + description: Flat-rate handling fee applied to shipping cost. + example: '0' + type: string + display_separately: + description: Indicates whether store displays handling fee separately at checkout. + example: true + type: boolean + title: fixed surcharge + - properties: + percentage_surcharge: + description: Percentage handling fee applied to shipping cost. + example: '5' + type: string + display_separately: + description: Indicates whether store displays handling fee separately at checkout. + example: true + type: boolean + title: percentage surcharge enabled: description: Whether this shipping zone is enabled. example: true @@ -365,18 +392,27 @@ paths: handling_fees: title: Shipping Zone Handling Fees type: object - properties: - fixed_surcharge: - description: '' - example: '0' - type: string - percentage_surcharge: - description: '' - type: string - display_separately: - description: '' - example: true - type: boolean + oneOf: + - properties: + fixed_surcharge: + description: Flat-rate handling fee applied to shipping cost. + example: '0' + type: string + display_separately: + description: Indicates whether store displays handling fee separately at checkout. + example: true + type: boolean + title: fixed surcharge + - properties: + percentage_surcharge: + description: Percentage handling fee applied to shipping cost. + example: '5' + type: string + display_separately: + description: Indicates whether store displays handling fee separately at checkout. + example: true + type: boolean + title: percentage surcharge enabled: description: Whether this shipping zone is enabled. example: true @@ -479,18 +515,27 @@ paths: handling_fees: title: Shipping Zone Handling Fees type: object - properties: - fixed_surcharge: - description: '' - example: '0' - type: string - percentage_surcharge: - description: '' - type: string - display_separately: - description: '' - example: true - type: boolean + oneOf: + - properties: + fixed_surcharge: + description: Flat-rate handling fee applied to shipping cost. + example: '0' + type: string + display_separately: + description: Indicates whether store displays handling fee separately at checkout. + example: true + type: boolean + title: fixed surcharge + - properties: + percentage_surcharge: + description: Percentage handling fee applied to shipping cost. + example: '5' + type: string + display_separately: + description: Indicates whether store displays handling fee separately at checkout. + example: true + type: boolean + title: percentage surcharge enabled: description: Whether this shipping zone is enabled. example: true @@ -512,7 +557,7 @@ paths: - name: id in: path required: true - description: Id of the shipping zone. + description: ID of the shipping zone. schema: type: integer exclusiveMinimum: false @@ -540,11 +585,12 @@ paths: properties: id: type: integer - description: Zone Id. READ-ONLY + description: Zone ID. Read-only. example: 1 + readOnly: true name: type: string - description: Zone name. Required for /PUT + description: Zone name. Required for PUT requests. example: United States type: type: string @@ -590,18 +636,27 @@ paths: handling_fees: title: Shipping Zone Handling Fees type: object - properties: - fixed_surcharge: - description: '' - example: '0' - type: string - percentage_surcharge: - description: '' - type: string - display_separately: - description: '' - example: true - type: boolean + oneOf: + - properties: + fixed_surcharge: + description: Flat-rate handling fee applied to shipping cost. + example: '0' + type: string + display_separately: + description: Indicates whether store displays handling fee separately at checkout. + example: true + type: boolean + title: fixed surcharge + - properties: + percentage_surcharge: + description: Percentage handling fee applied to shipping cost. + example: '5' + type: string + display_separately: + description: Indicates whether store displays handling fee separately at checkout. + example: true + type: boolean + title: percentage surcharge enabled: description: Whether this shipping zone is enabled. example: true @@ -620,11 +675,12 @@ paths: properties: id: type: integer - description: Zone Id. READ-ONLY + description: Zone ID. Read-only. example: 1 + readOnly: true name: type: string - description: Zone name. Required for /PUT + description: Zone name. Required for PUT requests. example: United States type: type: string @@ -670,18 +726,27 @@ paths: handling_fees: title: Shipping Zone Handling Fees type: object - properties: - fixed_surcharge: - description: '' - example: '0' - type: string - percentage_surcharge: - description: '' - type: string - display_separately: - description: '' - example: true - type: boolean + oneOf: + - properties: + fixed_surcharge: + description: Flat-rate handling fee applied to shipping cost. + example: '0' + type: string + display_separately: + description: Indicates whether store displays handling fee separately at checkout. + example: true + type: boolean + title: fixed surcharge + - properties: + percentage_surcharge: + description: Percentage handling fee applied to shipping cost. + example: '5' + type: string + display_separately: + description: Indicates whether store displays handling fee separately at checkout. + example: true + type: boolean + title: percentage surcharge enabled: description: Whether this shipping zone is enabled. example: true @@ -698,7 +763,7 @@ paths: - name: id in: path required: true - description: Id of the shipping zone. + description: ID of the shipping zone. schema: type: integer exclusiveMinimum: false @@ -740,7 +805,7 @@ paths: type: string '/stores/{store_hash}/v2/shipping/zones/{zone_id}/methods': get: - description: 'Returns a list of *Shipping Methods* in a zone. Default sorting is by shipping-method id, from lowest to highest.' + description: 'Returns a list of *Shipping Methods* in a zone. Default sorting is by shipping method ID, from lowest to highest.' summary: Get All Shipping Methods in a Zone tags: - Shipping Method @@ -748,7 +813,7 @@ paths: - name: zone_id in: path required: true - description: Id of the shipping zone. + description: ID of the shipping zone. schema: type: integer exclusiveMinimum: false @@ -866,7 +931,7 @@ paths: IsMultiContentStreaming: false operationId: getShippingMethodsZone post: - description: "Creates a *Shipping Method* within a shipping zone. Real Time Carrier\nConnections are also supported by this endpoint. \n\n\n## Carrier Configurations – Current\n\n\nThis section provides a sample request and a carrier-specific object/property model, for each supported carrier.\n \n### USPS by Endicia\n\n\n#### Sample Request\n\n\n\n```json\n\n{\n \"name\": \"USPS by Endicia\",\n \"type\": \"endicia\",\n \"settings\": {\n \"carrier_options\": {\n \"delivery_services\" : [\"PriorityExpress\",\"Priority\", \"PriorityMailExpressInternational\"],\n\t\t\t\"packaging_type\" : \"LargeFlatRateBox\",\n \"show_transit_time\" : true\n }\n },\n \"enabled\": true\n}\n\n```\n\n\n### USPS by Endicia Object Properties\n\n\n| Property | Type | Values |\n| - | - | - |\n| delivery_services | array | PriorityExpress
PriorityMailExpressInternational
FirstClassPackageInternationalService
Priority
PriorityMailInternational
First
ParcelSelect
MediaMail |\n| packaging_type | array | FlatRateLegalEnvelope
FlatRatePaddedEnvelope
Parcel
SmallFlatRateBox
MediumFlatRateBox
LargeFlatRateBox
FlatRateEnvelope
RegionalRateBoxA
RegionalRateBoxB |\n|show_transit_time | boolean | true
false |\n\n\n\n### FedEx\n\n\n#### Sample Request\n\n\n```json\n\n{\n \"name\": \"FEDEX\",\n \"type\": \"fedex\",\n \"settings\": {\n \"carrier_options\": {\n \"delivery_services\": [\n \"PRIORITY_OVERNIGHT\",\n\t\t\t\t\"FEDEX_2_DAY\"\n ],\n \"dropoff_type\": \"REGULAR_PICKUP\",\n \"packaging_type\": \"FEDEX_ENVELOPE\",\n \"packing_method\": \"SEPARATE\",\n \"rate_type\": \"NONE\",\n \"include_package_value\": true,\n \"destination_type\": \"residential\"\n }\n },\n \"enabled\": true\n}\n\n```\n\n\n#### FedEx Object Properties\n\n\n| Property | Type | Values |\n| - | - | - |\n| delivery_services | array | PRIORITY_OVERNIGHT
STANDARD_OVERNIGHT
FIRST_OVERNIGHT
FEDEX_2_DAY
FEDEX_EXPRESS_SAVER
INTERNATIONAL_PRIORITY
INTERNATIONAL_ECONOMY
INTERNATIONAL_FIRST
FEDEX_1_DAY_FREIGHT
FEDEX_2_DAY_FREIGHT
FEDEX_3_DAY_FREIGHT
FEDEX_GROUND
GROUND_HOME_DELIVERY
INTERNATIONAL_PRIORITY_FREIGHT
INTERNATIONAL_ECONOMY_FREIGHT
EUROPE_FIRST_INTERNATIONAL_PRIORITY |\n| dropoff_type | string | REGULAR_PICKUP
REQUEST_COURIER
DROP_BOX
BUSINESS_SERVICE_CENTER
STATION |\n| packaging_type | string | FEDEX_ENVELOPE
FEDEX_PAK
FEDEX_BOX
FEDEX_TUBE
FEDEX_10KG_BOX
FEDEX_25KG_BOX
YOUR_PACKAGING |\n| packing_method | string | SEPARATE
COMBINED |\n| rate_type | string | NONE
LIST |\n| include_package_value | boolean | true
false |\n| destination_type | string | residential
business |\n\n\n### UPS Ready\n\n\n#### Sample Request\n\n\n```json\n\n{\n \"name\": \"UPS ready\",\n \"type\": \"upsready\",\n \"settings\": {\n \"carrier_options\": {\n \"delivery_services\": [\n \"2nd_Day_Air\",\"Standard\"\n ],\n \"packaging_type\": \"21\",\n \"packing_method\": \"separate\",\n \"include_package_value\": true,\n \"destination_type\": \"residential\",\n \"show_transit_time\" : true\n }\n },\n \"enabled\": true\n}\n\n```\n\n\n#### UPS Ready Object Properties\n\n\n| Property | Type | Values |\n| - | - | - |\n| delivery_services | array | 2nd_Day_Air
2nd_Day_Air_AM
3_Day_Select
Expedited
Express
Express_Plus
Express_Saver
Express_Early_AM
Ground
Next_Day_Air
Next_Day_Air_Early_AM
Next_Day_Air_Saver
Saver
Standard
Today_Dedicated_Courier
Today_Express
Today_Express_Saver
Today_Intercity
Today_Standard
Worldwide_Expedited
Worldwide_Express
Worldwide_Express_Plus
Worldwide_Express_Saver
Worldwide_Saver |\n| destination_type | string | residential
business |\n| packing_method | string | separate
combined |\n| packaging_type | string (only codes allowed) | 21: UPS® Express Box
24: UPS® 25 KG Box
25: UPS® 10 KG Box
30: Pallet
01: UPS® Letter
02: Customer Supplied Package
03: Tube
04: PAK
2a: Small Express Box
2b: Medium Express Box
2c: Large Express Box |\n| include_package_value | boolean | true
false |\n| show_transit_time | boolean | true
false |\n\n\n### Canada Post\n\n\n#### Sample Request\n\n\n```json\n\n{\n \"name\": \"Canada Post\",\n \"type\": \"canadapost\",\n \"settings\": {\n \"carrier_options\": {\n \"delivery_services\": [\n \"DOM.RP\",\"DOM.EP\"\n ]\n }\n },\n \"enabled\": true\n}\n\n```\n\n\n#### Canada Post Object Properties\n\n\n| Property | Type | Values |\n| - | - | - |\n| delivery_services | array | DOM.RP
DOM.EP
DOM.XP
DOM.XP.CERT
DOM.PC DOM.LIB
USA.EP
USA.PW.ENV
USA.PW.PAK
USA.PW.PARCEL
USA.SP.AIR
USA.TP
USA.TP.LVM
USA.XP
INT.XP
INT.IP.AIR
INT.IP.SURF
INT.PW.ENV
INT.PW.PAK
INT.PW.PARCEL
INT.SP.AIR
INT.SP.SURF
INT.TP |\n\n\n### Australia Post\n\n\n```json\n\n{\n \"name\": \"Australia Post\",\n \"type\": \"auspost\",\n \"settings\": {\n \"carrier_options\": {\n \"delivery_services\": [\n \"AUS_PARCEL_REGULAR\",\n\t\t\t\t\"AUS_PARCEL_EXPRESS\"\n ]\n }\n },\n \"enabled\": true\n}\n\n```\n\n\n#### Australia Post Object Properties\n\n\n| Property | Type | Values |\n| - | - | - |\n| delivery_services | array | AUS_LETTER_REGULAR_SMALL
AUS_LETTER_REGULAR_Large
AUS_LETTER_EXPRESS_SMALL
AUS_LETTER_EXPRESS_MEDIUM
AUS_LETTER_EXPRESS_LARGE
AUS_PARCEL_REGULAR
AUS_PARCEL_REGULAR_SATCHEL_500G
AUS_PARCEL_REGULAR_SATCHEL_3KG
AUS_PARCEL_REGULAR_SATCHEL_5KG
AUS_PARCEL_EXPRESS
AUS_PARCEL_EXPRESS_SATCHEL_500G
AUS_PARCEL_EXPRESS_SATCHEL_3KG
AUS_PARCEL_EXPRESS_SATCHEL_5KG
AUS_PARCEL_COURIER
AUS_PARCEL_COURIER_SATCHEL_MEDIUM
INT_PARCEL_COR_OWN_PACKAGING
INT_PARCEL_EXP_OWN_PACKAGING
INT_PARCEL_STD_OWN_PACKAGING
INT_PARCEL_AIR_OWN_PACKAGING
INT_PARCEL_SEA_OWN_PACKAGING |\n\n\n### Royal Mail\n\n\n#### Sample Request\n\n\n```json\n\n{\n \"name\": \"Royal Mail\",\n \"type\": \"royalmail\",\n \"settings\": {\n \"carrier_options\": {\n \"delivery_services\": [\n \"StandardFirstClass\",\n\t\t\t\t\"StandardSecondClass\"\n ]\n }\n },\n \"enabled\": true\n}\n\n```\n\n\n#### Royal Mail Object Properties\n\n\n| Property | Type | Values |\n| - | - | - |\n| delivery_services | array | SpecialDelivery1pm
SpecialDelivery9am
SpecialDelivery1pmSaturday
SpecialDelivery9amSaturday
SignedForFirstClass
SignedForSecondClass
Express9
Express10
ExpressAM
Express24
Express48
StandardFirstClass
StandardSecondClass
InternationalStandard
InternationalTracked
InternationalEconomy |\n\n\n### Zoom2U\n\n\n#### Sample Request\n\n\n```json\n\n{\n \"name\": \"Zoom2U\",\n \"type\": \"zoom2u\",\n \"settings\": {\n \"carrier_options\": {\n \"delivery_services\": [\n \"3_hour\",\n\t\t\t\t\"Same_day\",\n\t\t\t\t\"VIP\"\n ]\n }\n },\n \"enabled\": true\n}\n\n```\n\n\n#### Zoom2U Object Properties\n\n\n| Property | Type | Values |\n| - | - | - |\n| delivery_services | array | 3_hour
Same_day
VIP|\n\n\n\n### Settings Objects \n\n\nA shipping method's `type` and `settings` properties can match one of the following models:\n\n\n### perorder Object – Properties \n\n\nObject model for flat-rate shipping quotes per order.\n\n\n| Name | Type | Description |\n| - | - | - |\n| rate | number | Flat rate per order. |\n\n\n#### JSON Example \n\n\n```json\n\n{\n\t\"name\": \"Flat Rate per Order\",\n\t\"type\": \"perorder\",\n\t\"settings\": {\n\t\t\"rate\": 7\n\t}\n},\n\n```\n\n\n### peritem Object – Properties \n\n\nObject model for flat-rate shipping quotes per item ordered.\n\n\n| Name | Type | Description |\n| - | - | - |\n| rate | number | Flat rate per item. |\n\n\n#### JSON Example \n\n\n```json\n\n{\n\t\"name\": \"Flat Rate per Item\",\n\t\"type\": \"peritem\",\n\t\"settings\": {\n\t\t\"rate\": 8\n\t}\n},\n\n```\n\n\n### weight Object – Properties \n\n\nObject model for shipping quotes by weight.\n\n\n| Name | Type | Description |\n| - | - | - |\n| default_cost | number | Default shipping cost, applied either as a percentage of the order's total value or as a fixed amount. |\n| default_cost_type | string | How the default shipping cost is calculated. One of: `percentage_of_total` or `fixed_amount`. |\n| range | number | Array of [range](#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. |\n\n\n\n#### JSON Example \n \n```json\n\n{\n\t\"name\": \"Rate per Weight\",\n\t\"type\": \"weight\",\n\t\"settings\": {\n\t\t\"default_cost\": 12,\n\t\t\"default_cost_type\": \"fixed_amount\",\n\t\t\"range\": [\n\t\t\t{\n\t\t\t\t\"lower_limit\": 0,\n\t\t\t\t\"upper_limit\": 20,\n\t\t\t\t\"shipping_cost\": 8\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"lower_limit\": 20,\n\t\t\t\t\"upper_limit\": 40,\n\t\t\t\t\"shipping_cost\": 12\n\t\t\t}\n\t\t]\n\t}\n}\n\n```\n\n\n### total Object – Properties \n\n\nObject model for shipping quotes by order's total value.\n\n\n| Name | Type | Description |\n| - | - | - |\n| default_cost | number | Default shipping cost, applied either as a percentage of the order's total value or as a fixed amount. |\n| default_cost_type | string | How the default shipping cost is calculated. One of: `percentage_of_total` or `fixed_amount`. |\n| include_order_total_taxes | boolean | Whether or not to include taxes on the order's total value in the shipping-cost calculation. |\n| range | number | Array of [range](#range) objects. The units for these ranges' `lower_limit` and `upper_limit` properties are values in the store's currency. |\n\n\n#### JSON Example \n\n\nThis example sets free shipping above a certain order total:\n\n\n```json\n\n{\n\t\"name\": \"Per Total or Free\",\n\t\"type\": \"total\",\n\t\"settings\": {\n\t\t\"default_cost\": 12,\n\t\t\"default_cost_type\": \"fixed_amount\",\n\t\t\"include_order_total_taxes\": 0,\n\t\t\"range\": [\n\t\t\t{\n\t\t\t\t\"lower_limit\": 0,\n\t\t\t\t\"upper_limit\": 5,\n\t\t\t\t\"shipping_cost\": 5\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"lower_limit\": 5,\n\t\t\t\t\"upper_limit\": 10,\n\t\t\t\t\"shipping_cost\": 8\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"lower_limit\": 10,\n\t\t\t\t\"upper_limit\": 20,\n\t\t\t\t\"shipping_cost\": 10\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"lower_limit\": 20,\n\t\t\t\t\"upper_limit\": 49.99,\n\t\t\t\t\"shipping_cost\": 15\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"lower_limit\": 50,\n\t\t\t\t\"upper_limit\": 100000,\n\t\t\t\t\"shipping_cost\": 0\n\t\t\t} \n\t\t]\n\t}\n}\n\n```\n\n\n### Range Object – Properties \n\n\nObject model to define ranges for shipping quotes. Units are defined in the parent object.\n\n\n| Name | Type | Description |\n| - | - | - |\n| lower_limit | number | Lower limit for order total. |\n| upper_limit | number | Upper limit for order total. |\n| shipping_cost | number | Shipping cost for orders whose total falls between the lower and upper limits. |\n\n\n#### JSON Example \n\n\n```json\n\n{\n\t\"lower_limit\": 0,\n\t\"upper_limit\": 20,\n\t\"shipping_cost\": 8\n}\n\n```" + description: "Creates a *Shipping Method* within a shipping zone. Real Time Carrier\nConnections are also supported by this endpoint. \n\n\n## Carrier Configurations – Current\n\n\nThis section provides a sample request and a carrier-specific object/property model, for each supported carrier.\n \n### USPS by Endicia\n\n\n#### Sample Request\n\n\n\n```json\n\n{\n \"name\": \"USPS by Endicia\",\n \"type\": \"endicia\",\n \"settings\": {\n \"carrier_options\": {\n \"delivery_services\" : [\"PriorityExpress\",\"Priority\", \"PriorityMailExpressInternational\"],\n\t\t\t\"packaging_type\" : \"LargeFlatRateBox\",\n \"show_transit_time\" : true\n }\n },\n \"enabled\": true\n}\n\n```\n\n\n### USPS by Endicia Object Properties\n\n\n| Property | Type | Values |\n| - | - | - |\n| delivery_services | array | PriorityExpress
PriorityMailExpressInternational
FirstClassPackageInternationalService
Priority
PriorityMailInternational
First
ParcelSelect
MediaMail |\n| packaging_type | array | FlatRateLegalEnvelope
FlatRatePaddedEnvelope
Parcel
SmallFlatRateBox
MediumFlatRateBox
LargeFlatRateBox
FlatRateEnvelope
RegionalRateBoxA
RegionalRateBoxB |\n|show_transit_time | boolean | true
false |\n\n\n\n### FedEx\n\n\n#### Sample Request\n\n\n```json\n\n{\n \"name\": \"FEDEX\",\n \"type\": \"fedex\",\n \"settings\": {\n \"carrier_options\": {\n \"delivery_services\": [\n \"PRIORITY_OVERNIGHT\",\n\t\t\t\t\"FEDEX_2_DAY\"\n ],\n \"dropoff_type\": \"REGULAR_PICKUP\",\n \"packaging_type\": \"FEDEX_ENVELOPE\",\n \"packing_method\": \"SEPARATE\",\n \"rate_type\": \"NONE\",\n \"include_package_value\": true,\n \"destination_type\": \"residential\"\n }\n },\n \"enabled\": true\n}\n\n```\n\n\n#### FedEx Object Properties\n\n\n| Property | Type | Values |\n| - | - | - |\n| delivery_services | array | PRIORITY_OVERNIGHT
STANDARD_OVERNIGHT
FIRST_OVERNIGHT
FEDEX_2_DAY
FEDEX_EXPRESS_SAVER
INTERNATIONAL_PRIORITY
INTERNATIONAL_ECONOMY
INTERNATIONAL_FIRST
FEDEX_1_DAY_FREIGHT
FEDEX_2_DAY_FREIGHT
FEDEX_3_DAY_FREIGHT
FEDEX_GROUND
GROUND_HOME_DELIVERY
INTERNATIONAL_PRIORITY_FREIGHT
INTERNATIONAL_ECONOMY_FREIGHT
EUROPE_FIRST_INTERNATIONAL_PRIORITY |\n| dropoff_type | string | REGULAR_PICKUP
REQUEST_COURIER
DROP_BOX
BUSINESS_SERVICE_CENTER
STATION |\n| packaging_type | string | FEDEX_ENVELOPE
FEDEX_PAK
FEDEX_BOX
FEDEX_TUBE
FEDEX_10KG_BOX
FEDEX_25KG_BOX
YOUR_PACKAGING |\n| packing_method | string | SEPARATE
COMBINED |\n| rate_type | string | NONE
LIST |\n| include_package_value | boolean | true
false |\n| destination_type | string | residential
business |\n\n\n### UPS Ready\n\n\n#### Sample Request\n\n\n```json\n\n{\n \"name\": \"UPS ready\",\n \"type\": \"upsready\",\n \"settings\": {\n \"carrier_options\": {\n \"delivery_services\": [\n \"2nd_Day_Air\",\"Standard\"\n ],\n \"packaging_type\": \"21\",\n \"packing_method\": \"separate\",\n \"include_package_value\": true,\n \"destination_type\": \"residential\",\n \"show_transit_time\" : true\n }\n },\n \"enabled\": true\n}\n\n```\n\n\n#### UPS Ready Object Properties\n\n\n| Property | Type | Values |\n| - | - | - |\n| delivery_services | array | 2nd_Day_Air
2nd_Day_Air_AM
3_Day_Select
Expedited
Express
Express_Plus
Express_Saver
Express_Early_AM
Ground
Next_Day_Air
Next_Day_Air_Early_AM
Next_Day_Air_Saver
Saver
Standard
Today_Dedicated_Courier
Today_Express
Today_Express_Saver
Today_Intercity
Today_Standard
Worldwide_Expedited
Worldwide_Express
Worldwide_Express_Plus
Worldwide_Express_Saver
Worldwide_Saver |\n| destination_type | string | residential
business |\n| packing_method | string | separate
combined |\n| packaging_type | string (only codes allowed) | 21: UPS® Express Box
24: UPS® 25 KG Box
25: UPS® 10 KG Box
30: Pallet
01: UPS® Letter
02: Customer Supplied Package
03: Tube
04: PAK
2a: Small Express Box
2b: Medium Express Box
2c: Large Express Box |\n| include_package_value | boolean | true
false |\n| show_transit_time | boolean | true
false |\n\n\n### Canada Post\n\n\n#### Sample Request\n\n\n```json\n\n{\n \"name\": \"Canada Post\",\n \"type\": \"canadapost\",\n \"settings\": {\n \"carrier_options\": {\n \"delivery_services\": [\n \"DOM.RP\",\"DOM.EP\"\n ]\n }\n },\n \"enabled\": true\n}\n\n```\n\n\n#### Canada Post Object Properties\n\n\n| Property | Type | Values |\n| - | - | - |\n| delivery_services | array | DOM.RP
DOM.EP
DOM.XP
DOM.XP.CERT
DOM.PC DOM.LIB
USA.EP
USA.PW.ENV
USA.PW.PAK
USA.PW.PARCEL
USA.SP.AIR
USA.TP
USA.TP.LVM
USA.XP
INT.XP
INT.IP.AIR
INT.IP.SURF
INT.PW.ENV
INT.PW.PAK
INT.PW.PARCEL
INT.SP.AIR
INT.SP.SURF
INT.TP |\n\n\n### Australia Post\n\n\n```json\n\n{\n \"name\": \"Australia Post\",\n \"type\": \"auspost\",\n \"settings\": {\n \"carrier_options\": {\n \"delivery_services\": [\n \"AUS_PARCEL_REGULAR\",\n\t\t\t\t\"AUS_PARCEL_EXPRESS\"\n ]\n }\n },\n \"enabled\": true\n}\n\n```\n\n\n#### Australia Post Object Properties\n\n\n| Property | Type | Values |\n| - | - | - |\n| delivery_services | array | AUS_LETTER_REGULAR_SMALL
AUS_LETTER_REGULAR_Large
AUS_LETTER_EXPRESS_SMALL
AUS_LETTER_EXPRESS_MEDIUM
AUS_LETTER_EXPRESS_LARGE
AUS_PARCEL_REGULAR
AUS_PARCEL_REGULAR_SATCHEL_500G
AUS_PARCEL_REGULAR_SATCHEL_3KG
AUS_PARCEL_REGULAR_SATCHEL_5KG
AUS_PARCEL_EXPRESS
AUS_PARCEL_EXPRESS_SATCHEL_500G
AUS_PARCEL_EXPRESS_SATCHEL_3KG
AUS_PARCEL_EXPRESS_SATCHEL_5KG
AUS_PARCEL_COURIER
AUS_PARCEL_COURIER_SATCHEL_MEDIUM
INT_PARCEL_COR_OWN_PACKAGING
INT_PARCEL_EXP_OWN_PACKAGING
INT_PARCEL_STD_OWN_PACKAGING
INT_PARCEL_AIR_OWN_PACKAGING
INT_PARCEL_SEA_OWN_PACKAGING |\n\n\n### Royal Mail\n\n\n#### Sample Request\n\n\n```json\n\n{\n \"name\": \"Royal Mail\",\n \"type\": \"royalmail\",\n \"settings\": {\n \"carrier_options\": {\n \"delivery_services\": [\n \"StandardFirstClass\",\n\t\t\t\t\"StandardSecondClass\"\n ]\n }\n },\n \"enabled\": true\n}\n\n```\n\n\n#### Royal Mail Object Properties\n\n\n| Property | Type | Values |\n| - | - | - |\n| delivery_services | array | SpecialDelivery1pm
SpecialDelivery9am
SpecialDelivery1pmSaturday
SpecialDelivery9amSaturday
SignedForFirstClass
SignedForSecondClass
Express9
Express10
ExpressAM
Express24
Express48
StandardFirstClass
StandardSecondClass
InternationalStandard
InternationalTracked
InternationalEconomy |\n\n\n### Zoom2U\n\n\n#### Sample Request\n\n\n```json\n\n{\n \"name\": \"Zoom2U\",\n \"type\": \"zoom2u\",\n \"settings\": {\n \"carrier_options\": {\n \"delivery_services\": [\n \"3_hour\",\n\t\t\t\t\"Same_day\",\n\t\t\t\t\"VIP\"\n ]\n }\n },\n \"enabled\": true\n}\n\n```\n\n\n#### Zoom2U Object Properties\n\n\n| Property | Type | Values |\n| - | - | - |\n| delivery_services | array | 3_hour
Same_day
VIP|\n\n\n\n### Settings Objects \n\n\nA shipping method's `type` and `settings` properties can match one of the following models:\n\n\n### perorder Object – Properties \n\n\nObject model for flat-rate shipping quotes per order.\n\n\n| Name | Type | Description |\n| - | - | - |\n| rate | number | Flat rate per order. |\n\n\n#### JSON Example \n\n\n```json\n\n{\n\t\"name\": \"Flat Rate per Order\",\n\t\"type\": \"perorder\",\n\t\"settings\": {\n\t\t\"rate\": 7\n\t}\n},\n\n```\n\n\n### peritem Object – Properties \n\n\nObject model for flat-rate shipping quotes per item ordered.\n\n\n| Name | Type | Description |\n| - | - | - |\n| rate | number | Flat rate per item. |\n\n\n#### JSON Example \n\n\n```json\n\n{\n\t\"name\": \"Flat Rate per Item\",\n\t\"type\": \"peritem\",\n\t\"settings\": {\n\t\t\"rate\": 8\n\t}\n},\n\n```\n\n\n### weight Object – Properties \n\n\nObject model for shipping quotes by weight.\n\n\n| Name | Type | Description |\n| - | - | - |\n| default_cost | number | Default shipping cost, applied either as a percentage of the order's total value or as a fixed amount. |\n| default_cost_type | string | How the default shipping cost is calculated. One of: `percentage_of_total` or `fixed_amount`. |\n| range | number | Array of [range](#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. |\n\n\n\n#### JSON Example \n \n```json\n\n{\n\t\"name\": \"Rate per Weight\",\n\t\"type\": \"weight\",\n\t\"settings\": {\n\t\t\"default_cost\": 12,\n\t\t\"default_cost_type\": \"fixed_amount\",\n\t\t\"range\": [\n\t\t\t{\n\t\t\t\t\"lower_limit\": 0,\n\t\t\t\t\"upper_limit\": 20,\n\t\t\t\t\"shipping_cost\": 8\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"lower_limit\": 20,\n\t\t\t\t\"upper_limit\": 40,\n\t\t\t\t\"shipping_cost\": 12\n\t\t\t}\n\t\t]\n\t}\n}\n\n```\n\n\n### total Object – Properties \n\n\nObject model for shipping quotes by order's total value.\n\n\n| Name | Type | Description |\n| - | - | - |\n| default_cost | number | Default shipping cost, applied either as a percentage of the order's total value or as a fixed amount. |\n| default_cost_type | string | How the default shipping cost is calculated. One of: `percentage_of_total` or `fixed_amount`. |\n| include_order_total_taxes | boolean | Whether or not to include taxes on the order's total value in the shipping cost calculation. |\n| range | number | Array of [range](#range) objects. The units for these ranges' `lower_limit` and `upper_limit` properties are values in the store's currency. |\n\n\n#### JSON Example \n\n\nThis example sets free shipping above a certain order total:\n\n\n```json\n\n{\n\t\"name\": \"Per Total or Free\",\n\t\"type\": \"total\",\n\t\"settings\": {\n\t\t\"default_cost\": 12,\n\t\t\"default_cost_type\": \"fixed_amount\",\n\t\t\"include_order_total_taxes\": 0,\n\t\t\"range\": [\n\t\t\t{\n\t\t\t\t\"lower_limit\": 0,\n\t\t\t\t\"upper_limit\": 5,\n\t\t\t\t\"shipping_cost\": 5\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"lower_limit\": 5,\n\t\t\t\t\"upper_limit\": 10,\n\t\t\t\t\"shipping_cost\": 8\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"lower_limit\": 10,\n\t\t\t\t\"upper_limit\": 20,\n\t\t\t\t\"shipping_cost\": 10\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"lower_limit\": 20,\n\t\t\t\t\"upper_limit\": 49.99,\n\t\t\t\t\"shipping_cost\": 15\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"lower_limit\": 50,\n\t\t\t\t\"upper_limit\": 100000,\n\t\t\t\t\"shipping_cost\": 0\n\t\t\t} \n\t\t]\n\t}\n}\n\n```\n\n\n### Range Object – Properties \n\n\nObject model to define ranges for shipping quotes. Units are defined in the parent object.\n\n\n| Name | Type | Description |\n| - | - | - |\n| lower_limit | number | Lower limit for order total. |\n| upper_limit | number | Upper limit for order total. |\n| shipping_cost | number | Shipping cost for orders whose total falls between the lower and upper limits. |\n\n\n#### JSON Example \n\n\n```json\n\n{\n\t\"lower_limit\": 0,\n\t\"upper_limit\": 20,\n\t\"shipping_cost\": 8\n}\n\n```" summary: Create a Shipping Method tags: - Shipping Method @@ -874,7 +939,7 @@ paths: - name: zone_id in: path required: true - description: Id of the shipping zone. + description: ID of the shipping zone. schema: type: integer exclusiveMinimum: false @@ -1039,7 +1104,7 @@ paths: | - | - | - | | 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. | + | 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](#range) objects. The units for these ranges' `lower_limit` and `upper_limit` properties are values in the store's currency. | #### JSON Example @@ -1111,7 +1176,7 @@ paths: - name: zone_id in: path required: true - description: Id of the shipping zone. + description: ID of the shipping zone. schema: type: integer exclusiveMinimum: false @@ -1119,7 +1184,7 @@ paths: - name: method_id in: path required: true - description: Id of the shipping method within the shipping zone. + description: ID of the shipping method within the shipping zone. schema: type: integer exclusiveMinimum: false @@ -1148,9 +1213,10 @@ paths: type: object properties: id: - description: Shipping-method ID. READ-ONLY + description: Shipping method ID. Read-only. example: 1 type: integer + readOnly: true name: description: Display name for shipping method. example: Flat Rate @@ -1195,24 +1261,26 @@ paths: - royalmail - upsready settings: - description: 'Depends on the shipping-method type. See the [supported settings object](#supported-settings).' + description: 'Depends on the shipping method type. See the [supported settings object](#supported-settings).' type: object enabled: - description: Whether or not this shipping-zone method is enabled. + description: Whether or not this shipping zone method is enabled. example: true type: boolean handling_fees: oneOf: - - properties: - fixed_surcharge: - type: number - description: Flat-rate handling fee applied to shipping cost - example: 0 - - properties: - percentage_surcharge: - type: number - description: Percentage handling fee applied to shipping cost - example: 0 + - properties: + fixed_surcharge: + type: number + description: Flat-rate handling fee applied to shipping cost. + example: 0 + title: fixed surcharge + - properties: + percentage_surcharge: + type: number + description: Percentage handling fee applied to shipping cost. + example: 0 + title: percentage surcharge type: object is_fallback: description: Whether or not this shipping zone is the fallback if all others are not valid for the order. @@ -1249,7 +1317,7 @@ paths: IsMultiContentStreaming: false operationId: getAShippingMethod put: - description: "Updates a *Shipping Method* in a zone. Real Time Carrier Connections are also supported by this endpoint. \n\n**Read Only Fields**\n* id\n\n### Settings Objects \n\nA shipping method's `type` and `settings` properties can match one of the following models:\n\n### perorder Object – Properties \n\nObject model for flat-rate shipping quotes per order.\n\n| Name | Type | Description |\n| - | - | - |\n| rate | number | Flat rate per order. |\n\n#### JSON Example \n\n```json\n{\n\t\"name\": \"Flat Rate per Order\",\n\t\"type\": \"perorder\",\n\t\"settings\": {\n\t\t\"rate\": 7\n\t}\n},\n```\n\n### peritem Object – Properties \n\nObject model for flat-rate shipping quotes per item ordered.\n\n| Name | Type | Description |\n| - | - | - |\n| rate | number | Flat rate per item. |\n\n#### JSON Example \n\n```json\n{\n\t\"name\": \"Flat Rate per Item\",\n\t\"type\": \"peritem\",\n\t\"settings\": {\n\t\t\"rate\": 8\n\t}\n},\n```\n\n### weight Object – Properties \n\nObject model for shipping quotes by weight.\n\n| Name | Type | Description |\n| - | - | - |\n| default_cost | number | Default shipping cost, applied either as a percentage of the order's total value or as a fixed amount. |\n| default_cost_type | string | How the default shipping cost is calculated. One of: `percentage_of_total` or `fixed_amount`. |\n| range | number | Array of [range](#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. |\n\n\n#### JSON Example \n \n```json\n{\n\t\"name\": \"Rate per Weight\",\n\t\"type\": \"weight\",\n\t\"settings\": {\n\t\t\"default_cost\": 12,\n\t\t\"default_cost_type\": \"fixed_amount\",\n\t\t\"range\": [\n\t\t\t{\n\t\t\t\t\"lower_limit\": 0,\n\t\t\t\t\"upper_limit\": 20,\n\t\t\t\t\"shipping_cost\": 8\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"lower_limit\": 20,\n\t\t\t\t\"upper_limit\": 40,\n\t\t\t\t\"shipping_cost\": 12\n\t\t\t}\n\t\t]\n\t}\n}\n```\n\n### total Object – Properties \n\nObject model for shipping quotes by order's total value.\n\n| Name | Type | Description |\n| - | - | - |\n| default_cost | number | Default shipping cost, applied either as a percentage of the order's total value or as a fixed amount. |\n| default_cost_type | string | How the default shipping cost is calculated. One of: `percentage_of_total` or `fixed_amount`. |\n| include_order_total_taxes | boolean | Whether or not to include taxes on the order's total value in the shipping-cost calculation. |\n| range | number | Array of [range](#range) objects. The units for these ranges' `lower_limit` and `upper_limit` properties are values in the store's currency. |\n\n#### JSON Example \n\nThis example sets free shipping above a certain order total:\n\n```json\n{\n\t\"name\": \"Per Total or Free\",\n\t\"type\": \"total\",\n\t\"settings\": {\n\t\t\"default_cost\": 12,\n\t\t\"default_cost_type\": \"fixed_amount\",\n\t\t\"include_order_total_taxes\": 0,\n\t\t\"range\": [\n\t\t\t{\n\t\t\t\t\"lower_limit\": 0,\n\t\t\t\t\"upper_limit\": 5,\n\t\t\t\t\"shipping_cost\": 5\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"lower_limit\": 5,\n\t\t\t\t\"upper_limit\": 10,\n\t\t\t\t\"shipping_cost\": 8\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"lower_limit\": 10,\n\t\t\t\t\"upper_limit\": 20,\n\t\t\t\t\"shipping_cost\": 10\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"lower_limit\": 20,\n\t\t\t\t\"upper_limit\": 49.99,\n\t\t\t\t\"shipping_cost\": 15\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"lower_limit\": 50,\n\t\t\t\t\"upper_limit\": 100000,\n\t\t\t\t\"shipping_cost\": 0\n\t\t\t} \n\t\t]\n\t}\n}\n```\n\n### Range Object – Properties \n\nObject model to define ranges for shipping quotes. Units are defined in the parent object.\n\n| Name | Type | Description |\n| - | - | - |\n| lower_limit | number | Lower limit for order total. |\n| upper_limit | number | Upper limit for order total. |\n| shipping_cost | number | Shipping cost for orders whose total falls between the lower and upper limits. |\n\n#### JSON Example \n\n```json\n{\n\t\"lower_limit\": 0,\n\t\"upper_limit\": 20,\n\t\"shipping_cost\": 8\n}\n```\n" + description: "Updates a *Shipping Method* in a zone. Real Time Carrier Connections are also supported by this endpoint. \n\n**Read Only Fields**\n* id\n\n### Settings Objects \n\nA shipping method's `type` and `settings` properties can match one of the following models:\n\n### perorder Object – Properties \n\nObject model for flat-rate shipping quotes per order.\n\n| Name | Type | Description |\n| - | - | - |\n| rate | number | Flat rate per order. |\n\n#### JSON Example \n\n```json\n{\n\t\"name\": \"Flat Rate per Order\",\n\t\"type\": \"perorder\",\n\t\"settings\": {\n\t\t\"rate\": 7\n\t}\n},\n```\n\n### peritem Object – Properties \n\nObject model for flat-rate shipping quotes per item ordered.\n\n| Name | Type | Description |\n| - | - | - |\n| rate | number | Flat rate per item. |\n\n#### JSON Example \n\n```json\n{\n\t\"name\": \"Flat Rate per Item\",\n\t\"type\": \"peritem\",\n\t\"settings\": {\n\t\t\"rate\": 8\n\t}\n},\n```\n\n### weight Object – Properties \n\nObject model for shipping quotes by weight.\n\n| Name | Type | Description |\n| - | - | - |\n| default_cost | number | Default shipping cost, applied either as a percentage of the order's total value or as a fixed amount. |\n| default_cost_type | string | How the default shipping cost is calculated. One of: `percentage_of_total` or `fixed_amount`. |\n| range | number | Array of [range](#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. |\n\n\n#### JSON Example \n \n```json\n{\n\t\"name\": \"Rate per Weight\",\n\t\"type\": \"weight\",\n\t\"settings\": {\n\t\t\"default_cost\": 12,\n\t\t\"default_cost_type\": \"fixed_amount\",\n\t\t\"range\": [\n\t\t\t{\n\t\t\t\t\"lower_limit\": 0,\n\t\t\t\t\"upper_limit\": 20,\n\t\t\t\t\"shipping_cost\": 8\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"lower_limit\": 20,\n\t\t\t\t\"upper_limit\": 40,\n\t\t\t\t\"shipping_cost\": 12\n\t\t\t}\n\t\t]\n\t}\n}\n```\n\n### total Object – Properties \n\nObject model for shipping quotes by order's total value.\n\n| Name | Type | Description |\n| - | - | - |\n| default_cost | number | Default shipping cost, applied either as a percentage of the order's total value or as a fixed amount. |\n| default_cost_type | string | How the default shipping cost is calculated. One of: `percentage_of_total` or `fixed_amount`. |\n| include_order_total_taxes | boolean | Whether or not to include taxes on the order's total value in the shipping cost calculation. |\n| range | number | Array of [range](#range) objects. The units for these ranges' `lower_limit` and `upper_limit` properties are values in the store's currency. |\n\n#### JSON Example \n\nThis example sets free shipping above a certain order total:\n\n```json\n{\n\t\"name\": \"Per Total or Free\",\n\t\"type\": \"total\",\n\t\"settings\": {\n\t\t\"default_cost\": 12,\n\t\t\"default_cost_type\": \"fixed_amount\",\n\t\t\"include_order_total_taxes\": 0,\n\t\t\"range\": [\n\t\t\t{\n\t\t\t\t\"lower_limit\": 0,\n\t\t\t\t\"upper_limit\": 5,\n\t\t\t\t\"shipping_cost\": 5\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"lower_limit\": 5,\n\t\t\t\t\"upper_limit\": 10,\n\t\t\t\t\"shipping_cost\": 8\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"lower_limit\": 10,\n\t\t\t\t\"upper_limit\": 20,\n\t\t\t\t\"shipping_cost\": 10\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"lower_limit\": 20,\n\t\t\t\t\"upper_limit\": 49.99,\n\t\t\t\t\"shipping_cost\": 15\n\t\t\t},\n\t\t\t{\n\t\t\t\t\"lower_limit\": 50,\n\t\t\t\t\"upper_limit\": 100000,\n\t\t\t\t\"shipping_cost\": 0\n\t\t\t} \n\t\t]\n\t}\n}\n```\n\n### Range Object – Properties \n\nObject model to define ranges for shipping quotes. Units are defined in the parent object.\n\n| Name | Type | Description |\n| - | - | - |\n| lower_limit | number | Lower limit for order total. |\n| upper_limit | number | Upper limit for order total. |\n| shipping_cost | number | Shipping cost for orders whose total falls between the lower and upper limits. |\n\n#### JSON Example \n\n```json\n{\n\t\"lower_limit\": 0,\n\t\"upper_limit\": 20,\n\t\"shipping_cost\": 8\n}\n```\n" summary: Update a Shipping Method tags: - Shipping Method @@ -1257,7 +1325,7 @@ paths: - name: zone_id in: path required: true - description: Id of the shipping zone. + description: ID of the shipping zone. schema: type: integer exclusiveMinimum: false @@ -1265,7 +1333,7 @@ paths: - name: method_id in: path required: true - description: Id of the shipping method within the shipping zone. + description: ID of the shipping method within the shipping zone. schema: type: integer exclusiveMinimum: false @@ -1341,7 +1409,7 @@ paths: - name: zone_id in: path required: true - description: Id of the shipping zone. + description: ID of the shipping zone. schema: type: integer exclusiveMinimum: false @@ -1349,7 +1417,7 @@ paths: - name: method_id in: path required: true - description: Id of the shipping method within the shipping zone. + description: ID of the shipping method within the shipping zone. schema: type: integer exclusiveMinimum: false @@ -1432,10 +1500,10 @@ paths: pass_phrase: yourEndiciaPassphrase responses: '204': - description: Returns if request was succesful + description: Returns if request was successful. '400': description: |- - If a required field is not provided it will return a 400 response. + If a required field is not provided, the request will return a 400 response. [ { @@ -1448,7 +1516,7 @@ paths: schema: {} operationId: updateACarrierConnection post: - description: "Creates a *Carrier Connection*. \n\nCarrier connections refer to specific settings required to connect to a specific shipping carrier. Each carrier requires your app to supply a unique set of properties/fields to establish a connection with that carrier.\n\n*Notes:*\n\n- There is no `GET` with this resource. It has `PUT`, `POST` and `DELETE`.\n * `PUT` is used to update. The connection can be updated via API.\n\n \n- Connections created here do not enable the shipping method. To enable the carrier for a shipping zone, use the Shipping Methods API. \n\n- The Carrier Connection resource returns a 204 for both succesful and unsuccesful attempts to connect. If a field is missing, it will return a 400.\n\n### Australia Post\n\n#### Sample Request – PUT or POST\n\n```json\n{\n\t\"carrier_id\" : \"auspost\",\n\t\"connection\" : {\n\t\t\"auth_key\" : \"yourAusPostAuthKey\",\n\t\t\"test_mode\" : false\n\t}\n}\n```\n\n#### Sample Request – DELETE\n\n```json\n{\n\t\"carrier_id\" : \"auspost\"\n}\n```\n\n#### Australia Post Connection Object – Properties\n\nAustralia Post `PUT` or `POST` requests require all of the following properties. (These requests won’t be fulfilled unless these properties are valid.) `DELETE` requests require only a `carrier_id`.\n\n\n| Property | Type | Description\n| - | - | - |\n| auth_key | string | Australia Post authorization key. |\n| test_mode | boolean | Whether or not to use Australia Post test-mode settings. Acceptable values are `true` or `false`. |\n\n\n### Endicia\nUSPS is connected through Endicia.\n\n#### Sample Request – PUT or POST\n\n```json\n{\t\"carrier_id\" : \"endicia\",\n\t\"connection\": {\n\t\t\"account_id\" : \"yourEndiciaAccountId\",\n\t\t\"pass_phrase\" : \"yourEndiciaPassphrase\"\n\t}\n}\n```\n\n#### Sample Request – DELETE\n\n```json\n{\n\t\"carrier_id\" : \"endicia\"\n}\n```\n\n#### Endicia Connection Object – Properties\n\nEndicia `PUT` or `POST` requests require all of the following properties. (These requests won’t be fulfilled unless these properties are valid.) `DELETE` requests require only a `carrier_id`.\n\n\n| Property | Type | Description |\n| - | - | - |\n| account_id | string | Endicia account ID. |\n| passphrase | string | Endicia passphrase. |\n\n\n### FedEx\n\n#### Sample Request – PUT or POST\n\n```json\n{\n\t\"carrier_id\" : \"fedex\",\n\t\"connection\" : {\n\t\t\"key\" : \"yourFedexKey\",\n\t\t\"password\" : \"yourFedexPassword\",\n\t\t\"account_number\" : \"yourFedexAccountNumber\",\n\t\t\"meter_number\" : \"yourFedexMeterNumber\"\n\t}\n}\n```\n\n#### Sample Request – DELETE\n\n```json\n{\n\t\"carrier_id\" : \"fedex\"\n}\n```\n\n#### FedEx Connection Object – Properties\n\nFedEx `PUT` or `POST` requests require all of the following properties. (These requests won’t be fulfilled unless these properties are valid.) `DELETE` requests require only a `carrier_id`.\n\n\n| Property | Type | Description | \n| - | - | - |\n| key | string | FedEx account ID. | \n| password | string | FedEx passphrase. |\n| account_number | string | FedEx account number. |\n| meter_number | string | FedEx meter number. |\n\n### Royal Mail\n\nSample Request - PUT or POST\n\n```json\n{\n \"carrier_id\" : \"royalmail\",\n \"connection\" : {\n \n }\n}\n```\n\nSample Request - DELETE\n\n```json\n{\n \"carrier_id\" : \"royalmail\"\n}\n```\n\n#### Royal Mail Connection Object - Properties\n\nRoyal Mail has no connection object properties.\n\n\n### Zoom2U\n\n#### Sample Request – PUT or POST\n\n```json\n{\n\t\"carrier_id\" : \"zoom2u\",\n\t\"connection\" : {\n\t\t\"auth_key\" : \"yourZoom2uAuthKey\",\n\t\t\"test_mode\" : false\n\t}\n}\n```\n\n#### Sample Request – DELETE\n\n```json\n{\n\t\"carrier_id\" : \"zoom2u\"\n}\n```\n\n#### Zoom2U Connection Object – Properties\n\nZoom2U `PUT` or `POST` requests require all of the following properties. (These requests won’t be fulfilled unless these properties are valid.) `DELETE` requests require only a `carrier_id`.\n\n\n| Property | Type | Description | \n| - | - | - |\n| auth_key | string | Zoom2U authorization key. |\n| test_mode | boolean | Whether or not to use Zoom2U test-mode settings. Acceptable values are `true` or `false`. |" + description: "Creates a *Carrier Connection*. \n\nCarrier connections refer to specific settings required to connect to a specific shipping carrier. Each carrier requires your app to supply a unique set of properties/fields to establish a connection with that carrier.\n\n*Notes:*\n\n- There is no `GET` with this resource. It has `PUT`, `POST` and `DELETE`.\n * `PUT` is used to update. The connection can be updated by API.\n\n \n- Connections created here do not enable the shipping method. To enable the carrier for a shipping zone, use the Shipping Methods API. \n\n- The Carrier Connection resource returns a 204 for both successful and unsuccessful attempts to connect. If a field is missing, it will return a 400.\n\n### Australia Post\n\n#### Sample Request – PUT or POST\n\n```json\n{\n\t\"carrier_id\" : \"auspost\",\n\t\"connection\" : {\n\t\t\"auth_key\" : \"yourAusPostAuthKey\",\n\t\t\"test_mode\" : false\n\t}\n}\n```\n\n#### Sample Request – DELETE\n\n```json\n{\n\t\"carrier_id\" : \"auspost\"\n}\n```\n\n#### Australia Post Connection Object – Properties\n\nAustralia Post `PUT` or `POST` requests require all of the following properties. (These requests won’t be fulfilled unless these properties are valid.) `DELETE` requests require only a `carrier_id`.\n\n\n| Property | Type | Description\n| - | - | - |\n| auth_key | string | Australia Post authorization key. |\n| test_mode | boolean | Whether or not to use Australia Post test-mode settings. Acceptable values are `true` or `false`. |\n\n\n### Endicia\nUSPS is connected through Endicia.\n\n#### Sample Request – PUT or POST\n\n```json\n{\t\"carrier_id\" : \"endicia\",\n\t\"connection\": {\n\t\t\"account_id\" : \"yourEndiciaAccountId\",\n\t\t\"pass_phrase\" : \"yourEndiciaPassphrase\"\n\t}\n}\n```\n\n#### Sample Request – DELETE\n\n```json\n{\n\t\"carrier_id\" : \"endicia\"\n}\n```\n\n#### Endicia Connection Object – Properties\n\nEndicia `PUT` or `POST` requests require all of the following properties. (These requests won’t be fulfilled unless these properties are valid.) `DELETE` requests require only a `carrier_id`.\n\n\n| Property | Type | Description |\n| - | - | - |\n| account_id | string | Endicia account ID. |\n| passphrase | string | Endicia passphrase. |\n\n\n### FedEx\n\n#### Sample Request – PUT or POST\n\n```json\n{\n\t\"carrier_id\" : \"fedex\",\n\t\"connection\" : {\n\t\t\"key\" : \"yourFedexKey\",\n\t\t\"password\" : \"yourFedexPassword\",\n\t\t\"account_number\" : \"yourFedexAccountNumber\",\n\t\t\"meter_number\" : \"yourFedexMeterNumber\"\n\t}\n}\n```\n\n#### Sample Request – DELETE\n\n```json\n{\n\t\"carrier_id\" : \"fedex\"\n}\n```\n\n#### FedEx Connection Object – Properties\n\nFedEx `PUT` or `POST` requests require all of the following properties. (These requests won’t be fulfilled unless these properties are valid.) `DELETE` requests require only a `carrier_id`.\n\n\n| Property | Type | Description | \n| - | - | - |\n| key | string | FedEx account ID. | \n| password | string | FedEx passphrase. |\n| account_number | string | FedEx account number. |\n| meter_number | string | FedEx meter number. |\n\n### Royal Mail\n\nSample Request - PUT or POST\n\n```json\n{\n \"carrier_id\" : \"royalmail\",\n \"connection\" : {\n \n }\n}\n```\n\nSample Request - DELETE\n\n```json\n{\n \"carrier_id\" : \"royalmail\"\n}\n```\n\n#### Royal Mail Connection Object - Properties\n\nRoyal Mail has no connection object properties.\n\n\n### Zoom2U\n\n#### Sample Request – PUT or POST\n\n```json\n{\n\t\"carrier_id\" : \"zoom2u\",\n\t\"connection\" : {\n\t\t\"auth_key\" : \"yourZoom2uAuthKey\",\n\t\t\"test_mode\" : false\n\t}\n}\n```\n\n#### Sample Request – DELETE\n\n```json\n{\n\t\"carrier_id\" : \"zoom2u\"\n}\n```\n\n#### Zoom2U Connection Object – Properties\n\nZoom2U `PUT` or `POST` requests require all of the following properties. (These requests won’t be fulfilled unless these properties are valid.) `DELETE` requests require only a `carrier_id`.\n\n\n| Property | Type | Description | \n| - | - | - |\n| auth_key | string | Zoom2U authorization key. |\n| test_mode | boolean | Whether or not to use Zoom2U test-mode settings. Acceptable values are `true` or `false`. |" summary: Create a Carrier Connection parameters: - name: Accept @@ -1478,7 +1546,7 @@ paths: test_mode: false responses: '204': - description: Returns if request was succesful + description: Returns if request was successful. '400': description: | Invalid requests will return a 400 response. @@ -1551,10 +1619,10 @@ paths: carrier_id: fedex responses: '204': - description: Returns if request was succesful + description: Returns if request was successful. '400': description: |- - If a required field is not provided it will return a 400 response. + If a required field is not provided, the request will return a 400 response. [ { @@ -1578,19 +1646,6 @@ paths: required: true schema: type: string -tags: - - name: Shipping Method - - name: Shipping Carrier - - name: Shipping Zones - - name: Shipping Products Custom Information -security: - - X-Auth-Token: [] -x-stoplight: - docs: - includeDownloadLink: true - showModels: false -servers: - - url: 'https://api.bigcommerce.com' components: securitySchemes: X-Auth-Token: @@ -1701,11 +1756,12 @@ components: properties: id: type: integer - description: Zone Id. READ-ONLY + description: Zone ID. Read-only. example: 1 + readOnly: true name: type: string - description: Zone name. Required for /PUT + description: Zone name. Required for PUT requests. example: United States type: type: string @@ -1751,18 +1807,27 @@ components: handling_fees: title: Shipping Zone Handling Fees type: object - properties: - fixed_surcharge: - description: '' - example: '0' - type: string - percentage_surcharge: - description: '' - type: string - display_separately: - description: '' - example: true - type: boolean + oneOf: + - properties: + fixed_surcharge: + description: Flat-rate handling fee applied to shipping cost. + example: '0' + type: string + display_separately: + description: Indicates whether store displays handling fee separately at checkout. + example: true + type: boolean + title: fixed surcharge + - properties: + percentage_surcharge: + description: Percentage handling fee applied to shipping cost. + example: '5' + type: string + display_separately: + description: Indicates whether store displays handling fee separately at checkout. + example: true + type: boolean + title: percentage surcharge enabled: description: Whether this shipping zone is enabled. example: true @@ -1794,18 +1859,27 @@ components: HandlingFees: title: Shipping Zone Handling Fees type: object - properties: - fixed_surcharge: - description: '' - example: '0' - type: string - percentage_surcharge: - description: '' - type: string - display_separately: - description: '' - example: true - type: boolean + oneOf: + - properties: + fixed_surcharge: + description: Flat-rate handling fee applied to shipping cost. + example: '0' + type: string + display_separately: + description: Indicates whether store displays handling fee separately at checkout. + example: true + type: boolean + title: fixed surcharge + - properties: + percentage_surcharge: + description: Percentage handling fee applied to shipping cost. + example: '5' + type: string + display_separately: + description: Indicates whether store displays handling fee separately at checkout. + example: true + type: boolean + title: percentage surcharge x-internal: false shippingMethod_Full: title: shippingMethod_Full @@ -1813,9 +1887,10 @@ components: - type: object properties: id: - description: Shipping-method ID. READ-ONLY + description: Shipping method ID. Read-only. example: 1 type: integer + readOnly: true - $ref: '#/components/schemas/shippingMethod_Base' x-internal: false ShippingMethodType: @@ -1907,30 +1982,31 @@ components: - royalmail - upsready settings: - description: 'Depends on the shipping-method type. See the [supported settings object](#supported-settings).' + description: 'Depends on the shipping method type. See the [supported settings object](#supported-settings).' type: object properties: rate: type: number - description: 'Flat rate per order. ' + description: Flat rate per order. example: 7 enabled: - description: Whether or not this shipping-zone method is enabled. + description: Whether or not this shipping zone method is enabled. example: true type: boolean handling_fees: oneOf: - - properties: - fixed_surcharge: - type: number - description: Flat-rate handling fee applied to shipping cost - example: 0 - - properties: - percentage_surcharge: - type: number - description: | - Percentage handling fee applied to shipping cost - example: 0 + - properties: + fixed_surcharge: + type: number + description: Flat-rate handling fee applied to shipping cost. + example: 0 + title: fixed surcharge + - properties: + percentage_surcharge: + type: number + description: Percentage handling fee applied to shipping cost. + example: 0 + title: percentage surcharge type: object is_fallback: description: Whether or not this shipping zone is the fallback if all others are not valid for the order. @@ -1949,11 +2025,11 @@ components: type: string connection: type: object - description: '`connection` object varies by carrier' + description: 'The `connection` object varies by carrier.' x-internal: false metaCollection: title: metaCollection - description: Meta data relating to pagination + description: Meta data relating to pagination. type: object properties: pagination: @@ -1995,3 +2071,7 @@ components: description: Query string appended to the resource to show the current page. example: '?limit=1&page=2' x-internal: false +x-stoplight: + docs: + includeDownloadLink: true + showModels: false