CHAUFFEUR API SERVICE

Third-Party Integration API

Comprehensive API documentation for integrating with the Saafir Chauffeur service. Manage bookings, authentication, and location services with ease.

🔐

Auth

JWT-based authentication with client credentials

📋

Booking

Create, list, retrieve, and cancel bookings

📍

Location

Query countries and cities for service areas

Authentication

The API uses Bearer JWT tokens for authentication. First, obtain tokens via the Login endpoint using your clientId and clientSecret. Then include the access token in the Authorization header of all subsequent requests.

Authorization Header
Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...
💡 Token Refresh: When your access token expires, use the Refresh Token endpoint to get a new pair of tokens without re-authenticating.

Base URL (Dev)

Base URL (Dev)
https://api.tp-chauffeur.b2b.dev-saafir.jatritech.com
Auth Endpoints
POST /chauffeur-api/v1/auth/login

Login with Client Credentials

Authenticate using your client credentials to receive access and refresh tokens.

Request Body

Field Type Required Description
clientId string Yes Your client ID
clientSecret string Yes Your client secret
JSON
{
  "clientId": "client-id-here",
  "clientSecret": "client-secret-here"
}
200 — Authenticated successfully
{
  "success": true,
  "statusCode": 200,
  "message": "Authenticated successfully",
  "data": {
    "accessToken": "eyJhbGciOiJIUzI1NiIs...",
    "refreshToken": "eyJhbGciOiJIUzI1NiIs..."
  }
}
401 — Invalid token
{
  "success": false,
  "code": 401,
  "message": "Invalid token!",
  "errors": [],
  "data": {},
  "path": "/auth/login",
  "timestamp": "2026-03-11T05:07:29.582Z"
}
403 — You are not logged in
{
  "success": false,
  "code": 403,
  "message": "You are not logged in!",
  "errors": [],
  "data": {},
  "path": "/auth/login",
  "timestamp": "2026-03-11T05:07:29.582Z"
}
POST /chauffeur-api/v1/auth/refresh

Refresh Access Token

Use a valid refresh token to obtain a new pair of access and refresh tokens.

Request Body

Field Type Required Description
refreshToken string Yes A valid refresh token
JSON
{
  "refreshToken": "refresh-token-here"
}
200 — Token refreshed successfully
{
  "success": true,
  "statusCode": 200,
  "message": "Token refreshed successfully",
  "data": {
    "accessToken": "eyJhbGciOiJIUzI1NiIs...",
    "refreshToken": "eyJhbGciOiJIUzI1NiIs..."
  }
}
401 — Invalid token
{
  "success": false,
  "code": 401,
  "message": "Invalid token!",
  "errors": [],
  "data": {},
  "path": "/auth/refresh",
  "timestamp": "2026-03-11T05:07:29.583Z"
}
403 — You are not logged in
{
  "success": false,
  "code": 403,
  "message": "You are not logged in!",
  "errors": [],
  "data": {},
  "path": "/auth/refresh",
  "timestamp": "2026-03-11T05:07:29.583Z"
}
Booking Endpoints
POST /chauffeur-api/v1/booking 🔒 Bearer Token

Create a New Booking

Create a booking for one of the supported service types. The request body varies by bookingType.

Select Booking Type

Choose a booking type to see both the request body and 201 response specific to that type.

