> ## Documentation Index
> Fetch the complete documentation index at: https://developer.mileiq.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Group Reported Drives

> Retrieve a paginated list of reported drives for a specific group, ordered by last modification date (most recent first). This endpoint returns drives that have been submitted for review by group members. Note: The 'created' field represents when the drive was reported to the system, while 'started_at' and 'ended_at' indicate the actual drive times. Supports filtering by date ranges and includes comprehensive drive details, driver information, and review status.



## OpenAPI

````yaml https://external-api.mileiq.com/openapi.json get /v1/groups/{group_id}/reported-drives
openapi: 3.1.0
info:
  title: MileIQ External API
  description: External API for integrating with the MileIQ Platform.
  termsOfService: https://mileiq.com/terms
  contact:
    name: MileIQ
    url: https://developer.mileiq.com/
    email: support@mileiq.com
  version: 1.4.0
servers:
  - url: https://external-api.mileiq.com
    description: MileIQ External API
security: []
paths:
  /v1/groups/{group_id}/reported-drives:
    get:
      tags:
        - groups
      summary: Get Group Reported Drives
      description: >-
        Retrieve a paginated list of reported drives for a specific group,
        ordered by last modification date (most recent first). This endpoint
        returns drives that have been submitted for review by group members.
        Note: The 'created' field represents when the drive was reported to the
        system, while 'started_at' and 'ended_at' indicate the actual drive
        times. Supports filtering by date ranges and includes comprehensive
        drive details, driver information, and review status.
      operationId: get_group_reported_drives
      parameters:
        - name: group_id
          in: path
          required: true
          schema:
            type: string
            title: Group Id
        - name: limit
          in: query
          required: false
          schema:
            type: integer
            maximum: 1000
            exclusiveMinimum: 0
            description: The number of drives to retrieve
            default: 100
            title: Limit
          description: The number of drives to retrieve
          example: '50'
        - name: date_before
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            description: >-
              The end date of the range to retrieve drives for based on the
              defined filter_by param (exclusive). Filter_by needs to be set for
              this field to be used. Should be in UTC
            title: Date Before
          description: >-
            The end date of the range to retrieve drives for based on the
            defined filter_by param (exclusive). Filter_by needs to be set for
            this field to be used. Should be in UTC
          example: '2024-05-05T16:01:07Z'
        - name: date_after
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            description: >-
              The start date of the range to retrieve drives for based on the
              defined filter_by param (exclusive). Filter_by needs to be set for
              this field to be used. Should be in UTC
            title: Date After
          description: >-
            The start date of the range to retrieve drives for based on the
            defined filter_by param (exclusive). Filter_by needs to be set for
            this field to be used. Should be in UTC
          example: '2024-05-05T16:01:07Z'
        - name: filter_by
          in: query
          required: false
          schema:
            anyOf:
              - $ref: '#/components/schemas/GetDrivesRequestFilterBy'
              - type: 'null'
            description: >-
              Use 'ended' to filter by the date the drive has ended. Use
              'modified' to filter by the date the drive was last updated
            title: Filter By
          description: >-
            Use 'ended' to filter by the date the drive has ended. Use
            'modified' to filter by the date the drive was last updated
        - name: modified_before
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            description: >-
              The end date of the range to retrieve drives for (exclusive). If
              the drive was reviewed by an admin, this will be the last review
              date. If not, this will be the same as the date it was reported.
              [DEPRECATED] Use [date_before, date_after] + filter_by instead
            title: Modified Before
          description: >-
            The end date of the range to retrieve drives for (exclusive). If the
            drive was reviewed by an admin, this will be the last review date.
            If not, this will be the same as the date it was reported.
            [DEPRECATED] Use [date_before, date_after] + filter_by instead
          example: '2024-05-12T16:01:07Z'
        - name: modified_after
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            description: >-
              The start date of the range to retrieve drives for (exclusive). If
              the drive was reviewed by an admin, this will be the last review
              date. If not, this will be the same as the date it was reported.
              [DEPRECATED] Use [date_before, date_after] + filter_by instead
            title: Modified After
          description: >-
            The start date of the range to retrieve drives for (exclusive). If
            the drive was reviewed by an admin, this will be the last review
            date. If not, this will be the same as the date it was reported.
            [DEPRECATED] Use [date_before, date_after] + filter_by instead
          example: '2024-05-05T16:01:07Z'
        - name: Authorization
          in: header
          required: false
          schema:
            type: string
            title: Authorization
      responses:
        '200':
          description: >-
            Successfully retrieved group reported drives. Returns paginated list
            of drives with complete details including driver info, locations,
            expenses, and review comments.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetReportedDrivesResponse'
        '400':
          description: >-
            Bad request. Invalid query parameters such as limit exceeding
            maximum allowed value or invalid date format.
        '401':
          description: Authentication failed. Invalid or missing authorization token.
        '403':
          description: >-
            Insufficient permissions. User does not have the required
            'groups_read_reported_drives' scope, is not authenticated, or is not
            an administrator of the requested group.
        '404':
          description: >-
            Group not found. The specified group ID does not exist or is not
            accessible to the user.
        '422':
          description: >-
            Validation error. Invalid group ID format or malformed query
            parameters.
        '429':
          description: Rate limit exceeded. Maximum 60 requests per minute allowed.
        '500':
          description: >-
            Internal server error. An unexpected error occurred while processing
            the request.
