Create MPS Order: Rest of the World and Cross-Border

This API takes the shipment details, drop information, pickup information and creates an order with specified carrier partner. This applies for shipments created and transported within North America, Europe, Middle East and South-East Asia and cross-border Multi-Piece shipments.

Overview

To create orders with international couriers, Clickpost has provided the V4 Order Creation API that caters specifically to international customers or cross-border shipments. Enterprises can place both Single Piece and Multi-Piece Shipments with this API, to be delivered by their preferred courier partner.

This page specifically deals with Multi-Piece Shipments (MPS).

Important Links

Run in Postman API Reference

Usecase

This is a standard API which applies to all MPS (Multi-Piece Shipment) and SPS (Single Piece Shipment) orders

Geography

  • Shipments created and transported in
    • North America
    • Europe
    • Middle East
    • South East Asia
  • Cross-Border shipments: Shipments that are to be transported from India to any other country in the aforementioned regions, or vice versa

Placing Reverse Shipment (RVP) Requests

The customer can also use this API to place Reverse Shipment (RVP) orders, orders that typically are picked up from the end-user's address and sent to the enterprise warehouse. The payload used for the request for placing an order is mostly the same as forward shipments, but 3 points need to considered in order to place a successful RVP order (All of these are mandatory, and Clickpost will throw errors if one of these is not fulfilled):

  • The carrier partner to be used to place the RVP order must support RVP shipments. Ensure that the value passed in the courier_partner field is the partner ID for a carrier that supports RVP shipments.
  • Ensure that the delivery_type field in the shipment_details object has the value "RVP".
  • Ensure that the rvp_reason field is added in the additional object.

If the enterprise is interested in conducting a quality-control check (QC check) at the end-user's end by the carrier, they can also add an optional qc_type field in the additional object and set it's value to "doorstep". The enterprise can also configure which parameters of the item to check for during the QC check (e.g: brand, color or whether all buttons are working) from Clickpost's dashboard, and the check will be done only on those parameters.

URL

POST <https://www.clickpost.in/api/v4/create-order/?username=test-enterprise&key=34be9be5-3de8-4223-ad14-d7391159b80e>

URL Parameters

Query Parameters to be passed directly in the URL.

Field NameData TypeFieldDescriptionMax LengthExample
usernameStringMandatoryUsername of the enterprise100"test-enterprise"
keyStringMandatoryUnique license key provided by Clickpost for the enterprise100"34be9be5-3de8-4223-ad14-d7391159b80e"

Payload

The payload will consist of the following fields:

Field NameData TypeFieldDescriptionMax LengthExample
pickup_infoObjectMandatoryInformation for where the shipment will be picked up by the courier
drop_infoObjectMandatoryInformation for where the shipment will be delivered by the courier
additionalObjectOptionalAdditional optional information about the shipment
shipment_detailsObjectMandatoryInformation about the shipment itself
tax_infoObjectOptionalInformation for taxes levied on the shipment. Note: Required only for cross-border having tax/customs requirements

Pickup Info (pickup_info)

This mandatory object takes in the data for the warehouse/pickup location for the shipment.

Field NameData TypeFieldDescriptionMax LengthExample
latFloatOptionalLatitude of the pickup location45.12211
longFloatOptionalLongitude of the pickup location88.12342
nameStringMandatoryContact name of the consignor of the shipment100"John Smith"
organisationStringOptionalName of the Shipper Organisation100"Walmart"
addressStringMandatoryAddress of the pickup location500"123, ABC Street"
districtStringOptionalDistrict of the pickup location100"Nadia"
cityStringMandatoryCity of the pickup location100"Frankfort"
stateStringMandatoryState/province of the pickup location100"Ohio"
landmarkStringOptionalLandmarks to help find the pickup location500"Near XYZ Towers"
emailStringMandatoryEmail of the pickup contact50"[email protected]"
phoneStringMandatoryContact number of the pickup contact11"9876543210"
timeStringMandatoryTime of pickup for the order (to be provided in YYYY-MM-DDTHH:MM:SS format only)2022-01-10T10:02:33
postal_codeStringMandatoryPostal code of the pickup location. If postal code system is not applicable for the location, use blank string.10"L4YG6C"
country_codeStringMandatoryAlpha ISO-2 country code of the pickup location2"CA"
address_typeStringOptionalAddress type of the pickup location. Must be either OFFICE or RESIDENTIAL50"OFFICE"

Drop Info (drop_info)

This mandatory object takes in the data for the delivery/consignee location for the shipment.

