v1

latestOpenAPI 3.1.02026-07-2617501.1 MB

List all the company dispatch records (v2)

get/v2/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 to display per page.

page_nointeger

Denotes the current page number.

Response

200

OR

Example response

{
  "dispatches": [
    {
      "dispatch": {
        "id": 2642,
        "consignee_dispatch_location_id": 8412,
        "shipper_dispatch_location_id": 8411,
        "consignee_form_ids": [
          "1c7b6a72-2924-4aab-a047-8da48e174aeb"
        ],
        "consignee_status": "available",
        "consignee_type": "dropoff",
        "shipper_form_ids": [
          "1306ac21-94de-447e-ad80-d21cc3e5d1f9"
        ],
        "shipper_status": "available",
        "shipper_type": "pickup",
        "status": "planned",
        "status_updated_at": "2021-11-04T01:40:42Z",
        "shipper_dispatch_trip_id": 1341,
        "consignee_dispatch_trip_id": 1341,
        "vendor_id": "VD-1",
        "vendor_shipper_id": "VSS-1",
        "vendor_consignee_id": "VDS-1",
        "dispatch_stops": [
          {
            "dispatch_stop": {
              "id": 1912,
              "dispatch_location_id": 8387,
              "form_ids": [
                "be4cd651-5aca-436b-8cf3-e7881c3d76b8"
              ],
              "number": 1,
              "status": "available",
              "type": "delivery",
              "dispatch_trip_id": 1341,
              "vendor_id": "VBS-2",
              "vendor_dispatch_location_id": "v-3"
            }
          }
        ],
        "dispatch_trips": [
          {
            "dispatch_trip": {
              "id": 1341,
              "status": "not_started",
              "vendor_id": "VT-2",
              "driver_id": 4806,
              "vehicle_id": 2597
            }
          }
        ],
        "vendor_shipper_dispatch_location_id": "ead677",
        "vendor_consignee_dispatch_location_id": "b03a87"
      }
    }
  ],
  "pagination": {
    "per_page": 25,
    "page_no": 1,
    "total": 1
  }
}