Request Body
{
  "bookingType": "AIRPORT_TRANSPORT",
  "country": "6950bdd10cc3bba0ff2b6dbd",
  "city": "6950bdeedb2b4e5447e9ea6c",
  "timeZone": "Asia/Dhaka",
  "fromDateTime": "2025-03-06T10:00:00.000Z",
  "fromLocalDate": "2025-03-06",
  "fromLocation": "Hajrat Shah Jalal International Airport, Terminal 3",
  "viaLocation": ["Business Bay", "Downtown Dubai"],
  "toLocation": "Burj Al Arab Hotel, Dubai",
  "airlineName": "Emirates",
  "flightNumber": "EK215",
  "terminalNumber": "Terminal 3",
  "specialInstruction": "Please arrive 15 minutes early",
  "vehicleType": "PREMIUM_SEDAN",
  "totalPassenger": 3,
  "totalLuggage": 4,
  "passengers": [
    {
      "name": "John Doe",
      "dialCode": "+880",
      "number": "15487878877",
      "countryId": "6950bdd10cc3bba0ff2b6dbd"
    }
  ]
}
201 — Response
{
  "success": true,
  "statusCode": 201,
  "message": "New booking has been created successfully.",
  "data": {
    "_id": "69ab06f85925b5856483910b",
    "uId": "BC-2603125",
    "bookingType": "AIRPORT_TRANSPORT",
    "country": { "_id": "6950bdd10cc3bba0ff2b6dbd", "name": "Bangladesh" },
    "city": { "_id": "6950bdeedb2b4e5447e9ea6c", "name": "Dhaka" },
    "timeZone": "Asia/Dhaka",
    "specialInstruction": "Please arrive 15 minutes early",
    "fromDateTime": "2025-03-06T10:00:00.000Z",
    "fromLocation": "Hajrat Shah Jalal International Airport, Terminal 3",
    "viaLocation": ["Business Bay", "Downtown Dubai"],
    "toLocation": "Burj Al Arab Hotel, Dubai",
    "totalPassenger": 3,
    "vehicleType": "PREMIUM_SEDAN",
    "totalLuggage": 4,
    "passengers": [
      { "name": "John Doe", "dialCode": "+880", "number": "15487878877", "isLead": false, "countryId": "6950bdd10cc3bba0ff2b6dbd" }
    ],
    "airlineName": "Emirates",
    "terminalNumber": "Terminal 3",
    "flightNumber": "EK215",
    "vehicleName": null,
    "modelYear": null,
    "registrationNumber": null,
    "driverName": null,
    "driverNumber": null,
    "invoiceUrl": null
  }
}
Request Body
{
  "bookingType": "FULL_DAY_CHAUFFEUR",
  "country": "6950bdd10cc3bba0ff2b6dbd",
  "city": "6950bdeedb2b4e5447e9ea6c",
  "timeZone": "Asia/Dubai",
  "fromDateTime": "2025-03-06T10:00:00.000Z",
  "fromLocalDate": "2025-03-06",
  "fromLocation": "Dubai Marina",
  "viaLocation": ["Burj Khalifa", "Palm Jumeirah"],
  "toLocation": "Dubai Mall",
  "specialInstruction": "Client prefers English-speaking driver",
  "vehicleType": "PREMIUM_SEDAN",
  "totalPassenger": 2,
  "totalLuggage": 4,
  "passengers": [
    {
      "name": "John Doe",
      "dialCode": "+880",
      "number": "15487878877",
      "countryId": "6950bdd10cc3bba0ff2b6dbd"
    }
  ]
}
201 — Response
{
  "success": true,
  "statusCode": 201,
  "message": "New booking has been created successfully.",
  "data": {
    "_id": "69ab07a45925b58564839124",
    "uId": "BC-2603127",
    "bookingType": "FULL_DAY_CHAUFFEUR",
    "country": { "_id": "6950bdd10cc3bba0ff2b6dbd", "name": "Bangladesh" },
    "city": { "_id": "6950bdeedb2b4e5447e9ea6c", "name": "Dhaka" },
    "timeZone": "Asia/Dubai",
    "specialInstruction": "Client prefers English-speaking driver",
    "fromDateTime": "2025-03-06T10:00:00.000Z",
    "fromLocation": "Dubai Marina",
    "viaLocation": ["Burj Khalifa", "Palm Jumeirah"],
    "toLocation": "Dubai Mall",
    "totalPassenger": 2,
    "vehicleType": "PREMIUM_SEDAN",
    "totalLuggage": 4,
    "passengers": [
      { "name": "John Doe", "dialCode": "+880", "number": "15487878877", "isLead": false, "countryId": "6950bdd10cc3bba0ff2b6dbd" }
    ],
    "vehicleName": null,
    "modelYear": null,
    "registrationNumber": null,
    "driverName": null,
    "driverNumber": null,
    "invoiceUrl": null
  }
}
Request Body
{
  "bookingType": "HOURLY_RENTAL",
  "country": "6950bdd10cc3bba0ff2b6dbd",
  "city": "6950bdeedb2b4e5447e9ea6c",
  "timeZone": "Asia/Dubai",
  "package": "Premium",
  "fromDateTime": "2025-03-06T10:00:00.000Z",
  "fromLocalDate": "2025-03-06",
  "fromLocation": "Dubai Mall",
  "viaLocation": ["Business Bay"],
  "toLocation": "Dubai Marina",
  "specialInstruction": "Please arrive 15 minutes early",
  "vehicleType": "PREMIUM_SEDAN",
  "totalPassenger": 2,
  "totalLuggage": 4,
  "passengers": [
    {
      "name": "John Doe",
      "dialCode": "+880",
      "number": "15487878877",
      "countryId": "6950bdd10cc3bba0ff2b6dbd"
    }
  ]
}
201 — Response
{
  "success": true,
  "statusCode": 201,
  "message": "New booking has been created successfully.",
  "data": {
    "_id": "69ab07c35925b5856483912e",
    "uId": "BC-2603128",
    "bookingType": "HOURLY_RENTAL",
    "country": { "_id": "6950bdd10cc3bba0ff2b6dbd", "name": "Bangladesh" },
    "city": { "_id": "6950bdeedb2b4e5447e9ea6c", "name": "Dhaka" },
    "timeZone": "Asia/Dubai",
    "specialInstruction": "Please arrive 15 minutes early",
    "fromDateTime": "2025-03-06T10:00:00.000Z",
    "fromLocation": "Dubai Mall",
    "viaLocation": ["Business Bay"],
    "toLocation": "Dubai Marina",
    "totalPassenger": 2,
    "vehicleType": "PREMIUM_SEDAN",
    "totalLuggage": 4,
    "passengers": [
      { "name": "John Doe", "dialCode": "+880", "number": "15487878877", "isLead": false, "countryId": "6950bdd10cc3bba0ff2b6dbd" }
    ],
    "package": null,
    "vehicleName": null,
    "modelYear": null,
    "registrationNumber": null,
    "driverName": null,
    "driverNumber": null,
    "invoiceUrl": null
  }
}
Request Body
{
  "bookingType": "SELF_DRIVEN_RENTAL",
  "country": "6950bdd10cc3bba0ff2b6dbd",
  "city": "6950bdeedb2b4e5447e9ea6c",
  "timeZone": "Asia/Dubai",
  "fromDateTime": "2025-03-06T10:00:00.000Z",
  "fromLocalDate": "2025-03-06",
  "toDateTime": "2024-12-31T18:00:00.000Z",
  "fromLocation": "Rental Office, Dubai",
  "toLocation": "Dubai Airport",
  "specialInstruction": "Please arrive 15 minutes early",
  "vehicleType": "PREMIUM_SEDAN",
  "fullName": "Alice Williams",
  "contactNumber": {
    "name": "John Doe",
    "dialCode": "+880",
    "number": "15487878877",
    "countryId": "6950bdd10cc3bba0ff2b6dbd"
  },
  "email": "alice.w@example.com"
}
201 — Response
{
  "success": true,
  "statusCode": 201,
  "message": "New booking has been created successfully.",
  "data": {
    "_id": "69ab07da5925b58564839138",
    "uId": "BC-2603129",
    "bookingType": "SELF_DRIVEN_RENTAL",
    "country": { "_id": "6950bdd10cc3bba0ff2b6dbd", "name": "Bangladesh" },
    "city": { "_id": "6950bdeedb2b4e5447e9ea6c", "name": "Dhaka" },
    "timeZone": "Asia/Dubai",
    "specialInstruction": "Please arrive 15 minutes early",
    "fromDateTime": "2025-03-06T10:00:00.000Z",
    "fromLocation": "Rental Office, Dubai",
    "viaLocation": null,
    "toLocation": "Dubai Airport",
    "totalPassenger": 0,
    "vehicleType": "PREMIUM_SEDAN",
    "vehicleName": null,
    "toDateTime": "2024-12-31T18:00:00.000Z",
    "rentalCompany": null,
    "rentalReferenceNumber": null,
    "modelYear": null,
    "registrationNumber": null,
    "driverName": null,
    "driverNumber": null,
    "invoiceUrl": null
  }
}
Request Body
{
  "bookingType": "MEET_AND_GREET",
  "country": "6950bdd10cc3bba0ff2b6dbd",
  "city": "6950bdeedb2b4e5447e9ea6c",
  "timeZone": "Asia/Dubai",
  "fromDateTime": "2025-03-06T10:00:00.000Z",
  "fromLocalDate": "2025-03-06",
  "airportName": "Dubai Airport",
  "airlineName": "Qatar Airways",
  "flightNumber": "QR815",
  "terminalNumber": "Terminal 1",
  "specialInstruction": "Hold welcome sign with client name",
  "servicePackage": "PREMIUM",
  "totalPassenger": 2,
  "totalLuggage": 4,
  "passengers": [
    {
      "name": "John Doe",
      "dialCode": "+880",
      "number": "15487878877",
      "countryId": "6950bdd10cc3bba0ff2b6dbd"
    }
  ]
}
201 — Response
{
  "success": true,
  "statusCode": 201,
  "message": "New booking has been created successfully.",
  "data": {
    "_id": "69ab07f35925b58564839142",
    "uId": "BC-2603130",
    "bookingType": "MEET_AND_GREET",
    "country": { "_id": "6950bdd10cc3bba0ff2b6dbd", "name": "Bangladesh" },
    "city": { "_id": "6950bdeedb2b4e5447e9ea6c", "name": "Dhaka" },
    "timeZone": "Asia/Dubai",
    "specialInstruction": "Hold welcome sign with client name",
    "fromDateTime": "2025-03-06T10:00:00.000Z",
    "totalPassenger": 2,
    "totalLuggage": 4,
    "passengers": [
      { "name": "John Doe", "dialCode": "+880", "number": "15487878877", "isLead": false, "countryId": "6950bdd10cc3bba0ff2b6dbd" }
    ],
    "airlineName": "Qatar Airways",
    "terminalNumber": "Terminal 1",
    "flightNumber": "QR815",
    "servicePackage": "PREMIUM",
    "qrCodeImageUrl": null,
    "airportName": "Dubai Airport",
    "invoiceUrl": null
  }
}
Request Body
{
  "bookingType": "VISA_SERVICE",
  "country": "6950bdd10cc3bba0ff2b6dbd",
  "city": "6950bdeedb2b4e5447e9ea6c",
  "timeZone": "Asia/Dubai",
  "visaType": "BUSINESS",
  "entryType": "SINGLE",
  "processingType": "STANDARD",
  "fromDateTime": "2025-03-06T10:00:00.000Z",
  "fromLocalDate": "2025-03-06",
  "lengthOfStay": 30,
  "purposeOfVisit": "Business Meeting",
  "specialInstruction": "Please arrive 15 minutes early",
  "applicantName": "David Lee",
  "applicantNumber": {
    "dialCode": "+880",
    "number": "15487878877",
    "countryId": "6950bdd10cc3bba0ff2b6dbd"
  },
  "applicantEmail": "david.lee@example.com",
  "applicantNationality": "6950bdd10cc3bba0ff2b6dbd",
  "applicantPassport": "A12345678"
}
201 — Response
{
  "success": true,
  "statusCode": 201,
  "message": "New booking has been created successfully.",
  "data": {
    "_id": "69ab0bff92c8a45c0dfa7744",
    "uId": "BC-2603131",
    "bookingType": "VISA_SERVICE",
    "country": { "_id": "6950bdd10cc3bba0ff2b6dbd", "name": "Bangladesh" },
    "city": { "_id": "6950bdeedb2b4e5447e9ea6c", "name": "Dhaka" },
    "timeZone": "Asia/Dubai",
    "specialInstruction": "Please arrive 15 minutes early",
    "fromDateTime": "2025-03-06T10:00:00.000Z",
    "applicantName": "David Lee",
    "applicantNumber": {
      "dialCode": "+880",
      "number": "15487878877",
      "countryId": "6950bdd10cc3bba0ff2b6dbd"
    },
    "applicantEmail": "david.lee@example.com",
    "applicantNationality": { "_id": "6950bdd10cc3bba0ff2b6dbd", "name": "Bangladesh" },
    "applicantPassport": "A12345678",
    "lengthOfStay": 30,
    "visaType": "BUSINESS",
    "entryType": "SINGLE",
    "processingType": "STANDARD",
    "purposeOfVisit": "Business Meeting",
    "invoiceUrl": null
  }
}
Request Body
{
  "bookingType": "CITY_DROP_SERVICE",
  "country": "6950bdd10cc3bba0ff2b6dbd",
  "city": "6950bdeedb2b4e5447e9ea6c",
  "timeZone": "Asia/Dubai",
  "fromDateTime": "2025-03-06T10:00:00.000Z",
  "fromLocalDate": "2025-03-06",
  "fromLocation": "Dubai Marina",
  "viaLocation": ["Business Bay"],
  "toLocation": "Downtown Dubai",
  "specialInstruction": "Please arrive 15 minutes early",
  "vehicleType": "PREMIUM_SEDAN",
  "totalPassenger": 2,
  "totalLuggage": 4,
  "passengers": [
    {
      "name": "John Doe",
      "dialCode": "+880",
      "number": "15487878877",
      "countryId": "6950bdd10cc3bba0ff2b6dbd"
    }
  ]
}
201 — Response
{
  "success": true,
  "statusCode": 201,
  "message": "New booking has been created successfully.",
  "data": {
    "_id": "69ab0c5092c8a45c0dfa7758",
    "uId": "BC-2603133",
    "bookingType": "CITY_DROP_SERVICE",
    "country": { "_id": "6950bdd10cc3bba0ff2b6dbd", "name": "Bangladesh" },
    "city": { "_id": "6950bdeedb2b4e5447e9ea6c", "name": "Dhaka" },
    "timeZone": "Asia/Dubai",
    "specialInstruction": "Please arrive 15 minutes early",
    "fromDateTime": "2025-03-06T10:00:00.000Z",
    "fromLocation": "Dubai Marina",
    "viaLocation": ["Business Bay"],
    "toLocation": "Downtown Dubai",
    "totalPassenger": 2,
    "vehicleType": "PREMIUM_SEDAN",
    "totalLuggage": 4,
    "passengers": [
      { "name": "John Doe", "dialCode": "+880", "number": "15487878877", "isLead": false, "countryId": "6950bdd10cc3bba0ff2b6dbd" }
    ],
    "vehicleName": null,
    "modelYear": null,
    "registrationNumber": null,
    "driverName": null,
    "driverNumber": null,
    "invoiceUrl": null
  }
}
Request Body
{
  "bookingType": "OTHER_SERVICE",
  "country": "6950bdd10cc3bba0ff2b6dbd",
  "city": "6950bdeedb2b4e5447e9ea6c",
  "timeZone": "Asia/Dubai",
  "fromDateTime": "2025-03-06T10:00:00.000Z",
  "fromLocalDate": "2025-03-06",
  "serviceDetails": "Custom service details and requirements",
  "specialInstruction": "Hold welcome sign with client name"
}
201 — Response
{
  "success": true,
  "statusCode": 201,
  "message": "New booking has been created successfully.",
  "data": {
    "_id": "69ab0c2192c8a45c0dfa774e",
    "uId": "BC-2603132",
    "bookingType": "OTHER_SERVICE",
    "country": { "_id": "6950bdd10cc3bba0ff2b6dbd", "name": "Bangladesh" },
    "city": { "_id": "6950bdeedb2b4e5447e9ea6c", "name": "Dhaka" },
    "timeZone": "Asia/Dubai",
    "specialInstruction": "Hold welcome sign with client name",
    "fromDateTime": "2025-03-06T10:00:00.000Z",
    "serviceDetails": "Custom service details and requirements",
    "invoiceUrl": null
  }
}
401 — Invalid token
{
  "success": false,
  "code": 401,
  "message": "Invalid token!",
  "errors": [],
  "data": {},
  "path": "/booking",
  "timestamp": "2026-03-11T05:07:29.510Z"
}
403 — You are not logged in
{
  "success": false,
  "code": 403,
  "message": "You are not logged in!",
  "errors": [],
  "data": {},
  "path": "/booking",
  "timestamp": "2026-03-11T05:07:29.510Z"
}
GET /chauffeur-api/v1/booking 🔒 Bearer Token