Field NameData TypeFieldDescriptionMax LengthExample
latFloatOptionalLatitude of the drop location45.12211
longFloatOptionalLongitude of the drop location88.12342
nameStringMandatoryContact name of the consignee of the shipment100"John Smith"
organisationStringOptionalName of the Recipient Organisation100"Walmart"
addressStringMandatoryAddress of the drop location500"123, ABC Street"
districtStringOptionalDistrict of the drop location100"Nadia"
cityStringMandatoryCity of the drop location100"Frankfort"
stateStringMandatoryState/province of the drop location100"Ohio"
landmarkStringOptionalLandmarks to help find the drop location500"Near XYZ Towers"
emailStringOptionalEmail of the drop contact50"[email protected]"
phoneStringMandatoryContact number of the drop contact11"9876543210"
timeStringOptionalEstimated time of drop for the order (to be provided in YYYY-MM-DDTHH:MM:SS format only)2022-01-10T10:02:33
postal_codeStringMandatoryPostal code of the drop location. If postal code system is not applicable for the location, use blank string.10"L4YG6C"
country_codeStringMandatoryAlpha ISO-2 country code of the drop location2"CA"
address_typeStringOptionalAddress type of the drop location. Must be either OFFICE or RESIDENTIAL50"OFFICE"

Additional Fields (additional)

In the "additional" object optional fields can be passed which may be used by the courier partner, or give additional details for the order, e.g. Async/Sync order creation or whether label generation is needed.

Field NameData TypeFieldDescriptionMax LengthExample
labelBooleanOptionalWhether label is required for the order or not. Defaults to true.
priorityStringOptionalPriority of the order to be delivered. Can only take values as "NORMAL" or "URGENT". Defaults to "NORMAL"10"URGENT"/"NORMAL"
estimated_delivery_dateDateOptionalThe date of estimated delivery has been shared with the customer. This field can be used to measure carrier performance by comparing it with the actual date of delivery in the Clickpost reports

To be given in YYYY-MM-DD format
102023-02-23

Return Info (return_info)

In the "return_info" object, the details for the return address is to be provided. The details are particularly useful in case of a failed delivery or product return due to other reasons.

Field NameData TypeFieldDescriptionMax LengthExample
latFloatOptionalLatitude of the return location45.12211
longFloatOptionalLongitude of the return location88.12342
nameStringMandatoryContact name of the return contact of the shipment100"John Smith"
organisationStringOptionalName of the organisation the shipment is being returned to100"Walmart"
addressStringMandatoryAddress of the return location500"123, ABC Street"
districtStringOptionalDistrict of the return location100"Nadia"
cityStringMandatoryCity of the return location100"Frankfort"
stateStringMandatoryState/province of the return location100"Ohio"
landmarkStringOptionalLandmarks to help find the return location500"Near XYZ Towers"
emailStringOptionalEmail of the return contact50"[email protected]"
phoneStringMandatoryContact number of the return contact11"9876543210"
postal_codeStringMandatoryPostal code of the return location. If postal code system is not applicable for the location, use blank string.10"L4YG6C"
country_codeStringMandatoryAlpha ISO-2 country code of the return location2"CA"

Shipment Details (shipment_details)

In the 'shipment_details' field, the details regarding all items, and important order details like payment type, order type, courier partner, etc. are added.

Field NameData TypeFieldDescriptionMax LengthExample
itemsList[Object]MandatoryJson list with multiple item objects in it. Each item object represents a carton.
vendor_codeStringConditionalVendor code of pickup location. only if required by courier partner100"test_warehouse"
account_codeStringMandatoryCourier partner account name configured on the Clickpost dashboard. Will return a 400 Bad Request response if the given account is inactive or does not exist.100'test_courier'
heightIntegerMandatoryHeight of the overall package (in cms)25
breadthIntegerMandatoryWidth of the overall package (in cms)45
lengthIntegerMandatoryLength of the overall package (in cms)75
weightIntegerMandatoryWeight of the package (in gms)500
courier_partnerIntegerMandatoryPartner ID of the desired carrier. Refer to List of carriers supported by Clickpost to get the partner ID.123
reference_numberStringMandatoryReference number of the order. Must be unique for every shipment, i.e. every call of this API.100"TestOrder00001"
cod_valueFloatMandatoryCash to be given to the courier (currency to be determined by currency_code). Must be non-zero for COD orders, and zero for PREPAID orders.25.25
order_idStringOptionalIdentification string for the order100"TestOrderID00001"
order_typeStringMandatoryType of payment of the shipment. Can only take values "COD" or "PREPAID". cod_value must be non-zero for COD shipments and zero for PREPAID shipments.10"COD"/"PREPAID"
delivery_typeStringMandatoryType of delivery to be done. Can only take values "FORWARD" or "RVP".10"FORWARD"/"RVP"
rvp_reasonStringConditionalReason for returning the product/failed delivery. Mandatory if delivery_type is RVP.500"Defect in product"
invoice_valueFloatMandatoryValue of the shipment as mentioned in the invoice.256.29
invoice_dateStringMandatoryDate of issuance of the invoice of the shipment. (YYYY-MM-DD format only)1002022-01-10
awb_numberStringOptionalThe airwaybill number of the shipment.100"TESTAWB00001"
items_in_shipmentList[Object]OptionalContains a list of items. Only needed when multiple items of different SKUs are to be shipped in a single box

