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

# Delete a Dataset

> Permanently delete a dataset. All associated files are soft-deleted and can be restored later.

<RequestExample>
  ```bash cURL theme={null}
  curl --request DELETE \
    --url "https://api.roe-ai.com/v1/datasets/YOUR_DATASET_ID/?organization_id=YOUR_ORG_ID" \
    --header "Authorization: Bearer YOUR_API_KEY"
  ```
</RequestExample>


## OpenAPI

````yaml DELETE /v1/datasets/{dataset_id}/
openapi: 3.1.0
info:
  title: Roe API
  version: 1.0.0
  description: Complete API documentation for Roe platform
servers:
  - url: https://api.roe-ai.com
    description: Production API
security: []
paths:
  /v1/datasets/{dataset_id}/:
    delete:
      tags:
        - v1
      summary: Delete a dataset.
      description: >-
        Permanently delete a dataset. All associated files are soft-deleted and
        can be restored later.
      operationId: v1_datasets_destroy
      parameters:
        - in: path
          name: dataset_id
          schema:
            type: string
            format: uuid
          description: Dataset UUID
          required: true
        - in: query
          name: organization_id
          schema:
            type: string
            format: uuid
          description: Organization ID for access control.
          required: true
      responses:
        '204':
          description: Dataset deleted successfully.
        '403':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
          description: Access forbidden.
        '404':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
          description: Dataset not found.
      security:
        - apiKeyAuth: []
components:
  schemas:
    ErrorResponse:
      type: object
      description: |-
        Legacy `{message}` error shape.

        No public-API error path actually emits this shape — do not reference it
        on SDK-surface operations. Use ErrorDetailResponseSerializer,
        ApiErrorResponseSerializer, or the validation-error schemas below, which
        match what the handlers really return.
      properties:
        message:
          type: string
          description: Error message
      required:
        - message
  securitySchemes:
    apiKeyAuth:
      type: http
      scheme: bearer
      description: >-
        Organization API key passed as a Bearer token. This is the scheme used
        by the public SDK surface.

````