Mixpanel data export - terminated early response

235 Views Asked by At

Just exploring mixpanel's data export. The events are pushed from web app to mixpanel and I am trying to extract events from mixpanel thereafter; tried using the UI where we can hit api directly via mixpanel & even tried on local server backend.

The error remains the same, 'terminated early'. The response code is 200 though

Request

curl --request GET \
 --url 'https://data.mixpanel.com/api/2.0/export?project_id=<Project id redacted>&from_date=2023-08-06&to_date=2023-08-06' \
 --header 'accept: text/plain' \
 --header 'authorization: Basic <redacted>'

Response

terminated early

1

There are 1 best solutions below

0
Simi On

I was receiving the same error because my mixpanel project was in the EU.

In that case, you should use the base-url https://data-eu.mixpanel.com/api/2.0/ instead of https://data.mixpanel.com/api/2.0/.