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

# Get software install logs on a device

> Return every install attempt of ONE software on ONE device, newest first (up to the 20 most recent): status, script/query output for a package, the decoded MDM error for an App Store app, when it ran, and what triggered it (`manual`, `selfService`, `policy` with its name, or `setupExperience`). MDM retries a failed install, so the OLDEST attempt usually carries the root cause while later ones fail on the debris of the first — read the whole list, not just `attempts[0]`. `skippedInstall` marks an attempt that was postponed because the app was open, not a real failure. To list all software on a device, use `getDeviceSoftware` instead.

<span className="badge-read">Key: Read</span><span className="badge-company">Scope: Company</span>


## OpenAPI

````yaml https://api.getprimo.com/openapi.json get /devices/{deviceId}/software/{softwareId}/install-logs
openapi: 3.1.1
info:
  title: Public API - BETA
  description: Read docs on https://docs.getprimo.com/
  version: '1.0'
  contact: {}
servers:
  - url: https://api.getprimo.com
security:
  - apikey: []
tags: []
paths:
  /devices/{deviceId}/software/{softwareId}/install-logs:
    get:
      tags:
        - Devices
      summary: Get software install logs on a device
      description: >-
        Return every install attempt of ONE software on ONE device, newest first
        (up to the 20 most recent): status, script/query output for a package,
        the decoded MDM error for an App Store app, when it ran, and what
        triggered it (`manual`, `selfService`, `policy` with its name, or
        `setupExperience`). MDM retries a failed install, so the OLDEST attempt
        usually carries the root cause while later ones fail on the debris of
        the first — read the whole list, not just `attempts[0]`.
        `skippedInstall` marks an attempt that was postponed because the app was
        open, not a real failure. To list all software on a device, use
        `getDeviceSoftware` instead.
      operationId: getSoftwareInstallLogs
      parameters:
        - name: deviceId
          required: true
          in: path
          schema:
            type: string
        - name: softwareId
          required: true
          in: path
          schema:
            type: string
      responses:
        default:
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetSoftwareInstallLogs_Output'
components:
  schemas:
    GetSoftwareInstallLogs_Output:
      type: object
      properties:
        status:
          anyOf:
            - type: string
              enum:
                - installed
                - pending_install
                - failed_install
                - no_install_attempt
                - logs_unavailable
            - type: 'null'
        attempts:
          type: array
          items:
            type: object
            properties:
              status:
                anyOf:
                  - type: string
                    enum:
                      - installed
                      - pending_install
                      - failed_install
                  - type: 'null'
              ranAt:
                type: string
              trigger:
                type: string
                enum:
                  - manual
                  - selfService
                  - policy
                  - setupExperience
              policyName:
                anyOf:
                  - type: string
                  - type: 'null'
              output:
                anyOf:
                  - type: string
                  - type: 'null'
              preInstallQueryOutput:
                anyOf:
                  - type: string
                  - type: 'null'
              postInstallScriptOutput:
                anyOf:
                  - type: string
                  - type: 'null'
              failureReason:
                anyOf:
                  - type: string
                  - type: 'null'
              skippedInstall:
                type: boolean
            required:
              - status
              - ranAt
              - trigger
              - policyName
              - output
              - preInstallQueryOutput
              - postInstallScriptOutput
              - failureReason
              - skippedInstall
            additionalProperties: false
      required:
        - status
        - attempts
      additionalProperties: false
  securitySchemes:
    apikey:
      scheme: bearer
      bearerFormat: API key
      type: http
      description: >-
        Use your Primo API key in the Authorization header as `Bearer
        <API_KEY>`.

````