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

# List message events

> Returns delivery and engagement events for messages (sends, opens, bounces, reads). You must supply at least one of `contact_id` or `message_id`.

Get delivery and engagement events

**Response shape:** `data` is an object containing `results` only — no page metadata.



## OpenAPI

````yaml /api-reference/specs/messages.json get /api/messages/events
openapi: 3.1.0
info:
  title: ConveYour API — Messages
  description: >-
    Send SMS and email messages to contacts, and manage conversation thread
    assignments.
  version: 1.0.0
servers:
  - url: https://{subdomain}.conveyour.com
    description: Your organization's ConveYour instance
    variables:
      subdomain:
        default: acme
        description: >-
          Your organization's slug — the subdomain you sign in on. Replace
          `acme` with yours: if you sign in at `bigco.conveyour.com`, enter
          `bigco`.
security:
  - conveyourToken: []
tags:
  - name: Messages
    description: >-
      Send SMS and email messages to contacts, and manage conversation thread
      assignments.
paths:
  /api/messages/events:
    get:
      tags:
        - Messages
      summary: List message events
      description: >-
        Returns delivery and engagement events for messages (sends, opens,
        bounces, reads). You must supply at least one of `contact_id` or
        `message_id`.


        Get delivery and engagement events


        **Response shape:** `data` is an object containing `results` only — no
        page metadata.
      operationId: getDeliveryAndEngagementEvents
      parameters:
        - name: contact_id
          in: query
          description: >-
            Filter events for a specific contact. Required unless `message_id`
            is provided.
          schema:
            type: string
        - name: message_id
          in: query
          description: >-
            Filter events for a specific message. Required unless `contact_id`
            is provided.
          schema:
            type: string
        - name: event
          in: query
          description: Filter by event type (e.g. `send`, `open`, `bounce`, `read`).
          schema:
            type: string
        - name: limit
          in: query
          description: 'Maximum number of events to return. Default: `5000`.'
          schema:
            type: integer
        - name: format
          in: query
          description: Pass `csv` to download results as a CSV file instead of JSON.
          schema:
            type: string
        - $ref: '#/components/parameters/teams'
      responses:
        '200':
          description: Success.
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/Envelope'
                  - type: object
                    properties:
                      data:
                        $ref: '#/components/schemas/MessageEvents'
              example:
                status: ok
                message: message found
                data:
                  results:
                    - m_id: 64a1b2c3d4e5f6a7b8c9d0e1
                      con_id: 64a1b2c3d4e5f6a7b8c9d0e2
                      event: open
                      ts: 1718438400
                      contact_first_name: Jane
                      contact_last_name: Doe
                      contact_name: Jane Doe
                      contact_mobile: '+15555550100'
        '403':
          $ref: '#/components/responses/Forbidden'
components:
  parameters:
    teams:
      name: teams[]
      in: query
      description: >-
        Team scope for the request, as one or more team ObjectIds. The brackets
        are required: PHP keeps only the last value for a repeated plain key, so
        `teams=A&teams=B` silently resolves to B alone. On requests with a JSON
        body you may send `teams` (no brackets) in the body instead.


        **Values that are not valid ObjectIds are silently ignored** — a
        mistyped team ID behaves as if no team was sent. See the [teams section
        of the API conventions guide](/guides/api-conventions#team-scoping).
      style: form
      explode: true
      schema:
        type: array
        items:
          type: string
      example:
        - 64a1b2c3d4e5f6a7b8c9d0ff
  schemas:
    Envelope:
      type: object
      description: The common response envelope shared by all ConveYour endpoints.
      properties:
        status:
          type: string
          enum:
            - ok
            - failed
          description: '`ok` on success, `failed` on error.'
        message:
          type: string
          description: Human-readable description of the result.
        data:
          description: >-
            The response payload — an object or an array depending on the
            endpoint.
    MessageEvents:
      type: object
      description: >-
        Message delivery events. `page`, `pages` and `count` are present only
        when the request paginates — pagination is disabled whenever `limit` is
        below `limits.message_events`, in which case only `results` is returned.
      properties:
        page:
          type: integer
          description: Current page. Present only when paginating.
        pages:
          type: integer
          description: Total pages. Present only when paginating.
        count:
          type: integer
          description: Total matching events. Present only when paginating.
        results:
          type: array
          items:
            $ref: '#/components/schemas/MessageEvent'
          description: The events, newest first.
      required:
        - results
    MessageEvent:
      allOf:
        - type: object
          description: A message report row with contact details resolved and attached.
          properties:
            contact_first_name:
              type:
                - string
                - 'null'
              description: Resolved from con_id at read time.
            contact_last_name:
              type:
                - string
                - 'null'
              description: Resolved from con_id at read time.
            contact_name:
              type:
                - string
                - 'null'
              description: Resolved from con_id at read time.
            contact_mobile:
              type:
                - string
                - 'null'
              description: Resolved from con_id at read time.
  responses:
    Forbidden:
      description: >-
        The token is missing or invalid, or the service account behind it lacks
        the permission this endpoint requires.
      content:
        application/json:
          example:
            status: failed
            message: Lacking necessary permission add_contacts
            data:
              permission: add_contacts
  securitySchemes:
    conveyourToken:
      type: apiKey
      in: header
      name: x-conveyour-token
      description: >-
        Your API key token. Contacts endpoints require a **Server-only — Full
        API** key — see [Authentication](/quickstart).

````

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