curl -X PATCH https://api.kasiye.com/v1/shipments/SHP-12345 \
-H "Authorization: Bearer shp_your_key" \
-H "Content-Type: application/json" \
-d '{
"customer_name": "Acme Corp",
"customer_email": "logistics@acme.com",
"pickup_address": "Area 47, Lilongwe",
"pickup_lat": -13.9626,
"pickup_lng": 33.7741,
"dropoff_address": "City Centre, Lilongwe",
"dropoff_lat": -13.9833,
"dropoff_lng": 33.7689,
"weight_kg": 40
}'
Shipments
Update a shipment
Change customer, addresses, and weight while the shipment is unpaid.
PATCH
/
shipments
/
{shipment}
curl -X PATCH https://api.kasiye.com/v1/shipments/SHP-12345 \
-H "Authorization: Bearer shp_your_key" \
-H "Content-Type: application/json" \
-d '{
"customer_name": "Acme Corp",
"customer_email": "logistics@acme.com",
"pickup_address": "Area 47, Lilongwe",
"pickup_lat": -13.9626,
"pickup_lng": 33.7741,
"dropoff_address": "City Centre, Lilongwe",
"dropoff_lat": -13.9833,
"dropoff_lng": 33.7689,
"weight_kg": 40
}'
Allowed only while
After payment, update returns
status is pending and payment_status is awaiting_payment. Kasiye recalculates the quote. If the new route is not covered, the shipment is left unchanged and the API returns 422.
The request body is the same as create.
string
required
Shipment reference, for example
SHP-12345.string
required
Customer display name.
string
required
Customer email.
number
Existing customer id on this workspace. Ignored if it belongs to another team.
string
Optional national id or similar identifier.
string
required
Human-readable pickup address.
number
required
Pickup latitude (
-90 to 90).number
required
Pickup longitude (
-180 to 180).string
required
Human-readable dropoff address.
number
required
Dropoff latitude (
-90 to 90).number
required
Dropoff longitude (
-180 to 180).number
required
Package weight in kilograms. Must be at least
0.01.curl -X PATCH https://api.kasiye.com/v1/shipments/SHP-12345 \
-H "Authorization: Bearer shp_your_key" \
-H "Content-Type: application/json" \
-d '{
"customer_name": "Acme Corp",
"customer_email": "logistics@acme.com",
"pickup_address": "Area 47, Lilongwe",
"pickup_lat": -13.9626,
"pickup_lng": 33.7741,
"dropoff_address": "City Centre, Lilongwe",
"dropoff_lat": -13.9833,
"dropoff_lng": 33.7689,
"weight_kg": 40
}'
422:
{
"message": "This shipment can no longer be updated.",
"errors": {
"shipment": ["This shipment can no longer be updated."]
}
}