v1

latestOpenAPI 3.1.02026-07-2617501.1 MB

List company dispatch records (v3)

get/v3/dispatches

Query parameters

ids[]integer[]

Specify the ID of the dispatches that you want to view.

vendor_idsstring[]

Specify one or more vendor IDs for filter the search.

driver_ids[]integer[]

Specify the driver ID for fetching the dispatch record for the particular driver.

vehicle_ids[]integer[]

Specify the ID of the vehicle for which you want to fetch the dispatch records.

statusesstring[]

Specify the status of the dispatch to fetch the records of that particular value. Allowed values are "planned", "active", "completed", "cancelled"

include_nativeboolean

Use this parameter to include the dispatches created on the Motive dashboard. Allowed values are <b>true</b>: Include all the dispatches created on the Motive Dashboard. <b>false</b>: Do not include the dispatches created on the Motive Dashboard.

min_updated_atstring date

Fetch the dispatch records that were updated after the specified date.

max_updated_atstring date

Fetch the dispatch records that were updated before the specified time.

per_pageinteger

Denotes the number of records shown per page.

page_nointeger

Denotes the current page number.

Response

200

OR

Example response

{
  "dispatches": [
    {
      "dispatch": {
        "id": 16534,
        "status": "planned",
        "status_updated_at": "2023-03-24T10:51:36Z",
        "auto_complete_forms": true,
        "vendor_id": "VV-1",
        "dispatch_stops": [
          {
            "dispatch_stop": {
              "id": 27601,
              "dispatch_location_id": 8197,
              "early_date": "2023-03-13T19:13:00+00:00",
              "form_ids": [
                "1ee148ac-6083-4b5a-af7b-75b875bb233f"
              ],
              "late_date": "2023-03-15T19:13:00+00:00",
              "number": 1,
              "status": "available",
              "type": "pickup",
              "dispatch_trip_id": 10236,
              "vendor_id": "VDS-1",
              "vendor_dispatch_location_id": "VDSL-1"
            }
          }
        ],
        "dispatch_trips": [
          {
            "dispatch_trip": {
              "id": 10236,
              "status": "not_started",
              "vendor_id": "VT-1",
              "driver_id": 1088505,
              "vehicle_id": 64734
            }
          }
        ]
      }
    }
  ],
  "pagination": {
    "per_page": 25,
    "page_no": 1,
    "total": 1
  }
}