openapi: 3.1.0
info:
  title: Datablist Enrichment API
  version: '2026-10-09'
  description: Collection-independent asynchronous enrichment and source tasks. Sources generate flat
    data without a Datablist collection.
servers:
- url: https://api.datablist.com
  description: Production
tags:
- name: Catalog
- name: Tasks
paths:
  /v1/enrichments:
    get:
      operationId: listEnrichments
      summary: List enabled enrichments
      tags:
      - Catalog
      security: []
      description: Public discovery; no authentication is required.
      responses:
        '200':
          description: Enabled enrichment catalog
          content:
            application/json:
              schema:
                type: object
                required:
                - enrichments
                properties:
                  enrichments:
                    type: array
                    items:
                      $ref: '#/components/schemas/Enrichment'
        '403':
          $ref: '#/components/responses/Forbidden'
  /v1/enrichments/{enrichmentId}:
    parameters:
    - $ref: '#/components/parameters/EnrichmentId'
    get:
      operationId: getEnrichmentSchema
      summary: Get an enrichment schema
      tags:
      - Catalog
      security: []
      description: Public discovery; no authentication is required.
      responses:
        '200':
          description: Resolved public schema and limits
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Enrichment'
        '404':
          $ref: '#/components/responses/NotFound'
  /v1/enrichments/tasks:
    post:
      operationId: createEnrichmentTask
      summary: Create an asynchronous enrichment task
      description: Requires a caller-supplied uniqueId in the JSON body. A queued, running, or stop_asked
        task in the same account with that uniqueId returns 409 DuplicateApiTask. Failed, completed, stopped,
        and overdue tasks do not block reuse; reuse creates a new task, without comparing or hashing inputs
        and settings. The API stores the submission and awaits all queue batches before 202. A queue failure
        returns 503 and marks the unaccepted task failed, releasing the uniqueId for a new execution.
        Batches already started may have executed and consumed credits. Check history before retrying
        an ambiguous response. A best effort account limit targets twenty active tasks with future deadlines;
        concurrent requests can occasionally exceed the target.
      tags:
      - Tasks
      security:
      - apiKeyAuth: []
      - bearerAuth: []
      x-required-scopes:
      - enrichments:tasks:create
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateTaskRequest'
            example:
              enrichmentId: name_to_domain
              uniqueId: company-import-20261009-part-1
              settings: {}
              inputs:
              - inputId: company-123
                data:
                  companyName: Acme, Inc.
              - inputId: company-456
                data:
                  companyName: Example GmbH
      responses:
        '202':
          description: New task stored durably and all queue batches accepted
          headers:
            Location:
              description: Absolute task status URL
              schema:
                type: string
                format: uri
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Task'
        '409':
          $ref: '#/components/responses/Conflict'
        '413':
          $ref: '#/components/responses/PayloadTooLarge'
        '422':
          $ref: '#/components/responses/Unprocessable'
        '429':
          $ref: '#/components/responses/RateLimited'
        '503':
          $ref: '#/components/responses/DispatchFailed'
    get:
      operationId: listEnrichmentTasks
      summary: List authorized task history
      tags:
      - Tasks
      security:
      - apiKeyAuth: []
      - bearerAuth: []
      x-required-scopes:
      - enrichments:tasks:read
      parameters:
      - $ref: '#/components/parameters/Cursor'
      - $ref: '#/components/parameters/Limit'
      - name: status
        in: query
        schema:
          $ref: '#/components/schemas/TaskStatus'
      - name: enrichmentId
        in: query
        schema:
          type: string
      responses:
        '200':
          description: Task page
          content:
            application/json:
              schema:
                type: object
                required:
                - tasks
                - nextCursor
                properties:
                  tasks:
                    type: array
                    items:
                      $ref: '#/components/schemas/Task'
                  nextCursor:
                    $ref: '#/components/schemas/NullableCursor'
        '401':
          $ref: '#/components/responses/Unauthorized'
  /v1/enrichments/tasks/{taskId}:
    parameters:
    - $ref: '#/components/parameters/TaskId'
    get:
      operationId: getEnrichmentTask
      summary: Get task status
      tags:
      - Tasks
      security:
      - apiKeyAuth: []
      - bearerAuth: []
      x-required-scopes:
      - enrichments:tasks:read
      responses:
        '200':
          description: Task metadata without raw inputs
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Task'
        '404':
          $ref: '#/components/responses/NotFound'
  /v1/enrichments/tasks/{taskId}/stop:
    parameters:
    - $ref: '#/components/parameters/TaskId'
    post:
      operationId: stopEnrichmentTask
      summary: Request task cancellation
      description: Moves an active task to stop_asked. Already-started work may finish and non-stoppable
        provider polling may continue until it returns or its heartbeat lease expires. Remaining inputs
        are returned as skipped.
      tags:
      - Tasks
      security:
      - apiKeyAuth: []
      - bearerAuth: []
      x-required-scopes:
      - enrichments:tasks:create
      responses:
        '202':
          description: Stop request accepted, or the task was already terminal
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Task'
        '404':
          $ref: '#/components/responses/NotFound'
  /v1/enrichments/tasks/{taskId}/inputs:
    parameters:
    - $ref: '#/components/parameters/TaskId'
    - $ref: '#/components/parameters/Cursor'
    - $ref: '#/components/parameters/Limit'
    get:
      operationId: listEnrichmentTaskInputs
      summary: Get immutable task settings and inputs
      tags:
      - Tasks
      security:
      - apiKeyAuth: []
      - bearerAuth: []
      x-required-scopes:
      - enrichments:tasks:read
      responses:
        '200':
          description: Submitted input page
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InputPage'
        '404':
          $ref: '#/components/responses/NotFound'
  /v1/enrichments/tasks/{taskId}/results:
    parameters:
    - $ref: '#/components/parameters/TaskId'
    - $ref: '#/components/parameters/Cursor'
    - $ref: '#/components/parameters/Limit'
    get:
      operationId: listEnrichmentTaskResults
      summary: Get terminal results
      description: Returns 409 ResultsNotReady until the task is terminal. Completed, failed, and stopped
        tasks may be read. Continuations retain one final result per original input, with later-step results
        and credits accumulated across steps. Partial dispatch failures can leave fewer persisted results
        than original inputs.
      tags:
      - Tasks
      security:
      - apiKeyAuth: []
      - bearerAuth: []
      x-required-scopes:
      - enrichments:tasks:read
      responses:
        '200':
          description: Stable input-order result page
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ResultPage'
        '409':
          $ref: '#/components/responses/Conflict'
        '404':
          $ref: '#/components/responses/NotFound'
  /v1/sources:
    get:
      operationId: listSources
      summary: List enabled sources
      tags:
      - Catalog
      security: []
      description: Public discovery; no authentication is required.
      responses:
        '200':
          description: Enabled source catalog
          content:
            application/json:
              schema:
                type: object
                required:
                - sources
                properties:
                  sources:
                    type: array
                    items:
                      $ref: '#/components/schemas/Source'
        '403':
          $ref: '#/components/responses/Forbidden'
  /v1/sources/{sourceId}:
    parameters:
    - $ref: '#/components/parameters/SourceId'
    get:
      operationId: getSourceSchema
      summary: Get a source schema
      tags:
      - Catalog
      security: []
      description: Public discovery; no authentication is required.
      responses:
        '200':
          description: Resolved public schema and limits
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Source'
        '404':
          $ref: '#/components/responses/NotFound'
  /v1/sources/tasks:
    post:
      operationId: createSourceTask
      summary: Create an asynchronous source task
      tags:
      - Tasks
      security:
      - apiKeyAuth: []
      - bearerAuth: []
      x-required-scopes:
      - enrichments:tasks:create
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateSourceTaskRequest'
            example:
              sourceId: instagram-source
              uniqueId: instagram-followers-20261009
              settings:
                profiles: example_profile
                scrapingType: followers
                limitPerProfile: 100
      responses:
        '202':
          description: New task stored durably and all queue batches accepted
          headers:
            Location:
              description: Absolute task status URL
              schema:
                type: string
                format: uri
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SourceTask'
        '409':
          $ref: '#/components/responses/Conflict'
        '413':
          $ref: '#/components/responses/PayloadTooLarge'
        '422':
          $ref: '#/components/responses/Unprocessable'
        '429':
          $ref: '#/components/responses/RateLimited'
        '503':
          $ref: '#/components/responses/DispatchFailed'
      description: Create one source execution from settings, without input rows or a destination collection.
        Continuations share the task budget and stop lease. Omitted maxCredits means unlimited. Each execution
        can return at most 10,000 objects, 16 KiB per object and 5 MiB in total. Account admission limits
        and active uniqueId reservations are shared with enrichment tasks. A duplicate queued, running,
        or stop_asked task returns 409. Terminal and overdue tasks release their uniqueId; a retry then
        creates new work.
    get:
      operationId: listSourceTasks
      summary: List authorized task history
      tags:
      - Tasks
      security:
      - apiKeyAuth: []
      - bearerAuth: []
      x-required-scopes:
      - enrichments:tasks:read
      parameters:
      - $ref: '#/components/parameters/Cursor'
      - $ref: '#/components/parameters/Limit'
      - name: status
        in: query
        schema:
          $ref: '#/components/schemas/TaskStatus'
      - name: sourceId
        in: query
        schema:
          type: string
      responses:
        '200':
          description: Task page
          content:
            application/json:
              schema:
                type: object
                required:
                - tasks
                - nextCursor
                properties:
                  tasks:
                    type: array
                    items:
                      $ref: '#/components/schemas/SourceTask'
                  nextCursor:
                    $ref: '#/components/schemas/NullableCursor'
        '401':
          $ref: '#/components/responses/Unauthorized'
  /v1/sources/tasks/{taskId}:
    parameters:
    - $ref: '#/components/parameters/TaskId'
    get:
      operationId: getSourceTask
      summary: Get task status
      tags:
      - Tasks
      security:
      - apiKeyAuth: []
      - bearerAuth: []
      x-required-scopes:
      - enrichments:tasks:read
      responses:
        '200':
          description: Task metadata without raw inputs
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SourceTask'
        '404':
          $ref: '#/components/responses/NotFound'
  /v1/sources/tasks/{taskId}/stop:
    parameters:
    - $ref: '#/components/parameters/TaskId'
    post:
      operationId: stopSourceTask
      summary: Request task cancellation
      tags:
      - Tasks
      security:
      - apiKeyAuth: []
      - bearerAuth: []
      x-required-scopes:
      - enrichments:tasks:create
      responses:
        '202':
          description: Stop request accepted, or the task was already terminal
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SourceTask'
        '404':
          $ref: '#/components/responses/NotFound'
      description: Moves an active source task to stop_asked. Already-started work may finish and non-stoppable
        provider polling may continue until it returns or its inactivity lease expires. Poll until completed,
        failed, or stopped and then retrieve partial generated results. No skipped-input rows are created
        for sources.
  /v1/sources/tasks/{taskId}/results:
    parameters:
    - $ref: '#/components/parameters/TaskId'
    - $ref: '#/components/parameters/Cursor'
    - $ref: '#/components/parameters/Limit'
    get:
      operationId: listSourceTaskResults
      summary: Get terminal results
      tags:
      - Tasks
      security:
      - apiKeyAuth: []
      - bearerAuth: []
      x-required-scopes:
      - enrichments:tasks:read
      responses:
        '200':
          description: Stable page of flat generated objects
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SourceResultPage'
        '409':
          $ref: '#/components/responses/Conflict'
        '404':
          $ref: '#/components/responses/NotFound'
      description: Flat generated JSON objects, available only on completed, failed, or stopped tasks.
        Failed and stopped tasks preserve partial results. Ordering is stable within a terminal task,
        not chronological across executions. limit is 1–100 and each page is bounded to 128 KiB. nextCursor
        is opaque.
