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

# List Tasks

> List all tasks for a team with filtering and pagination.

**Required Role:** VIEWER or higher

**Query Parameters:**
- `q`: Search by name (case-insensitive partial match)
- `status_filter`: Filter by task status (enabled, disabled, archived)
- `task_type`: Filter by task type (copy, sync)
- `source_location_id`: Filter by source location UUID
- `destination_location_id`: Filter by destination location UUID
- `is_scheduled`: Filter by scheduled (true) or manual (false) tasks
- `sort_by`: Field to sort by (name, status, updated_at)
- `sort_order`: Sort direction (asc, desc). Default: desc
- `page`: Page number (default: 1)
- `limit`: Items per page (default: 50, max: 100)

**Example Response:**
```json
{
    "tasks": [...],
    "total": 42,
    "page": 1,
    "limit": 50,
    "pages": 1
}
```



## OpenAPI

````yaml GET /v1/teams/{team_id}/tasks
openapi: 3.1.0
info:
  title: Data Raven API
  description: Cloud-to-cloud data transfer platform powered by RClone
  version: 0.5.0
servers: []
security: []
paths:
  /v1/teams/{team_id}/tasks:
    get:
      tags:
        - Tasks
      summary: List Tasks
      description: >-
        List all tasks for a team with filtering and pagination.


        **Required Role:** VIEWER or higher


        **Query Parameters:**

        - `q`: Search by name (case-insensitive partial match)

        - `status_filter`: Filter by task status (enabled, disabled, archived)

        - `task_type`: Filter by task type (copy, sync)

        - `source_location_id`: Filter by source location UUID

        - `destination_location_id`: Filter by destination location UUID

        - `is_scheduled`: Filter by scheduled (true) or manual (false) tasks

        - `location_type`: Filter by provider type (matches source or
        destination)

        - `sort_by`: Field to sort by (name, status, created_at, updated_at)

        - `sort_order`: Sort direction (asc, desc). Default: desc

        - `page`: Page number (default: 1)

        - `limit`: Items per page (default: 50, max: 100)


        **Example Response:**

        ```json

        {
            "tasks": [...],
            "total": 42,
            "page": 1,
            "limit": 50,
            "pages": 1
        }

        ```
      operationId: list_tasks_v1_teams__team_id__tasks_get
      parameters:
        - name: team_id
          in: path
          required: true
          schema:
            type: string
            format: uuid
            title: Team Id
        - name: q
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: Search by name (case-insensitive partial match)
            title: Q
          description: Search by name (case-insensitive partial match)
        - name: status_filter
          in: query
          required: false
          schema:
            anyOf:
              - $ref: '#/components/schemas/TaskStatus'
              - type: 'null'
            description: Filter by task status
            title: Status Filter
          description: Filter by task status
        - name: task_type
          in: query
          required: false
          schema:
            anyOf:
              - $ref: '#/components/schemas/TaskType'
              - type: 'null'
            description: Filter by task type (copy/sync)
            title: Task Type
          description: Filter by task type (copy/sync)
        - name: source_location_id
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: uuid
              - type: 'null'
            description: Filter by source location
            title: Source Location Id
          description: Filter by source location
        - name: destination_location_id
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: uuid
              - type: 'null'
            description: Filter by destination location
            title: Destination Location Id
          description: Filter by destination location
        - name: is_scheduled
          in: query
          required: false
          schema:
            anyOf:
              - type: boolean
              - type: 'null'
            description: Filter by scheduled/manual tasks
            title: Is Scheduled
          description: Filter by scheduled/manual tasks
        - name: location_type
          in: query
          required: false
          schema:
            anyOf:
              - $ref: '#/components/schemas/LocationType'
              - type: 'null'
            description: Filter by provider (matches source or destination)
            title: Location Type
          description: Filter by provider (matches source or destination)
        - name: page
          in: query
          required: false
          schema:
            type: integer
            minimum: 1
            description: Page number (1-indexed)
            default: 1
            title: Page
          description: Page number (1-indexed)
        - name: limit
          in: query
          required: false
          schema:
            type: integer
            maximum: 100
            minimum: 1
            description: Items per page
            default: 50
            title: Limit
          description: Items per page
        - name: sort_by
          in: query
          required: false
          schema:
            anyOf:
              - enum:
                  - name
                  - status
                  - created_at
                  - updated_at
                type: string
              - type: 'null'
            description: 'Field to sort by: name, status, created_at, updated_at'
            title: Sort By
          description: 'Field to sort by: name, status, created_at, updated_at'
        - name: sort_order
          in: query
          required: false
          schema:
            anyOf:
              - $ref: '#/components/schemas/SortOrder'
              - type: 'null'
            description: 'Sort order: asc or desc (default: desc)'
            title: Sort Order
          description: 'Sort order: asc or desc (default: desc)'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PaginatedResponse_TaskListItemResponse_'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBearer: []
