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

# List DataForms audit history

> Returns the paginated audit history for a single DataForms. Snapshots (`beforeSnapshot`, `afterSnapshot`) are excluded by default — opt in with `?include=beforeSnapshot,afterSnapshot`. Standard query DSL applies (filter, sort, page, pageSize). The default sort is `createdOn:desc`.



## OpenAPI

````yaml /api-reference/api-docs.yaml get /api/data-forms/{id}/audit
openapi: 3.0.1
info:
  title: Kodexa AI
  description: >-
    The Kodexa platform API provides programmatic access to document processing,
    intelligent automation, and data extraction capabilities. Use this API to
    manage organizations, projects, document stores, taxonomies, assistants, and
    processing pipelines. All endpoints require authentication via API key,
    Bearer token, or Basic auth.
  version: 8.0.0
  license:
    name: Commercial
    url: https://kodexa.ai
servers:
  - url: https://platform.kodexa.ai
    description: Production
  - url: http://localhost:8080
    description: Local development
security:
  - x-api-key: []
  - bearerAuth: []
tags:
  - name: AI Gateway
  - name: AccessTokens
    description: Manage API access tokens for programmatic authentication.
  - name: Account
    description: Account management endpoints for the authenticated user.
  - name: Activities
  - name: ActivityDocumentFamilies
  - name: ActivityPlans
  - name: Agent Runtimes
    description: Manage agent runtime definitions backed by AWS Bedrock AgentCore.
  - name: Agent Sessions
    description: View and manage stateful conversation sessions within agent runtimes.
  - name: Agents
    description: Manage agents — instantiated agent runtimes within an org+project.
  - name: Analytics
  - name: Applied Knowledge
    description: Manage applied knowledge instances used during document processing.
  - name: Applied Knowledge Sets
    description: Manage applied knowledge set configurations.
  - name: Assistants
    description: Manage AI assistants that process and analyze documents within a project.
  - name: Batch Updates
    description: Batch document update operations for efficient bulk processing.
  - name: Channel
    description: Manage messaging channels for real-time communication within the platform.
  - name: Channel Types
  - name: Content Exception
    description: View and manage content exceptions that occur during document processing.
  - name: Content Object
    description: >-
      Manage content objects — individual files or processing results within a
      document family.
  - name: Credit Transactions
    description: View and manage credit transactions for organization billing.
  - name: Data Definitions
    description: >-
      Manage data definitions (taxonomies) that define document structure and
      extraction rules.
  - name: Data Forms
    description: Manage data form definitions for structured data capture from documents.
  - name: Data Stores
    description: Manage data stores for structured data storage.
  - name: Document Assignments
    description: Manage document assignments linking document families to users for review.
  - name: Document Family Statistics
    description: View statistics about document families including processing metrics.
  - name: Document Statuses
    description: >-
      Manage document status definitions for tracking document processing
      states.
  - name: Document Stores
    description: >-
      Manage document stores — containers for organizing and processing
      documents within a project.
  - name: Document Transitions
    description: Track state transitions of documents through processing stages.
  - name: DocumentFamilies
    description: >-
      Manage document families — groups of related content objects representing
      a single logical document.
  - name: Events
    description: >-
      Manage and publish platform events for real-time notifications and
      integrations.
  - name: Execution Slices
    description: View execution slice details within pipeline executions.
  - name: Executions
    description: View and manage processing execution records.
  - name: Intakes
    description: >-
      Manage intake configurations for ingesting documents from external
      sources.
  - name: Knowledge Clause Features
    description: Manage features within knowledge clauses.
  - name: Knowledge Clauses
    description: Manage knowledge clauses within knowledge items.
  - name: Knowledge Feature Types
    description: Manage knowledge feature type definitions.
  - name: Knowledge Features
    description: >-
      Manage knowledge features representing specific data points within
      knowledge items.
  - name: Knowledge Item Types
    description: Manage knowledge item type definitions.
  - name: Knowledge Items
    description: Manage individual knowledge items within knowledge sets.
  - name: Knowledge Set Snapshots
    description: Manage snapshots of knowledge sets for versioning and comparison.
  - name: Knowledge Set Sources
    description: Manage source references for knowledge sets.
  - name: Knowledge Sets
    description: >-
      Manage knowledge sets — collections of extracted knowledge used for
      AI-assisted processing.
  - name: Labels
    description: >-
      Manage labels used for categorizing and tagging resources within an
      organization.
  - name: Linked Deltas
    description: Manage linked deltas representing changes between document versions.
  - name: Messages
    description: Manage messages within channels.
  - name: Model Costs
  - name: Module Runtimes
    description: Manage module runtime definitions within the orchestrator.
  - name: Modules
  - name: Orchestrator Modules
    description: Manage processing modules for orchestrator pipelines.
  - name: Organizations
    description: >-
      Manage organizations — the top-level tenant in Kodexa. All projects,
      stores, and resources belong to an organization.
  - name: Permissions
  - name: Platform Configuration
    description: Manage platform-wide configuration settings.
  - name: Platform Overview
    description: Platform configuration and overview endpoints.
  - name: Product Groups
    description: Manage product groups that bundle related products together.
  - name: Product Overview
    description: Browse and manage products available on the Kodexa platform.
  - name: Product Subscriptions
    description: Manage product subscriptions linking organizations to products.
  - name: ProductProjectTemplates
    description: >-
      Manage product project templates that define default project
      configurations.
  - name: Project Resources
  - name: Project Status
    description: Manage project status definitions for tracking project lifecycle.
  - name: Project Templates
    description: Manage project templates that define reusable project configurations.
  - name: Projects
    description: >-
      Manage projects within an organization. Projects group related document
      stores, assistants, tasks, and processing pipelines.
  - name: Prompts
    description: Manage prompt templates used by AI assistants for document processing.
  - name: Purge Items
    description: Manage purge items for scheduled content cleanup.
  - name: Recent Executions
    description: View recent execution history for document processing.
  - name: Resource Resolution
  - name: Role Permissions
  - name: Roles
  - name: Service Bridges
  - name: Sessions
    description: Manage processing sessions for document operations.
  - name: Step Executions
    description: View step-level execution details within pipeline executions.
  - name: Tag Metadata
    description: Manage tag metadata definitions for document labeling and categorization.
  - name: Task Groups
  - name: Task Statuses
    description: Manage task status definitions for tracking task workflow states.
  - name: TaskActivity
    description: Track activity history on tasks, including status changes and comments.
  - name: TaskDocumentFamilies
    description: Manage the association between tasks and document families.
  - name: TaskGroupHistory
  - name: TaskTemplates
    description: Manage task templates that define reusable task configurations.
  - name: Tasks
    description: >-
      Manage tasks for document review workflows. Tasks have assignees,
      statuses, due dates, and can contain document families.
  - name: Team Members
    description: Manage team membership assignments.
  - name: Team Org Assignments
  - name: Team Project Assignments
  - name: Teams
    description: Manage teams for collaborative access control within projects.
  - name: Triggers
  - name: Users
    description: Manage platform user accounts.
  - name: Workspaces
    description: Manage workspaces for organizing project resources.