Item Level details (items)

🚧

Note: Each item object represents a carton box and should have the following:

Field NameData TypeFieldDescriptionMax LengthExample
descriptionStringMandatoryBrief description of the items500"Brown Cotton Socks - 1 pair"
quantityIntegerMandatoryNumber of units of the item in the box5
weightIntegerMandatoryWeight of the box500
priceFloatMandatoryNon-negative price of each unit of the box (currency to be decided by 'currency_code' field)64.99
gst_infoObjectConditionalRequired for multi-seller shipments
Information regarding the GST levied on the item. GST Info to be passed will have the same fields as thegst_infofield mentioned below.
additionalObjectConditionalAdditional details regarding the box
heightIntegerMandatoryHeight of the box (in cms)25
breadthIntegerMandatoryWidth of the box (in cms)45
lengthIntegerMandatoryLength of the box (in cms)75
Field NameData TypeFieldDescriptionMax LengthExample
catStringOptionalCategory of the item in question50Footwear
descriptionStringMandatoryBrief description of the item500"Brown Cotton Socks - 1 pair"
quantityIntegerMandatoryNumber of units of the item5
weightIntegerMandatoryWeight of each unit of the item500
priceFloatMandatoryPrice of each unit of the item (currency to be decided by 'currency_code' field)64.99
manufacture_country_codeStringOptionalAlpha-2 ISO Country code of manufacture of the item2"CA"
manufacture_countryStringOptionalFull country name of manufacture of the item100"Canada"
skuStringOptionalStock-keeping unit of the item100"SKU0001"
return_daysIntegerOptionalNumber of days within which the item can be returned5
exchange_daysIntegerOptionalNumber of days within which the item can be exchanged5
product_urlStringOptionalURL for the product. If there are multiple URLs, they can be sent as a single string with comma-separated values.1000"http://link1.to.product, http://link2.to.product"
imagesStringOptionalURL for the image(s) of the product. If there are multiple URLs, they can be sent as a single string with comma-separated values.1000"http://link.to.product.image1, http://link.to.product.image2"
carta_porteObjectConditionalApplicable for Mexican couriers only

Mexican couriers often require a bill of lading in their invoices, known as Carta Porte. This object encapsulates all necessary details for the bill of lading.
colorStringConditional OptionalColour of the item Applicable for quality checking for RVP shipments100"dark blue"
sub_categoryStringConditional OptionalCategory the item's type is classified in Applicable for quality checking for RVP shipments100"T-Shirts"
sizeStringConditional OptionalSize of the item
Applicable for quality checking for RVP shipments
100"XL"
brandStringConditional OptionalBrand of the item
Applicable for quality checking for RVP shipments
100"Puma"
return_reasonStringConditional OptionalReason for returning the item
Applicable for quality checking for RVP shipments
100"Defective product"
special_instructionsStringConditional OptionalSpecial Instructions for returning the item
Applicable for quality checking for RVP shipments
100"Handle with care"
imeiStringConditional OptionalIMEI number of the item (if it is a mobile device)
Applicable for quality checking for RVP shipments
100"12345678910111"
eanStringConditional OptionalEAN Number of the item
Applicable for quality checking for RVP shipments
100"EAN00001"
heightIntegerMandatoryHeight of one unit of the item (in cms)25
breadthIntegerMandatoryWidth of one unit of the item (in cms)45
lengthIntegerMandatoryLength of one unit of the item (in cms)75

Carta Porte Details (carta_porte field) - For Mexico Only

