> ## 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 Hapus Tujuan Webhook

> Hapus permanen tujuan webhook Didit, beserta rahasia penandatanganan dan log pengirimannya. Operasi webhook bayar per panggilan, tanpa kontrak.



Prompt API Penghapusan Tujuan Webhook
        Salin prompt ke papan klip



      
      

\<pre>

\`Delete a Didit webhook destination through the Management API.

Endpoint:
DELETE https://verification.didit.me/v3/webhook/destinations/{destination_uuid}/

Authentication:
Use the x-api-key header with my Didit API key.

Goal:
\- Delete a destination so Didit stops pushing webhooks to its URL. Use this when retiring an integration, rotating to a new URL, or cleaning up test destinations.

Path parameter:
\- destination_uuid — the destination UUID from GET /v3/webhook/destinations/.

Important semantics:
\- After this call, no new webhook is sent to this destination's URL. Other destinations subscribed to the same events keep receiving deliveries.
\- The destination, its signing secret and its entire delivery log are deleted permanently and cannot be recovered; its deliveries, delivery detail and resend routes answer 404.
\- The destination disappears from GET /v3/webhook/destinations/ and subsequent GET /v3/webhook/destinations/{destination_uuid}/ calls return 404.
\- Didit also updates the application's legacy webhook_url: it becomes the URL of the oldest remaining enabled destination, or is cleared when no enabled destination is left, so other tooling sees "no webhook configured".
\- Returns 204 No Content with an empty body on success.
\- Idempotent in effect: calling DELETE again on the same UUID returns 404.

Workflow when rotating endpoints:
1\. POST /v3/webhook/destinations/ to create the new destination and capture its secret_shared_key.
2\. Verify the new endpoint is receiving and validating webhooks correctly.
3\. DELETE the old destination.

Example call:
curl -X DELETE "https://verification.didit.me/v3/webhook/destinations/{destination_uuid}/" \
-H "x-api-key: YOUR_API_KEY"

Failure modes:
\- 401 — missing or malformed x-api-key.
\- 403 — canonical { "detail": "You do not have permission to perform this action." } envelope.
\- 404 — destination not found in this application (or already deleted).

Side effects:
\- The destination, its signing secret and its delivery log are deleted permanently. This cannot be undone.
\- No new webhook is sent to its URL.

For the full integration shape, see /integration/integration-prompt.`

\</pre>



      
      

Tempel ke

> [!WARNING]
>
> Menghapus tujuan bersifat permanen.
> Tujuan, rahasia penandatanganannya, dan seluruh log pengiriman akan dihapus dan tidak dapat dipulihkan.


## OpenAPI

````yaml id/openapi-25.json DELETE /v3/webhook/destinations/{destination_uuid}/
openapi: 3.0.0
info:
  version: 3.0.0
  title: Didit Verification API
  description: API Verifikasi Identitas. Lakukan autentikasi dengan header x-api-key.
servers:
  - url: https://verification.didit.me