Get All Bookings

Retrieve all bookings for the authenticated agency. Supports pagination and filtering.

Query Parameters

Parameter Type Required Description
page number No Page number (default: 1)
limit number No Records per page (default: 10)
dateType string No Date field to filter on: ISO, LOCAL, BOOKING_DATE
bookingType string No Filter by service type. Possible values:
AIRPORT_TRANSPORT | FULL_DAY_CHAUFFEUR | HOURLY_RENTAL | SELF_DRIVEN_RENTAL | MEET_AND_GREET | VISA_SERVICE | OTHER_SERVICE | CITY_DROP_SERV
bookingId string No Filter by unique booking ID (uId)
country string No Filter by Country ID
city string No Filter by City ID
supplier string No Filter by Supplier ID (ObjectId)
assignedSupport string No Filter by Assigned Support User ID (ObjectId)
status string No PENDING | CONFIRMED | COMPLETED | CANCELLED | REJECTED
fromDate string No Start date (ISO 8601)
toDate string No End date (ISO 8601)
leadPassengerName string No Filter by passenger name (partial)
leadPassengerPhone string No Filter by passenger phone (suffix)
pickupLocation string No Filter by pickup location
dropoffLocation string No Filter by drop-off location
driverName string No Filter by driver name (partial)
driverPhone string No Filter by driver phone (suffix)
200 — List of bookings with pagination
{
  "success": true,
  "statusCode": 200,
  "message": "Success",
  "data": {
    "data": [ { "...booking object..." } ],
    "pagination": {
      "page": 1, "limit": 10, "total": 1, "totalPages": 1,
      "hasNext": false, "hasPrev": false,
      "nextPage": null, "prevPage": null
    }
  }
}
401 — Invalid token
{
  "success": false,
  "code": 401,
  "message": "Invalid token!",
  "errors": [],
  "data": {},
  "path": "/booking",
  "timestamp": "2026-03-11T05:46:54.860Z"
}
403 — You are not logged in
{
  "success": false,
  "code": 403,
  "message": "You are not logged in!",
  "errors": [],
  "data": {},
  "path": "/booking",
  "timestamp": "2026-03-11T05:46:54.861Z"
}
GET /chauffeur-api/v1/booking/{id} 🔒 Bearer Token

