Last active
January 2, 2024 16:14
-
-
Save ak--47/05d73181bf85d4b47317dee9d16aed4d to your computer and use it in GitHub Desktop.
reload mixpanel data
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# reload all EVENTS from one project to another | |
# environment variables | |
# CUSTOMIZE THESE 👇 | |
export START=2023-01-01 | |
export END=2023-05-31 | |
export SOURCE_SECRET=my-source-project-secret | |
export TARGET_SECRET=my-target-project-secret | |
# export → import | |
npx --yes mixpanel-import --type export --start $START --end $END --secret $SOURCE_SECRET && npx --yes mixpanel-import ./mixpanel-exports/ --secret $TARGET_SECRET | |
############################## | |
# reload all USER PROFILES from one project to another | |
# environment variables | |
# CUSTOMIZE THESE 👇 | |
export SOURCE_SECRET=my-source-project-secret | |
export TARGET_SECRET=my-target-project-secret | |
export TARGET_TOKEN=my-target-project-token | |
# export → import | |
npx --yes mixpanel-import --type peopleExport --secret $SOURCE_SECRET && npx --yes mixpanel-import ./mixpanel-exports/ --type user --token $TARGET_TOKEN --secret $TARGET_SECRET --fixData --format json |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment