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

# List scheduled jobs

> Lists the caller's scheduled jobs, newest first, with opaque cursor pagination. `next_fire_at` is computed at read time via croniter.



## OpenAPI

````yaml /openapi.json get /scheduled-jobs
openapi: 3.1.0
info:
  title: GetDialed Flows API
  version: 0.1.0
servers:
  - url: https://api.getdialed.ai/flows
    description: Production
  - url: http://localhost:8000
    description: Local development
security: []
paths:
  /scheduled-jobs:
    get:
      tags:
        - scheduled-jobs
      summary: List scheduled jobs
      description: >-
        Lists the caller's scheduled jobs, newest first, with opaque cursor
        pagination. `next_fire_at` is computed at read time via croniter.
      operationId: list_scheduled_jobs_scheduled_jobs_get
      parameters:
        - name: cursor
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Cursor
        - name: limit
          in: query
          required: false
          schema:
            type: integer
            maximum: 200
            minimum: 1
            default: 50
            title: Limit
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ScheduledJobListResponse'
        '401':
          description: Missing or invalid authentication
          content:
            application/json:
              example:
                detail: Authentication required
        '422':
          description: Validation error (see body for field details)
          content:
            application/json:
              example:
                detail: Validation error
      security:
        - APIKeyHeader: []
        - HTTPBearer: []
components:
  schemas:
    ScheduledJobListResponse:
      properties:
        items:
          items:
            $ref: '#/components/schemas/ScheduledJobResponse'
          type: array
          title: Items
        next_cursor:
          anyOf:
            - type: string
            - type: 'null'
          title: Next Cursor
      type: object
      required:
        - items
      title: ScheduledJobListResponse
      description: |-
        GET /scheduled-jobs list envelope.

        `next_cursor` is the router-encoded opaque base64url(json) token —
        the repository emits the structured dict shape `{"c": iso, "i": id}`
        and the router does the encoding (separation of concerns: persistence
        layer doesn't speak HTTP).
    ScheduledJobResponse:
      properties:
        id:
          type: string
          title: Id
        definition_id:
          type: string
          title: Definition Id
        org_id:
          type: string
          title: Org Id
        description:
          type: string
          title: Description
        cron_expression:
          type: string
          title: Cron Expression
        enabled:
          type: boolean
          title: Enabled
        input_data:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Input Data
        metadata:
          additionalProperties: true
          type: object
          title: Metadata
        created_at:
          type: string
          format: date-time
          title: Created At
        updated_at:
          type: string
          format: date-time
          title: Updated At
        next_fire_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Next Fire At
        last_fired_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Last Fired At
        last_fire_status:
          anyOf:
            - type: string
              enum:
                - success
                - failure
                - running
            - type: 'null'
          title: Last Fire Status
      type: object
      required:
        - id
        - definition_id
        - org_id
        - description
        - cron_expression
        - enabled
        - input_data
        - metadata
        - created_at
        - updated_at
        - next_fire_at
        - last_fired_at
        - last_fire_status
      title: ScheduledJobResponse
      description: >-
        GET response — `next_fire_at` is injected by the router via croniter
        (D-14).


        `next_fire_at` is None only for legacy rows whose stored cron cannot

        produce a next fire (CR-02 defense in depth) — the write gate rejects

        such expressions for all new/updated records.
      example:
        created_at: '2026-07-09T09:00:00Z'
        cron_expression: 0 9 * * 1-5
        definition_id: def_a1b2c3d4
        description: Nightly Five9 report sync
        enabled: true
        id: sched_1a2b3c4d
        input_data:
          report: daily_calls
        metadata:
          owner: ops
        next_fire_at: '2026-07-10T09:00:00Z'
        org_id: org_e5f6g7h8
        updated_at: '2026-07-09T09:00:00Z'
  securitySchemes:
    APIKeyHeader:
      type: apiKey
      in: header
      name: X-API-Key
    HTTPBearer:
      type: http
      scheme: bearer
      bearerFormat: JWT

````