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

# Task List

> List scheduled commands visible to the current user.

Includes all commands owned by the user (any state), plus public commands.



## OpenAPI

````yaml get /api/task
openapi: 3.1.0
info:
  title: Apigene
  description: Apigene API
  version: 1.0.0
  contact:
    name: Apigene Support
    url: https://app.apigene.ai
    email: support@apigene.ai
servers:
  - url: https://app.apigene.ai
security:
  - BearerAuth: []
paths:
  /api/task:
    get:
      tags:
        - Task
      summary: Task List
      description: >-
        List scheduled commands visible to the current user.


        Includes all commands owned by the user (any state), plus public
        commands.
      operationId: task_list
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                items:
                  $ref: '#/components/schemas/Task'
                type: array
                title: Response Task List
      security:
        - BearerAuth: []
components:
  schemas:
    Task:
      properties:
        id:
          anyOf:
            - type: string
            - type: 'null'
          title: Id
          description: Unique identifier for the command
        name:
          type: string
          title: Name
          description: Command display name.
        prompt:
          type: string
          title: Prompt
          description: Prompt / command text.
        agent_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Agent Id
          description: Optional Copilot agent id.
        chat_model:
          anyOf:
            - $ref: '#/components/schemas/ChatModelRef'
            - type: 'null'
          description: Optional model override.
        mentions:
          items:
            additionalProperties: true
            type: object
          type: array
          title: Mentions
        created_by:
          type: string
          title: Created By
          description: User who created the command (email)
        visibility:
          $ref: '#/components/schemas/Visibility'
          default: private
        schedule:
          $ref: '#/components/schemas/Schedule'
        state:
          $ref: '#/components/schemas/TaskState'
          default: enabled
        thread_policy:
          $ref: '#/components/schemas/ThreadPolicy'
          default: new_each_run
        thread_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Thread Id
        next_run:
          type: string
          format: date-time
          title: Next Run
          description: Next scheduled execution time (UTC)
          default: '1970-01-01T00:00:00'
        last_run_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Last Run At
        last_run_status:
          anyOf:
            - type: string
            - type: 'null'
          title: Last Run Status
        last_run_thread_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Last Run Thread Id
      type: object
      required:
        - name
        - prompt
        - created_by
      title: Task
    ChatModelRef:
      properties:
        provider:
          anyOf:
            - type: string
            - type: 'null'
          title: Provider
        model:
          anyOf:
            - type: string
            - type: 'null'
          title: Model
      type: object
      title: ChatModelRef
    Visibility:
      type: string
      enum:
        - private
        - public
      title: Visibility
    Schedule:
      properties:
        frequency:
          $ref: '#/components/schemas/ScheduleFrequency'
          description: 'Schedule frequency: ''manual'', ''daily'', or ''weekly'''
        hour:
          type: string
          title: Hour
          description: Hour of the day in HH:MM to run the command
          default: '09:00'
        day:
          type: string
          title: Day
          description: Day of the week for weekly schedules
          default: Monday
        timezone:
          type: string
          title: Timezone
          description: IANA timezone for schedule evaluation
          default: UTC
      type: object
      required:
        - frequency
      title: Schedule
    TaskState:
      type: string
      enum:
        - disabled
        - enabled
      title: TaskState
    ThreadPolicy:
      type: string
      enum:
        - new_each_run
        - append
      title: ThreadPolicy
    ScheduleFrequency:
      type: string
      enum:
        - manual
        - daily
        - weekly
      title: ScheduleFrequency
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >-
        JWT Authorization header using the Bearer scheme. Example:
        'Authorization: Bearer {token}'

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.