> ## 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-доставки сессии через API

> Получите одну webhook-доставку сессии в Didit: URL, HTTP-ответ вашего endpoint и точные заголовки подписи и JSON-тело, которые отправил Didit.



Промпт API для получения webhook-доставки сессии
        Скопировать промпт в буфер обмена



      
      

\<pre>

\`Retrieve one webhook delivery of a Didit verification session through the API.

Endpoint:
GET https://verification.didit.me/v3/session/{session_id}/webhook/{webhook_uuid}
(no trailing slash)

Authentication:
Send my Didit API key in the x-api-key header. A scoped key needs sessions: read and decisions: read.

Goal:
\- Read exactly what Didit sent to my webhook endpoint for one delivery and what my endpoint answered, to debug a rejected or missing event.

Behavior:
\- {webhook_uuid} is the uuid of an entry from GET /v3/session/{session_id}/webhooks/. It must belong to the session in the path; a delivery of another session returns 404.
\- request_header and request_body are JSON-encoded strings. Parse them with a JSON parser.
\- To check my signature code, recompute X-Signature-V2 from the parsed request_body with my destination's secret (the application-level secret for a delivery sent to the legacy webhook_url) and compare it with the header. A scoped key without media: read or sessions: write receives a redacted body, which no longer matches the signatures.

Example call:
curl -X GET "https://verification.didit.me/v3/session/11111111-2222-3333-4444-555555555555/webhook/9f8e7d6c-5b4a-4321-8fed-cba987654321" \
-H "x-api-key: YOUR_API_KEY"

What to read from the response:
\- response_status: the HTTP status my endpoint returned (null while queued, 504 timeout, 503 connection failure, 400 URL refused as unsafe).
\- request_url: where it was sent.
\- request_header: the X-Signature, X-Signature-V2, X-Signature-Simple and X-Timestamp values sent.
\- request_body: the webhook payload (event_id, webhook_type, session_id, status, decision when present).
\- status, webhook_type, created_at.

Failure modes:
\- 401: the API key has expired.
\- 403: missing key (a wrong, revoked or expired key gets 401), a key of another application, a scoped key without the permissions above, or a request from outside the key's IP allowlist.
\- 404: the session does not exist, was deleted, or is outside a scoped key's limits, or the delivery does not belong to this session ({ "detail": "No WebhookLog matches the given query." }).
\- 429: more than 600 reads per minute for this API key; honor Retry-After.

Side effects: none. This is a pure read.

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

\</pre>



      
      

Вставьте в

Payload внутри `request_body` описан в разделе [Webhook](https://docs.didit.me/ru/integration/webhooks.md#структура-payload), а заголовки описаны в разделе [проверка подписи](https://docs.didit.me/ru/integration/webhooks.md#проверка-подписи). Чтобы отправить доставку повторно, используйте [Повторная отправка доставки webhook для сессии](https://docs.didit.me/ru/management-api/sessions/resend-webhook.md).


## OpenAPI

````yaml ru/openapi-25.json GET /v3/session/{sessionId}/webhook/{webhook_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/session/{sessionId}/webhook/{webhook_uuid}:
    get:
      tags:
        - Sessions
      summary: Получить доставку webhook сессии
      description: >-
        Получить одну доставку webhook для сессии верификации: URL, на который
        она была отправлена, HTTP-статус, возвращённый вашим endpoint, а также
        точные заголовки и JSON-тело, отправленные Didit. Поля `request_header`
        и `request_body` представляют собой текст JSON; чтобы выполнить вашу
        [проверку
        подписи](https://docs.didit.me/ru/integration/webhooks#проверка-подписи),
        пересчитайте `X-Signature-V2` на основе распарсенного тела с секретом
        адреса назначения, на который была отправлена доставка (или секретом
        уровня приложения для доставки на устаревший URL webhook). Путь не
        содержит слэша на конце: с ним возвращается ошибка `404`. API-ключу с
        ограниченной областью действия требуются разрешения `sessions: read` и
        `decisions: read`.
      operationId: get_v3_session_webhook
      parameters:
        - name: sessionId
          in: path
          required: true
          description: >-
            UUID сессии верификации, пользователя (KYC) или компании (KYB):
            `session_id`, возвращённый `POST /v3/session/`. Сервер сопоставляет
            его для обоих типов сессий.


            **Должен быть корректным UUID.** Маршрут сопоставляется только с
            корректно сформированными UUID, поэтому некорректное значение
            отклоняется маршрутизатором URL ещё до выполнения кода приложения, и
            в ответ возвращается **HTML**-страница `404`, а не конверт JSON
            `{"detail": ...}`, показанный ниже.
          schema:
            type: string
            format: uuid
          example: 22222222-3333-4444-5555-666666666666
        - name: webhook_uuid
          in: path
          required: true
          description: >-
            UUID доставки: `uuid` записи, возвращаемой методом `GET
            /v3/session/{sessionId}/webhooks/`. Он должен принадлежать сессии,
            указанной в пути.
          schema:
            type: string
            format: uuid
          example: 66666666-7777-8888-9999-000000000001
      responses:
        '200':
          description: Доставка вместе с заголовками и телом её запроса.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SessionWebhookDelivery'
              examples:
                Connection failure:
                  value:
                    uuid: 66666666-7777-8888-9999-000000000001
                    session_id: 22222222-3333-4444-5555-666666666666
                    request_url: https://yourapp.com/webhooks/didit
                    response_status: 503
                    status: In Progress
                    webhook_type: status.updated
                    request_header: >-
                      {"Content-Type": "application/json", "X-Signature":
                      "a5e02a03404e1337a0198e6be15d34abbd053c658a0e51e5d0e78554213ef29b",
                      "X-Signature-V2":
                      "927e7cb770c94ce745939bff73f04aa200015f3bc64795ba46c2aaf78a6cedc5",
                      "X-Signature-Simple":
                      "e37b0d4c716c72bb5ae7127b9cc455d28ab4686e9e22312b4ec2327409a73302",
                      "X-Timestamp": "1792056078", "User-Agent":
                      "DiditWebhook/2.0 +https://didit.me"}
                    request_body: >-
                      {"application_id":"aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee","created_at":1792056057,"environment":"live","event_id":"33333333-4444-5555-6666-777777777777","sandbox_scenario":null,"session_id":"22222222-3333-4444-5555-666666666666","status":"In
                      Progress","timestamp":1792056078,"vendor_data":"user-123","webhook_type":"status.updated","workflow_id":"44444444-5555-6666-7777-888888888888","workflow_version":3}
                    created_at: '2026-10-15T09:21:18.412345Z'
        '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`, а также недействительный
            или отозванный ключ возвращают `Authentication credentials were not
            provided or are invalid.` Ключ другого приложения возвращает `You do
            not have permission to perform this action.` Ключ с ограниченной
            областью действия без требуемых для этого endpoint прав возвращает
            сообщение с указанием недостающих разрешений, а ключ, используемый
            не из разрешённого списка IP-адресов, возвращает `This API key can't
            be used from this IP address.` Неизвестный `sessionId` возвращает
            `404` ещё до проверки учётных данных.
          content:
            application/json:
              schema:
                type: object
                properties:
                  detail:
                    type: string
                    description: Понятное сообщение об ошибке.
              examples:
                Missing or invalid key:
                  value:
                    detail: >-
                      Authentication credentials were not provided or are
                      invalid.
                Key of another application:
                  value:
                    detail: You do not have permission to perform this action.
                Scoped key without sessions read:
                  value:
                    detail: This API key has no read access to sessions.
                Scoped key without decisions read:
                  value:
                    detail: This API key has no read access to decisions.
                Outside the IP allowlist:
                  value:
                    detail: This API key can't be used from this IP address.
        '404':
          description: >-
            Сессия не существует или была удалена (`Not found.`, возвращается до
            проверки учетных данных), либо находится за пределами ограничений по
            сценариям или статусам для ключа с ограниченным доступом (`Session
            not found.`). Доставка, которая не существует, принадлежит другой
            сессии или больше недоступна, возвращает `No WebhookLog matches the
            given query.`
          content:
            application/json:
              schema:
                type: object
                properties:
                  detail:
                    type: string
                    description: Понятное сообщение об ошибке.
              examples:
                Unknown session:
                  value:
                    detail: Not found.
                Outside the key's limits:
                  value:
                    detail: Session not found.
                Delivery not in this session:
                  value:
                    detail: No WebhookLog matches the given query.
        '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/session/22222222-3333-4444-5555-666666666666/webhook/66666666-7777-8888-9999-000000000001'
            \
              -H 'x-api-key: YOUR_API_KEY'
        - lang: python
          label: Python
          source: |-
            from didit import Didit

            # Reads DIDIT_API_KEY.
            client = Didit()

            result = client.sessions.webhooks.retrieve(
                "22222222-3333-4444-5555-666666666666",
                "66666666-7777-8888-9999-000000000001",
            )
            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.sessions.webhooks.retrieve(
              "22222222-3333-4444-5555-666666666666",
              "66666666-7777-8888-9999-000000000001",
            );
            console.log(result);
        - lang: go
          label: Go
          source: "ctx := context.Background()\n// Reads DIDIT_API_KEY.\nclient := didit.NewClient()\n\nresult, err := client.Sessions.Webhooks.Retrieve(ctx, \"22222222-3333-4444-5555-666666666666\", \"66666666-7777-8888-9999-000000000001\")\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.sessions().webhooks().retrieve("22222222-3333-4444-5555-666666666666",
            "66666666-7777-8888-9999-000000000001");

            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->sessions->webhooks->retrieve('22222222-3333-4444-5555-666666666666',
            '66666666-7777-8888-9999-000000000001');

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

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

            result = didit.sessions.webhooks.retrieve(
              "22222222-3333-4444-5555-666666666666",
              "66666666-7777-8888-9999-000000000001"
            )
            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.Sessions.Webhooks.RetrieveAsync("22222222-3333-4444-5555-666666666666",
            "66666666-7777-8888-9999-000000000001");

            Console.WriteLine(JsonSerializer.Serialize(result));
