> ## 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.

# واجهة الحصول على إعدادات webhook

> اقرأ إعدادات webhook في Didit لتطبيقك: رابط webhook القديم وسره، والوجهات، والأحداث القابلة للاشتراك، وسياسة الاحتفاظ، ومضيفات إرجاع المحافظ.



موجّه الحصول على إعدادات webhook عبر API
        نسخ الموجّه إلى الحافظة



      
      

\<pre>

\`Read my Didit application's webhook configuration through the Management API.

Endpoint:
GET https://verification.didit.me/v3/webhook/

Authentication:
Use the x-api-key header with my Didit API key. A scoped API key needs webhooks: read.

Goal:
\- Get every setting that controls how Didit sends webhooks for my application, plus the data-retention policy and the Digital ID wallet return hosts, in one call. Use it to audit the setup or to show the current configuration in a back office.

Behavior:
\- Didit delivers webhooks to webhook destinations (/v3/webhook/destinations/). Each destination has its own url, webhook_version, secret_shared_key and subscribed_events.
\- webhook_url, webhook_version and secret_shared_key at the top level are the application-level (legacy) webhook. Didit uses them only while the application has no enabled destination, and then only for status.updated and data.updated.
\- Every create, update or delete of a destination sets webhook_url to the URL of the oldest enabled destination, or null when none is enabled.
\- API-key callers always receive the application secret and every destination secret in full.

Example call:
curl -X GET "https://verification.didit.me/v3/webhook/" \
-H "x-api-key: YOUR_API_KEY"

What to read from the response:
\- endpoints: every destination, oldest first, with uuid, label, url, enabled, webhook_version, secret_shared_key and subscribed_events. Verify each webhook with the secret of the destination it was sent to.
\- available_events: every event type you can subscribe a destination to ({ value, label }).
\- webhook_url, webhook_version, secret_shared_key: the legacy webhook, only relevant when no destination is enabled.
\- data_retention_months (null means no automatic deletion), face_retention_policy and face_retention_days: the retention policy.
\- allowed_return_hosts: hosts a Digital ID wallet verification may send the person back to.
\- allowed_domains: web origins the hosted verification flow may be embedded in and may send the user back to; empty means no restriction.
\- capture_method: MOBILE or MOBILE_AND_DESKTOP. A legacy setting with no effect; capture options are set per workflow.

Failure modes:
\- 401: { "detail": "This API key has expired." }
\- 403: { "detail": "You do not have permission to perform this action." } for a missing key (a wrong, revoked or expired key gets 401); { "detail": "This API key has no read access to webhooks." } for a scoped key without webhooks: read.
\- 429: more than 600 GET requests per minute with this key; wait for Retry-After.

Side effects: none. This is a pure read, and the response contains signing secrets: never log it.

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

\</pre>



      
      

الصق في

تُرجع نقطة النهاية هذه الـ webhook على مستوى التطبيق، وهو الإعداد الذي سبق وجود الوجهات، إلى جانب قائمة [وجهات webhook](https://docs.didit.me/ar/management-api/webhook/list-destinations.md). تُرسل Didit الـ webhooks إلى وجهات webhook الخاصة بك، ويُوقَّع كل إرسال بالسر المشترك الخاص بتلك الوجهة `secret_shared_key`. أما `webhook_url` و`webhook_version` و`secret_shared_key` على المستوى الأعلى فتُستخدم فقط عندما لا تكون أي وجهة مفعّلة، وحينها لأحداث `status.updated` و`data.updated` فقط.> [!WARNING]
>
> تتضمن الاستجابة جميع المفاتيح السرية لتوقيع التطبيق. لا تتركها في السجلات ولا في الكود الذي يعمل على جانب العميل.لتغيير هذه الإعدادات، استخدم [تحديث إعدادات webhook](https://docs.didit.me/ar/management-api/webhook/update-config.md). للاطلاع على التحقق من التوقيع والـ payload، راجع [دليل webhooks](https://docs.didit.me/ar/integration/webhooks.md). أما حقول الاحتفاظ بالبيانات فراجع [الاحتفاظ بالبيانات](https://docs.didit.me/ar/console/data-retention.md).


## OpenAPI

````yaml ar/openapi-25.json GET /v3/webhook/
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/webhook/:
    get:
      tags:
        - Webhook
      summary: الحصول على تكوين webhook
      description: >-
        إرجاع إعدادات webhook الخاصة بالتطبيق في استدعاء واحد: كل [وجهة
        webhook](https://docs.didit.me/ar/management-api/webhook/list-destinations)
        مع سر التوقيع الخاص بها، وأنواع الأحداث التي يمكن لوجهة الاشتراك فيها،
        وعنوان URL لـ webhook على مستوى التطبيق (القديم)، وإصداره وسره، وسياسة
        الاحتفاظ بالبيانات والقوالب البيومترية، ومضيفي العودة لمحفظة Digital ID.
        ترسل Didit إشعارات webhook إلى الوجهات، وتكون كل منها موقعة باستخدام
        `secret_shared_key` الخاص بها؛ ويُستخدم `webhook_url` و`webhook_version`
        و`secret_shared_key` على المستوى الأعلى فقط عندما لا تكون هناك أي وجهة
        مُمكّنة، وحينها فقط للأحداث `status.updated` و`data.updated`. تحتوي
        الاستجابة على أسرار التوقيع، لذا احرص على إبقائها بعيدة عن السجلات
        والأكواد البرمجية من جانب العميل. يتطلب مفتاح API محدد النطاق إذن
        `webhooks: read`.
      operationId: get_webhook_config
      parameters: []
      responses:
        '200':
          description: تكوين webhook.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WebhookConfig'
              examples:
                One destination:
                  value:
                    webhook_url: https://yourapp.com/webhooks/didit
                    webhook_version: v3
                    secret_shared_key: dGhpcy1pcy10aGUtYXBwLWxldmVsLXNlY3JldC0wMDA
                    capture_method: MOBILE
                    data_retention_months: 24
                    face_retention_policy: delete_with_session
                    face_retention_days: null
                    biometric_consent_mode: auto
                    available_events:
                      - value: status.updated
                        label: Session status updated
                      - value: data.updated
                        label: Session data updated
                      - value: user.status.updated
                        label: User status updated
                      - value: user.data.updated
                        label: User data updated
                      - value: business.status.updated
                        label: Business status updated
                      - value: business.data.updated
                        label: Business data updated
                      - value: activity.created
                        label: Activity created
                      - value: transaction.created
                        label: Transaction created
                      - value: transaction.status.updated
                        label: Transaction status updated
                      - value: travel_rule.status.updated
                        label: Travel Rule Status Updated
                      - value: workflow.compliance_changed
                        label: Workflow Compliance Changed
                    allowed_return_hosts:
                      - shop.example.com
                    endpoints:
                      - uuid: 11111111-2222-3333-4444-555555555555
                        label: Production session webhooks
                        url: https://yourapp.com/webhooks/didit
                        enabled: true
                        webhook_version: v3
                        secret_shared_key: dGhpcy1pcy1hbi1leGFtcGxlLXNlY3JldC0wMDAwMDA
                        subscribed_events:
                          - status.updated
                          - data.updated
                        created_at: '2026-01-04T08:00:00.000000Z'
                        updated_at: '2026-04-22T14:09:11.523671Z'
        '401':
          description: >-
            انتهت صلاحية مفتاح API: تم إنشاؤه مع تاريخ انتهاء قد مضى. يتلقى
            المفتاح الخاطئ أو الملغى أيضاً `401`؛ ويتلقى المفتاح المفقود `403`.
          content:
            application/json:
              schema:
                type: object
                properties:
                  detail:
                    type: string
                    description: رسالة خطأ سهلة القراءة.
              examples:
                Expired key:
                  value:
                    detail: This API key has expired.
        '403':
          description: >-
            الطلب غير مسموح به. عند فقدان `x-api-key` أو عدم صلاحيته أو إلغائه،
            تتلقى `You do not have permission to perform this action.`. يحصل
            المفتاح ذو النطاق المحدود الذي يفتقر إلى الوصول الذي يتطلبه هذا الـ
            endpoint على رسالة تذكر نوع الوصول المفقود، والمفتاح المستخدم من
            خارج قائمة العناوين المسموح بها الخاصة به يتلقى `This API key can't
            be used from this IP address.`.
          content:
            application/json:
              schema:
                type: object
                properties:
                  detail:
                    type: string
                    description: رسالة خطأ سهلة القراءة.
              examples:
                Missing or invalid key:
                  value:
                    detail: You do not have permission to perform this action.
                Scoped key without webhooks read:
                  value:
                    detail: This API key has no read access to webhooks.
                Outside the IP allowlist:
                  value:
                    detail: This API key can't be used from this IP address.
        '429':
          description: >-
            تم تجاوز حد المعدل: أكثر من 600 طلب GET في نافذة الدقيقة الواحدة
            الحالية لمفتاح API هذا. انتظر لعدد الثواني المحدد في `Retry-After`
            قبل إعادة المحاولة.
          headers:
            Retry-After:
              description: عدد الثواني الواجب انتظارها قبل إعادة المحاولة.
              schema:
                type: integer
                minimum: 1
                example: 30
            X-RateLimit-Limit:
              description: الطلبات المسموح بها خلال نافذة الدقيقة الواحدة (600).
              schema:
                type: integer
                example: 600
            X-RateLimit-Remaining:
              description: الطلبات المتبقية في النافذة الحالية.
              schema:
                type: integer
                example: 0
            X-RateLimit-Reset:
              description: توقيت Unix (بالثواني) عند إعادة تعيين النافذة الحالية.
              schema:
                type: integer
                example: 1792056120
            X-RateLimit-Scope:
              description: اسم الميزانية التي تم تجاوزها.
              schema:
                type: string
                example: generic-get
          content:
            application/json:
              schema:
                type: object
                properties:
                  detail:
                    type: string
                    description: رسالة خطأ سهلة القراءة.
              examples:
                Throttled:
                  value:
                    detail: >-
                      GET request rate limit exceeded. You can make up to 600
                      requests per minute.
      security:
        - ApiKeyAuth: []
      x-codeSamples:
        - lang: curl
          label: curl
          source: |-
            curl -X GET 'https://verification.didit.me/v3/webhook/' \
              -H 'x-api-key: YOUR_API_KEY'
        - lang: python
          label: Python
          source: |-
            from didit import Didit

            # Reads DIDIT_API_KEY.
            client = Didit()

            result = client.webhooks.retrieve_config()
            print(result)
        - lang: javascript
          label: Node.js
          source: |-
            import Didit from "@didit-protocol/sdk-node";

            // Reads DIDIT_API_KEY.
            const didit = new Didit();

            const result = await didit.webhooks.retrieveConfig();
            console.log(result);
        - lang: go
          label: Go
          source: "ctx := context.Background()\n// Reads DIDIT_API_KEY.\nclient := didit.NewClient()\n\nresult, err := client.Webhooks.RetrieveConfig(ctx)\nif err != nil {\n\tlog.Fatal(err)\n}\nfmt.Printf(\"%+v\\n\", result)"
        - lang: java
          label: Java
          source: |-
            import me.didit.Didit;

            // Reads DIDIT_API_KEY.
            Didit client = new Didit();

            var result = client.webhooks().retrieveConfig();
            System.out.println(result);
        - lang: php
          label: PHP
          source: |-
            <?php

            require 'vendor/autoload.php';

            use Didit\DiditClient;

            // Reads DIDIT_API_KEY.
            $didit = new DiditClient();

            $result = $didit->webhooks->retrieveConfig();
            print_r($result->toArray());
        - lang: ruby
          label: Ruby
          source: |-
            require "didit"

            # Reads DIDIT_API_KEY.
            didit = Didit::Client.new

            result = didit.webhooks.retrieve_config
            puts result.to_h
        - lang: csharp
          label: .NET
          source: |-
            using System;
            using System.Text.Json;
            using Didit;

            // Reads DIDIT_API_KEY.
            using var client = new DiditClient();

            var result = await client.Webhooks.RetrieveConfigAsync();
            Console.WriteLine(JsonSerializer.Serialize(result));
components:
  schemas:
    WebhookConfig:
      type: object
      description: >-
        تكوين webhook على مستوى التطبيق، وسياسة الاحتفاظ بالبيانات، ومضيفو إرجاع
        محفظة الهوية الرقمية، مع كل وجهة webhook.
      required:
        - webhook_url
        - webhook_version
        - secret_shared_key
        - capture_method
        - data_retention_months
        - face_retention_policy
        - face_retention_days
        - available_events
        - allowed_return_hosts
        - endpoints
      properties:
        webhook_url:
          type: string
          format: uri
          nullable: true
          description: >-
            رابط webhook على مستوى التطبيق (القديم). يرسل Didit إليه فقط في حال
            عدم وجود وجهة مفعّلة للتطبيق، وحينها يرسل `status.updated`
            و`data.updated` فقط. كل عملية إنشاء أو تحديث أو حذف لوجهة تضبطه على
            عنوان URL لأقدم وجهة مفعّلة، أو `null` عند عدم وجود أي وجهة مفعّلة.
        webhook_version:
          type: string
          enum:
            - v1
            - v2
            - v3
          description: >-
            إصدار payload لـ `webhook_url` القديم. لكل وجهة `webhook_version`
            خاص بها.
        secret_shared_key:
          type: string
          description: >-
            سر التوقيع على مستوى التطبيق (token آمن لعناوين URL مكوّن من 43
            حرفاً). يقوم بتوقيع عمليات التسليم المرسلة إلى `webhook_url` القديم
            فقط؛ بينما توقّع كل وجهة باستخدام `secret_shared_key` الخاص بها.
            يستلمه مستدعو مفتاح API دائماً بالكامل؛ بينما يتلقى مستخدمو Console
            الذين لا يملكون إذن `read:webhooks` سلسلة فارغة.
        capture_method:
          type: string
          enum:
            - MOBILE
            - MOBILE_AND_DESKTOP
          description: >-
            إعداد تطبيق قديم. لا يقرأه سير التحقق: خيارات الالتقاط يتم تكوينها
            لكل سير عمل.
        data_retention_months:
          type: integer
          nullable: true
          minimum: 1
          maximum: 120
          description: >-
            نافذة الحذف التلقائي. تُحذف جلسات التحقق من المستخدمين التي تم
            إنشاؤها قبل أكثر من هذا العدد من الأشهر (الشهر يُحسب كـ 30 يومًا)
            تلقائيًا، وهذا الحذف لا يمكن التراجع عنه. تعني القيمة `null` أنه لا
            يتم حذف الجلسات تلقائيًا أبدًا. راجع [الاحتفاظ
            بالبيانات](https://docs.didit.me/ar/console/data-retention).
        face_retention_policy:
          type: string
          enum:
            - delete_with_session
            - retain_until_user_deleted
          description: >-
            ما يحدث لتضمين الوجه الخاص بالجلسة عند حذف الجلسة.
            `delete_with_session` (افتراضي) يحذفه مع الجلسة.
            `retain_until_user_deleted` هو خيار الاشتراك في [الاحتفاظ بالقالب
            البيومتري](https://docs.didit.me/ar/console/data-retention#الاحتفاظ-بالقالب-البيومتري):
            تتم إدارة قالب بيومتري خالٍ من الصور مرتبط بالمستخدم (User) بشكل
            منفصل حتى تنتهي فترة الاحتفاظ به، أو يُحذف المستخدم، أو تقوم بمسحه.
        face_retention_days:
          type: integer
          nullable: true
          minimum: 1
          maximum: 3650
          description: >-
            فترة الاحتفاظ، بالأيام، بالقوالب البيومترية بموجب
            `retain_until_user_deleted`. مطلوبة عند تعيين تلك السياسة.
        biometric_consent_mode:
          type: string
          enum:
            - auto
            - always
            - never
          description: >-
            متى يطلب التدفق المستضاف وحزم SDK الأصلية من الشخص الموافقة
            البيومترية الصريحة قبل التقاط الوجه. يطلب `auto` (الافتراضي) فقط عند
            انطباق مُشغِّل: ولاية مُعلنة، أو عنوان IP الخاص بالشخص، أو جهة إصدار
            مستند الهوية في إلينوي أو تكساس أو كولورادو، أو يبدو أن الشخص في
            الولايات المتحدة دون ولاية معروفة. يطلب `always` من كل شخص يلتقط سير
            العمل الخاص به وجهاً. لا يعرض `never` الخطوة أبداً، وتقوم بجمع
            الموافقة بنفسك قبل التقاط صورة سيلفي. يتم تسجيل كل تغيير في سجل
            التدقيق. راجع [الموافقة
            البيومترية](https://docs.didit.me/ar/getting-started/biometric-consent).
        available_events:
          type: array
          description: كل نوع حدث يمكن للوجهة الاشتراك فيه، مع تسمية للعرض.
          items:
            type: object
            required:
              - value
              - label
            properties:
              value:
                $ref: '#/components/schemas/WebhookEvent'
              label:
                type: string
                description: تسمية العرض، على سبيل المثال `Session status updated`.
        allowed_return_hosts:
          type: array
          maxItems: 20
          description: >-
            أسماء المضيفين (تطابق تام، عبر HTTPS فقط) التي يجوز لعملية تحقق
            مستقلة من محفظة الهوية الرقمية إعادة المستخدم إليها عبر
            `return_url`. يُسمح دائماً بنطاق العلامة البيضاء الخاص بك أيضاً.
            راجع [تسجيل وجهة الإرجاع الخاصة
            بك](https://docs.didit.me/ar/standalone-apis/digital-id-wallets#سجّل-وجهة-العودة-الخاصة-بك).
          items:
            type: string
            maxLength: 253
        endpoints:
          type: array
          description: >-
            كل وجهة webhook للتطبيق، الأقدم أولاً، مع سر التوقيع الخاص بكل منها.
            للقراءة فقط هنا: يمكنك إدارة الوجهات باستخدام endpoints الخاصة بـ
            `/v3/webhook/destinations/`.
          items:
            $ref: '#/components/schemas/WebhookConfigDestination'
        allowed_domains:
          type: array
          maxItems: 50
          items:
            type: string
            maxLength: 300
          description: >-
            الأصول (على سبيل المثال `https://app.example.com`؛ و`http` لـ
            `localhost` فقط) التي قد يتم تضمين سير عمل التحقق المستضاف فيها، وقد
            يُعاد إرسال المستخدم إليها عبر استدعاء رجوعي للجلسة. لا تتأثر
            الاستدعاءات بين الخوادم. تعني القائمة الفارغة عدم وجود أي قيود. يخزن
            Didit كل أصل بأحرف صغيرة دون منفذ افتراضي. أي إدخال غير صالح يفشل
            بخطأ `400` في `allowed_domains`.
          example:
            - https://app.example.com
    WebhookEvent:
      type: string
      description: >-
        اسم حدث webhook المدعوم. استخدم هذه النصوص بدقة في `subscribed_events`؛
        حيث يتم رفض القيم غير المدعومة.
      enum:
        - status.updated
        - data.updated
        - user.status.updated
        - user.data.updated
        - business.status.updated
        - business.data.updated
        - activity.created
        - transaction.created
        - transaction.status.updated
        - travel_rule.status.updated
        - workflow.compliance_changed
        - transaction_rule_suggestions.created
        - auth.signup
        - auth.login
        - auth.login_failed
        - auth.password_reset_requested
        - auth.password_reset_completed
        - auth.mfa_changed
        - auth.new_device
        - auth.account_locked
        - investigator.report.ready
        - investigator.decision.automated
        - investigator.decision.overridden
        - investigator.decision.contested
        - investigator.question.raised
        - investigator.automation.paused
        - investigator.rfi.answered
        - investigator.rfi.overdue
        - investigator.drift.detected
        - investigator.sla.breached
        - investigator.qa.failed
        - investigator.external.report.ready
    WebhookConfigDestination:
      type: object
      description: >-
        وجهة webhook كما هي مدرجة في إعدادات webhook، بدون مقاييس التسليم. يضيف
        `GET /v3/webhook/destinations/{destination_uuid}/` ملخص التسليم الخاص
        بها.
      required:
        - uuid
        - label
        - url
        - enabled
        - webhook_version
        - secret_shared_key
        - subscribed_events
        - created_at
        - updated_at
      properties:
        uuid:
          type: string
          format: uuid
          description: معرّف الوجهة.
        label:
          type: string
          maxLength: 255
          description: اسم مقروء للبشر.
        url:
          type: string
          format: uri
          maxLength: 2000
          description: HTTPS endpoint ترسل Didit الأحداث إليه.
        enabled:
          type: boolean
          description: تؤدي القيمة `false` إلى إيقاف عمليات التسليم مؤقتاً إلى هذه الوجهة.
        webhook_version:
          type: string
          enum:
            - v1
            - v2
            - v3
          description: إصدار payload المرسل إلى هذه الوجهة.
        secret_shared_key:
          type: string
          description: >-
            سر توقيع هذه الوجهة (token آمن للاستخدام في عناوين URL بطول 43
            حرفاً). تحقق من كل webhook باستخدام سر الوجهة التي أُرسل إليها.
            يتلقاه المستدعون باستخدام مفتاح API دائماً بالكامل؛ بينما يتلقى
            مستخدمو Console غير الحاصلين على إذن `read:webhooks` سلسلة فارغة.
        subscribed_events:
          type: array
          uniqueItems: true
          description: >-
            أنواع الأحداث المُسلّمة إلى هذه الوجهة. تكون فارغة عندما تم إنشاء
            الوجهة بدون أحداث، وفي هذه الحالة لا تتلقى أي شيء.
          items:
            $ref: '#/components/schemas/WebhookEvent'
        created_at:
          type: string
          format: date-time
        updated_at:
          type: string
          format: date-time
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: >-
        مفتاح API الخاص بتطبيقك، من Developers -> API keys في Business Console.
        يمتلك المفتاح الأساسي وصولاً كاملاً. يمكن تحديد نطاق المفتاح المسمى: لا
        شيء، أو قراءة، أو كتابة لكل مورد، ومحدوداً ببعض مسارات العمل أو بالجلسات
        المقبولة، وبقائمة من عناوين IP، وبتاريخ انتهاء الصلاحية. يشير 401 إلى أن
        المفتاح غير صحيح أو ملغى أو منتهي الصلاحية؛ ويشير 403 إلى أنه لم يتم
        إرسال أي مفتاح، أو أن المفتاح ليس لديه حق الوصول إلى هذا المورد أو
        الإجراء، أو أن الطلب جاء من عنوان خارج قائمة عناوين IP الخاصة به؛ ويشير
        404 في مسار جلسة إلى أن الجلسة خارج مسارات العمل أو الحالات الخاصة
        بالمفتاح. يتلقى المفتاح الذي لا يمتلك حق الوصول إلى الوسائط عناوين URL
        للصور ومقاطع الفيديو وملفات PDF كـ null، ويتلقى المفتاح الذي لا يمتلك
        إذن كتابة للجلسات روابط الجلسة وtoken كـ null. راجع
        https://docs.didit.me/console/api-keys.

````

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