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

# Upload File

> Upload a file to temporary staging storage. Used for tools that require file uploads (e.g. media uploads).



## OpenAPI

````yaml POST /proxy/tools/upload
openapi: 3.1.0
info:
  title: Kylon Tools API
  description: >-
    Kylon Tools API for searching, authenticating, inspecting, executing,
    proxying, and uploading files for connected tools.
  version: 1.0.0
servers:
  - url: https://api.kylon.io
    description: Production
security:
  - apiKey: []
paths:
  /proxy/tools/upload:
    post:
      tags:
        - Execution
      summary: Upload file
      description: >-
        Upload a file to temporary staging storage. Used for tools that require
        file uploads (e.g. media uploads).
      operationId: uploadFile
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                file:
                  type: string
                  format: binary
                  description: The file to upload.
              required:
                - file
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/UploadResult'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '413':
          description: File too large
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  schemas:
    UploadResult:
      type: object
      properties:
        stagingKey:
          type: string
          description: >-
            Use this key as the `stagingKey` argument when executing
            upload-capable tools.
        contentType:
          type: string
        size:
          type: integer
          description: File size in bytes.
      required:
        - stagingKey
        - contentType
        - size
    Error:
      type: object
      properties:
        error:
          type: string
      required:
        - error
  responses:
    BadRequest:
      description: Bad request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Unauthorized:
      description: Unauthorized - invalid or missing API key
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  securitySchemes:
    apiKey:
      type: apiKey
      in: header
      name: x-api-key
      description: >-
        API key for authentication. Can also be passed as `Authorization: Bearer
        <token>`.

````