All statistics

GET/api/v2/stats/all

Returns the outreach, follow-up, tag, pipeline and leaderboard statistics in one request.

Leaderboards ignore the tag filters, and only pipelines use date_property. If one part fails, the request still returns 200: that part is null and partial_errors lists what failed.

Headers

  • x-api-keyheaderRequired

    Your API key.

  • Content-Typeheader

    application/json. Not needed for this request.

Query parameters

  • start_datestring

    First day, as YYYY-MM-DD. Send both dates, or neither for all time.

  • end_datestring

    Last day, as YYYY-MM-DD. Included.

  • timezonestring

    Time zone that decides when each day starts: an IANA name (America/New_York) or an offset (+02:00). Default UTC.

  • tag_namesstring

    Tags to filter contacts by, comma-separated: hot lead,vip. Needs tag_filter_operator.

  • tag_idsstring

    The same with tag ids: 287,301.

  • tag_filter_operatorstring

    any_of (any of the tags), is (all of them), is_not (none of them), is_empty (contacts without tags) or is_not_empty (contacts with any tag).

  • date_propertystring

    created (default) counts contacts created in the period. pipeline_status_updated counts contacts whose stage changed in the period.

Errors

ErrorWhen
400
message is Validation failed and errors lists each query parameter that is not valid.
401
The API key is missing or wrong.
500
Something went wrong on our side, or timezone is not a time zone the API recognises.
Request
curl "https://app.dmtracker.ai/api/v2/stats/all?start_date=2026-10-19&end_date=2026-10-21&timezone=America/New_York" \
  -H "x-api-key: $DMTRACKER_API_KEY" \
  -H "Content-Type: application/json"
Response 200
{
  "status": "ok",
  "data": {
    "outreach": {
      "OUTREACH_SENT": {
        "total_outreach_sent": {
          "outreach_count": 120,
          "outreach_change_percent": 20
        }
      }
    },
    "follow_ups": {
      "follow_ups_count": 84
    },
    "tags": {
      "total_tags": 46
    },
    "leaderboards": {
      "follow_ups_sent_by_user": [
        {
          "user_id": "b7d2e9a4-1c3f-4e8b-9a60-5f2c8d1e7b39",
          "user_email": "alex@yourcompany.com",
          "user_full_name": "Alex Morgan",
          "user_profile_picture": null,
          "follow_ups": 50
        },
        {
          "user_id": "3e8c1f5a-7b2d-4a96-8e04-c9a1d6f2b573",
          "user_email": "sam@yourcompany.com",
          "user_full_name": "Sam Lee",
          "user_profile_picture": null,
          "follow_ups": 34
        }
      ]
    },
    "pipelines": {
      "WON_TREND": {
        "total_won": 9
      }
    }
  }
}

Shortened. Each part is the full data of its own endpoint.

Link copied