components:
  securitySchemes:
    apiKeyAuth:
      type: apiKey
      in: header
      name: X-API-Key
      description: Personal API Key. Datablist handles token exchange and renewal. Send either this header or Authorization, not both.
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: Account access token obtained by exchanging a Personal API Key at POST /v1/account/token.
        The same account bearer credential is used for REST and MCP.
  parameters:
    EnrichmentId:
      name: enrichmentId
      in: path
      required: true
      schema:
        type: string
    TaskId:
      name: taskId
      in: path
      required: true
      description: Copy the task's returned @id unchanged. New tasks use a 32-character hexadecimal UUID4; existing IDs with the task_ prefix remain supported.
      schema:
        type: string
        pattern: ^(?:task_)?[a-f0-9]{32}$
    Cursor:
      name: cursor
      in: query
      required: false
      schema:
        type: string
    Limit:
      name: limit
      in: query
      required: false
      schema:
        type: integer
        minimum: 1
        maximum: 100
        default: 50
    SourceId:
      name: sourceId
      in: path
      required: true
      schema:
        type: string
  schemas:
    JsonObject:
      type: object
      additionalProperties: true
    TaskStatus:
      type: string
      enum:
      - queued
      - running
      - stop_asked
      - completed
      - failed
      - stopped
      description: Active states are queued, running, and stop_asked. Terminal states are completed, failed,
        and stopped. A best-effort maxCredits stop can complete the task with partial results; a user
        cancellation ends in stopped unless a failure takes precedence.
    TaskErrorReason:
      type: string
      enum:
      - dispatch_failed
      - deadline_exceeded
      - worker_failed
      - enrichment_failed
      - credits_error
      description: Stable reason for a failed task.
    TaskFailure:
      type:
      - object
      - 'null'
      required:
      - reason
      - code
      - message
      - traceId
      properties:
        reason:
          $ref: '#/components/schemas/TaskErrorReason'
        code:
          type: string
        message:
          type: string
        traceId:
          type:
          - string
          - 'null'
      description: Null while active and on successful completion. Failed tasks contain safe failure details;
        stopped tasks retain any recorded failure. Trace ID is nullable for routine failures without a
        support trace.
    NullableTimestamp:
      type:
      - string
      - 'null'
      format: date-time
    NullableCursor:
      type:
      - string
      - 'null'
    Enrichment:
      type: object
      required:
      - '@id'
      - '@type'
      - name
      - description
      - schemaVersion
      - creditsPerInput
      - inputSchema
      - settingsSchema
      - outputSchema
      - limits
      properties:
        '@id':
          type: string
        '@type':
          type: string
          const: Enrichment
        name:
          type: string
        description:
          type: string
        schemaVersion:
          type: string
        creditsPerInput:
          type:
          - string
          - 'null'
          description: Fixed credit amount when known; null for variable-price actions. Actual usage is
            returned with task results.
        cost:
          type:
          - string
          - 'null'
          description: Human-readable pricing description. Null when unavailable; actual credit usage is returned with task results.
        inputSchema:
          $ref: '#/components/schemas/JsonObject'
          description: >-
            Describes each input data object. Properties can carry enableOnSetting rules
            and requiredWhenEnabled. Conditional required inputs are required only when
            the rule matches the submitted task settings; unconditional requirements use
            the ordinary required array. Supplied known fields are validated even when inactive.
        settingsSchema:
          $ref: '#/components/schemas/JsonObject'
          description: >-
            Describes known settings. Optional enableOnSetting annotations describe
            visibility in a configuration UI; they do not change settings validation.
            Additional settings remain accepted.
        outputSchema:
          $ref: '#/components/schemas/JsonObject'
          description: >-
            Descriptive snapshot of known outputs. Optional enableOnSetting annotations
            describe which fields are relevant to the submitted settings. Dynamic fields
            can be absent. Results omit legacy compatibility status fields and preserve
            other returned fields; enableOnSetting conditions never filter results.
        limits:
          $ref: '#/components/schemas/JsonObject'
    TaskInput:
      type: object
      additionalProperties: false
      required:
      - inputId
      - data
      properties:
        inputId:
          type: string
          minLength: 1
          maxLength: 128
          description: Caller-supplied UTF-8 correlation value, preserved unchanged.
        data:
          $ref: '#/components/schemas/JsonObject'
    CreateTaskRequest:
      type: object
      additionalProperties: false
      required:
      - enrichmentId
      - uniqueId
      - inputs
      properties:
        enrichmentId:
          type: string
          description: An authorized enrichment ID from catalog discovery.
        uniqueId:
          type: string
          minLength: 1
          maxLength: 128
          pattern: ^[A-Za-z0-9_-]+$
        settings:
          type: object
          additionalProperties: true
          description: Validated against the requested enrichment's settingsSchema from catalog discovery.
        inputs:
          type: array
          minItems: 1
          maxItems: 10000
          items:
            $ref: '#/components/schemas/TaskInput'
        maxCredits:
          type: string
          pattern: ^[0-9]+(\.[0-9]+)?$
          description: Optional best-effort stop threshold for the complete task. Omit for no limit; an
            explicit "0" stops after the first paid completion. Completed and already-started batches
            can exceed the threshold. Values use hundredth-credit precision; positive fractional hundredths
            are rounded upward. Account credits still apply when omitted; prices may vary and actual usage
            is reported in credits.used.
    Task:
      type: object
      required:
      - '@id'
      - '@type'
      - enrichmentId
      - uniqueId
      - status
      - error
      - createdAt
      - startedAt
      - finishedAt
      - progress
      - outcomes
      - credits
      - links
      - kind
      properties:
        '@id':
          type: string
        '@type':
          type: string
          const: EnrichmentTask
        enrichmentId:
          type: string
        uniqueId:
          type: string
          minLength: 1
          maxLength: 128
          pattern: ^[A-Za-z0-9_-]+$
        status:
          $ref: '#/components/schemas/TaskStatus'
        error:
          $ref: '#/components/schemas/TaskFailure'
        createdAt:
          type: string
          format: date-time
        startedAt:
          $ref: '#/components/schemas/NullableTimestamp'
        finishedAt:
          $ref: '#/components/schemas/NullableTimestamp'
        progress:
          type: object
          required:
          - totalInputs
          - finishedInputs
          properties:
            totalInputs:
              type: integer
              minimum: 1
              maximum: 10000
            finishedInputs:
              type: integer
              minimum: 0
              maximum: 10000
        outcomes:
          type: object
          required:
          - success
          - noResult
          - error
          - skipped
          properties:
            success:
              type: integer
              minimum: 0
            noResult:
              type: integer
              minimum: 0
            error:
              type: integer
              minimum: 0
            skipped:
              type: integer
              minimum: 0
        credits:
          type: object
          required:
          - used
          - max
          properties:
            used:
              type: string
              pattern: ^[0-9]+(\.[0-9]+)?$
            max:
              type:
              - string
              - 'null'
              pattern: ^[0-9]+(\.[0-9]+)?$
              description: Null when the caller omitted maxCredits (no limit).
        links:
          $ref: '#/components/schemas/JsonObject'
        kind:
          type: string
          const: enrichment
      description: Account-owned task metadata. Execution has a 24-hour deadline; metadata and results
        remain readable for 90 days after terminal state. Read results on completed, failed, or stopped
        tasks.
    StoredInput:
      type: object
      additionalProperties: false
      required:
      - inputId
      - data
      - inputIndex
      properties:
        inputId:
          type: string
          minLength: 1
          maxLength: 128
        data:
          $ref: '#/components/schemas/JsonObject'
        inputIndex:
          type: integer
          minimum: 0
    InputPage:
      type: object
      required:
      - taskId
      - settings
      - inputs
      - nextCursor
      properties:
        taskId:
          type: string
        settings:
          $ref: '#/components/schemas/JsonObject'
        inputs:
          type: array
          items:
            $ref: '#/components/schemas/StoredInput'
        nextCursor:
          $ref: '#/components/schemas/NullableCursor'
    PublicError:
      type:
      - object
      - 'null'
      properties:
        code:
          type: string
        message:
          type: string
    TaskResult:
      type: object
      required:
      - inputId
      - status
      - outputs
      - creditsUsed
      - error
      properties:
        inputId:
          type: string
        status:
          type: string
          enum:
          - success
          - no_result
          - error
          - skipped
        outputs:
          $ref: '#/components/schemas/JsonObject'
        creditsUsed:
          type: string
          pattern: ^[0-9]+(\.[0-9]+)?$
          description: Uses hundredth-credit precision, rounded upward.
        error:
          $ref: '#/components/schemas/PublicError'
    ResultPage:
      type: object
      required:
      - taskId
      - results
      - nextCursor
      properties:
        taskId:
          type: string
        results:
          type: array
          items:
            $ref: '#/components/schemas/TaskResult'
        nextCursor:
          $ref: '#/components/schemas/NullableCursor'
    Error:
      type: object
      required:
      - http_status
      - code
      - description
      properties:
        http_status:
          type: integer
        code:
          type: string
        description:
          type: string
        trace_id:
          type:
          - string
          - 'null'
    Source:
      type: object
      required:
      - '@id'
      - '@type'
      - name
      - description
      - schemaVersion
      - settingsSchema
      - outputSchema
      - limits
      properties:
        '@id':
          type: string
        '@type':
          type: string
          const: Source
        name:
          type: string
        description:
          type: string
        cost:
          type:
          - string
          - 'null'
          description: Human-readable pricing description. Null when unavailable; actual credit usage is returned with task results.
        schemaVersion:
          type: string
        settingsSchema:
          $ref: '#/components/schemas/JsonObject'
          description: >-
            Describes known settings. Optional enableOnSetting annotations describe
            visibility in a configuration UI; they do not change settings validation.
            Additional settings remain accepted.
        outputSchema:
          $ref: '#/components/schemas/JsonObject'
          description: >-
            Descriptive snapshot of known outputs. Optional enableOnSetting annotations
            describe which fields are relevant to the submitted settings. Dynamic fields
            can be absent. Results omit legacy compatibility status fields and preserve
            other returned fields; enableOnSetting conditions never filter results.
        limits:
          type: object
          properties:
            executionDeadlineSeconds:
              type: integer
    CreateSourceTaskRequest:
      type: object
      additionalProperties: false
      required:
      - sourceId
      - uniqueId
      properties:
        uniqueId:
          type: string
          minLength: 1
          maxLength: 128
          pattern: ^[A-Za-z0-9_-]+$
        settings:
          type: object
          additionalProperties: true
          description: Validated against the requested source's settingsSchema from catalog discovery.
        maxCredits:
          type: string
          pattern: ^[0-9]+(\.[0-9]+)?$
          description: Optional best-effort stop threshold for the complete task. Omit for no limit; an
            explicit "0" stops after the first paid completion. Completed and already-started batches
            can exceed the threshold. Values use hundredth-credit precision; positive fractional hundredths
            are rounded upward. Account credits still apply when omitted; prices may vary and actual usage
            is reported in credits.used.
        sourceId:
          type: string
          description: An authorized source ID from catalog discovery.
    SourceTask:
      type: object
      required:
      - '@id'
      - '@type'
      - uniqueId
      - status
      - createdAt
      - startedAt
      - finishedAt
      - progress
      - credits
      - links
      - kind
      - sourceId
      - error
      properties:
        '@id':
          type: string
        '@type':
          type: string
          const: SourceTask
        uniqueId:
          type: string
          minLength: 1
          maxLength: 128
          pattern: ^[A-Za-z0-9_-]+$
        status:
          $ref: '#/components/schemas/TaskStatus'
        createdAt:
          type: string
          format: date-time
        startedAt:
          $ref: '#/components/schemas/NullableTimestamp'
        finishedAt:
          $ref: '#/components/schemas/NullableTimestamp'
        progress:
          type: object
          required:
          - results
          properties:
            results:
              type: integer
              minimum: 0
          description: Number of generated objects recorded so far.
        credits:
          type: object
          required:
          - used
          - max
          properties:
            used:
              type: string
              pattern: ^[0-9]+(\.[0-9]+)?$
            max:
              type:
              - string
              - 'null'
              pattern: ^[0-9]+(\.[0-9]+)?$
              description: Null when the caller omitted maxCredits (no limit).
        links:
          $ref: '#/components/schemas/JsonObject'
        kind:
          type: string
          const: source
        sourceId:
          type: string
        error:
          $ref: '#/components/schemas/TaskFailure'
      description: Account-owned task metadata. Execution has a 24-hour deadline; metadata and results
        remain readable for 90 days after terminal state. Read results on completed, failed, or stopped
        tasks.
    SourceResultPage:
      type: object
      required:
      - taskId
      - results
      - nextCursor
      properties:
        taskId:
          type: string
        results:
          type: array
          items:
            $ref: '#/components/schemas/JsonObject'
        nextCursor:
          $ref: '#/components/schemas/NullableCursor'
  responses:
    DispatchFailed:
      description: Queue submission failed; the unaccepted task is failed and uniqueId can be reused
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Unauthorized:
      description: Missing, invalid, or expired access token
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Forbidden:
      description: Missing permission
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    NotFound:
      description: Missing, expired, or inaccessible resource
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Conflict:
      description: Duplicate active uniqueId or results not ready
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    PayloadTooLarge:
      description: Request exceeds 10 MiB
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Unprocessable:
      description: Unsupported enrichment or invalid schema
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    RateLimited:
      description: Rate or best effort active-task admission limit reached
      headers:
        Retry-After:
          schema:
            type: integer
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
