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

# Get Machine Tasks

> Retrieves a list of scheduled machine tasks based on various query parameters such as date range, machine, driver, route, and other filters.



## OpenAPI

````yaml /openapi/lynx.yaml get /v1/Scheduling/schedule/machine-tasks
openapi: 3.0.1
info:
  title: Nayax Operational Lynx API
  version: v1
servers:
  - url: https://qa-lynx.nayax.com/operational
security:
  - Authorization: []
paths:
  /v1/Scheduling/schedule/machine-tasks:
    get:
      tags:
        - Scheduling
      summary: Get Machine Tasks
      description: >-
        Retrieves a list of scheduled machine tasks based on various query
        parameters such as date range, machine, driver, route, and other
        filters.
      operationId: get-machine-tasks
      parameters:
        - name: StartDate
          in: query
          description: The start date of the task scheduling period.
          schema:
            type: string
            format: date-time
        - name: EndDate
          in: query
          description: The end date of the task scheduling period.
          schema:
            type: string
            format: date-time
        - name: SchedulingId
          in: query
          description: The unique identifier for the specific scheduling instance.
          schema:
            type: integer
            format: int64
        - name: ActorId
          in: query
          description: The unique identifier for the actor associated with the task.
          schema:
            type: integer
            format: int32
        - name: MachineId
          in: query
          description: The unique identifier for the machine associated with the task.
          schema:
            type: integer
            format: int64
        - name: DriverId
          in: query
          description: The unique identifier for the driver assigned to the task.
          schema:
            type: string
            format: uuid
        - name: RouteId
          in: query
          description: The unique identifier for the route associated with the task.
          schema:
            type: integer
            format: int64
        - name: TimePeriod
          in: query
          description: >-
            The time period for which the tasks are requested, with a default of
            31 days.
          schema:
            type: integer
            format: int32
            default: 31
        - name: IsForlist
          in: query
          description: A flag indicating if the tasks are for list view. Default is true.
          schema:
            type: boolean
            default: true
        - name: IsStatic
          in: query
          description: A flag indicating if the tasks are static.
          schema:
            type: boolean
      responses:
        '200':
          description: A list of scheduled machine tasks matching the specified criteria.
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/TaskSchedulingResponseDto'
components:
  schemas:
    TaskSchedulingResponseDto:
      type: object
      properties:
        MachineId:
          type: integer
          format: int64
          description: The unique identifier of the machine associated with the task.
        RouteId:
          type: integer
          format: int64
          nullable: true
          description: >-
            The unique identifier of the route associated with the task, if
            applicable.
        RouteName:
          type: string
          nullable: true
          description: The name of the route associated with the task, if applicable.
        VisitDate:
          type: string
          format: date-time
          nullable: true
          description: The date and time of the scheduled visit.
        ScheduleTasks:
          type: array
          items:
            $ref: '#/components/schemas/ScheduleTaskDto'
          nullable: true
          description: A list of scheduled tasks associated with the machine.
      additionalProperties: false
    ScheduleTaskDto:
      type: object
      properties:
        MachineId:
          type: integer
          format: int64
          description: The unique identifier of the machine associated with the task.
        TaskLutId:
          type: string
          nullable: true
          description: The identifier for the type of task from the lookup table.
        SchedulingId:
          type: integer
          format: int64
          description: The unique identifier of the scheduling instance.
        DriverId:
          type: string
          format: uuid
          nullable: true
          description: The unique identifier of the driver assigned to the task.
        DriverName:
          type: string
          nullable: true
          description: The name of the driver assigned to the task.
        TimezoneOffset:
          type: number
          format: double
          description: The timezone offset in hours for the scheduled task.
        ScheduleDate:
          type: string
          format: date-time
          nullable: true
          description: The date and time when the task is scheduled.
        StatusId:
          type: integer
          format: int32
          description: The status identifier of the task.
        Notes:
          type: string
          nullable: true
          description: Additional notes related to the task.
        GeneratePickList:
          type: boolean
          description: Indicates whether a pick list should be generated for the task.
        GeneratePickListTime:
          type: string
          nullable: true
          description: The time when the pick list is generated.
        GeneratePickListRange:
          type: integer
          format: int32
          nullable: true
          description: The range in minutes for generating the pick list.
        ScheduleNextWorkingDay:
          type: boolean
          description: >-
            Indicates whether the task should be scheduled for the next working
            day.
        AssignedToPatternId:
          type: integer
          format: int64
          nullable: true
          description: The unique identifier of the pattern to which the task is assigned.
        AssignedToScheduleId:
          type: integer
          format: int64
          nullable: true
          description: The unique identifier of the schedule to which the task is assigned.
        IncompletionReason:
          type: string
          nullable: true
          description: The reason for task incompletion, if applicable.
        IncompletionReasonImages:
          type: array
          items:
            $ref: '#/components/schemas/EntityPicture'
          nullable: true
          description: A list of images associated with the reason for task incompletion.
        Pattern:
          $ref: '#/components/schemas/Pattern'
          description: The pattern details associated with the task, if any.
        IsClustered:
          type: boolean
          nullable: true
          description: Indicates whether the task is part of a clustered set of tasks.
        ClusterIds:
          type: string
          nullable: true
          description: The identifiers of the clustered tasks, if applicable.
        CreatedBy:
          type: integer
          format: int64
          description: The unique identifier of the user who created the task.
        CreatedDt:
          type: string
          format: date-time
          description: The date and time when the task was created.
        UpdatedBy:
          type: integer
          format: int64
          nullable: true
          description: The unique identifier of the user who last updated the task.
        UpdatedDt:
          type: string
          format: date-time
          nullable: true
          description: The date and time when the task was last updated.
        isMobile:
          type: boolean
          nullable: true
          description: >-
            Indicates whether the task was created or updated via a mobile
            device.
        isSeriesUpdate:
          type: boolean
          nullable: true
          description: Indicates whether the task is part of a series update.
        originalDate:
          type: string
          nullable: true
          description: >-
            The original date of the task before any rescheduling, if
            applicable.
        IncompletionReasonId:
          type: integer
          format: int32
          nullable: true
          description: The unique identifier of the reason for task incompletion.
        IncompletionReasonName:
          type: string
          nullable: true
          description: The name of the reason for task incompletion.
      additionalProperties: false
    EntityPicture:
      type: object
      properties:
        EntityPictureId:
          type: integer
          format: int32
          description: The unique identifier of the entity picture.
        EntityPictureUrl:
          type: string
          nullable: true
          description: The URL of the entity picture.
      additionalProperties: false
    Pattern:
      type: object
      properties:
        PatternId:
          type: integer
          format: int64
          nullable: true
          description: The unique identifier of the pattern.
        Name:
          type: string
          nullable: true
          description: The name of the pattern.
        Description:
          type: string
          nullable: true
          description: The description of the pattern.
        RepeatType:
          type: integer
          format: int32
          nullable: true
          description: The type of repetition for the pattern (e.g., daily, weekly).
        RepeatInterval:
          type: integer
          format: int32
          description: The interval of repetition for the pattern.
        IsStatic:
          type: boolean
          description: Indicates whether the pattern is static.
        StartOn:
          type: string
          format: date-time
          nullable: true
          description: The start date and time of the pattern.
        EndOn:
          type: string
          format: date-time
          nullable: true
          description: The end date and time of the pattern.
        EndAfter:
          type: integer
          format: int32
          nullable: true
          description: The number of occurrences after which the pattern ends.
        RepeatOn:
          type: array
          items:
            $ref: '#/components/schemas/RepeatOn'
          nullable: true
          description: The days and weeks on which the pattern repeats.
      additionalProperties: false
    RepeatOn:
      type: object
      properties:
        Tasks:
          type: string
          nullable: true
          description: The tasks associated with the repetition pattern.
        Days:
          type: string
          nullable: true
          description: The days of the week on which the tasks repeat.
        Week:
          type: string
          nullable: true
          description: The week of the month on which the tasks repeat.
        MonthDay:
          type: string
          nullable: true
          description: The day of the month on which the tasks repeat.
        SetPos:
          type: string
          nullable: true
          description: >-
            The position within the month (e.g., first, second) for the tasks to
            repeat.
        RecurrenceEx:
          type: string
          nullable: true
          description: Any exceptions to the recurrence pattern.
        WeekNumber:
          type: string
          nullable: true
          description: The week number within the recurrence period.
      additionalProperties: false
  securitySchemes:
    Authorization:
      type: http
      scheme: bearer
      description: Enter your Bearer token. It's required to authenticate API requests.

````