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

# Dispatch real-time events

> Send real-time event data from end-user interactions within your application. Events will be analyzed for proactive fraud prevention and risk scoring.



## OpenAPI

````yaml post /v2/watch/event
openapi: 3.1.0
info:
  title: Prelude API
  version: 2.0.0
  description: The Prelude API allows you to send messages to your users.
  contact:
    email: support@prelude.so
servers:
  - url: https://api.prelude.dev
    description: Production server
security:
  - apiToken: []
tags:
  - name: Notify
    description: Send transactional and marketing messages with compliance enforcement.
  - name: Transactional
    description: Send transactional messages (deprecated - use Notify API instead).
  - name: Verify
    description: Verify phone numbers.
  - name: Watch
    description: Evaluate email addresses and phone numbers for trustworthiness.
  - name: Lookup
    description: >-
      Retrieve detailed information about a phone number including carrier data,
      line type, and portability status.
paths:
  /v2/watch/event:
    post:
      tags:
        - Watch
      summary: Dispatch events
      description: >-
        Send real-time event data from end-user interactions within your
        application. Events will be analyzed for proactive fraud prevention and
        risk scoring.
      operationId: dispatchEvents
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/EventWatchRequest'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/EventWatchResponse'
        '400':
          description: KO
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/Error'
                example:
                  code: invalid_events
                  message: >-
                    The provided events are invalid. See `details` field for
                    more information.
                  type: bad_request
                  param: events
                  details:
                    - path: events.0.target.value
                      message: >-
                        Target value must be a valid email address or E.164
                        formatted phone number.
                    - path: events.0.confidence
                      message: >-
                        Confidence must be one of 'maximum', 'high', 'neutral',
                        'low' or 'minimum'.
                  request_id: 3d19215e-2991-4a05-a41a-527314e6ff6a
components:
  schemas:
    EventWatchRequest:
      type: object
      properties:
        events:
          type: array
          description: >-
            A list of events to dispatch. A maximum of 100 events can be sent in
            a single request.
          maxItems: 100
          items:
            $ref: '#/components/schemas/WatchEvent'
      required:
        - events
    EventWatchResponse:
      type: object
      properties:
        status:
          type: string
          examples:
            - success
          enum:
            - success
          description: The status of the events dispatch.
        request_id:
          type: string
          examples:
            - 3d19215e-2991-4a05-a41a-527314e6ff6a
          description: >-
            A string that identifies this specific request. Report it back to us
            to help us diagnose your issues.
      required:
        - status
        - request_id
    Error:
      type: object
      properties:
        code:
          type: string
          description: The error code.
          examples:
            - invalid_phone_number
        message:
          type: string
          examples:
            - >-
              The provided phone number is invalid. Provide a valid E.164 phone
              number.
          description: A human-readable message describing the error.
        type:
          type: string
          examples:
            - bad_request
          description: The error type.
        request_id:
          type: string
          examples:
            - 3d19215e-2991-4a05-a41a-527314e6ff6a
          description: >-
            A string that identifies this specific request. Report it back to us
            to help us diagnose your issues.
      required:
        - code
        - message
        - type
    WatchEvent:
      type: object
      properties:
        target:
          $ref: '#/components/schemas/Target'
          description: The event target. Only supports phone numbers for now.
        label:
          type: string
          description: A label to describe what the event refers to.
          examples:
            - onboarding.start
            - onboarding.complete
        confidence:
          type: string
          enum:
            - maximum
            - high
            - neutral
            - low
            - minimum
          description: >
            The level of trust you place in this event, in increasing order of
            trust: `minimum`, `low`, `neutral`, `high`, `maximum`.

            Prelude uses this value to weight your signals when scoring traffic
            — events flagged with `minimum` confidence indicate end-users you
            trust the least to be legitimate, and the pipeline will use these
            signals to filter them out.
      required:
        - target
        - label
        - confidence
    Target:
      type: object
      description: The operation target. Either a phone number or an email address.
      properties:
        type:
          type: string
          enum:
            - phone_number
            - email_address
          description: The type of the target. Either "phone_number" or "email_address".
        value:
          type: string
          examples:
            - '+30123456789'
            - mail@example.com
          description: An E.164 formatted phone number or an email address.
      required:
        - type
        - value
  securitySchemes:
    apiToken:
      type: http
      scheme: bearer

````