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

# Get file metadata

> Retrieve a file's metadata by ID.



## OpenAPI

````yaml GET /files/{file_id}
openapi: 3.1.0
info:
  title: Valar API
  version: '2026-08-14'
  description: >-
    Valar exposes Responses and Chat Completions endpoints that match the OpenAI
    shape. This reference documents the fields Valar supports today.
servers:
  - url: https://api.valarhq.ai/v1
security:
  - BearerAuth: []
tags:
  - name: Models API
    description: Discover which models you can call.
  - name: Responses API
    description: Responses endpoints that follow the OpenAI interface.
  - name: Chat Completions API
    description: Chat Completions endpoints that follow the OpenAI interface.
  - name: Batches API
    description: Submit request batches and track their progress.
paths:
  /files/{file_id}:
    get:
      tags:
        - Files API
      summary: Get file metadata
      operationId: getFile
      parameters:
        - name: file_id
          in: path
          required: true
          schema:
            type: string
      responses:
        '200':
          description: The file's metadata.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/FileObject'
              example:
                id: file-abc123
                object: file
                bytes: 34333913
                created_at: 1741564800
                filename: requests.jsonl
                purpose: batch
                status: uploaded
                status_details: null
        '401':
          description: We could not authenticate the request.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: The file was not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '500':
          description: Something went wrong on Valar's side.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
components:
  schemas:
    FileObject:
      type: object
      required:
        - id
        - object
        - bytes
        - created_at
        - filename
        - purpose
      properties:
        id:
          type: string
          description: The file's unique ID.
        object:
          type: string
          enum:
            - file
        bytes:
          type: integer
          description: The file's size in bytes.
        created_at:
          type: integer
          description: When the file was uploaded, as a Unix timestamp.
        filename:
          type: string
          description: The name the file was uploaded with.
        purpose:
          type: string
          description: What the file is for. Use `batch` for Batch API input files.
        status:
          type: string
          description: The file's processing status.
        status_details:
          type: string
          nullable: true
    ErrorResponse:
      type: object
      required:
        - error
      properties:
        error:
          $ref: '#/components/schemas/ErrorObject'
      additionalProperties: false
    ErrorObject:
      type: object
      required:
        - message
        - type
      properties:
        message:
          type: string
        type:
          type: string
        param:
          oneOf:
            - type: string
            - type: 'null'
        code:
          oneOf:
            - type: string
            - type: integer
            - type: 'null'
      additionalProperties: true
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: API Key

````