> ## Documentation Index
> Fetch the complete documentation index at: https://domoinc-openapi-sync-dataflows.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Deleting Dataset Versions

> This endpoint removes a set of data versions from Vault for a given dataset. This is a destructive operation and cannot be undone. A list of data versions to delete is supplied in the body of the request. The method returns an empty response with a 200 OK http status if the delete was successful.

If you are deleting data versions that are part of the active data in Adrenaline you should include the index=true request parameter in order to remove the data from Adrenaline as well.



## OpenAPI

````yaml /openapi/product/managing-dataset-history-api.yaml delete /api/data/v2/datasources/{datasetId}/dataversions
openapi: 3.1.0
info:
  title: Managing Dataset History API
  version: 1.0.0
  description: >-
    Authentication


    Requests to the endpoints in this document should be authenticated using an
    access token. The token should be passed using the X-DOMO-Developer-Token
    header. For information about generating an access token see
    https://domo-support.domo.com/s/article/360042934494?language=en_US.
servers:
  - url: https://{instance}.domo.com
    variables:
      instance:
        default: YOUR_INSTANCE
        description: Domo instance subdomain
security:
  - DomoDeveloperToken: []
tags:
  - name: Dataset History
paths:
  /api/data/v2/datasources/{datasetId}/dataversions:
    delete:
      tags:
        - Managing Dataset History API
      summary: Deleting Dataset Versions
      description: >-
        This endpoint removes a set of data versions from Vault for a given
        dataset. This is a destructive operation and cannot be undone. A list of
        data versions to delete is supplied in the body of the request. The
        method returns an empty response with a 200 OK http status if the delete
        was successful.


        If you are deleting data versions that are part of the active data in
        Adrenaline you should include the index=true request parameter in order
        to remove the data from Adrenaline as well.
      parameters:
        - in: path
          name: datasetId
          required: true
          description: <dataset-id>
          schema:
            $ref: '#/components/schemas/DatasetIdParam'
        - in: query
          name: index
          required: false
          description: index=<true|false>
          schema:
            type: boolean
      requestBody:
        required: true
        description: List of data versions.
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/DataVersionDeleteRequest'
            examples:
              example:
                value:
                  - 2
      responses:
        '200':
          description: >-
            An empty response with a 200 OK http status if the delete was
            successful.
components:
  schemas:
    DatasetIdParam:
      type: string
      description: <dataset-id>
    DataVersionDeleteRequest:
      type: array
      description: List of data versions.
      items:
        type: integer
  securitySchemes:
    DomoDeveloperToken:
      type: apiKey
      in: header
      name: X-DOMO-Developer-Token

````