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

# Upload a new dataset file



## OpenAPI

````yaml post /v1/datasets
openapi: 3.0.0
info:
  title: Datasets API
  version: 1.0.0
  description: API for managing dataset files
servers: []
security: []
paths:
  /v1/datasets:
    post:
      tags:
        - Datasets
      summary: Upload a new dataset file
      requestBody:
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                file:
                  type: string
                  format: binary
                  description: JSONL file in OpenAI format
                name:
                  type: string
                  description: User-assigned name for the dataset
                description:
                  type: string
                  description: User-provided description of the dataset
      responses:
        '201':
          description: Successfully uploaded dataset
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DatasetResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
      security:
        - ApiKeyAuth: []
components:
  schemas:
    DatasetResponse:
      type: object
      properties:
        id:
          type: string
          format: uuid
        created_at:
          type: string
          format: date-time
        updated_at:
          type: string
          format: date-time
        status:
          type: string
          enum:
            - UPLOADED
            - VALIDATED
            - ERROR
            - DELETED
        name:
          type: string
        description:
          type: string
        file_name:
          type: string
        file_size:
          type: integer
        errors:
          type: object
    ErrorResponse:
      type: object
      properties:
        status:
          type: integer
        message:
          type: string
  responses:
    BadRequest:
      description: Bad request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
    Unauthorized:
      description: Unauthorized
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key

````