Safaribid Docs

Create Delivery Request

Complete guide to initiating a delivery request on the Safaribid platform.

Create Delivery Request

The /deliveries endpoint is the core of the Safaribid Logistics API. It allows you to request a rider for immediate or scheduled fulfillment.

Endpoint

POST /v1/deliveries

The Delivery Workflow

  1. Request: Your application sends a delivery request.
  2. Matching: Safaribid's engine identifies and notifies the nearest qualified riders.
  3. Acceptance: A rider accepts the request.
  4. Pickup: The rider arrives at the pickup location.
  5. Transit: The rider delivers the package to the destination.
  6. Completion: Delivery is confirmed via OTP or signature.

Request Body

ParameterTypeRequiredDescription
pickupObjectYesPickup location and contact details.
dropoffObjectYesDestination and customer details.
packageObjectYesDetails about the items being delivered.
payment_methodStringYeswallet, m-pesa, or cash.
instructionsStringNoSpecial handling instructions.

Pickup Object

{
  "name": "Safaribid Business Store",
  "phone": "+254700000000",
  "address": "Westlands, Nairobi",
  "lat": -1.2633,
  "lng": 36.8000
}

Dropoff Object

{
  "name": "John Doe",
  "phone": "+254711111111",
  "address": "Kilimani, Nairobi",
  "lat": -1.2833,
  "lng": 36.8167
}

Request Example

{
  "pickup": {
    "name": "The Hub Karen",
    "phone": "+254700123456",
    "address": "Dagoretti Rd, Nairobi"
  },
  "dropoff": {
    "name": "Jane Smith",
    "phone": "+254722123456",
    "address": "State House Rd, Nairobi"
  },
  "package": {
    "type": "electronics",
    "weight": 2.5,
    "description": "Fragile: Laptop"
  },
  "payment_method": "wallet"
}

Response Example

{
  "id": "del_8x2j9k1",
  "status": "searching",
  "eta": "15 mins",
  "tracking_url": "https://track.safaribid.com/del_8x2j9k1",
  "created_at": "2026-05-14T10:00:00Z"
}

Implementation

const delivery = await client.deliveries.create({
  pickup: {
    name: 'The Hub Karen',
    address: 'Dagoretti Rd, Nairobi'
  },
  dropoff: {
    name: 'Jane Smith',
    address: 'State House Rd, Nairobi'
  },
  package: {
    type: 'electronics',
    weight: 2.5
  },
  payment_method: 'wallet'
});
$delivery = $client->deliveries->create([
    'pickup' => ['name' => 'The Hub', 'address' => 'Karen'],
    'dropoff' => ['name' => 'Jane', 'address' => 'State House'],
    'package' => ['type' => 'electronics', 'weight' => 2.5],
    'payment_method' => 'wallet'
]);
delivery = client.deliveries.create(
    pickup={'name': 'The Hub', 'address': 'Karen'},
    dropoff={'name': 'Jane', 'address': 'State House'},
    package={'type': 'electronics', 'weight': 2.5},
    payment_method='wallet'
)

Scheduling Deliveries

You can schedule a delivery for later by providing a scheduled_at timestamp (ISO 8601).

{
  "scheduled_at": "2026-05-15T09:00:00Z",
  "pickup": { ... },
  "dropoff": { ... }
}

On this page