Mexican couriers often require a bill of lading per item in their invoices, known as Carta Porte. The carta_porte object encapsulates all necessary details for the bill of lading of the item. For more information, you can visit What you should know about the 'Carta Porte'

The following fields can be included in the carta_porte field.

Field NameData TypeFieldDescriptionMax LengthExample
bienesTranspStringConditional MandatoryA number representing the categorization of the SKU of the item by the government.100"10257"
descripcionStringConditional
Mandatory
Item description100"HP Pavillion Laptop"
materialPeligrosoBooleanConditional
Mandatory
Whether the item is dangerous/inflammable/reactive.
cveMaterialPeligrosoStringConditional
Mandatory
An ID for the item, denoting what type of danger it might pose if it is dangerous. Leave blank if materialPeligroso is set to false.10
embalajeStringConditional
Mandatory
Type of packing of the item10
claveUnidadStringConditional
Mandatory
Stock-keeping unit of the item100

The sample request payload may look like this:

Tax Info (tax_info)

This field will contain several information for the taxes levied on the shipment.

Field NameData TypeFieldDescriptionMax LengthExample
shipper_tax_idStringOptionalTax Identification Number of the shipper100"09AAFCK6022N1Z8"
consignee_tax_idStringOptionalTax Identification Number of the consignee100"123456"
consignee_tax_typeStringOptionalType of tax levied, on the consignee e.g: VAT, GST, etc.100"VAT"
consignee_tax_type_country_codeStringOptionalAlpha-2 ISO Country code, denoting the country where the tax is levied on the consignee2"US"
exporter_tax_idStringOptionalTax Identification Number of the exporter/shipper100"123456"
exporter_tax_typeStringOptionalType of tax levied, on the exporter/shipper e.g: VAT, GST, etc.100"VAT"
exporter_tax_type_country_codeStringOptionalAlpha-2 ISO Country code, denoting the country where the tax is levied on the exporter/shipper2"IN"
shipping_chargesStringOptionalThis refers to the shipping charges. In cases where duty is paid by the consignee (DDU) this value is pushed to denote the freight charges."10.234"
import_duty_vat_chargesStringOptionalSome countries have additional duties on imported goods. This field refers to the additional duty/vat that is going to be charged on the shipment when it's imported into the destination country."100"

Response

The response typically consists of the following fields. Keep in mind that additional fields can be present according to the requirement of the enterprise/courier.

Field NameData TypeDescription
metaObjectMetadata for the request, e.g. status code, error messages.
resultObjectActual result of the request
order_idIntegerOrder ID of the request
tracking_idIntegerA special ID of the request used for tracking

Response Meta

Field NameData TypeDescription
statusIntegerStatus code for the request (including but not limited to HTTP Status codes)
messageStringError/Success messages for the request
successBooleanWhether the order was successfully created or not

Response Result

Field NameData TypeDescription
waybillStringWaybill of the newly created order, or the one passed in the awb_number field (if any). This waybill is automatically registered for tracking in our database
reference_numberStringReference number of the order, sent in the payload.
labelString/NullURL to the generated label of the order. If labels are not needed, this stays null.
commercial_invoice_urlString(Appears for certain couriers) URL to the generated commercial invoice of the order
courier_partner_idIntegerID of the courier partner
courier_nameStringName of the courier
sort_codeString/NullCourier Partner Sort code. Certain couriers use something called a sort code that can be passed to the shipping label for custom-built labels. Will return null if sort codes are not supported.
security_keyStringUUID security key of the order that needs to be stored at the enterprise's end.
childrenObject(Only for MPS responses) A list of item objects, with details of each item

Sample Payload

