🚚
truQ Services
  • Getting Started
  • Environment
  • Status Codes
  • Booking Management
    • Trip Booking
      • Getting a Quote
      • Booking an open trip
      • Booking a standard trip
      • Booking a merchant trip
    • Payment and Order Confirmation
      • Standard trip order confirmation
      • Business trip order confirmation
  • Parameter Guide
    • Trip Types
    • Vehicle Categories
    • Source and Destination
Powered by GitBook
On this page
  1. Parameter Guide

Source and Destination

Generally, when you request our API to book a trip, we expect you to send two required fields, the source and destination object. However, getting the source and destination object requires the latitude, longitude and state of a precise location. Our API fetches latitude and longitude from Google Maps API services, using Place Autocomplete API to find the latitude and longitude of a location. Since the API requires this information, you can fetch the data yourself from any third-party service.

Source and Destination
{
    "source": {
        "address": "Ikoyi",
        "latitude":  6.4500,
        "longitude": 3.4333,
        "state": "Lagos"
    },
    "destination": {
        "address": "Ikoyi",
        "latitude":  6.4500,
        "longitude": 3.4333,
        "state": "Lagos",
        "stops": {
            "number": 0,
            "stopovers": []
        }
    },
    ...
}

Last updated 1 year ago