Shipping > Shipping Providers > shippingProvidersModify
Commerce APIShippingShipping ProvidersshippingProvidersModify
shippingProvidersModify
POST:shipping_providers.json

Description

Modify one or multiple shipping providers.

Permission bit: "shipping_providers.modify"

Topic: Shipping Providers

Arguments

data: [ShippingProviderModify!]!

Main argument for mutations.


ids: [String!]!

List of shipping provider ids. See also: Unique Identifiers

Example: ["sp_EQzGqWoY"]


shop_id: String!

Unique shop identifier. See also: Unique Identifiers

Example: "sh_EQzGqWoY"


Data Argument Fields

auspost_options: AuspostOptionsCreate


canadapost_options: CanadapostOptionsCreate


currency: String

Currency code for shipping provider to use

Example: "USD"


delivery_date_guaranteed: Boolean

Whether delivery date is guaranteed or not (fixed providers)

Example: true


delivery_days_max: Int

Maximum days it would take to deliver a package (fixed providers)

Example: 5

Valid when: delivery_days_max is a non-negative integer


delivery_days_min: Int

Minimum days it would take to deliver a package (fixed providers)

Example: 2

Valid when: delivery_days_min is a non-negative integer


description: String

Description text visible to the customer

Translatable

Example: "TODO"

Valid when: description's length doesn't exceed 4096 characters


fedex_options: FedexOptionsCreate


lead_time_hours_max: Int

The maximum amount of time the inventory location will take to fulfill the order using this shipping provider

Example: 5

Valid when: lead_time_hours_max is a non-negative integer


lead_time_hours_min: Int

The minimum amount of time the inventory location will take to fulfill the order using this shipping provider

Example: 2

Valid when: lead_time_hours_min is a non-negative integer


name: String

Name of the shipping provider

Translatable

Example: "Fixed 20$"

Valid when: name is not empty

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


rate: Int

Shipping rate for fixed providers

Example: 2000

Valid when: rate is a non-negative integer


surcharge_fixed: Int

For non-fixed shipping provider types, fixed amount to add on top of the rate

Example: 500

Valid when: surcharge_fixed is a non-negative integer


surcharge_percentage: Float

For non-fixed shipping provider types, percentage to add on top of the rate

Example: 1.0

Valid when: surcharge_percentage is valid percentage, i.e.: 0 ≤ surcharge_percentage ≤ 100


test: Boolean

Whether shipping provider test mode is enabled

Example: false


tracking: Boolean

Is it allowed to use this shipping provider for tracking requests?

Example: true


type: ShippingProviderType

Type of the shipping provider


ups_options: UPSOptionsCreate


usps_options: USPSOptionsCreate


whitelist: [ShippingProviderWhitelistCreate!]

Shipping rate whilelist for non-fixed providers


Result

[ShippingProvider!]

Preview (typescript)

Loading module