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

# Delete a volume tag

> Deletes a tag without deleting its version.



## OpenAPI

````yaml delete /v1/volumes/{volume_namespace}/{volume_name}/tags/{volume_tag}
openapi: 3.1.0
info:
  description: REST API for management of Baseten resources
  title: Baseten management API
  version: 1.0.0
servers:
  - url: https://api.baseten.co
security:
  - BearerAuth: []
paths:
  /v1/volumes/{volume_namespace}/{volume_name}/tags/{volume_tag}:
    parameters:
      - $ref: '#/components/parameters/volume_namespace'
      - $ref: '#/components/parameters/volume_name'
      - $ref: '#/components/parameters/volume_tag'
    delete:
      summary: Deletes a volume tag
      description: >-
        The version remains available by digest and any other tags. If the tag
        is absent, the request succeeds with `deleted` set to `false`. Deleting
        `head` makes references without a tag or digest stop resolving until
        `head` is set again.
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/DeleteVolumeTagRequestV1'
        required: true
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DeleteVolumeTagResponseV1'
      x-codeSamples:
        - lang: bash
          source: >-
            curl --request DELETE \

            --url
            https://api.baseten.co/v1/volumes/{volume_namespace}/{volume_name}/tags/{volume_tag}
            \

            --header "Authorization: Bearer $BASETEN_API_KEY" \

            --data '{
              "expected_sequence": null
            }'
        - lang: python
          source: >-
            import requests

            import os

            API_KEY = os.environ.get("BASETEN_API_KEY", "<YOUR_API_KEY>")

            url =
            "https://api.baseten.co/v1/volumes/{volume_namespace}/{volume_name}/tags/{volume_tag}"


            headers = {"Authorization": f"Bearer {API_KEY}"}


            response = requests.request(
                "DELETE",
                url,
                headers=headers,
                json={'expected_sequence': None}
            )


            print(response.text)
components:
  parameters:
    volume_namespace:
      schema:
        type: string
      name: volume_namespace
      in: path
      required: true
    volume_name:
      schema:
        type: string
      name: volume_name
      in: path
      required: true
    volume_tag:
      schema:
        type: string
      name: volume_tag
      in: path
      required: true
  schemas:
    DeleteVolumeTagRequestV1:
      additionalProperties: false
      properties:
        expected_sequence:
          anyOf:
            - minimum: 0
              type: integer
            - type: 'null'
          default: null
          description: >-
            Revision the volume is expected to be at. When set, the delete fails
            with a conflict if the volume has changed since, so it cannot delete
            a tag someone else has just set on another version. Take the value
            from volume_sequence.
          title: Expected Sequence
      title: DeleteVolumeTagRequestV1
      type: object
    DeleteVolumeTagResponseV1:
      properties:
        namespace:
          description: Namespace the volume belongs to, in lowercase.
          title: Namespace
          type: string
        volume:
          description: Name of the volume, in lowercase.
          title: Volume
          type: string
        tag:
          description: Tag name from the request, with its original capitalization.
          title: Tag
          type: string
        deleted:
          description: >-
            Whether the tag existed and was deleted. False when the volume had
            no tag by that name, which is not an error.
          title: Deleted
          type: boolean
        volume_sequence:
          description: Revision of the volume after the delete.
          title: Volume Sequence
          type: integer
      required:
        - namespace
        - volume
        - tag
        - deleted
        - volume_sequence
      title: DeleteVolumeTagResponseV1
      type: object
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      description: >-
        Send `Authorization: Bearer <api_key>`. The legacy `Authorization:
        Api-Key <api_key>` scheme is also accepted.

````