Get Booking by ID

Retrieve a single booking by its ObjectId.

Path Parameters

Parameter Type Required Description
id string Yes Booking ObjectId
200 — Booking details
{
  "success": true,
  "statusCode": 200,
  "message": "Success",
  "data": {
    "_id": "507f1f77bcf86cd799439020",
    "uId": "BK-ABC12345",
    "bookingType": "AIRPORT_TRANSPORT",
    "country": {
      "_id": "507f1f77bcf86cd799439011",
      "name": "United Arab Emirates"
    },
    "city": {
      "_id": "507f1f77bcf86cd799439012",
      "name": "Dubai"
    },
    "timeZone": "Asia/Dubai",
    "status": "CONFIRMED",
    "fromDateTime": "2024-12-25T10:00:00.000Z",
    "fromLocalDate": "2024-12-25",
    "fromLocation": "Dubai International Airport, Terminal 3",
    "viaLocation": [
      "Business Bay"
    ],
    "toLocation": "Burj Al Arab Hotel, Dubai",
    "specialInstruction": "Please arrive 15 minutes early",
    "totalPassenger": 2,
    "vehicleType": "PREMIUM_SEDAN",
    "totalLuggage": 4,
    "airlineName": "Emirates",
    "terminalNumber": "Terminal 3",
    "flightNumber": "EK215",
    "passengers": [
      {
        "name": "John Doe",
        "dialCode": "+1",
        "number": "5551234567",
        "countryId": "67654e993a49a516ffc18b21"
      }
    ],
    "netSellingPrice": 571.43,
    "vatRateApplied": 5,
    "baseSellingPrice": 500,
    "invoiceUrl": "https://s3.url/invoice.pdf",
    "createdAt": "2024-12-24T07:00:00.000Z",
    "updatedAt": "2024-12-24T07:00:00.000Z"
  }
}
401 — Invalid token
{
  "success": false,
  "code": 401,
  "message": "Invalid token!",
  "errors": [],
  "data": {},
  "path": "/booking/:id",
  "timestamp": "2026-03-11T05:46:54.862Z"
}
403 — You are not logged in
{
  "success": false,
  "code": 403,
  "message": "You are not logged in!",
  "errors": [],
  "data": {},
  "path": "/booking/:id",
  "timestamp": "2026-03-11T05:46:54.862Z"
}
404 — Booking not found
{
  "success": false,
  "statusCode": 404,
  "message": "Booking not found",
  "data": {}
}
POST /chauffeur-api/v1/booking/{id}/cancel 🔒 Bearer Token

