NB: The 'user' field in the request body is the control business id.
{
"status": true,
"message": "Delivery cancelled",
"data": {
}
}
{
"status": false,
"message": "Invalid app_id or app_secret",
"data": {
"statusCode": 401,
"message": "Invalid app_id or app_secret",
"isOperational": true,
}
}
// Sample Request Information
Url: https://sandbox.sendstack.africa/api/v1/drops/updateDeliveryWindow
Method: POST
Headers:
- app_id: "your app_id"
- app_secret: "your app_secret"
// Sample Request body
{
"estimatedPickupWindow": {
"date": "2024-09-22 00:00:00",
"start": "2024-09-22 07:00:00",
"end": "2024-09-22 13:00:00"
},
"estimatedDropoffWindow": {
"date": "2024-09-22 00:00:00",
"start": "2024-09-22 13:00:00",
"end": "2024-09-22 18:00:00"
},
"user": "65b78c4e13d8753d300a1c59",
"dropIds": ["65b8c2c734d8cd1be099fd45"],
"pickupDate": "2024-09-22"
}
//Sample Response Body - 200 OK
{
"status": true,
"message": "Delivery window updated",
"data": [
{
"id": "65b8c2c734d8cd1be099fd45",
"status": "PENDING",
"paymentStatus": "PENDING",
"trackingId": "E033LM",
//...truncated for brevity
}
]
}
// Sample Request body
{
"estimatedPickupWindow": {
"date": "2024-09-22 00:00:00",
"start": "2024-09-22 07:00:00",
"end": "2024-09-22 13:00:00"
},
"estimatedDropoffWindow": {
"date": "2024-09-22 00:00:00",
"start": "2024-09-22 13:00:00",
"end": "2024-09-22 18:00:00"
},
"user": "65b78c4e13d8753d300a1c59",
"dropIds": ["invalidDropId"],
"pickupDate": "2024-09-22"
}
//Sample Response Body - 400 Bad Request
{
"status": false,
"message": "Invalid dropId"
}