Overview
Mixpanel is product analytics – events, profiles, cohorts, funnels, exports. The Automize connector covers track (ingest), engage (people profiles), exports, JQL queries, annotations, and lookup-table / group management.
- Regions: US (api.mixpanel.com) and EU (api-eu.mixpanel.com). Set the region on the project at creation time – projects can't be migrated between regions.
- Plans: Free tier has unlimited events, but Cohort export, Group Analytics, and JQL all require Growth or Enterprise. Service-account auth (which the connector uses) is paid-only.
Setting up the connection
Auth type: HTTP Basic.
- In Mixpanel → Project Settings → Service Accounts, click Create. Pick a role (Admin / Member / Consumer) – Consumer is enough for read-only Export + JQL flows.
- Copy the username (looks like 'name.<random>.mp-service-account') and secret.
- In Automize, paste the service-account username + secret, plus the Project ID (visible in Project Settings → Overview).
- Ingest endpoints (track, track-batch, engage, groups) also accept the project token alone – but the connector standardises on service accounts so the same credential covers query + ingest.
Find your credentials at https://docs.mixpanel.com/docs/orgs-and-projects/service-accounts.
Rate limits
Ingest (track / track-batch / engage): 2000 req/sec, batches up to 2000 events. Query (export / JQL / engage queries): 60 req/hour per project on free plans, higher on Growth+. Connector backs off on 429 with the Retry-After hint.
Data model
Mixpanel's analytics graph:
Organization
└─ Projects (separate token + secret per project)
├─ Events (timestamped, $insert_id-deduped)
│ └─ Properties (dict; reserved keys prefixed $)
├─ People (Users)
│ ├─ distinct_id (canonical user identifier)
│ └─ Properties ($set, $add, $append, $union, $unset)
├─ Groups (entity analytics – accounts, teams)
├─ Cohorts (saved query result sets)
├─ Annotations (chart markers – deploys, campaigns)
└─ Lookup Tables (CSV-uploaded join data)
Reserved property keys (prefix $):
$insert_id 5-day dedupe key for retries
$time event timestamp (unix ms / sec, configurable)
$browser, $os, $city, etc. – auto-set by client SDKs only
Identity model: distinct_id is the join key. $identify events merge
multiple distinct_ids; alias is the legacy linking method. People
profiles are 1:1 with the canonical distinct_id.
Region matters: events posted to api.mixpanel.com (US) and
api-eu.mixpanel.com (EU) are stored in separate clusters. Projects
are pinned to a region at creation and CANNOT be migrated.Available operations
11 operations available. Click any row to jump to its detail.
| Operation | Category | What it does |
|---|---|---|
| List Annotations | General | List project annotations |
| Get Cohort Members | General | Engage-format query for members of a cohort |
| Create Annotation | General | Create a project annotation |
| Update People Profile | General | Set, set-once, increment, append, union, unset on a user profile |
| Export Events | General | Raw event export (Data Pipeline / Raw Export) |
| Update Group Profile | General | Update group analytics profile |
| List Cohorts | General | List saved cohorts |
| List Lookup Tables | General | List configured lookup tables |
| Run JQL Query | General | Run a JavaScript Query Language script |
| Track Batch | General | Ingest up to 2000 events in one call |
| Track Event | General | Ingest a single event (JSON Importer) |
Operations
List Annotations
List project annotations
No input parameters.
Tips
- GET /api/2.0/annotations – chart markers (deploys, campaigns, incidents) overlaid on dashboards.
- Filter by from_date + to_date; date format is YYYY-MM-DD.
Get Cohort Members
Engage-format query for members of a cohort
| Parameter | Required | Type | Description |
|---|---|---|---|
Filter By Cohort filter_by_cohort | No | text |
Tips
- Returns distinct_ids of users in a saved cohort. cohort_id from List Cohorts.
- engagement parameter switches between fetching by user-ID or by full profile.
Create Annotation
Create a project annotation
| Parameter | Required | Type | Description |
|---|---|---|---|
Date date | No | text | |
Description description | No | text | |
Project Id project_id | No | text |
Tips
- POST /api/2.0/annotations/create – body: date (YYYY-MM-DD HH:MM:SS) + description.
- Useful for automated CI: post a Mixpanel annotation on every prod deploy to correlate metric shifts with releases.
Update People Profile
Set, set-once, increment, append, union, unset on a user profile
No input parameters.
Tips
- People profile mutations. Operators: $set, $set_once, $add, $append, $union, $remove, $unset, $delete.
- $ignore_time:true keeps $last_seen from being touched – useful for backfills.
Export Events
Raw event export (Data Pipeline / Raw Export)
No input parameters.
Tips
- Raw event export. from_date + to_date in YYYY-MM-DD UTC. Streaming JSONL response – large windows can take minutes.
- where= takes the Mixpanel expression language; e.g. properties['$country_code'] == 'ZA'.
Update Group Profile
Update group analytics profile
No input parameters.
Tips
- Group Analytics – entity-level (account, company, team) rather than user-level analytics.
- Set group properties via $group_set, $group_unset operators on this endpoint. group_key + group_id together identify the entity.
- Group Analytics needs Growth or Enterprise. Free tier returns 402 on these endpoints.
List Cohorts
List saved cohorts
No input parameters.
Tips
- Returns project cohort definitions with cohort_id, name, description, count, is_visible_by_owner_only.
- Cohorts can be Behavioral (events-based) or Property (people-properties-based). The 'name' is the only human-readable identifier – cohort_id is opaque integer.
List Lookup Tables
List configured lookup tables
No input parameters.
Tips
- Returns CSV-uploaded join tables (Mixpanel's equivalent of dimension tables). Each table has a UUID + name + sync state.
- Use these in JQL via mixpanel.lookups['<name>'] to enrich event reports with static metadata you don't want to send as event properties.
Run JQL Query
Run a JavaScript Query Language script
| Parameter | Required | Type | Description |
|---|---|---|---|
Script script | No | text | |
Params params | No | text |
Tips
- JQL = JavaScript queries over events. Use Events() and People() as starting points; chain .filter / .groupBy / .reduce.
- 5-minute query timeout. Heavy joins are faster as two queries + client-side merge.
Track Batch
Ingest up to 2000 events in one call
No input parameters.
Tips
- Up to 2000 events / 2 MB. Way cheaper than 2000 single calls; use this whenever you have >1 event to send.
- Each event needs its own $insert_id for dedupe – Mixpanel retains insert_ids for 5 days.
Track Event
Ingest a single event (JSON Importer)
No input parameters.
Tips
- Single event ingest. Payload: event + properties (must include 'token' and either 'distinct_id' or 'device_id').
- Server-side ingest doesn't auto-populate $os/$browser – set them explicitly if you want them in funnels.
FAQ
- Service account vs project token vs API secret – which is which?
- Project token: 32-char hex, public, used in client-side ingest. API secret: legacy, deprecated for query auth (warn now, removed later). Service account: u/p pair, scoped per-project, the only auth that still works for query going forward. Use service accounts for everything.
- Why are events dropped silently?
- Three causes: (1) time too far in past/future (>5 days each way); (2) distinct_id missing or empty string; (3) project token mismatch (wrong project). Server-side ingest reports success even on these – check /import/ endpoints for strict validation.
- EU project – different endpoints?
- Yes. api-eu.mixpanel.com for ingest and query. The connector auto-routes based on which region you select on the credential.
- Can I delete a user (GDPR)?
- Engage with $delete:true (or use a dedicated /api/2.0/engage with $delete). Hard-delete on Mixpanel's side is async – propagates within 30 days. The connector exposes this through Engage.