UpdateOrderProducts
curl --request POST \
--url https://{server_name}/Order/UpdateOrderProducts \
--header 'Content-Type: application/json' \
--data '
{
"MetaDataUpdateType": "<string>",
"OrderId": "<string>",
"Products": [
{
"Attributes": [
{
"AttributeCode": "<string>",
"AttributeTypeCode": "<string>",
"Name": "<string>"
}
],
"AttributesEnglish": [
{
"AttributeCode": "<string>",
"AttributeTypeCode": "<string>",
"Name": "<string>"
}
],
"BackOrderDate": "<string>",
"Brand": {
"BrandCode": "<string>",
"Name": "<string>"
},
"CartItemId": "<string>",
"CartItemOptionId": "<string>",
"Categories": [
{
"CategoryCode": "<string>",
"Name": "<string>"
}
],
"DeliveryQuantity": 123,
"Description": "<string>",
"DescriptionEnglish": "<string>",
"GenericHSCode": "<string>",
"GiftMessage": "<string>",
"HandlingCode": "<string>",
"Height": 123,
"HubCode": "<string>",
"ImageHeight": 123,
"ImageURL": "<string>",
"ImageWidth": 123,
"IsBackOrdered": true,
"IsBlockedForGlobalE": true,
"IsBundle": true,
"IsFixedPrice": true,
"IsVirtual": true,
"Keywords": "<string>",
"Length": 123,
"LineItemOriginalSalePrice": 123,
"LineItemSalePrice": 123,
"ListPrice": 123,
"LocalVATRateType": {
"Name": "<string>",
"Rate": 123,
"VATRateTypeCode": "<string>"
},
"MetaData": {
"Attributes": [
{
"AttributeCode": "<string>",
"AttributeTypeCode": "<string>",
"Name": "<string>"
}
]
},
"Name": "<string>",
"NameEnglish": "<string>",
"NetVolume": 123,
"NetWeight": 123,
"OrderedQuantity": 123,
"OriginalListPrice": 123,
"OriginalSalePrice": 123,
"OriginCountryCode": "<string>",
"ParentCartItemId": "<string>",
"PriceCoefficientRate": 123,
"ProductClassCode": "<string>",
"ProductCode": "<string>",
"ProductCodeSecondary": "<string>",
"ProductGroupCode": "<string>",
"ProductGroupCodeSecondary": "<string>",
"SalePrice": 123,
"SalePriceBeforeRounding": 123,
"SalePriceReason": "<string>",
"URL": "<string>",
"VATCategory": {
"Name": "<string>",
"VATCategoryCode": "<string>"
},
"VATRateType": {
"Name": "<string>",
"Rate": 123,
"VATRateTypeCode": "<string>"
},
"Volume": 123,
"Weight": 123,
"Width": 123
}
]
}
'import requests
url = "https://{server_name}/Order/UpdateOrderProducts"
payload = {
"MetaDataUpdateType": "<string>",
"OrderId": "<string>",
"Products": [
{
"Attributes": [
{
"AttributeCode": "<string>",
"AttributeTypeCode": "<string>",
"Name": "<string>"
}
],
"AttributesEnglish": [
{
"AttributeCode": "<string>",
"AttributeTypeCode": "<string>",
"Name": "<string>"
}
],
"BackOrderDate": "<string>",
"Brand": {
"BrandCode": "<string>",
"Name": "<string>"
},
"CartItemId": "<string>",
"CartItemOptionId": "<string>",
"Categories": [
{
"CategoryCode": "<string>",
"Name": "<string>"
}
],
"DeliveryQuantity": 123,
"Description": "<string>",
"DescriptionEnglish": "<string>",
"GenericHSCode": "<string>",
"GiftMessage": "<string>",
"HandlingCode": "<string>",
"Height": 123,
"HubCode": "<string>",
"ImageHeight": 123,
"ImageURL": "<string>",
"ImageWidth": 123,
"IsBackOrdered": True,
"IsBlockedForGlobalE": True,
"IsBundle": True,
"IsFixedPrice": True,
"IsVirtual": True,
"Keywords": "<string>",
"Length": 123,
"LineItemOriginalSalePrice": 123,
"LineItemSalePrice": 123,
"ListPrice": 123,
"LocalVATRateType": {
"Name": "<string>",
"Rate": 123,
"VATRateTypeCode": "<string>"
},
"MetaData": { "Attributes": [
{
"AttributeCode": "<string>",
"AttributeTypeCode": "<string>",
"Name": "<string>"
}
] },
"Name": "<string>",
"NameEnglish": "<string>",
"NetVolume": 123,
"NetWeight": 123,
"OrderedQuantity": 123,
"OriginalListPrice": 123,
"OriginalSalePrice": 123,
"OriginCountryCode": "<string>",
"ParentCartItemId": "<string>",
"PriceCoefficientRate": 123,
"ProductClassCode": "<string>",
"ProductCode": "<string>",
"ProductCodeSecondary": "<string>",
"ProductGroupCode": "<string>",
"ProductGroupCodeSecondary": "<string>",
"SalePrice": 123,
"SalePriceBeforeRounding": 123,
"SalePriceReason": "<string>",
"URL": "<string>",
"VATCategory": {
"Name": "<string>",
"VATCategoryCode": "<string>"
},
"VATRateType": {
"Name": "<string>",
"Rate": 123,
"VATRateTypeCode": "<string>"
},
"Volume": 123,
"Weight": 123,
"Width": 123
}
]
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
MetaDataUpdateType: '<string>',
OrderId: '<string>',
Products: [
{
Attributes: [{AttributeCode: '<string>', AttributeTypeCode: '<string>', Name: '<string>'}],
AttributesEnglish: [{AttributeCode: '<string>', AttributeTypeCode: '<string>', Name: '<string>'}],
BackOrderDate: '<string>',
Brand: {BrandCode: '<string>', Name: '<string>'},
CartItemId: '<string>',
CartItemOptionId: '<string>',
Categories: [{CategoryCode: '<string>', Name: '<string>'}],
DeliveryQuantity: 123,
Description: '<string>',
DescriptionEnglish: '<string>',
GenericHSCode: '<string>',
GiftMessage: '<string>',
HandlingCode: '<string>',
Height: 123,
HubCode: '<string>',
ImageHeight: 123,
ImageURL: '<string>',
ImageWidth: 123,
IsBackOrdered: true,
IsBlockedForGlobalE: true,
IsBundle: true,
IsFixedPrice: true,
IsVirtual: true,
Keywords: '<string>',
Length: 123,
LineItemOriginalSalePrice: 123,
LineItemSalePrice: 123,
ListPrice: 123,
LocalVATRateType: {Name: '<string>', Rate: 123, VATRateTypeCode: '<string>'},
MetaData: {
Attributes: [{AttributeCode: '<string>', AttributeTypeCode: '<string>', Name: '<string>'}]
},
Name: '<string>',
NameEnglish: '<string>',
NetVolume: 123,
NetWeight: 123,
OrderedQuantity: 123,
OriginalListPrice: 123,
OriginalSalePrice: 123,
OriginCountryCode: '<string>',
ParentCartItemId: '<string>',
PriceCoefficientRate: 123,
ProductClassCode: '<string>',
ProductCode: '<string>',
ProductCodeSecondary: '<string>',
ProductGroupCode: '<string>',
ProductGroupCodeSecondary: '<string>',
SalePrice: 123,
SalePriceBeforeRounding: 123,
SalePriceReason: '<string>',
URL: '<string>',
VATCategory: {Name: '<string>', VATCategoryCode: '<string>'},
VATRateType: {Name: '<string>', Rate: 123, VATRateTypeCode: '<string>'},
Volume: 123,
Weight: 123,
Width: 123
}
]
})
};
fetch('https://{server_name}/Order/UpdateOrderProducts', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://{server_name}/Order/UpdateOrderProducts",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'MetaDataUpdateType' => '<string>',
'OrderId' => '<string>',
'Products' => [
[
'Attributes' => [
[
'AttributeCode' => '<string>',
'AttributeTypeCode' => '<string>',
'Name' => '<string>'
]
],
'AttributesEnglish' => [
[
'AttributeCode' => '<string>',
'AttributeTypeCode' => '<string>',
'Name' => '<string>'
]
],
'BackOrderDate' => '<string>',
'Brand' => [
'BrandCode' => '<string>',
'Name' => '<string>'
],
'CartItemId' => '<string>',
'CartItemOptionId' => '<string>',
'Categories' => [
[
'CategoryCode' => '<string>',
'Name' => '<string>'
]
],
'DeliveryQuantity' => 123,
'Description' => '<string>',
'DescriptionEnglish' => '<string>',
'GenericHSCode' => '<string>',
'GiftMessage' => '<string>',
'HandlingCode' => '<string>',
'Height' => 123,
'HubCode' => '<string>',
'ImageHeight' => 123,
'ImageURL' => '<string>',
'ImageWidth' => 123,
'IsBackOrdered' => true,
'IsBlockedForGlobalE' => true,
'IsBundle' => true,
'IsFixedPrice' => true,
'IsVirtual' => true,
'Keywords' => '<string>',
'Length' => 123,
'LineItemOriginalSalePrice' => 123,
'LineItemSalePrice' => 123,
'ListPrice' => 123,
'LocalVATRateType' => [
'Name' => '<string>',
'Rate' => 123,
'VATRateTypeCode' => '<string>'
],
'MetaData' => [
'Attributes' => [
[
'AttributeCode' => '<string>',
'AttributeTypeCode' => '<string>',
'Name' => '<string>'
]
]
],
'Name' => '<string>',
'NameEnglish' => '<string>',
'NetVolume' => 123,
'NetWeight' => 123,
'OrderedQuantity' => 123,
'OriginalListPrice' => 123,
'OriginalSalePrice' => 123,
'OriginCountryCode' => '<string>',
'ParentCartItemId' => '<string>',
'PriceCoefficientRate' => 123,
'ProductClassCode' => '<string>',
'ProductCode' => '<string>',
'ProductCodeSecondary' => '<string>',
'ProductGroupCode' => '<string>',
'ProductGroupCodeSecondary' => '<string>',
'SalePrice' => 123,
'SalePriceBeforeRounding' => 123,
'SalePriceReason' => '<string>',
'URL' => '<string>',
'VATCategory' => [
'Name' => '<string>',
'VATCategoryCode' => '<string>'
],
'VATRateType' => [
'Name' => '<string>',
'Rate' => 123,
'VATRateTypeCode' => '<string>'
],
'Volume' => 123,
'Weight' => 123,
'Width' => 123
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://{server_name}/Order/UpdateOrderProducts"
payload := strings.NewReader("{\n \"MetaDataUpdateType\": \"<string>\",\n \"OrderId\": \"<string>\",\n \"Products\": [\n {\n \"Attributes\": [\n {\n \"AttributeCode\": \"<string>\",\n \"AttributeTypeCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ],\n \"AttributesEnglish\": [\n {\n \"AttributeCode\": \"<string>\",\n \"AttributeTypeCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ],\n \"BackOrderDate\": \"<string>\",\n \"Brand\": {\n \"BrandCode\": \"<string>\",\n \"Name\": \"<string>\"\n },\n \"CartItemId\": \"<string>\",\n \"CartItemOptionId\": \"<string>\",\n \"Categories\": [\n {\n \"CategoryCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ],\n \"DeliveryQuantity\": 123,\n \"Description\": \"<string>\",\n \"DescriptionEnglish\": \"<string>\",\n \"GenericHSCode\": \"<string>\",\n \"GiftMessage\": \"<string>\",\n \"HandlingCode\": \"<string>\",\n \"Height\": 123,\n \"HubCode\": \"<string>\",\n \"ImageHeight\": 123,\n \"ImageURL\": \"<string>\",\n \"ImageWidth\": 123,\n \"IsBackOrdered\": true,\n \"IsBlockedForGlobalE\": true,\n \"IsBundle\": true,\n \"IsFixedPrice\": true,\n \"IsVirtual\": true,\n \"Keywords\": \"<string>\",\n \"Length\": 123,\n \"LineItemOriginalSalePrice\": 123,\n \"LineItemSalePrice\": 123,\n \"ListPrice\": 123,\n \"LocalVATRateType\": {\n \"Name\": \"<string>\",\n \"Rate\": 123,\n \"VATRateTypeCode\": \"<string>\"\n },\n \"MetaData\": {\n \"Attributes\": [\n {\n \"AttributeCode\": \"<string>\",\n \"AttributeTypeCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ]\n },\n \"Name\": \"<string>\",\n \"NameEnglish\": \"<string>\",\n \"NetVolume\": 123,\n \"NetWeight\": 123,\n \"OrderedQuantity\": 123,\n \"OriginalListPrice\": 123,\n \"OriginalSalePrice\": 123,\n \"OriginCountryCode\": \"<string>\",\n \"ParentCartItemId\": \"<string>\",\n \"PriceCoefficientRate\": 123,\n \"ProductClassCode\": \"<string>\",\n \"ProductCode\": \"<string>\",\n \"ProductCodeSecondary\": \"<string>\",\n \"ProductGroupCode\": \"<string>\",\n \"ProductGroupCodeSecondary\": \"<string>\",\n \"SalePrice\": 123,\n \"SalePriceBeforeRounding\": 123,\n \"SalePriceReason\": \"<string>\",\n \"URL\": \"<string>\",\n \"VATCategory\": {\n \"Name\": \"<string>\",\n \"VATCategoryCode\": \"<string>\"\n },\n \"VATRateType\": {\n \"Name\": \"<string>\",\n \"Rate\": 123,\n \"VATRateTypeCode\": \"<string>\"\n },\n \"Volume\": 123,\n \"Weight\": 123,\n \"Width\": 123\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://{server_name}/Order/UpdateOrderProducts")
.header("Content-Type", "application/json")
.body("{\n \"MetaDataUpdateType\": \"<string>\",\n \"OrderId\": \"<string>\",\n \"Products\": [\n {\n \"Attributes\": [\n {\n \"AttributeCode\": \"<string>\",\n \"AttributeTypeCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ],\n \"AttributesEnglish\": [\n {\n \"AttributeCode\": \"<string>\",\n \"AttributeTypeCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ],\n \"BackOrderDate\": \"<string>\",\n \"Brand\": {\n \"BrandCode\": \"<string>\",\n \"Name\": \"<string>\"\n },\n \"CartItemId\": \"<string>\",\n \"CartItemOptionId\": \"<string>\",\n \"Categories\": [\n {\n \"CategoryCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ],\n \"DeliveryQuantity\": 123,\n \"Description\": \"<string>\",\n \"DescriptionEnglish\": \"<string>\",\n \"GenericHSCode\": \"<string>\",\n \"GiftMessage\": \"<string>\",\n \"HandlingCode\": \"<string>\",\n \"Height\": 123,\n \"HubCode\": \"<string>\",\n \"ImageHeight\": 123,\n \"ImageURL\": \"<string>\",\n \"ImageWidth\": 123,\n \"IsBackOrdered\": true,\n \"IsBlockedForGlobalE\": true,\n \"IsBundle\": true,\n \"IsFixedPrice\": true,\n \"IsVirtual\": true,\n \"Keywords\": \"<string>\",\n \"Length\": 123,\n \"LineItemOriginalSalePrice\": 123,\n \"LineItemSalePrice\": 123,\n \"ListPrice\": 123,\n \"LocalVATRateType\": {\n \"Name\": \"<string>\",\n \"Rate\": 123,\n \"VATRateTypeCode\": \"<string>\"\n },\n \"MetaData\": {\n \"Attributes\": [\n {\n \"AttributeCode\": \"<string>\",\n \"AttributeTypeCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ]\n },\n \"Name\": \"<string>\",\n \"NameEnglish\": \"<string>\",\n \"NetVolume\": 123,\n \"NetWeight\": 123,\n \"OrderedQuantity\": 123,\n \"OriginalListPrice\": 123,\n \"OriginalSalePrice\": 123,\n \"OriginCountryCode\": \"<string>\",\n \"ParentCartItemId\": \"<string>\",\n \"PriceCoefficientRate\": 123,\n \"ProductClassCode\": \"<string>\",\n \"ProductCode\": \"<string>\",\n \"ProductCodeSecondary\": \"<string>\",\n \"ProductGroupCode\": \"<string>\",\n \"ProductGroupCodeSecondary\": \"<string>\",\n \"SalePrice\": 123,\n \"SalePriceBeforeRounding\": 123,\n \"SalePriceReason\": \"<string>\",\n \"URL\": \"<string>\",\n \"VATCategory\": {\n \"Name\": \"<string>\",\n \"VATCategoryCode\": \"<string>\"\n },\n \"VATRateType\": {\n \"Name\": \"<string>\",\n \"Rate\": 123,\n \"VATRateTypeCode\": \"<string>\"\n },\n \"Volume\": 123,\n \"Weight\": 123,\n \"Width\": 123\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://{server_name}/Order/UpdateOrderProducts")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"MetaDataUpdateType\": \"<string>\",\n \"OrderId\": \"<string>\",\n \"Products\": [\n {\n \"Attributes\": [\n {\n \"AttributeCode\": \"<string>\",\n \"AttributeTypeCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ],\n \"AttributesEnglish\": [\n {\n \"AttributeCode\": \"<string>\",\n \"AttributeTypeCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ],\n \"BackOrderDate\": \"<string>\",\n \"Brand\": {\n \"BrandCode\": \"<string>\",\n \"Name\": \"<string>\"\n },\n \"CartItemId\": \"<string>\",\n \"CartItemOptionId\": \"<string>\",\n \"Categories\": [\n {\n \"CategoryCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ],\n \"DeliveryQuantity\": 123,\n \"Description\": \"<string>\",\n \"DescriptionEnglish\": \"<string>\",\n \"GenericHSCode\": \"<string>\",\n \"GiftMessage\": \"<string>\",\n \"HandlingCode\": \"<string>\",\n \"Height\": 123,\n \"HubCode\": \"<string>\",\n \"ImageHeight\": 123,\n \"ImageURL\": \"<string>\",\n \"ImageWidth\": 123,\n \"IsBackOrdered\": true,\n \"IsBlockedForGlobalE\": true,\n \"IsBundle\": true,\n \"IsFixedPrice\": true,\n \"IsVirtual\": true,\n \"Keywords\": \"<string>\",\n \"Length\": 123,\n \"LineItemOriginalSalePrice\": 123,\n \"LineItemSalePrice\": 123,\n \"ListPrice\": 123,\n \"LocalVATRateType\": {\n \"Name\": \"<string>\",\n \"Rate\": 123,\n \"VATRateTypeCode\": \"<string>\"\n },\n \"MetaData\": {\n \"Attributes\": [\n {\n \"AttributeCode\": \"<string>\",\n \"AttributeTypeCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ]\n },\n \"Name\": \"<string>\",\n \"NameEnglish\": \"<string>\",\n \"NetVolume\": 123,\n \"NetWeight\": 123,\n \"OrderedQuantity\": 123,\n \"OriginalListPrice\": 123,\n \"OriginalSalePrice\": 123,\n \"OriginCountryCode\": \"<string>\",\n \"ParentCartItemId\": \"<string>\",\n \"PriceCoefficientRate\": 123,\n \"ProductClassCode\": \"<string>\",\n \"ProductCode\": \"<string>\",\n \"ProductCodeSecondary\": \"<string>\",\n \"ProductGroupCode\": \"<string>\",\n \"ProductGroupCodeSecondary\": \"<string>\",\n \"SalePrice\": 123,\n \"SalePriceBeforeRounding\": 123,\n \"SalePriceReason\": \"<string>\",\n \"URL\": \"<string>\",\n \"VATCategory\": {\n \"Name\": \"<string>\",\n \"VATCategoryCode\": \"<string>\"\n },\n \"VATRateType\": {\n \"Name\": \"<string>\",\n \"Rate\": 123,\n \"VATRateTypeCode\": \"<string>\"\n },\n \"Volume\": 123,\n \"Weight\": 123,\n \"Width\": 123\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"Success": true,
"Reason": "<string>"
}Update Order Products
The UpdateOrderProducts API lets you update the order product’s metadata and country of origin after the order has been created.
POST
/
Order
/
UpdateOrderProducts
UpdateOrderProducts
curl --request POST \
--url https://{server_name}/Order/UpdateOrderProducts \
--header 'Content-Type: application/json' \
--data '
{
"MetaDataUpdateType": "<string>",
"OrderId": "<string>",
"Products": [
{
"Attributes": [
{
"AttributeCode": "<string>",
"AttributeTypeCode": "<string>",
"Name": "<string>"
}
],
"AttributesEnglish": [
{
"AttributeCode": "<string>",
"AttributeTypeCode": "<string>",
"Name": "<string>"
}
],
"BackOrderDate": "<string>",
"Brand": {
"BrandCode": "<string>",
"Name": "<string>"
},
"CartItemId": "<string>",
"CartItemOptionId": "<string>",
"Categories": [
{
"CategoryCode": "<string>",
"Name": "<string>"
}
],
"DeliveryQuantity": 123,
"Description": "<string>",
"DescriptionEnglish": "<string>",
"GenericHSCode": "<string>",
"GiftMessage": "<string>",
"HandlingCode": "<string>",
"Height": 123,
"HubCode": "<string>",
"ImageHeight": 123,
"ImageURL": "<string>",
"ImageWidth": 123,
"IsBackOrdered": true,
"IsBlockedForGlobalE": true,
"IsBundle": true,
"IsFixedPrice": true,
"IsVirtual": true,
"Keywords": "<string>",
"Length": 123,
"LineItemOriginalSalePrice": 123,
"LineItemSalePrice": 123,
"ListPrice": 123,
"LocalVATRateType": {
"Name": "<string>",
"Rate": 123,
"VATRateTypeCode": "<string>"
},
"MetaData": {
"Attributes": [
{
"AttributeCode": "<string>",
"AttributeTypeCode": "<string>",
"Name": "<string>"
}
]
},
"Name": "<string>",
"NameEnglish": "<string>",
"NetVolume": 123,
"NetWeight": 123,
"OrderedQuantity": 123,
"OriginalListPrice": 123,
"OriginalSalePrice": 123,
"OriginCountryCode": "<string>",
"ParentCartItemId": "<string>",
"PriceCoefficientRate": 123,
"ProductClassCode": "<string>",
"ProductCode": "<string>",
"ProductCodeSecondary": "<string>",
"ProductGroupCode": "<string>",
"ProductGroupCodeSecondary": "<string>",
"SalePrice": 123,
"SalePriceBeforeRounding": 123,
"SalePriceReason": "<string>",
"URL": "<string>",
"VATCategory": {
"Name": "<string>",
"VATCategoryCode": "<string>"
},
"VATRateType": {
"Name": "<string>",
"Rate": 123,
"VATRateTypeCode": "<string>"
},
"Volume": 123,
"Weight": 123,
"Width": 123
}
]
}
'import requests
url = "https://{server_name}/Order/UpdateOrderProducts"
payload = {
"MetaDataUpdateType": "<string>",
"OrderId": "<string>",
"Products": [
{
"Attributes": [
{
"AttributeCode": "<string>",
"AttributeTypeCode": "<string>",
"Name": "<string>"
}
],
"AttributesEnglish": [
{
"AttributeCode": "<string>",
"AttributeTypeCode": "<string>",
"Name": "<string>"
}
],
"BackOrderDate": "<string>",
"Brand": {
"BrandCode": "<string>",
"Name": "<string>"
},
"CartItemId": "<string>",
"CartItemOptionId": "<string>",
"Categories": [
{
"CategoryCode": "<string>",
"Name": "<string>"
}
],
"DeliveryQuantity": 123,
"Description": "<string>",
"DescriptionEnglish": "<string>",
"GenericHSCode": "<string>",
"GiftMessage": "<string>",
"HandlingCode": "<string>",
"Height": 123,
"HubCode": "<string>",
"ImageHeight": 123,
"ImageURL": "<string>",
"ImageWidth": 123,
"IsBackOrdered": True,
"IsBlockedForGlobalE": True,
"IsBundle": True,
"IsFixedPrice": True,
"IsVirtual": True,
"Keywords": "<string>",
"Length": 123,
"LineItemOriginalSalePrice": 123,
"LineItemSalePrice": 123,
"ListPrice": 123,
"LocalVATRateType": {
"Name": "<string>",
"Rate": 123,
"VATRateTypeCode": "<string>"
},
"MetaData": { "Attributes": [
{
"AttributeCode": "<string>",
"AttributeTypeCode": "<string>",
"Name": "<string>"
}
] },
"Name": "<string>",
"NameEnglish": "<string>",
"NetVolume": 123,
"NetWeight": 123,
"OrderedQuantity": 123,
"OriginalListPrice": 123,
"OriginalSalePrice": 123,
"OriginCountryCode": "<string>",
"ParentCartItemId": "<string>",
"PriceCoefficientRate": 123,
"ProductClassCode": "<string>",
"ProductCode": "<string>",
"ProductCodeSecondary": "<string>",
"ProductGroupCode": "<string>",
"ProductGroupCodeSecondary": "<string>",
"SalePrice": 123,
"SalePriceBeforeRounding": 123,
"SalePriceReason": "<string>",
"URL": "<string>",
"VATCategory": {
"Name": "<string>",
"VATCategoryCode": "<string>"
},
"VATRateType": {
"Name": "<string>",
"Rate": 123,
"VATRateTypeCode": "<string>"
},
"Volume": 123,
"Weight": 123,
"Width": 123
}
]
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
MetaDataUpdateType: '<string>',
OrderId: '<string>',
Products: [
{
Attributes: [{AttributeCode: '<string>', AttributeTypeCode: '<string>', Name: '<string>'}],
AttributesEnglish: [{AttributeCode: '<string>', AttributeTypeCode: '<string>', Name: '<string>'}],
BackOrderDate: '<string>',
Brand: {BrandCode: '<string>', Name: '<string>'},
CartItemId: '<string>',
CartItemOptionId: '<string>',
Categories: [{CategoryCode: '<string>', Name: '<string>'}],
DeliveryQuantity: 123,
Description: '<string>',
DescriptionEnglish: '<string>',
GenericHSCode: '<string>',
GiftMessage: '<string>',
HandlingCode: '<string>',
Height: 123,
HubCode: '<string>',
ImageHeight: 123,
ImageURL: '<string>',
ImageWidth: 123,
IsBackOrdered: true,
IsBlockedForGlobalE: true,
IsBundle: true,
IsFixedPrice: true,
IsVirtual: true,
Keywords: '<string>',
Length: 123,
LineItemOriginalSalePrice: 123,
LineItemSalePrice: 123,
ListPrice: 123,
LocalVATRateType: {Name: '<string>', Rate: 123, VATRateTypeCode: '<string>'},
MetaData: {
Attributes: [{AttributeCode: '<string>', AttributeTypeCode: '<string>', Name: '<string>'}]
},
Name: '<string>',
NameEnglish: '<string>',
NetVolume: 123,
NetWeight: 123,
OrderedQuantity: 123,
OriginalListPrice: 123,
OriginalSalePrice: 123,
OriginCountryCode: '<string>',
ParentCartItemId: '<string>',
PriceCoefficientRate: 123,
ProductClassCode: '<string>',
ProductCode: '<string>',
ProductCodeSecondary: '<string>',
ProductGroupCode: '<string>',
ProductGroupCodeSecondary: '<string>',
SalePrice: 123,
SalePriceBeforeRounding: 123,
SalePriceReason: '<string>',
URL: '<string>',
VATCategory: {Name: '<string>', VATCategoryCode: '<string>'},
VATRateType: {Name: '<string>', Rate: 123, VATRateTypeCode: '<string>'},
Volume: 123,
Weight: 123,
Width: 123
}
]
})
};
fetch('https://{server_name}/Order/UpdateOrderProducts', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://{server_name}/Order/UpdateOrderProducts",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'MetaDataUpdateType' => '<string>',
'OrderId' => '<string>',
'Products' => [
[
'Attributes' => [
[
'AttributeCode' => '<string>',
'AttributeTypeCode' => '<string>',
'Name' => '<string>'
]
],
'AttributesEnglish' => [
[
'AttributeCode' => '<string>',
'AttributeTypeCode' => '<string>',
'Name' => '<string>'
]
],
'BackOrderDate' => '<string>',
'Brand' => [
'BrandCode' => '<string>',
'Name' => '<string>'
],
'CartItemId' => '<string>',
'CartItemOptionId' => '<string>',
'Categories' => [
[
'CategoryCode' => '<string>',
'Name' => '<string>'
]
],
'DeliveryQuantity' => 123,
'Description' => '<string>',
'DescriptionEnglish' => '<string>',
'GenericHSCode' => '<string>',
'GiftMessage' => '<string>',
'HandlingCode' => '<string>',
'Height' => 123,
'HubCode' => '<string>',
'ImageHeight' => 123,
'ImageURL' => '<string>',
'ImageWidth' => 123,
'IsBackOrdered' => true,
'IsBlockedForGlobalE' => true,
'IsBundle' => true,
'IsFixedPrice' => true,
'IsVirtual' => true,
'Keywords' => '<string>',
'Length' => 123,
'LineItemOriginalSalePrice' => 123,
'LineItemSalePrice' => 123,
'ListPrice' => 123,
'LocalVATRateType' => [
'Name' => '<string>',
'Rate' => 123,
'VATRateTypeCode' => '<string>'
],
'MetaData' => [
'Attributes' => [
[
'AttributeCode' => '<string>',
'AttributeTypeCode' => '<string>',
'Name' => '<string>'
]
]
],
'Name' => '<string>',
'NameEnglish' => '<string>',
'NetVolume' => 123,
'NetWeight' => 123,
'OrderedQuantity' => 123,
'OriginalListPrice' => 123,
'OriginalSalePrice' => 123,
'OriginCountryCode' => '<string>',
'ParentCartItemId' => '<string>',
'PriceCoefficientRate' => 123,
'ProductClassCode' => '<string>',
'ProductCode' => '<string>',
'ProductCodeSecondary' => '<string>',
'ProductGroupCode' => '<string>',
'ProductGroupCodeSecondary' => '<string>',
'SalePrice' => 123,
'SalePriceBeforeRounding' => 123,
'SalePriceReason' => '<string>',
'URL' => '<string>',
'VATCategory' => [
'Name' => '<string>',
'VATCategoryCode' => '<string>'
],
'VATRateType' => [
'Name' => '<string>',
'Rate' => 123,
'VATRateTypeCode' => '<string>'
],
'Volume' => 123,
'Weight' => 123,
'Width' => 123
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://{server_name}/Order/UpdateOrderProducts"
payload := strings.NewReader("{\n \"MetaDataUpdateType\": \"<string>\",\n \"OrderId\": \"<string>\",\n \"Products\": [\n {\n \"Attributes\": [\n {\n \"AttributeCode\": \"<string>\",\n \"AttributeTypeCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ],\n \"AttributesEnglish\": [\n {\n \"AttributeCode\": \"<string>\",\n \"AttributeTypeCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ],\n \"BackOrderDate\": \"<string>\",\n \"Brand\": {\n \"BrandCode\": \"<string>\",\n \"Name\": \"<string>\"\n },\n \"CartItemId\": \"<string>\",\n \"CartItemOptionId\": \"<string>\",\n \"Categories\": [\n {\n \"CategoryCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ],\n \"DeliveryQuantity\": 123,\n \"Description\": \"<string>\",\n \"DescriptionEnglish\": \"<string>\",\n \"GenericHSCode\": \"<string>\",\n \"GiftMessage\": \"<string>\",\n \"HandlingCode\": \"<string>\",\n \"Height\": 123,\n \"HubCode\": \"<string>\",\n \"ImageHeight\": 123,\n \"ImageURL\": \"<string>\",\n \"ImageWidth\": 123,\n \"IsBackOrdered\": true,\n \"IsBlockedForGlobalE\": true,\n \"IsBundle\": true,\n \"IsFixedPrice\": true,\n \"IsVirtual\": true,\n \"Keywords\": \"<string>\",\n \"Length\": 123,\n \"LineItemOriginalSalePrice\": 123,\n \"LineItemSalePrice\": 123,\n \"ListPrice\": 123,\n \"LocalVATRateType\": {\n \"Name\": \"<string>\",\n \"Rate\": 123,\n \"VATRateTypeCode\": \"<string>\"\n },\n \"MetaData\": {\n \"Attributes\": [\n {\n \"AttributeCode\": \"<string>\",\n \"AttributeTypeCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ]\n },\n \"Name\": \"<string>\",\n \"NameEnglish\": \"<string>\",\n \"NetVolume\": 123,\n \"NetWeight\": 123,\n \"OrderedQuantity\": 123,\n \"OriginalListPrice\": 123,\n \"OriginalSalePrice\": 123,\n \"OriginCountryCode\": \"<string>\",\n \"ParentCartItemId\": \"<string>\",\n \"PriceCoefficientRate\": 123,\n \"ProductClassCode\": \"<string>\",\n \"ProductCode\": \"<string>\",\n \"ProductCodeSecondary\": \"<string>\",\n \"ProductGroupCode\": \"<string>\",\n \"ProductGroupCodeSecondary\": \"<string>\",\n \"SalePrice\": 123,\n \"SalePriceBeforeRounding\": 123,\n \"SalePriceReason\": \"<string>\",\n \"URL\": \"<string>\",\n \"VATCategory\": {\n \"Name\": \"<string>\",\n \"VATCategoryCode\": \"<string>\"\n },\n \"VATRateType\": {\n \"Name\": \"<string>\",\n \"Rate\": 123,\n \"VATRateTypeCode\": \"<string>\"\n },\n \"Volume\": 123,\n \"Weight\": 123,\n \"Width\": 123\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://{server_name}/Order/UpdateOrderProducts")
.header("Content-Type", "application/json")
.body("{\n \"MetaDataUpdateType\": \"<string>\",\n \"OrderId\": \"<string>\",\n \"Products\": [\n {\n \"Attributes\": [\n {\n \"AttributeCode\": \"<string>\",\n \"AttributeTypeCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ],\n \"AttributesEnglish\": [\n {\n \"AttributeCode\": \"<string>\",\n \"AttributeTypeCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ],\n \"BackOrderDate\": \"<string>\",\n \"Brand\": {\n \"BrandCode\": \"<string>\",\n \"Name\": \"<string>\"\n },\n \"CartItemId\": \"<string>\",\n \"CartItemOptionId\": \"<string>\",\n \"Categories\": [\n {\n \"CategoryCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ],\n \"DeliveryQuantity\": 123,\n \"Description\": \"<string>\",\n \"DescriptionEnglish\": \"<string>\",\n \"GenericHSCode\": \"<string>\",\n \"GiftMessage\": \"<string>\",\n \"HandlingCode\": \"<string>\",\n \"Height\": 123,\n \"HubCode\": \"<string>\",\n \"ImageHeight\": 123,\n \"ImageURL\": \"<string>\",\n \"ImageWidth\": 123,\n \"IsBackOrdered\": true,\n \"IsBlockedForGlobalE\": true,\n \"IsBundle\": true,\n \"IsFixedPrice\": true,\n \"IsVirtual\": true,\n \"Keywords\": \"<string>\",\n \"Length\": 123,\n \"LineItemOriginalSalePrice\": 123,\n \"LineItemSalePrice\": 123,\n \"ListPrice\": 123,\n \"LocalVATRateType\": {\n \"Name\": \"<string>\",\n \"Rate\": 123,\n \"VATRateTypeCode\": \"<string>\"\n },\n \"MetaData\": {\n \"Attributes\": [\n {\n \"AttributeCode\": \"<string>\",\n \"AttributeTypeCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ]\n },\n \"Name\": \"<string>\",\n \"NameEnglish\": \"<string>\",\n \"NetVolume\": 123,\n \"NetWeight\": 123,\n \"OrderedQuantity\": 123,\n \"OriginalListPrice\": 123,\n \"OriginalSalePrice\": 123,\n \"OriginCountryCode\": \"<string>\",\n \"ParentCartItemId\": \"<string>\",\n \"PriceCoefficientRate\": 123,\n \"ProductClassCode\": \"<string>\",\n \"ProductCode\": \"<string>\",\n \"ProductCodeSecondary\": \"<string>\",\n \"ProductGroupCode\": \"<string>\",\n \"ProductGroupCodeSecondary\": \"<string>\",\n \"SalePrice\": 123,\n \"SalePriceBeforeRounding\": 123,\n \"SalePriceReason\": \"<string>\",\n \"URL\": \"<string>\",\n \"VATCategory\": {\n \"Name\": \"<string>\",\n \"VATCategoryCode\": \"<string>\"\n },\n \"VATRateType\": {\n \"Name\": \"<string>\",\n \"Rate\": 123,\n \"VATRateTypeCode\": \"<string>\"\n },\n \"Volume\": 123,\n \"Weight\": 123,\n \"Width\": 123\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://{server_name}/Order/UpdateOrderProducts")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"MetaDataUpdateType\": \"<string>\",\n \"OrderId\": \"<string>\",\n \"Products\": [\n {\n \"Attributes\": [\n {\n \"AttributeCode\": \"<string>\",\n \"AttributeTypeCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ],\n \"AttributesEnglish\": [\n {\n \"AttributeCode\": \"<string>\",\n \"AttributeTypeCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ],\n \"BackOrderDate\": \"<string>\",\n \"Brand\": {\n \"BrandCode\": \"<string>\",\n \"Name\": \"<string>\"\n },\n \"CartItemId\": \"<string>\",\n \"CartItemOptionId\": \"<string>\",\n \"Categories\": [\n {\n \"CategoryCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ],\n \"DeliveryQuantity\": 123,\n \"Description\": \"<string>\",\n \"DescriptionEnglish\": \"<string>\",\n \"GenericHSCode\": \"<string>\",\n \"GiftMessage\": \"<string>\",\n \"HandlingCode\": \"<string>\",\n \"Height\": 123,\n \"HubCode\": \"<string>\",\n \"ImageHeight\": 123,\n \"ImageURL\": \"<string>\",\n \"ImageWidth\": 123,\n \"IsBackOrdered\": true,\n \"IsBlockedForGlobalE\": true,\n \"IsBundle\": true,\n \"IsFixedPrice\": true,\n \"IsVirtual\": true,\n \"Keywords\": \"<string>\",\n \"Length\": 123,\n \"LineItemOriginalSalePrice\": 123,\n \"LineItemSalePrice\": 123,\n \"ListPrice\": 123,\n \"LocalVATRateType\": {\n \"Name\": \"<string>\",\n \"Rate\": 123,\n \"VATRateTypeCode\": \"<string>\"\n },\n \"MetaData\": {\n \"Attributes\": [\n {\n \"AttributeCode\": \"<string>\",\n \"AttributeTypeCode\": \"<string>\",\n \"Name\": \"<string>\"\n }\n ]\n },\n \"Name\": \"<string>\",\n \"NameEnglish\": \"<string>\",\n \"NetVolume\": 123,\n \"NetWeight\": 123,\n \"OrderedQuantity\": 123,\n \"OriginalListPrice\": 123,\n \"OriginalSalePrice\": 123,\n \"OriginCountryCode\": \"<string>\",\n \"ParentCartItemId\": \"<string>\",\n \"PriceCoefficientRate\": 123,\n \"ProductClassCode\": \"<string>\",\n \"ProductCode\": \"<string>\",\n \"ProductCodeSecondary\": \"<string>\",\n \"ProductGroupCode\": \"<string>\",\n \"ProductGroupCodeSecondary\": \"<string>\",\n \"SalePrice\": 123,\n \"SalePriceBeforeRounding\": 123,\n \"SalePriceReason\": \"<string>\",\n \"URL\": \"<string>\",\n \"VATCategory\": {\n \"Name\": \"<string>\",\n \"VATCategoryCode\": \"<string>\"\n },\n \"VATRateType\": {\n \"Name\": \"<string>\",\n \"Rate\": 123,\n \"VATRateTypeCode\": \"<string>\"\n },\n \"Volume\": 123,\n \"Weight\": 123,\n \"Width\": 123\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"Success": true,
"Reason": "<string>"
}Error Codes
When providing an invalid or non-existent value, the Global-e returns an “ErrorInfo” with an appropriate error message.| Code | Error Message | Description |
|---|---|---|
| D001 | Orderid %OrderId% not found. | The provided order ID does not exist |
| D002 | CartItemId %CartItemId% not found | The provided cart item ID does not exist in this order |
| D003 | ProductCode %ProductCode% not found | The provided product code does not exist in this order |
| D004 | OriginCountryCode %OriginCountryCode% is invalid | The provided origin country code does not exist in the system |
| D005 | ProductMetaData %key% cannot have an empty value | The provided value for product meta-data is empty or null |
Body
application/json
The order information and list of products that require updating
Response
200 - application/json
Indicates the results of the API call.
- Option 1
- Option 2
Indicates the results of the API call.
⌘I