components:
  schemas:
    TaskStatus:
      type: string
      enum:
        - enabled
        - disabled
        - archived
      title: TaskStatus
      description: Task definition status.
    TaskType:
      type: string
      enum:
        - copy
        - sync
      title: TaskType
      description: Task operation types.
    LocationType:
      type: string
      enum:
        - s3
        - azure_blob
        - gcs
        - r2
        - b2
        - wasabi
        - railway
        - oracle_object_storage_s3
        - s3_compatible
        - tigris
        - digitalocean_spaces
        - hetzner
        - rabata
      title: LocationType
      description: Cloud storage provider types.
    SortOrder:
      type: string
      enum:
        - asc
        - desc
      title: SortOrder
      description: Sort order for list endpoints.
    PaginatedResponse_TaskListItemResponse_:
      properties:
        data:
          items:
            $ref: '#/components/schemas/TaskListItemResponse'
          type: array
          title: Data
        pagination:
          $ref: '#/components/schemas/PaginationResponse'
      type: object
      required:
        - data
        - pagination
      title: PaginatedResponse[TaskListItemResponse]
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    TaskListItemResponse:
      properties:
        id:
          type: string
          format: uuid
          title: Id
        team_id:
          type: string
          format: uuid
          title: Team Id
        created_by:
          type: string
          format: uuid
          title: Created By
        name:
          type: string
          title: Name
        description:
          anyOf:
            - type: string
              maxLength: 2000
            - type: 'null'
          title: Description
        task_type:
          $ref: '#/components/schemas/TaskType'
        source_path:
          anyOf:
            - type: string
              maxLength: 1000
            - type: 'null'
          title: Source Path
          description: Path within source bucket
          examples:
            - /prod/data
            - /logs/2024
        destination_path:
          anyOf:
            - type: string
              maxLength: 1000
            - type: 'null'
          title: Destination Path
          description: Path within destination bucket
          examples:
            - /backup
            - /archive/2024
        source_location_id:
          type: string
          format: uuid
          title: Source Location Id
        source_location_name:
          type: string
          title: Source Location Name
          description: Source location display name
        source_location_bucket:
          type: string
          title: Source Location Bucket
          description: Source location bucket name
        source_location_type:
          type: string
          title: Source Location Type
          description: Source location provider type
        destination_location_id:
          type: string
          format: uuid
          title: Destination Location Id
        destination_location_name:
          type: string
          title: Destination Location Name
          description: Destination location display name
        destination_location_bucket:
          type: string
          title: Destination Location Bucket
          description: Destination location bucket name
        destination_location_type:
          type: string
          title: Destination Location Type
          description: Destination location provider type
        is_scheduled:
          type: boolean
          title: Is Scheduled
        schedule_cron:
          anyOf:
            - type: string
              maxLength: 100
            - type: 'null'
          title: Schedule Cron
        last_scheduled_run_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Last Scheduled Run At
          description: Last scheduled execution time
        status:
          $ref: '#/components/schemas/TaskStatus'
        created_at:
          type: string
          format: date-time
          title: Created At
        updated_at:
          type: string
          format: date-time
          title: Updated At
        last_execution_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Last Execution At
          description: When the last non-dry-run execution completed
        last_execution_status:
          anyOf:
            - $ref: '#/components/schemas/ExecutionStatus'
            - type: 'null'
          description: Status of the last non-dry-run execution
        has_active_execution:
          type: boolean
          title: Has Active Execution
          description: Whether a PENDING or RUNNING execution exists
          default: false
        has_dry_run_completed:
          type: boolean
          title: Has Dry Run Completed
          description: >-
            Whether at least one execution with status DRY_RUN_COMPLETED exists.
            Useful for clients that need a successful-run signal without a
            separate executions query, since `last_execution_status` excludes
            dry runs.
          default: false
      type: object
      required:
        - id
        - team_id
        - created_by
        - name
        - task_type
        - source_location_id
        - source_location_name
        - source_location_bucket
        - source_location_type
        - destination_location_id
        - destination_location_name
        - destination_location_bucket
        - destination_location_type
        - is_scheduled
        - status
        - created_at
        - updated_at
      title: TaskListItemResponse
      description: Lightweight task response for list endpoint (excludes rclone_config).
    PaginationResponse:
      properties:
        page:
          type: integer
          title: Page
        limit:
          type: integer
          title: Limit
        total:
          type: integer
          title: Total
        total_pages:
          type: integer
          title: Total Pages
      type: object
      required:
        - page
        - limit
        - total
        - total_pages
      title: PaginationResponse
      description: Pagination metadata in responses.
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
    ExecutionStatus:
      type: string
      enum:
        - pending
        - running
        - completed
        - failed
        - cancelled
        - dry_run_completed
      title: ExecutionStatus
      description: Runtime execution status.
  securitySchemes:
    HTTPBearer:
      type: http
      scheme: bearer

````