components:
  schemas:
    GetDrivesRequestFilterBy:
      type: string
      enum:
        - modified
        - ended
      title: GetDrivesRequestFilterBy
    GetReportedDrivesResponse:
      properties:
        results:
          items:
            $ref: '#/components/schemas/ReportedDriveSchema'
          type: array
          title: Results
          description: >-
            Array of reported drive objects containing complete drive details,
            driver information, and review status for group reporting
        has_more:
          type: boolean
          title: Has More
          description: >-
            Pagination indicator - true if additional drives exist beyond the
            current result set within the specified filters and date range
      type: object
      required:
        - results
        - has_more
      title: GetReportedDrivesResponse
    ReportedDriveSchema:
      properties:
        id:
          type: string
          title: Id
          description: The ID of the drive
        driver:
          anyOf:
            - $ref: '#/components/schemas/Driver'
            - type: 'null'
          description: The driver of the drive
        details:
          anyOf:
            - $ref: '#/components/schemas/DriveDetails'
            - type: 'null'
          description: The details of the drive
        created:
          type: string
          format: date-time
          title: Created
          description: The time in which the drive was reported. In ISO 8601 format
        modified:
          type: string
          format: date-time
          title: Modified
          description: >-
            The last time the drive was reviewed.If it was not reviewed, should
            be the same as created. In ISO 8601 format
        status:
          type: string
          title: Status
          description: The status of the drive
        review_comments:
          anyOf:
            - items:
                $ref: '#/components/schemas/ReviewComment'
              type: array
            - type: 'null'
          title: Review Comments
          description: The list of review comments on the drive
      type: object
      required:
        - id
        - driver
        - details
        - created
        - modified
        - status
        - review_comments
      title: ReportedDriveSchema
      description: >-
        Represents a single drive in a report with the drive details and the
        driver details.
    Driver:
      properties:
        id:
          type: string
          title: Id
          description: Driver parse ID
        name:
          type: string
          title: Name
          description: Driver's full name
        email:
          type: string
          title: Email
          description: Driver's email address
        status:
          type: string
          title: Status
          description: Whether the driver is active
        timezone_offset:
          type: number
          title: Timezone Offset
          description: Timezone offset for the user
      type: object
      required:
        - id
        - name
        - email
        - status
        - timezone_offset
      title: Driver
      description: Represent a driver information
    DriveDetails:
      properties:
        distance:
          anyOf:
            - $ref: '#/components/schemas/Distance'
            - $ref: '#/components/schemas/DistanceWithDiscount'
            - type: 'null'
          title: Distance
          description: The distance of the drive
        value:
          anyOf:
            - $ref: '#/components/schemas/Value'
            - type: 'null'
          description: The value of the drive
        toll_fees:
          anyOf:
            - $ref: '#/components/schemas/Value'
            - type: 'null'
          description: The toll fees of the drive
        parking_fees:
          anyOf:
            - $ref: '#/components/schemas/Value'
            - type: 'null'
          description: The parking fees of the drive
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
          description: The description of the drive from the driver notes
        entry:
          $ref: '#/components/schemas/DriveEntry'
          description: The entry method of the drive
        classification:
          anyOf:
            - $ref: '#/components/schemas/DriveClassification'
            - type: 'null'
          description: The classification of the drive
        purpose:
          anyOf:
            - type: string
            - type: 'null'
          title: Purpose
          description: The purpose of the drive
        start:
          anyOf:
            - $ref: '#/components/schemas/Geolocation'
            - type: 'null'
          description: The start location of the drive
        end:
          anyOf:
            - $ref: '#/components/schemas/Geolocation'
            - type: 'null'
          description: The end location of the drive
      type: object
      required:
        - distance
        - value
        - toll_fees
        - parking_fees
        - description
        - entry
        - classification
        - purpose
        - start
        - end
      title: DriveDetails
      description: Details of a single drive.
    ReviewComment:
      properties:
        id:
          type: string
          title: Id
          description: The ID of the review comment
        text:
          type: string
          title: Text
          description: The text of the review comment
        created_at:
          type: string
          format: date-time
          title: Created At
          description: The time in ISO 8601 format
        user_email:
          type: string
          title: User Email
          description: The email of the user who made the review comment
      type: object
      required:
        - id
        - text
        - created_at
        - user_email
      title: ReviewComment
      description: Represent a review comment within a reported drive
    Distance:
      properties:
        amount:
          type: number
          title: Amount
          description: The amount of the distance, in the specified units
        units:
          $ref: '#/components/schemas/DistanceUnits'
          description: The units of the distance
      type: object
      required:
        - amount
        - units
      title: Distance
      description: Represent the distance for a drive
    DistanceWithDiscount:
      properties:
        amount:
          type: number
          title: Amount
          description: The amount of the distance, in the specified units
        units:
          $ref: '#/components/schemas/DistanceUnits'
          description: The units of the distance
        discounted:
          anyOf:
            - type: integer
            - type: 'null'
          title: Discounted
          description: The discounted amount of the distance, in the specified units
      type: object
      required:
        - amount
        - units
      title: DistanceWithDiscount
      description: >-
        Represent the distance for a drive, with a discounted value set by the
        team
    Value:
      properties:
        amount:
          type: integer
          title: Amount
          description: The amount of the value, in the smallest unit of currency
        currency:
          $ref: '#/components/schemas/Currency'
          description: The currency of the value, in ISO 4217 format
      type: object
      required:
        - amount
        - currency
      title: Value
      description: Represent the value of a drive (excluding toll & parking fees)
    DriveEntry:
      type: string
      enum:
        - manual
        - automatic
      title: DriveEntry
      description: Whether the drive was entered manually or automatically
    DriveClassification:
      type: string
      enum:
        - business
        - personal
        - unclassified
      title: DriveClassification
      description: Drive classifications
    Geolocation:
      properties:
        name:
          type: string
          title: Name
          description: The name of the location
        lat:
          anyOf:
            - type: string
            - type: 'null'
          title: Lat
          description: The latitude of the location
        lon:
          anyOf:
            - type: string
            - type: 'null'
          title: Lon
          description: The longitude of the location
        time:
          type: string
          format: date-time
          title: Time
          description: The time in ISO 8601 format
        address:
          anyOf:
            - $ref: '#/components/schemas/Address'
            - type: 'null'
          description: The address of the location
      type: object
      required:
        - name
        - time
      title: Geolocation
      description: Represent the geolocation information of a drive
    DistanceUnits:
      type: string
      enum:
        - mi
        - km
      title: DistanceUnits
      description: Different distance units used for drives
    Currency:
      type: string
      enum:
        - USD
        - CAD
        - GBP
      title: Currency
      description: Different currencies used for drives
    Address:
      properties:
        country:
          anyOf:
            - type: string
            - type: 'null'
          title: Country
          description: Country name or code where the location is situated
        state:
          anyOf:
            - type: string
            - type: 'null'
          title: State
          description: State, province, or administrative region within the country
        city:
          anyOf:
            - type: string
            - type: 'null'
          title: City
          description: City or municipality name
        street:
          anyOf:
            - type: string
            - type: 'null'
          title: Street
          description: Street address including number and street name
        postal_code:
          anyOf:
            - type: string
            - type: 'null'
          title: Postal Code
          description: Postal or ZIP code for the location
      type: object
      title: Address
      description: >-
        Geographical address information for drive locations with standardized
        components

````