Cancel a Booking

Cancel an existing booking by its ObjectId.

Path Parameters

Parameter Type Required Description
id string Yes Booking ObjectId

Request Body

Field Type Required Description
note string No Reason for cancellation
JSON
{
  "note": "Customer requested cancellation due to change of plans"
}
200 — Booking cancelled
{
  "success": true,
  "statusCode": 200,
  "message": "Booking cancelled successfully",
  "data": {}
}
400 — Invalid status
{
  "success": false,
  "statusCode": 400,
  "message": "Booking is already cancelled",
  "data": {}
}
401 — Invalid token
{
  "success": false,
  "code": 401,
  "message": "Invalid token!",
  "errors": [],
  "data": {},
  "path": "/booking/:id/cancel",
  "timestamp": "2026-03-11T05:46:54.865Z"
}
403 — You are not logged in
{
  "success": false,
  "code": 403,
  "message": "You are not logged in!",
  "errors": [],
  "data": {},
  "path": "/booking/:id/cancel",
  "timestamp": "2026-03-11T05:46:54.865Z"
}
404 — Booking not found
{
  "success": false,
  "statusCode": 404,
  "message": "Booking not found",
  "data": {}
}
Location Endpoints
GET /chauffeur-api/v1/location/country 🔒 Bearer Token

