Email Activity Report

POST /api/reports/email-report/{crm_id}

Overview

Fetches a paginated log of outbound email activity for a specific CRM instance within a given date range. This includes details such as send method, status, recipient, and timestamps for delivery, open, and click events.

Note: This report is scoped to a single CRM instance. To query other branches, run the request against each relevant {crm_id}.

Endpoint

  • POST

    https://secure-api.setshape.com/api/reports/email-report/{crm_id}

Headers

  • Authorization: {SHAPE_API_KEY}

Request Parameters

Send the following parameters in the request body under the filters object:

  • Parameter

    fromDate


    toDate


    slctPerPage


    pn

  • Type

    String


    String


    Number


    Number

  • Description

    Start date of the report (YYYY-MM-DD)

    End date of the report (YYYY-MM-DD)

    Number of results per page


    Page number (for pagination)

Example Request Body

{

  “filters”: {

    “fromDate”: “2025-08-01”,

    “toDate”: “2025-08-08”,

    “slctPerPage”: 3,

    “pn”: 1

  }

}

Sample Response

{

  “status”: 1,

  “msg”: “success”,

  “Data”: [

    {

      “templateName”: “Sean, Mary Reed sent you a text!”,

      “lead_id”: 27925120,

      “emailRecipient”: “Mary Reed”,

      “recipientEmail”: “SBeaudry@Annie-Mac.com”,

      “sender”: “Sean Beaudry”,

      “sentFrom”: “no-reply@shapeemail.com”,

      “emailSubject”: “Sean, Mary Reed sent you a text!”,

      “sendMethod”: “Manual”,

      “status”: “Failed”,

      “dateSent”: “08/08/2025 11:57 PM”,

      “createdat”: “2025-08-09 06:57:14”,

      “processedOn”: “2025-08-09 06:57:14”,

      “deliveredOn”: “2025-08-09 06:57:16”,

      “openedOn”: “0000-00-00 00:00:00”,

      “clickedOn”: “0000-00-00 00:00:00”,

      “rejectedOn”: “0000-00-00 00:00:00”,

      “failedOn”: “2025-08-09 06:57:14”,

      “isprocessed”: true,

      “issent”: true,

      “response”: “”,

      “emailStatsId”: 8628423

    }

  ]

}

Key Fields

  • Field

    templateName


    lead_id


    emailRecipient


    recipientEmail


    sender


    sentFrom


    emailSubject


    sendMethod


    status


    dateSent


    deliveredOn


    openedOn


    clickedOn


    failedOn


    rejectedOn


    processedOn


    createdat


    isprocessed


    issent


    response


    emailStatsId

  • Description

    Name of the email template used


    ID of the lead the email is associated with


    Display name of the recipient


    Email address of the recipient


    Name of the user who sent the email

    Email address used to send (typically system-generated)


    Subject line of the email


    How the email was sent (e.g. Manual, Automated, Triggered)

    Status of the email (e.g. Sent, Failed, Delivered)

    Date and time the email was triggered to send

    Timestamp when the email was marked delivered (if successful)

    Timestamp when the email was opened


    Timestamp when a link in the email was clicked

    Timestamp when the email failed (if applicable)

    Timestamp when the email was rejected (e.g. due to invalid address)

    Timestamp when the email was processed by the system

    Timestamp when the email was created in the queue

    Boolean flag indicating whether processing completed

    Boolean flag indicating whether the send was attempted

    Response returned by the email provider (if any)

    Unique ID used for email analytics tracking

Filtering Tips

If you’re building reports on active users only, filter by:

“status”: “Active”

To isolate retired/inactive users, filter where:

 “status”: “Inactive”

Notes

  • Be sure to replace {crm_id} in the URL with the actual CRM instance ID you want to query.
  • Dates must be in the format YYYY-MM-DD.
  • If you’re paging through a large result set, adjust slctPerPage and pn as needed.

Get started with Shape today