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

# List baseline item history

> The package's baseline row history, newest first: custom rows created / deleted and every row edit. Entries of deleted rows stay listed. Fields hidden from the role are left out.



## OpenAPI

````yaml /openapi.yaml post /projects/{project_id}/packages/{package_id}/baseline_items/history
openapi: 3.0.1
info:
  title: GetSpecs REST API
  description: REST API documentation for GetSpecs.
  version: 1.0.0
servers:
  - url: /v1
  - url: https://demo-api.getspecs.io/v1
security: []
paths:
  /projects/{project_id}/packages/{package_id}/baseline_items/history:
    post:
      tags:
        - BaselineItem
      summary: List baseline item history
      description: >-
        The package's baseline row history, newest first: custom rows created /
        deleted and every row edit. Entries of deleted rows stay listed. Fields
        hidden from the role are left out.
      operationId: baseline_items#history
      parameters:
        - name: X-Workspace-ID
          in: header
          required: true
          schema:
            type: string
        - name: project_id
          in: path
          required: true
          schema:
            type: integer
        - name: package_id
          in: path
          required: true
          schema:
            type: integer
        - name: page
          in: query
          required: false
          schema:
            type: integer
        - name: per_page
          in: query
          required: false
          schema:
            type: integer
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/requestBodyBaselineItemHistory'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/baseline_item_history_collection'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/error'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/error'
      security:
        - apiKey: []
          workspaceId: []
components:
  schemas:
    requestBodyBaselineItemHistory:
      type: object
      properties:
        ids:
          type: array
          description: >-
            Narrow to these baseline rows (deleted rows included). Omit for the
            whole package.
          items:
            type: integer
        created_at_from:
          type: string
          format: date-time
        created_at_to:
          type: string
          format: date-time
    baseline_item_history_collection:
      type: object
      properties:
        item_histories:
          type: array
          items:
            $ref: '#/components/schemas/baseline_item_history'
    error:
      type: object
      properties:
        error:
          type: string
        errors:
          type: array
          items:
            type: object
            properties:
              field:
                type: string
                nullable: true
              code:
                type: string
                nullable: true
              message:
                type: string
            required:
              - message
    baseline_item_history:
      type: object
      properties:
        id:
          type: integer
        entity_type:
          type: string
          enum:
            - PackageBaselineItem
        entity_id:
          type: integer
          description: >-
            The baseline row. It may have been deleted since (`action`
            `destroyed`).
        action:
          type: string
          enum:
            - created
            - updated
            - destroyed
        identifier:
          type: string
          nullable: true
          description: >-
            The row's current identifier, or for a deleted row the last one it
            logged.
        column_changes:
          type: object
          description: >-
            Changed fields by baseline field group (`identifier`, `name`,
            `category`, `package_section`, `description`, `unit_type`,
            `supplier`, `image`, `quantity`, `unit_cost_price`, `cost_price`,
            `client_price`), each `{ from, to }`. Values are display values —
            category path, section path, supplier company name, image file name,
            numbers as 2-decimal strings; null = blank. `created` entries list
            every non-blank field from null, `destroyed` ones to null. Fields
            hidden from the current user's role are left out.
          additionalProperties:
            type: object
            properties:
              from:
                nullable: true
              to:
                nullable: true
        has_hidden_changes:
          type: boolean
          description: The entry also changed fields hidden from the current user's role.
        created_at:
          type: string
          format: date-time
        user:
          type: object
          nullable: true
          properties:
            id:
              type: integer
            first_name:
              type: string
              nullable: true
            last_name:
              type: string
              nullable: true
            email:
              type: string
            logo_url:
              type: string
              nullable: true
  securitySchemes:
    apiKey:
      type: apiKey
      name: authorization
      in: header
    workspaceId:
      type: apiKey
      name: X-Workspace-ID
      in: header

````

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