Create order batch
POST/v1/batches/orders
Create order batch. Beta
Request
- application/json
Body
required
Array [
Array [
]
]
orders
object[]
required
The list of orders to process.
The source' order id.
The order date. format: YYYY-MM-DD
Default value: API
The order's source.
e.g. API, POS, ERP, Shopify, Woocommerce, etc.
shipping_to
object
required
Possible values: <= 10 characters
The address postal code (required for shipment purchase)
Possible values: <= 30 characters
The address city. (required for shipment purchase)
Possible values: <= 20 characters
The party frederal tax id
Possible values: <= 20 characters
The party state id
Possible values: <= 50 characters
Attention to (required for shipment purchase)
Possible values: <= 50 characters
The company name if the party is a company
Possible values: [AC
, AD
, AE
, AF
, AG
, AI
, AL
, AM
, AN
, AO
, AR
, AS
, AT
, AU
, AW
, AZ
, BA
, BB
, BD
, BE
, BF
, BG
, BH
, BI
, BJ
, BM
, BN
, BO
, BR
, BS
, BT
, BW
, BY
, BZ
, CA
, CD
, CF
, CG
, CH
, CI
, CK
, CL
, CM
, CN
, CO
, CR
, CU
, CV
, CY
, CZ
, DE
, DJ
, DK
, DM
, DO
, DZ
, EC
, EE
, EG
, ER
, ES
, ET
, FI
, FJ
, FK
, FM
, FO
, FR
, GA
, GB
, GD
, GE
, GF
, GG
, GH
, GI
, GL
, GM
, GN
, GP
, GQ
, GR
, GT
, GU
, GW
, GY
, HK
, HN
, HR
, HT
, HU
, IC
, ID
, IE
, IL
, IN
, IQ
, IR
, IS
, IT
, JE
, JM
, JO
, JP
, KE
, KG
, KH
, KI
, KM
, KN
, KP
, KR
, KV
, KW
, KY
, KZ
, LA
, LB
, LC
, LI
, LK
, LR
, LS
, LT
, LU
, LV
, LY
, MA
, MC
, MD
, ME
, MG
, MH
, MK
, ML
, MM
, MN
, MO
, MP
, MQ
, MR
, MS
, MT
, MU
, MV
, MW
, MX
, MY
, MZ
, NA
, NC
, NE
, NG
, NI
, NL
, NO
, NP
, NR
, NU
, NZ
, OM
, PA
, PE
, PF
, PG
, PH
, PK
, PL
, PR
, PT
, PW
, PY
, QA
, RE
, RO
, RS
, RU
, RW
, SA
, SB
, SC
, SD
, SE
, SG
, SH
, SI
, SK
, SL
, SM
, SN
, SO
, SR
, SS
, ST
, SV
, SY
, SZ
, TC
, TD
, TG
, TH
, TJ
, TL
, TN
, TO
, TR
, TT
, TV
, TW
, TZ
, UA
, UG
, US
, UY
, UZ
, VA
, VC
, VE
, VG
, VI
, VN
, VU
, WS
, XB
, XC
, XE
, XM
, XN
, XS
, XY
, YE
, YT
, ZA
, ZM
, ZW
, EH
, IM
, BL
, MF
, SX
]
The address country code
The party email
Possible values: <= 20 characters
The party phone number.
Possible values: <= 20 characters
The address state code
Indicate if the address is residential or commercial (enterprise)
Possible values: <= 20 characters
The address street number
Possible values: <= 50 characters
The address line with street number
(required for shipment purchase)
Possible values: <= 50 characters
The address line with suite number
Indicate if the address should be validated
shipping_from
object
nullable
Possible values: <= 10 characters
The address postal code (required for shipment purchase)
Possible values: <= 30 characters
The address city. (required for shipment purchase)
Possible values: <= 20 characters
The party frederal tax id
Possible values: <= 20 characters
The party state id
Possible values: <= 50 characters
Attention to (required for shipment purchase)
Possible values: <= 50 characters
The company name if the party is a company
Possible values: [AC
, AD
, AE
, AF
, AG
, AI
, AL
, AM
, AN
, AO
, AR
, AS
, AT
, AU
, AW
, AZ
, BA
, BB
, BD
, BE
, BF
, BG
, BH
, BI
, BJ
, BM
, BN
, BO
, BR
, BS
, BT
, BW
, BY
, BZ
, CA
, CD
, CF
, CG
, CH
, CI
, CK
, CL
, CM
, CN
, CO
, CR
, CU
, CV
, CY
, CZ
, DE
, DJ
, DK
, DM
, DO
, DZ
, EC
, EE
, EG
, ER
, ES
, ET
, FI
, FJ
, FK
, FM
, FO
, FR
, GA
, GB
, GD
, GE
, GF
, GG
, GH
, GI
, GL
, GM
, GN
, GP
, GQ
, GR
, GT
, GU
, GW
, GY
, HK
, HN
, HR
, HT
, HU
, IC
, ID
, IE
, IL
, IN
, IQ
, IR
, IS
, IT
, JE
, JM
, JO
, JP
, KE
, KG
, KH
, KI
, KM
, KN
, KP
, KR
, KV
, KW
, KY
, KZ
, LA
, LB
, LC
, LI
, LK
, LR
, LS
, LT
, LU
, LV
, LY
, MA
, MC
, MD
, ME
, MG
, MH
, MK
, ML
, MM
, MN
, MO
, MP
, MQ
, MR
, MS
, MT
, MU
, MV
, MW
, MX
, MY
, MZ
, NA
, NC
, NE
, NG
, NI
, NL
, NO
, NP
, NR
, NU
, NZ
, OM
, PA
, PE
, PF
, PG
, PH
, PK
, PL
, PR
, PT
, PW
, PY
, QA
, RE
, RO
, RS
, RU
, RW
, SA
, SB
, SC
, SD
, SE
, SG
, SH
, SI
, SK
, SL
, SM
, SN
, SO
, SR
, SS
, ST
, SV
, SY
, SZ
, TC
, TD
, TG
, TH
, TJ
, TL
, TN
, TO
, TR
, TT
, TV
, TW
, TZ
, UA
, UG
, US
, UY
, UZ
, VA
, VC
, VE
, VG
, VI
, VN
, VU
, WS
, XB
, XC
, XE
, XM
, XN
, XS
, XY
, YE
, YT
, ZA
, ZM
, ZW
, EH
, IM
, BL
, MF
, SX
]
The address country code
The party email
Possible values: <= 20 characters
The party phone number.
Possible values: <= 20 characters
The address state code
Indicate if the address is residential or commercial (enterprise)
Possible values: <= 20 characters
The address street number
Possible values: <= 50 characters
The address line with street number
(required for shipment purchase)
Possible values: <= 50 characters
The address line with suite number
Indicate if the address should be validated
billing_address
object
nullable
Possible values: <= 10 characters
The address postal code (required for shipment purchase)
Possible values: <= 30 characters
The address city. (required for shipment purchase)
Possible values: <= 20 characters
The party frederal tax id
Possible values: <= 20 characters
The party state id
Possible values: <= 50 characters
Attention to (required for shipment purchase)
Possible values: <= 50 characters
The company name if the party is a company
Possible values: [AC
, AD
, AE
, AF
, AG
, AI
, AL
, AM
, AN
, AO
, AR
, AS
, AT
, AU
, AW
, AZ
, BA
, BB
, BD
, BE
, BF
, BG
, BH
, BI
, BJ
, BM
, BN
, BO
, BR
, BS
, BT
, BW
, BY
, BZ
, CA
, CD
, CF
, CG
, CH
, CI
, CK
, CL
, CM
, CN
, CO
, CR
, CU
, CV
, CY
, CZ
, DE
, DJ
, DK
, DM
, DO
, DZ
, EC
, EE
, EG
, ER
, ES
, ET
, FI
, FJ
, FK
, FM
, FO
, FR
, GA
, GB
, GD
, GE
, GF
, GG
, GH
, GI
, GL
, GM
, GN
, GP
, GQ
, GR
, GT
, GU
, GW
, GY
, HK
, HN
, HR
, HT
, HU
, IC
, ID
, IE
, IL
, IN
, IQ
, IR
, IS
, IT
, JE
, JM
, JO
, JP
, KE
, KG
, KH
, KI
, KM
, KN
, KP
, KR
, KV
, KW
, KY
, KZ
, LA
, LB
, LC
, LI
, LK
, LR
, LS
, LT
, LU
, LV
, LY
, MA
, MC
, MD
, ME
, MG
, MH
, MK
, ML
, MM
, MN
, MO
, MP
, MQ
, MR
, MS
, MT
, MU
, MV
, MW
, MX
, MY
, MZ
, NA
, NC
, NE
, NG
, NI
, NL
, NO
, NP
, NR
, NU
, NZ
, OM
, PA
, PE
, PF
, PG
, PH
, PK
, PL
, PR
, PT
, PW
, PY
, QA
, RE
, RO
, RS
, RU
, RW
, SA
, SB
, SC
, SD
, SE
, SG
, SH
, SI
, SK
, SL
, SM
, SN
, SO
, SR
, SS
, ST
, SV
, SY
, SZ
, TC
, TD
, TG
, TH
, TJ
, TL
, TN
, TO
, TR
, TT
, TV
, TW
, TZ
, UA
, UG
, US
, UY
, UZ
, VA
, VC
, VE
, VG
, VI
, VN
, VU
, WS
, XB
, XC
, XE
, XM
, XN
, XS
, XY
, YE
, YT
, ZA
, ZM
, ZW
, EH
, IM
, BL
, MF
, SX
]
The address country code
The party email
Possible values: <= 20 characters
The party phone number.
Possible values: <= 20 characters
The address state code
Indicate if the address is residential or commercial (enterprise)
Possible values: <= 20 characters
The address street number
Possible values: <= 50 characters
The address line with street number
(required for shipment purchase)
Possible values: <= 50 characters
The address line with suite number
Indicate if the address should be validated
line_items
object[]
required
The order line items.
The commodity's weight
Possible values: [KG
, LB
, OZ
, G
]
The commodity's weight unit
Possible values: <= 35 characters
A description of the commodity
Possible values: <= 100 characters
A description of the commodity
Default value: 1
The commodity's quantity (number or item)
Possible values: <= 35 characters
The commodity's sku number
Possible values: <= 35 characters
The commodity's hs_code number
The monetary value of the commodity
Possible values: [EUR
, AED
, USD
, XCD
, AMD
, ANG
, AOA
, ARS
, AUD
, AWG
, AZN
, BAM
, BBD
, BDT
, XOF
, BGN
, BHD
, BIF
, BMD
, BND
, BOB
, BRL
, BSD
, BTN
, BWP
, BYN
, BZD
, CAD
, CDF
, XAF
, CHF
, NZD
, CLP
, CNY
, COP
, CRC
, CUC
, CVE
, CZK
, DJF
, DKK
, DOP
, DZD
, EGP
, ERN
, ETB
, FJD
, GBP
, GEL
, GHS
, GMD
, GNF
, GTQ
, GYD
, HKD
, HNL
, HRK
, HTG
, HUF
, IDR
, ILS
, INR
, IRR
, ISK
, JMD
, JOD
, JPY
, KES
, KGS
, KHR
, KMF
, KPW
, KRW
, KWD
, KYD
, KZT
, LAK
, LKR
, LRD
, LSL
, LYD
, MAD
, MDL
, MGA
, MKD
, MMK
, MNT
, MOP
, MRO
, MUR
, MVR
, MWK
, MXN
, MYR
, MZN
, NAD
, XPF
, NGN
, NIO
, NOK
, NPR
, OMR
, PEN
, PGK
, PHP
, PKR
, PLN
, PYG
, QAR
, RSD
, RUB
, RWF
, SAR
, SBD
, SCR
, SDG
, SEK
, SGD
, SHP
, SLL
, SOS
, SRD
, SSP
, STD
, SYP
, SZL
, THB
, TJS
, TND
, TOP
, TRY
, TTD
, TWD
, TZS
, UAH
, UYU
, UZS
, VEF
, VND
, VUV
, WST
, YER
, ZAR
, null
]
The currency of the commodity value amount
Possible values: [AC
, AD
, AE
, AF
, AG
, AI
, AL
, AM
, AN
, AO
, AR
, AS
, AT
, AU
, AW
, AZ
, BA
, BB
, BD
, BE
, BF
, BG
, BH
, BI
, BJ
, BM
, BN
, BO
, BR
, BS
, BT
, BW
, BY
, BZ
, CA
, CD
, CF
, CG
, CH
, CI
, CK
, CL
, CM
, CN
, CO
, CR
, CU
, CV
, CY
, CZ
, DE
, DJ
, DK
, DM
, DO
, DZ
, EC
, EE
, EG
, ER
, ES
, ET
, FI
, FJ
, FK
, FM
, FO
, FR
, GA
, GB
, GD
, GE
, GF
, GG
, GH
, GI
, GL
, GM
, GN
, GP
, GQ
, GR
, GT
, GU
, GW
, GY
, HK
, HN
, HR
, HT
, HU
, IC
, ID
, IE
, IL
, IN
, IQ
, IR
, IS
, IT
, JE
, JM
, JO
, JP
, KE
, KG
, KH
, KI
, KM
, KN
, KP
, KR
, KV
, KW
, KY
, KZ
, LA
, LB
, LC
, LI
, LK
, LR
, LS
, LT
, LU
, LV
, LY
, MA
, MC
, MD
, ME
, MG
, MH
, MK
, ML
, MM
, MN
, MO
, MP
, MQ
, MR
, MS
, MT
, MU
, MV
, MW
, MX
, MY
, MZ
, NA
, NC
, NE
, NG
, NI
, NL
, NO
, NP
, NR
, NU
, NZ
, OM
, PA
, PE
, PF
, PG
, PH
, PK
, PL
, PR
, PT
, PW
, PY
, QA
, RE
, RO
, RS
, RU
, RW
, SA
, SB
, SC
, SD
, SE
, SG
, SH
, SI
, SK
, SL
, SM
, SN
, SO
, SR
, SS
, ST
, SV
, SY
, SZ
, TC
, TD
, TG
, TH
, TJ
, TL
, TN
, TO
, TR
, TT
, TV
, TW
, TZ
, UA
, UG
, US
, UY
, UZ
, VA
, VC
, VE
, VG
, VI
, VN
, VU
, WS
, XB
, XC
, XE
, XM
, XN
, XS
, XY
, YE
, YT
, ZA
, ZM
, ZW
, EH
, IM
, BL
, MF
, SX
, null
]
The origin or manufacture country
The id of the related order line item.
metadata
object
nullable
Commodity user references metadata.
{ "part_number": "5218487281", "reference1": "# ref 1", "reference2": "# ref 2", "reference3": "# ref 3", ... }
Commodity user references metadata.
{
"part_number": "5218487281",
"reference1": "# ref 1",
"reference2": "# ref 2",
"reference3": "# ref 3",
...
}
</details>
options
object
nullable
The options available for the order shipments.
{ "currency": "USD", "paid_by": "third_party", "payment_account_number": "123456789", "duty_paid_by": "third_party", "duty_account_number": "123456789", "invoice_number": "123456789", "invoice_date": "2020-01-01", "single_item_per_parcel": true, "carrier_ids": ["canadapost-test"], "preferred_service": "fedex_express_saver", }
The options available for the order shipments.
{
"currency": "USD",
"paid_by": "third_party",
"payment_account_number": "123456789",
"duty_paid_by": "third_party",
"duty_account_number": "123456789",
"invoice_number": "123456789",
"invoice_date": "2020-01-01",
"single_item_per_parcel": true,
"carrier_ids": ["canadapost-test"],
"preferred_service": "fedex_express_saver",
}
</details>
metadata
object
User metadata for the order.
Default value: [object Object]
User metadata for the order.
Responses
- 200
- 404
- 500
- application/json
- Schema
- Example (from schema)
Schema
Array [
]
A unique identifier
Possible values: [queued
, running
, failed
, completed
, completed_with_errors
]
Possible values: [orders
, shipments
, trackers
, billing
]
resources
object[]
required
A unique identifier
Possible values: [queued
, running
, failed
, completed
, completed_with_errors
]
The batch operation resource status
errors
object
nullable
Resource processing errors
Resource processing errors
{
"id": "string",
"status": "queued",
"resource_type": "orders",
"resources": [
{
"id": "string",
"status": "queued",
"errors": {}
}
],
"created_at": "2024-07-29T15:51:28.071Z",
"updated_at": "2024-07-29T15:51:28.071Z",
"test_mode": true
}
- application/json
- Schema
- Example (from schema)
Schema
Array [
]
errors
object[]
The list of API errors
The error or warning message
The message code
details
object
any additional details
any additional details
{
"errors": [
{
"message": "string",
"code": "string",
"details": {}
}
]
}
- application/json
- Schema
- Example (from schema)
Schema
Array [
]
errors
object[]
The list of API errors
The error or warning message
The message code
details
object
any additional details
any additional details
{
"errors": [
{
"message": "string",
"code": "string",
"details": {}
}
]
}