Call the following endpoint in order to get the order details.

The order details include:

1: Pickup and Dropoff details including description

2: Driver details including name, phone number, avatar and vehicle information

3: Order price and payment details

4: Order statuses

5: Share URL. A tool which you can use to share a link with your clients to view the live driver status.


HTTP Request

https://api.pass.qa/business/v1/orders/{ORDER_ID}

Sample Request

<?php

$curl = curl_init();

curl_setopt_array($curl, [
  CURLOPT_URL            => "https://api.pass.qa/business/v1/orders/{ORDER_ID}",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING       => "",
  CURLOPT_MAXREDIRS      => 10,
  CURLOPT_TIMEOUT        => 30,
  CURLOPT_HTTP_VERSION   => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST  => "GET",
  CURLOPT_HTTPHEADER => [
    "Authorization: Bearer ".$token,//$token is your token created in dashboard.
    "Content-Type: application/json; charset=utf-8",
    "Accept: application/json"
  ],
]);

$response = curl_exec($curl);
$err      = curl_error($curl);

curl_close($curl);

if ($err) {
  echo 'cURL Error #:' . $err;
} else {
  echo $response;
}
var request = require("request");
var token = 'mytokenvalue' //token value to be placed here;
var baseURL = 'https://api.pass.qa/business';

var options = { method: 'GET',
  url: baseURL+'/v1/orders/{ORDER_ID}',
  headers: 
   { Accept: 'application/json',
     Authorization: 'Bearer '+token,
     'Content-Type': 'application/json' },
  json: true };

request(options, function (error, response, body) {
  if (error) throw new Error(error);
  console.log(body);
});
import requests
token = 'your token'
baseUrl ='https://api.pass.qa/business'
headers = {'Authorization': 'Bearer '+token,'Accept':'application/json','Content-Type':'application/json'}
response = requests.get(baseUrl+'/v1/orders/{ORDER_ID}', headers=headers)
print(response.json())

Response Descriptions

AttributeDescription
statusIndicates whether the progress has been successful or not.
driver[name]Driver's name
driver[mobile]Driver's phone number
driver[avatar]Driver's avatar i.e. profile photo
driver[plate]Driver's vehicle plate
pickup[lat]Sender latitude
pickup[long]Sender longitude
pickup[name]Sender name
pickup[phone]Sender phone
pickup[address]Sender address
pickup[description]Sender description
dropoffsAn array of objects that each one is like a pickup object.
The maximum length of the array is 3 and the minimum is 1.
Please see the sample response at the end of this page.
priceOrder's price
in_progressIndicates that the order is in progress or not
dateDate of the order creation
payment_type"wallet" or "cash on delivery"
order_statusThere are 7 steps in each order that is explained in the table below
share_urlLink of the order information and tracking to sharing with others
Order Status ResponsesDescription
searchingSearching for drivers
acceptDriver has accepted the order and is on the way to the pickup
arriveThe driver has arrived to the pickup location and is waiting to pickup the package
pickupThe driver has picked up the package and is driving towards the dropoff.
dropoffThe driver has reached the drop off point. Kindly note that this step can be responded as 'dropoff1. dropoff2. dropoff3' if the order is a multiple drop off order. View example in the sample code.
completeThe order has been completed.
cancelThe order has been cancelled. This can be because of a cancellation from the driver, from the customer, from a pass agent or even as a result of an order expiry.
{
    "status": "success",
    "message": "success",
    "data": {
        "id": 13198,
        "driver": {
            "name": "Muhammad Saeed",
            "mobile": "+97470155549",
            "avatar": "https://pass-space.fra1.cdn.digitaloceanspaces.com/drivers/YORaFadtNJakaP1zlGJ6jljNYl7xPnAx7FVtmO0c.jpg",
            "plate": "408612"
        },
        "pickup": {
            "lat": "25.275047",
            "lng": "51.535141",
            "name": "Greg Beahan",
            "phone": "+97466661234",
            "address": "505 Laura Drives",
            "description": "it is a sample description"
        },
        "dropoffs": [
            {
                "lat": "25.277007",
                "lng": "51.530034",
                "name": "Sharon Dicki",
                "phone": "+97466661234",
                "address": "18383 Frank River",
                "description": "Global"
            },
            {
                "lat": "25.277007",
                "lng": "51.530034",
                "name": "Jana Hane",
                "phone": "+97466661234",
                "address": "227 Parker Ford",
                "description": "Forward"
            },
            {
                "lat": "25.277007",
                "lng": "51.530034",
                "name": "Lynn Macejkovic",
                "phone": "+97466661234",
                "address": "1389 Mittie Islands",
                "description": "Principal"
            }
        ],
        "price": 11.04,
        "in_progress": true,
        "date": "14/02/2023 15:42:12",
        "payment_type": "wallet",
        "status": "accept",
        "share_url": "https://api.pass.qa/safe-url/MTMxOTg="
    }
}