Skip to main content

Official Mixpanel library for Python

Project description

PyPI PyPI - Python Version PyPI - Downloads https://github.com/mixpanel/mixpanel-python/workflows/Tests/badge.svg

This is the official Mixpanel Python library. This library allows for server-side integration of Mixpanel.

To import, export, transform, or delete your Mixpanel data, please see our mixpanel-utils package.

Installation

The library can be installed using pip:

pip install mixpanel

Getting Started

Typical usage usually looks like this:

from mixpanel import Mixpanel

mp = Mixpanel(YOUR_TOKEN)

# tracks an event with certain properties
mp.track(DISTINCT_ID, 'button clicked', {'color' : 'blue', 'size': 'large'})

# sends an update to a user profile
mp.people_set(DISTINCT_ID, {'$first_name' : 'Ilya', 'favorite pizza': 'margherita'})

You can use an instance of the Mixpanel class for sending all of your events and people updates.

Additional Information

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mixpanel-4.10.1.tar.gz (9.8 kB view hashes)

Uploaded Source

Built Distribution

mixpanel-4.10.1-py2.py3-none-any.whl (9.0 kB view hashes)

Uploaded Python 2 Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page