Get All Countries

Retrieve all available countries with their details including currency, phone code, and timezones.

200 — Countries list
{
  "success": true,
  "statusCode": 200,
  "message": "Fetched all countries successfully",
  "data": [
    {
      "_id": "6926bd932b1ecd3f3f2eadbe",
      "iso3": "AFG",
      "currency": "AFN",
      "currencyName": "Afghan afghani",
      "currencySymbol": "؋",
      "flagEmoji": "🇦🇫",
      "iso2": "AF",
      "name": "Afghanistan",
      "phoneCode": "93",
      "timezones": [
        {
          "zoneName": "Asia/Kabul",
          "gmtOffset": 16200,
          "gmtOffsetName": "UTC+04:30",
          "abbreviation": "AFT",
          "tzName": "Afghanistan Time"
        }
      ]
    },
    {
      "_id": "6926bd932b1ecd3f3f2eada0",
      "iso3": "ALA",
      "currency": "EUR",
      "currencyName": "Euro",
      "currencySymbol": "€",
      "flagEmoji": "🇦�",
      "iso2": "AX",
      "name": "Aland Islands",
      "phoneCode": "358",
      "timezones": [
        {
          "zoneName": "Europe/Mariehamn",
          "gmtOffset": 7200,
          "gmtOffsetName": "UTC+02:00",
          "abbreviation": "EET",
          "tzName": "Eastern European Time"
        }
      ]
    }
  ]
}
401 — Invalid token
{
  "success": false,
  "code": 401,
  "message": "Invalid token!",
  "errors": [],
  "data": {},
  "path": "/location/country",
  "timestamp": "2026-03-11T05:46:54.869Z"
}
403 — You are not logged in
{
  "success": false,
  "code": 403,
  "message": "You are not logged in!",
  "errors": [],
  "data": {},
  "path": "/location/country",
  "timestamp": "2026-03-11T05:46:54.869Z"
}
GET /chauffeur-api/v1/location/country/{id} 🔒 Bearer Token

