> ## Documentation Index
> Fetch the complete documentation index at: https://docs.devmob.app.br/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Trip Tracking

> Returns the last accepted trip tracking ping.



## OpenAPI

````yaml /api-reference/ops/openapi.json get /api/v1/ops/trips/{tripId}/tracking
openapi: 3.0.0
info:
  title: OABUS OPS API
  description: OABUS API
  version: '1.0'
  contact: {}
servers: []
security: []
tags: []
paths:
  /api/v1/ops/trips/{tripId}/tracking:
    get:
      tags:
        - Trip
      summary: Get Trip Tracking
      description: Returns the last accepted trip tracking ping.
      operationId: getTripTracking
      parameters:
        - name: tripId
          required: true
          in: path
          schema:
            type: string
            format: uuid
            description: Trip identifier
            example: 0195e7a1-8b5c-7d3e-9f4a-2c6b8d0e1f3a
        - name: fields
          required: false
          in: query
          description: >-
            Comma-separated list of fields to include in the response. Supports
            dot notation for nested projection (e.g.
            `id,name,user.email,trips.route.id`). Unknown fields are silently
            dropped.
          schema:
            type: string
      responses:
        '200':
          $ref: '#/components/responses/GetTripTracking200Response'
        '400':
          $ref: '#/components/responses/GetTripTracking400Response'
        '401':
          $ref: '#/components/responses/GetTripTracking401Response'
        '403':
          $ref: '#/components/responses/GetTripTracking403Response'
        '500':
          $ref: '#/components/responses/GetTripTracking500Response'
      security:
        - bearer: []
        - bearer: []
components:
  responses:
    GetTripTracking200Response:
      content:
        application/json:
          schema:
            type: object
            properties:
              tripTrackingId:
                type: string
                format: uuid
                description: Trip tracking identifier
                example: 0197a812-12e1-77fb-a2d1-b6fbf0570f89
              tripId:
                type: string
                format: uuid
                description: Trip identifier
                example: 0197a80f-2d8f-7710-b243-b67fb477a1c0
              driverId:
                type: string
                format: uuid
                description: Driver identifier
                example: 0197a807-1ec7-75e8-8ff8-df64dd070046
              latitude:
                type: number
                minimum: -90
                maximum: 90
                description: Latitude
                example: -23.55052
              longitude:
                type: number
                minimum: -180
                maximum: 180
                description: Longitude
                example: -46.63331
              accuracyMeters:
                description: Accuracy in meters
                example: 12
                nullable: true
                type: integer
              speedKmh:
                description: Speed in km/h
                example: 42.7
                nullable: true
                type: number
                minimum: 0
              headingDegrees:
                description: Heading in degrees
                example: 126.4
                nullable: true
                type: number
                minimum: 0
                maximum: 360
              source:
                type: string
                enum:
                  - DRIVER_APP_FOREGROUND
                  - DRIVER_APP_BACKGROUND
                description: Trip tracking source
                example: DRIVER_APP_BACKGROUND
              createdBy:
                description: Created by
                example: null
                nullable: true
                type: string
                format: uuid
              updatedBy:
                description: Updated by
                example: null
                nullable: true
                type: string
                format: uuid
              acceptedAt:
                type: string
                format: date-time
                description: Accepted at
                example: '2026-07-04T08:15:10.000Z'
              createdAt:
                type: string
                format: date-time
                description: Created at
                example: '2026-07-04T08:00:00.000Z'
              recordedAt:
                description: Device recorded time
                example: '2026-07-04T08:15:08.000Z'
                nullable: true
                type: string
                format: date-time
              updatedAt:
                type: string
                format: date-time
                description: Updated at
                example: '2026-07-04T08:15:10.000Z'
            required:
              - tripTrackingId
              - tripId
              - driverId
              - latitude
              - longitude
              - source
              - acceptedAt
              - createdAt
              - updatedAt
            additionalProperties: false
            description: Trip tracking
      description: OK
    GetTripTracking400Response:
      content:
        application/json:
          example:
            errors:
              - message: required
                path: name
            message: Bad Request Error
            statusCode: 400
          schema:
            properties:
              message:
                type: string
              statusCode:
                enum:
                  - 400
                type: number
              errors:
                items:
                  properties:
                    message:
                      type: string
                    path:
                      type: string
                  required:
                    - message
                    - path
                  type: object
                type: array
            required:
              - message
              - statusCode
            type: object
      description: Bad Request Error
    GetTripTracking401Response:
      content:
        application/json:
          example:
            message: Missing or invalid access token
            statusCode: 401
          schema:
            properties:
              message:
                type: string
              statusCode:
                enum:
                  - 401
                type: number
            required:
              - message
              - statusCode
            type: object
      description: Unauthorized
    GetTripTracking403Response:
      content:
        application/json:
          example:
            message: Insufficient permissions
            statusCode: 403
          schema:
            properties:
              message:
                type: string
              statusCode:
                enum:
                  - 403
                type: number
            required:
              - message
              - statusCode
            type: object
      description: Forbidden
    GetTripTracking500Response:
      content:
        application/json:
          example:
            message: Internal Server Error
            statusCode: 500
          schema:
            properties:
              message:
                type: string
              statusCode:
                enum:
                  - 500
                type: number
            required:
              - message
              - statusCode
            type: object
      description: Internal Server Error
  securitySchemes:
    bearer:
      scheme: bearer
      bearerFormat: JWT
      type: http

````