security: []
tags: []
paths:
  /v3/webhook/destinations/{destination_uuid}/:
    delete:
      tags:
        - Webhook
      summary: Hapus tujuan webhook
      description: >-
        Hapus tujuan webhook, rahasia penandatanganannya, dan seluruh log
        pengirimannya secara permanen. Tindakan ini tidak dapat dibatalkan.
        Tidak ada webhook baru yang dikirim ke URL tujuan; tujuan lain yang
        berlangganan event yang sama akan tetap menerimanya. Setelah itu, tujuan
        tidak lagi muncul di `GET /v3/webhook/destinations/`, dan setiap rute di
        bawah `/v3/webhook/destinations/{destination_uuid}/`, termasuk
        pengirimannya, detail pengiriman, serta pengiriman ulangnya, merespons
        dengan 404. `webhook_url` lama aplikasi diatur ke URL tujuan aktif
        tertua yang tersisa, atau dikosongkan jika tidak ada tujuan aktif yang
        tersisa. Memanggil DELETE lagi mengembalikan 404.
      operationId: delete_webhook_destination
      parameters:
        - name: destination_uuid
          in: path
          required: true
          description: UUID tujuan yang akan dihapus.
          schema:
            type: string
            format: uuid
          example: 11111111-2222-3333-4444-555555555555
      responses:
        '204':
          description: >-
            Tujuan, rahasia penandatanganan, dan log pengiriman dihapus secara
            permanen. Tidak ada isi respons.
        '403':
          description: >-
            Kunci API tidak ada, format salah, kedaluwarsa, atau memiliki
            cakupan untuk aplikasi yang berbeda. Kunci yang tidak ada
            mengembalikan `403`; kunci yang salah, dicabut, atau kedaluwarsa
            mengembalikan `401`.
          content:
            application/json:
              examples:
                Forbidden:
                  value:
                    detail: You do not have permission to perform this action.
        '404':
          description: >-
            Tidak ada tujuan dengan UUID ini untuk aplikasi tersebut (sudah
            dihapus atau tidak pernah ada).
          content:
            application/json:
              examples:
                Not found:
                  value:
                    detail: Webhook destination not found.
        '429':
          description: Batas laju terlampaui; lakukan back off dan coba lagi.
          content:
            application/json:
              examples:
                Throttled:
                  value:
                    detail: Request was throttled. Expected available in 30 seconds.
      security:
        - ApiKeyAuth: []
      x-codeSamples:
        - lang: curl
          label: curl
          source: >-
            curl -X DELETE
            'https://verification.didit.me/v3/webhook/destinations/11111111-2222-3333-4444-555555555555/'
            \
              -H 'x-api-key: YOUR_API_KEY'
        - lang: python
          label: Python
          source: |-
            from didit import Didit

            # Reads DIDIT_API_KEY.
            client = Didit()

            client.webhooks.destinations.delete(
                "11111111-2222-3333-4444-555555555555",
            )
        - lang: javascript
          label: Node.js
          source: >-
            import Didit from "@didit-protocol/sdk-node";


            // Reads DIDIT_API_KEY.

            const didit = new Didit();


            await
            didit.webhooks.destinations.delete("11111111-2222-3333-4444-555555555555");
        - lang: go
          label: Go
          source: "ctx := context.Background()\n// Reads DIDIT_API_KEY.\nclient := didit.NewClient()\n\nif err := client.Webhooks.Destinations.Delete(ctx, \"11111111-2222-3333-4444-555555555555\"); err != nil {\n\tlog.Fatal(err)\n}"
        - lang: java
          label: Java
          source: >-
            import me.didit.Didit;


            // Reads DIDIT_API_KEY.

            Didit client = new Didit();


            client.webhooks().destinations().delete("11111111-2222-3333-4444-555555555555");
        - lang: php
          label: PHP
          source: >-
            <?php


            require 'vendor/autoload.php';


            use Didit\DiditClient;


            // Reads DIDIT_API_KEY.

            $didit = new DiditClient();


            $didit->webhooks->destinations->delete('11111111-2222-3333-4444-555555555555');
        - lang: ruby
          label: Ruby
          source: >-
            require "didit"


            # Reads DIDIT_API_KEY.

            didit = Didit::Client.new


            didit.webhooks.destinations.delete("11111111-2222-3333-4444-555555555555")
        - lang: csharp
          label: .NET
          source: >-
            using System;

            using Didit;


            // Reads DIDIT_API_KEY.

            using var client = new DiditClient();


            await
            client.Webhooks.Destinations.DeleteAsync("11111111-2222-3333-4444-555555555555");
components:
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: >-
        Kunci API aplikasi Anda, dari Developers -> API keys di Business
        Console. Kunci utama memiliki akses penuh. Kunci bernama dapat diberi
        cakupan: none, read, atau write per sumber daya, dibatasi pada beberapa
        alur kerja atau pada sesi yang disetujui, pada daftar alamat IP, dan
        pada tanggal kedaluwarsa. 401 berarti kuncinya salah, dicabut, atau
        kedaluwarsa; 403 berarti tidak ada kunci yang dikirimkan, kunci tidak
        memiliki akses ke sumber daya atau tindakan ini, atau permintaan datang
        dari alamat di luar daftar IP-nya; 404 pada rute sesi berarti sesi
        berada di luar alur kerja atau status kunci tersebut. Kunci tanpa akses
        media menerima URL gambar, video, dan PDF sebagai null, dan kunci tanpa
        izin tulis sesi menerima tautan sesi dan token sebagai null. Lihat
        https://docs.didit.me/console/api-keys.

````

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