Get Country by ID

Retrieve a single country's details by its ObjectId.

Path Parameters

Parameter Type Required Description
id string Yes Country ObjectId
200 — Country details
{
  "success": true,
  "statusCode": 200,
  "message": "Fetched country details successfully",
  "data": {
    "_id": "6926bd932b1ecd3f3f2eae3b",
    "iso3": "EGY",
    "currency": "EGP",
    "currencyName": "Egyptian pound",
    "currencySymbol": "ج.م",
    "flagEmoji": "🇪🇬",
    "iso2": "EG",
    "name": "Egypt",
    "phoneCode": "20",
    "timezones": [
      {
        "zoneName": "Africa/Cairo",
        "gmtOffset": 7200,
        "gmtOffsetName": "UTC+02:00",
        "abbreviation": "EET",
        "tzName": "Eastern European Time"
      }
    ]
  }
}
400 — Invalid Country ID
{
  "statusCode": 400,
  "message": "Invalid Country ID",
  "error": "Bad Request"
}
401 — Invalid token
{
  "success": false,
  "code": 401,
  "message": "Invalid token!",
  "errors": [],
  "data": {},
  "path": "/location/country/:id",
  "timestamp": "2026-03-11T05:46:54.870Z"
}
403 — You are not logged in
{
  "success": false,
  "code": 403,
  "message": "You are not logged in!",
  "errors": [],
  "data": {},
  "path": "/location/country/:id",
  "timestamp": "2026-03-11T05:46:54.870Z"
}
404 — Country not found
{
  "success": false,
  "code": 404,
  "message": "Country not found",
  "errors": [],
  "data": {},
  "path": "/location/country/6926bd932b1ecd3f3f2eaf3b",
  "timestamp": "2025-12-07T12:06:48.484Z"
}
GET /chauffeur-api/v1/location/country/city/{countryId} 🔒 Bearer Token