externalDocs:
  description: Kodexa Developer Documentation
  url: https://developer.kodexa.ai
paths:
  /api/data-forms/{id}/audit:
    get:
      tags:
        - Data Forms
      summary: List DataForms audit history
      description: >-
        Returns the paginated audit history for a single DataForms. Snapshots
        (`beforeSnapshot`, `afterSnapshot`) are excluded by default — opt in
        with `?include=beforeSnapshot,afterSnapshot`. Standard query DSL applies
        (filter, sort, page, pageSize). The default sort is `createdOn:desc`.
      operationId: listDataFormsAudit
      parameters:
        - name: page
          in: query
          description: Page number (1-indexed). Defaults to 1.
          schema:
            type: integer
            format: int32
          example: 1
        - name: pageSize
          in: query
          description: Number of items per page (1-1000). Defaults to 20, maximum 1000.
          schema:
            type: integer
            format: int32
          example: 20
        - name: sort
          in: query
          description: >-
            Sort expression as `field,direction`. Direction is `asc` or `desc`.
            Multiple sort fields can be specified by repeating the parameter.
          schema:
            type: string
          example: name,asc
        - name: filter
          in: query
          description: >-
            RSQL/FIQL filter expression. Supported operators: `==` (equals),
            `!=` (not equals), `=like=` (contains), `=in=` (in list), `>` / `>=`
            / `<` / `<=` (comparison), `=isnull=true` (is null), `=isnull=false`
            (is not null). Combine with `;` (AND) or `,` (OR). Example:
            `name=='Acme Corp';status==active`
          schema:
            type: string
          example: name=='Acme Corp'
        - name: query
          in: query
          description: >-
            Full-text search query matching against the entity's searchable
            fields.
          schema:
            type: string
          example: invoice
        - name: id
          in: path
          description: Unique identifier (UUID) of the resource.
          required: true
          schema:
            type: string
            format: uuid
          example: 550e8400-e29b-41d4-a716-446655440000
        - name: include
          in: query
          description: >-
            Comma-separated list of optional fields to include in the response.
            Supported values: `beforeSnapshot`, `afterSnapshot`. Both are
            excluded by default because they can be large.
          schema:
            type: string
          example: beforeSnapshot,afterSnapshot
      responses:
        '200':
          description: Page of DataForms audit entries.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PageAuditEntry'
        '400':
          description: Bad Request — the request body or parameters are invalid.
        '401':
          description: Unauthorized — authentication is required.
        '403':
          description: Forbidden — the authenticated user does not have permission.
        '404':
          description: >-
            Not Found — no resource exists with the given ID, or the caller does
            not have read access to it.