{
   "additional":{
      "channel":"",
      "async":false,
      "duty_fee_paid_by":"R",
      "invoice_base_64":"PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPEVycm9yPjxDb2RlPkFjY2Vzc0RlbmllZDwvQ29kZT48TWVzc2FnZT5BY2Nlc3MgRGVuaWVkPC9NZXNzYWdlPjxSZXF1ZXN0SWQ+WThIR1pGN0FYS1hBRkQxQzwvUmVxdWVzdElkPjxIb3N0SWQ+YWhxenVzMG5Ycnc2aDM3dzVSWnhxUXBsblpQdFhPZzY2SnJBaGdScjd4cW5xVFVYOGNBUk50Yjl4bi9RNnYrdms2NGZGK3BqUjg4PTwvSG9zdElkPjwvRXJyb3I+",
      "is_fragile":false,
			"estimated_delivery_date":"2023-12-05",
      "label":true,
      "max_edd":"10",
      "order_date":"2023-08-21",
      "return_info":{
         "address":"Naman Midtown - A Wing - 18th floor Senapati Bapat Marg, Prabhadevi",
         "city":"Mumbai",
         "country_code":"IN",
         "district":"",
         "email":"[email protected]",
         "landmark":"",
         "lat":null,
         "long":null,
         "name":"Lokesh",
         "phone":"6285657600",
         "phone_code":"+91",
         "postal_code":"400013",
         "state":"Maharashtra"
      }
   },
   "courier_custom_fields":{
      
   },
   "drop_info":{
      "address":"usa",
      "city":"New York",
      "country_code":"US",
      "district":"",
      "email":"[email protected]",
      "landmark":"",
      "lat":null,
      "long":null,
      "name":"Sehdev",
      "phone":"8446313562",
      "phone_code":"+1",
      "postal_code":"10001",
      "state":"NY"
   },
   "pickup_info":{
      "address":"Naman Midtown - A Wing - 18th floor Senapati Bhawan, Mahesmati",
      "city":"Mumbai",
      "country_code":"IN",
      "district":"",
      "email":"[email protected]",
      "landmark":"",
      "lat":null,
      "long":null,
      "name":"Clickpost HQ",
      "phone":"02262808699",
      "phone_code":"+91",
      "postal_code":"400013",
      "state":"MH",
      "time":"2023-08-22T17:00:00"
   },
   "shipment_details":{
      "account_code":"Fedex Bundle Duty paid by Receiver",
      "breadth":8,
      "cod_value":0,
      "courier_partner":330,
      "currency_code":"INR",
      "delivery_type":"FORWARD",
      "height":13,
      "invoice_date":"2023-08-21",
      "invoice_number":"12324",
      "invoice_url":"http://link.to.inv1.com",
      "invoice_value":9000,
      "items":[
         {
            "breadth":8,
            "cat":"Customized Fashion Garments",
            "description":"Floral Print Anarkali With Dupatta",
            "fob_value":9000,
            "images":"https://fb.com/products/22/8/192005329771_BTM_RAW_1.JPG",
            "product_url":"https://fb.com/products/22/8/192005329771_BTM_RAW_1.JPG",
            "gst_info":{
               "igst_amount":0,
               "igst_tax_rate":0,
               "taxable_value":9000
            },
            "height":13,
            "hs_code":"44209090",
            "length":13,
            "manufacture_country":"INDIA",
            "manufacture_country_code":"IN",
            "price":9000,
            "product_category":"Customized Fashion Garments",
            "quantity":1,
            "sku":"615168",
            "sub_category":"Customized Fashion Garments",
            "weight":120,
            "width":0
         }
      ],
      "items_in_shipment":[
         {
            "box_number":1,
            "breadth":8,
            "cat":"Customized Fashion Garments",
            "description":"Floral Print Anarkali With Dupatta",
            "fob_value":9000,
            "exchange_days":2,
            "gst_info":{
               "igst_amount":0,
               "igst_tax_rate":0,
               "taxable_value":9000
            },
            "height":13,
            "hs_code":"44209090",
            "length":13,
            "manufacture_country":"INDIA",
            "manufacture_country_code":"IN",
            "price":9000,
            "product_category":"Customized Fashion Garments",
            "quantity":1,
            "sku":"615168",
            "sub_category":"Customized Fashion Garments",
            "weight":120,
            "width":0,
            "images":"http://link1.image.com,http://link2.image.com",
            "product_url":"http://link1.product.com,http://link2.procuct.com",
            "return_days":2
         }
      ],
      "length":13,
      "order_id":"304491",
      "order_type":"PREPAID",
      "reference_number":"304491-12324-14",
      "weight":120
   },
   "tax_info":{
      "consignee_tax_country_code":"US",
      "consignee_tax_id":"NA",
      "consignee_tax_type":"VAT",
      "consignee_tax_type_country_code":"US",
      "exporter_tax_country_code":"IN",
      "exporter_tax_id":"27AAACO7149M1ZZ",
      "exporter_tax_type":"VAT",
      "exporter_tax_type_country_code":"IN",
      "exporter_type":"",
      "import_duty_vat_charges":0,
      "shipper_tax_id":"27AAACO7149M1ZZ",
      "shipping_charges":0,
      "tax_amount":0,
      "tax_paid":true
   }
}
{
    "tax_info": {},
    "drop_info": {
        "lat": 0,
        "city": "Dubai",
        "long": 0,
        "name": "dsadsad sadsad",
        "email": "[email protected]",
        "phone": "9876543210",
        "state": "Dubai",
        "address": "123 ABC St",
        "district": "Dubai",
        "landmark": "Near III Towers",
        "phone_code": "+965",
        "postal_code": "12345",
        "country_code": "KW"
    },
    "pickup_info": {
        "lat": 25.1414664,
        "city": "Dubai",
        "long": 55.255369,
        "name": "TEST DO NOT PICKUP",
        "time": "2022-07-01T11:52:36+04:00",
        "email": "[email protected]",
        "phone": "1234567890",
        "state": "Dubai",
        "address": "123, ABC St",
        "district": "Dubai",
        "landmark": "Near HHH Towers",
        "phone_code": "+971",
        "postal_code": "502626",
        "country_code": "AE"
    },
    "shipment_details": {
        "items": [
            {
                "sku": "53813",
                "price": 249.29,
                "weight": 500,
                "hs_code": "6405.10.00",
                "quantity": 1,
                "description": "Tod's Blue Patent Cutout Ankle Strap Ballet Flats Size 39.5",
                "manufacture_country": "Italy",
                "manufacture_country_code": "IT",
                "cat": "Footwear",
              	"images": "http://link1.image.com,http://link2.image.com",
              	"product_url": "http://link1.product.com,http://link2.procuct.com",
              	"return_days": 2,
              	"exchange_days": 2,
              	"color": "dark blue",
              	"brand": "Tod's",
              	"size": "39.5",
              	"sub_category": "Flats",
              	"return_reason": "Defective",
              	"special_instructions": "Handle with care",
              	"imei": "12345678910111",
              	"ean": "EAN123456"
            },
            {
                "sku": "53814",
                "price": 111.00,
                "weight": 78,
                "hs_code": "1234.56.78",
                "quantity": 1,
                "description": "Tod's Blue Shoes - Size 8",
                "manufacture_country": "Italy",
                "manufacture_country_code": "IT",
                "cat": "Footwear",
              	"images": "http://link1.image.com,http://link2.image.com",
              	"product_url": "http://link1.product.com,http://link2.procuct.com",
              	"return_days": 2,
              	"exchange_days": 2,
              	"color": "dark blue",
              	"brand": "Tod's",
              	"size": "39.5",
              	"sub_category": "Flats",
              	"return_reason": "Defective",
              	"special_instructions": "Handle with care",
              	"imei": "12345678910111",
              	"ean": "EAN123456"
            }
        ],
        "height": 13,
        "length": 23,
        "weight": "1000",
        "breadth": 31,
        "order_id": "Test.UPS.Order0002",
        "cod_value": 50,
        "order_type": "COD",
        "invoice_date": "2022-06-21",
        "account_code": "test",
        "currency_code": "USD",
        "delivery_type": "RVP",
        "rvp_reason": "Defective product",
        "invoice_value": 468.58,
        "invoice_number": "TLC-2022-06-WS-00038",
        "courier_partner": "107",
        "reference_number": "Test.UPS.Order0002"
    },
    "additional": {
        "return_info": {
            "lat": 25.1414664,
            "city": "Dubai",
            "long": 55.255369,
            "name": "TEST DO NOT RETURN",
            "email": "[email protected]",
            "phone": "1234567890",
            "state": "Dubai",
            "address": "123, ABC St",
            "district": "Dubai",
            "landmark": "Near RRR Towers",
            "phone_code": "+965",
            "postal_code": "502626",
            "country_code": "KW"
        },
      	"label": true,
      	"invoice_base_64": "JVBERklsfhs16561sfsfsvsvsv"
    },
  	"courier_custom_fields": {}
}
{
    "drop_info": {
        "city": "HERMOSILLO",
        "name": "Hernan Cortez",
        "time": "2022-09-07T19:16:24",
        "email": "[email protected]",
        "phone": "1234567890",
        "state": "SO",
        "district":"HERMOSILLO",
        "address": "52, ABC Calle",
        "phone_code": "+52",
        "postal_code": "12345",
        "country_code": "MX",
        "alternate_phone": "",
        "lat": 12.34,
        "long": 56.78,
        "instructions": "Leave at the door",
        "landmark": "lampost"
    },
    "additional": {
        "from_wh": "",
        "asn_code": "Test-GLS-MX-1",
        "order_id": "521512117539Test5",
        "sort_code": "",
        "account_code": "paq-testing",
        "channel_name": "",
        "user_defined_field_array": [
            {
                "name": "ship_via_method",
                "type": "String",
                "value": "75120003"
            },
            {
                "name": "max_edd",
                "type": "String",
                "value": "2022-09-19"
            },
            {
                "name": "ship_via_po",
                "type": "String",
                "value": "521512117539-2-Test4"
            }
        ]
    },
    "pickup_info": {
        "city": "MEGAPARK",
        "name": "WALMART.COM",
        "time": "2022-09-07T19:16:24",
        "email": "[email protected]",
        "phone": "9876543210",
        "state": "CP",
        "address": "113, Tlaloc Calle",
        "district":"MEXICO",
        "phone_code": "+52",
        "postal_code": "54321",
        "country_code": "MX",
        "lat": "",
        "long": "",
        "landmark": "Society Park"
    },
    "shipment_details": {
        "items": [
            {
                "sku": "6000202721854",
                "price": 0,
                "height": 17,
                "length": 25,
                "weight": 1000,
                "breadth": 1,
                "quantity": 1,
                "additional": {
                    "asn_code": "Test-GLS-MX-1"
                },
                "carta_porte": {
                    "embalaje": "",
                    "claveUnidad": "H87",
                    "descripcion": "LapTop",
                    "bienesTransp": "10282",
                    "materialPeligroso": "",
                    "cveMaterialPeligroso": ""
                },
                "description": "Baby powder"
            }
        ],
        "height": 17,
        "length": 25,
        "weight": 1000,
        "breadth": 1,
        "cod_value": 0,
        "order_type": "PREPAID",
        "invoice_date": "2022-09-19",
        "currency_code": "MXN",
        "delivery_type": "FORWARD",
        "invoice_value": 1,
        "invoice_number": "IOL-000024",
        "courier_partner": 234,
        "reference_number": "TEST30092022003"
    },
  	"additional": {
        "return_info": {
            "lat": 25.1414664,
            "city": "San Francisco de Campeche",
            "long": 55.255369,
            "name": "TEST DO NOT RETURN",
            "email": "[email protected]",
            "phone": "1234567890",
            "state": "Campeche",
            "address": "123, ABC St",
            "district": "Campeche City",
            "landmark": "Near RRR Towers",
            "phone_code": "+52",
            "postal_code": "502626",
            "country_code": "MX"
        },
      	"label": true
    },
  	"courier_custom_fields": {}
} 

