Create Orders POST
/order/orders/
Request Example
Development Endpoint: https://api.int.janio.asia/api/order/orders/
Production Endpoint: https://api.janio.asia/api/order/orders/
{
"secret_key": "string",
"blocking": false,
"orders": [
{
"service_id": 1,
"shipper_order_id": "ORDER123",
"order_length": 12,
"order_width": 12,
"order_height": 12,
"order_weight": 12,
"payment_type": "cod",
"cod_amt_to_collect": 40.5,
"incoterm": "DDP",
"identification_document_name": "LOCALTAXID",
"consignee_identifcation_number": "S1234567G",
"consignee_name": "Susan",
"consignee_number": "+6291234567891",
"consignee_country": "Indonesia",
"consignee_address": "Pos 5 security komp perumahan PT INALUM tanjung gading., Jln berangin.",
"consignee_postal": "12420",
"consignee_state": "Daerah Khusus Ibukota Jakarta",
"consignee_city": "Jakarta Selatan",
"consignee_province": "Cilandak",
"consignee_email": "susan123@email.com",
"pickup_contact_name": "Jackson",
"pickup_contact_number": "+6591234567",
"pickup_country": "Singapore",
"pickup_address": "Jurong West Ave 1",
"pickup_postal": "640534",
"pickup_state": "Singapore State",
"pickup_city": null,
"pickup_province": null,
"items": [
{
"item_desc": "Blue Male T-Shirt",
"item_category": "Fashion Apparel",
"item_product_id": "PROD123",
"item_sku": "ITEMSKU123",
"item_quantity": 3,
"item_price_value": 23.55,
"item_price_currency": "IDR"
}
]
}
]
}
For more information regarding our request parameters, please vist our FAQ Page
Response Example
Success (non blocking) 201
// Tracking numbers in "tracking_nos" array are ordered in the same order of tracking numbers supplied
{
"upload_batch_no": "ABC123456",
"tracking_nos": [
"TRACKINGNUMBER1",
"TRACKINGNUMBER2",
"TRACKINGNUMBER3"
]
}
Success (blocking) 201
// Orders in "orders" array are ordered in the same order of orders supplied.
// "order_label_url" is the URL linking to the label of each order.
{
"upload_batch_no": "ABC123456",
"orders": [
{
"tracking_no": "TRACKINGNUMBER1",
"order_label_url": "https://order-label-url.com/TRACKINGNUMBER1/"
},
{
"tracking_no": "TRACKINGNUMBER2",
"order_label_url": "https://order-label-url.com/TRACKINGNUMBER2/"
},
{
"tracking_no": "TRACKINGNUMBER3",
"order_label_url": "https://order-label-url.com/TRACKINGNUMBER3/"
}
]
}
Accepted (blocking) 202
// Orders in "orders" array are ordered in the same order of orders supplied.
// This case occurs when labels for one or more of the orders cannot be generated due to errors in submission to external partners.
// For orders whose labels are not generated, "order_label_url" is null and "message" is the error message.
// For these orders, you can try to obtain the order label URL some time again in the future using the view orders API.
// If order label URL remains to be unavailable, please contact clientsupport@janio.asia for assistance.
{
"upload_batch_no": "ABC123456",
"orders": [
{
"tracking_no": "TRACKINGNUMBER1",
"order_label_url": "https://order-label-url.com/TRACKINGNUMBER1/"
},
{
"tracking_no": "TRACKINGNUMBER2",
"order_label_url": "https://order-label-url.com/TRACKINGNUMBER2/"
},
{
"tracking_no": "TRACKINGNUMBER3",
"order_label_url": null,
"message": "We are unable to generate label for this order. Please contact our customer support at clientsupport@janio.asia for further assistance on label creation. Apologies for the inconvenience caused.'
}
]
}
Failure 400
// Errors are sorted by the index of order submission, for e.g., the 2nd order submitted will always be index 1.
{
"orders": [
{
"fieldname_as_key": [
"Enter a valid email address."
]
}
]
}
Failure 400
// Returns when order value is incorrect
{
"orders": [
{
"order_width": [
"A valid number is required."
]
}
]
}
Failure 400
// Returns when item value is incorrect
{
"orders": [
{
"items": [
{
"item_quantity": [
"A valid integer is required."
]
}
]
}
]
}