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

# Get Application Demo Detail

> Return the demo record plus the live picture of its namespace on the staging cluster: the derived provisioning steps, the bill of materials, the namespace's Kubernetes events, and the pod/container names that drive the log viewer. A malformed workspace_id is reported as the same 404 as an unknown demo. A browser session twin is mounted at the same path without the /api/v1 prefix (cookie authentication).



## OpenAPI

````yaml https://platform.ankra.app/openapi.json get /api/v1/org/applications/{application_id}/demos/{workspace_id}/detail
openapi: 3.1.0
info:
  title: FastAPI
  version: 0.1.0
servers:
  - url: https://platform.ankra.app
security: []
paths:
  /api/v1/org/applications/{application_id}/demos/{workspace_id}/detail:
    get:
      tags:
        - Applications API
      summary: Get Application Demo Detail
      description: >-
        Return the demo record plus the live picture of its namespace on the
        staging cluster: the derived provisioning steps, the bill of materials,
        the namespace's Kubernetes events, and the pod/container names that
        drive the log viewer. A malformed workspace_id is reported as the same
        404 as an unknown demo. A browser session twin is mounted at the same
        path without the /api/v1 prefix (cookie authentication).
      operationId: >-
        get_application_demo_detail_api_v1_org_applications__application_id__demos__workspace_id__detail_get
      parameters:
        - in: path
          name: application_id
          required: true
          schema:
            title: Application Id
            type: string
        - in: path
          name: workspace_id
          required: true
          schema:
            format: uuid
            type: string
            title: Workspace Id
        - in: header
          name: authorization
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Authorization
        - in: header
          name: x-ankra-organisation-id
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: X-Ankra-Organisation-Id
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApplicationDemoDetailResponse'
          description: Successful Response
        '401':
          description: Unauthorized
        '404':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DemoDetailError'
          description: Not found ("Unknown demo for this application")
        '422':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
          description: Validation Error
