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

# Agent understanding history

> Read the version history of one agent’s understanding, with a selected version’s Mermaid diagram.



## OpenAPI

````yaml https://api.uselemma.ai/openapi.json get /projects/{project_id}/agent-understanding/history
openapi: 3.1.0
info:
  title: Lemma Platform API
  description: Lemma Platform HTTP API for AI observability and workspace operations.
  version: 0.1.0
servers:
  - url: https://api.uselemma.ai
    description: Lemma production API
security:
  - bearerAuth: []
paths:
  /projects/{project_id}/agent-understanding/history:
    get:
      tags:
        - Artifacts
      summary: Agent understanding history
      description: >-
        Read the version history of one agent’s understanding, with a selected
        version’s Mermaid diagram.
      operationId: get_agent_understanding_history
      parameters:
        - name: project_id
          in: path
          required: true
          description: Project ID
          schema:
            type: string
        - name: agent_name
          in: query
          required: true
          description: Required agent name; an empty value selects the untagged agent.
          schema:
            type: string
        - name: version
          in: query
          required: false
          description: Positive version number; omit to select the latest.
          schema:
            type: integer
            minimum: 1
      responses:
        '200':
          description: Understanding version history and diagram metadata
          content:
            application/json:
              schema:
                type: object
                properties:
                  versions:
                    type: array
                    items:
                      type: object
                      properties:
                        artifact_version_id:
                          type: string
                          format: uuid
                        version:
                          type: number
                        agent_name:
                          type:
                            - string
                            - 'null'
                        created_at:
                          type: string
                          format: date-time
                        updated_at:
                          type: string
                          format: date-time
                      required:
                        - artifact_version_id
                        - version
                        - agent_name
                        - created_at
                        - updated_at
                      additionalProperties: false
                  selected_version:
                    type:
                      - object
                      - 'null'
                    properties:
                      artifact_version_id:
                        type: string
                        format: uuid
                      version:
                        type: number
                      agent_name:
                        type:
                          - string
                          - 'null'
                      mermaid:
                        type: string
                      created_at:
                        type: string
                        format: date-time
                      updated_at:
                        type: string
                        format: date-time
                    required:
                      - artifact_version_id
                      - version
                      - agent_name
                      - mermaid
                      - created_at
                      - updated_at
                    additionalProperties: false
                required:
                  - versions
                  - selected_version
                additionalProperties: false
        '400':
          description: Bad request
          content:
            application/json:
              schema:
                type: object
                properties:
                  detail:
                    type: string
                  code:
                    type: string
                  retryable:
                    type: boolean
                  retry_after_seconds:
                    type: number
                    minimum: 0
                required:
                  - detail
                  - code
                  - retryable
                additionalProperties: false
        '401':
          description: Unauthenticated
          content:
            application/json:
              schema:
                type: object
                properties:
                  detail:
                    type: string
                  code:
                    type: string
                required:
                  - detail
                additionalProperties: false
        '404':
          description: Not found
          content:
            application/json:
              schema:
                type: object
                properties:
                  detail:
                    type: string
                  code:
                    type: string
                  retryable:
                    type: boolean
                  retry_after_seconds:
                    type: number
                    minimum: 0
                required:
                  - detail
                  - code
                  - retryable
                additionalProperties: false
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                type: object
                properties:
                  detail:
                    type: string
                  code:
                    type: string
                  retryable:
                    type: boolean
                  retry_after_seconds:
                    type: number
                    minimum: 0
                required:
                  - detail
                  - code
                  - retryable
                additionalProperties: false
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````

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