Discussions

Ask a Question
Back to All

Create a Shipment 201 always represents created,but I want to test the status of 200

The example given in the API access method : when the value of this method < buy_label_synchronous> is true, it always reports an error of 500, and when the value is false, 201 always represents created, but I want to test the status of 200
{
"origin_address": {
"line_1": "55 Prospect St",
"line_2": "Unit 401",
"state": "NY",
"city": "Sydney",
"postal_code": "11201",
"country_alpha2": "US",
"contact_name": "Mandy Morrison",
"company_name": "Mandy's Watches",
"contact_phone": "+1396380000",
"contact_email": "[email protected]"
},
"sender_address": {
"line_1": "55 Prospect St",
"line_2": "Unit 401",
"state": "NY",
"city": "Sydney",
"postal_code": "11201",
"country_alpha2": "US",
"contact_name": "Mandy Morrison",
"company_name": "Mandy's Watches",
"contact_phone": "+1396380000",
"contact_email": "[email protected]"
},
"return_address": {
"line_1": "55 Prospect St",
"line_2": "Unit 401",
"state": "NY",
"city": "Sydney",
"postal_code": "11201",
"country_alpha2": "US",
"contact_name": "Mandy Morrison",
"company_name": "Mandy's Watches",
"contact_phone": "+1396380000",
"contact_email": "[email protected]"
},
"destination_address": {
"line_1": "1 quai de Jemmapes",
"line_2": "Porte A",
"state": "CA",
"city": "Paris",
"postal_code": "75010",
"country_alpha2": "FR",
"contact_name": "Sonny Bill",
"company_name": null,
"contact_phone": "+336638000",
"contact_email": "[email protected]"
},
"metadata": {},
"set_as_residential": true,//
"consignee_tax_id": null,
"eei_reference": null,
"incoterms": "DDU",
"insurance": {
"is_insured": true,//
"insured_amount": 600,
"insured_currency": "USD"
},
"order_data": {
"platform_name": "Shopify",//
"platform_order_number": "#1001",//
"order_tag_list": [
"VIP"
],
"seller_notes": null,
"buyer_notes": null
},
"courier_selection": {
"selected_courier_id": "5179fe34-33ba-403a-9270-bda4162bc190",
"allow_courier_fallback": false,
"apply_shipping_rules": true
},
"shipping_settings": {
"units": {
"weight": "lb",
"dimensions": "in"
},
"printing_options": {
"format": "png",
"label": "4x6",
"commercial_invoice": "A4",
"packing_slip": "4x6"
},
"buy_label": false,
"buy_label_synchronous": true
},
"parcels": [
{
"total_actual_weight": 0.8,
"box": {
"slug": null,
"length": 10,
"width": 8,
"height": 5
},
"items": [
{
"description": "Silk dress",
"category": "fashion",
"sku": "test01",
"quantity": 2,
"dimensions": {
"length": null,
"width": null,
"height": null
},
"actual_weight": 10,
"declared_currency": "USD",
"declared_customs_value": 20
}
]
}
]
}