API Update Order
Update information of created order. Only available when shipping status
Caution : The API Order Info need to infusion token and shop_id in header
post/gethttps://online-gateway.ghn.vn/shiip/public-api/v2/shipping-order/update
https://dev-online-gateway.ghn.vn/shiip/public-api/v2/shipping-order/update
curl --location --request POST 'https://dev-online-gateway.ghn.vn/shiip/public-api/v2/shipping-order/update' \
--header 'Content-Type: application/json' \
--header 'ShopId: 885' \
--header 'Token: 637170d5-942b-11ea-9821-0281a26fb5d4' \
--header 'Content-Type: text/plain' \
--data-raw '{"note":"nhớ gọi 30p khi giao","order_code":"5F5NH3LN"}'
Parameter
Field | Type | Description |
---|---|---|
token | String |
Must be sent with all client requests. This Token helps server to validate request source. Provided by GHN. |
shop_id | Int |
Manage information for shop/seller |
order_code | String |
GHN Order Code. This is tracking code. |
from_name | String |
Client name. (Shop / Seller) |
from_phone | String |
Client phone. (Shop / Seller) |
from_address | String |
Client address. (Shop / Seller) |
from_ward_code | String |
Ward Code pick up parcels. Use API GetWards. |
to_name | String |
Client name. (Shop / Seller) |
to_phone | String |
Client phone number. (Shop / Seller) |
to_address | String |
Client address. (Shop / Seller). |
to_ward_code | String |
Ward Code pick up parcels.Use API Get Ward |
to_district_id | Int |
District ID drop off parcels.Use API Get District |
return_phone | String |
Contact phone number to return parcels. |
return_address | String |
Address return parcels. |
return_district_id | Int |
District ID return parcels. Use API GetDistricts |
return_ward_code | String |
Ward Code return parcels. Use API Get Ward. |
client_order_code | String |
External order code managed by logged client [Unique field]. Default value: |
cod_amount | Int |
Amount cash to collect. Maximum Default value: |
content | String |
Content for order |
weight | Int |
Weight (gram) |
length | Int |
Length (cm) |
width | Int |
width (cm) |
height | Int |
height (cm) |
pick_station_id | Int |
The shipper not pickup parcels at shop’s address |
insurance_value | Int |
Use to declare parcel value. GHN will base on this value for compensation if any unexpected things happen (lost, broken...). Maximum Default value: |
coupon | String |
Coupon Code for discount. |
service_type_id | Int |
Input value 1: Express , 2: Standard or 3: Saving (if not input service_id) |
service_id | Int |
Choose which Sevice ID suitable with your shipping plan (Express, Standard or Saving). Each Service ID has different fee and leadtime. Use API Get service (if not input service_type_id) |
payment_type_id | Int |
Choose who pay shipping fee.
|
note | String |
Client note for shipper. Ex: Please call before delivery |
required_note | String |
Note shipping order.Allowed values: |
{
"code": 200,
"message": "Success",
"data":null
}
{
"code": 400,
"message": "code=400, message=Syntax error: offset=30, error=invalid character '}' after array element, internal=invalid character '}' after array element",
"data": null
"code_message": "USER_ERR_COMMON"
}