Order API - Update check first
Update Check First
Endpoint: POST *base*/check-first
Authentication: API Key
This will update the status of a check-first warehouse on an order.
Updating a check first for an order is irreversible. Once an order has been accepted or rejected, it can no longer be changed.
Parameters
Order ID to update the Check first.
Warehouse ID associated with the Check first order.
Whether to accept or reject the Check First warehouse. true
to accept, false
to reject.
Request example
POST <base>/check-first HTTP/1.1
Content-type: application/json
{
"orderNumber": 123,
"warehouseId": 321,
"accepted": true
}
Response
200
Content-type: application/json
ok
if success, else no
.
If status
returns no
, this value should send back a message why it failed.
Error message describing an issue with the provided order number.
Error message describing an issue with the provided warehouse id.
Error message describing an issue with the provided accepted value.
Response example
HTTP/1.1 200 OK
Content-type: application/json
{
"status": "ok"
}
Error examples
{
"status": "no",
"msg": {
"orderNumber": "invalid value",
"warehouseId": "required",
"accepted": "invalid value"
}
}
{
"msg": "order does not exist",
"status": "no"
}
{
"msg": "failed to allocate stock",
"status": "no"
}