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

# Get Process Output

> Retrieves the output of a background process by its ID.



## OpenAPI

````yaml api-reference/openapi.json get /api/bash/process/{pid}/output
openapi: 3.1.0
info:
  title: FastAPI
  version: 0.1.0
servers:
  - url: http://localhost:4242/{computer_name}
    description: Local development server
    variables:
      computer_name:
        default: your-computer-name
        description: Computer name
security: []
paths:
  /api/bash/process/{pid}/output:
    get:
      tags:
        - bash
      summary: Get Process Output
      description: Retrieves the output of a background process by its ID.
      operationId: getProcessOutput
      parameters:
        - name: pid
          in: path
          required: true
          schema:
            type: integer
            title: Pid
      responses:
        '200':
          description: Successfully retrieved process output
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CommandResponse'
              example:
                output: |-
                  Processing...
                  50% complete
                process_id: 1234
                status: background
        '404':
          description: Process not found
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
        '500':
          description: Internal server error
components:
  schemas:
    CommandResponse:
      properties:
        output:
          anyOf:
            - type: string
            - type: 'null'
          title: Output
          description: Command output if available
          example: |-
            total 20
            drwxr-xr-x  3 user  group   96 Mar 10 12:34 .
        process_id:
          anyOf:
            - type: integer
            - type: 'null'
          title: Process Id
          description: Process ID if running in background
          example: 1234
        status:
          type: string
          title: Status
          description: 'Command status: ''completed'' or ''background'''
          default: completed
          example: completed
      type: object
      title: CommandResponse
      example:
        output: |-
          total 20
          drwxr-xr-x  3 user  group   96 Mar 10 12:34 .
        status: completed
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError

````