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

# Delete Collection

> Programmatically deletes a Collection.

<Danger>
**Warning**

This is destructive and cannot be reversed.
</Danger>



## OpenAPI

````yaml /openapi/framework/appdb.yaml delete /domo/datastores/v1/collections/{collectionName}
openapi: 3.0.0
info:
  title: Domo AppDB API
  version: v1
  description: >
    AppDB API for storing arbitrary JSON documents similar to a NoSQL database.
    This enables storing state within your DomoApp

    with optional syncing to Domo DataSets.


    Three layers provide data storage:

    - **Datastores**: Analogous to a database. A CustomApp has a single
    datastore created automatically.

    - **Collections**: Analogous to a collection in NoSQL or table in relational
    databases.

    - **Documents**: Analogous to documents in NoSQL or table rows in relational
    databases.
servers:
  - url: https://{instance}.domo.com
    description: Domo Instance
    variables:
      instance:
        default: example
        description: Your Domo instance name
security: []
paths:
  /domo/datastores/v1/collections/{collectionName}:
    delete:
      tags:
        - AppDB API
      summary: Delete Collection
      description: |-
        Programmatically deletes a Collection.

        <Danger>
        **Warning**

        This is destructive and cannot be reversed.
        </Danger>
      parameters:
        - $ref: '#/components/parameters/CollectionName'
      responses:
        '200':
          description: Collection deleted successfully. No response body is returned.
        '403':
          description: You do not have the DELETE permission on this collection.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                status: 403
                statusReason: >-
                  status 403 reading
                  CollectionsResourceClient#deleteCollection(UUID); content:

                  {"status":403,"toe":"AIFZ3S4ZR9-CVL5Q-1FOQC"}
                toe: AIFZ3S4ZR9-CVL5Q-1FOQC
        '404':
          description: >-
            Collection not found. Verify the collection name is correct (it is
            case-sensitive) and that the collection has been created or
            correctly wired in this app's datastore.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                status: 404
                statusReason: >-
                  status 404 reading
                  CollectionsResourceClient#deleteCollection(UUID); content:

                  {"message":"No collection with id
                  1b9eebac-e9b0-4e98-b218-34d4d751d15b
                  found","status":404,"statusReason":"Not
                  Found","toe":"CUDX3VBUXC-8BF1P-DXONT"}
                toe: CUDX3VBUXC-8BF1P-DXONT
      x-codeSamples:
        - lang: JavaScript
          label: domo.js
          source: |-
            const collectionName = 'YourCollection';

            domo.delete(`/domo/datastores/v1/collections/${collectionName}`)
              .then(() => console.log('collection deleted'));
        - lang: JavaScript
          label: domo.js v6
          source: |-
            // domo.js v6
            const collectionName = 'Students';

            await domo.appdb.deleteCollection(collectionName);
            console.log('collection deleted');
        - lang: cURL
          label: cURL
          source: |-
            # This API is only available inside a Domo app.
            # Use the JavaScript (domo.js) tab for the correct usage.
        - lang: Python
          label: Python
          source: |-
            # This API is only available inside a Domo app.
            # Use the JavaScript (domo.js) tab for the correct usage.
        - lang: PHP
          label: PHP
          source: |-
            // This API is only available inside a Domo app.
            // Use the JavaScript (domo.js) tab for the correct usage.
        - lang: Go
          label: Go
          source: |-
            // This API is only available inside a Domo app.
            // Use the JavaScript (domo.js) tab for the correct usage.
        - lang: Java
          label: Java
          source: |-
            // This API is only available inside a Domo app.
            // Use the JavaScript (domo.js) tab for the correct usage.
        - lang: Ruby
          label: Ruby
          source: |-
            # This API is only available inside a Domo app.
            # Use the JavaScript (domo.js) tab for the correct usage.
components:
  parameters:
    CollectionName:
      name: collectionName
      in: path
      required: true
      description: The name given to the collection in the manifest. Case-sensitive.
      schema:
        type: string
  schemas:
    ErrorResponse:
      type: object
      properties:
        message:
          type: string
          description: >-
            A plain-English explanation of the error. Present on some errors but
            not all.
        status:
          type: integer
          description: The HTTP error code
        statusReason:
          type: string
          description: >-
            A human-readable error message, sometimes including nested error
            detail
        toe:
          type: string
          description: >-
            Thread of Execution; a unique identifier that Support can use to
            find more info about your problem
      example:
        status: 404
        statusReason: 'DA0088: Invalid collection name: Students'
        toe: FTYRJMBLKD-5HB2Z-H6W8A

````