Book an instant courier
Send a same-day delivery with a motorbike or car, at a time you choose, and follow the driver.
- Product
- APIShipping Engine API
- Section
- Guides
- Reading time
- 7 min read
Goal: book an instant courier (Lalamove, GrabExpress, Paxel, Dash or Blitz) that picks the parcel up within the hour or at a time you choose, and show your customer who the driver is.
Before you start:
- You can book a regular shipment. Instant booking uses the same endpoints with a few extra fields.
- You have the coordinates (latitude and longitude) of the pickup point and of every drop-off point. Instant couriers price by distance.
- Your API key has
READ_SHIPPING_RATESandCREATE_ORDER.
Pick a vehicle the parcel fits
Instant couriers need a
vehicle. List the vehicles and their limits (no token needed):curl -s "$FASTRAC_API/public/vehicles"InboundResponse (example values) { "statusCode": 200, "message": "Vehicles retrieved successfully.", "data": [ { "code": "BIKE", "name": "Motor", "length": 40, "width": 40, "height": 40, "weight": 20000 } ] }length,widthandheightare in cm andweightin grams. Pick the smallest vehicle that holds the whole parcel: the total weight must not exceedweight, and every package must fit the vehicle in some orientation. A parcel that doesn't fit is refused when you create the order, for exampleTotal package weight (25000g) exceeds the maximum capacity of vehicle 'Motor' (20000g).Quote with coordinates, vehicle and (optionally) a time
Request rates with
courierCode: "INSTANT"to ask every instant courier, or a single code such asLALAMOVE. Addcoordinateto the origin and every destination, andvehicle.insuranceis optional for instant couriers.To book for later, add
scheduledAt. Leave it out for as soon as possible.curl -s -X POST "$FASTRAC_API/b2b/shipping-rate" \ -H "Authorization: Bearer $FASTRAC_TOKEN" \ -H "Content-Type: application/json" \ -d '{ "origin": { "fullAddress": "Jl. Tebet Raya No. 12, Jakarta Selatan", "subdistrictId": "3174091001", "coordinate": { "latitude": -6.2262, "longitude": 106.8530 } }, "destinations": [{ "fullAddress": "Jl. Kemang Raya No. 5, Jakarta Selatan", "subdistrictId": "3174071004", "coordinate": { "latitude": -6.2607, "longitude": 106.8137 } }], "courierCode": "INSTANT", "vehicle": "BIKE", "scheduledAt": "2026-11-21T14:00:00+07:00", "packages": [{ "itemValue": 150000, "isGlassware": false, "weight": 1500, "dimension": { "length": 25, "width": 20, "height": 15 } }] }'Rate coordinates are numbers. Remember the
scheduledAtyou sent: you need it again in the next step.Create the order with the same schedule
Instant shipments default to
PICKUP. Send the sender'scoordinate(as strings in the order) and, if you quoted a time, the same time asshippingOptions.schedule:curl -s -X POST "$FASTRAC_API/b2b/orders" \ -H "Authorization: Bearer $FASTRAC_TOKEN" \ -H "Content-Type: application/json" \ -d '{ "shipments": [{ "shippingRateCode": "SR-LM4X8B2Q", "sender": { "name": "Toko Contoh", "email": "[email protected]", "phoneNumber": "081234567890", "coordinate": { "latitude": "-6.2262", "longitude": "106.8530" } }, "receivers": [{ "name": "Sari Wijaya", "phoneNumber": "081311112222", "addressNote": "Lobby tower B, titip satpam", "label": "Kantor", "stopSequence": 1 }], "shippingOptions": { "fulfillmentMethod": "PICKUP", "schedule": "2026-11-21T14:00:00+07:00" } }] }'How the order's schedule is treated depends on the courier:
Courier Pickup time If the order sends a different time LALAMOVE,DASH,BLITZFixed by the quote. The courier books exactly the quoted time, or as soon as possible if you quoted without scheduledAt.Rejected with code PICKUP_SCHEDULE_NOT_QUOTED. Send the same time, or none.GRAB,PAXELTaken from the order's schedule.The order's time is used. PICKUP_SCHEDULE_NOT_QUOTED { "statusCode": 400, "code": "PICKUP_SCHEDULE_NOT_QUOTED", "message": "Jadwal pickup tidak sesuai dengan ongkir yang dipilih. Hitung ulang ongkir dengan jadwal tersebut, atau pesan tanpa jadwal untuk pickup secepatnya.", "quotedScheduledAt": "2026-11-21T14:00:00+07:00", "requestedScheduledAt": "2026-11-21T15:00:00+07:00" }To change the time, quote again with the new
scheduledAtand book with the new rate code.The response has
pickupSchedule:{ "scheduledAt": "2026-11-21T14:00:00+07:00", "asSoonAsPossible": false }, or{ "scheduledAt": null, "asSoonAsPossible": true }for an immediate pickup.Show the driver to your customer
Once a driver accepts the job, Shipping Engine knows their name, phone number and licence plate. Get them in any of these ways:
Source Fields Webhook shipment.pending_pickup(also sent when a driver is assigned)data.driver_name,data.driver_phone,data.driver_license_plate,data.tracking_linkGET /b2b/shipments/track/{code}driver.name,driver.phone,driver.licensePlate,trackingUrlGET /b2b/shipments/{code}/detailsdriverDetails.name,driverDetails.phone,driverDetails.licensePlatecurl -s "$FASTRAC_API/b2b/shipments/track/SHP-261121-K7P3Q2" \ -H "Authorization: Bearer $FASTRAC_TOKEN"InboundResponse (trimmed) { "statusCode": 200, "data": { "currentStatus": "PENDING_PICKUP", "trackingUrl": "https://…", "courier": "Lalamove", "service": "Lalamove Motor", "driver": { "name": "Andi", "phone": "+6281355556666", "licensePlate": "B 1234 XYZ" } } }Driver fields stay
nulluntil the courier assigns someone. ThetrackingUrlof an instant courier often shows the driver on a live map, so it is the best thing to show your customer.Handle a failed pickup
Sometimes no driver takes the job, or the courier gives up on it.
Courier What you see What to do LALAMOVEStatus PROBLEM_SHIPMENT, webhookshipment.pickup_failed.Cancel the shipment to get the refund, then quote and book again. DASHStatus CANCELLED(failed pickup). The price is refunded to your balance.Quote and book again. BLITZStatus stays PENDING_PICKUPwhile Blitz retries the pickup.Wait. A final failure moves it to PROBLEM_SHIPMENT.Others Status PROBLEM_SHIPMENT, webhookshipment.problem_detected.Check the shipment. Cancel and rebook if it doesn't recover, or contact support.
Timing at a glance
| Moment | Rule |
|---|---|
| Quote → order | Book before validUntil. Lalamove also checks its own quote when you pay: an expired Lalamove quote fails with Payment failed, but order … was created successfully. Reason: Tarif LALAMOVE untuk pesanan ini sudah kedaluwarsa…. Quote again. |
| Scheduled pickup | At least 15 minutes ahead, Jakarta time. A scheduled quote that is now less than 15 minutes away is rejected with PICKUP_SCHEDULE_EXPIRED: quote again. |
| As soon as possible | Leave out scheduledAt and schedule. The courier starts looking for a driver as soon as the order is created. |
Checklist
- Send coordinates for the pickup point and every drop-off.
- Pick a vehicle the parcel fits, using
GET /public/vehicles. - For Lalamove, Dash and Blitz, send the quoted
scheduledAtasschedule, or none. - Book right after quoting; instant quotes are short-lived.
- Show
trackingUrland driver details onceshipment.pending_pickuparrives. - Watch for
shipment.pickup_failedandPROBLEM_SHIPMENT, and rebook.
Was this page helpful?