moovexDocs

Get trip by id

Returns trip details including stops, passengers, and route options.

GET/trips/single/{id}

Path Parameters

ParameterTypeDescription
idstringTrip numeric id

Example Response

{
  "id": 10,
  "date": 1700000000,
  "distance": 12500,
  "endTripETA": 1700003600,
  "inCar": 2,
  "stopsCompleted": 1,
  "stops": [
    {
      "id": "stop-1",
      "date": 1700000000,
      "shouldWait": 0,
      "stopType": "default",
      "stopComplete": true,
      "address": {
        "name": "Depot",
        "lat": 32.1,
        "lng": 34.8
      },
      "passengers": [
        {
          "stopType": "pick",
          "reservation": {
            "id": 21,
            "status": "canceled",
            "seats": 2,
            "date": 1700000000,
            "dateType": "pick"
          }
        }
      ]
    }
  ],
  "mapRoutes": {
    "selectedIndex": 0,
    "options": [
      {
        "coordinates": [
          {
            "lat": 32.1,
            "lng": 34.8
          },
          {
            "lat": 31.99,
            "lng": 34.89
          }
        ],
        "legs": [
          {
            "distance": 12500,
            "duration": 2400
          }
        ],
        "totalDistance": 12500,
        "totalDuration": 2400
      }
    ]
  },
  "reservations": [
    {
      "id": 21,
      "status": "new",
      "date": 1700000000,
      "dateType": "pick",
      "from": {
        "name": "Depot",
        "lat": 32.1,
        "lng": 34.8
      },
      "to": {
        "name": "Airport",
        "lat": 31.99,
        "lng": 34.89
      },
      "seats": 2
    }
  ],
  "seats": 8,
  "status": "in-route",
  "driver": {
    "name": "John Doe",
    "isVirtual": false
  },
  "vehicle": {
    "name": "Minivan",
    "isVirtual": false
  },
  "bypassedRules": []
}

On this page