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

# Test screening webhook

> Triggers a simulated payload to the destination URL, with the webhook key in the "x-webhook-key" header. The header and payload have the same structure as in production, so you can use this endpoint during development to test how your service handles the configured webhooks. The main use case is confirming that the destination server and path are configured correctly and that the receiving service can authenticate the webhook key.

**Notice:** the fields you provide are echoed through as-is. The test endpoint applies no conditional simulation, so it does not check that the field values match the configured conditions for triggering the webhook. Provide the fields that trigger the logic in your own service implementation.




## OpenAPI

````yaml /api-reference/admin-api.json post /v2/webhooks/screening/{webhookId}/test
openapi: 3.0.0
info:
  version: 1.0.0
  title: MinervaAI Admin API
  description: Admin endpoints for the Minerva application suite.
servers:
  - url: https://admin-api.gominerva.com
    description: The instance of admin-api to send the Swagger test requests to
security:
  - ApiKeyAuth: []
tags: []
paths:
  /v2/webhooks/screening/{webhookId}/test:
    post:
      tags:
        - Screening Webhooks
      summary: Test screening webhook
      description: >
        Triggers a simulated payload to the destination URL, with the webhook
        key in the "x-webhook-key" header. The header and payload have the same
        structure as in production, so you can use this endpoint during
        development to test how your service handles the configured webhooks.
        The main use case is confirming that the destination server and path are
        configured correctly and that the receiving service can authenticate the
        webhook key.


        **Notice:** the fields you provide are echoed through as-is. The test
        endpoint applies no conditional simulation, so it does not check that
        the field values match the configured conditions for triggering the
        webhook. Provide the fields that trigger the logic in your own service
        implementation.
      parameters:
        - in: path
          name: webhookId
          required: true
          schema:
            type: string
            format: uuid
          description: The unique identifier of the webhook to test
          example: ecc9b161-e6bf-48e4-816d-b13046a42eaa
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/WebhookTestRequest'
            example:
              eventKind: profile_status_updated
              eventValue: accepted
              latestFlags:
                - Sanctions
                - PEP
                - News
              profileId: minerva-profile-id-1
              externalId: user-profile-id-1
      responses:
        '200':
          description: Webhook test triggered successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WebhookTestResponse'
              example:
                status: 200
                message: Webhook test triggered successfully
                payload:
                  webhookId: ecc9b161-e6bf-48e4-816d-b13046a42eaa
                  webhookName: Test webhook
                  event:
                    kind: profile_status_updated
                    value: accepted
                    meta:
                      latestFlags:
                        - name: screeningSanctionsMatch
                          count: 1
                          label: Sanctions
                        - name: screeningPepMatch
                          count: 1
                          label: PEP
                        - name: screeningAdverseMediaMatch
                          count: 1
                          label: Adverse Media
                      profileId: minerva-profile-id-1
                      externalId: user-profile-id-1
        '400':
          description: 'Bad request: invalid request body, or webhook not found.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiError'
              example:
                status: 400
                message: Invalid event kind provided
                code: VALIDATION_ERROR
        '403':
          description: API key invalid or insufficient permissions
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiError'
        '404':
          description: Webhook not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiError'
              example:
                status: 404
                message: Webhook not found
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiError'
      security:
        - ApiKeyAuth: []