Sample Response

{
    "meta": {
        "status": 400,
        "message": "Error Message",
        "success": false
    }
}
{
    "meta":{
        "status":200,
        "message":"Order Placed Successfully",
        "success":true
    },
    "result":{
        "label":"https://pyck-res-bucket.s3.amazonaws.com:443/DHL_MPS/2022-11-09/6852865692.pdf",
        "waybill":"6852865692",
        "order_id":151445760,
        "sort_code":null,
        "tracking_id":506175035,
        "courier_name":"DHL",
        "security_key":"efa57dfe-8456-4744-b83d-cd9f36577632",
        "courier_partner_id":164,
        "commercial_invoice_url":"https://pyck-res-bucket.s3.amazonaws.com:443/DHL_MPS/INVOICE_DATA/2022-11-09/6852865692.pdf"
    }
}

Possible Error Codes

These are the list of possible error/status codes that can appear in the response metadata, and the actionables corresponding to each.

Meta Status CodeHTTP Status CodeDescriptionActionableOrder Successful?Status Message
102200For async orders: The order has been recorded in Clickpost's database and is under processing.Need to re-attempt Clickpost's order creation API to check if the order has been processed.No"
200200The order is successfully createdNoneYes"Success"
301200The customer is sending an invalid/non-existent/inactive license key in the URL parametersNeed to re-attempt the order with a valid/registered/active license key.No"Authentication Failed: Invalid Token or API Key"
302200Either of the three things:
- The customer is sending the courier_partner value as a string
- The customer is sending a null value in the courier_partner field.
- The partner ID being sent in courier_partner field does not exist.
Need to re-attempt the order with a valid integer value in the courier_partner field, and the value should exist in Clickpost's database.No"Invalid Courier Partner Id with Field courier_partner"
303200For async orders: The awb_number provided already exists and is registered by ClickpostNeed to re-attempt the order with a different awb_number value.Yes"Waybill already registered"
307200Theorder_type value is anything other than PREPAID, COD or EXCHANGE, or is null.Need to re-attempt the order with the order_type as either PREPAID, COD or EXCHANGE.No"You have entered invalid Order Type"
308200Thepriority value is anything other than NORMAL or URGENT.Need to re-attempt the order with the priority as either NORMAL or URGENT.No"You have entered invalid Order priority"
309200Thedelivery_type value is anything other than FORWARD or RVP.Need to re-attempt the order with the delivery_type as either FORWARD or RVP.No"Invalid Delivery Type"
310200In case of RVP orders: This is due to either of the following
- The rvp_reason field is missing
- The rvp_reason length is more than 500 characters.
Need to re-attempt the RVP order with a non-null rvp_reason value within 500 characters.No"RVP reason is missing" or "RVP reason can't be more than 500 chars"
311200For RVP orders: The courier partner defined by the courier_partner field does not support RVP shipments, or is not an RVP courier.Need to re-attempt the RVP order with a courier_partner value that supports RVP shipments.No"Invalid Courier Partner For RVP"
312200There is no item data in the payload (in the item field).Need to retry the order with a non-empty items array.No"Items Data is missing from order details"
313200Either of the following:
- The item data being sent in the items field is either a string or any other invalid format.
- The items value is an array, but of anything other than objects.
- The items value is an array of objects, but one or more mandatory fields are missing for one or more items.
Need to retry the order with proper items data, as an array of JSON objects.No"Invalid Format of items for Order data"
314200There is an issue with the order data being passed.The error is captured in the status message. Retry the order after addressing the status message.No"Invalid Format of items for Order data: "
315200Either of the following:
- For a PREPAID order, the cod_value is non-zero.
- For a COD order, the cod_value is zero.
Need to retry the orders after:
- (For PREPAID orders) setting the cod_value to zero.
- (For COD orders) setting the cod_value to a non-zero number
No"Invalid Cod Value"
316200There are no credentials for the courier partner of the account given in account_code, or the credentials are blank.Need to re-attempt the order with a different account_code, or fill the credential fields in the dashboard and retry.No"You do not have credentials for the Courier Partner"
319200There is an issue in placing orders with the courier partner.The actual error generally pops up alongside the error message. In cases where the error message is vague, contact the support team.No"Error In Order Placing To Courier Partner: "
320200The enterprise has not subscribed for Clickpost's Order Creation Service.Need to subscribe to the order creation service, then retry with all valid details and credentials.No"This service is not subscribed by you"
321200The awb provided in the awb_number field does not exist in Clickpost's database.Need to provide a registered AWB, or remove the AWB field and try again.No"Awb Number Does not exist in system for courier partner"
322200There is an issue in the courier partner servers.Need to retry after waiting for a while, or get in touch with Clickpost support or the courier partner support.No"Internal Server Error In Courier Partners Server"
323200An order is already present in Clickpost's database with the same reference number as the one provided.Need to re-attempt the order with a different reference numberYes"You have already placed this order"
328200Some mandatory field in the POST data might be missing.Check for missing fields that are supposed to be there in the data and retryNo"Invalid POST data"
329200The connection to the courier partner's API timed out.Need to retry after waiting for a while, or get in touch with Clickpost support or the courier partner support.No"Courier Partner API timeout"
351200The account name of the courier partner account given in the account_code field does not exist for the enterprise user.The user needs to check either/all of the things below if they are correct
- Enterprise license key in the URL params
- Courier Partner ID in the courier_partner field.
- Account name in the account_code field, and whether this account exists for this courier partner.

Re-attempt the order after correcting any of the incorrect details mentioned above.
No"Clickpost Account: Does not exist"
352200There are multiple accounts of the same enterprise with the same courier partner with the same name as the one in account_code field.No"Multiple account exists"
353200The account mentioned in the account_code field is inactive.Need to either enable the account on the dashboard from the enterprise's end, or use an active account.No"Clickpost Account: Inactive"
354200There is an unhandled error from the courier partner's end.The error is typically visible in the status message and can be fixed accordingly. In case of vague error messages, get in touch with the support teamNo"Unhandled error! Contact [email protected]" or the actual error
355200In certain couriers the vendor_code field is required. This error pops up whenever vendor_code is not passed in the payloadNeed to pass the vendor_code field alongwith a registered vendor code.No"Vendor code not found"
400200There is an issue with the payload, or some invalid data is being sent in the request.Need to fix the issues in the payload as mentioned in the status message. If "Bad Request" pops up, get in touch with the support team.No"Bad Request" or the actual error
500200There is an error in Clickpost's servers.Need to wait a while and try again. If this error pops up even after multiple tries, get in touch with the support team.No"Oops! Internal server error in Clickpost"