Create a Bill By ID

Create Bill By ID Location

Automatically transfer order information to Nhat Tin including details such as dimensions, weight, phone number, and many other information. From there, a delivery order will be created.

API Configuration

HTTP Request

POST /v1/bill/create-byID

No.ParameterTypeRequireDescription
1partner_idNumberAlt textID of partner. That registration on https://khachhang.ntlogistics.vn/ (opens in a new tab)
2ref_codeStringCustomer's Reference Code - might be Invoice No or Purchase Order No
3package_noNumberNumber or Packages (Default 1)
4weightDoubleAlt textEstimated Weight of packages measured by client
5widthDoubleWidth of Package in Total (Measured in cm,Default 0)
6lengthDoubleLength of Package in Total (Measured in cm,Default 0)
7heightDoubleHeight of Package in Total (Measured in cm,Default 0)
8cargo_contentStringBreif description of Package Product Items
9service_idNumberAlt textShipping Service Id. Define in Master Data sheet
10payment_method_idNumberAlt textPayment Method Id. Define in Master Data sheet
11is_return_docintReturn document or invoice (1: Yes, 0: no, Default is 0)
12cod_amountDoubleAmount of COD to collect when package delivered to receiver
13noteStringAdditional note, delivery instruction of the order
14cargo_valueDoubleBreif value of Package Product Items
15cargo_type_idNumberAlt textBreif ID of Package Product Items.
16s_nameStringAlt textFullname of sender
17s_phoneStringAlt textSender contact phone number
18s_addressStringAlt textAddress of sender
19s_ward_idNumberAlt textWard ID of sender
20s_district_idNumberAlt textDistrict ID of sender
21s_province_idNumberAlt textProvince ID of sender
22r_nameStringAlt textFull name of receiver
23r_phoneStringAlt textReceiver's contact phone number
24r_addressStringAlt textFull address of receiver (e.g., Tổ 5, KP7, 52A Nguyễn Thái Bình)
25r_ward_idintAlt textWard ID of receiver
26r_district_idintAlt textDistrict ID of receiver
27r_province_idintAlt textProvince ID of receiver
28r_emailStringEmail address of receiver
29utm_sourceStringAlt textThe UTM source passed from the partner in the format api_partnername (e.g., api_garmin). Used to help the carrier system with additional analysis information in case of incidents.

JSON body respone

NameTypeDescription
successbooleanReturn true if create bill success, all other false means error. See message for further description.
messagestringReturn Message of API Respond.
dataobjectData of API response.

Request

{
   "partner_id: 123736,
   "ref_code": "TEST-009",
   "package_no": 1,
   "height": 0,
   "s_name": "Shop A",
   "s_phone": "0969755353",
   "s_province_id": 50,
   "s_district_id": 5001,
   "s_ward_id": 28250,
   "s_address": "52A, Nguyễn Thái Bình",
   "r_name": "Nguyễn Văn A",
   "r_phone": "0969755353",
   "r_province_id": 50,
   "r_district_id": 5001,
   "r_ward_id": 28244,
   "r_address": "40 Út Tịch",
   "r_email": "emamil_nguoi_nhan@gmail.com",
   "cod_amount": 200000,
   "service_id": 10,
   "payment_method_id": 10,
   "cargo_type_id": 2,
   "cargo_content": "Quần áo",
   "cargo_value": 1000000,
   "note": "ghi chú đơn hàng",
   "utm_source": "api_nt",
   "is_return_doc": 0
  }

Response

{
"success": true,
"messsage": "",
"data":
        {
           "bill_id": 159840,
           "bill_code": "CP15984057",
           "ref_code": "TEST-009",
           "status_id": 2,
           "cod_amount": 200000,
           "service_id": 10,
           "payment_method": 10,
           "created_at": "2022-12-01 15:39:00",
           "main_fee": 33462,
           "cod_fee": 0,
           "insurr_fee": 5500,
           "lifting_fee": 0,
           "remote_fee": 0,
           "counting_fee": 0,
           "packing_fee": 0,
           "total_fee": 38962,
           "partner_address_id": 24371,
           "receiver_name": "Nguyễn Văn A",
           "receiver_phone": "0969755353",
           "receiver_address": "40 Út Tịch",
           "package_no": 1,
           "weight": 1.3,
           "cargo_content": "Quần áo",
           "cargo_value": 1000000,
           "note": "ghi chú đơn hàng"
        }
}