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

# Delete file

> Delete a file. Follows the [OpenAI Files API spec](https://platform.openai.com/docs/api-reference/files/delete).



## OpenAPI

````yaml api-reference/openapi.json delete /v1/files/{file_id}
openapi: 3.1.0
info:
  title: UncensoredGPT API
  description: >-
    Every UncensoredGPT model through a single, OpenAI-compatible endpoint.
    Create an API key in the [UncensoredGPT
    Console](https://console.uncensoredgpt.ai), point your code at this base
    URL, and pay per token.
  version: 1.0.0
servers:
  - url: https://api.uncensoredgpt.ai
security: []
tags:
  - name: Chat
    description: >-
      Create a chat response for a list of messages. Supports streaming, tool
      calling, and vision models.
  - name: Completions
    description: Generate a text continuation for a prompt (legacy completions format).
  - name: Embeddings
    description: >-
      Turn text into a vector representation for search, retrieval, and
      clustering.
  - name: Responses
    description: >-
      The Responses API: stateful generations with tool use, plus retrieval and
      deletion of past responses.
  - name: Models
    description: List and inspect the models available to your API key.
  - name: Moderations
    description: Classify text against usage policies.
  - name: Batches
    description: >-
      Submit batches of requests for asynchronous processing within 24 hours, at
      lower cost.
  - name: Files
    description: Upload and manage files, for example Batch input files.
  - name: Images
    description: Generate or edit images from a text prompt.
  - name: Messages
    description: >-
      Call models using the Anthropic Messages format, for code that already
      targets the Anthropic API.
paths:
  /v1/files/{file_id}:
    delete:
      tags:
        - Files
      summary: Delete File
      description: >-
        Delete a file. Follows the [OpenAI Files API
        spec](https://platform.openai.com/docs/api-reference/files/delete).
      operationId: delete_file_v1_files__file_id__delete
      parameters:
        - name: file_id
          in: path
          required: true
          schema:
            title: File Id
            type: string
      responses:
        '200':
          content:
            application/json:
              schema: {}
          description: Successful Response
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - bearerAuth: []
components:
  schemas:
    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
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        An UncensoredGPT API key created in the [UncensoredGPT
        Console](https://console.uncensoredgpt.ai).

````

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