components:
  schemas:
    WebhookTestRequest:
      type: object
      description: Request body for testing a screening webhook
      properties:
        eventKind:
          $ref: '#/components/schemas/ScreeningEventKind'
          description: >-
            The mock event kind to send in the webhook payload. It passes
            through unchanged into the mock payload delivered to the webhook
            destination URL.
        eventValue:
          $ref: '#/components/schemas/ScreeningEventValue'
          description: >-
            The mock event value to send in the webhook payload. It passes
            through unchanged into the mock payload delivered to the webhook
            destination URL.
        latestFlags:
          type: array
          items:
            type: string
            enum:
              - Sanctions
              - PEP
              - News
              - Criminal
              - Legal
              - Registries
              - Ownership
              - Offshore
              - Open Source
              - Social Media
          description: >-
            The mock flags to send in the **latestFlags** webhook payload field.
            Minerva interprets these values and builds real object mocks in the
            webhook payload sent to the destination URL.
          example:
            - Sanctions
            - PEP
            - News
        profileId:
          type: string
          description: >-
            The mock profile ID to send in the payload to the destination URL.
            Optional. Provide it to test the webhook update for a specific
            Minerva profile ID within your service logic.
          example: minerva-profile-id-1
        externalId:
          type: string
          description: >-
            The mock external ID to send in the payload to the destination URL.
            Optional. Provide it to test the webhook update for a specific
            external system ID within your service logic.
          example: user-profile-id-1
      required:
        - eventKind
        - eventValue
    WebhookTestResponse:
      type: object
      description: Response from testing a screening webhook
      properties:
        status:
          type: integer
          description: HTTP status code
          example: 200
        message:
          type: string
          description: Response message
          example: Webhook test triggered successfully
        payload:
          type: object
          description: The payload that was sent to the destination webhook
          properties:
            webhookId:
              type: string
              format: uuid
              description: The unique identifier of the webhook
              example: ecc9b161-e6bf-48e4-816d-b13046a42eaa
            webhookName:
              type: string
              description: The name of the webhook
              example: Test webhook
            event:
              type: object
              description: The event data that was sent
              properties:
                kind:
                  $ref: '#/components/schemas/ScreeningEventKind'
                value:
                  $ref: '#/components/schemas/ScreeningEventValue'
                meta:
                  type: object
                  description: Additional metadata for the event
                  properties:
                    latestFlags:
                      type: array
                      description: Array of flag objects with name, count, and label
                      items:
                        type: object
                        properties:
                          name:
                            type: string
                            description: The internal flag name
                            example: screeningSanctionsMatch
                          count:
                            type: integer
                            description: The count of matches
                            example: 1
                          label:
                            type: string
                            description: The human-readable flag label
                            example: Sanctions
                        required:
                          - name
                          - count
                          - label
                    profileId:
                      type: string
                      description: The profile ID that was sent
                      example: minerva-profile-id-1
                    externalId:
                      type: string
                      description: The external ID that was sent
                      example: user-profile-id-1
                  required:
                    - latestFlags
                    - profileId
                    - externalId
              required:
                - kind
                - value
                - meta
          required:
            - webhookId
            - webhookName
            - event
      required:
        - status
        - message
        - payload
    ApiError:
      type: object
      description: Standard API error response
      properties:
        status:
          type: number
          description: HTTP status code
          example: 400
        message:
          type: string
          description: Error message
          example: Bad request
        code:
          type: string
          description: Error code
          example: VALIDATION_ERROR
      required:
        - status
        - message
    ScreeningEventKind:
      type: string
      enum:
        - profile_status_updated
        - idv
        - onboarding
      description: >-
        The kind of the event to subscribe to. Supported workspace webhook kinds
        are screening profile status updates ("profile_status_updated"), IDV
        lifecycle events ("idv"), and profile onboarding lifecycle events
        ("onboarding"). See the [Webhooks](/api-reference/webhooks) reference
        for configuration, payloads, and delivery details.
      example: profile_status_updated
    ScreeningEventValue:
      type: string
      enum:
        - potential_match
        - accepted
        - rejected
        - idv.session.completed
        - idv.session.approved
        - idv.session.rejected
        - idv.session.requires_review
        - idv.session.failed
        - idv.document.captured
        - profile_onboarding.review_required
        - profile_onboarding.completed
        - profile_onboarding.failed
      description: >-
        The required values for the event that should be subscribed to. Values
        are validated against the selected event kind; screening values cannot
        be used under IDV or onboarding kinds, and vice versa.
      example: potential_match
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: >-
        Admin API key for authentication. Manage API keys in the Minerva
        dashboard under Administration > Developers.

````

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