components:
  schemas:
    ApplicationDemoDetailResponse:
      description: >-
        The demo record plus the live picture of its namespace on the staging
        cluster.
      properties:
        can_deploy:
          type: boolean
        demo:
          $ref: '#/components/schemas/DemoWorkspace'
        inspection:
          $ref: '#/components/schemas/DemoInspection'
        staging:
          $ref: '#/components/schemas/DemoStagingStatus'
      required:
        - demo
        - inspection
        - staging
        - can_deploy
      type: object
    DemoDetailError:
      description: >-
        The FastAPI-style detail envelope the demo routes use for
        400/403/404/409/502 responses.
      properties:
        detail:
          type: string
      required:
        - detail
      type: object
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          title: Detail
          type: array
      title: HTTPValidationError
      type: object
    DemoWorkspace:
      description: >-
        One ephemeral PR or branch demo record. kind is pr_demo or branch_demo;
        status is one of pending, provisioning, ready, failed, tearing_down,
        destroyed.
      properties:
        application_id:
          anyOf:
            - type: string
            - type: 'null'
        branch:
          anyOf:
            - type: string
            - type: 'null'
        cluster_id:
          anyOf:
            - type: string
            - type: 'null'
        component:
          anyOf:
            - type: string
            - type: 'null'
          description: >-
            The deployable component this demo runs; null for rows predating
            component records.
        container_port:
          anyOf:
            - type: integer
            - type: 'null'
        created_at:
          format: date-time
          type: string
        created_by_user_id:
          type: string
        database:
          type: boolean
        detected_container_port:
          anyOf:
            - type: integer
            - type: 'null'
          description: >-
            The port the readiness reconciler's log parser saw the container
            announce; set with port_corrected_at when a runtime correction
            happened.
        port_corrected_at:
          anyOf:
            - format: date-time
              type: string
            - type: 'null'
          description: >-
            When the demo's container port was automatically corrected from the
            container's own logs; a demo row receives at most one correction.
        demo_base_stack_error:
          anyOf:
            - type: string
            - type: 'null'
        demo_base_stack_id:
          anyOf:
            - type: string
            - type: 'null'
          description: >-
            References the shared base stack this demo depends on;
            name/status/error are joined from the base stack for display. All
            absent when the demo has no base-stack dependency.
        demo_base_stack_name:
          anyOf:
            - type: string
            - type: 'null'
        demo_base_stack_status:
          anyOf:
            - type: string
            - type: 'null'
        demo_stack_error:
          anyOf:
            - type: string
            - type: 'null'
        demo_stack_name:
          anyOf:
            - type: string
            - type: 'null'
          description: >-
            The stack-profile replica attached to a full-stack demo; absent for
            single-service demos (as are demo_stack_status and
            demo_stack_error).
        demo_stack_status:
          anyOf:
            - type: string
            - type: 'null'
        environment:
          description: >-
            The demo's env entry names and secret flags only - values (sentinel
            or plaintext) never ride list surfaces.
          items:
            $ref: '#/components/schemas/DemoEnvironmentSummaryEntry'
          type: array
        expires_at:
          format: date-time
          type: string
        head_sha:
          anyOf:
            - type: string
            - type: 'null'
        id:
          type: string
        image_tag:
          anyOf:
            - type: string
            - type: 'null'
        kind:
          type: string
        last_error:
          anyOf:
            - type: string
            - type: 'null'
        namespace:
          type: string
        pod_name:
          anyOf:
            - type: string
            - type: 'null'
        pr_number:
          anyOf:
            - type: integer
            - type: 'null'
        preview_url:
          anyOf:
            - type: string
            - type: 'null'
        repos:
          items:
            $ref: '#/components/schemas/DemoWorkspaceRepo'
          type: array
        stack_profile_name:
          anyOf:
            - type: string
            - type: 'null'
          description: >-
            The profile's display name, denormalized so list surfaces can badge
            full-stack demos without a second lookup.
        status:
          type: string
        components:
          type: array
          nullable: true
          items:
            $ref: '#/components/schemas/DemoWorkspaceComponent'
          description: >-
            Every deployable component the demo runs; null for single-workload
            demos predating multi-component records.
      required:
        - id
        - kind
        - application_id
        - cluster_id
        - namespace
        - pod_name
        - pr_number
        - branch
        - image_tag
        - container_port
        - preview_url
        - head_sha
        - status
        - last_error
        - repos
        - database
        - expires_at
        - created_by_user_id
        - created_at
      type: object
    DemoInspection:
      description: >-
        The full live picture of one demo, read from the staging cluster in one
        uncached pass. cluster_reachable false means the staging cluster or its
        agent could not be reached; steps and resources are then empty rather
        than misleadingly showing nothing-has-happened-yet.
      properties:
        cluster_reachable:
          type: boolean
        containers:
          items:
            type: string
          type: array
        elapsed_seconds:
          description: Time in the demo's current status.
          type: integer
        events:
          items:
            $ref: '#/components/schemas/DemoEvent'
          type: array
        pod_names:
          items:
            type: string
          type: array
        resources:
          items:
            $ref: '#/components/schemas/DemoResource'
          type: array
        steps:
          items:
            $ref: '#/components/schemas/DemoStep'
          type: array
        timeout_seconds:
          description: The provisioning budget after which the reconciler fails the demo.
          type: integer
        unreachable_reason:
          type: string
        unreadable_kinds:
          description: >-
            Resource kinds the cluster agent could not read on this pass; absent
            from resources because their state is unknown, not because they do
            not exist.
          items:
            type: string
          type: array
      required:
        - cluster_reachable
        - unreachable_reason
        - steps
        - resources
        - events
        - pod_names
        - containers
        - unreadable_kinds
        - elapsed_seconds
        - timeout_seconds
      type: object
    DemoStagingStatus:
      description: The staging-cluster status the demos tab renders.
      properties:
        agent_online:
          type: boolean
        cluster_id:
          anyOf:
            - type: string
            - type: 'null'
        cluster_name:
          anyOf:
            - type: string
            - type: 'null'
        configured:
          type: boolean
      required:
        - configured
        - cluster_id
        - cluster_name
        - agent_online
      type: object
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          title: Location
          type: array
        msg:
          title: Message
          type: string
        type:
          title: Error Type
          type: string
      required:
        - loc
        - msg
        - type
      title: ValidationError
      type: object
    DemoEnvironmentSummaryEntry:
      description: >-
        The value-free projection list surfaces expose: names and secret flags
        only, never values.
      properties:
        name:
          type: string
        secret:
          type: boolean
      required:
        - name
        - secret
      type: object
    DemoWorkspaceRepo:
      description: One repository cloned into a workspace pod.
      properties:
        name:
          type: string
        path:
          type: string
        url:
          type: string
      required:
        - name
        - url
        - path
      type: object
    DemoWorkspaceComponent:
      type: object
      description: >-
        One deployable component of a demo: its own Deployment and Service
        inside the demo namespace. The entry component owns the demo host's root
        path.
      properties:
        name:
          type: string
        image_tag:
          type: string
        container_port:
          type: integer
        ingress_path:
          type: string
          description: >-
            Path prefix the component is published under on the demo host; empty
            keeps it in-cluster only.
        entry:
          type: boolean
      required:
        - name
        - container_port
    DemoEvent:
      description: One Kubernetes event from the demo namespace.
      properties:
        count:
          type: integer
        message:
          type: string
        object:
          type: string
        reason:
          type: string
        timestamp:
          type: string
        type:
          type: string
      required:
        - type
        - reason
        - message
        - object
        - count
        - timestamp
      type: object
    DemoResource:
      description: >-
        One entry in a demo's bill of materials: a resource Ankra creates (or
        that Kubernetes derives from one), paired with what the cluster
        currently holds.
      properties:
        ankra:
          description: Whether Ankra itself applies this resource.
          type: boolean
        facts:
          items:
            $ref: '#/components/schemas/DemoResourceFact'
          type: array
        kind:
          type: string
        manifest:
          description: >-
            The live object when present (pruned of Kubernetes bookkeeping and
            with every secret value redacted), otherwise the manifest Ankra
            would apply. manifest_source says which.
          type: object
        manifest_source:
          type: string
        name:
          type: string
        present:
          description: Whether the object exists on the cluster right now.
          type: boolean
        purpose:
          type: string
        status:
          enum:
            - ready
            - pending
            - missing
            - failed
          type: string
        component:
          type: string
          description: >-
            Demo component this resource belongs to; empty for demo-wide
            infrastructure.
      required:
        - kind
        - name
        - purpose
        - ankra
        - present
        - status
        - facts
        - manifest
        - manifest_source
      type: object
    DemoStep:
      description: >-
        One stage of bringing a demo up. Every 'done' is backed by a live
        cluster signal; nothing is inferred from elapsed time. Keys are stable
        across releases: namespace, guardrails, base_stack (only for demos with
        a base-stack dependency), stack (only for full-stack demos), workload,
        scheduled, image, accepting, routing.
      properties:
        detail:
          description: >-
            The live evidence behind status - a node name, a pull reason, an
            ingress address.
          type: string
        key:
          enum:
            - namespace
            - guardrails
            - base_stack
            - stack
            - workload
            - scheduled
            - image
            - accepting
            - routing
          type: string
        label:
          type: string
        status:
          description: >-
            pending: not started, or not yet observable; active: currently being
            waited on; done: positively observed as complete; failed: cannot
            recover without redeploying; skipped: does not apply to this demo.
          enum:
            - pending
            - active
            - done
            - failed
            - skipped
          type: string
      required:
        - key
        - label
        - status
        - detail
      type: object
    DemoResourceFact:
      description: One labelled observation about a resource, rendered verbatim.
      properties:
        label:
          type: string
        value:
          type: string
      required:
        - label
        - value
      type: object

````