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

# केस हटाने का API

> Didit में अनुपालन केस और उसकी ड्राफ़्ट नियामक रिपोर्ट हटाएँ। अंतिम रूप दी गई रिपोर्ट को हटाने तक केस का हटाना रुका रहता है।

केस हटाने का API प्रॉम्प्ट
प्रॉम्प्ट को क्लिपबोर्ड पर कॉपी करें

<pre>
  \`Delete a compliance case through the Management API.

  Endpoint:
  DELETE [https://verification.didit.me/v3/organization/\{organization\_id}/application/\{application\_id}/cases/\{case\_uuid}/](https://verification.didit.me/v3/organization/\{organization_id}/application/\{application_id}/cases/\{case_uuid}/)

  Authentication:
  Use the x-api-key header with my Didit API key. Use a full-access API key; the caller needs write:cases.

  Request body: none.

  Example call:
  curl -X DELETE "[https://verification.didit.me/v3/organization/\{organization\_id}/application/\{application\_id}/cases/\{case\_uuid}/](https://verification.didit.me/v3/organization/\{organization_id}/application/\{application_id}/cases/\{case_uuid}/)" \
  -H "x-api-key: YOUR\_API\_KEY"

  Response 204: the case is deleted.

  What is deleted:

  * The case.
  * Its draft regulatory reports.
    Linked verifications, people, companies and transactions are NOT deleted. There is no undelete endpoint.

  Failure modes:

  * 409 - the case has a finalized regulatory report. Nothing is deleted. The body has code: in\_filed\_report and names each report with uuid, report\_number, report\_type and case\_uuid. Delete the reports, then repeat this request.
  * 403 - the key cannot delete cases (requires a full-access key and write:cases).
  * 404 - the case does not exist in this application or was already deleted.

  For the full integration shape, see /integration/integration-prompt.\`
</pre>

यहाँ पेस्ट करें

केस को स्थायी रूप से हटाएँ। उसकी ड्राफ़्ट नियामक रिपोर्ट भी उसके साथ हटा दी जाती हैं।

जुड़े हुए सत्यापन, लोग, कंपनियाँ और लेन-देन **नहीं** हटाए जाते। हटाए गए केस को पुनर्स्थापित करने वाला कोई endpoint उपलब्ध नहीं है।

## अंतिम रूप दी गई रिपोर्ट के कारण अवरुद्ध

अगर केस में कोई अंतिम रूप दी गई नियामक रिपोर्ट है, तो पूरा अनुरोध `409` लौटाता है और कुछ भी हटाया नहीं जाता:

```json theme={null}
{
  "detail": "This case has a finalized regulatory report, so it cannot be deleted.",
  "code": "in_filed_report",
  "reports": [
    {
      "uuid": "5ec00000-0000-4000-8000-000000000007",
      "report_number": "SAR-0001",
      "report_type": "SAR",
      "case_uuid": "c1a5e000-0000-4000-8000-000000000001"
    }
  ]
}
```

हर रिपोर्ट को [रिपोर्ट हटाएँ](https://docs.didit.me/hi/management-api/regulatory-reports/delete.md) से हटाएँ, फिर यही अनुरोध दोबारा भेजें। जब कोई अंतिम रिपोर्ट शेष न रहे, तब केस हटाया जा सकता है।

## संबंधित

* [केस प्राप्त करें](https://docs.didit.me/hi/management-api/cases/get.md)
* [केस अपडेट करें](https://docs.didit.me/hi/management-api/cases/update.md)
* [रिपोर्ट हटाएँ](https://docs.didit.me/hi/management-api/regulatory-reports/delete.md)
* [केस (कंसोल)](https://docs.didit.me/hi/console/case-management/cases.md)


## OpenAPI

````yaml hi/openapi-25.json DELETE /v3/organization/{organization_id}/application/{application_id}/cases/{case_uuid}/
openapi: 3.0.0
info:
  version: 3.0.0
  title: Didit Verification API
  description: पहचान सत्यापन API। x-api-key हेडर के साथ प्रमाणीकृत करें।
servers:
  - url: https://verification.didit.me
security: []
tags: []
paths:
  /v3/organization/{organization_id}/application/{application_id}/cases/{case_uuid}/:
    delete:
      tags:
        - Cases
      summary: केस हटाएं
      description: >-
        किसी केस को स्थायी रूप से हटाएं। इसके ड्राफ्ट नियामक रिपोर्ट इसके साथ
        हटा दिए जाते हैं। लिंक किए गए सत्यापन, लोग, कंपनियां और लेन-देन नहीं
        हटाए जाते हैं। पुनर्स्थापित करने वाला कोई endpoint नहीं है。


        यदि केस में कोई अंतिम रूप दी गई नियामक रिपोर्ट है, तो पूरा अनुरोध `409`
        के साथ अस्वीकृत कर दिया जाता है और कुछ भी नहीं हटाया जाता है। बॉडी में
        `code: in_filed_report` का उपयोग होता है और प्रत्येक रिपोर्ट को `uuid`,
        `report_number`, `report_type` और `case_uuid` के साथ नामित किया जाता है।
        रिपोर्ट हटाएं, फिर अनुरोध दोहराएं।
      operationId: delete_case
      parameters:
        - name: organization_id
          in: path
          required: true
          schema:
            type: string
            format: uuid
          description: संगठन UUID।
        - name: application_id
          in: path
          required: true
          schema:
            type: string
            format: uuid
          description: एप्लिकेशन UUID।
        - name: case_uuid
          in: path
          required: true
          schema:
            type: string
            format: uuid
            example: c1a5e000-0000-4000-8000-000000000001
          description: केस UUID।
      responses:
        '204':
          description: केस हटाया गया।
        '403':
          description: >-
            कुंजी केस हटा नहीं सकती। इसके लिए `write:cases` वाली पूर्ण-एक्सेस
            कुंजी की आवश्यकता होती है।
          content:
            application/json:
              schema:
                type: object
                properties:
                  detail:
                    type: string
        '404':
          description: केस इस एप्लिकेशन में मौजूद नहीं है या पहले ही हटाया जा चुका है।
          content:
            application/json:
              schema:
                type: object
                properties:
                  detail:
                    type: string
        '409':
          description: केस में एक अंतिम नियामक रिपोर्ट है। कुछ भी हटाया नहीं गया है।
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InFiledReportError'
      security:
        - ApiKeyAuth: []
      x-codeSamples:
        - lang: curl
          label: curl
          source: >-
            curl -X DELETE
            'https://verification.didit.me/v3/organization/11111111-2222-3333-4444-555555555555/application/aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee/cases/c1a5e000-0000-4000-8000-000000000001/'
            \
              -H 'x-api-key: YOUR_API_KEY'
        - lang: python
          label: Python
          source: |-
            from didit import Didit

            # Reads DIDIT_API_KEY, DIDIT_ORGANIZATION_ID
            # and DIDIT_APPLICATION_ID.
            client = Didit()

            client.cases.delete(
                "c1a5e000-0000-4000-8000-000000000001",
            )
        - lang: javascript
          label: Node.js
          source: |-
            import Didit from "@didit-protocol/sdk-node";

            // Reads DIDIT_API_KEY, DIDIT_ORGANIZATION_ID
            // and DIDIT_APPLICATION_ID.
            const didit = new Didit();

            await didit.cases.delete("c1a5e000-0000-4000-8000-000000000001");
        - lang: go
          label: Go
          source: "ctx := context.Background()\n// Reads DIDIT_API_KEY, DIDIT_ORGANIZATION_ID\n// and DIDIT_APPLICATION_ID.\nclient := didit.NewClient()\n\nif err := client.Cases.Delete(ctx, \"c1a5e000-0000-4000-8000-000000000001\"); err != nil {\n\tlog.Fatal(err)\n}"
        - lang: java
          label: Java
          source: |-
            import me.didit.Didit;

            // Reads DIDIT_API_KEY, DIDIT_ORGANIZATION_ID
            // and DIDIT_APPLICATION_ID.
            Didit client = new Didit();

            client.cases().delete("c1a5e000-0000-4000-8000-000000000001");
        - lang: php
          label: PHP
          source: |-
            <?php

            require 'vendor/autoload.php';

            use Didit\DiditClient;

            // Reads DIDIT_API_KEY, DIDIT_ORGANIZATION_ID
            // and DIDIT_APPLICATION_ID.
            $didit = new DiditClient();

            $didit->cases->delete('c1a5e000-0000-4000-8000-000000000001');
        - lang: ruby
          label: Ruby
          source: |-
            require "didit"

            # Reads DIDIT_API_KEY, DIDIT_ORGANIZATION_ID
            # and DIDIT_APPLICATION_ID.
            didit = Didit::Client.new

            didit.cases.delete("c1a5e000-0000-4000-8000-000000000001")
        - lang: csharp
          label: .NET
          source: >-
            using System;

            using Didit;


            // Reads DIDIT_API_KEY, DIDIT_ORGANIZATION_ID

            // and DIDIT_APPLICATION_ID.

            using var client = new DiditClient();


            await
            client.Cases.DeleteAsync("c1a5e000-0000-4000-8000-000000000001");
components:
  schemas:
    InFiledReportError:
      type: object
      description: >-
        हटाने से इनकार कर दिया गया है क्योंकि चयनित डेटा एक अंतिम विनियामक
        रिपोर्ट में है। कुछ भी हटाया नहीं गया है। रिपोर्ट हटाएं, फिर अनुरोध
        दोहराएं।
      required:
        - detail
        - code
      properties:
        detail:
          type: string
        code:
          type: string
          enum:
            - in_filed_report
          description: >-
            अंतिम रूप दी गई नियामक रिपोर्ट द्वारा अवरुद्ध विलोपन के लिए स्थिर
            त्रुटि कोड।
        reports:
          type: array
          items:
            $ref: '#/components/schemas/FiledRegulatoryReport'
          description: >-
            ऐसी रिपोर्ट जो किसी व्यक्ति, कंपनी, केस या सत्र के विलोपन को ब्लॉक
            करती हैं।
        transactions:
          type: array
          items:
            $ref: '#/components/schemas/FiledReportTransaction'
          description: >-
            लेन-देन जो किसी लेन-देन विलोपन को ब्लॉक करते हैं, प्रत्येक उन
            रिपोर्टों के साथ जो इसे सूचीबद्ध करती हैं।
    FiledRegulatoryReport:
      type: object
      description: एक फ़ाइनलाइज़ की गई नियामक रिपोर्ट जो अनुरोधित विलोपन को रोकती है।
      required:
        - uuid
        - report_number
        - report_type
        - case_uuid
      properties:
        uuid:
          type: string
          format: uuid
          description: रिपोर्ट UUID।
        report_number:
          type: string
          description: कंसोल में दिखाई गई रिपोर्ट संख्या (उदाहरण के लिए, SAR-0001)।
        report_type:
          type: string
          enum:
            - SAR
            - STR
            - CTR
            - TTR
            - UTR
            - IFT
            - CBR
            - TFR
          description: नियामक रिपोर्ट प्रकार।
        case_uuid:
          type: string
          format: uuid
          description: वह केस जिससे यह रिपोर्ट संबंधित है।
    FiledReportTransaction:
      type: object
      description: >-
        एक लेन-देन जिसे हटाया नहीं जा सकता क्योंकि एक अंतिम रूप दी गई नियामक
        रिपोर्ट में इसे सूचीबद्ध किया गया है।
      required:
        - uuid
        - transaction_id
        - reports
      properties:
        uuid:
          type: string
          format: uuid
          description: Didit लेन-देन UUID।
        transaction_id:
          type: string
          description: लेन-देन बनाते समय प्रदान किया गया लेन-देन पहचानकर्ता।
        reports:
          type: array
          items:
            $ref: '#/components/schemas/FiledRegulatoryReport'
          description: अंतिम रूप दी गई रिपोर्टें जो इस लेन-देन को सूचीबद्ध करती हैं।
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: >-
        आपकी एप्लिकेशन की API कुंजी, Business Console में Developers -> API keys
        से। प्राथमिक कुंजी के पास पूर्ण एक्सेस होता है। एक नामित कुंजी को स्कोप
        किया जा सकता है: प्रति संसाधन none, read या write, कुछ वर्कफ़्लो या
        स्वीकृत सत्रों तक सीमित, IP पतों की सूची तक सीमित, और समाप्ति तिथि तक
        सीमित। 401 का अर्थ है कि कुंजी गलत है, निरस्त कर दी गई है या उसकी
        समय-सीमा समाप्त हो गई है; 403 का अर्थ है कि कोई कुंजी नहीं भेजी गई थी,
        कुंजी के पास इस संसाधन या कार्रवाई का एक्सेस नहीं है, या अनुरोध उसकी IP
        सूची से बाहर के पते से आया था; सत्र रूट पर 404 का अर्थ है कि सत्र कुंजी
        के वर्कफ़्लो या स्थितियों से बाहर है। मीडिया एक्सेस के बिना एक कुंजी को
        छवि, वीडियो और PDF URL null के रूप में प्राप्त होते हैं, और सत्र write
        के बिना एक कुंजी को सत्र लिंक और token null के रूप में प्राप्त होते हैं।
        देखें https://docs.didit.me/console/api-keys।

````

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