Get All Cities by Country

Retrieve all cities belonging to a specific country.

Path Parameters

Parameter Type Required Description
countryId string Yes Country ObjectId
200 — Cities list
{
  "success": true,
  "statusCode": 200,
  "message": "Fetched all cities successfully",
  "data": [
    { "_id": "6927e2bcbfddbc8b6803aee8", "name": "Baillif" },
    { "_id": "6927e2bcbfddbc8b6803aeea", "name": "Bouillante" }
  ]
}
400 — Invalid Country ID
{
  "statusCode": 400,
  "message": "Invalid Country ID",
  "error": "Bad Request"
}
401 — Invalid token
{
  "success": false,
  "code": 401,
  "message": "Invalid token!",
  "errors": [],
  "data": {},
  "path": "/location/country/city/:countryId",
  "timestamp": "2026-03-11T05:46:54.870Z"
}
403 — You are not logged in
{
  "success": false,
  "code": 403,
  "message": "You are not logged in!",
  "errors": [],
  "data": {},
  "path": "/location/country/city/:countryId",
  "timestamp": "2026-03-11T05:46:54.870Z"
}
404 — Country not found
{
  "success": false,
  "code": 404,
  "message": "Country not found",
  "errors": [],
  "data": {},
  "path": "/location/country/6926bd932b1ecd3f3f2eaf3b",
  "timestamp": "2025-12-07T12:06:48.484Z"
}
GET /chauffeur-api/v1/location/city/{id} 🔒 Bearer Token

Get City by ID

Retrieve a single city's details by its ObjectId, including the parent country information.

Path Parameters

Parameter Type Required Description
id string Yes City ObjectId
200 — City details
{
  "success": true,
  "statusCode": 200,
  "message": "Fetched city details successfully",
  "data": {
    "_id": "6927e2babfddbc8b68032502",
    "name": "Dhaka",
    "country": {
      "_id": "6926bd932b1ecd3f3f2eacc7",
      "iso3": "BGD",
      "currency": "BDT",
      "currencyName": "Bangladeshi taka",
      "currencySymbol": "৳",
      "flagEmoji": "🇧🇩",
      "iso2": "BD",
      "name": "Bangladesh",
      "phoneCode": "880",
      "timezones": [
        {
          "zoneName": "Asia/Dhaka",
          "gmtOffset": 21600,
          "gmtOffsetName": "UTC+06:00",
          "abbreviation": "BDT",
          "tzName": "Bangladesh Standard Time"
        }
      ]
    }
  }
}
400 — Invalid City ID
{
  "success": false,
  "code": 404,
  "message": "Invalid City ID",
  "error": "Bad Request"
}
401 — Invalid token
{
  "success": false,
  "code": 401,
  "message": "Invalid token!",
  "errors": [],
  "data": {},
  "path": "/location/city/:id",
  "timestamp": "2026-03-11T05:46:54.871Z"
}
403 — You are not logged in
{
  "success": false,
  "code": 403,
  "message": "You are not logged in!",
  "errors": [],
  "data": {},
  "path": "/location/city/:id",
  "timestamp": "2026-03-11T05:46:54.872Z"
}
404 — City not found
{
  "success": false,
  "code": 404,
  "message": "City not found",
  "errors": [],
  "data": {},
  "path": "/location/city/6927e2aabfddbc8b68032502",
  "timestamp": "2025-12-07T12:07:41.945Z"
}