components:
  schemas:
    SessionWebhookDelivery:
      type: object
      description: >-
        Одна попытка доставки webhook, зафиксированная для сессии верификации, с
        точными заголовками и телом запроса, отправленными Didit.
      required:
        - uuid
        - session_id
        - request_url
        - response_status
        - status
        - webhook_type
        - request_header
        - request_body
        - created_at
      properties:
        uuid:
          type: string
          format: uuid
          description: >-
            ID доставки. Используйте его в качестве `{webhook_uuid}`, чтобы
            получить или повторно отправить эту доставку.
        session_id:
          type: string
          format: uuid
          description: Сессия, к которой относится доставка (сессия в пути URL).
        request_url:
          type: string
          format: uri
          nullable: true
          description: URL, на который была отправлена доставка.
        response_status:
          type: integer
          nullable: true
          description: >-
            HTTP-статус, возвращённый вашим endpoint. `null`, пока доставка
            находится в очереди и попытка ещё не совершена. Если HTTP-ответ не
            был получен, Didit фиксирует собственный статус: `504`, если ваш
            endpoint не ответил в течение 5 секунд, `503` при ошибке
            подключения, `400`, если URL был отклонён как небезопасный
            (например, приватный или внутренний адрес), и `404` при любой другой
            ошибке запроса. Статус `400` или выше считается неудачной доставкой.
        status:
          type: string
          nullable: true
          description: >-
            Статус сессии на момент генерации события, например `In Progress`,
            `Approved` или `Declined`.
        webhook_type:
          $ref: '#/components/schemas/WebhookEvent'
        request_header:
          type: string
          description: >-
            JSON-текст (строка) заголовков запроса, отправленных Didit:
            `Content-Type`, `X-Signature`, `X-Signature-V2`,
            `X-Signature-Simple`, `X-Timestamp` и `User-Agent`. Разберите его с
            помощью JSON-парсера. Он содержит подписи и никогда не содержит
            секрет подписи.
        request_body:
          type: string
          description: >-
            JSON-текст (строка) точного payload, отправленного Didit, с
            отсортированными ключами, включая `event_id` и `timestamp`.
            Разберите его с помощью JSON-парсера; см. [Формат
            payload](https://docs.didit.me/ru/integration/webhooks#структура-payload).
            Для ключа с ограниченной областью действия без `media: read`
            URL-адреса медиафайлов внутри него имеют значение `null`; без
            `sessions: write` токены сессий и ссылки на размещённую страницу
            верификации имеют значение `null`. После такого изменения тела
            подписи больше ему не соответствуют. Didit не сохраняет тело ответа,
            возвращённое вашим endpoint.
        created_at:
          type: string
          format: date-time
          description: Когда была создана доставка.
    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
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: >-
        API-ключ вашего приложения из раздела «Разработчикам» -> «API-ключи» в
        Business Console. Основной ключ имеет полный доступ. Именованный ключ
        может иметь ограниченную область действия: без доступа, чтение или
        запись для каждого ресурса, ограничение определенными сценариями или
        одобренными сессиями, списком IP-адресов и сроком действия. 401
        означает, что ключ неверен, отозван или его срок действия истек; 403
        означает, что ключ не был передан, у ключа нет доступа к этому ресурсу
        или действию, либо запрос поступил с адреса вне его списка IP-адресов;
        404 на маршруте сессии означает, что сессия не входит в сценарии или
        статусы ключа. Ключ без доступа к медиа получает URL изображений, видео
        и PDF как null, а ключ без прав на запись сессий получает ссылки на
        сессии и токены как null. См. https://docs.didit.me/console/api-keys.

````

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