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

# Upload custom model archive



## OpenAPI

````yaml https://api.tokenfactory.nebius.com/openapi.json post /v0/models/upload
openapi: 3.1.0
info:
  title: Nebius OpenAI-compatible inference API
  version: 20260506-297d05704
servers:
  - url: https://api.tokenfactory.nebius.com
security: []
paths:
  /v0/models/upload:
    post:
      tags:
        - files
      summary: Upload custom model archive
      operationId: upload_model_file_v0_models_upload_post
      parameters:
        - name: ai_project_id
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: Project ID to upload file to
            title: Ai Project Id
          description: Project ID to upload file to
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              $ref: >-
                #/components/schemas/Body_upload_model_file_v0_models_upload_post
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OpenAIFile'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBearer: []
components:
  schemas:
    Body_upload_model_file_v0_models_upload_post:
      properties:
        file:
          type: string
          format: binary
          title: File
      type: object
      required:
        - file
      title: Body_upload_model_file_v0_models_upload_post
    OpenAIFile:
      properties:
        id:
          type: string
          title: Id
        bytes:
          type: integer
          title: Bytes
        created_at:
          type: integer
          title: Created At
        filename:
          type: string
          title: Filename
        object:
          type: string
          title: Object
          default: file
        purpose:
          type: string
          title: Purpose
        status:
          anyOf:
            - type: string
            - type: 'null'
          title: Status
        status_details:
          anyOf:
            - type: string
            - type: 'null'
          title: Status Details
      type: object
      required:
        - id
        - bytes
        - created_at
        - filename
        - purpose
      title: OpenAIFile
    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
  securitySchemes:
    HTTPBearer:
      type: http
      scheme: bearer

````