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

# Download Minion

> Download the latest stable Minion installer for the selected platform. Requires a project or organization API key with project:manage-minions.

## Query Parameters

<ParamField query="platform" type="string" required>
  Target platform: `windows-x86_64`, `linux-x86_64`, or `darwin-aarch64`.
</ParamField>

## Response

The endpoint responds with `307 Temporary Redirect`. The `Location` header
contains a download URL valid for 24 hours.

| Status | Meaning |
| - | - |
| `307` | Redirect to the installer download |
| `400` | Missing or unsupported platform |
| `401` | Unauthenticated |
| `403` | Missing `project:manage-minions` permission |
| `404` | No release is available |
| `500` | Invalid release metadata or internal error |
| `503` | Minion downloads are unavailable |

<RequestExample>
  ```bash cURL theme={"theme":{"light":"catppuccin-latte","dark":"catppuccin-mocha"}}
  curl --fail --location \
    --output minion-installer \
    --header "X-API-Key: $NUNU_API_KEY" \
    "https://nunu.ai/api/v1/minions/download?platform=linux-x86_64"
  ```
</RequestExample>


## OpenAPI

````yaml GET /minions/download
openapi: 3.1.0
info:
  title: nunu.ai API
  description: >-
    The nunu.ai Public API allows you to programmatically interact with your
    projects, manage test runs, and upload builds.
  version: 1.0.0
servers:
  - url: https://nunu.ai/api/v1
security:
  - apiKeyAuth: []
paths:
  /minions/download:
    get:
      tags:
        - Minions
      summary: Download Minion
      description: >-
        Download the latest stable Minion installer for the selected platform.
        Requires a project or organization API key with project:manage-minions.
      operationId: downloadMinion
      parameters:
        - name: platform
          in: query
          required: true
          description: Platform and architecture of the Minion installer.
          schema:
            $ref: '#/components/schemas/MinionDownloadPlatform'
          example: linux-x86_64
      responses:
        '307':
          description: 'Redirect to the latest stable installer. '
          headers:
            Location:
              description: Installer download URL, valid for 24 hours.
              schema:
                type: string
                format: uri
        '400':
          description: Missing or unsupported platform.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: Authentication required or invalid API key.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '403':
          description: Access denied, may mean missing project:manage-minions permission.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: Minion release not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '500':
          description: Invalid release metadata or an internal error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '503':
          description: Minion update service unavailable.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  schemas:
    MinionDownloadPlatform:
      type: string
      enum:
        - windows-x86_64
        - linux-x86_64
        - darwin-aarch64
      description: Windows x64, Linux x64, or macOS Apple Silicon.
    Error:
      type: object
      properties:
        error:
          type: string
        code:
          type: string
        details:
          type: object
  securitySchemes:
    apiKeyAuth:
      type: apiKey
      in: header
      name: X-Api-Key
      description: API key for authentication

````

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