Shipping boxes
Update shipping box detail
PUT
/
store
/
shipping-boxes
/
{id}
Update shipping box detail
curl --request PUT \
--url https://staging.api.commercengine.io/api/v1/{store_id}/admin/store/shipping-boxes/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"length": 123,
"width": 123,
"height": 123,
"empty_box_weight": 123,
"max_weight_box_can_carry": 123,
"empty_box_price": 123,
"warehouse_id": [
"<string>"
],
"id": "<string>"
}
'import requests
url = "https://staging.api.commercengine.io/api/v1/{store_id}/admin/store/shipping-boxes/{id}"
payload = {
"name": "<string>",
"length": 123,
"width": 123,
"height": 123,
"empty_box_weight": 123,
"max_weight_box_can_carry": 123,
"empty_box_price": 123,
"warehouse_id": ["<string>"],
"id": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
length: 123,
width: 123,
height: 123,
empty_box_weight: 123,
max_weight_box_can_carry: 123,
empty_box_price: 123,
warehouse_id: ['<string>'],
id: '<string>'
})
};
fetch('https://staging.api.commercengine.io/api/v1/{store_id}/admin/store/shipping-boxes/{id}', 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://staging.api.commercengine.io/api/v1/{store_id}/admin/store/shipping-boxes/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'length' => 123,
'width' => 123,
'height' => 123,
'empty_box_weight' => 123,
'max_weight_box_can_carry' => 123,
'empty_box_price' => 123,
'warehouse_id' => [
'<string>'
],
'id' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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://staging.api.commercengine.io/api/v1/{store_id}/admin/store/shipping-boxes/{id}"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"length\": 123,\n \"width\": 123,\n \"height\": 123,\n \"empty_box_weight\": 123,\n \"max_weight_box_can_carry\": 123,\n \"empty_box_price\": 123,\n \"warehouse_id\": [\n \"<string>\"\n ],\n \"id\": \"<string>\"\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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.put("https://staging.api.commercengine.io/api/v1/{store_id}/admin/store/shipping-boxes/{id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"length\": 123,\n \"width\": 123,\n \"height\": 123,\n \"empty_box_weight\": 123,\n \"max_weight_box_can_carry\": 123,\n \"empty_box_price\": 123,\n \"warehouse_id\": [\n \"<string>\"\n ],\n \"id\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://staging.api.commercengine.io/api/v1/{store_id}/admin/store/shipping-boxes/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"length\": 123,\n \"width\": 123,\n \"height\": 123,\n \"empty_box_weight\": 123,\n \"max_weight_box_can_carry\": 123,\n \"empty_box_price\": 123,\n \"warehouse_id\": [\n \"<string>\"\n ],\n \"id\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"message": "<string>",
"success": true,
"content": {
"shipping_box": {
"name": "<string>",
"length": 123,
"width": 123,
"height": 123,
"empty_box_weight": 123,
"max_weight_box_can_carry": 123,
"empty_box_price": 123,
"id": "<string>",
"warehouses": [
{
"name": "<string>",
"warehouse_type": "retail-store",
"city": "<string>",
"address_line1": "<string>",
"pincode": "<string>",
"state": "<string>",
"country": "<string>",
"contact_phone": "<string>",
"contact_email": "<string>",
"can_receive_stock": true,
"can_ship_parcel": true,
"can_collect": true,
"is_checkout_point": true,
"accepts_returns": true,
"id": "<string>",
"active": true,
"gstin": "<string>",
"address_line2": "<string>",
"landmark": "<string>",
"country_code": "<string>",
"is_default": true,
"image_url": "<string>",
"seller_warehouse_id": "<string>",
"opening_hours": {
"monday": {
"opening_time": "<string>",
"closing_time": "<string>"
},
"tuesday": {
"opening_time": "<string>",
"closing_time": "<string>"
},
"wednesday": {
"opening_time": "<string>",
"closing_time": "<string>"
},
"thursday": {
"opening_time": "<string>",
"closing_time": "<string>"
},
"friday": {
"opening_time": "<string>",
"closing_time": "<string>"
},
"saturday": {
"opening_time": "<string>",
"closing_time": "<string>"
},
"sunday": {
"opening_time": "<string>",
"closing_time": "<string>"
}
},
"channels": [
{
"id": "<string>",
"name": "<string>",
"active": true,
"kind": "storefront",
"sales_channel_type": "<string>",
"sales_channel_slug": "<string>",
"channel_type": "<string>",
"is_default": true,
"domain": "<string>",
"app_platform": "<string>",
"external_id": "<string>",
"pos_vendor": "<string>",
"store_id": "<string>",
"store_name": "<string>",
"marketplace_id": "<string>",
"marketplace": {
"id": "<string>",
"name": "<string>",
"slug": "<string>",
"marketplace_type": "<string>",
"store_id": "<string>",
"sync_products": true,
"sync_inventory": true,
"sync_orders": true,
"required_credentials_params": {},
"created_at": "2023-11-07T05:31:56Z",
"modified_at": "2023-11-07T05:31:56Z"
},
"seller_account": {
"id": "<string>",
"name": "<string>",
"trade_name": "<string>",
"legal_name": "<string>",
"business_type": "sole_proprietorship",
"tax_identification_number": "<string>",
"status": "pending_approval",
"kyc_status": "document_pending",
"visibility": "public",
"logo": "<string>",
"marketplace_id": "<string>",
"marketplace_name": "<string>"
}
}
],
"marketplace_listing": [
{
"marketplace_id": "<string>"
}
],
"seller_id": "<string>",
"service_provider_id": [
"<string>"
],
"shipping_boxes": [
{
"name": "<string>",
"length": 123,
"width": 123,
"height": 123,
"empty_box_weight": 123,
"max_weight_box_can_carry": 123,
"empty_box_price": 123,
"id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"modified_at": "2023-11-07T05:31:56Z"
}
],
"shipping_providers": [
{
"id": "<string>",
"name": "<string>",
"description": "<string>",
"is_connected": true,
"is_forward_shipping": true,
"is_return_shipping": true,
"logo_dark": "<string>",
"logo_light": "<string>",
"logo": "<string>",
"fulfillment_type": "delivery",
"sort_order": 123,
"type": "auto",
"status": "active"
}
],
"manual_methods": [
{
"id": "<string>",
"name": "<string>",
"description": "<string>",
"is_connected": true,
"is_forward_shipping": true,
"is_return_shipping": true,
"logo_dark": "<string>",
"logo_light": "<string>",
"logo": "<string>",
"fulfillment_type": "delivery",
"sort_order": 123,
"type": "auto",
"status": "active",
"shipping_method_type": "manual",
"shipping_rate_name": "<string>",
"shipping_rate_fixed_price": 123,
"shipping_rate_condition": {
"rate_based_on": "item-weight",
"rate_type": "weight-slabs",
"slabs": [
{
"weight": 123,
"shipping_rate": 123,
"condition": "less-or-equal"
}
]
},
"maximum_weight": 123,
"delivery_leadtime_minimum": 123,
"delivery_leadtime_maximum": 123
}
],
"available_shipping_options": [
{
"id": "<string>",
"name": "<string>",
"description": "<string>",
"is_connected": true,
"is_forward_shipping": true,
"is_return_shipping": true,
"logo_dark": "<string>",
"logo_light": "<string>",
"logo": "<string>",
"fulfillment_type": "delivery",
"sort_order": 123,
"type": "auto",
"status": "active"
}
]
}
],
"created_at": "2023-11-07T05:31:56Z",
"modified_at": "2023-11-07T05:31:56Z"
}
}
}{
"message": "<string>",
"success": true,
"code": "<string>",
"errors": {},
"content": {},
"details": "<string>"
}{
"message": "<string>",
"success": true,
"code": "<string>",
"details": "<string>"
}{
"message": "<string>",
"success": true,
"code": "<string>",
"details": "<string>"
}{
"message": "<string>",
"code": "method-not-allowed",
"success": false,
"details": "<string>"
}{
"message": "<string>",
"success": true,
"code": "<string>",
"details": "<string>",
"error_id": "<string>"
}Authorizations
Body
application/json
Was this page helpful?
⌘I
Update shipping box detail
curl --request PUT \
--url https://staging.api.commercengine.io/api/v1/{store_id}/admin/store/shipping-boxes/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "<string>",
"length": 123,
"width": 123,
"height": 123,
"empty_box_weight": 123,
"max_weight_box_can_carry": 123,
"empty_box_price": 123,
"warehouse_id": [
"<string>"
],
"id": "<string>"
}
'import requests
url = "https://staging.api.commercengine.io/api/v1/{store_id}/admin/store/shipping-boxes/{id}"
payload = {
"name": "<string>",
"length": 123,
"width": 123,
"height": 123,
"empty_box_weight": 123,
"max_weight_box_can_carry": 123,
"empty_box_price": 123,
"warehouse_id": ["<string>"],
"id": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
length: 123,
width: 123,
height: 123,
empty_box_weight: 123,
max_weight_box_can_carry: 123,
empty_box_price: 123,
warehouse_id: ['<string>'],
id: '<string>'
})
};
fetch('https://staging.api.commercengine.io/api/v1/{store_id}/admin/store/shipping-boxes/{id}', 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://staging.api.commercengine.io/api/v1/{store_id}/admin/store/shipping-boxes/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'length' => 123,
'width' => 123,
'height' => 123,
'empty_box_weight' => 123,
'max_weight_box_can_carry' => 123,
'empty_box_price' => 123,
'warehouse_id' => [
'<string>'
],
'id' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"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://staging.api.commercengine.io/api/v1/{store_id}/admin/store/shipping-boxes/{id}"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"length\": 123,\n \"width\": 123,\n \"height\": 123,\n \"empty_box_weight\": 123,\n \"max_weight_box_can_carry\": 123,\n \"empty_box_price\": 123,\n \"warehouse_id\": [\n \"<string>\"\n ],\n \"id\": \"<string>\"\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
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.put("https://staging.api.commercengine.io/api/v1/{store_id}/admin/store/shipping-boxes/{id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"length\": 123,\n \"width\": 123,\n \"height\": 123,\n \"empty_box_weight\": 123,\n \"max_weight_box_can_carry\": 123,\n \"empty_box_price\": 123,\n \"warehouse_id\": [\n \"<string>\"\n ],\n \"id\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://staging.api.commercengine.io/api/v1/{store_id}/admin/store/shipping-boxes/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"length\": 123,\n \"width\": 123,\n \"height\": 123,\n \"empty_box_weight\": 123,\n \"max_weight_box_can_carry\": 123,\n \"empty_box_price\": 123,\n \"warehouse_id\": [\n \"<string>\"\n ],\n \"id\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"message": "<string>",
"success": true,
"content": {
"shipping_box": {
"name": "<string>",
"length": 123,
"width": 123,
"height": 123,
"empty_box_weight": 123,
"max_weight_box_can_carry": 123,
"empty_box_price": 123,
"id": "<string>",
"warehouses": [
{
"name": "<string>",
"warehouse_type": "retail-store",
"city": "<string>",
"address_line1": "<string>",
"pincode": "<string>",
"state": "<string>",
"country": "<string>",
"contact_phone": "<string>",
"contact_email": "<string>",
"can_receive_stock": true,
"can_ship_parcel": true,
"can_collect": true,
"is_checkout_point": true,
"accepts_returns": true,
"id": "<string>",
"active": true,
"gstin": "<string>",
"address_line2": "<string>",
"landmark": "<string>",
"country_code": "<string>",
"is_default": true,
"image_url": "<string>",
"seller_warehouse_id": "<string>",
"opening_hours": {
"monday": {
"opening_time": "<string>",
"closing_time": "<string>"
},
"tuesday": {
"opening_time": "<string>",
"closing_time": "<string>"
},
"wednesday": {
"opening_time": "<string>",
"closing_time": "<string>"
},
"thursday": {
"opening_time": "<string>",
"closing_time": "<string>"
},
"friday": {
"opening_time": "<string>",
"closing_time": "<string>"
},
"saturday": {
"opening_time": "<string>",
"closing_time": "<string>"
},
"sunday": {
"opening_time": "<string>",
"closing_time": "<string>"
}
},
"channels": [
{
"id": "<string>",
"name": "<string>",
"active": true,
"kind": "storefront",
"sales_channel_type": "<string>",
"sales_channel_slug": "<string>",
"channel_type": "<string>",
"is_default": true,
"domain": "<string>",
"app_platform": "<string>",
"external_id": "<string>",
"pos_vendor": "<string>",
"store_id": "<string>",
"store_name": "<string>",
"marketplace_id": "<string>",
"marketplace": {
"id": "<string>",
"name": "<string>",
"slug": "<string>",
"marketplace_type": "<string>",
"store_id": "<string>",
"sync_products": true,
"sync_inventory": true,
"sync_orders": true,
"required_credentials_params": {},
"created_at": "2023-11-07T05:31:56Z",
"modified_at": "2023-11-07T05:31:56Z"
},
"seller_account": {
"id": "<string>",
"name": "<string>",
"trade_name": "<string>",
"legal_name": "<string>",
"business_type": "sole_proprietorship",
"tax_identification_number": "<string>",
"status": "pending_approval",
"kyc_status": "document_pending",
"visibility": "public",
"logo": "<string>",
"marketplace_id": "<string>",
"marketplace_name": "<string>"
}
}
],
"marketplace_listing": [
{
"marketplace_id": "<string>"
}
],
"seller_id": "<string>",
"service_provider_id": [
"<string>"
],
"shipping_boxes": [
{
"name": "<string>",
"length": 123,
"width": 123,
"height": 123,
"empty_box_weight": 123,
"max_weight_box_can_carry": 123,
"empty_box_price": 123,
"id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"modified_at": "2023-11-07T05:31:56Z"
}
],
"shipping_providers": [
{
"id": "<string>",
"name": "<string>",
"description": "<string>",
"is_connected": true,
"is_forward_shipping": true,
"is_return_shipping": true,
"logo_dark": "<string>",
"logo_light": "<string>",
"logo": "<string>",
"fulfillment_type": "delivery",
"sort_order": 123,
"type": "auto",
"status": "active"
}
],
"manual_methods": [
{
"id": "<string>",
"name": "<string>",
"description": "<string>",
"is_connected": true,
"is_forward_shipping": true,
"is_return_shipping": true,
"logo_dark": "<string>",
"logo_light": "<string>",
"logo": "<string>",
"fulfillment_type": "delivery",
"sort_order": 123,
"type": "auto",
"status": "active",
"shipping_method_type": "manual",
"shipping_rate_name": "<string>",
"shipping_rate_fixed_price": 123,
"shipping_rate_condition": {
"rate_based_on": "item-weight",
"rate_type": "weight-slabs",
"slabs": [
{
"weight": 123,
"shipping_rate": 123,
"condition": "less-or-equal"
}
]
},
"maximum_weight": 123,
"delivery_leadtime_minimum": 123,
"delivery_leadtime_maximum": 123
}
],
"available_shipping_options": [
{
"id": "<string>",
"name": "<string>",
"description": "<string>",
"is_connected": true,
"is_forward_shipping": true,
"is_return_shipping": true,
"logo_dark": "<string>",
"logo_light": "<string>",
"logo": "<string>",
"fulfillment_type": "delivery",
"sort_order": 123,
"type": "auto",
"status": "active"
}
]
}
],
"created_at": "2023-11-07T05:31:56Z",
"modified_at": "2023-11-07T05:31:56Z"
}
}
}{
"message": "<string>",
"success": true,
"code": "<string>",
"errors": {},
"content": {},
"details": "<string>"
}{
"message": "<string>",
"success": true,
"code": "<string>",
"details": "<string>"
}{
"message": "<string>",
"success": true,
"code": "<string>",
"details": "<string>"
}{
"message": "<string>",
"code": "method-not-allowed",
"success": false,
"details": "<string>"
}{
"message": "<string>",
"success": true,
"code": "<string>",
"details": "<string>",
"error_id": "<string>"
}