components:
  schemas:
    PageAuditEntry:
      type: object
      properties:
        content:
          type: array
          items:
            $ref: '#/components/schemas/AuditEntry'
          description: >-
            Audit entries on this page, oldest-first or newest-first depending
            on the `sort` parameter (default is `createdOn:desc`).
        first:
          type: boolean
          description: Whether this is the first page.
        last:
          type: boolean
          description: Whether this is the last page.
        number:
          type: integer
          format: int32
          description: Current page number (0-indexed).
        numberOfElements:
          type: integer
          format: int32
          description: Number of items on the current page.
        pageable:
          $ref: '#/components/schemas/PageableObject'
          description: Pagination metadata.
        size:
          type: integer
          format: int32
          description: Page size (number of items per page).
        sort:
          $ref: '#/components/schemas/SortObject'
          description: Sort metadata.
        totalElements:
          type: integer
          format: int64
          description: Total audit entries across all pages for this entity.
        totalPages:
          type: integer
          format: int32
          description: Total number of pages.
      description: Paginated response containing audit entries.
    AuditEntry:
      type: object
      properties:
        action:
          $ref: '#/components/schemas/AuditAction'
          description: The audit-loggable operation.
        afterSnapshot:
          type: object
          description: >-
            Post-change entity snapshot. Null on DELETE. Excluded by default —
            pass `?include=afterSnapshot` to receive it.
        beforeSnapshot:
          type: object
          description: >-
            Pre-change entity snapshot. Null on CREATE. Excluded by default —
            pass `?include=beforeSnapshot` to receive it.
        changeSequence:
          type: integer
          format: int32
          description: >-
            The entity's `changeSequence` at the moment of the change. Matches
            AbstractMetadata.ChangeSequence and bumps once per UPDATE.
        createdOn:
          type: string
          format: date-time
          description: When the audit row was inserted (server clock).
        entityId:
          type: string
          format: uuid
          description: ID of the audited entity.
        entitySlug:
          type: string
          description: Slug of the audited entity at the moment of the change.
        entityType:
          type: string
          description: >-
            Polymorphic discriminator (e.g. `module`, `taxonomy`,
            `task-template`). Matches the URL path segment of the parent
            resource.
        id:
          type: string
          format: uuid
          description: Unique identifier for the audit row.
        ipAddress:
          type: string
          description: >-
            Resolved client IP per the trusted-proxy chain. May be nullable
            after a GDPR scrub.
        ipTrustLevel:
          type: string
          description: How the IP was determined (`direct`, `trusted_proxy`, `untrusted`).
        metadata:
          type: object
          description: >-
            Free-form per-action metadata (e.g. attachment names, child action
            descriptors). Optional.
        requestId:
          type: string
          description: >-
            Per-request correlation ID; matches the chi RequestID middleware
            value.
        userAgent:
          type: string
          description: >-
            User-Agent header as seen at the request boundary. May be nullable
            after a GDPR scrub.
        userEmail:
          type: string
          description: >-
            Actor email at the time of the change. May be nullable after a GDPR
            scrub.
        userId:
          type: string
          description: >-
            Actor ID, prefixed `user:` or `system:` (e.g. `user:550e8400…` or
            `system:scheduler`).
        userRoles:
          type: array
          items:
            type: string
          description: Roles held by the actor at the time of the change.
      description: >-
        A single row from the metadata audit log. Each row records one CREATE,
        UPDATE, DELETE, or attachment change on an audited AbstractMetadata
        entity. Append-only at the database level — no row is ever modified or
        removed in flight (the GDPR-scrub path is the only override and runs via
        a privileged code path).
    PageableObject:
      type: object
      properties:
        offset:
          type: integer
          format: int64
          description: Offset from the beginning of the result set.
        pageNumber:
          type: integer
          format: int32
          description: Current page number (0-indexed).
        pageSize:
          type: integer
          format: int32
          description: Number of items per page.
        paged:
          type: boolean
          description: Whether pagination is active.
        sort:
          $ref: '#/components/schemas/SortObject'
          description: Sort metadata.
        unpaged:
          type: boolean
          description: Whether the result is unpaged (all results returned).
      description: Pagination parameters describing the current page position.
    SortObject:
      type: object
      properties:
        empty:
          type: boolean
          description: Whether the sort is empty (no sort criteria specified).
        sorted:
          type: boolean
          description: Whether sorting is active.
        unsorted:
          type: boolean
          description: Whether results are unsorted.
      description: Sort metadata describing the current sort state.
    AuditAction:
      type: string
      enum:
        - CREATE
        - UPDATE
        - DELETE
        - ATTACHMENT_ADDED
        - ATTACHMENT_REPLACED
        - ATTACHMENT_REMOVED
  securitySchemes:
    x-api-key:
      type: apiKey
      name: x-api-key
      in: header
      description: >-
        API key for authentication. Create one from the Kodexa platform UI under
        Settings > Access Tokens.
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: JWT Bearer token obtained from the authentication provider.

````