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

# List pending interactions

> The pending questions the inbox shows, one page at a time — the initial-load
surface a client reads BEFORE applying the live stream
(``GET /api/interactions/stream``).

Order is the store's pending order (each group's most-recent question ``created_at``,
then stream order within a group). A RESTRICTED caller sees ONLY questions addressed
to its identity — the audience filter runs BEFORE paging so ``total`` is honest; an
UNRESTRICTED caller sees every pending question. A ``page`` or ``page_size`` below 1,
or a ``page`` above the served maximum, is a 400; a ``page_size`` above the cap is
capped, never refused. The pending read reconciles phantom/abandoned questions as it
goes (phantom-group prune, abandoned past-deadline prune, answered/missing skip). Returns
``{"items", "total", "page", "page_size", "next_page", "truncated"}`` — ``items``
carry the same shape as the stream's add frames, and ``truncated`` is always
``false`` (the pending index is the whole set, sliced in memory).



## OpenAPI

````yaml /openapi.json get /api/interactions
openapi: 3.1.0
info:
  description: The operator HTTP surface served under /api/*.
  title: tai42-skeleton API
  version: 14.0.2
servers: []
security: []
paths:
  /api/interactions:
    get:
      tags:
        - interactions
      summary: List pending interactions
      description: >-
        The pending questions the inbox shows, one page at a time — the
        initial-load

        surface a client reads BEFORE applying the live stream

        (``GET /api/interactions/stream``).


        Order is the store's pending order (each group's most-recent question
        ``created_at``,

        then stream order within a group). A RESTRICTED caller sees ONLY
        questions addressed

        to its identity — the audience filter runs BEFORE paging so ``total`` is
        honest; an

        UNRESTRICTED caller sees every pending question. A ``page`` or
        ``page_size`` below 1,

        or a ``page`` above the served maximum, is a 400; a ``page_size`` above
        the cap is

        capped, never refused. The pending read reconciles phantom/abandoned
        questions as it

        goes (phantom-group prune, abandoned past-deadline prune,
        answered/missing skip). Returns

        ``{"items", "total", "page", "page_size", "next_page", "truncated"}`` —
        ``items``

        carry the same shape as the stream's add frames, and ``truncated`` is
        always

        ``false`` (the pending index is the whole set, sliced in memory).
      operationId: get_api_interactions
      parameters:
        - description: 1-based page number, pending order.
          in: query
          name: page
          required: false
          schema:
            default: 1
            maximum: 1000000
            minimum: 1
            title: Page
            type: integer
        - description: Items per page. A larger value is capped to 200, never refused.
          in: query
          name: pageSize
          required: false
          schema:
            default: 50
            minimum: 1
            title: Pagesize
            type: integer
      responses:
        '200':
          content:
            application/json:
              schema:
                properties:
                  data:
                    $ref: '#/components/schemas/InteractionWindow'
                required:
                  - data
                type: object
          description: Success.
        '400':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
          description: Malformed request.
        '401':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
          description: Missing or invalid api key.
      security:
        - ApiKeyAuth: []
components:
  schemas:
    InteractionWindow:
      description: >-
        One page of pending questions. ``truncated`` is always false (the
        pending

        index is the whole set, sliced in memory); ``next_page`` is ``null`` on
        the

        last page.
      properties:
        items:
          items:
            $ref: '#/components/schemas/InteractionFrame'
          title: Items
          type: array
        next_page:
          anyOf:
            - type: integer
            - type: 'null'
          default: null
          title: Next Page
        page:
          title: Page
          type: integer
        page_size:
          title: Page Size
          type: integer
        total:
          title: Total
          type: integer
        truncated:
          title: Truncated
          type: boolean
      required:
        - items
        - total
        - page
        - page_size
        - truncated
      title: InteractionWindow
      type: object
    Error:
      properties:
        code:
          description: >-
            Stable machine-readable reason a client keys a dedicated error state
            on, present on refusals that opt in (e.g. a 501 not-configured
            refusal). Optional: absent when the error carries only a
            human-readable message.
          type: string
        error:
          type: string
      required:
        - error
      type: object
    InteractionFrame:
      description: >-
        One pending question's client add-frame (the paged list door and the
        live

        tail share it). ``format_payload`` is the verifier-stripped,
        otherwise-open

        payload (``null`` when the question carries none). ``server_verified``
        rides

        ONLY when a verifier was stripped; ``channel``/``recipient``/``origin``/

        ``audience``/``media`` ride only when the question set them (absent
        otherwise).
      properties:
        answer_format:
          title: Answer Format
          type: string
        audience:
          anyOf:
            - type: string
            - type: 'null'
          default: null
          title: Audience
        channel:
          anyOf:
            - type: string
            - type: 'null'
          default: null
          title: Channel
        created_at:
          title: Created At
          type: string
        format_payload:
          $ref: '#/components/schemas/JsonValue'
        group_id:
          title: Group Id
          type: string
        interaction_id:
          title: Interaction Id
          type: string
        media:
          anyOf:
            - items:
                $ref: '#/components/schemas/MediaItem'
              type: array
            - type: 'null'
          default: null
          title: Media
        origin:
          anyOf:
            - type: string
            - type: 'null'
          default: null
          title: Origin
        question:
          title: Question
          type: string
        recipient:
          anyOf:
            - type: string
            - type: 'null'
          default: null
          title: Recipient
        sensitive:
          title: Sensitive
          type: boolean
        server_verified:
          anyOf:
            - type: boolean
            - type: 'null'
          default: null
          title: Server Verified
        timeout_at:
          title: Timeout At
          type: string
      required:
        - interaction_id
        - group_id
        - question
        - answer_format
        - format_payload
        - created_at
        - timeout_at
        - sensitive
      title: InteractionFrame
      type: object
    JsonValue: {}
    MediaItem:
      description: >-
        One media item shown WITH a message — a display element, and inbound the
        shape a participant's

        sent media takes.


        ``kind`` selects how it renders: an ``image`` inline, a
        ``document``/``video``/``audio`` as

        the matching file bubble, a ``link`` as a labelled anchor. ``url`` is
        the source. A file

        kind (``image``/``document``/``video``/``audio``) must be an absolute
        ``https`` URL, a

        same-origin ``{MEDIA_ROUTE_PREFIX}{id}`` reference to media the skeleton
        serves by id, or an

        absolute ``http(s)`` served reference of that same
        ``{MEDIA_ROUTE_PREFIX}{id}`` path a

        channel send mints from ``public_base_url`` (remote file media is
        https-only: the inbox CSP

        ``img-src`` admits ``https:``/``data:`` and same-origin but not
        ``http:``, so an ``http:``

        remote source would be an unrenderable record); ``image`` ADDITIONALLY
        admits an inline

        ``data:image/*`` URI — that inline form is image-only, a ``data:`` URI
        on any other file

        kind is refused. A ``link`` must be an absolute ``http(s)`` URL (anchors
        are not governed by

        ``img-src``; the human clicks through). A remote url names a host
        directly — an ASCII DNS

        name, dotted-quad IPv4, or bracketed IPv6 (IDN callers supply punycode);
        an embedded

        ``user@`` credential form is rejected as it spoofs the authority — and
        is always a single

        line — raw whitespace and control/format characters are rejected.
        ``caption`` is the

        accessibility text — the image's alt text, a file's label, or the link's
        display label.

        ``filename`` is the document's suggested display name; it is meaningful
        ONLY for a

        ``document`` item and is refused on every other kind.
      properties:
        caption:
          anyOf:
            - type: string
            - type: 'null'
          default: null
          title: Caption
        filename:
          anyOf:
            - type: string
            - type: 'null'
          default: null
          title: Filename
        kind:
          $ref: '#/components/schemas/MediaKind'
        url:
          title: Url
          type: string
      required:
        - kind
        - url
      title: MediaItem
      type: object
    MediaKind:
      enum:
        - image
        - link
        - document
        - video
        - audio
      title: MediaKind
      type: string
  securitySchemes:
    ApiKeyAuth:
      in: header
      name: x-api-key
      type: apiKey

````