Skip to main content

Reject Order (NACK)

Negative acknowledge the order (reject the order).

Path​

post

/v1/order/:order_id/fs/:fs_id/nack

Request Parameters​

ParameterTypeRequiredLocationDescription
order_id
Integer
Required
path
Order unique identifier
fs_id
Integer
Required
path
Fulfillment service unique identifier
reason_code
Integer
Required
body
Reason code of the order rejection. Check Order Reject Reason for available reason code
reason
String
Required
body
Reason of the order rejection
shop_close_end_date
String
Optional
body
Mandatory if reason_code is 4 (shop closed). The date string layout is DD/MM/YYYY e.g. 17/05/2017.
shop_close_note
String
Optional
body
Mandatory if reason_code is 4 (shop closed).
empty_products
Integer Array
Optional
body
Prodct id(s) that has empty stocks

Note: For query order_id and invoice_num, user must choose one of those queries to retrieve order information

Example Request​

curl -X POST \
https://fs.tokopedia.net/v1/order/12490706/fs/13004/nack \
-H 'Authorization: Bearer OoHgyxcgQ5a1uCbmbbXjjA' \
-H 'Content-Type: application/json' \
-d '{
"reason_code": 1,
"reason": "out of stock",
"shop_close_end_date": "17/05/2017",
"shop_close_note": "Maaf Pak, shop saya tutup untuk liburan",
"empty_products": [2148038232, 2148042339]
}'

Response Parameters​

NameTypeDemo ValueDescription
data
String
success
Response Message

Success Response Examples​

{
"header": {
"process_time": 0.18334048,
"messages": "Your request has been processed successfully"
},
"data": "success",
}

Error Response Examples​

{
"header": {
"process_time": 0.12873117,
"messages": "We could not process your request due to malformed request, please check again",
"reason": "Error When Request Reject Order To Ext Service",
"error_code": "ORD_USC_014"
},
"data": null
}

Error Codes​

Error CodeError MessageDescription
ORD_API_006
There Are Error From Ext Service
Failed getting response from upstream
ORD_USC_003
Order ID from warehouse id is not authenticate
Order ID is not associated with Warehouse ID
ORD_USC_004
Order ID need to be fulfilled by tokocabang
ORD_USC_005
Order ID from shop id is not authenticate
Order ID is not associated with Shop ID
ORD_USC_006
Admin ID Not Found From Shop ID
ORD_USC_008
Order Status not eligible to reject
Order satatus it not eligible to changed to reject
ORD_USC_009
Mandatory To Fill Reason
It is required to fill reject reason
ORD_USC_010
Failed Getting Products
Failed getting product information
ORD_USC_011
No Matching product id
ORD_USC_012
Mandatory To Fill Shop Close End Date and Note
It is required to fill shop close end date and note
ORD_USC_013
Shop Close End Date Present But Invalid
Invalid shop close end date value
ORD_USC_014
Error When Request Reject Order To Ext Service
Failed getting response from upstream
ORD_USC_018
Order ID from warehouse id is not authenticate
Order ID is not associated with Warehouse ID
ORD_USC_019
Order need to get request cancellation first from buyer
ORD_USC_020
You are not allowed to reject this order
ORD_DLV_002
invalid fs_id format
Invalid fs_id format, please check again
ORD_DLV_005
invalid order_id format
Invalid order_id format, please check again
ORD_DLV_019
failed read body request
Failed read body request, please check again
ORD_DLV_020
wrong json format
Wrong JSON body format, please check again

Notes​

These are the available order reject reason (possible reasons)

CodeDescription
empty/0
Only for reject shipping case - reason required with max length 200 characters
1
Product(s) out of stock
2
Product variant unavailable
3
Wrong price or weight
4
Shop closed. close_end and closed_note required
5
Others
7
Courier problem - reason required with max length 200 characters
8
Buyer’s request - reason required with max length 200 characters

Have a feedback?