Using pip:
pip3 install customerio-cdp-analyticsor you can install directly from this repo:
pip3 install git+http://github.com/customerio/cdp-analytics-pythonfromcustomerioimportanalyticsanalytics.write_key='YOUR_WRITE_KEY'analytics.track(user_id=4, event='order_complete')If you're using a different data center such as our EU region, you can specify an alternate endpoint:
fromcustomerioimportanalyticsanalytics.write_key='YOUR_WRITE_KEY'analytics.host='https://cdp-eu.customer.io'analytics.track(user_id=4, event='order_complete')The links below contain more detailed documentation on how to use this library: